/* ── TuneLab ──────────────────────────────────
   Navy-Violet gradient palette with light/dark
   theme support. Mouse glow, grain overlay,
   particles, sharp grid cards.
   ────────────────────────────────────────────────── */


/* ── Solide BC (logo wordmark) ────────────────── */
@font-face {
    font-family: 'Solide BC';
    src: url('/static/fonts/solide-bc.woff') format('woff');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'Solide BC';
    src: url('/static/fonts/solide-italic-bc.woff') format('woff');
    font-weight: 700;
    font-style: italic;
    font-display: swap;
}

@font-face {
    font-family: 'Ferro BC';
    src: url('/static/fonts/ferro-bc.woff') format('woff');
    font-weight: 700;
    font-style: italic;
    font-display: swap;
}

/* ── Dark theme (default) ─────────────────────── */
:root {
    --bg-deep:       #08081a;
    --bg:            #0e0e24;
    --bg-mid:        #121030;
    --surface:       rgba(16, 14, 38, 0.88);
    --surface-solid: #100e26;
    --border:        rgba(30, 28, 68, 0.7);
    --border-solid:  #1e1c44;
    --border-hover:  rgba(60, 56, 120, 0.5);
    --text:          #e0e2f0;
    --text-dim:      #8a88a8;
    --text-muted:    #7a789a;
    --accent:        #60a0ff;
    --accent-dim:    rgba(96, 160, 255, 0.08);
    --accent-glow:   rgba(96, 160, 255, 0.15);
    --warm:          #e8906a;
    --warm-glow:     rgba(232, 144, 106, 0.3);
    --glow-color:    rgba(100, 80, 200, 0.05);
    --glow-card:     rgba(100, 80, 200, 0.06);
    --grain-opacity: 0.035;
    --grad-a:        rgba(100, 80, 200, 0.04);
    --grad-b:        rgba(96, 160, 255, 0.02);
    --body-font:     'DM Sans', system-ui, -apple-system, sans-serif;
    --heading-font:  'Barlow Condensed', sans-serif;
    --mono-font:     'DM Mono', monospace;
}

/* ── Light theme ──────────────────────────────── */
[data-theme="light"] {
    --bg-deep:       #e8e6f0;
    --bg:            #f8f7fc;
    --bg-mid:        #efedf8;
    --surface:       rgba(255, 255, 255, 0.92);
    --surface-solid: #ffffff;
    --border:        rgba(160, 150, 200, 0.4);
    --border-solid:  #c8c2d8;
    --border-hover:  rgba(140, 130, 190, 0.4);
    --text:          #1a1830;
    --text-dim:      #5a566e;
    --text-muted:    #6a688a;
    --accent:        #4f46e5;
    --accent-dim:    rgba(79, 70, 229, 0.06);
    --accent-glow:   rgba(79, 70, 229, 0.12);
    --warm:          #d06050;
    --warm-glow:     rgba(208, 96, 80, 0.25);
    --glow-color:    rgba(79, 70, 229, 0.03);
    --glow-card:     rgba(79, 70, 229, 0.04);
    --grain-opacity: 0.018;
    --grad-a:        rgba(79, 70, 229, 0.03);
    --grad-b:        rgba(96, 160, 255, 0.02);
}

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

html { scroll-behavior: smooth; }

body {
    font-family: var(--body-font);
    font-weight: 400;
    font-size: 15px;
    background: var(--bg-deep);
    color: var(--text);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    position: relative;
    letter-spacing: 0.01em;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ── grain overlay ────────────────────────────── */
body::after {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 9999;
    pointer-events: none;
    opacity: var(--grain-opacity);
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
    background-size: 180px;
    mix-blend-mode: overlay;
}

/* ── page-wide mouse glow ─────────────────────── */
body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background: radial-gradient(
        600px circle at var(--mouse-x, 50%) var(--mouse-y, 50%),
        var(--glow-color),
        transparent 40%
    );
}

/* ── background gradient ──────────────────────── */
.bg-gradient {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background:
        radial-gradient(ellipse at 30% 0%, var(--grad-a) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 100%, var(--grad-b) 0%, transparent 40%),
        linear-gradient(170deg, var(--bg) 0%, var(--bg-deep) 30%, var(--bg-mid) 70%, var(--bg-deep) 100%);
}

/* ── particles ────────────────────────────────── */
#particles {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
}

.particle {
    position: absolute;
    bottom: -4px;
    width: 1px;
    height: 1px;
    background: var(--text-dim);
    border-radius: 50%;
    opacity: 0;
    animation:
        particleDrift var(--dur, 18s) linear var(--delay, 0s) infinite,
        particleTwinkle var(--twinkle, 4s) ease-in-out var(--delay, 0s) infinite;
}

@keyframes particleDrift {
    0%   { transform: translateY(0) translateX(0); opacity: 0; }
    8%   { opacity: 0.5; }
    88%  { opacity: 0.3; }
    100% { transform: translateY(-105vh) translateX(var(--dx, 20px)); opacity: 0; }
}

@keyframes particleTwinkle {
    0%, 100% { filter: brightness(1); }
    50%      { filter: brightness(2); }
}

[data-theme="light"] .particle { opacity: 0; animation: none; display: none; }
[data-theme="light"] .upload-area {
    border-color: rgba(79, 70, 229, 0.35);
    background: radial-gradient(ellipse at 50% 0%, rgba(79, 70, 229, 0.05) 0%, transparent 70%), var(--surface);
}
[data-theme="light"] .upload-area:hover {
    border-color: rgba(79, 70, 229, 0.55);
    box-shadow: 0 0 30px rgba(79, 70, 229, 0.08), inset 0 1px 0 rgba(79, 70, 229, 0.1);
}
[data-theme="light"] .upload-icon .bar { background: var(--accent); }
[data-theme="light"] .privacy-badge {
    border-color: rgba(22, 163, 74, 0.25);
    background: linear-gradient(135deg, rgba(22, 163, 74, 0.08), rgba(79, 70, 229, 0.03));
    color: var(--text-dim);
    box-shadow: 0 0 12px rgba(22, 163, 74, 0.04);
}
[data-theme="light"] .privacy-badge svg { color: rgba(22, 163, 74, 0.85); }

/* ── light theme depth & polish ──────────────── */
[data-theme="light"] .tool-card {
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04), 0 4px 12px rgba(79, 70, 229, 0.03);
}
[data-theme="light"] .tool-card:hover {
    box-shadow: 0 8px 28px rgba(79, 70, 229, 0.1), 0 2px 8px rgba(0, 0, 0, 0.04);
}
[data-theme="light"] .why-block {
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03), 0 4px 12px rgba(79, 70, 229, 0.03);
}
[data-theme="light"] .faq-item {
    background: rgba(255, 255, 255, 0.6);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
}
[data-theme="light"] .faq-item:hover {
    background: rgba(255, 255, 255, 0.85);
    border-color: rgba(79, 70, 229, 0.2);
    box-shadow: 0 4px 16px rgba(79, 70, 229, 0.06);
}
[data-theme="light"] .faq-section h2 { color: var(--text); }
[data-theme="light"] .related-tool-card {
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04), 0 4px 12px rgba(79, 70, 229, 0.03);
}
[data-theme="light"] .related-tool-card:hover {
    box-shadow: 0 8px 24px rgba(79, 70, 229, 0.1);
}
[data-theme="light"] .category-section h2::before {
    background: var(--accent);
}
[data-theme="light"] .category-header::after {
    background: linear-gradient(90deg, #4f46e5, rgba(124, 59, 237, 0.4), transparent);
}
[data-theme="light"] .step-pill {
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
}
[data-theme="light"] footer::before {
    background: linear-gradient(90deg, transparent, var(--accent), transparent);
    opacity: 0.25;
}

/* ── nav ──────────────────────────────────────── */
nav {
    position: sticky;
    top: 0;
    z-index: 50;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 2rem;
    height: 56px;
    border-bottom: 1px solid var(--border);
    background: rgba(14, 14, 36, 0.72);
    backdrop-filter: blur(18px) saturate(1.5);
    -webkit-backdrop-filter: blur(18px) saturate(1.5);
    transition: background 0.3s, backdrop-filter 0.3s, box-shadow 0.3s;
}
nav::after {
    content: "";
    position: absolute;
    bottom: -1px;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent 5%, var(--accent) 50%, transparent 95%);
    opacity: 0.2;
    pointer-events: none;
}
[data-theme="light"] nav {
    background: rgba(248, 247, 252, 0.82);
}
[data-theme="light"] nav::after {
    opacity: 0.15;
}
nav.nav-scrolled {
    background: rgba(8, 8, 26, 0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(96, 160, 255, 0.1);
}
[data-theme="light"] nav.nav-scrolled {
    background: rgba(255, 255, 255, 0.85);
}

/* ── logo ──────────────────────────────────────── */
nav .logo {
    font-family: 'Ferro BC', 'Solide BC', var(--heading-font);
    font-weight: 700;
    font-style: italic;
    font-size: 2rem;
    background: linear-gradient(
        135deg,
        #60a0ff 0%,
        #a855f7 25%,
        #e040fb 50%,
        #60a0ff 75%,
        #a855f7 100%
    );
    background-size: 300% 300%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradient-shift 6s ease-in-out infinite;
    text-decoration: none;
    letter-spacing: 2.5px;
    text-transform: uppercase;
    transition: filter 0.3s;
    filter: drop-shadow(0 0 8px rgba(96, 160, 255, 0.25));
    animation: gradient-shift 6s ease-in-out infinite, logo-neon-pulse 4s ease-in-out infinite;
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.45rem;
    flex-shrink: 0;
}
nav .logo .logo-mark {
    width: 30px;
    height: 30px;
    object-fit: contain;
    flex-shrink: 0;
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}
nav .logo:hover .logo-mark {
    transform: scale(1.1) rotate(-3deg);
}
nav .logo:hover {
    filter: drop-shadow(0 0 14px rgba(96, 160, 255, 0.5)) drop-shadow(0 0 30px rgba(168, 85, 247, 0.3));
}
[data-theme="light"] nav .logo {
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 25%, #a855f7 50%, #4f46e5 75%, #7c3aed 100%);
    background-size: 300% 300%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradient-shift 6s ease-in-out infinite;
    filter: drop-shadow(0 0 6px rgba(79, 70, 229, 0.2));
}
[data-theme="light"] nav .logo:hover {
    filter: drop-shadow(0 0 12px rgba(79, 70, 229, 0.4)) drop-shadow(0 0 24px rgba(124, 58, 237, 0.25));
}

/* ── nav links ──────────────────────────────────── */
.nav-right { display: flex; align-items: center; gap: 0.2rem; flex-wrap: wrap; }
.nav-right a {
    font-family: var(--mono-font);
    font-weight: 400;
    font-size: 0.72rem;
    color: var(--text-dim);
    text-decoration: none;
    letter-spacing: 0.5px;
    padding: 0.4rem 0.65rem;
    border-radius: 8px;
    border: 1px solid transparent;
    transition: color 0.2s, background 0.2s, border-color 0.2s;
    position: relative;
}
.nav-right > a::after {
    content: "";
    position: absolute;
    bottom: 4px;
    left: 50%;
    width: 0;
    height: 1.5px;
    background: var(--accent);
    border-radius: 1px;
    transition: width 0.25s cubic-bezier(0.33, 1, 0.68, 1), left 0.25s cubic-bezier(0.33, 1, 0.68, 1);
}
.nav-right > a:hover::after {
    width: 60%;
    left: 20%;
}
.nav-right > a.active::after {
    width: 60%;
    left: 20%;
    opacity: 0.6;
}
.nav-right a:hover {
    color: var(--text);
    background: rgba(96, 160, 255, 0.05);
}
.nav-right a.active {
    color: var(--accent);
    background: rgba(96, 160, 255, 0.06);
    border-color: rgba(96, 160, 255, 0.1);
}
[data-theme="light"] .nav-right a:hover {
    background: rgba(79, 70, 229, 0.05);
}
[data-theme="light"] .nav-right a.active {
    background: rgba(79, 70, 229, 0.06);
    border-color: rgba(79, 70, 229, 0.12);
}
.nav-short { display: none; }
@media (max-width: 900px) {
    .nav-full { display: none; }
    .nav-short { display: inline; }
}

/* ── nav dropdown (All Tools) ────────────────── */
.nav-more { position: relative; }
.nav-more-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-family: var(--mono-font);
    font-weight: 500;
    font-size: 0.72rem;
    color: var(--text-dim);
    letter-spacing: 0.5px;
    padding: 0.38rem 0.75rem;
    border-radius: 8px;
    border: 1px solid var(--border);
    background: var(--accent-dim);
    cursor: pointer;
    transition: color 0.25s, background 0.25s, border-color 0.25s, box-shadow 0.25s;
}
.nav-more-btn svg {
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    opacity: 0.6;
}
.nav-more-btn:hover,
.nav-more.open .nav-more-btn {
    color: var(--text);
    background: rgba(96, 160, 255, 0.1);
    border-color: rgba(96, 160, 255, 0.2);
    box-shadow: 0 0 16px rgba(96, 160, 255, 0.06);
}
.nav-more-btn:hover svg,
.nav-more.open .nav-more-btn svg { opacity: 1; }
.nav-more.open .nav-more-btn svg { transform: rotate(180deg); }
[data-theme="light"] .nav-more-btn {
    background: rgba(79, 70, 229, 0.04);
    border-color: rgba(79, 70, 229, 0.15);
}
[data-theme="light"] .nav-more-btn:hover,
[data-theme="light"] .nav-more.open .nav-more-btn {
    background: rgba(79, 70, 229, 0.08);
    border-color: rgba(79, 70, 229, 0.2);
    box-shadow: 0 0 16px rgba(79, 70, 229, 0.06);
}

.nav-dropdown {
    position: absolute;
    top: calc(100% + 0.75rem);
    right: 0;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.25rem 1.2rem;
    min-width: 560px;
    padding: 1.4rem 1.5rem 1.2rem;
    border-radius: 16px;
    border: 1px solid var(--border);
    background: rgba(14, 14, 36, 0.94);
    backdrop-filter: blur(24px) saturate(1.5);
    -webkit-backdrop-filter: blur(24px) saturate(1.5);
    box-shadow:
        0 20px 60px rgba(0, 0, 0, 0.45),
        0 0 0 1px rgba(96, 160, 255, 0.05),
        inset 0 1px 0 rgba(255, 255, 255, 0.03);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px) scale(0.98);
    transform-origin: top right;
    transition: opacity 0.25s cubic-bezier(0.16, 1, 0.3, 1),
                visibility 0.25s,
                transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    z-index: 100;
}
.nav-dropdown::before {
    content: "";
    position: absolute;
    top: -6px;
    right: 24px;
    width: 12px;
    height: 12px;
    background: rgba(14, 14, 36, 0.94);
    border: 1px solid var(--border);
    border-bottom: none;
    border-right: none;
    transform: rotate(45deg);
    z-index: -1;
}
.nav-more.open .nav-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}
[data-theme="light"] .nav-dropdown {
    background: rgba(255, 255, 255, 0.96);
    box-shadow:
        0 20px 60px rgba(0, 0, 0, 0.1),
        0 0 0 1px rgba(79, 70, 229, 0.06),
        inset 0 1px 0 rgba(255, 255, 255, 0.5);
}
[data-theme="light"] .nav-dropdown::before {
    background: rgba(255, 255, 255, 0.96);
}

.nav-dropdown-heading {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-family: var(--heading-font);
    font-weight: 600;
    font-size: 0.62rem;
    text-transform: uppercase;
    letter-spacing: 1.8px;
    color: var(--accent);
    padding: 0 0.5rem 0.5rem;
    margin-bottom: 0.3rem;
    border-bottom: 1px solid var(--border);
}
.nav-dropdown-heading .dd-icon {
    display: inline-flex;
    width: 16px;
    height: 16px;
    align-items: center;
    justify-content: center;
    opacity: 0.7;
    flex-shrink: 0;
}
.nav-dropdown-col { display: flex; flex-direction: column; gap: 0.1rem; }
.nav-dropdown a {
    font-family: var(--mono-font);
    font-size: 0.72rem;
    color: var(--text-dim);
    text-decoration: none;
    padding: 0.4rem 0.5rem;
    border-radius: 6px;
    transition: color 0.15s, background 0.15s, padding-left 0.2s, transform 0.15s;
    white-space: nowrap;
    position: relative;
}
.nav-dropdown a:hover {
    color: var(--text);
    background: rgba(96, 160, 255, 0.08);
    padding-left: 0.65rem;
}
.nav-dropdown a.active {
    color: var(--accent);
    background: rgba(96, 160, 255, 0.06);
}
.nav-dropdown a.active::before {
    content: "";
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 14px;
    border-radius: 2px;
    background: var(--accent);
    opacity: 0.7;
}
[data-theme="light"] .nav-dropdown a:hover {
    background: rgba(79, 70, 229, 0.06);
}
[data-theme="light"] .nav-dropdown a.active {
    background: rgba(79, 70, 229, 0.06);
}

