/* =====================================================================
   ASA landing page. Tokens mirror AccountingSystem/wwwroot/css/app.css
   Theme: system preference, overridden by <html data-theme="light|dark">
   ===================================================================== */

:root {
    --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    --primary: #3b5bdb;
    --primary-rgb: 59, 91, 219;
    --primary-hover: #2f4ac0;
    --on-primary: #ffffff;
    --bg: #ffffff;
    --bg-alt: #f4f6fb;
    --surface: #ffffff;
    --surface-2: #f8f9fc;
    --border: #e4e8f1;
    --text: #1d2433;
    --muted: #667085;
    --dim: #98a2b3;
    --side: #111a2e;
    --good: #12805c;
    --bad: #d92d20;
    --warn: #b54708;
    --series-1: #2a78d6;
    --series-2: #eb6834;
    --series-3: #1baf7a;
    --shadow: 0 1px 2px rgba(16,24,40,.04), 0 1px 3px rgba(16,24,40,.06);
    --shadow-lg: 0 24px 60px rgba(16,24,40,.14);
    --radius: 14px;
    --radius-sm: 8px;
    color-scheme: light;
}

@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) {
        --primary: #6d8aff;
        --primary-rgb: 109, 138, 255;
        --primary-hover: #8aa1ff;
        --on-primary: #0b1020;
        --bg: #0b1020;
        --bg-alt: #0f1628;
        --surface: #121a2c;
        --surface-2: #172036;
        --border: #222d45;
        --text: #e4e9f3;
        --muted: #98a2b8;
        --dim: #6b7690;
        --side: #0a0f1d;
        --good: #3ccb8f;
        --bad: #ff6b5e;
        --warn: #f5a524;
        --shadow: 0 1px 2px rgba(0,0,0,.3);
        --shadow-lg: 0 24px 60px rgba(0,0,0,.45);
        color-scheme: dark;
    }
}

:root[data-theme="dark"] {
    --primary: #6d8aff;
    --primary-rgb: 109, 138, 255;
    --primary-hover: #8aa1ff;
    --on-primary: #0b1020;
    --bg: #0b1020;
    --bg-alt: #0f1628;
    --surface: #121a2c;
    --surface-2: #172036;
    --border: #222d45;
    --text: #e4e9f3;
    --muted: #98a2b8;
    --dim: #6b7690;
    --side: #0a0f1d;
    --good: #3ccb8f;
    --bad: #ff6b5e;
    --warn: #f5a524;
    --shadow: 0 1px 2px rgba(0,0,0,.3);
    --shadow-lg: 0 24px 60px rgba(0,0,0,.45);
    color-scheme: dark;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; }
body {
    margin: 0;
    font-family: var(--font);
    font-size: 16px;
    line-height: 1.6;
    color: var(--text);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
}
h1, h2, h3 { line-height: 1.15; letter-spacing: -.02em; margin: 0 0 .5em; }
h1 { font-size: clamp(2.1rem, 4.6vw, 3.4rem); font-weight: 800; }
h2 { font-size: clamp(1.6rem, 3vw, 2.3rem); font-weight: 800; }
h3 { font-size: 1.08rem; font-weight: 700; }
p { margin: 0 0 1rem; }
a { color: var(--primary); text-decoration: none; }
code { font-family: ui-monospace, SFMono-Regular, Consolas, monospace; }

.container { width: 100%; max-width: 1180px; margin: 0 auto; padding: 0 16px; }
.container.narrow { max-width: 780px; }

.eyebrow {
    display: inline-flex; align-items: center; gap: .45rem;
    font-size: .8rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
    color: var(--primary);
    margin-bottom: .9rem;
}

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: .55rem;
    font: inherit; font-weight: 600; font-size: .95rem;
    padding: .65rem 1.15rem;
    border-radius: var(--radius-sm);
    border: 1px solid transparent;
    cursor: pointer;
    transition: background .15s, border-color .15s, transform .15s;
    white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); }
.btn-sm { padding: .45rem .85rem; font-size: .88rem; }
.btn-lg { padding: .85rem 1.4rem; font-size: 1rem; }
.btn-primary { background: var(--primary); color: var(--on-primary); }
.btn-primary:hover { background: var(--primary-hover); }
.btn-ghost { background: var(--surface); color: var(--text); border-color: var(--border); }
.btn-ghost:hover { border-color: var(--primary); }
.btn-light { background: #fff; color: #1d2433; }
.icon-btn {
    width: 38px; height: 38px;
    display: inline-grid; place-items: center;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--muted);
    cursor: pointer;
}
.icon-btn:hover { color: var(--primary); border-color: var(--primary); }

