:root {
    color-scheme: light;
    --bg: #f5f7fb;
    --panel: #ffffff;
    --panel-soft: #eef6f6;
    --ink: #13202f;
    --muted: #667085;
    --line: #d9e2e7;
    --primary: #0f766e;
    --primary-dark: #115e59;
    --navy: #172033;
    --accent: #b45309;
    --danger: #b42318;
    --success: #027a48;
    --shadow: 0 18px 45px rgba(20, 32, 48, 0.1);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-width: 320px;
    background: var(--bg);
    color: var(--ink);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
}

a {
    color: inherit;
}

.page-shell {
    min-height: 100vh;
}

.topbar {
    position: sticky;
    top: 0;
    z-index: 20;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 14px clamp(18px, 4vw, 56px);
    border-bottom: 1px solid rgba(217, 226, 231, 0.82);
    background: rgba(255, 255, 255, 0.94);
    backdrop-filter: blur(14px);
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 220px;
    text-decoration: none;
}

.brand-mark {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    background: #ffffff;
    object-fit: contain;
    box-shadow: inset 0 0 0 1px var(--line);
}

.brand-name {
    display: block;
    color: var(--ink);
    font-size: 15px;
    font-weight: 800;
    line-height: 1.1;
}

.brand-subtitle {
    display: block;
    margin-top: 2px;
    color: var(--muted);
    font-size: 12px;
    font-weight: 600;
}

.nav-links {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 8px;
}

.nav-link,
.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    border-radius: 8px;
    padding: 0 14px;
    border: 1px solid transparent;
    font-size: 14px;
    font-weight: 750;
    text-decoration: none;
    white-space: nowrap;
}

.nav-link {
    color: #344054;
}

.nav-link:hover {
    background: #eef6f6;
    color: var(--primary-dark);
}

.button {
    border-color: var(--primary);
    background: var(--primary);
    color: #ffffff;
    box-shadow: 0 10px 24px rgba(15, 118, 110, 0.18);
}

.button:hover {
    background: var(--primary-dark);
}

.button.secondary {
    border-color: var(--line);
    background: #ffffff;
    color: var(--ink);
    box-shadow: none;
}

.button.secondary:hover {
    border-color: #9bb8ba;
    background: #f7fbfb;
}

.button.warning {
    border-color: var(--accent);
    background: var(--accent);
}

.button.danger {
    border-color: var(--danger);
    background: var(--danger);
}

.hero {
    display: grid;
    grid-template-columns: minmax(0, 1.08fr) minmax(360px, 0.92fr);
    gap: clamp(28px, 5vw, 56px);
    align-items: center;
    padding: clamp(44px, 7vw, 86px) clamp(18px, 4vw, 56px) 42px;
    background:
        linear-gradient(110deg, rgba(23, 32, 51, 0.97), rgba(13, 67, 70, 0.92)),
        radial-gradient(circle at 80% 15%, rgba(15, 118, 110, 0.32), transparent 30%);
    color: #ffffff;
}

.eyebrow {
    margin: 0 0 16px;
    color: #99f6e4;
    font-size: 13px;
    font-weight: 850;
    letter-spacing: 0;
    text-transform: uppercase;
}

.hero h1 {
    margin: 0;
    max-width: 880px;
    font-size: clamp(38px, 5.1vw, 72px);
    line-height: 0.98;
    letter-spacing: 0;
}

.hero-copy {
    max-width: 760px;
    margin: 22px 0 0;
    color: #d8e7ea;
    font-size: clamp(17px, 1.7vw, 21px);
    line-height: 1.65;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 30px;
}

.inline-form {
    display: inline-flex;
    margin: 0;
}

.trust-row {
    display: grid;
    grid-template-columns: repeat(3, minmax(120px, 1fr));
    gap: 12px;
    max-width: 690px;
    margin-top: 34px;
}

.trust-item {
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 8px;
    padding: 15px;
    background: rgba(255, 255, 255, 0.07);
}

.trust-item strong {
    display: block;
    font-size: 22px;
    line-height: 1;
}

.trust-item span {
    display: block;
    margin-top: 7px;
    color: #c4d9dd;
    font-size: 13px;
    line-height: 1.35;
}

.audit-panel {
    border-radius: 8px;
    padding: 24px;
    background: #ffffff;
    color: var(--ink);
    box-shadow: var(--shadow);
}

.audit-panel h2 {
    margin: 0;
    font-size: 22px;
}

.audit-panel p {
    margin: 8px 0 22px;
    color: var(--muted);
    line-height: 1.55;
}

.form-grid {
    display: grid;
    gap: 14px;
}

.field label {
    display: block;
    margin-bottom: 7px;
    color: #344054;
    font-size: 13px;
    font-weight: 800;
}

.field input,
.field select {
    width: 100%;
    min-height: 46px;
    border: 1px solid #cbd5dc;
    border-radius: 8px;
    padding: 0 13px;
    background: #ffffff;
    color: var(--ink);
    font: inherit;
}

.field input:focus,
.field select:focus {
    outline: 3px solid rgba(15, 118, 110, 0.18);
    border-color: var(--primary);
}

.section {
    padding: clamp(38px, 6vw, 72px) clamp(18px, 4vw, 56px);
}

.section-inner {
    max-width: 1180px;
    margin: 0 auto;
}

.section-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 24px;
}

