/* ==========================================================
   AudiV — site styles. Static, no build, no framework.

   Palette mirrors the iOS app:
     - Brand primary navy:  #0F1A2E
     - Brand secondary:     #20384C
     - Accent (Ember):      #FA7317
     - Accent (Aurora blue):#3B81F5

   Layered backgrounds use the same teal-leaning navy as the
   app gradient so the marketing site feels like a continuation
   of the product, not a separate page.
   ========================================================== */

:root {
    /* Core palette */
    --bg-deep:        #0A0F1A;
    --bg-navy:        #0F1A2E;
    --bg-navy-2:      #16263F;
    --surface:        #1A2940;
    --surface-2:      rgba(255, 255, 255, 0.04);
    --surface-3:      rgba(255, 255, 255, 0.06);
    --border:         rgba(255, 255, 255, 0.08);
    --border-strong:  rgba(255, 255, 255, 0.16);

    /* Brand */
    --ember:          #FA7317;
    --ember-soft:     #FFB347;
    --aurora:         #3B81F5;
    --aurora-soft:    #6BA8FF;
    --teal:           #14B8A6;

    /* Text */
    --text-1:         #F4F6FB;
    --text-2:         #B8C2D4;
    --text-3:         #7B8AA3;
    --text-muted:     #5C6A82;

    /* Sizing */
    --max-width:      1180px;
    --radius-sm:      8px;
    --radius:         14px;
    --radius-lg:      22px;
    --radius-pill:    999px;

    /* Type */
    --font-sans:      -apple-system, BlinkMacSystemFont, "SF Pro Text",
                      "Inter", "Segoe UI", Roboto, "Helvetica Neue",
                      Arial, sans-serif;
    --font-mono:      "SF Mono", "JetBrains Mono", Menlo, Consolas,
                      monospace;

    /* Motion */
    --easing:         cubic-bezier(0.22, 0.61, 0.36, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html {
    background: var(--bg-deep);
    color-scheme: dark;
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-sans);
    font-size: 17px;
    line-height: 1.6;
    color: var(--text-2);
    background:
        radial-gradient(1200px 800px at 80% -200px,
            rgba(250, 115, 23, 0.10), transparent 60%),
        radial-gradient(1100px 700px at -100px 30%,
            rgba(59, 129, 245, 0.10), transparent 60%),
        linear-gradient(180deg, var(--bg-deep) 0%,
            var(--bg-navy) 30%,
            var(--bg-deep) 100%);
    min-height: 100vh;
    overflow-x: hidden;
}

img, svg { display: block; max-width: 100%; }

a {
    color: var(--aurora-soft);
    text-decoration: none;
    transition: color 0.18s var(--easing);
}
a:hover { color: var(--ember-soft); }

::selection {
    background: rgba(250, 115, 23, 0.4);
    color: white;
}

/* ----------------------------------------------------------
   Navbar — translucent + accent-bordered, sticky on scroll.
   ---------------------------------------------------------- */

.nav {
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: blur(18px) saturate(180%);
    -webkit-backdrop-filter: blur(18px) saturate(180%);
    background: rgba(10, 15, 26, 0.7);
    border-bottom: 1px solid var(--border);
}

.nav-inner {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 14px 24px;
    display: flex;
    align-items: center;
    gap: 24px;
}

.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 19px;
    color: var(--text-1);
    letter-spacing: -0.4px;
}