@media (max-width: 768px) {
    .nav-dropdown {
        grid-template-columns: repeat(2, 1fr);
        min-width: 320px;
        right: -1rem;
    }
    .nav-dropdown::before { right: 32px; }
}
@media (max-width: 480px) {
    .nav-more-btn span { display: none; }
    .nav-more-btn svg { margin: 0; }
    .nav-dropdown {
        position: fixed;
        top: 60px;
        right: 0.5rem;
        left: 0.5rem;
        grid-template-columns: 1fr 1fr;
        min-width: 0;
        max-height: calc(100vh - 80px);
        overflow-y: auto;
    }
    .nav-dropdown::before { display: none; }
}

/* ── theme toggle ─────────────────────────────── */
.theme-toggle {
    background: none;
    border: 1px solid var(--border);
    color: var(--text-dim);
    cursor: pointer;
    width: 34px;
    height: 34px;
    padding: 0;
    font-size: 0.9rem;
    line-height: 1;
    transition: color 0.3s, border-color 0.3s, background 0.3s, transform 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    position: relative;
    overflow: hidden;
    flex-shrink: 0;
}
.theme-toggle:hover {
    color: var(--text);
    border-color: var(--border-hover);
    background: var(--accent-dim);
    transform: scale(1.05);
}
.theme-toggle:active {
    transform: scale(0.95);
}
.theme-toggle .icon-sun,
.theme-toggle .icon-moon {
    display: none;
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.3s;
}
:root .theme-toggle .icon-sun { display: inline; }
:root .theme-toggle .icon-moon { display: none; }
[data-theme="light"] .theme-toggle .icon-sun { display: none; }
[data-theme="light"] .theme-toggle .icon-moon { display: inline; }

/* ── main layout (wider for tools) ────────────── */
main {
    position: relative;
    z-index: 1;
    flex: 1;
    max-width: 900px;
    margin: 0 auto;
    padding: 2rem;
    width: 100%;
}

/* ── hero ──────────────────────────────────────── */
/* ── hero section ────────────────────────────── */
.hero {
    text-align: center;
    padding: 4rem 0 2.5rem;
    position: relative;
    overflow: hidden;
    border-radius: 1rem;
}

/* subtle animated mesh gradient behind hero */
.hero::before {
    content: "";
    position: absolute;
    inset: -40% -20%;
    z-index: -1;
    pointer-events: none;
    background:
        radial-gradient(ellipse 600px 400px at 20% 30%, rgba(96, 160, 255, 0.08) 0%, transparent 70%),
        radial-gradient(ellipse 500px 350px at 75% 60%, rgba(140, 80, 255, 0.06) 0%, transparent 70%),
        radial-gradient(ellipse 400px 300px at 50% 10%, rgba(232, 144, 106, 0.04) 0%, transparent 70%);
    animation: heroMeshDrift 12s ease-in-out infinite alternate;
    filter: blur(40px);
}
@keyframes heroMeshDrift {
    0%   { transform: translate(0, 0) scale(1); }
    50%  { transform: translate(-3%, 2%) scale(1.03); }
    100% { transform: translate(2%, -1%) scale(0.98); }
}
[data-theme="light"] .hero::before {
    background:
        radial-gradient(ellipse 600px 400px at 20% 30%, rgba(79, 70, 229, 0.06) 0%, transparent 70%),
        radial-gradient(ellipse 500px 350px at 75% 60%, rgba(140, 80, 255, 0.05) 0%, transparent 70%),
        radial-gradient(ellipse 400px 300px at 50% 10%, rgba(232, 144, 106, 0.03) 0%, transparent 70%);
}

/* ── Hero spotlight — mouse-follow glow ───────── */
.hero-spotlight {
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.4s ease;
    background: radial-gradient(
        400px circle at var(--spot-x, 50%) var(--spot-y, 50%),
        rgba(96, 160, 255, 0.06) 0%,
        transparent 70%
    );
}
[data-theme="light"] .hero-spotlight {
    background: radial-gradient(
        400px circle at var(--spot-x, 50%) var(--spot-y, 50%),
        rgba(79, 70, 229, 0.04) 0%,
        transparent 70%
    );
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-family: var(--mono-font);
    font-weight: 500;
    font-size: 0.62rem;
    letter-spacing: 2.5px;
    text-transform: uppercase;
    color: var(--accent);
    border: 1px solid rgba(96, 160, 255, 0.25);
    padding: 0.45rem 1.2rem;
    margin-bottom: 1.8rem;
    border-radius: 100px;
    background: linear-gradient(135deg, rgba(96, 160, 255, 0.08) 0%, rgba(140, 80, 255, 0.04) 100%);
    box-shadow:
        0 0 16px rgba(96, 160, 255, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
    animation: badgePulse 3s ease-in-out infinite;
}
@keyframes badgePulse {
    0%, 100% { box-shadow: 0 0 16px rgba(96, 160, 255, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.05); }
    50%      { box-shadow: 0 0 24px rgba(96, 160, 255, 0.14), inset 0 1px 0 rgba(255, 255, 255, 0.08); }
}
.hero-badge::before {
    content: "";
    display: inline-block;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 8px var(--accent);
    animation: badgeDot 2s ease-in-out infinite;
}
@keyframes badgeDot {
    0%, 100% { opacity: 0.6; }
    50%      { opacity: 1; }
}
[data-theme="light"] .hero-badge {
    border-color: rgba(79, 70, 229, 0.3);
    background: linear-gradient(135deg, rgba(79, 70, 229, 0.08) 0%, rgba(140, 80, 255, 0.04) 100%);
    box-shadow: 0 0 16px rgba(79, 70, 229, 0.06), inset 0 1px 0 rgba(255, 255, 255, 0.3);
    color: var(--accent);
}

.hero h1 {
    font-family: var(--heading-font);
    font-weight: 700;
    font-size: clamp(2.4rem, 6vw, 4rem);
    line-height: 1.05;
    text-transform: uppercase;
    letter-spacing: -0.5px;
    margin-bottom: 1.2rem;
    background: linear-gradient(
        135deg,
        #e0e2f0 0%,
        #a78bfa 25%,
        #60a0ff 50%,
        #c084fc 75%,
        #e0e2f0 100%
    );
    background-size: 300% 300%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradient-shift 8s ease-in-out infinite;
    text-shadow: none;
}
@keyframes gradient-shift {
    0%   { background-position: 0% 50%; }
    50%  { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}
@keyframes logo-neon-pulse {
    0%, 100% { filter: drop-shadow(0 0 6px rgba(96, 160, 255, 0.2)) drop-shadow(0 0 20px rgba(168, 85, 247, 0.0)); }
    50%      { filter: drop-shadow(0 0 10px rgba(96, 160, 255, 0.4)) drop-shadow(0 0 30px rgba(168, 85, 247, 0.15)); }
}
/* Light theme: slightly richer gradient */
[data-theme="light"] .hero h1 {
    background: linear-gradient(
        135deg,
        #1e1b4b 0%,
        #4f46e5 25%,
        #7c3aed 50%,
        #4f46e5 75%,
        #1e1b4b 100%
    );
    background-size: 300% 300%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradient-shift 8s ease-in-out infinite;
}

.hero .subtitle {
    font-size: 0.95rem;
    font-weight: 300;
    color: var(--text-dim);
    max-width: 520px;
    margin: 0 auto 2.5rem;
    line-height: 1.75;
}

/* ── upload area ──────────────────────────────── */
.upload-area {
    position: relative;
    border: 2px dashed rgba(96, 160, 255, 0.4);
    border-radius: 16px;
    padding: 2.5rem 2rem;
    min-height: 200px;
    background:
        radial-gradient(ellipse at 50% 0%, rgba(96, 160, 255, 0.1) 0%, transparent 70%),
        var(--surface);
    box-shadow: 0 0 0 1px rgba(96, 160, 255, 0.06), inset 0 1px 0 rgba(96, 160, 255, 0.08);
    transition: border-color 0.3s, box-shadow 0.3s;
    overflow: hidden;
    cursor: pointer;
    animation: uploadPulse 3s ease-in-out infinite;
}

.upload-area::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: radial-gradient(
        400px circle at var(--mouse-x, 50%) var(--mouse-y, 50%),
        rgba(96, 160, 255, 0.08),
        transparent 40%
    );
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}
.upload-area:hover::before { opacity: 1; }
.upload-area:hover {
    border-color: rgba(96, 160, 255, 0.5);
    border-style: solid;
    box-shadow: 0 0 30px rgba(96, 160, 255, 0.08), inset 0 1px 0 rgba(96, 160, 255, 0.1);
}
.upload-area.drag-over {
    border-color: var(--accent);
    border-style: solid;
    box-shadow: 0 0 40px rgba(96, 160, 255, 0.15), inset 0 0 40px var(--accent-dim);
}

@keyframes uploadPulse {
    0%, 100% { box-shadow: 0 0 0 rgba(96, 160, 255, 0); }
    50%      { box-shadow: 0 0 20px rgba(96, 160, 255, 0.04); }
}

.upload-prompt {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.8rem;
}
.upload-prompt p {
    color: var(--text-dim);
    font-size: 0.85rem;
    font-family: var(--mono-font);
}

.upload-icon {
    display: flex;
    align-items: center;
    gap: 3px;
    margin-bottom: 0.3rem;
    height: 36px;
}
.upload-icon .bar {
    width: 3px;
    background: var(--accent);
    border-radius: 2px;
    animation: waveBar 1.4s ease-in-out infinite;
    opacity: 0.5;
}
.upload-icon .bar:nth-child(1) { height: 10px; animation-delay: 0.0s; }
.upload-icon .bar:nth-child(2) { height: 20px; animation-delay: 0.15s; }
.upload-icon .bar:nth-child(3) { height: 30px; animation-delay: 0.3s; }
.upload-icon .bar:nth-child(4) { height: 24px; animation-delay: 0.45s; }
.upload-icon .bar:nth-child(5) { height: 14px; animation-delay: 0.6s; }
.upload-icon .bar:nth-child(6) { height: 26px; animation-delay: 0.75s; }
.upload-icon .bar:nth-child(7) { height: 16px; animation-delay: 0.9s; }

@keyframes waveBar {
    0%, 100% { transform: scaleY(0.4); opacity: 0.25; }
    50%      { transform: scaleY(1); opacity: 0.7; }
}

/* ── buttons ──────────────────────────────────── */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-family: var(--heading-font);
    font-weight: 600;
    font-size: 0.85rem;
    padding: 0.65rem 1.6rem;
    border: none;
    cursor: pointer;
    letter-spacing: 1px;
    text-transform: uppercase;
    transition: all 0.2s ease;
    text-decoration: none;
}

.btn-primary {
    background: var(--accent);
    color: var(--bg-deep);
}
.btn-primary:hover {
    filter: brightness(1.15);
    box-shadow: 0 0 24px var(--accent-dim);
}
.btn-primary:active { transform: scale(0.98); }

.btn-secondary {
    background: transparent;
    color: var(--text-dim);
    border: 1px solid var(--border);
}
.btn-secondary:hover {
    color: var(--text);
    border-color: var(--border-hover);
}

/* ── progress spinner ─────────────────────────── */
.hidden { display: none !important; }

.spinner-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}
.spinner {
    width: 32px;
    height: 32px;
    border: 1px solid var(--border);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin 0.9s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.spinner-wrap p {
    color: var(--text-dim);
    font-size: 0.8rem;
    font-family: var(--mono-font);
    letter-spacing: 0.5px;
}

/* ── mode toggle ──────────────────────────────── */
.mode-toggle {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}
.toggle-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    font-size: 0.85rem;
    color: var(--text);
}
.toggle-label input[type="checkbox"] { display: none; }
.toggle-slider {
    position: relative;
    width: 36px;
    height: 20px;
    background: var(--border);
    border-radius: 10px;
    transition: background 0.2s;
}
.toggle-slider::after {
    content: '';
    position: absolute;
    top: 2px; left: 2px;
    width: 16px; height: 16px;
    background: var(--text);
    border-radius: 50%;
    transition: transform 0.2s;
}
.toggle-label input:checked + .toggle-slider {
    background: var(--accent);
}
.toggle-label input:checked + .toggle-slider::after {
    transform: translateX(16px);
}
.toggle-hint {
    font-size: 0.7rem;
    color: var(--text-muted);
}

/* ── progress bar (legacy — still used by tools without renderUI) ─── */
.progress-bar {
    width: 100%;
    max-width: 320px;
    height: 6px;
    background: var(--border);
    border-radius: 3px;
    overflow: hidden;
}
.progress-fill {
    height: 100%;
    width: 0%;
    background: var(--accent);
    border-radius: 3px;
    transition: width 0.3s ease-out;
}
.progress-wrap p {
    color: var(--text-dim);
    font-size: 0.8rem;
    font-family: var(--mono-font);
    letter-spacing: 0.5px;
}