.section-header h2 {
    margin: 0;
    font-size: clamp(28px, 3.2vw, 42px);
    line-height: 1.08;
}

.section-header p {
    max-width: 540px;
    margin: 0;
    color: var(--muted);
    line-height: 1.6;
}

.metric-grid,
.card-grid,
.workflow-grid {
    display: grid;
    gap: 16px;
}

.metric-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.card-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.workflow-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
}

.metric,
.card,
.workflow-step {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--panel);
}

.metric {
    padding: 22px;
}

.metric strong {
    display: block;
    color: var(--primary-dark);
    font-size: 30px;
    line-height: 1;
}

.metric span {
    display: block;
    margin-top: 10px;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.45;
}

.card {
    display: flex;
    flex-direction: column;
    min-height: 220px;
    padding: 22px;
}

.card h3,
.workflow-step h3 {
    margin: 0;
    font-size: 19px;
}

.card p,
.workflow-step p {
    color: var(--muted);
    line-height: 1.6;
}

.card p {
    margin: 11px 0 22px;
}

.card .button {
    width: fit-content;
    margin-top: auto;
}

.workflow-step {
    padding: 18px;
    background: #ffffff;
}

.step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    margin-bottom: 16px;
    border-radius: 8px;
    background: var(--panel-soft);
    color: var(--primary-dark);
    font-weight: 850;
}

.split-band {
    background: #ffffff;
}

.command-panel {
    display: grid;
    grid-template-columns: 0.8fr 1.2fr;
    gap: 22px;
    align-items: stretch;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 24px;
    background: #ffffff;
    box-shadow: var(--shadow);
}

.status-block {
    border-radius: 8px;
    padding: 22px;
    background: var(--navy);
    color: #ffffff;
}

.status-pill {
    display: inline-flex;
    border-radius: 999px;
    padding: 6px 10px;
    background: rgba(153, 246, 228, 0.16);
    color: #99f6e4;
    font-size: 12px;
    font-weight: 850;
    text-transform: uppercase;
}

.status-block h1,
.status-block h2 {
    margin: 18px 0 10px;
}

.status-block p {
    color: #d8e7ea;
    line-height: 1.6;
}

.action-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.action-tile {
    display: block;
    min-height: 106px;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 17px;
    background: #ffffff;
    text-decoration: none;
}

.action-tile:hover {
    border-color: #9bb8ba;
    background: #f7fbfb;
}

.action-tile strong {
    display: block;
    margin-bottom: 7px;
    font-size: 16px;
}

.action-tile span {
    color: var(--muted);
    font-size: 13px;
    line-height: 1.45;
}

.log-panel,
.result-panel {
    margin-top: 22px;
    border-radius: 8px;
    padding: 20px;
    background: #101828;
    color: #e6f3f5;
}

.log-panel h2,
.result-panel h1 {
    margin-top: 0;
}

.log-lines,
.result-pre {
    overflow: auto;
    max-height: 360px;
    white-space: pre-wrap;
    font-size: 13px;
    line-height: 1.65;
}

.preview-shell {
    max-width: 980px;
    margin: 0 auto;
    padding: clamp(28px, 5vw, 60px) 18px;
}

.preview-header {
    border-radius: 8px;
    padding: clamp(28px, 5vw, 48px);
    background: linear-gradient(120deg, var(--navy), #0f766e);
    color: #ffffff;
}

.preview-header h1 {
    max-width: 720px;
    margin: 0;
    font-size: clamp(32px, 5vw, 56px);
    line-height: 1;
}

.preview-header p {
    max-width: 720px;
    color: #d8e7ea;
    font-size: 18px;
    line-height: 1.65;
}

.risk-list {
    display: grid;
    gap: 12px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.risk-list li {
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 15px;
    background: #ffffff;
    font-weight: 750;
}

.checklist {
    display: grid;
    gap: 10px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.checklist li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 14px;
    background: #ffffff;
    line-height: 1.45;
}

.checklist input {
    width: 18px;
    height: 18px;
    margin-top: 2px;
    accent-color: var(--primary);
    flex: 0 0 auto;
}

.stack {
    display: grid;
    gap: 18px;
}

.progress-track {
    height: 12px;
    overflow: hidden;
    border-radius: 999px;
    background: #e8eef2;
}

.progress-fill {
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--primary), #14b8a6);
}

.notice {
    border-left: 5px solid var(--accent);
    border-radius: 8px;
    padding: 20px;
    background: #fffbeb;
    color: #533300;
}

.footer {
    padding: 28px clamp(18px, 4vw, 56px);
    border-top: 1px solid var(--line);
    background: #ffffff;
    color: var(--muted);
    font-size: 13px;
}

@media (max-width: 980px) {
    .hero,
    .command-panel {
        grid-template-columns: 1fr;
    }

    .metric-grid,
    .card-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .workflow-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .section-header {
        align-items: flex-start;
        flex-direction: column;
    }
}

@media (max-width: 700px) {
    .topbar {
        position: static;
        align-items: flex-start;
        flex-direction: column;
    }

    .brand {
        min-width: 0;
    }

    .nav-links {
        justify-content: flex-start;
        width: 100%;
    }

    .nav-link,
    .button {
        white-space: normal;
    }

    .trust-row,
    .metric-grid,
    .card-grid,
    .workflow-grid,
    .action-grid {
        grid-template-columns: 1fr;
    }

    .hero {
        padding-top: 34px;
    }
}