/* ---------- Header ---------- */
.site-header {
    position: sticky; top: 0; z-index: 50;
    background: color-mix(in srgb, var(--bg) 85%, transparent);
    backdrop-filter: saturate(1.4) blur(12px);
    border-bottom: 1px solid var(--border);
}
.nav { display: flex; align-items: center; gap: 1.5rem; height: 64px; }
.brand { display: inline-flex; align-items: center; gap: .6rem; color: var(--text); }
.brand-mark {
    width: 36px; height: 36px; border-radius: 9px;
    display: grid; place-items: center;
    background: var(--primary); color: #fff;
}
.brand-text { display: flex; flex-direction: column; font-weight: 800; font-size: 1.05rem; line-height: 1.05; }
.brand-text small { font-weight: 500; font-size: .7rem; color: var(--muted); letter-spacing: .02em; }
.nav-links { display: flex; gap: 1.4rem; margin-left: auto; }
.nav-links a { color: var(--muted); font-weight: 500; font-size: .93rem; }
.nav-links a:hover { color: var(--text); }
.nav-actions { display: flex; align-items: center; gap: .6rem; }
.nav-burger { display: none; }

/* ---------- Hero ---------- */
.hero {
    padding: 72px 0 80px;
    background:
        radial-gradient(900px 420px at 85% -10%, rgba(var(--primary-rgb), .16), transparent 70%),
        radial-gradient(700px 380px at -10% 110%, rgba(var(--primary-rgb), .08), transparent 70%);
    overflow: hidden;
}
.hero-grid { display: grid; grid-template-columns: 1.02fr 1fr; gap: 56px; align-items: center; }
.lead { font-size: 1.15rem; color: var(--muted); max-width: 36rem; }
.hero-cta { display: flex; flex-wrap: wrap; gap: .75rem; margin: 1.6rem 0 1.4rem; }
.hero-points { list-style: none; padding: 0; margin: 0; display: grid; gap: .4rem; color: var(--muted); font-size: .94rem; }
.hero-points i { color: var(--good); margin-right: .45rem; }