/* ── Progress UI (waveform + step dots + messages) ────────── */
.progress-wrap {
    display:flex;flex-direction:column;align-items:center;gap:0.5rem;width:100%;padding:0 1rem;min-height:60px;
}
.progress-waveform {
    display:flex;justify-content:center;gap:3px;height:36px;align-items:end;
}
.wbar {
    width:4px;border-radius:2px;height:40%;
    background:linear-gradient(to top,var(--accent),var(--accent-violet,#a78bfa));
    animation:wbar-wave 0.7s ease-in-out var(--d,0s) infinite alternate;
}
.wbar.frozen { animation:none; height:60%; opacity:0.5; }
@keyframes wbar-wave { from{height:25%} to{height:100%} }

.progress-step-label {
    font-size:1rem;color:var(--text-primary,#fff);font-weight:500;
}
.progress-fun-msg {
    height:1.2rem;overflow:hidden;
}
.progress-fun-msg span {
    display:block;font-size:0.72rem;color:var(--accent-violet,#a78bfa);font-style:italic;
    transition:opacity 0.4s,transform 0.4s;
}
.progress-eta {
    font-size:0.85rem;color:var(--accent);font-family:var(--mono-font);
}
.progress-dots-track {
    position:relative;width:100%;max-width:340px;margin:0 auto;
}
.progress-dots-bar {
    height:5px;background:var(--border);border-radius:3px;overflow:hidden;
}
.progress-dots-fill {
    height:100%;width:0%;border-radius:3px;transition:width 0.5s ease-out;
    background:linear-gradient(90deg,var(--accent),var(--accent-violet,#a78bfa));
}
.progress-dot {
    position:absolute;top:-5px;width:14px;height:14px;border-radius:50%;
    border:2px solid var(--bg-deep,#0d0d2b);background:var(--border);
    transform:translateX(-50%);transition:background 0.4s,box-shadow 0.4s;
}
.progress-dot.done { background:var(--accent); }
.progress-dot.active { background:var(--accent-violet,#a78bfa); animation:dot-pulse 1.5s ease-in-out infinite; }
@keyframes dot-pulse {
    0%,100%{box-shadow:0 0 0 0 rgba(167,139,250,0.4)}
    50%{box-shadow:0 0 0 6px rgba(167,139,250,0)}
}
.progress-dot-labels {
    display:flex;justify-content:space-between;margin-top:0.6rem;font-size:0.55rem;color:var(--text-muted);
}
.progress-dot-labels span.done { color:var(--accent); }
.progress-dot-labels span.done::after { content:' \2713'; }
.progress-dot-labels span.active { color:var(--accent-violet,#a78bfa);font-weight:600; }

/* Light theme overrides */
[data-theme="light"] .wbar {
    background:linear-gradient(to top,var(--accent),#7c3aed);
}
[data-theme="light"] .progress-dot {
    border-color:var(--bg-surface,#f4f0ff);
}
[data-theme="light"] .progress-dots-bar {
    background:#e0d4f5;
}

/* ── result card ──────────────────────────────── */
.result {
    margin-top: 1.5rem;
    padding: 1.5rem;
    background: var(--surface);
    border: 1px solid var(--border);
    animation: result-in 0.3s ease-out;
    contain: content;
}
@keyframes result-in {
    from { opacity: 0; transform: translateY(6px); }
    to   { opacity: 1; transform: translateY(0); }
}
.result.match { border-left: 2px solid var(--accent); }
.result.no-match { border-left: 2px solid var(--warm); }
.result h2 {
    font-family: var(--heading-font);
    font-weight: 600;
    font-size: 1.2rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.5rem;
}
.result .track-info {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    margin-bottom: 0.6rem;
}
.result .track-info span {
    color: var(--text-dim);
    font-size: 0.82rem;
}
.result .meta {
    color: var(--text-muted);
    font-size: 0.72rem;
    font-family: var(--mono-font);
    padding-top: 0.5rem;
    border-top: 1px solid var(--border);
}

/* ── tool grid (home page) ────────────────────── */
.features h2 {
    font-family: var(--mono-font);
    font-size: 0.65rem;
    font-weight: 400;
    text-align: center;
    color: var(--text-dim);
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-bottom: 1.5rem;
}

.tool-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 14px;
}

/* ── Trust strip ─────────────────────────────── */
/* ── trust strip ────────────────────────────── */
.trust-strip {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.5rem 0.6rem;
    padding: 1rem 1.5rem;
    margin-bottom: 2.5rem;
    font-family: var(--mono-font);
    font-size: 0.6rem;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    color: var(--text-muted);
}
.trust-strip span {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.35rem 0.8rem;
    border-radius: 100px;
    background: rgba(96, 160, 255, 0.04);
    border: 1px solid rgba(96, 160, 255, 0.1);
    transition: background 0.3s, border-color 0.3s, color 0.3s, box-shadow 0.3s;
}
.trust-strip span:hover {
    background: rgba(96, 160, 255, 0.08);
    border-color: rgba(96, 160, 255, 0.18);
    color: var(--text-dim);
    box-shadow: 0 0 12px rgba(96, 160, 255, 0.06);
}
[data-theme="light"] .trust-strip span {
    background: rgba(79, 70, 229, 0.03);
    border-color: rgba(79, 70, 229, 0.1);
}
[data-theme="light"] .trust-strip span:hover {
    background: rgba(79, 70, 229, 0.07);
    border-color: rgba(79, 70, 229, 0.18);
    box-shadow: 0 0 12px rgba(79, 70, 229, 0.05);
}
.trust-strip span::before {
    content: "\2713";
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: rgba(96, 160, 255, 0.12);
    color: var(--accent);
    font-size: 0.5rem;
    font-weight: 700;
    flex-shrink: 0;
    line-height: 1;
}
[data-theme="light"] .trust-strip span::before {
    background: rgba(79, 70, 229, 0.1);
}

/* ── Featured grid (3 large cards) ───────────── */
.featured-section {
    margin-bottom: 3rem;
    position: relative;
}
.featured-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}
.featured-card {
    padding: 2.2rem 1.8rem;
    border: 1px solid rgba(96, 160, 255, 0.12);
    border-left: none;
    background: rgba(14, 14, 42, 0.5);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-radius: 16px;
    position: relative;
    overflow: hidden;
    box-shadow:
        0 4px 24px rgba(0, 0, 0, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
    transition: transform 0.25s ease, background 0.3s ease, box-shadow 0.35s ease, border-color 0.3s ease;
}
/* gradient top edge accent */
.featured-card::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--accent), rgba(140, 80, 255, 0.7), var(--accent));
    opacity: 0.6;
    transition: opacity 0.3s;
}
.featured-card:hover::after { opacity: 1; }

.featured-card .tool-icon {
    width: 72px;
    height: 72px;
    margin: 0 auto 1.2rem;
    filter: drop-shadow(0 4px 16px rgba(96, 160, 255, 0.25));
    transition: transform 0.35s ease, filter 0.35s ease;
}
.featured-card:hover .tool-icon {
    transform: translateY(-4px) scale(1.05);
    filter: drop-shadow(0 8px 24px rgba(96, 160, 255, 0.35));
}
.featured-card h3 { font-size: 1.08rem; }
.featured-card p { font-size: 0.85rem; }
.featured-card:hover {
    background: rgba(14, 14, 42, 0.6);
    border-color: rgba(96, 160, 255, 0.2);
    box-shadow:
        0 8px 40px rgba(0, 0, 0, 0.3),
        0 0 20px rgba(96, 160, 255, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.08);
    transform: translateY(-2px);
}
[data-theme="light"] .featured-card {
    background: rgba(255, 255, 255, 0.6);
    border-color: rgba(79, 70, 229, 0.1);
    box-shadow:
        0 4px 24px rgba(0, 0, 0, 0.06),
        inset 0 1px 0 rgba(255, 255, 255, 0.8);
}
[data-theme="light"] .featured-card::after {
    background: linear-gradient(90deg, var(--accent), #7c3aed, var(--accent));
}
[data-theme="light"] .featured-card:hover {
    background: rgba(255, 255, 255, 0.75);
    border-color: rgba(79, 70, 229, 0.2);
    box-shadow:
        0 8px 40px rgba(0, 0, 0, 0.08),
        0 0 20px rgba(79, 70, 229, 0.06),
        inset 0 1px 0 rgba(255, 255, 255, 0.9);
}
[data-theme="light"] .featured-card:hover .tool-icon {
    filter: drop-shadow(0 8px 24px rgba(79, 70, 229, 0.2));
}

/* featured label ("Most Popular") */
.featured-label {
    display: inline-block;
    font-family: var(--mono-font);
    font-weight: 500;
    font-size: 0.55rem;
    letter-spacing: 2.5px;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 0.8rem;
    padding: 0.25rem 0.8rem;
    border-radius: 4px;
    background: rgba(96, 160, 255, 0.04);
    border: 1px solid rgba(96, 160, 255, 0.08);
}
[data-theme="light"] .featured-label {
    background: rgba(79, 70, 229, 0.03);
    border-color: rgba(79, 70, 229, 0.08);
}

/* icon wrapper with ambient glow ring */
.featured-icon-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 88px;
    height: 88px;
    margin: 0 auto 1rem;
    border-radius: 20px;
    background: radial-gradient(circle, rgba(96, 160, 255, 0.06) 0%, transparent 70%);
    border: 1px solid rgba(96, 160, 255, 0.08);
    transition: border-color 0.3s, box-shadow 0.3s, background 0.3s;
    position: relative;
}
.featured-icon-wrap .tool-icon {
    margin: 0;
}
.featured-card:hover .featured-icon-wrap {
    border-color: rgba(96, 160, 255, 0.18);
    box-shadow: 0 0 24px rgba(96, 160, 255, 0.1);
    background: radial-gradient(circle, rgba(96, 160, 255, 0.1) 0%, transparent 70%);
}
[data-theme="light"] .featured-icon-wrap {
    background: radial-gradient(circle, rgba(79, 70, 229, 0.04) 0%, transparent 70%);
    border-color: rgba(79, 70, 229, 0.08);
}
[data-theme="light"] .featured-card:hover .featured-icon-wrap {
    border-color: rgba(79, 70, 229, 0.18);
    box-shadow: 0 0 24px rgba(79, 70, 229, 0.08);
    background: radial-gradient(circle, rgba(79, 70, 229, 0.08) 0%, transparent 70%);
}

/* ── Stats strip ────────────────────────────── */
.stats-strip {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 0;
    padding: 0;
    margin-bottom: 3rem;
    font-family: var(--mono-font);
    font-size: 0.6rem;
    font-weight: 500;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--accent);
    border: 1px solid rgba(96, 160, 255, 0.12);
    border-radius: 14px;
    background:
        linear-gradient(90deg, rgba(96, 160, 255, 0.04), rgba(140, 80, 255, 0.03), rgba(96, 160, 255, 0.04)),
        rgba(14, 14, 36, 0.6);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    overflow: hidden;
    position: relative;
}
/* animated gradient shimmer */
.stats-strip::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(96, 160, 255, 0.06) 25%,
        rgba(140, 80, 255, 0.04) 50%,
        rgba(96, 160, 255, 0.06) 75%,
        transparent 100%
    );
    background-size: 200% 100%;
    animation: statsShimmer 6s ease-in-out infinite;
    pointer-events: none;
}
@keyframes statsShimmer {
    0%   { background-position: -100% 0; }
    100% { background-position: 200% 0; }
}
.stats-strip span {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 1.6rem;
    position: relative;
    transition: background 0.3s;
    flex: 1 1 auto;
    text-align: center;
    white-space: nowrap;
}
.stats-strip span:hover {
    background: rgba(96, 160, 255, 0.06);
}
/* vertical dividers between stats */
.stats-strip span + span::before {
    content: "";
    position: absolute;
    left: 0;
    top: 25%;
    bottom: 25%;
    width: 1px;
    background: rgba(96, 160, 255, 0.15);
}
[data-theme="light"] .stats-strip {
    border-color: rgba(79, 70, 229, 0.12);
    background:
        linear-gradient(90deg, rgba(79, 70, 229, 0.03), rgba(140, 80, 255, 0.02), rgba(79, 70, 229, 0.03)),
        rgba(255, 255, 255, 0.6);
}
[data-theme="light"] .stats-strip::before {
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(79, 70, 229, 0.04) 25%,
        rgba(140, 80, 255, 0.03) 50%,
        rgba(79, 70, 229, 0.04) 75%,
        transparent 100%
    );
    background-size: 200% 100%;
}
[data-theme="light"] .stats-strip span:hover {
    background: rgba(79, 70, 229, 0.04);
}
[data-theme="light"] .stats-strip span + span::before {
    background: rgba(79, 70, 229, 0.12);
}

/* ── Why section ────────────────────────────── */
.why-section {
    margin-bottom: 3.5rem;
    text-align: center;
    position: relative;
    padding-top: 1rem;
}
/* subtle top divider */
.why-section::before {
    content: "";
    position: absolute;
    top: 0;
    left: 10%;
    right: 10%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(96, 160, 255, 0.15), transparent);
}
[data-theme="light"] .why-section::before {
    background: linear-gradient(90deg, transparent, rgba(79, 70, 229, 0.12), transparent);
}
.why-section h2 {
    font-family: var(--heading-font);
    font-weight: 600;
    font-size: 1.2rem;
    color: var(--text);
    margin-bottom: 0.5rem;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}
.why-intro {
    font-size: 0.84rem;
    color: var(--text-dim);
    margin-bottom: 2rem;
    max-width: 480px;
    margin-left: auto;
    margin-right: auto;
}
.why-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
    text-align: left;
}
.why-block {
    padding: 1.6rem;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 14px;
    transition: border-color 0.3s, transform 0.3s ease, box-shadow 0.3s;
    position: relative;
}
.why-block:hover {
    border-color: rgba(96, 160, 255, 0.2);
    transform: translateY(-4px);
    box-shadow:
        0 12px 36px rgba(96, 160, 255, 0.08),
        0 0 0 1px rgba(96, 160, 255, 0.04);
}
[data-theme="light"] .why-block:hover {
    border-color: rgba(79, 70, 229, 0.2);
    box-shadow:
        0 12px 36px rgba(79, 70, 229, 0.08),
        0 0 0 1px rgba(79, 70, 229, 0.04);
}
.why-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(96, 160, 255, 0.1), rgba(140, 80, 255, 0.06));
    border: 1px solid rgba(96, 160, 255, 0.15);
    font-size: 1.15rem;
    margin-bottom: 1rem;
    transition: transform 0.3s, box-shadow 0.3s;
}
.why-block:hover .why-icon {
    transform: scale(1.08);
    box-shadow: 0 4px 16px rgba(96, 160, 255, 0.12);
}
[data-theme="light"] .why-icon {
    background: linear-gradient(135deg, rgba(79, 70, 229, 0.08), rgba(140, 80, 255, 0.04));
    border-color: rgba(79, 70, 229, 0.15);
}
[data-theme="light"] .why-block:hover .why-icon {
    box-shadow: 0 4px 16px rgba(79, 70, 229, 0.1);
}
.why-block h3 {
    font-family: var(--heading-font);
    font-weight: 600;
    font-size: 0.88rem;
    color: var(--text);
    margin-bottom: 0.5rem;
    letter-spacing: 0.3px;
}
.why-block p {
    font-size: 0.78rem;
    color: var(--text-dim);
    line-height: 1.6;
}

/* ── Category sections ───────────────────────── */
.category-section {
    margin-bottom: 3.5rem;
    position: relative;
}
.category-header {
    display: flex;
    align-items: baseline;
    gap: 1rem;
    margin-bottom: 0.6rem;
    position: relative;
}
.category-header::after {
    content: "";
    flex: 1;
    height: 2px;
    background: linear-gradient(90deg, var(--accent), rgba(168, 85, 247, 0.5), transparent);
    position: relative;
    top: -2px;
    transform-origin: left;
}
.category-section h2 {
    font-family: var(--heading-font);
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: var(--text);
    margin-bottom: 0;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 0.6rem;
}
.category-section h2::before {
    content: "";
    display: inline-block;
    width: 3px;
    height: 18px;
    background: var(--accent);
    border-radius: 2px;
    flex-shrink: 0;
}
.category-count {
    font-family: var(--mono-font);
    font-size: 0.6rem;
    font-weight: 400;
    letter-spacing: 0.5px;
    color: var(--text-muted);
    background: var(--accent-dim);
    border: 1px solid rgba(96, 160, 255, 0.1);
    padding: 0.15rem 0.5rem;
    border-radius: 20px;
    white-space: nowrap;
}
[data-theme="light"] .category-count {
    border-color: rgba(79, 70, 229, 0.12);
}
.category-intro {
    font-size: 0.82rem;
    color: var(--text-dim);
    margin-bottom: 1.2rem;
    padding-left: 0;
    line-height: 1.65;
    max-width: 540px;
}

/* ── Tool cards ──────────────────────────────── */
.tool-card {
    position: relative;
    overflow: hidden;
    padding: 1.6rem 1.4rem 1.4rem;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 14px;
    transition: background 0.3s, border-color 0.3s, transform 0.3s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.3s;
    color: var(--text);
    display: flex;
    flex-direction: column;
    align-items: center;
}
/* icon background glow — sits behind icon */
.tool-card .tool-icon-wrap {
    position: relative;
    margin-bottom: 0.8rem;
}
.tool-card .tool-icon-wrap::before {
    content: "";
    position: absolute;
    inset: -8px;
    border-radius: 50%;
    background: radial-gradient(circle, var(--accent-dim) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.35s ease;
    pointer-events: none;
}
.tool-card:hover .tool-icon-wrap::before {
    opacity: 1;
}
/* mouse-follow glow overlay */
.tool-card::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(
        300px circle at var(--mouse-x, 50%) var(--mouse-y, 50%),
        var(--glow-card),
        transparent 40%
    );
    opacity: 0;
    transition: opacity 0.25s ease;
    pointer-events: none;
    border-radius: inherit;
}
/* top accent line on hover */
.tool-card .tool-icon-wrap::after {
    content: "";
    position: absolute;
    top: -1.6rem;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--accent), transparent);
    border-radius: 1px;
    transition: width 0.4s cubic-bezier(0.22, 1, 0.36, 1);
    pointer-events: none;
}
.tool-card:hover .tool-icon-wrap::after {
    width: 40px;
}
/* Full-card click area via ::after on the anchor */
.tool-card h3 a {
    color: inherit;
    text-decoration: none;
}
.tool-card h3 a::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
}
.tool-card:hover::before { opacity: 1; }
.tool-card:hover {
    background: var(--bg-mid);
    border-color: var(--border-hover);
    transform: translateY(-4px);
    box-shadow:
        0 12px 40px rgba(96, 160, 255, 0.1),
        0 4px 16px rgba(96, 160, 255, 0.06),
        0 0 0 1px rgba(96, 160, 255, 0.08);
}
[data-theme="light"] .tool-card:hover {
    box-shadow:
        0 12px 40px rgba(79, 70, 229, 0.1),
        0 4px 16px rgba(79, 70, 229, 0.04),
        0 0 0 1px rgba(79, 70, 229, 0.08);
}
/* ── Category-colored card hover glow ────────── */
/* 1. Tempo & Rhythm — blue */
.category-section:nth-child(1 of .category-section) .tool-card:hover {
    box-shadow: 0 8px 30px rgba(96,160,255,.15), 0 0 0 1px rgba(96,160,255,.1);
    border-color: rgba(96,160,255,.25);
}
/* 2. Pitch & Harmony — violet */
.category-section:nth-child(2 of .category-section) .tool-card:hover {
    box-shadow: 0 8px 30px rgba(168,85,247,.15), 0 0 0 1px rgba(168,85,247,.1);
    border-color: rgba(168,85,247,.25);
}
/* 3. Stems & Separation — green */
.category-section:nth-child(3 of .category-section) .tool-card:hover {
    box-shadow: 0 8px 30px rgba(52,211,153,.15), 0 0 0 1px rgba(52,211,153,.1);
    border-color: rgba(52,211,153,.25);
}
/* 4. Edit & Analyze — orange */
.category-section:nth-child(4 of .category-section) .tool-card:hover {
    box-shadow: 0 8px 30px rgba(232,144,106,.15), 0 0 0 1px rgba(232,144,106,.1);
    border-color: rgba(232,144,106,.25);
}
/* Light theme — stronger category glow */
[data-theme="light"] .category-section:nth-child(1 of .category-section) .tool-card:hover {
    box-shadow: 0 8px 30px rgba(96,160,255,.2), 0 0 0 1px rgba(96,160,255,.12);
    border-color: rgba(96,160,255,.3);
}
[data-theme="light"] .category-section:nth-child(2 of .category-section) .tool-card:hover {
    box-shadow: 0 8px 30px rgba(168,85,247,.2), 0 0 0 1px rgba(168,85,247,.12);
    border-color: rgba(168,85,247,.3);
}
[data-theme="light"] .category-section:nth-child(3 of .category-section) .tool-card:hover {
    box-shadow: 0 8px 30px rgba(52,211,153,.2), 0 0 0 1px rgba(52,211,153,.12);
    border-color: rgba(52,211,153,.3);
}
[data-theme="light"] .category-section:nth-child(4 of .category-section) .tool-card:hover {
    box-shadow: 0 8px 30px rgba(232,144,106,.2), 0 0 0 1px rgba(232,144,106,.12);
    border-color: rgba(232,144,106,.3);
}