.brand-mark {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    background: linear-gradient(135deg, var(--ember) 0%, var(--aurora) 100%);
    box-shadow:
        0 0 0 1px rgba(255, 255, 255, 0.12),
        0 4px 14px rgba(250, 115, 23, 0.35);
    position: relative;
    overflow: hidden;
}
.brand-mark::after {
    content: "";
    position: absolute;
    inset: 6px;
    border: 2px solid rgba(255, 255, 255, 0.85);
    border-radius: 999px;
    border-color: rgba(255, 255, 255, 0.85) rgba(255, 255, 255, 0.5)
                  rgba(255, 255, 255, 0.25) rgba(255, 255, 255, 0.5);
    animation: spin 8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.nav-links {
    display: flex;
    gap: 22px;
    margin-left: auto;
    align-items: center;
}
.nav-links a {
    color: var(--text-2);
    font-size: 14.5px;
    font-weight: 500;
}
.nav-links a:hover { color: var(--text-1); }

.nav-cta {
    padding: 8px 16px;
    border-radius: var(--radius-pill);
    background: linear-gradient(135deg, var(--ember) 0%, #d35b0e 100%);
    color: white !important;
    font-weight: 600;
    box-shadow: 0 4px 14px rgba(250, 115, 23, 0.35);
    transition: transform 0.15s var(--easing), box-shadow 0.18s var(--easing);
}
.nav-cta:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(250, 115, 23, 0.5);
    color: white !important;
}

/* mobile nav toggle */
.nav-toggle {
    display: none;
    background: transparent;
    border: 1px solid var(--border-strong);
    color: var(--text-1);
    width: 38px;
    height: 38px;
    border-radius: 10px;
    cursor: pointer;
    align-items: center;
    justify-content: center;
    margin-left: auto;
}

@media (max-width: 760px) {
    .nav-links { display: none; }
    .nav-toggle { display: flex; }
    .nav-links.open {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: rgba(15, 26, 46, 0.96);
        backdrop-filter: blur(18px);
        padding: 14px 24px 18px;
        border-bottom: 1px solid var(--border);
        gap: 16px;
        align-items: flex-start;
    }
    .nav-links.open .nav-cta { width: 100%; text-align: center; }
}

/* ----------------------------------------------------------
   Container helpers
   ---------------------------------------------------------- */

.section {
    padding: 110px 24px;
    position: relative;
}
.section-narrow { padding: 80px 24px; }

.container {
    max-width: var(--max-width);
    margin: 0 auto;
}

.eyebrow {
    color: var(--ember);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 1.4px;
    text-transform: uppercase;
    margin-bottom: 14px;
}

h1, h2, h3, h4 {
    color: var(--text-1);
    font-weight: 700;
    letter-spacing: -0.6px;
    line-height: 1.15;
}

h1 {
    font-size: clamp(38px, 6vw, 72px);
    letter-spacing: -1.4px;
    line-height: 1.05;
}
h2 { font-size: clamp(28px, 3.4vw, 44px); }
h3 { font-size: 22px; }
h4 { font-size: 18px; }

p { max-width: 70ch; }
.lede {
    font-size: 19px;
    color: var(--text-2);
    max-width: 60ch;
}

/* ----------------------------------------------------------
   HERO
   ---------------------------------------------------------- */

.hero {
    padding: 120px 24px 60px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero h1 {
    margin: 0 auto 18px;
    max-width: 18ch;
}
.hero .gradient-text {
    background: linear-gradient(120deg, var(--ember) 0%, #ff9d52 50%, var(--aurora) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero .lede { margin: 0 auto 36px; }

.hero-ctas {
    display: flex;
    gap: 14px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 70px;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 26px;
    border-radius: var(--radius-pill);
    font-weight: 600;
    font-size: 16px;
    transition: transform 0.15s var(--easing), box-shadow 0.18s var(--easing);
    cursor: pointer;
    border: none;
}

.btn-primary {
    background: linear-gradient(135deg, var(--ember) 0%, #d35b0e 100%);
    color: white !important;
    box-shadow: 0 6px 22px rgba(250, 115, 23, 0.4);
}
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 32px rgba(250, 115, 23, 0.55);
    color: white !important;
}

.btn-ghost {
    background: var(--surface-3);
    color: var(--text-1) !important;
    border: 1px solid var(--border-strong);
}
.btn-ghost:hover {
    background: var(--surface-2);
    transform: translateY(-2px);
}

.btn svg { width: 18px; height: 18px; }

/* Animated echo waves behind the hero — same vibe as the
   launch screen: 3 concentric waves expanding subtly. */
.hero-waves {
    position: absolute;
    inset: 0;
    z-index: -1;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
    opacity: 0.45;
}
.hero-waves .wave {
    position: absolute;
    border-radius: 50%;
    border: 2px solid var(--aurora);
    animation: wave-pulse 6s ease-in-out infinite;
}
.hero-waves .wave:nth-child(1) {
    width: 360px; height: 360px;
    border-color: rgba(250, 115, 23, 0.45);
    animation-delay: 0s;
}
.hero-waves .wave:nth-child(2) {
    width: 600px; height: 600px;
    border-color: rgba(59, 129, 245, 0.32);
    animation-delay: 1s;
}
.hero-waves .wave:nth-child(3) {
    width: 880px; height: 880px;
    border-color: rgba(20, 184, 166, 0.2);
    animation-delay: 2s;
}
@keyframes wave-pulse {
    0%, 100% { transform: scale(1); opacity: 0.45; }
    50%      { transform: scale(1.05); opacity: 0.65; }
}

/* Phone mockup */
.phone-stage {
    margin: 0 auto;
    max-width: 920px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    align-items: end;
    position: relative;
}
@media (max-width: 720px) {
    .phone-stage { grid-template-columns: 1fr; max-width: 320px; }
    .phone-stage .phone:nth-child(2) { display: none; }
}

.phone {
    position: relative;
    aspect-ratio: 9 / 19;
    background: linear-gradient(180deg, #1B2A42 0%, #0F1A2E 100%);
    border-radius: 42px;
    border: 1px solid var(--border-strong);
    padding: 14px;
    box-shadow:
        0 30px 80px rgba(0, 0, 0, 0.55),
        0 8px 28px rgba(59, 129, 245, 0.18),
        inset 0 1px 0 rgba(255, 255, 255, 0.08);
}
.phone::before {
    content: "";
    position: absolute;
    top: 18px; left: 50%;
    transform: translateX(-50%);
    width: 80px; height: 18px;
    background: var(--bg-deep);
    border-radius: 999px;
    z-index: 2;
}
.phone-screen {
    position: relative;
    height: 100%;
    border-radius: 30px;
    overflow: hidden;
    background: linear-gradient(180deg, #0F1A2E 0%, #060B16 100%);
    padding: 40px 18px 18px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* Mock cards inside phone */
.mock-card {
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
}
.mock-cover {
    width: 36px; height: 36px;
    border-radius: 7px;
    background: linear-gradient(135deg, var(--c1, var(--aurora)), var(--c2, var(--ember)));
    flex-shrink: 0;
    position: relative;
}
.mock-cover::after {
    content: attr(data-mono);
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 800;
    font-size: 12px;
    letter-spacing: 0.5px;
}
.mock-text {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
    min-width: 0;
}
.mock-line {
    height: 8px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.10);
}
.mock-line.short { width: 60%; }
.mock-line.shorter { width: 40%; height: 6px; opacity: 0.7; }

/* "Now playing" mock card with progress + waveform */
.mock-now {
    background: linear-gradient(135deg, rgba(59, 129, 245, 0.12), rgba(250, 115, 23, 0.10));
    border: 1px solid rgba(59, 129, 245, 0.3);
    margin-top: auto;
}
.mock-progress {
    height: 4px;
    background: rgba(255, 255, 255, 0.12);
    border-radius: 999px;
    overflow: hidden;
    margin-top: 6px;
}
.mock-progress-fill {
    height: 100%;
    width: 38%;
    background: linear-gradient(90deg, var(--aurora), var(--ember));
    border-radius: 999px;
    animation: fill-grow 4s ease-in-out infinite;
}
@keyframes fill-grow {
    0%, 100% { width: 38%; }
    50%      { width: 62%; }
}

/* ----------------------------------------------------------
   Trust strip — three quick selling points under the hero
   ---------------------------------------------------------- */

.trust-strip {
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    padding: 28px 24px;
    background: var(--surface-2);
}
.trust-grid {
    max-width: var(--max-width);
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    text-align: center;
}
@media (max-width: 720px) {
    .trust-grid { grid-template-columns: 1fr; gap: 14px; }
}
.trust-item {
    color: var(--text-2);
    font-size: 14.5px;
}
.trust-item strong { color: var(--text-1); font-weight: 600; }
.trust-icon {
    color: var(--ember);
    margin-right: 8px;
    vertical-align: -2px;
}

/* ----------------------------------------------------------
   Feature grid
   ---------------------------------------------------------- */

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
    margin-top: 50px;
}
@media (max-width: 920px) { .features-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .features-grid { grid-template-columns: 1fr; } }

.feature {
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 28px 24px;
    transition: transform 0.18s var(--easing),
                background 0.18s var(--easing),
                border-color 0.18s var(--easing);
}
.feature:hover {
    transform: translateY(-4px);
    background: var(--surface-3);
    border-color: var(--border-strong);
}
.feature-icon {
    width: 44px; height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
    background: var(--icon-bg, rgba(59, 129, 245, 0.18));
    color: var(--icon-fg, var(--aurora));
}
.feature-icon svg { width: 22px; height: 22px; }
.feature h3 { color: var(--text-1); margin-bottom: 8px; font-size: 18px; }
.feature p { color: var(--text-3); font-size: 15px; line-height: 1.55; }

/* per-feature accent overrides */
.feature-blue   { --icon-bg: rgba(59, 129, 245, 0.16);  --icon-fg: #6BA8FF; }
.feature-orange { --icon-bg: rgba(250, 115, 23, 0.16);  --icon-fg: var(--ember-soft); }
.feature-green  { --icon-bg: rgba(16, 185, 129, 0.16);  --icon-fg: #34D399; }
.feature-purple { --icon-bg: rgba(139, 92, 246, 0.16);  --icon-fg: #A78BFA; }
.feature-pink   { --icon-bg: rgba(236, 72, 153, 0.16);  --icon-fg: #F472B6; }
.feature-teal   { --icon-bg: rgba(20, 184, 166, 0.16);  --icon-fg: #2DD4BF; }
.feature-amber  { --icon-bg: rgba(245, 158, 11, 0.16);  --icon-fg: #FBBF24; }
.feature-indigo { --icon-bg: rgba(99, 102, 241, 0.16);  --icon-fg: #818CF8; }
.feature-red    { --icon-bg: rgba(239, 68, 68, 0.16);   --icon-fg: #F87171; }

/* ----------------------------------------------------------
   Highlighted "split" sections — alternating image/text
   ---------------------------------------------------------- */

.split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}
@media (max-width: 880px) { .split { grid-template-columns: 1fr; gap: 40px; } }
.split-reverse > *:first-child { order: 2; }
@media (max-width: 880px) { .split-reverse > *:first-child { order: 0; } }

.split h2 { margin-bottom: 18px; }
.split p { margin-bottom: 16px; }

.split-card {
    aspect-ratio: 5 / 6;
    border-radius: var(--radius-lg);
    background: linear-gradient(160deg,
        rgba(59, 129, 245, 0.10),
        rgba(250, 115, 23, 0.08));
    border: 1px solid var(--border);
    padding: 28px;
    display: flex;
    flex-direction: column;
    gap: 14px;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
    position: relative;
    overflow: hidden;
}
.split-card::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(400px 200px at 30% 20%,
        rgba(250, 115, 23, 0.18), transparent 60%);
    pointer-events: none;
}

/* "Family Link card" mock — stat tiles */
.stat-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-top: 8px;
}
.stat-tile {
    background: var(--bg-navy);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 14px 10px;
    text-align: center;
}
.stat-tile .icon {
    width: 22px; height: 22px;
    margin: 0 auto 4px;
    color: var(--tile-c, var(--aurora));
}
.stat-tile .v { color: var(--text-1); font-weight: 800; font-size: 16px; }
.stat-tile .l { color: var(--text-3); font-size: 11px; margin-top: 2px; }

/* "Theme picker card" mock */
.theme-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}
.theme-swatch {
    aspect-ratio: 1;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--c1), var(--c2));
    border: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
    cursor: pointer;
    transition: transform 0.15s var(--easing);
}
.theme-swatch:hover { transform: scale(1.06); }
.theme-swatch.selected::after {
    content: "✓";
    position: absolute;
    inset: 0;
    display: flex; align-items: center; justify-content: center;
    color: white;
    font-weight: 800;
    font-size: 18px;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.5);
}

/* ----------------------------------------------------------
   Privacy section
   ---------------------------------------------------------- */

.privacy-callout {
    background:
        radial-gradient(800px 360px at 50% 0%,
            rgba(250, 115, 23, 0.10), transparent 70%),
        var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 60px 40px;
    text-align: center;
    max-width: 900px;
    margin: 0 auto;
}
.privacy-callout h2 { margin-bottom: 14px; }
.privacy-callout p { margin: 0 auto 22px; }

.privacy-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
    margin-top: 26px;
    text-align: left;
}
@media (max-width: 600px) { .privacy-list { grid-template-columns: 1fr; } }
.privacy-row {
    display: flex;
    gap: 12px;
    align-items: flex-start;
}
.privacy-row svg {
    flex-shrink: 0;
    color: var(--ember);
    margin-top: 2px;
}
.privacy-row strong { color: var(--text-1); }

/* ----------------------------------------------------------
   FAQ
   ---------------------------------------------------------- */

.faq-item {
    border-top: 1px solid var(--border);
    padding: 22px 0;
}
.faq-item:last-child { border-bottom: 1px solid var(--border); }
.faq-q {
    color: var(--text-1);
    font-weight: 600;
    font-size: 18px;
    cursor: pointer;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
}
.faq-q::-webkit-details-marker { display: none; }
.faq-q::after {
    content: "+";
    color: var(--text-3);
    font-size: 22px;
    font-weight: 300;
    transition: transform 0.2s var(--easing);
}
details[open] .faq-q::after { transform: rotate(45deg); }
.faq-a {
    margin-top: 12px;
    color: var(--text-3);
}

/* ----------------------------------------------------------
   Footer
   ---------------------------------------------------------- */

footer {
    padding: 60px 24px 30px;
    border-top: 1px solid var(--border);
    background: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 0.4) 100%);
}
.footer-inner {
    max-width: var(--max-width);
    margin: 0 auto;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}
@media (max-width: 760px) {
    .footer-inner { grid-template-columns: 1fr 1fr; gap: 32px; }
}
.footer-brand p {
    color: var(--text-3);
    font-size: 14px;
    margin-top: 12px;
    max-width: 32ch;
}
.footer-col h4 {
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    color: var(--text-3);
    font-weight: 700;
    margin-bottom: 14px;
}
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 10px; }
.footer-col a {
    color: var(--text-2);
    font-size: 14.5px;
}
.footer-col a:hover { color: var(--ember-soft); }

.footer-bottom {
    max-width: var(--max-width);
    margin: 0 auto;
    padding-top: 24px;
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 14px;
    color: var(--text-muted);
    font-size: 13.5px;
}
/* Long-form typography for /privacy, /terms, /support. Reuses
   the design tokens from styles.css; only adds prose-specific
   rules so the marketing palette stays consistent. */

.legal-hero {
    padding: 80px 24px 30px;
    text-align: center;
}
.legal-hero h1 {
    font-size: clamp(36px, 5vw, 56px);
    margin-bottom: 12px;
}
.legal-hero .updated {
    color: var(--text-3);
    font-size: 14px;
    margin-top: 4px;
}

.legal-body {
    max-width: 760px;
    margin: 0 auto;
    padding: 0 24px 100px;
    color: var(--text-2);
    font-size: 17px;
    line-height: 1.7;
}

.legal-body h2 {
    font-size: 26px;
    color: var(--text-1);
    margin: 56px 0 16px;
    padding-top: 12px;
    scroll-margin-top: 80px;
}
.legal-body h2:first-of-type { margin-top: 24px; }
.legal-body h3 {
    font-size: 19px;
    color: var(--text-1);
    margin: 32px 0 10px;
}

.legal-body p { margin-bottom: 16px; max-width: none; }
.legal-body strong { color: var(--text-1); font-weight: 600; }

.legal-body ul, .legal-body ol {
    margin: 0 0 18px 24px;
    padding: 0;
}
.legal-body li {
    margin-bottom: 8px;
    color: var(--text-2);
}
.legal-body li::marker { color: var(--ember); }

.legal-body code {
    font-family: var(--font-mono);
    font-size: 14px;
    background: var(--surface-2);
    padding: 2px 6px;
    border-radius: 5px;
    border: 1px solid var(--border);
    color: var(--ember-soft);
}

.legal-body hr {
    border: none;
    border-top: 1px solid var(--border);
    margin: 50px 0;
}

.legal-body table {
    width: 100%;
    border-collapse: collapse;
    margin: 18px 0;
    font-size: 15px;
}
.legal-body th, .legal-body td {
    border-bottom: 1px solid var(--border);
    padding: 12px 14px;
    text-align: left;
}
.legal-body th {
    background: var(--surface-2);
    color: var(--text-1);
    font-weight: 600;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.6px;
}

.legal-body blockquote {
    border-left: 3px solid var(--ember);
    padding: 6px 18px;
    margin: 18px 0;
    color: var(--text-3);
    font-style: italic;
    background: var(--surface-2);
    border-radius: 4px;
}

/* Table of contents — sticky left rail on wide screens */
.legal-wrap {
    max-width: 1100px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 220px 1fr;
    gap: 60px;
    padding: 0 24px 100px;
}
@media (max-width: 1000px) {
    .legal-wrap { grid-template-columns: 1fr; gap: 0; }
    .legal-toc { display: none; }
}
.legal-toc {
    position: sticky;
    top: 90px;
    align-self: start;
    font-size: 13.5px;
    border-right: 1px solid var(--border);
    padding-right: 18px;
}
.legal-toc h4 {
    color: var(--text-3);
    text-transform: uppercase;
    letter-spacing: 1.2px;
    font-size: 11px;
    margin-bottom: 12px;
}
.legal-toc ol {
    list-style: none;
    margin: 0;
    padding: 0;
}
.legal-toc li {
    padding: 4px 0;
}
.legal-toc a {
    color: var(--text-3);
    font-size: 13.5px;
}
.legal-toc a:hover { color: var(--ember-soft); }

/* "back to home" link */
.back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--text-3);
    font-size: 14px;
    margin-bottom: 24px;
    transition: color 0.15s var(--easing), transform 0.15s var(--easing);
}
.back-link:hover {
    color: var(--ember-soft);
    transform: translateX(-2px);
}
.back-link svg {
    width: 14px !important;
    height: 14px !important;
    max-width: 14px;
    max-height: 14px;
    flex-shrink: 0;
}