.hero-visual { position: relative; }
.mock {
    border-radius: var(--radius);
    background: var(--surface);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-lg);
    overflow: hidden;
    transform: perspective(1600px) rotateY(-6deg) rotateX(2deg);
}
.mock-bar { display: flex; align-items: center; gap: 6px; padding: 10px 14px; border-bottom: 1px solid var(--border); background: var(--surface-2); }
.mock-bar > span { width: 10px; height: 10px; border-radius: 50%; background: var(--border); }
.mock-url { margin-left: 10px; font-size: .72rem; color: var(--dim); }
.mock-body { display: grid; grid-template-columns: 52px 1fr; min-height: 340px; }
.mock-side { background: var(--side); display: flex; flex-direction: column; align-items: center; gap: 18px; padding: 14px 0; color: #6f7b95; font-size: .9rem; }
.mock-side .active { color: #fff; }
.mock-brand { width: 28px; height: 28px; border-radius: 7px; background: var(--primary); color: #fff; display: grid; place-items: center; font-size: .75rem; margin-bottom: 4px; }
.mock-main { padding: 16px; display: grid; gap: 12px; background: var(--bg-alt); }
.mock-kpis { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.kpi { background: var(--surface); border: 1px solid var(--border); border-radius: 9px; padding: 10px 12px; display: flex; flex-direction: column; }
.kpi small { font-size: .66rem; color: var(--muted); }
.kpi strong { font-size: 1.05rem; }
.kpi em { font-style: normal; font-size: .66rem; color: var(--muted); }
.kpi em.up { color: var(--good); }
.kpi em.down { color: var(--warn); }
.mock-chart { background: var(--surface); border: 1px solid var(--border); border-radius: 9px; padding: 10px 12px; }
.mock-chart-head { display: flex; justify-content: space-between; font-size: .7rem; font-weight: 600; color: var(--muted); }
.legend i { display: inline-block; width: 8px; height: 8px; border-radius: 2px; margin: 0 4px 0 8px; }
.legend .s1 { background: var(--series-1); }
.legend .s2 { background: var(--series-2); }
.bars { display: grid; grid-template-columns: repeat(8, 1fr); gap: 10px; align-items: end; height: 110px; margin-top: 8px; }
.bars div { display: flex; gap: 3px; align-items: end; height: 100%; }
.bars i, .bars b { flex: 1; border-radius: 3px 3px 0 0; }
.bars i { background: var(--series-1); }
.bars b { background: var(--series-2); opacity: .85; }
.mock-list { background: var(--surface); border: 1px solid var(--border); border-radius: 9px; padding: 4px 12px; }
.mock-list .row { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 7px 0; font-size: .72rem; border-bottom: 1px solid var(--border); }
.mock-list .row:last-child { border-bottom: 0; }
.pill { font-size: .62rem; font-weight: 700; padding: 2px 8px; border-radius: 99px; white-space: nowrap; }
.pill.warn { background: rgba(181,71,8,.12); color: var(--warn); }
.pill.ok { background: rgba(18,128,92,.12); color: var(--good); }
.pill.info { background: rgba(var(--primary-rgb), .12); color: var(--primary); }

.float-card {
    position: absolute;
    display: flex; align-items: center; gap: .7rem;
    background: var(--surface); border: 1px solid var(--border);
    border-radius: 12px; padding: .7rem .95rem;
    box-shadow: var(--shadow-lg);
    font-size: .82rem;
}
.float-card i { width: 32px; height: 32px; border-radius: 8px; display: grid; place-items: center; background: rgba(var(--primary-rgb), .12); color: var(--primary); }
.float-card div { display: flex; flex-direction: column; line-height: 1.3; }
.float-card small { color: var(--muted); }
.fc-1 { left: -28px; bottom: 34px; }
.fc-2 { right: -14px; top: -18px; }
.fc-2 i { background: rgba(217,45,32,.12); color: var(--bad); }

/* ---------- Strip ---------- */
.strip { border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); background: var(--surface-2); }
.strip-inner { display: flex; align-items: center; gap: 1.5rem; padding-top: 18px; padding-bottom: 18px; flex-wrap: wrap; }
.strip-label { font-size: .85rem; color: var(--muted); font-weight: 500; }
.chips { display: flex; flex-wrap: wrap; gap: .5rem; }
.chips span { font-size: .8rem; font-weight: 700; padding: .3rem .7rem; border-radius: 99px; border: 1px solid var(--border); background: var(--surface); }

/* ---------- Sections ---------- */
.section { padding: 88px 0; }
.section.alt { background: var(--bg-alt); }
.section-head { text-align: center; max-width: 680px; margin: 0 auto 48px; }
.section-head p { color: var(--muted); font-size: 1.05rem; }

.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.feature {
    background: var(--surface); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 24px;
    box-shadow: var(--shadow);
    transition: transform .2s, box-shadow .2s;
}
.feature:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.feature p { color: var(--muted); font-size: .94rem; margin: 0; }
.f-icon { width: 44px; height: 44px; border-radius: 11px; display: grid; place-items: center; margin-bottom: 16px; font-size: 1.1rem; }
.c1 { background: rgba(42,120,214,.12); color: var(--series-1); }
.c2 { background: rgba(235,104,52,.12); color: var(--series-2); }
.c3 { background: rgba(27,175,122,.12); color: var(--series-3); }
.c4 { background: rgba(124,92,255,.12); color: #7c5cff; }
.c5 { background: rgba(214,51,132,.12); color: #d63384; }
.c6 { background: rgba(var(--primary-rgb), .12); color: var(--primary); }

/* ---------- Workflow ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.split > div > p { color: var(--muted); font-size: 1.05rem; }
.checks { list-style: none; padding: 0; margin: 1.5rem 0 0; display: grid; gap: 1rem; }
.checks li { display: flex; gap: .8rem; }
.checks i { color: var(--good); margin-top: .25rem; }
.checks div { display: flex; flex-direction: column; }
.checks span { color: var(--muted); font-size: .93rem; }
.flow-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 26px; box-shadow: var(--shadow-lg); }
.flow-title { font-weight: 700; margin-bottom: 18px; display: flex; gap: .6rem; align-items: center; }
.flow-title i { color: var(--primary); }
.flow { list-style: none; margin: 0; padding: 0; position: relative; }
.flow::before { content: ""; position: absolute; left: 7px; top: 10px; bottom: 10px; width: 2px; background: var(--border); }
.flow li { display: flex; gap: 1rem; padding: 0 0 18px; position: relative; }
.flow li:last-child { padding-bottom: 0; }
.flow div { display: flex; flex-direction: column; }
.flow small { color: var(--muted); font-size: .84rem; }
.dot { width: 16px; height: 16px; border-radius: 50%; flex: none; margin-top: 4px; border: 3px solid var(--surface); box-shadow: 0 0 0 1px var(--border); position: relative; }
.s-draft { background: var(--dim); }
.s-wait { background: var(--warn); }
.s-post { background: var(--primary); }
.s-info { background: var(--series-1); }
.s-done { background: var(--good); }

/* ---------- Compliance ---------- */
.tax-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.tax { display: flex; flex-direction: column; gap: .3rem; padding: 20px 22px; border-radius: var(--radius); border: 1px solid var(--border); background: var(--surface); border-left: 4px solid var(--primary); }
.tax b { font-size: 1.05rem; }
.tax span { color: var(--muted); font-size: .92rem; }

/* ---------- Demo ---------- */
.role-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.role { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 22px; display: flex; flex-direction: column; }
.role > i { color: var(--primary); font-size: 1.2rem; margin-bottom: 12px; }
.role p { color: var(--muted); font-size: .92rem; flex: 1; }
.role code { align-self: flex-start; font-size: .85rem; padding: .25rem .6rem; border-radius: 6px; background: var(--surface-2); border: 1px solid var(--border); }
.demo-cta { margin-top: 32px; display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 1rem; }
.cred { display: flex; align-items: center; gap: .7rem; padding: .5rem .6rem .5rem 1rem; border-radius: 10px; border: 1px dashed var(--border); background: var(--surface); }
.cred span { color: var(--muted); font-size: .88rem; }
.cred code { font-weight: 700; }
.fine { text-align: center; color: var(--dim); font-size: .85rem; margin-top: 18px; }

/* ---------- FAQ ---------- */
.faq { border-bottom: 1px solid var(--border); padding: 18px 0; }
.faq summary { cursor: pointer; font-weight: 600; list-style: none; display: flex; justify-content: space-between; gap: 1rem; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--primary); font-size: 1.3rem; line-height: 1; }
.faq[open] summary::after { content: "−"; }
.faq p { color: var(--muted); margin: .7rem 0 0; }

/* ---------- Final CTA / footer ---------- */
.final { padding: 0 0 88px; }
.final-inner {
    text-align: center; color: #fff;
    background: linear-gradient(135deg, #3b5bdb, #2a3fa8 60%, #1f2f7a);
    border-radius: 20px; padding: 56px 24px;
}
.final-inner p { color: rgba(255,255,255,.8); font-size: 1.05rem; margin-bottom: 1.6rem; }
.site-footer { border-top: 1px solid var(--border); padding: 28px 0; }
.foot { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.foot nav { display: flex; gap: 1.2rem; }
.foot nav a, .foot small { color: var(--muted); font-size: .9rem; }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
    .hero-grid, .split { grid-template-columns: 1fr; gap: 48px; }
    .feature-grid, .tax-grid, .role-grid { grid-template-columns: repeat(2, 1fr); }
    .mock { transform: none; }
    .fc-1 { left: 8px; }
    .fc-2 { right: 8px; }
}
@media (max-width: 760px) {
    .nav-links {
        display: none;
        position: absolute; top: 64px; left: 0; right: 0;
        flex-direction: column; gap: 0;
        background: var(--bg); border-bottom: 1px solid var(--border);
        padding: 8px 16px 16px;
    }
    .nav-links.open { display: flex; }
    .nav-links a { padding: .6rem 0; }
    .nav-burger { display: inline-grid; }
    .nav-actions { margin-left: auto; }
    .nav-actions .btn { display: none; }
    .hero { padding: 48px 0 64px; }
    .section { padding: 64px 0; }
    .feature-grid, .tax-grid, .role-grid { grid-template-columns: 1fr; }
    .mock-kpis { grid-template-columns: repeat(2, 1fr); }
    .mock-kpis .kpi:last-child { display: none; }
    .float-card { display: none; }
    .hero-cta .btn { flex: 1 1 100%; }
}

/* ---------- Contact ---------- */
.contact { align-items: start; }
.inquiry {
    display: grid; gap: 14px;
    background: var(--surface); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 26px; box-shadow: var(--shadow-lg);
}
.inquiry label { display: grid; gap: 6px; font-size: .88rem; font-weight: 600; }
.inquiry label b { color: var(--bad); }
.inquiry input, .inquiry select, .inquiry textarea {
    font: inherit; font-size: .95rem; font-weight: 400;
    width: 100%; padding: .6rem .75rem;
    color: var(--text); background: var(--surface-2);
    border: 1px solid var(--border); border-radius: var(--radius-sm);
}
.inquiry textarea { resize: vertical; min-height: 120px; }
.inquiry input:focus, .inquiry select:focus, .inquiry textarea:focus { outline: 2px solid rgba(var(--primary-rgb), .35); border-color: var(--primary); }
.inquiry .invalid { border-color: var(--bad); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.inquiry .btn { justify-self: start; }
.inquiry .btn:disabled { opacity: .6; cursor: wait; transform: none; }
.form-status { margin: 0; font-size: .92rem; min-height: 1.4em; }
.form-status.ok { color: var(--good); }
.form-status.err { color: var(--bad); }
.final-cta { display: flex; flex-wrap: wrap; justify-content: center; gap: .75rem; }
.btn-outline-light { background: transparent; color: #fff; border-color: rgba(255,255,255,.55); }
.btn-outline-light:hover { border-color: #fff; }
@media (max-width: 760px) {
    .field-row { grid-template-columns: 1fr; }
    .inquiry { padding: 20px; }
    .inquiry .btn { justify-self: stretch; }
}