.tool-card:hover h3 a { color: var(--accent); }

.tool-icon {
    display: block;
    width: 48px;
    height: 48px;
    border-radius: 10px;
    filter: drop-shadow(0 2px 8px rgba(96, 160, 255, 0.15));
    transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1), filter 0.3s;
}
.tool-card:hover .tool-icon {
    transform: scale(1.08);
    filter: drop-shadow(0 4px 16px rgba(96, 160, 255, 0.3));
}
[data-theme="light"] .tool-card:hover .tool-icon {
    filter: drop-shadow(0 4px 16px rgba(79, 70, 229, 0.2));
}

/* tool type badge */
.tool-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    font-family: var(--mono-font);
    font-size: 0.55rem;
    font-weight: 500;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    padding: 0.2rem 0.55rem;
    border-radius: 20px;
    margin-bottom: 0.4rem;
    white-space: nowrap;
}
.tool-badge--ai {
    color: #a78bfa;
    background: rgba(167, 139, 250, 0.1);
    border: 1px solid rgba(167, 139, 250, 0.15);
}
.tool-badge--realtime {
    color: #34d399;
    background: rgba(52, 211, 153, 0.08);
    border: 1px solid rgba(52, 211, 153, 0.15);
}
.tool-badge--browser {
    color: var(--accent);
    background: var(--accent-dim);
    border: 1px solid rgba(96, 160, 255, 0.12);
}
[data-theme="light"] .tool-badge--ai {
    color: #7c3aed;
    background: rgba(124, 58, 237, 0.08);
    border-color: rgba(124, 58, 237, 0.15);
}
[data-theme="light"] .tool-badge--realtime {
    color: #059669;
    background: rgba(5, 150, 105, 0.08);
    border-color: rgba(5, 150, 105, 0.15);
}
[data-theme="light"] .tool-badge--browser {
    color: var(--accent);
    background: rgba(79, 70, 229, 0.06);
    border-color: rgba(79, 70, 229, 0.12);
}

.tool-card h3 {
    font-family: var(--heading-font);
    font-weight: 600;
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.4rem;
    text-align: center;
    transition: color 0.2s;
}
.tool-card p {
    font-size: 0.8rem;
    font-weight: 300;
    color: var(--text-dim);
    line-height: 1.65;
    text-align: center;
}

/* ── Tool grid staggered entrance ────────────── */
.tool-grid {
    counter-reset: card;
}
.tool-card {
    counter-increment: card;
}

/* ── entrance animations ────────────────────── */
@keyframes fadeUp {
    from { opacity: 0; transform: translateY(16px); }
    to   { opacity: 1; transform: translateY(0); }
}
.hero { animation: fadeUp 0.5s ease-out both; }
.trust-strip { animation: fadeUp 0.5s ease-out 0.1s both; }
.featured-section { animation: fadeUp 0.5s ease-out 0.15s both; }
.featured-card:nth-child(1) { animation: fadeUp 0.4s ease-out 0.2s both; }
.featured-card:nth-child(2) { animation: fadeUp 0.4s ease-out 0.3s both; }
.featured-card:nth-child(3) { animation: fadeUp 0.4s ease-out 0.4s both; }
.stats-strip { animation: fadeUp 0.4s ease-out 0.45s both; }
.why-section { animation: fadeUp 0.5s ease-out 0.5s both; }

/* ── scroll-triggered reveals (progressive enhancement) ── */
@supports (animation-timeline: view()) {
    @keyframes scrollReveal {
        from { opacity: 0; transform: translateY(24px); }
        to   { opacity: 1; transform: translateY(0); }
    }
    @keyframes scrollRevealCard {
        from { opacity: 0; transform: translateY(20px) scale(0.97); }
        to   { opacity: 1; transform: translateY(0) scale(1); }
    }
    .category-section,
    .faq-section,
    .related-tools {
        animation: scrollReveal linear both;
        animation-timeline: view();
        animation-range: entry 0% entry 30%;
    }
    .category-section .tool-card {
        animation: scrollRevealCard linear both;
        animation-timeline: view();
        animation-range: entry 0% entry 25%;
    }
    /* staggered delays for cards within each grid */
    .category-section .tool-card:nth-child(2) { animation-range: entry 2% entry 27%; }
    .category-section .tool-card:nth-child(3) { animation-range: entry 4% entry 29%; }
    .category-section .tool-card:nth-child(4) { animation-range: entry 6% entry 31%; }
    .category-section .tool-card:nth-child(5) { animation-range: entry 8% entry 33%; }
    .category-section .tool-card:nth-child(6) { animation-range: entry 10% entry 35%; }

    /* ── Staggered card entrance ──────────────────── */
    .tool-card:nth-child(1) { animation-delay: 0s; }
    .tool-card:nth-child(2) { animation-delay: 0.06s; }
    .tool-card:nth-child(3) { animation-delay: 0.12s; }
    .tool-card:nth-child(4) { animation-delay: 0.18s; }
    .tool-card:nth-child(5) { animation-delay: 0.24s; }
    .tool-card:nth-child(6) { animation-delay: 0.3s; }

    /* ── Animated category divider — draws in on scroll ── */
    @keyframes dividerDraw {
        from { transform: scaleX(0); }
        to   { transform: scaleX(1); }
    }
    .category-header::after {
        transform: scaleX(0);
        animation: dividerDraw 1s cubic-bezier(0.22, 1, 0.36, 1) both;
        animation-timeline: view();
        animation-range: entry 0% entry 40%;
    }
}

/* ── metronome ────────────────────────────────── */
.metronome-wrap {
    max-width: 500px;
    margin: 0 auto;
    text-align: center;
}

.metronome-display {
    margin-bottom: 1.5rem;
}

.bpm-display {
    font-family: var(--heading-font);
    font-weight: 700;
    font-size: 5rem;
    line-height: 1;
    color: var(--text);
}
.bpm-label {
    font-family: var(--mono-font);
    font-size: 0.7rem;
    color: var(--text-secondary);
    letter-spacing: 3px;
    text-transform: uppercase;
}

.beat-dots {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2rem;
}

.beat-dot {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 1.5px solid var(--border-hover);
    background: rgba(96, 160, 255, 0.06);
    transition: background 0.08s, box-shadow 0.08s, transform 0.08s;
}
.beat-dot.active { transform: scale(1.15); }
.beat-dot.active {
    background: var(--accent);
    box-shadow: 0 0 12px var(--accent-glow);
}
.beat-dot.accent.active {
    background: var(--warm);
    box-shadow: 0 0 12px var(--warm-glow);
}

.bpm-slider {
    width: 100%;
    margin-bottom: 1.5rem;
    accent-color: var(--accent);
}

.metronome-row {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.metronome-play {
    min-width: 100px;
}
.metronome-play.playing {
    background: var(--warm);
}

.metronome-label {
    font-family: var(--mono-font);
    font-size: 0.7rem;
    color: var(--text-secondary);
    letter-spacing: 0.5px;
}

.metronome-select {
    background: var(--surface-solid);
    border: 1px solid var(--border);
    color: var(--text);
    font-family: var(--mono-font);
    font-size: 0.8rem;
    padding: 0.4rem 0.8rem;
    cursor: pointer;
}

/* ── tap BPM ──────────────────────────────────── */
.tap-wrap {
    max-width: 400px;
    margin: 0 auto;
    text-align: center;
}

.tap-display {
    margin-bottom: 0.5rem;
}

.tap-bpm {
    font-family: var(--heading-font);
    font-weight: 700;
    font-size: 6rem;
    line-height: 1;
    color: var(--text);
}
.tap-label {
    font-family: var(--mono-font);
    font-size: 0.7rem;
    color: var(--text-muted);
    letter-spacing: 3px;
    text-transform: uppercase;
}

.tap-stability {
    font-family: var(--mono-font);
    font-size: 0.75rem;
    letter-spacing: 0.5px;
    margin-bottom: 1.5rem;
    min-height: 1.2em;
}
.tap-stability.stable { color: var(--accent); }
.tap-stability.moderate { color: var(--warm); }
.tap-stability.unstable { color: var(--text-dim); }

.tap-area {
    width: 100%;
    padding: 4rem 3rem;
    font-family: var(--heading-font);
    font-weight: 700;
    font-size: 1.8rem;
    letter-spacing: 4px;
    text-transform: uppercase;
    background: linear-gradient(135deg, var(--surface) 0%, var(--surface-solid) 100%);
    border: 2px solid var(--border-hover);
    color: var(--text);
    cursor: pointer;
    transition: all 0.1s ease;
    user-select: none;
    -webkit-user-select: none;
    -webkit-tap-highlight-color: transparent;
    position: relative;
}
.tap-area::after {
    content: "press any key or click";
    display: block;
    font-family: var(--mono-font);
    font-weight: 400;
    font-size: 0.65rem;
    letter-spacing: 1px;
    color: var(--text-dim);
    margin-top: 0.8rem;
}
.tap-area:hover {
    border-color: var(--accent);
    box-shadow: 0 0 30px var(--accent-dim);
}
.tap-area:active, .tap-area.tapped {
    background: var(--accent-dim);
    border-color: var(--accent);
    transform: scale(0.97);
    box-shadow: 0 0 40px var(--accent-glow);
}

.tap-actions {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 1.5rem;
}

.tap-info {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-top: 1rem;
    font-family: var(--mono-font);
    font-size: 0.7rem;
    color: var(--text-muted);
}

/* ── Camelot wheel ────────────────────────────── */
.camelot-wrap {
    display: flex;
    gap: 2rem;
    align-items: flex-start;
    justify-content: center;
    flex-wrap: wrap;
}

.camelot-svg-container {
    width: 360px;
    max-width: 100%;
}

#camelot-svg {
    width: 100%;
    height: auto;
}

.camelot-info {
    flex: 1;
    min-width: 200px;
    max-width: 300px;
}

.camelot-hint {
    color: var(--text-muted);
    font-family: var(--mono-font);
    font-size: 0.8rem;
}

.camelot-selected {
    margin-bottom: 1rem;
}

.camelot-code {
    font-family: var(--heading-font);
    font-weight: 700;
    font-size: 3rem;
    color: var(--text);
    line-height: 1;
}

.camelot-key {
    font-family: var(--mono-font);
    font-size: 0.85rem;
    color: var(--text-dim);
    margin-top: 0.3rem;
}

.camelot-compat {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    align-items: center;
}

.compat-label {
    font-family: var(--mono-font);
    font-size: 0.7rem;
    color: var(--text-muted);
    letter-spacing: 0.5px;
    margin-right: 0.3rem;
}

.compat-tag {
    display: inline-block;
    font-family: var(--mono-font);
    font-size: 0.72rem;
    padding: 0.2rem 0.6rem;
    border: 1px solid var(--border);
    color: var(--accent);
    letter-spacing: 0.3px;
}

.key-compat {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    align-items: center;
    margin-top: 0.5rem;
    margin-bottom: 0.5rem;
}

/* ── pitch detector / tuner ──────────────────── */
.tuner-wrap {
    max-width: 400px;
    margin: 0 auto;
    text-align: center;
}

.tuner-gauge {
    margin-bottom: 2rem;
}

.tuner-cents-bar {
    position: relative;
    height: 8px;
    background: var(--surface);
    border: 1px solid var(--border);
    margin-bottom: 0.5rem;
}

.tuner-cents-center {
    position: absolute;
    left: 50%;
    top: -2px;
    width: 2px;
    height: 12px;
    background: var(--text-muted);
    transform: translateX(-50%);
}

.tuner-cents-indicator {
    position: absolute;
    left: 50%;
    top: -3px;
    width: 10px;
    height: 14px;
    background: var(--accent);
    border-radius: 2px;
    transform: translateX(-50%);
    transition: left 0.1s ease;
}
.tuner-cents-indicator.in-tune {
    background: #4ade80;
    box-shadow: 0 0 12px rgba(74, 222, 128, 0.4);
}

.tuner-cents-labels {
    display: flex;
    justify-content: space-between;
    font-family: var(--mono-font);
    font-size: 0.6rem;
    color: var(--text-muted);
}

.tuner-display {
    margin-bottom: 2rem;
}

.tuner-note {
    font-family: var(--heading-font);
    font-weight: 700;
    font-size: 5rem;
    line-height: 1;
    color: var(--text);
}

.tuner-freq {
    font-family: var(--mono-font);
    font-size: 0.85rem;
    color: var(--text-dim);
    margin-top: 0.3rem;
}

.tuner-cents {
    font-family: var(--mono-font);
    font-size: 0.8rem;
    color: var(--text-muted);
}

.tuner-hint {
    font-family: var(--mono-font);
    font-size: 0.7rem;
    color: var(--text-muted);
    margin-top: 0.8rem;
}

/* ── audio cutter ─────────────────────────────── */
.cutter-wrap {
    margin-top: 1.5rem;
}

.waveform-container {
    position: relative;
    border: 1px solid var(--border);
    background: var(--surface);
    overflow: hidden;
}

#waveform-canvas {
    display: block;
    width: 100%;
}

.trim-handle {
    position: absolute;
    top: 0;
    width: 8px;
    height: 100%;
    background: var(--accent);
    cursor: ew-resize;
    z-index: 5;
    opacity: 0.8;
}
.trim-handle:hover { opacity: 1; }
.trim-handle-left { left: 0; border-radius: 2px 0 0 2px; }
.trim-handle-right { left: 100%; transform: translateX(-100%); border-radius: 0 2px 2px 0; }

.trim-region {
    position: absolute;
    top: 0;
    height: 100%;
    background: var(--accent-dim);
    pointer-events: none;
    z-index: 2;
}

.playhead {
    position: absolute;
    top: 0;
    left: 0;
    width: 2px;
    height: 100%;
    background: var(--warm);
    z-index: 6;
    pointer-events: none;
}

.cutter-times {
    display: flex;
    justify-content: space-between;
    font-family: var(--mono-font);
    font-size: 0.7rem;
    color: var(--text-dim);
    padding: 0.5rem 0;
}

.cutter-controls {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    align-items: center;
    margin-top: 1rem;
}

/* ── pills (genre selector etc.) ─────────────── */
.pill {
    background: var(--bg-card, var(--surface));
    border: 1px solid var(--border);
    color: var(--text);
    padding: 0.35rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.2s;
}
.pill:hover { border-color: var(--accent); }
.pill.active { background: var(--accent); color: #fff; border-color: var(--accent); }

/* ── about page ──────────────────────────────── */
.about-content {
    max-width: 640px;
    margin: 0 auto;
}
.about-content h2 {
    font-family: var(--heading-font);
    font-weight: 600;
    font-size: 1.1rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin: 2rem 0 0.8rem;
    color: var(--text);
}
.about-content p, .about-content li {
    font-size: 0.9rem;
    color: var(--text-dim);
    line-height: 1.7;
}
.about-content ul {
    padding-left: 1.2rem;
}
.about-content li {
    margin-bottom: 0.4rem;
}
.about-content a {
    color: var(--accent);
    text-decoration: none;
    border-bottom: 1px solid rgba(96, 160, 255, 0.3);
    transition: color 0.2s, border-color 0.2s;
}
.about-content a:hover {
    color: #fff;
    border-color: var(--accent);
}
[data-theme="light"] .about-content a:hover {
    color: #1a1a2e;
}

/* ── Mix Analyzer Report Card ────────────────── */

/* Score hero */
.mix-score-hero {
    display: flex;
    align-items: center;
    gap: 2rem;
    padding: 1.5rem 0 1.2rem;
    border-bottom: 1px solid var(--border);
    margin-bottom: 1.2rem;
}
.mix-grade-ring {
    position: relative;
    width: 96px;
    height: 96px;
    flex-shrink: 0;
}
.mix-grade-ring svg {
    width: 96px;
    height: 96px;
    transform: rotate(-90deg);
}
.mix-grade-ring .ring-bg {
    fill: none;
    stroke: var(--border);
    stroke-width: 4;
}
.mix-grade-ring .ring-fill {
    fill: none;
    stroke-width: 4;
    stroke-linecap: round;
    transition: stroke-dashoffset 1.2s cubic-bezier(0.22, 1, 0.36, 1);
}
.mix-grade-letter {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--heading-font);
    font-weight: 700;
    font-size: 2.4rem;
    line-height: 1;
    letter-spacing: -0.02em;
}
.mix-score-body {
    flex: 1;
    min-width: 0;
}
.mix-score-numeric {
    font-family: var(--mono-font);
    font-size: 0.85rem;
    color: var(--text-dim);
    margin-bottom: 0.6rem;
}
.mix-score-numeric strong {
    font-size: 1.3rem;
    font-weight: 500;
    color: var(--text);
}
.mix-sub-scores {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.5rem;
}
.mix-sub-score {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}
.mix-sub-score-label {
    font-family: var(--mono-font);
    font-size: 0.6rem;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--text-muted);
}
.mix-sub-score-bar {
    height: 4px;
    border-radius: 2px;
    background: var(--border);
    overflow: hidden;
}
.mix-sub-score-fill {
    height: 100%;
    border-radius: 2px;
    transition: width 0.8s cubic-bezier(0.22, 1, 0.36, 1);
}
.mix-sub-score-val {
    font-family: var(--mono-font);
    font-size: 0.7rem;
    color: var(--text-dim);
}
.mix-summary-line {
    font-family: var(--mono-font);
    font-size: 0.65rem;
    color: var(--text-muted);
    margin-top: 0.6rem;
    letter-spacing: 0.3px;
    display: flex;
    flex-wrap: wrap;
    gap: 0.15rem 0.75rem;
}

/* Report waveform area */
.mix-waveform-wrap {
    position: relative;
    border-radius: 8px;
    background: var(--bg-deep);
    border: 1px solid var(--border);
    overflow: hidden;
    margin-bottom: 0.5rem;
}
.mix-waveform-wrap canvas {
    display: block;
    width: 100%;
    cursor: crosshair;
}
.mix-wf-time-axis {
    display: flex;
    justify-content: space-between;
    padding: 0 4px;
    font-family: var(--mono-font);
    font-size: 0.55rem;
    color: var(--text-muted);
    margin-top: 2px;
    margin-bottom: 0.6rem;
}

/* Transition markers tooltip on hover */
.mix-marker-tooltip {
    position: absolute;
    top: -24px;
    transform: translateX(-50%);
    font-family: var(--mono-font);
    font-size: 0.6rem;
    padding: 2px 6px;
    border-radius: 3px;
    white-space: nowrap;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.15s;
}

/* Transition list */
.mix-transitions-header {
    font-family: var(--heading-font);
    font-weight: 600;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}
.mix-transition-card {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.6rem 0.8rem;
    border-radius: 6px;
    background: var(--surface);
    border: 1px solid var(--border);
    margin-bottom: 0.4rem;
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s;
}
.mix-transition-card:hover {
    border-color: var(--border-hover);
    background: var(--surface-solid);
}
.mix-transition-card.active {
    border-color: var(--accent);
    box-shadow: 0 0 0 1px var(--accent-glow);
}
.mix-tc-led {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
    box-shadow: 0 0 6px currentColor;
}
.mix-tc-time {
    font-family: var(--mono-font);
    font-size: 0.8rem;
    font-weight: 500;
    width: 3.5rem;
    flex-shrink: 0;
}
.mix-tc-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.2rem 0.6rem;
    font-size: 0.7rem;
    color: var(--text-dim);
}
.mix-tc-info .tag {
    font-family: var(--mono-font);
    font-size: 0.6rem;
    padding: 1px 5px;
    border-radius: 3px;
    background: var(--accent-dim);
    color: var(--accent);
    letter-spacing: 0.3px;
}
.mix-tc-score {
    font-family: var(--mono-font);
    font-size: 0.75rem;
    font-weight: 500;
    flex-shrink: 0;
}

/* Transition detail (expanded below waveform) */
.mix-detail-card {
    padding: 1rem;
    border-radius: 8px;
    background: var(--surface);
    border: 1px solid var(--accent);
    border-left: 3px solid var(--accent);
    margin-bottom: 1rem;
    animation: fadeSlideIn 0.25s ease-out;
}
@keyframes fadeSlideIn {
    from { opacity: 0; transform: translateY(-6px); }
    to { opacity: 1; transform: translateY(0); }
}
.mix-detail-header {
    font-family: var(--heading-font);
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--accent);
    margin-bottom: 0.6rem;
}
.mix-detail-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 0.6rem;
}
.mix-detail-item label {
    display: block;
    font-family: var(--mono-font);
    font-size: 0.55rem;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--text-muted);
    margin-bottom: 0.15rem;
}
.mix-detail-item span {
    font-family: var(--mono-font);
    font-size: 0.8rem;
}

/* Issues list */
.mix-issues-header {
    font-family: var(--heading-font);
    font-weight: 600;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-muted);
    margin-top: 1rem;
    margin-bottom: 0.5rem;
}
.mix-issue-row {
    display: flex;
    align-items: baseline;
    gap: 0.5rem;
    padding: 0.35rem 0;
    font-size: 0.75rem;
    border-bottom: 1px solid var(--border);
}
.mix-issue-row:last-child { border-bottom: none; }
.mix-issue-badge {
    font-family: var(--mono-font);
    font-size: 0.55rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 1px 5px;
    border-radius: 3px;
    flex-shrink: 0;
}
.mix-issue-badge.error   { background: rgba(239,68,68,0.15);  color: #ef4444; }
.mix-issue-badge.warning { background: rgba(245,158,11,0.15); color: #f59e0b; }
.mix-issue-badge.info    { background: rgba(96,160,255,0.1);  color: var(--accent); }
.mix-issue-time {
    font-family: var(--mono-font);
    font-size: 0.7rem;
    color: var(--text-muted);
    flex-shrink: 0;
    width: 3rem;
}
.mix-issue-msg {
    color: var(--text-dim);
    flex: 1;
}

/* Status colors */
.clr-locked      { color: #4ade80; }
.clr-slight-drift { color: #f59e0b; }
.clr-lost        { color: #ef4444; }
.clr-error       { color: #ef4444; }
.bg-locked       { background: #4ade80; }
.bg-slight-drift { background: #f59e0b; }
.bg-lost         { background: #ef4444; }
.bg-error        { background: #ef4444; }

/* "Analyze another" link */
.mix-analyze-again {
    display: inline-block;
    font-family: var(--mono-font);
    font-size: 0.7rem;
    color: var(--accent);
    cursor: pointer;
    margin-top: 1rem;
    opacity: 0.7;
    transition: opacity 0.2s;
}
.mix-analyze-again:hover { opacity: 1; }

/* No transitions banner */
.mix-info-banner {
    padding: 0.6rem 0.8rem;
    border-radius: 6px;
    background: var(--accent-dim);
    border: 1px solid var(--accent);
    font-family: var(--mono-font);
    font-size: 0.7rem;
    color: var(--accent);
    margin-bottom: 1rem;
}

@media (max-width: 640px) {
    .mix-score-hero { flex-direction: column; text-align: center; gap: 1rem; }
    .mix-sub-scores { grid-template-columns: repeat(2, 1fr); }
    .mix-summary-line { justify-content: center; }
    .mix-detail-grid { grid-template-columns: 1fr 1fr; }
}

/* ── audio-to-midi ───────────────────────────── */
.midi-stats {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}
.midi-stat {
    flex: 1;
    min-width: 100px;
    padding: 0.6rem;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 6px;
    text-align: center;
}
.midi-stat-label {
    font-family: var(--mono-font);
    font-size: 0.6rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-muted);
    margin-bottom: 0.2rem;
}
.midi-stat-value {
    font-family: var(--heading-font);
    font-weight: 700;
    font-size: 1.3rem;
    color: var(--accent);
}
.piano-roll-wrap {
    position: relative;
    background: var(--bg-deep);
    border: 1px solid var(--border);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 1rem;
}
.piano-roll-wrap canvas {
    display: block;
    width: 100%;
    cursor: grab;
}
.piano-roll-wrap canvas:active {
    cursor: grabbing;
}
.midi-controls {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

/* ── pitch shifter ───────────────────────────── */
.ps-controls {
    max-width: 600px;
    margin: 1.5rem auto 0;
}
.ps-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 0;
    border-bottom: 1px solid var(--border);
}
.ps-label {
    font-family: var(--mono-font);
    font-size: 0.7rem;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 1px;
    min-width: 42px;
}
.ps-slider {
    flex: 1;
    accent-color: var(--accent);
}
.ps-value {
    font-family: var(--mono-font);
    font-size: 0.9rem;
    color: var(--text);
    min-width: 50px;
    text-align: right;
}
.ps-step-btn {
    padding: 0.25rem 0.5rem !important;
    font-size: 0.75rem !important;
    min-width: unset !important;
    font-family: var(--mono-font) !important;
}
.ps-actions {
    display: flex;
    gap: 0.6rem;
    justify-content: center;
    margin-top: 1.5rem;
    flex-wrap: wrap;
}

/* ── ad slots (empty placeholders) ────────────── */
.ad-slot {
    position: relative;
    z-index: 1;
    max-width: 900px;
    margin: 0 auto;
}
.ad-leaderboard {
    min-height: 0;
    margin-top: 0.5rem;
}
.ad-rectangle {
    min-height: 0;
    margin-bottom: 0.5rem;
}

/* ── footer ───────────────────────────────────── */
footer {
    position: relative;
    z-index: 1;
    text-align: center;
    padding: 2.5rem 2rem 2rem;
    color: var(--text-muted);
    font-family: var(--mono-font);
    font-size: 0.65rem;
    border-top: none;
    letter-spacing: 0.5px;
    margin-top: 1rem;
}
footer::before {
    content: "";
    position: absolute;
    top: 0;
    left: 10%;
    right: 10%;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--accent), transparent);
    opacity: 0.3;
}
.footer-links {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.5rem 0;
    margin-bottom: 1.2rem;
    padding-bottom: 1.2rem;
    border-bottom: 1px solid var(--border);
}
.footer-links a {
    position: relative;
    padding: 0.3rem 0.85rem;
}
.footer-links a:not(:last-child)::after {
    content: "";
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 1px;
    height: 12px;
    background: var(--border);
}
footer a {
    color: var(--text-dim);
    text-decoration: none;
    transition: color 0.25s;
    position: relative;
}
footer a:hover { color: var(--text); }
footer .footer-links a::before {
    content: "";
    position: absolute;
    bottom: 2px;
    left: 0.85rem;
    right: 0.85rem;
    height: 1px;
    background: var(--accent);
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.3s cubic-bezier(0.33, 1, 0.68, 1);
}
footer .footer-links a:hover::before {
    transform: scaleX(1);
    transform-origin: left;
}
footer p {
    line-height: 1.8;
}
footer p a {
    text-decoration: underline;
    text-decoration-color: var(--border);
    text-underline-offset: 2px;
    transition: color 0.25s, text-decoration-color 0.25s;
}
footer p a:hover {
    text-decoration-color: var(--accent);
    color: var(--text);
}
.footer-brand {
    font-family: var(--heading-font);
    font-weight: 600;
    font-size: 0.75rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--text-dim);
    text-decoration: none !important;
}
.footer-brand:hover { color: var(--accent); }

/* ── drum machine ────────────────────────────── */
.dm-wrap {
    max-width: 900px;
    margin: 0 auto 2rem;
}

.dm-transport {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 8px;
    margin-bottom: 1rem;
}

.dm-play-btn {
    min-width: 5rem;
}
.dm-play-btn.playing {
    background: var(--warm);
}

.dm-ctrl-group {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.dm-ctrl-label {
    font-family: var(--mono-font);
    font-size: 0.65rem;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.dm-bpm-btn {
    padding: 0.3rem 0.6rem;
    font-size: 0.8rem;
    min-width: unset;
}

.dm-bpm-val {
    font-family: var(--heading-font);
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--accent);
    min-width: 2.5rem;
    text-align: center;
}

.dm-slider {
    width: 80px;
    accent-color: var(--accent);
}

.dm-swing-val {
    font-family: var(--mono-font);
    font-size: 0.7rem;
    color: var(--text-dim);
    min-width: 2rem;
}

.dm-select {
    font-family: var(--body-font);
    font-size: 0.8rem;
    padding: 0.3rem 0.5rem;
    background: var(--surface-solid);
    color: var(--text);
    border: 1px solid var(--border);
    border-radius: 4px;
    cursor: pointer;
}

/* Desktop grid */
.dm-grid {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.dm-row {
    display: flex;
    align-items: center;
    gap: 2px;
}

.dm-label {
    width: 50px;
    padding: 0.4rem 0.3rem;
    font-family: var(--mono-font);
    font-size: 0.65rem;
    font-weight: 500;
    color: var(--text-dim);
    background: var(--surface);
    border: 1px solid var(--border);
    border-left: 3px solid;
    border-radius: 4px;
    cursor: pointer;
    text-align: center;
    transition: all 0.15s;
    flex-shrink: 0;
}
.dm-label:hover {
    color: var(--text);
    background: var(--accent-dim);
}

.dm-steps {
    display: flex;
    gap: 2px;
    flex: 1;
}

.dm-cell {
    flex: 1;
    aspect-ratio: 1;
    max-height: 36px;
    border: 1px solid var(--border);
    border-radius: 3px;
    background: var(--surface);
    cursor: pointer;
    transition: all 0.1s;
    position: relative;
}
.dm-cell.dm-cell-alt {
    background: var(--accent-dim);
}
.dm-cell:hover {
    border-color: var(--border-hover);
}
.dm-cell.active {
    background: var(--ch-color, var(--accent));
    border-color: var(--ch-color, var(--accent));
    box-shadow: 0 0 6px color-mix(in srgb, var(--ch-color, var(--accent)) 40%, transparent);
}
.dm-cell.playhead::after {
    content: '';
    position: absolute;
    inset: 0;
    border: 2px solid var(--text);
    border-radius: 3px;
    opacity: 0.5;
}

.dm-vol-wrap {
    width: 60px;
    flex-shrink: 0;
}
.dm-vol {
    width: 100%;
    accent-color: var(--accent);
}

/* Mobile pads */
.dm-pads {
    display: none;
    grid-template-columns: repeat(4, 1fr);
    gap: 6px;
}

.dm-pad {
    aspect-ratio: 1;
    border: 2px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
    color: var(--text-dim);
    font-family: var(--mono-font);
    font-size: 0.65rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.dm-pad:active {
    transform: scale(0.95);
}
.dm-pad.selected {
    background: color-mix(in srgb, var(--pad-color) 20%, transparent);
    border-color: var(--pad-color);
    color: var(--text);
    box-shadow: 0 0 12px color-mix(in srgb, var(--pad-color) 30%, transparent);
}

/* Mobile mini-sequencer */
.dm-mobile-seq {
    display: none;
    flex-direction: column;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.dm-mini-seq {
    display: flex;
    gap: 3px;
}

.dm-mini-cell {
    flex: 1;
    height: 32px;
    border: 1px solid var(--border);
    border-radius: 3px;
    background: var(--surface);
    cursor: pointer;
    transition: all 0.1s;
}
.dm-mini-cell.dm-cell-alt {
    background: var(--accent-dim);
}
.dm-mini-cell.active {
    background: var(--ch-color, var(--accent));
    border-color: var(--ch-color, var(--accent));
}
.dm-mini-cell.playhead::after {
    content: '';
    position: absolute;
    inset: 0;
    border: 2px solid var(--text);
    border-radius: 3px;
    opacity: 0.5;
}
.dm-mini-cell {
    position: relative;
}

.dm-ch-vol-wrap {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* SEO content */
.seo-content {
    max-width: 700px;
    margin: 2rem auto;
    padding: 2rem;
    color: var(--text-dim);
    font-size: 0.85rem;
    line-height: 1.7;
}
.seo-content h2, .seo-content h3 {
    font-family: var(--heading-font);
    color: var(--text);
    margin: 1.5rem 0 0.5rem;
}
.seo-content h2 { font-size: 1.3rem; }
.seo-content h3 { font-size: 1rem; }
.seo-content p { margin-bottom: 0.8rem; }

/* ── seo components ──────────────────────────── */
.breadcrumb {
    max-width: 700px;
    margin: 0 auto 0.5rem;
    padding: 0.4rem 1rem;
    font-size: 0.75rem;
    color: var(--text-muted);
    font-family: var(--mono-font);
    border-radius: 999px;
}
.breadcrumb ol {
    list-style: none;
    display: flex;
    gap: 0.4rem;
    padding: 0;
    margin: 0;
    flex-wrap: wrap;
}
.breadcrumb li:not(:last-child)::after {
    content: '>';
    margin-left: 0.4rem;
    opacity: 0.5;
}
.breadcrumb a {
    color: var(--accent);
    text-decoration: none;
}
.breadcrumb [aria-current] {
    color: var(--text-muted);
}

.privacy-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1.1rem;
    border: 1px solid rgba(80, 200, 120, 0.3);
    border-radius: 100px;
    font-size: 0.7rem;
    color: rgba(80, 200, 120, 0.85);
    font-family: var(--mono-font);
    letter-spacing: 0.02em;
    margin: 0.5rem auto 1rem;
    text-align: center;
    background: linear-gradient(135deg, rgba(80, 200, 120, 0.1), rgba(96, 160, 255, 0.05));
    box-shadow: 0 0 20px rgba(80, 200, 120, 0.06), inset 0 1px 0 rgba(80, 200, 120, 0.08);
}
.privacy-badge svg {
    width: 14px;
    height: 14px;
    flex-shrink: 0;
    color: rgba(80, 200, 120, 0.9);
}

.how-to-section {
    max-width: 700px;
    margin: 2.5rem auto 0;
}
.how-to-section h2 {
    font-family: var(--heading-font);
    font-size: 1.2rem;
    color: var(--text);
    margin-bottom: 1rem;
    text-align: center;
}
.steps-pills {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}
.step-pill {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.6rem 1rem;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 100px;
    font-size: 0.8rem;
    color: var(--text);
    flex: 1;
    min-width: 180px;
    max-width: 280px;
}
.step-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--accent);
    color: #fff;
    font-size: 0.7rem;
    font-weight: 700;
    flex-shrink: 0;
}

.faq-section {
    max-width: 720px;
    margin: 4rem auto 0;
    padding: 2rem 0 0;
    border: none;
    position: relative;
}
.faq-section::before {
    content: "";
    display: block;
    width: 60px;
    height: 2px;
    background: linear-gradient(90deg, var(--accent), transparent);
    margin: 0 auto 2rem;
    border-radius: 1px;
}
.faq-section h2 {
    font-family: var(--heading-font);
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 1.5rem;
    text-align: center;
    letter-spacing: 1px;
    text-transform: uppercase;
}
.faq-item {
    border: 1px solid var(--border);
    border-radius: 12px;
    margin-bottom: 0.6rem;
    overflow: hidden;
    background: transparent;
    transition: border-color 0.3s, background 0.3s, box-shadow 0.3s;
}
.faq-item:hover {
    border-color: var(--border-hover);
    background: rgba(96, 160, 255, 0.03);
    box-shadow: 0 2px 12px rgba(96, 160, 255, 0.04);
}
.faq-item summary {
    padding: 1rem 1.4rem;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.85rem;
    color: var(--text);
    list-style: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    transition: color 0.2s;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary:hover { color: var(--accent); }
/* custom chevron indicator */
.faq-item summary::after {
    content: '';
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    border-radius: 50%;
    background: var(--accent-dim);
    border: 1px solid rgba(96, 160, 255, 0.12);
    position: relative;
    transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1), background 0.3s;
    /* chevron arrow via borders */
    display: flex;
    align-items: center;
    justify-content: center;
}
/* chevron drawn with box-shadow trick */
.faq-item summary::after {
    content: '';
    width: 7px;
    height: 7px;
    flex-shrink: 0;
    border-right: 2px solid var(--accent);
    border-bottom: 2px solid var(--accent);
    transform: rotate(45deg);
    transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.2s;
    opacity: 0.5;
    margin-right: 2px;
}
.faq-item:hover summary::after { opacity: 0.9; }
.faq-item[open] summary::after {
    transform: rotate(-135deg);
    opacity: 0.9;
}
.faq-item[open] {
    border-color: rgba(96, 160, 255, 0.25);
    background: rgba(96, 160, 255, 0.04);
    box-shadow: 0 4px 20px rgba(96, 160, 255, 0.06);
}
.faq-item[open] summary {
    color: var(--accent);
    border-bottom: 1px solid rgba(96, 160, 255, 0.1);
}
.faq-answer {
    padding: 0.8rem 1.4rem 1.2rem;
    font-size: 0.82rem;
    line-height: 1.75;
    color: var(--text-dim);
}
[data-theme="light"] .faq-section::before {
    background: linear-gradient(90deg, var(--accent), transparent);
}
[data-theme="light"] .faq-section h2 { color: var(--text); }
[data-theme="light"] .faq-item {
    border-color: rgba(79, 70, 229, 0.12);
    background: rgba(79, 70, 229, 0.02);
}
[data-theme="light"] .faq-item:hover {
    border-color: rgba(79, 70, 229, 0.2);
    background: rgba(79, 70, 229, 0.04);
    box-shadow: 0 2px 12px rgba(79, 70, 229, 0.04);
}
[data-theme="light"] .faq-item[open] {
    border-color: rgba(79, 70, 229, 0.25);
    background: rgba(79, 70, 229, 0.04);
    box-shadow: 0 4px 20px rgba(79, 70, 229, 0.06);
}
[data-theme="light"] .faq-item[open] summary {
    border-bottom-color: rgba(79, 70, 229, 0.1);
}
[data-theme="light"] .faq-item summary::after {
    border-right-color: var(--accent);
    border-bottom-color: var(--accent);
}

.related-tools {
    max-width: 700px;
    margin: 2.5rem auto 0;
}
.related-tools h2 {
    font-family: var(--heading-font);
    font-size: 1.2rem;
    color: var(--text);
    margin-bottom: 1rem;
}
.related-tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 0.8rem;
}
.related-tool-card {
    display: block;
    padding: 1rem;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    text-decoration: none;
    transition: border-color 0.2s, transform 0.2s;
}
.related-tool-card:hover {
    border-color: var(--accent);
    transform: translateY(-2px);
}
.related-tool-card h3 {
    font-family: var(--heading-font);
    font-size: 0.85rem;
    color: var(--text);
    margin: 0.4rem 0 0.2rem;
}
.related-tool-card p {
    font-size: 0.7rem;
    color: var(--text-muted);
    margin: 0;
    line-height: 1.4;
}
.related-tool-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    filter: drop-shadow(0 2px 6px rgba(96, 160, 255, 0.12));
}

.results-crosslink {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    margin-top: 1rem;
    padding: 0.5rem 1rem;
    background: var(--surface);
    border: 1px solid var(--accent);
    border-radius: 8px;
    color: var(--accent);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 600;
    transition: background 0.2s;
}
.results-crosslink:hover {
    background: var(--accent);
    color: #fff;
}

/* ── responsive ───────────────────────────────── */
@media (max-width: 900px) {
    .featured-grid { grid-template-columns: 1fr; gap: 10px; }
    .why-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
    .tool-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
    .category-header::after { display: none; }
    .camelot-wrap { flex-direction: column; align-items: center; }
    .camelot-info { max-width: 100%; text-align: center; }
    .nav-right { gap: 0.5rem; }
    .nav-right a { font-size: 0.6rem; }
}

@media (max-width: 640px) {
    nav { padding: 0 1.2rem; }
    main { padding: 1.2rem; }
    .hero { padding: 2.5rem 0 1.5rem; }
    .hero h1 { font-size: 2.2rem; }
    .upload-area { padding: 2rem 1.2rem; }
    .tool-grid { grid-template-columns: 1fr; gap: 8px; }
    .why-grid { grid-template-columns: 1fr; gap: 8px; }
    .trust-strip { gap: 0.3rem 0.4rem; font-size: 0.55rem; }
    .trust-strip span { padding: 0.25rem 0.55rem; }
    .stats-strip { flex-direction: column; border-radius: 12px; }
    .stats-strip span { padding: 0.7rem 1rem; font-size: 0.55rem; }
    .stats-strip span + span::before { left: 15%; right: 15%; top: 0; bottom: auto; width: auto; height: 1px; }
    .btn { padding: 0.6rem 1.2rem; font-size: 0.8rem; }
    .tap-area { padding: 5rem 2rem; }
    .bpm-display, .tap-bpm { font-size: 4rem; }

    /* Drum machine mobile layout */
    .dm-grid { display: none; }
    .dm-pads { display: grid; }
    .dm-mobile-seq { display: flex; }
    .dm-transport { gap: 0.5rem; }
    .dm-transport .dm-ctrl-group { flex-wrap: wrap; }

    /* SEO components mobile */
    .steps-pills { flex-direction: column; align-items: stretch; }
    .step-pill { max-width: 100%; }
    .related-tools-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 380px) {
    .nav-right a:not(:first-child):not(:last-child) { display: none; }
}

/* ── Auto-Master ─────────────────────────────── */
.slider-group { display: flex; flex-direction: column; gap: 0.25rem; }
.slider-label { font-size: 0.7rem; font-family: var(--mono-font); color: var(--text-dim); letter-spacing: 0.5px; }
.slider-ends { display: flex; justify-content: space-between; font-size: 0.6rem; color: var(--text-muted); }
.slider-value { font-size: 0.7rem; font-family: var(--mono-font); color: var(--accent); text-align: center; }
.slider { width: 100%; accent-color: var(--accent); }
.ab-toggle { display: inline-flex; border: 1px solid var(--border); border-radius: 6px; overflow: hidden; }
.ab-btn { padding: 0.35rem 0.75rem; font-size: 0.8rem; font-family: var(--mono-font); background: transparent; color: var(--text-dim); border: none; cursor: pointer; transition: background 0.2s, color 0.2s; }
.ab-btn.active { background: var(--accent); color: #fff; }
.ab-btn:hover:not(.active) { background: var(--accent-dim); }

@media (max-width: 600px) {
    #advanced-panel .slider-group { grid-template-columns: 1fr; }
    #results-section > div:first-child { grid-template-columns: 1fr !important; }
}

/* ── Song Analyzer ─────────────────────────────── */
.analyzer-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 16px;
  margin: 24px auto;
  max-width: 960px;
}
.analyzer-card {
  background: var(--glass);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px;
  position: relative;
  overflow: hidden;
}
.analyzer-card.wide { grid-column: span 2; }
.analyzer-card:nth-child(4) { grid-column: 1 / 3; }
.analyzer-card:nth-child(5) { grid-column: 3 / 4; }

.card-label {
  font-family: var(--font-heading);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
  margin-bottom: 12px;
}
.card-body { min-height: 80px; }

/* Skeleton shimmer */
.card-body.skeleton .skeleton-line {
  height: 14px;
  border-radius: 4px;
  background: linear-gradient(90deg, var(--border) 25%, rgba(96,160,255,0.08) 50%, var(--border) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s ease-in-out infinite;
  margin-bottom: 10px;
}
.card-body.skeleton .skeleton-line.short { width: 60%; }
@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* Result content fade-in */
.card-body.loaded { animation: cardFadeIn 0.3s ease; }
@keyframes cardFadeIn {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Key card */
.key-result-value { font-size: 2.5rem; font-weight: 700; color: var(--text); }
.key-result-sub { font-size: 0.85rem; color: var(--text-dim); margin-top: 4px; }

/* BPM card */
.bpm-result-value { font-size: 2.5rem; font-weight: 700; color: var(--text); }
.bpm-result-sub { font-size: 0.85rem; color: var(--text-dim); margin-top: 4px; }

/* Chords card */
.chord-timeline { max-height: 200px; overflow-y: auto; font-size: 0.85rem; }
.chord-row { display: flex; gap: 8px; padding: 4px 0; border-bottom: 1px solid var(--border); }
.chord-time { color: var(--text-dim); min-width: 50px; font-family: var(--font-mono); }
.chord-name { color: var(--text); font-weight: 600; }

/* MIDI card */
.midi-roll-container { height: 120px; border-radius: 6px; overflow: hidden; background: var(--bg-deep); }
.midi-actions { display: flex; gap: 8px; margin-top: 10px; }

/* Stems card */
.stem-row { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.stem-label { font-size: 0.8rem; color: var(--text-dim); min-width: 80px; }
.stem-waveform { flex: 1; height: 40px; background: var(--bg-deep); border-radius: 4px; overflow: hidden; }
.stem-actions { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 8px; }
.stem-mobile-gate {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  min-height: 100px; color: var(--text-dim); text-align: center; font-size: 0.85rem;
}

/* Refined badge */
.badge-refined {
  display: inline-block;
  font-size: 0.7rem;
  padding: 2px 8px;
  border-radius: 10px;
  background: rgba(96,160,255,0.12);
  color: var(--accent);
  margin-left: 8px;
  vertical-align: middle;
}

/* Card action buttons */
.card-btn {
  padding: 6px 12px;
  font-size: 0.75rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--glass);
  color: var(--text);
  cursor: pointer;
  transition: border-color 0.15s;
  text-decoration: none;
}
.card-btn:hover { border-color: var(--accent); }

/* Card error state */
.card-error { color: var(--text-dim); font-size: 0.85rem; text-align: center; padding: 20px 10px; }

/* Card progress */
.card-progress { height: 3px; background: var(--border); border-radius: 2px; margin-top: 8px; overflow: hidden; }
.card-progress-fill { height: 100%; background: var(--accent); transition: width 0.3s; width: 0%; }

/* Responsive: single column on mobile */
@media (max-width: 768px) {
  .analyzer-grid { grid-template-columns: 1fr; }
  .analyzer-card.wide,
  .analyzer-card:nth-child(4),
  .analyzer-card:nth-child(5) { grid-column: 1; }
}

/* ── OPFS cross-tool workflow ─────────────────── */
.opfs-suggestions { margin-top: 1.25rem; padding-top: 1rem; border-top: 1px solid var(--border); }
.opfs-suggest-group { margin-bottom: 0.75rem; }
.opfs-suggestions-label { display: block; font-size: 0.7rem; font-family: var(--mono-font); text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-muted); margin-bottom: 0.5rem; }
.opfs-suggest-btns { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.opfs-suggest-btn { display: inline-block; padding: 0.35rem 0.75rem; font-size: 0.8rem; font-family: var(--mono-font); color: var(--accent); background: var(--accent-dim); border: 1px solid var(--accent); border-radius: 6px; text-decoration: none; transition: background 0.2s, color 0.2s; cursor: pointer; }
.opfs-suggest-btn:hover { background: var(--accent); color: #fff; }
.opfs-recent { display: flex; flex-wrap: wrap; align-items: center; gap: 0.4rem; margin-top: 0.75rem; padding-top: 0.5rem; border-top: 1px solid var(--border); }
.opfs-recent-label { font-size: 0.65rem; font-family: var(--mono-font); text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-muted); }
.opfs-chip { display: inline-flex; align-items: center; gap: 0.3rem; padding: 0.25rem 0.6rem; font-size: 0.75rem; font-family: var(--mono-font); color: var(--text-dim); background: transparent; border: 1px solid var(--border); border-radius: 999px; cursor: pointer; transition: border-color 0.2s, color 0.2s; white-space: nowrap; max-width: 220px; }
.opfs-chip span:first-child { overflow: hidden; text-overflow: ellipsis; }
.opfs-chip:hover { border-color: var(--accent); color: var(--accent); }
.opfs-chip-tag { font-size: 0.6rem; padding: 0.05rem 0.3rem; border-radius: 3px; font-weight: 600; letter-spacing: 0.03em; flex-shrink: 0; }
.opfs-chip-tag-turbo { background: rgba(96, 160, 255, 0.15); color: var(--accent); }
.opfs-toast { position: fixed; bottom: 1.5rem; left: 50%; transform: translateX(-50%) translateY(1rem); padding: 0.6rem 1.2rem; font-size: 0.85rem; font-family: var(--mono-font); color: #fff; background: var(--bg-card); border: 1px solid var(--border); border-radius: 8px; opacity: 0; transition: opacity 0.3s, transform 0.3s; z-index: 9999; pointer-events: none; }
.opfs-toast.visible { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ── Next-steps bar ──────────────────────────── */
.next-steps-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; margin-top: 1rem; padding: 0.75rem 1rem; border-radius: 8px; background: var(--bg-card); border: 1px solid var(--border); }
.next-steps-title { font-size: 0.7rem; font-family: var(--mono-font); text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-muted); margin-right: 0.25rem; }
.next-steps-btn { padding: 0.35rem 0.85rem; font-size: 0.8rem; font-family: var(--mono-font); color: var(--accent); background: transparent; border: 1px solid var(--accent); border-radius: 6px; cursor: pointer; transition: background 0.2s, color 0.2s; white-space: nowrap; }
.next-steps-btn:hover { background: var(--accent); color: #fff; }

/* ── reduced motion ───────────────────────────── */
@media (prefers-reduced-motion: reduce) {
    .particle { animation: none !important; display: none; }
    .upload-icon .bar { animation: none !important; }
    *, *::before, *::after { transition-duration: 0.01s !important; animation-duration: 0.01s !important; }
}

/* === Turbo Nav Button === */
.turbo-nav { position: relative; }
.turbo-btn {
  display: inline-flex; align-items: center; gap: 6px;
  background: linear-gradient(135deg, rgba(96,160,255,0.08), rgba(168,85,247,0.08));
  border: 1px solid rgba(96,160,255,0.35);
  color: var(--accent); padding: 6px 14px; border-radius: 8px;
  font-family: var(--mono-font); font-size: 0.85rem;
  cursor: pointer; transition: all 0.25s ease;
  position: relative; overflow: hidden;
}
.turbo-btn::before {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(135deg, rgba(96,160,255,0.12), rgba(168,85,247,0.12));
  opacity: 0; transition: opacity 0.25s;
}
.turbo-btn:hover::before { opacity: 1; }
.turbo-btn:hover {
  border-color: rgba(96,160,255,0.6);
  box-shadow: 0 0 16px rgba(96,160,255,0.15), 0 0 4px rgba(168,85,247,0.1);
  transform: translateY(-1px);
}
.turbo-btn.turbo-active {
  background: linear-gradient(135deg, var(--accent), #a855f7);
  border-color: transparent; color: #fff;
  box-shadow: 0 0 20px rgba(96,160,255,0.3), 0 0 40px rgba(168,85,247,0.15);
  animation: turbo-glow 2.5s ease-in-out infinite;
}
.turbo-btn.turbo-active::before { display: none; }
@keyframes turbo-glow {
  0%, 100% { box-shadow: 0 0 12px rgba(96,160,255,0.3), 0 0 24px rgba(168,85,247,0.1); }
  50% { box-shadow: 0 0 20px rgba(96,160,255,0.5), 0 0 40px rgba(168,85,247,0.2); }
}
.turbo-icon { font-size: 1rem; filter: saturate(1.2); }

/* === Turbo Dropdown (Wallet) === */
.turbo-dropdown {
  position: absolute; top: calc(100% + 10px); right: 0;
  background: var(--surface-solid);
  border: 1px solid var(--border);
  border-radius: 14px; padding: 0; min-width: 280px;
  opacity: 0; visibility: hidden; transform: translateY(-8px) scale(0.97);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1); z-index: 100;
  backdrop-filter: blur(24px);
  box-shadow: 0 8px 32px rgba(0,0,0,0.3), 0 0 0 1px rgba(96,160,255,0.06);
  overflow: hidden;
}
.turbo-dropdown.open {
  opacity: 1; visibility: visible; transform: translateY(0) scale(1);
}
/* Top accent bar */
.turbo-dropdown::before {
  content: ''; display: block; height: 2px;
  background: linear-gradient(90deg, var(--accent), #a855f7, var(--accent));
  background-size: 200% 100%;
  animation: turbo-gradient-slide 3s linear infinite;
}
@keyframes turbo-gradient-slide {
  0% { background-position: 0% 50%; }
  100% { background-position: 200% 50%; }
}
.turbo-dropdown-inner { padding: 16px; }
.turbo-user-row {
  display: flex; align-items: center; gap: 8px;
  padding-bottom: 12px; margin-bottom: 12px;
  border-bottom: 1px solid rgba(96,160,255,0.1);
}
.turbo-user-avatar {
  width: 28px; height: 28px; border-radius: 50%;
  background: rgba(96,160,255,0.15); flex-shrink: 0;
  object-fit: cover;
}
.turbo-user-name {
  flex: 1; font-size: 0.85rem; color: var(--text);
  font-weight: 500; white-space: nowrap; overflow: hidden;
  text-overflow: ellipsis;
}
.turbo-logout-btn {
  background: none; border: 1px solid rgba(96,160,255,0.15);
  color: var(--text-dim); font-size: 0.75rem; padding: 3px 10px;
  border-radius: 6px; cursor: pointer; flex-shrink: 0;
  transition: color 0.2s, border-color 0.2s;
}
.turbo-logout-btn:hover {
  color: #ff6b6b; border-color: rgba(255,107,107,0.3);
}
.turbo-dropdown-header {
  font-family: var(--mono-font); font-size: 0.9rem;
  color: var(--text); margin-bottom: 4px;
  display: flex; align-items: center; gap: 6px;
}
.turbo-dropdown-header .turbo-icon { font-size: 0.9rem; }
.turbo-dropdown-balance {
  color: var(--accent); font-weight: 500;
}
.turbo-boosts, .turbo-pass-info {
  font-size: 0.8rem; color: var(--text-dim); margin-bottom: 8px;
}
.turbo-boosts .turbo-boosts-value {
  color: #22c55e; font-family: var(--mono-font); font-weight: 500;
}
.turbo-divider {
  border: none; border-top: 1px solid var(--border); margin: 12px 0;
}
.turbo-options-label {
  font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.8px;
  color: var(--text-muted); font-family: var(--heading-font); font-weight: 600;
  margin-bottom: 8px;
}
.turbo-options { display: flex; flex-direction: column; gap: 8px; }
.turbo-option {
  display: flex; justify-content: space-between; align-items: center;
  background: rgba(96,160,255,0.04); border: 1px solid var(--border);
  color: var(--text); padding: 12px 14px; border-radius: 10px;
  font-family: var(--body-font); font-size: 0.85rem;
  cursor: pointer; transition: all 0.2s ease;
  position: relative; text-decoration: none;
}
.turbo-option:hover {
  border-color: var(--accent);
  background: rgba(96,160,255,0.08);
  box-shadow: 0 2px 12px rgba(96,160,255,0.1);
}
.turbo-option:active { transform: scale(0.98); }
.turbo-option .turbo-option-name {
  display: flex; align-items: center; gap: 8px;
  font-weight: 600; font-size: 0.9rem;
}
.turbo-option > span:last-child {
  color: var(--text-dim); font-family: var(--mono-font); font-size: 0.8rem;
  font-weight: 400; white-space: nowrap;
}
.turbo-option .turbo-best-value {
  font-size: 0.55rem; text-transform: uppercase; letter-spacing: 0.8px;
  background: linear-gradient(135deg, var(--accent), #a855f7);
  color: #fff; padding: 3px 8px; border-radius: 99px;
  font-family: var(--heading-font); font-weight: 700;
  line-height: 1.3; white-space: nowrap;
}
.turbo-option--recommended {
  border-color: rgba(96,160,255,0.25);
  background: rgba(96,160,255,0.06);
}
.turbo-option--recommended:hover {
  border-color: var(--accent);
  background: rgba(96,160,255,0.1);
  box-shadow: 0 2px 12px rgba(96,160,255,0.15);
}
.turbo-topup-btn {
  width: 100%; padding: 11px; border: none; border-radius: 10px;
  background: linear-gradient(135deg, var(--accent), #a855f7);
  color: #fff; font-family: var(--heading-font);
  font-size: 0.95rem; letter-spacing: 0.5px; text-transform: uppercase;
  cursor: pointer; transition: all 0.2s ease;
  position: relative; overflow: hidden;
}
.turbo-topup-btn::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.12), transparent);
  opacity: 0; transition: opacity 0.2s;
}
.turbo-topup-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(96,160,255,0.25), 0 2px 8px rgba(168,85,247,0.15);
}
.turbo-topup-btn:hover::after { opacity: 1; }
.turbo-topup-btn:active { transform: translateY(0) scale(0.98); }

/* === Auth Modal === */
.turbo-modal-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.55);
  display: none; align-items: center; justify-content: center;
  z-index: 500;
  backdrop-filter: blur(12px) saturate(0.8);
  -webkit-backdrop-filter: blur(12px) saturate(0.8);
}
.turbo-modal-overlay.open { display: flex; }
.turbo-modal {
  background: var(--bg);
  border: 1px solid transparent;
  border-radius: 20px; padding: 2.25rem 2rem 2rem;
  max-width: 420px; width: 92%;
  position: relative;
  animation: modal-in 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow:
    0 24px 80px rgba(0,0,0,0.4),
    0 0 0 1px rgba(96,160,255,0.1),
    0 0 60px rgba(96,160,255,0.06),
    0 0 120px rgba(168,85,247,0.04);
}
/* Gradient border effect via background-clip */
.turbo-modal::before {
  content: ''; position: absolute; inset: -1px;
  border-radius: 21px; padding: 1px;
  background: linear-gradient(160deg, rgba(96,160,255,0.35), rgba(168,85,247,0.2), rgba(96,160,255,0.1));
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}
@keyframes modal-in {
  from { opacity: 0; transform: scale(0.92) translateY(10px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}
.turbo-modal-close {
  position: absolute; top: 14px; right: 18px;
  background: none; border: none; color: var(--text-dim);
  font-size: 1.5rem; cursor: pointer; line-height: 1;
  width: 32px; height: 32px; border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  transition: all 0.15s;
}
.turbo-modal-close:hover {
  color: var(--text); background: var(--accent-dim);
}
/* Modal header with bolt icon */
.turbo-modal-header-icon {
  display: flex; align-items: center; justify-content: center;
  width: 48px; height: 48px; margin: 0 auto 12px;
  background: linear-gradient(135deg, rgba(96,160,255,0.12), rgba(168,85,247,0.12));
  border-radius: 14px; font-size: 1.5rem;
  box-shadow: 0 0 24px rgba(96,160,255,0.1);
}
.turbo-modal-title {
  font-family: var(--heading-font); font-size: 1.35rem;
  margin-bottom: 0.5rem; text-align: center;
  font-weight: 600; letter-spacing: 0.3px;
}
.turbo-modal-subtitle {
  text-align: center; color: var(--text-dim); font-size: 0.82rem;
  margin-bottom: 1.5rem; line-height: 1.4;
}

/* Auth buttons */
.turbo-auth-buttons { display: flex; flex-direction: column; gap: 10px; }
.turbo-auth-btn {
  display: flex; align-items: center; gap: 12px;
  width: 100%; padding: 13px 16px; border-radius: 12px;
  font-family: var(--body-font); font-size: 0.9rem; font-weight: 500;
  cursor: pointer; transition: all 0.2s ease;
  border: 1px solid var(--border); position: relative;
  background: var(--surface); color: var(--text);
}
.turbo-auth-btn:hover {
  border-color: rgba(96,160,255,0.4);
  background: var(--accent-dim);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}
.turbo-auth-btn:active { transform: translateY(0) scale(0.99); }
.turbo-auth-btn svg { flex-shrink: 0; }

/* "3 free boosts" banner — shared incentive above all auth methods */
.turbo-auth-bonus {
  font-size: 0.75rem;
  font-family: var(--heading-font); font-weight: 600;
  letter-spacing: 0.4px; text-transform: uppercase;
  text-align: center;
  background: linear-gradient(135deg, rgba(96,160,255,0.15), rgba(168,85,247,0.15));
  color: var(--accent);
  padding: 0.5rem 1rem; border-radius: 999px;
  border: 1px solid rgba(96,160,255,0.2);
  margin-bottom: 1rem;
  animation: turbo-badge-glow 3s ease-in-out infinite;
}
@keyframes turbo-badge-glow {
  0%, 100% { box-shadow: 0 0 8px rgba(96,160,255,0.1); }
  50% { box-shadow: 0 0 16px rgba(96,160,255,0.2), 0 0 4px rgba(168,85,247,0.1); }
}

/* Divider */
.turbo-auth-divider {
  display: flex; align-items: center; gap: 12px;
  margin: 18px 0; color: var(--text-muted); font-size: 0.78rem;
  text-transform: uppercase; letter-spacing: 0.5px;
  font-family: var(--heading-font);
}
.turbo-auth-divider::before, .turbo-auth-divider::after {
  content: ''; flex: 1; height: 1px;
  background: linear-gradient(90deg, transparent, var(--border), transparent);
}

/* Email input */
.turbo-auth-email { display: flex; flex-direction: column; gap: 10px; }
.turbo-auth-input {
  width: 100%; padding: 13px 16px; border-radius: 12px;
  border: 1px solid var(--border); background: var(--surface);
  color: var(--text); font-family: var(--body-font); font-size: 0.9rem;
  outline: none; transition: all 0.2s ease; box-sizing: border-box;
}
.turbo-auth-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-dim), 0 0 12px rgba(96,160,255,0.06);
}
.turbo-auth-input::placeholder { color: var(--text-muted); }
.turbo-auth-send {
  background: linear-gradient(135deg, var(--accent), #7c6bff);
  color: #fff; border: none; font-weight: 500;
  box-shadow: 0 2px 8px rgba(96,160,255,0.2);
}
.turbo-auth-send:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(96,160,255,0.3);
}
.turbo-auth-send:active { transform: translateY(0) scale(0.98); }

/* Footer */
.turbo-auth-footer {
  text-align: center; color: var(--text-muted); font-size: 0.78rem;
  margin-top: 18px; display: flex; align-items: center;
  justify-content: center; gap: 6px;
}
.turbo-auth-footer-lock {
  display: inline-flex; opacity: 0.5;
}

/* === Light theme overrides === */
[data-theme="light"] .turbo-btn {
  background: linear-gradient(135deg, rgba(79,70,229,0.06), rgba(168,85,247,0.04));
  border-color: rgba(79,70,229,0.3);
}
[data-theme="light"] .turbo-btn:hover {
  border-color: rgba(79,70,229,0.5);
  box-shadow: 0 0 16px rgba(79,70,229,0.1);
}
[data-theme="light"] .turbo-btn.turbo-active {
  background: linear-gradient(135deg, var(--accent), #7c3aed);
  box-shadow: 0 0 20px rgba(79,70,229,0.2);
}
[data-theme="light"] .turbo-dropdown {
  box-shadow: 0 8px 32px rgba(0,0,0,0.08), 0 0 0 1px rgba(79,70,229,0.06);
}
[data-theme="light"] .turbo-dropdown::before {
  background: linear-gradient(90deg, var(--accent), #7c3aed, var(--accent));
  background-size: 200% 100%;
}
[data-theme="light"] .turbo-modal {
  box-shadow:
    0 24px 80px rgba(0,0,0,0.1),
    0 0 0 1px rgba(79,70,229,0.08),
    0 0 40px rgba(79,70,229,0.04);
}
[data-theme="light"] .turbo-modal::before {
  background: linear-gradient(160deg, rgba(79,70,229,0.25), rgba(168,85,247,0.15), rgba(79,70,229,0.08));
}
[data-theme="light"] .turbo-auth-bonus {
  background: linear-gradient(135deg, rgba(79,70,229,0.1), rgba(124,59,237,0.1));
  border-color: rgba(79,70,229,0.2);
}
[data-theme="light"] .turbo-auth-send {
  background: linear-gradient(135deg, var(--accent), #7c3aed);
}
[data-theme="light"] .turbo-topup-btn {
  background: linear-gradient(135deg, var(--accent), #7c3aed);
}

/* === Turbo Nudge === */
.turbo-nudge {
  position: fixed; inset: 0; z-index: 400;
  display: flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,0.6); backdrop-filter: blur(4px);
}
.turbo-nudge.hidden { display: none; }
.turbo-nudge-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 12px; padding: 1.5rem; max-width: 380px; width: 90vw;
  animation: modal-in 0.2s ease-out;
}
.turbo-nudge-header {
  display: flex; align-items: center; gap: 8px; margin-bottom: 1rem;
}
.turbo-nudge-indicator {
  width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0;
}
.turbo-cap-green  { background: #22c55e; box-shadow: 0 0 6px rgba(34,197,94,0.4); }
.turbo-cap-yellow { background: #eab308; box-shadow: 0 0 6px rgba(234,179,8,0.4); }
.turbo-cap-red    { background: #ef4444; box-shadow: 0 0 6px rgba(239,68,68,0.4); }
.turbo-nudge-title {
  font-family: var(--heading-font); font-size: 1rem; font-weight: 600;
}
.turbo-nudge-comparison {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 10px; margin-bottom: 1.25rem;
}
.turbo-nudge-eta {
  display: flex; flex-direction: column; align-items: center;
  padding: 12px 8px; border-radius: 8px; border: 1px solid var(--border);
}
.turbo-nudge-server {
  border-color: var(--accent); background: rgba(96,160,255,0.05);
}
.turbo-nudge-label {
  font-size: 0.75rem; color: var(--text-dim); margin-bottom: 4px;
}
.turbo-nudge-time {
  font-family: var(--mono-font); font-size: 1.1rem; font-weight: 600;
}
.turbo-nudge-server .turbo-nudge-time { color: var(--accent); }
.turbo-nudge-actions { display: flex; gap: 8px; }
.turbo-nudge-actions .btn { flex: 1; padding: 10px 12px; font-size: 0.85rem; }
.turbo-nudge-blocked {
  text-align: center; font-size: 0.8rem; color: var(--text-dim); margin-bottom: 1rem;
}
.turbo-nudge-badge {
  font-size: 0.65rem; font-weight: 600; color: var(--accent);
  margin-top: 4px; letter-spacing: 0.5px;
}
.turbo-cap-yellow, .turbo-cap-red {
  animation: turbo-pulse 2s ease-in-out infinite;
}
@keyframes turbo-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

/* Turbo progress overlay — shown during server-side processing */
/* Old turbo-progress-overlay removed — all progress uses inline ProcessingTracker waveform UI */

/* ── Choice screen — browser vs turbo two-card choice ──────────────── */
.turbo-choice-overlay {
  position: fixed; inset: 0; z-index: 400;
  display: flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,0.6); backdrop-filter: blur(4px);
}
.turbo-choice-overlay.hidden { display: none; }
.turbo-choice-container {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 16px; padding: 2rem; max-width: 520px; width: 92vw;
  animation: modal-in 0.2s ease-out;
}
.turbo-choice-heading {
  text-align: center; font-family: var(--heading-font);
  font-size: 1.1rem; font-weight: 600; margin: 0 0 1.25rem;
}
.turbo-choice-cards {
  display: grid; grid-template-columns: 1fr 1fr; gap: 12px;
}
.turbo-choice-card {
  display: flex; flex-direction: column; align-items: center;
  padding: 1.25rem 1rem; border-radius: 12px;
  border: 1px solid var(--border); text-align: center;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.turbo-choice-card:hover {
  border-color: var(--text-dim);
}
.turbo-choice-accent {
  border-color: var(--accent);
  background: rgba(96,160,255,0.04);
}
.turbo-choice-accent:hover {
  border-color: var(--accent);
  box-shadow: 0 0 12px rgba(96,160,255,0.15);
}
.choice-card-disabled {
  opacity: 0.4; pointer-events: none;
}
.choice-card-icon {
  font-size: 1.8rem; margin-bottom: 0.5rem;
}
.choice-card-title {
  font-family: var(--heading-font); font-size: 0.95rem;
  font-weight: 600; margin-bottom: 0.5rem;
}
.choice-card-eta {
  font-family: var(--mono-font); font-size: 0.85rem;
  color: var(--text-dim); margin-bottom: 0.5rem; min-height: 1.2em;
}
.choice-card-privacy {
  font-size: 0.72rem; color: var(--text-dim);
  margin-bottom: 0.75rem; line-height: 1.3;
}
.choice-card-btn {
  width: 100%; padding: 8px 12px; font-size: 0.85rem;
  margin-top: auto;
}
.turbo-choice-warning {
  text-align: center; font-size: 0.78rem; color: #eab308;
  margin-top: 1rem; padding: 0.5rem; border-radius: 6px;
  background: rgba(234,179,8,0.08);
}
.turbo-choice-warning.hidden { display: none; }
@media (max-width: 480px) {
  .turbo-choice-cards { grid-template-columns: 1fr; }
}

/* ── Processing mode badge ─────────────────────────────────────────── */
.processing-badge {
  display: flex; align-items: center; gap: 0.5rem;
  padding: 0.5rem 1rem; border-radius: 8px;
  font-size: 0.85rem; margin-bottom: 0.75rem;
  transition: all 0.3s ease;
}
.processing-badge.hidden { display: none; }
.badge-local {
  background: rgba(34,197,94,0.1);
  border: 1px solid rgba(34,197,94,0.3);
  color: #22c55e;
}
.badge-turbo {
  background: rgba(96,160,255,0.1);
  border: 1px solid rgba(96,160,255,0.3);
  color: var(--accent);
}
.badge-sub {
  font-size: 0.75rem; opacity: 0.7; margin-left: auto;
}
[data-theme="light"] .badge-local { background: rgba(34,197,94,0.08); color: #16a34a; }
[data-theme="light"] .badge-turbo { background: rgba(79,70,229,0.08); color: var(--accent); }

/* ── Escape hatch — switch to turbo mid-processing ─────────────────── */
.escape-hatch {
  text-align: center; margin-top: 0.75rem;
  transition: opacity 0.3s ease;
}
.escape-hatch.hidden { display: none; }
.escape-hatch-btn {
  background: transparent; border: 1px solid var(--accent);
  color: var(--accent); padding: 0.4rem 1rem; border-radius: 6px;
  cursor: pointer; font-size: 0.85rem; transition: all 0.2s ease;
}
.escape-hatch-btn:hover {
  background: rgba(96,160,255,0.1);
}

/* ── Mashup Maker ──────────────────────────────────────────────────── */
.mashup-drop { min-height: 160px; display: flex; align-items: center; justify-content: center; }

.mashup-fader-col {
    display: flex; flex-direction: column; align-items: center; gap: 0.5rem;
    padding: 1rem; background: var(--bg-deep); border-radius: 8px;
}
.mashup-fader {
    writing-mode: vertical-lr;
    direction: rtl;
    height: 120px; width: 32px;
    accent-color: var(--accent);
}

.badge { padding: 0.2rem 0.5rem; border-radius: 6px; font-size: 0.75rem; background: var(--bg-deep); }
.badge-green { background: rgba(34,197,94,0.12); color: #22c55e; border: 1px solid rgba(34,197,94,0.3); }
.badge-yellow { background: rgba(234,179,8,0.12); color: #eab308; border: 1px solid rgba(234,179,8,0.3); }
.badge-red { background: rgba(239,68,68,0.12); color: #ef4444; border: 1px solid rgba(239,68,68,0.3); }

.modal-overlay {
    position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.6); z-index: 1000;
    display: flex; align-items: center; justify-content: center;
}
.modal-overlay.hidden { display: none; }
.modal-content {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: 12px; padding: 1.5rem; max-width: 90vw;
}

@media (max-width: 640px) {
    .mashup-faders { grid-template-columns: repeat(2, 1fr) !important; }
    .mashup-fader { height: 80px; }
}

/* Lossless Checker */
.spectrogram-wrap {
    margin: 1.5rem 0 1rem;
    border-radius: var(--radius);
    overflow: hidden;
    background: #000;
}
#spectrogram-canvas {
    display: block;
    width: 100%;
    height: auto;
}
.lossless-result-panel {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1rem;
    padding: 1rem 0;
}
/* JS sets className = 'verdict verdict-{clean|transcoded|...}' */
.verdict,
.verdict-badge {
    display: inline-block;
    padding: 0.4rem 1.2rem;
    border-radius: var(--radius);
    font-family: var(--font-heading);
    font-size: 1.3rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}
.verdict-clean      { background: #16a34a; color: #fff; }
.verdict-transcoded { background: #dc2626; color: #fff; }
.verdict-upsampled  { background: #ea580c; color: #fff; }
.verdict-upscaled   { background: #ea580c; color: #fff; }
.verdict-unknown    { background: var(--bg-card); color: var(--text-muted); }
/* Metadata panel uses <dl> with <dt>/<dd> pairs */
.file-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 1.5rem;
}
.file-meta dt {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}
.file-meta dd {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--text-primary);
    margin: 0 0 0.25rem;
}
.meta-line {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--text-muted);
}
/* Spectrogram reading guide — reuses faq-item styling */
.content-section {
    max-width: 720px;
    margin: 3rem auto 0;
    padding: 2rem 0 0;
}
.content-section h2 {
    font-family: var(--heading-font);
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 0.5rem;
}
.content-section > p {
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 1rem;
}
.content-section table {
    border-collapse: collapse;
    font-size: 0.8rem;
}
.content-section th {
    border-bottom: 1px solid var(--border);
    font-weight: 600;
    color: var(--text);
}
.content-section td {
    border-bottom: 1px solid var(--border-subtle, rgba(255,255,255,0.05));
    color: var(--text-muted);
}

/* -- Stem Player --------------------------------------------------------- */
:root {
  --stem-vocals: #c9a0ff;
  --stem-instrumental: #50d890;
}
[data-theme="light"] {
  --stem-vocals: #7c4dff;
  --stem-instrumental: #2e7d32;
}

.stem-player {
  background: var(--surface);
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid rgba(96, 160, 255, 0.1);
}

.stem-row {
  display: grid;
  grid-template-columns: 36px 88px 1fr 100px 36px;
  gap: 10px;
  align-items: center;
  height: 56px;
  padding: 0 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.stem-row:last-of-type {
  border-bottom: none;
}

.stem-mute-btn {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1px solid color-mix(in srgb, var(--stem-color) 30%, transparent);
  background: color-mix(in srgb, var(--stem-color) 15%, transparent);
  color: var(--stem-color);
  font-size: 11px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  line-height: 1;
}
.stem-mute-btn:hover {
  background: color-mix(in srgb, var(--stem-color) 25%, transparent);
}
.stem-mute-btn.muted {
  opacity: 0.4;
}

.stem-label {
  font-weight: 600;
  font-size: 0.75rem;
  letter-spacing: 0.02em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.stem-wave-wrap {
  height: 40px;
  border-radius: 5px;
  position: relative;
  overflow: hidden;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.02);
}

.stem-wave {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  display: block;
}

.stem-vol {
  width: 90px;
  cursor: pointer;
}

.stem-download {
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  color: var(--text-muted);
  text-decoration: none;
  border-radius: 6px;
}
.stem-download:hover {
  color: var(--accent);
  background: rgba(96, 160, 255, 0.1);
}

.stem-transport {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 12px;
  background: rgba(0, 0, 0, 0.2);
  border-top: 1px solid rgba(255, 255, 255, 0.04);
}

.stem-transport-btn {
  width: 28px;
  height: 28px;
  background: var(--accent);
  border: none;
  border-radius: 50%;
  color: var(--bg-deep);
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  line-height: 1;
}
.stem-transport-btn:hover {
  filter: brightness(1.15);
}

.stem-time {
  font-size: 0.7rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
  min-width: 80px;
}

.stem-filename {
  flex: 1;
  text-align: right;
  font-size: 0.65rem;
  color: var(--text-dim);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (max-width: 600px) {
  .stem-row {
    grid-template-columns: 36px 1fr 36px;
    grid-template-rows: auto auto;
    height: auto;
    padding: 8px 12px;
    gap: 6px;
  }
  .stem-label {
    grid-column: 2;
  }
  .stem-wave-wrap {
    grid-column: 1 / -1;
    height: 36px;
  }
  .stem-vol {
    grid-column: 1 / -1;
    width: 100%;
  }
}

/* ── Trust badges ─────────────────────────────────────────── */
.upload-trust-badge{text-align:center;font-size:.72rem;color:var(--text-dim);margin-top:.5rem}
.trust-badge-main{display:flex;align-items:center;justify-content:center;gap:.25rem}
.trust-badge-main svg{flex-shrink:0}
.trust-badge-device{font-size:.65rem;color:var(--text-muted);margin-top:.15rem}
.processing-trust-badge{display:flex;align-items:center;justify-content:center;gap:.25rem;font-size:.7rem;color:var(--text-dim);margin-top:.5rem}

/* ── Cloud confirm dialog ─────────────────────────────────── */
.cloud-confirm-overlay{position:fixed;inset:0;z-index:9999;background:rgba(0,0,0,.6);display:flex;align-items:center;justify-content:center;backdrop-filter:blur(4px)}
.cloud-confirm-modal{background:var(--bg-card);border:1px solid var(--border);border-radius:1rem;padding:1.5rem 2rem;max-width:380px;width:90%;text-align:center}
.cloud-confirm-modal h3{margin:0 0 .75rem;font-size:1.1rem}
.cloud-confirm-modal p{margin:0 0 1.25rem;font-size:.85rem;color:var(--text-muted);line-height:1.5}
.cloud-confirm-actions{display:flex;gap:.75rem;justify-content:center}

/* ── Processing router — override modal ───────────────────── */
.override-modal-overlay{position:fixed;inset:0;z-index:1000;background:rgba(0,0,0,.6);backdrop-filter:blur(4px);display:flex;align-items:center;justify-content:center}
.override-modal-overlay.hidden{display:none}
.override-modal{background:var(--bg-card);border-radius:12px;padding:1.5rem;max-width:400px;width:90%;box-shadow:0 8px 32px rgba(0,0,0,.3)}
.override-modal h3{margin:0 0 .5rem}
.override-modal p{color:var(--text-muted);font-size:.85rem;margin-bottom:1rem}
.override-btn{display:flex;flex-direction:column;width:100%;text-align:left;padding:.75rem 1rem;margin-bottom:.5rem;border-radius:8px;border:1px solid var(--border);background:transparent;cursor:pointer;color:var(--text);font-size:.9rem}
.override-btn:hover{border-color:var(--accent)}
.override-active{border-color:var(--accent);background:rgba(96,160,255,.08)}
.override-sub{font-size:.75rem;color:var(--text-dim);margin-top:.25rem}
.override-premium{opacity:.7}

/* Clickable trust badge */
.badge-clickable{cursor:pointer}
.badge-clickable:hover .trust-badge-main{color:var(--accent)}

.track-badge{display:inline-block;padding:2px 8px;border-radius:99px;font-size:.75rem;font-weight:500;background:rgba(96,160,255,.12);color:var(--accent,#60a0ff);font-family:var(--font-mono,'DM Mono',monospace);white-space:nowrap}

/* ── Track Shelf ──────────────────────────────────────────────────────── */
.track-shelf{position:relative;display:inline-block}
.track-shelf[hidden]{display:none}
.track-shelf-btn{display:flex;align-items:center;gap:6px;background:rgba(96,160,255,.12);border:1px solid rgba(96,160,255,.2);border-radius:8px;padding:5px 12px;color:#60a0ff;font-weight:600;font-size:12px;cursor:pointer;font-family:inherit;transition:border-color .2s}
.track-shelf-btn:hover{border-color:rgba(96,160,255,.4)}
.track-shelf-icon{font-size:14px}
.track-shelf-count{background:#60a0ff;color:#fff;border-radius:99px;padding:1px 7px;font-size:10px;font-weight:700;min-width:16px;text-align:center}
.track-shelf-dropdown{position:absolute;right:0;top:calc(100% + 8px);width:300px;background:#111130;border:1px solid rgba(96,160,255,.15);border-radius:12px;overflow:hidden;box-shadow:0 12px 32px rgba(0,0,0,.5);z-index:200;animation:trackShelfIn .2s ease}
.track-shelf-header{padding:8px 14px;color:#888;font-size:10px;text-transform:uppercase;letter-spacing:1px;font-weight:600}
.track-shelf-card{padding:10px 14px;border-bottom:1px solid rgba(255,255,255,.04);cursor:pointer;display:flex;align-items:center;gap:10px;transition:background .15s}
.track-shelf-card:hover{background:rgba(96,160,255,.06)}
.track-shelf-card--active{background:rgba(96,160,255,.06)}
.track-shelf-card--expired{opacity:.5}
.track-shelf-avatar{width:32px;height:32px;border-radius:6px;display:flex;align-items:center;justify-content:center;flex-shrink:0;color:#fff;font-size:14px}
.track-shelf-card-info{flex:1;min-width:0}
.track-shelf-card-name{color:#eee;font-weight:600;font-size:13px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.track-shelf-card-duration{color:#555;font-size:10px;font-weight:400;margin-left:6px}
.track-shelf-card-badges{display:flex;gap:4px;margin-top:3px;flex-wrap:wrap}
.track-badge--turbo{background:rgba(168,85,247,.12);color:#a855f7}
.track-shelf-empty{padding:16px 14px;text-align:center;color:#555;font-size:12px;font-style:italic}
.track-shelf-footer{padding:8px 14px;background:rgba(255,255,255,.02);text-align:center;border-top:1px solid rgba(255,255,255,.04)}
.track-shelf-footer a{color:#60a0ff;text-decoration:none;font-size:11px;font-weight:500}
.track-shelf-footer a:hover{text-decoration:underline}
@keyframes trackShelfIn{from{opacity:0;transform:translateY(-4px)}to{opacity:1;transform:translateY(0)}}
@media(max-width:640px){.track-shelf-label{display:none}.track-shelf-dropdown{width:90vw;right:-40px}}
[data-theme="light"] .track-shelf-btn{background:rgba(79,70,229,.08);border-color:rgba(79,70,229,.15);color:#4f46e5}
[data-theme="light"] .track-shelf-count{background:#4f46e5}
[data-theme="light"] .track-shelf-dropdown{background:rgba(255,255,255,.95);border-color:rgba(79,70,229,.15);box-shadow:0 8px 24px rgba(0,0,0,.1)}
[data-theme="light"] .track-shelf-card:hover{background:rgba(79,70,229,.04)}
[data-theme="light"] .track-shelf-card--active{background:rgba(79,70,229,.06)}
[data-theme="light"] .track-shelf-card-name{color:#1a1a2e}
[data-theme="light"] .track-badge--turbo{background:rgba(168,85,247,.08);color:#7c3aed}
