/* ==========================================================================
   KAIonChord – Premium Dark Luxury UI
   KAIonAI brand: navy #1d3557 · red #e63946 · gold #f4a261
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;600;700&family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;0,9..40,600;0,9..40,700;1,9..40,400&display=swap');

/* ---------- Variables ---------- */
:root {
    --navy: #1d3557;
    --red: #e63946;
    --red-glow: rgba(230, 57, 70, 0.45);
    --red-soft: rgba(230, 57, 70, 0.15);
    --gold: #f4a261;
    --bg: #08080f;
    --glass: rgba(255, 255, 255, 0.05);
    --glass-card: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.1);
    --text: #f0f0f0;
    --text-dim: rgba(240, 240, 240, 0.6);
    --text-faint: rgba(240, 240, 240, 0.35);
    --font-display: 'Space Grotesk', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-body: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    --transition: 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    --radius: 18px;
    --radius-sm: 10px;
}

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

html {
    scroll-behavior: smooth;
}

body {
    background: var(--bg);
    color: var(--text);
    font-family: var(--font-body);
    font-weight: 400;
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    cursor: none; /* custom cursor */
}

a, button, input, [role="button"] {
    cursor: none;
}

::selection {
    background: var(--red);
    color: #fff;
}

/* ---------- Custom Scrollbar ---------- */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}
::-webkit-scrollbar-track {
    background: var(--bg);
}
::-webkit-scrollbar-thumb {
    background: var(--red);
    border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
    background: #ff4d5a;
}
* {
    scrollbar-width: thin;
    scrollbar-color: var(--red) var(--bg);
}

/* ==========================================================================
   Custom Cursor
   ========================================================================== */
.cursor-dot,
.cursor-ring {
    position: fixed;
    top: 0;
    left: 0;
    pointer-events: none;
    border-radius: 50%;
    z-index: 10000;
    transform: translate(-50%, -50%);
    mix-blend-mode: screen;
}

.cursor-dot {
    width: 20px;
    height: 20px;
    background: radial-gradient(circle, rgba(230, 57, 70, 0.9) 0%, rgba(230, 57, 70, 0.35) 60%, transparent 100%);
    box-shadow: 0 0 12px var(--red-glow), 0 0 30px rgba(230, 57, 70, 0.3);
    transition: opacity 0.2s ease;
}

.cursor-ring {
    width: 40px;
    height: 40px;
    border: 1.5px solid rgba(230, 57, 70, 0.6);
    box-shadow: 0 0 18px rgba(230, 57, 70, 0.25), inset 0 0 12px rgba(230, 57, 70, 0.12);
    transition: width 0.25s ease, height 0.25s ease, border-color 0.25s ease, opacity 0.2s ease;
}

body.cursor-hover .cursor-ring {
    width: 58px;
    height: 58px;
    border-color: var(--gold);
}

@media (hover: none), (pointer: coarse) {
    .cursor-dot, .cursor-ring { display: none; }
    body, a, button, input, [role="button"] { cursor: auto; }
}

/* ==========================================================================
   Backgrounds: Particles + Animated Gradient
   ========================================================================== */
#particle-canvas {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
}

.bg-gradient {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
    background:
        radial-gradient(ellipse 50% 40% at 8% 96%, rgba(230, 57, 70, 0.13) 0%, transparent 65%),
        radial-gradient(ellipse 60% 50% at 90% 80%, rgba(29, 53, 87, 0.35) 0%, transparent 70%),
        var(--bg);
}

/* Slowly drifting navy radial glow (15s loop) */
.bg-gradient::before {
    content: "";
    position: absolute;
    inset: -35%;
    background: radial-gradient(circle at 40% 30%, rgba(29, 53, 87, 0.55) 0%, transparent 50%);
    animation: gradientDrift 15s ease-in-out infinite;
    will-change: transform;
}

@keyframes gradientDrift {
    0%   { transform: translate(-6%, -4%) scale(1); }
    25%  { transform: translate(5%, 3%) scale(1.06); }
    50%  { transform: translate(9%, -3%) scale(1.1); }
    75%  { transform: translate(2%, 5%) scale(1.04); }
    100% { transform: translate(-6%, -4%) scale(1); }
}

/* Everything content sits above canvas */
.nav, .hero, main, .footer {
    position: relative;
    z-index: 2;
}

/* ==========================================================================
   Navigation
   ========================================================================== */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    background: rgba(8, 8, 15, 0.35);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: background var(--transition), border-color var(--transition);
}

.nav.scrolled {
    background: rgba(8, 8, 15, 0.85);
    border-bottom-color: var(--glass-border);
}

.nav-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 16px 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: var(--text);
}

.nav-logo {
    width: 46px;
    height: 46px;
    object-fit: contain;
    filter: drop-shadow(0 0 8px rgba(230, 57, 70, 0.35));
    transition: filter 0.3s ease, transform 0.3s ease;
    flex-shrink: 0;
}
.nav-brand:hover .nav-logo {
    filter: drop-shadow(0 0 14px rgba(230, 57, 70, 0.65));
    transform: rotate(-6deg) scale(1.08);
}

.nav-brand-text {
    display: flex;
    flex-direction: column;
    gap: 0;
    line-height: 1.1;
}

.brand-product {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 1.05rem;
    letter-spacing: 0.04em;
    color: var(--text);
}

.brand-domain {
    font-family: var(--font-body);
    font-size: 0.65rem;
    letter-spacing: 0.12em;
    color: var(--red);
    text-transform: uppercase;
    opacity: 0.8;
}

.brand-on {
    color: var(--red);
    font-style: italic;
    font-weight: 500;
}

.brand-sep {
    width: 1px;
    height: 20px;
    background: var(--glass-border);
}

.brand-product {
    font-family: var(--font-display);
    font-size: 1.2rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    background: linear-gradient(120deg, var(--text) 40%, var(--gold));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 16px;
}

.tier-badge {
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    padding: 6px 14px;
    border-radius: 999px;
    border: 1px solid var(--glass-border);
    background: var(--glass);
    color: var(--text-dim);
    transition: all var(--transition);
}

.tier-badge.premium {
    color: var(--gold);
    border-color: rgba(244, 162, 97, 0.5);
    background: rgba(244, 162, 97, 0.08);
    box-shadow: 0 0 18px rgba(244, 162, 97, 0.25);
}

.tier-badge.beta {
    color: #4ade80;
    border-color: rgba(74, 222, 128, 0.45);
    background: rgba(74, 222, 128, 0.08);
    box-shadow: 0 0 18px rgba(74, 222, 128, 0.2);
    animation: beta-pulse 2.5s ease-in-out infinite;
}

@keyframes beta-pulse {
    0%, 100% { box-shadow: 0 0 12px rgba(74, 222, 128, 0.2); }
    50%       { box-shadow: 0 0 28px rgba(74, 222, 128, 0.45); }
}

.btn-beta {
    background: linear-gradient(135deg, #22c55e, #16a34a) !important;
    color: #fff !important;
    pointer-events: auto;
}

/* ==========================================================================
   Beta Banner
   ========================================================================== */
.beta-banner {
    width: 100%;
    background: linear-gradient(90deg, rgba(34,197,94,0.18) 0%, rgba(20,184,166,0.14) 100%);
    border-bottom: 1px solid rgba(74, 222, 128, 0.25);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 10px 24px;
    position: relative;
    z-index: 200;
    overflow: hidden;
}

.beta-banner-text {
    font-size: 0.82rem;
    color: rgba(255,255,255,0.88);
    text-align: center;
    line-height: 1.5;
    font-family: var(--font-body);
}

.beta-banner-text strong {
    color: #4ade80;
}

.beta-banner-close {
    background: none;
    border: none;
    color: rgba(255,255,255,0.45);
    cursor: pointer;
    font-size: 0.85rem;
    padding: 4px 8px;
    border-radius: 4px;
    flex-shrink: 0;
    transition: color 0.2s;
    position: absolute;
    right: 16px;
}

.beta-banner-close:hover {
    color: rgba(255,255,255,0.9);
}

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-family: var(--font-body);
    font-size: 0.92rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    padding: 13px 30px;
    border-radius: 999px;
    border: none;
    text-decoration: none;
    transition: all var(--transition);
    will-change: transform;
}

.btn-primary {
    background: linear-gradient(135deg, var(--red) 0%, #c1121f 100%);
    color: #fff;
    box-shadow: 0 4px 20px rgba(230, 57, 70, 0.35);
}

.btn-primary:hover {
    transform: scale(1.05);
    box-shadow: 0 0 30px var(--red-glow), 0 8px 40px rgba(230, 57, 70, 0.45);
}

.btn-primary:active {
    transform: scale(0.98);
}

.btn-primary:disabled {
    opacity: 0.5;
    transform: none;
    box-shadow: none;
}

.btn-ghost {
    background: var(--glass);
    color: var(--text);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.btn-ghost:hover {
    transform: scale(1.05);
    border-color: rgba(230, 57, 70, 0.5);
    box-shadow: 0 0 24px rgba(230, 57, 70, 0.2);
}

.btn-lg {
    padding: 16px 40px;
    font-size: 1rem;
}

.btn-sm {
    padding: 9px 20px;
    font-size: 0.8rem;
}

.btn-nav {
    padding: 10px 24px;
    font-size: 0.82rem;
}

.btn-block {
    width: 100%;
}

.btn-link {
    background: none;
    border: none;
    color: var(--gold);
    font-family: var(--font-body);
    font-size: inherit;
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 3px;
    transition: color var(--transition);
}

.btn-link:hover {
    color: #ffc38a;
}

/* ==========================================================================
   Hero
   ========================================================================== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 120px 24px 80px;
    position: relative;
    overflow: hidden;
    background-image:
        linear-gradient(to bottom, rgba(8,8,15,0.75) 0%, rgba(8,8,15,0.55) 40%, rgba(8,8,15,0.80) 100%),
        url('/static/img/hero-bg.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.hero-layer {
    position: absolute;
    inset: 0;
    pointer-events: none;
    will-change: transform;
}

.glow-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(90px);
}

.glow-orb-red {
    width: 480px;
    height: 480px;
    bottom: -180px;
    left: -140px;
    background: radial-gradient(circle, rgba(230, 57, 70, 0.22) 0%, transparent 70%);
}

.glow-orb-navy {
    width: 640px;
    height: 640px;
    top: -220px;
    right: -180px;
    background: radial-gradient(circle, rgba(29, 53, 87, 0.6) 0%, transparent 70%);
}

/* Floating chord symbols */
.floating-chord {
    position: absolute;
    font-family: var(--font-display);
    font-style: italic;
    font-weight: 500;
    color: rgba(240, 240, 240, 0.1);
    text-shadow: 0 0 30px rgba(230, 57, 70, 0.15);
    will-change: transform;
    user-select: none;
    animation: chordFloat 8s ease-in-out infinite;
}

.fc-1 { top: 22%; left: 12%; font-size: 4.2rem; animation-delay: 0s; color: rgba(230, 57, 70, 0.13); }
.fc-2 { top: 30%; right: 14%; font-size: 3.2rem; animation-delay: -2.5s; }
.fc-3 { bottom: 26%; left: 20%; font-size: 5rem; animation-delay: -5s; }
.fc-4 { bottom: 20%; right: 18%; font-size: 2.8rem; animation-delay: -3.5s; color: rgba(244, 162, 97, 0.12); }

@keyframes chordFloat {
    0%, 100% { margin-top: 0; }
    50% { margin-top: -22px; }
}

.hero-content {
    max-width: 860px;
    will-change: transform;
}

.hero-eyebrow {
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 26px;
}

.hero-headline {
    font-family: var(--font-display);
    font-size: clamp(3rem, 7.5vw, 5.6rem);
    font-weight: 700;
    line-height: 1.08;
    letter-spacing: -0.015em;
    margin-bottom: 26px;
    text-shadow: 0 10px 60px rgba(0, 0, 0, 0.6);
}

.hero-headline .accent {
    color: var(--red);
    text-shadow: 0 0 50px var(--red-glow);
}

.hero-subline {
    font-size: clamp(1.05rem, 2vw, 1.3rem);
    font-weight: 300;
    color: var(--text-dim);
    max-width: 560px;
    margin: 0 auto 34px;
}

/* Sound wave SVG */
.soundwave-wrap {
    max-width: 520px;
    margin: 0 auto 40px;
}

.soundwave {
    width: 100%;
    height: 56px;
    display: block;
}

.soundwave-path {
    fill: none;
    stroke: var(--red);
    stroke-width: 2;
    opacity: 0.4;
    stroke-linecap: round;
    stroke-dasharray: 30 14;
    animation: waveFlow 3s linear infinite;
    filter: drop-shadow(0 0 6px rgba(230, 57, 70, 0.5));
}

@keyframes waveFlow {
    from { stroke-dashoffset: 0; }
    to   { stroke-dashoffset: -176; }
}

.hero-cta {
    display: flex;
    gap: 18px;
    justify-content: center;
    flex-wrap: wrap;
}

/* Scroll indicator */
.scroll-indicator {
    position: absolute;
    bottom: 34px;
    left: 50%;
    transform: translateX(-50%);
    width: 30px;
    height: 50px;
    border: 1.5px solid rgba(240, 240, 240, 0.25);
    border-radius: 999px;
    display: flex;
    justify-content: center;
    padding-top: 10px;
    transition: border-color var(--transition);
}

.scroll-indicator:hover {
    border-color: var(--red);
}

.scroll-arrow {
    display: block;
    width: 8px;
    height: 8px;
    border-right: 2px solid var(--red);
    border-bottom: 2px solid var(--red);
    transform: rotate(45deg);
    animation: scrollBounce 1.8s ease-in-out infinite;
}

@keyframes scrollBounce {
    0%, 100% { transform: translateY(0) rotate(45deg); opacity: 1; }
    50% { transform: translateY(14px) rotate(45deg); opacity: 0.3; }
}

/* ==========================================================================
   Sections (shared)
   ========================================================================== */
.section {
    max-width: 1200px;
    margin: 0 auto;
    padding: 110px 32px;
}

.section-title {
    font-family: var(--font-display);
    font-size: clamp(2rem, 4.5vw, 3rem);
    font-weight: 600;
    text-align: center;
    margin-bottom: 14px;
}

.section-sub {
    text-align: center;
    color: var(--text-dim);
    font-weight: 300;
    font-size: 1.08rem;
    margin-bottom: 60px;
}

/* Scroll reveal */
.reveal {
    opacity: 0;
    transform: translateY(36px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
    transition-delay: var(--reveal-delay, 0s);
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ==========================================================================
   Glassmorphism Cards
   ========================================================================== */
.glass-card {
    position: relative;
    background: var(--glass-card);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
    transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}

.glass-card:hover {
    border-color: rgba(230, 57, 70, 0.35);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5), 0 0 40px rgba(230, 57, 70, 0.15);
}

/* ==========================================================================
   Upload Section
   ========================================================================== */
.upload-section {
    padding-top: 40px;
}

.upload-card {
    padding: 46px;
    max-width: 900px;
    margin: 0 auto;
}

.dropzone {
    border: 2px dashed rgba(255, 255, 255, 0.18);
    border-radius: var(--radius);
    padding: 70px 30px;
    text-align: center;
    transition: all var(--transition);
    background: rgba(255, 255, 255, 0.015);
}

.dropzone:hover,
.dropzone.dragover {
    border-color: var(--red);
    background: var(--red-soft);
    box-shadow: inset 0 0 60px rgba(230, 57, 70, 0.08), 0 0 40px rgba(230, 57, 70, 0.15);
}

.dropzone-icon {
    font-size: 3.4rem;
    color: var(--red);
    text-shadow: 0 0 30px var(--red-glow);
    margin-bottom: 18px;
    animation: iconPulse 2.4s ease-in-out infinite;
    line-height: 1;
}

@keyframes iconPulse {
    0%, 100% { transform: scale(1); opacity: 0.85; }
    50% { transform: scale(1.12); opacity: 1; }
}

.dropzone-title {
    font-family: var(--font-display);
    font-size: 1.9rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.dropzone-sub {
    color: var(--text-dim);
    margin-bottom: 20px;
}

.dropzone-formats {
    font-size: 0.78rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--text-faint);
}

.dot-sep {
    color: var(--red);
    margin: 0 4px;
}

/* Error box */
.error-box {
    margin-top: 24px;
    padding: 16px 22px;
    border-radius: var(--radius-sm);
    background: rgba(230, 57, 70, 0.1);
    border: 1px solid rgba(230, 57, 70, 0.4);
    color: #ff8f97;
    font-size: 0.92rem;
    animation: fadeInUp 0.4s ease;
}

/* ==========================================================================
   Loading View
   ========================================================================== */
.loading-view {
    text-align: center;
    padding: 60px 20px;
    animation: fadeInUp 0.5s ease;
}

.analyzer-bars {
    display: flex;
    gap: 7px;
    justify-content: center;
    align-items: flex-end;
    height: 54px;
    margin-bottom: 28px;
}

.analyzer-bars span {
    width: 7px;
    border-radius: 4px;
    background: linear-gradient(to top, var(--red), var(--gold));
    box-shadow: 0 0 12px rgba(230, 57, 70, 0.5);
    animation: barBounce 1s ease-in-out infinite;
}

.analyzer-bars span:nth-child(1) { animation-delay: 0s; }
.analyzer-bars span:nth-child(2) { animation-delay: 0.15s; }
.analyzer-bars span:nth-child(3) { animation-delay: 0.3s; }
.analyzer-bars span:nth-child(4) { animation-delay: 0.45s; }
.analyzer-bars span:nth-child(5) { animation-delay: 0.6s; }

@keyframes barBounce {
    0%, 100% { height: 14px; }
    50% { height: 54px; }
}

.loading-text {
    font-family: var(--font-display);
    font-size: 1.4rem;
    margin-bottom: 6px;
}

.loading-dots span {
    animation: dotBlink 1.4s infinite;
}
.loading-dots span:nth-child(2) { animation-delay: 0.2s; }
.loading-dots span:nth-child(3) { animation-delay: 0.4s; }

@keyframes dotBlink {
    0%, 60%, 100% { opacity: 0.2; }
    30% { opacity: 1; }
}

.loading-filename {
    color: var(--text-faint);
    font-size: 0.9rem;
}

/* ==========================================================================
   Player View
   ========================================================================== */
.player-view {
    animation: fadeInUp 0.6s ease;
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(24px); }
    to   { opacity: 1; transform: translateY(0); }
}

.track-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 34px;
    flex-wrap: wrap;
}

.track-label {
    display: block;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 4px;
}

.track-title {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 600;
    word-break: break-word;
}

/* Giant current chord */
.current-chord-stage {
    text-align: center;
    padding: 20px 0 34px;
}

.current-chord-label {
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.26em;
    text-transform: uppercase;
    color: var(--text-faint);
    margin-bottom: 6px;
}

.current-chord {
    font-family: var(--font-display);
    font-size: clamp(4.5rem, 12vw, 8rem);
    font-weight: 700;
    line-height: 1.05;
    color: var(--red);
    text-shadow: 0 0 40px var(--red-glow), 0 0 90px rgba(230, 57, 70, 0.25);
    transition: color 0.25s ease, text-shadow 0.25s ease;
    min-height: 1.1em;
}

/* Custom audio player */
.player {
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 18px 24px;
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid var(--glass-border);
    border-radius: 999px;
    margin-bottom: 24px;
}

.play-btn {
    flex: 0 0 auto;
    width: 54px;
    height: 54px;
    border-radius: 50%;
    border: none;
    background: linear-gradient(135deg, var(--red) 0%, #c1121f 100%);
    color: #fff;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 22px rgba(230, 57, 70, 0.4);
    transition: all var(--transition);
}

.play-btn:hover {
    transform: scale(1.08);
    box-shadow: 0 0 34px var(--red-glow);
}

.play-icon {
    display: block;
    transform: translateX(1px);
    line-height: 1;
}

.player-time {
    flex: 0 0 auto;
    font-variant-numeric: tabular-nums;
    font-size: 0.85rem;
    color: var(--text-dim);
    min-width: 44px;
    text-align: center;
}

.progress-wrap {
    flex: 1;
    padding: 12px 0;
}

.progress-track {
    position: relative;
    height: 6px;
    border-radius: 3px;
    background: rgba(255, 255, 255, 0.1);
}

.progress-fill {
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 0%;
    border-radius: 3px;
    background: linear-gradient(90deg, var(--red), #ff6b76);
    box-shadow: 0 0 14px rgba(230, 57, 70, 0.6);
}

.progress-thumb {
    position: absolute;
    top: 50%;
    left: 0%;
    width: 15px;
    height: 15px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 0 12px var(--red-glow);
    transform: translate(-50%, -50%);
}

.free-limit-marker {
    position: absolute;
    top: -5px;
    bottom: -5px;
    width: 2px;
    background: var(--gold);
    box-shadow: 0 0 8px rgba(244, 162, 97, 0.7);
}

/* Free warning */
.free-warning {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    padding: 14px 22px;
    border-radius: var(--radius-sm);
    background: rgba(244, 162, 97, 0.08);
    border: 1px solid rgba(244, 162, 97, 0.35);
    color: var(--gold);
    font-size: 0.9rem;
    margin-bottom: 24px;
}

.free-warning.pulse {
    animation: warnPulse 0.8s ease 2;
}

@keyframes warnPulse {
    0%, 100% { box-shadow: none; }
    50% { box-shadow: 0 0 26px rgba(244, 162, 97, 0.45); }
}

/* Timeline */
.timeline-label {
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--text-faint);
    margin-bottom: 12px;
}

.timeline-container {
    overflow-x: auto;
    overflow-y: hidden;
    border-radius: var(--radius-sm);
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid var(--glass-border);
    margin-bottom: 30px;
    padding: 14px 0;
}

.timeline {
    position: relative;
    height: 76px;
    min-width: 100%;
}

.chord-block {
    position: absolute;
    top: 6px;
    bottom: 6px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: visible;
    transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
    opacity: 0.85;
}

.chord-block:hover {
    transform: scaleY(1.06);
    opacity: 1;
    z-index: 5;
}

.chord-block.active {
    opacity: 1;
    box-shadow: 0 0 18px rgba(255, 255, 255, 0.35), inset 0 0 0 2px rgba(255, 255, 255, 0.8);
    z-index: 4;
}

.chord-block-label {
    font-size: 0.82rem;
    font-weight: 700;
    color: #fff;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.7);
    white-space: nowrap;
    overflow: hidden;
    pointer-events: none;
    padding: 0 4px;
}

.chord-tooltip {
    position: absolute;
    bottom: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%);
    background: rgba(8, 8, 15, 0.95);
    border: 1px solid var(--glass-border);
    color: var(--text);
    font-size: 0.72rem;
    font-weight: 500;
    padding: 5px 10px;
    border-radius: 6px;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
    z-index: 10;
}

.chord-block:hover .chord-tooltip {
    opacity: 1;
}

.locked-block {
    background: repeating-linear-gradient(
        -45deg,
        rgba(255, 255, 255, 0.04),
        rgba(255, 255, 255, 0.04) 10px,
        rgba(255, 255, 255, 0.08) 10px,
        rgba(255, 255, 255, 0.08) 20px
    ) !important;
    border: 1px dashed rgba(244, 162, 97, 0.4);
}

.locked-block .chord-block-label {
    color: var(--gold);
}

.playhead {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    width: 2px;
    background: #fff;
    box-shadow: 0 0 10px var(--red-glow), 0 0 4px #fff;
    z-index: 6;
    pointer-events: none;
}

/* Actions */
.player-actions {
    text-align: center;
    margin-bottom: 40px;
}

/* Chord list */
.chord-list-title {
    font-family: var(--font-display);
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 16px;
}

.chord-table-wrap {
    max-height: 380px;
    overflow-y: auto;
    border-radius: var(--radius-sm);
    border: 1px solid var(--glass-border);
}

.chord-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.92rem;
}

.chord-table th {
    position: sticky;
    top: 0;
    text-align: left;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--text-faint);
    background: rgba(8, 8, 15, 0.95);
    padding: 13px 20px;
    border-bottom: 1px solid var(--glass-border);
    z-index: 2;
}

.chord-table td {
    padding: 11px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    color: var(--text-dim);
    font-variant-numeric: tabular-nums;
}

.chord-table tbody tr {
    transition: background var(--transition);
}

.chord-table tbody tr:hover {
    background: var(--red-soft);
}

.chord-table tbody tr.playing {
    background: rgba(230, 57, 70, 0.12);
}

.chord-badge {
    display: inline-block;
    min-width: 52px;
    text-align: center;
    padding: 4px 12px;
    border-radius: 999px;
    color: #fff;
    font-weight: 700;
    font-size: 0.85rem;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6);
}

/* ==========================================================================
   Features
   ========================================================================== */
.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
}

.feature-card {
    padding: 44px 34px;
    text-align: center;
}

.feature-card:hover {
    transform: translateY(-8px);
}

.feature-icon {
    font-size: 2.6rem;
    margin-bottom: 20px;
    filter: drop-shadow(0 0 18px rgba(230, 57, 70, 0.35));
}

.feature-title {
    font-family: var(--font-display);
    font-size: 1.45rem;
    font-weight: 600;
    margin-bottom: 12px;
}

.feature-text {
    color: var(--text-dim);
    font-weight: 300;
    font-size: 0.96rem;
}

.premium-tag {
    position: absolute;
    top: 18px;
    right: 18px;
    font-size: 0.64rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--gold);
    border: 1px solid rgba(244, 162, 97, 0.5);
    background: rgba(244, 162, 97, 0.08);
    padding: 5px 12px;
    border-radius: 999px;
    box-shadow: 0 0 14px rgba(244, 162, 97, 0.2);
}

/* ==========================================================================
   Pricing
   ========================================================================== */
.pricing-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 420px));
    justify-content: center;
    gap: 28px;
}

.pricing-grid-3 {
    grid-template-columns: repeat(3, minmax(0, 360px));
}

.price-card {
    padding: 44px 36px;
    text-align: center;
    position: relative;
}

.price-desc {
    font-size: 0.82rem;
    color: var(--text-faint);
    margin-bottom: 28px;
    margin-top: -18px;
}

/* Plus (red glow) */
.price-card-premium {
    border-color: rgba(230, 57, 70, 0.45);
    animation: premiumGlow 3.5s ease-in-out infinite;
}

@keyframes premiumGlow {
    0%, 100% { box-shadow: 0 20px 60px rgba(0,0,0,0.5), 0 0 40px rgba(230,57,70,0.15); }
    50%       { box-shadow: 0 20px 60px rgba(0,0,0,0.5), 0 0 70px rgba(230,57,70,0.3); }
}

/* Pro (gold glow) */
.price-card-pro {
    border-color: rgba(244, 162, 97, 0.4);
    animation: proGlow 3.5s ease-in-out infinite;
}

@keyframes proGlow {
    0%, 100% { box-shadow: 0 20px 60px rgba(0,0,0,0.5), 0 0 40px rgba(244,162,97,0.12); }
    50%       { box-shadow: 0 20px 60px rgba(0,0,0,0.5), 0 0 65px rgba(244,162,97,0.28); }
}

.pro-badge {
    position: absolute;
    top: -14px;
    right: 28px;
    background: linear-gradient(135deg, var(--gold), #e8870a);
    color: #08080f;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    padding: 5px 14px;
    border-radius: 50px;
    box-shadow: 0 4px 16px rgba(244,162,97,0.4);
}

.price-name {
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.26em;
    text-transform: uppercase;
    color: var(--text-dim);
    margin-bottom: 18px;
}

.price-card-premium .price-name { color: var(--red); }
.price-card-pro .price-name { color: var(--gold); }

.price-amount {
    font-family: var(--font-display);
    font-size: 3.2rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.price-period {
    font-family: var(--font-body);
    font-size: 0.92rem;
    font-weight: 400;
    color: var(--text-faint);
}

.price-features {
    list-style: none;
    margin-bottom: 32px;
    text-align: left;
}

.price-features li {
    padding: 9px 0 9px 26px;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    color: var(--text-dim);
    font-size: 0.9rem;
    position: relative;
}

.price-features li.feature-locked {
    opacity: 0.35;
    color: var(--text-faint);
}

.price-features li::before {
    content: attr(data-check);
    position: absolute;
    left: 2px;
    color: var(--red);
    font-weight: 700;
}

.price-card-premium .price-features li::before { color: var(--gold); }
.price-card-pro .price-features li::before { color: var(--gold); }

.pricing-compare {
    text-align: center;
    margin-top: 48px;
    font-size: 0.82rem;
    color: var(--text-faint);
    line-height: 1.8;
}

.btn-gold {
    background: linear-gradient(135deg, var(--gold), #e8870a);
    color: #08080f;
    font-weight: 700;
}
.btn-gold:hover {
    box-shadow: 0 8px 30px rgba(244,162,97,0.5);
    transform: translateY(-2px) scale(1.03);
}

/* Pro feature tag in features grid */
.pro-tag-feat {
    background: linear-gradient(135deg, var(--gold), #e8870a);
    color: #08080f;
}

/* Features 6-grid */
.features-grid-6 {
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

/* Pricing compare note */
.pricing-compare {
    margin-top: 40px;
    color: var(--text-faint);
    font-size: 0.82rem;
    text-align: center;
    line-height: 1.8;
}

.beta-pricing-note {
    display: flex;
    align-items: center;
    gap: 16px;
    margin: 40px auto 0;
    max-width: 600px;
    padding: 18px 24px;
    background: rgba(74, 222, 128, 0.07);
    border: 1px solid rgba(74, 222, 128, 0.25);
    border-radius: 14px;
    color: rgba(255,255,255,0.82);
    font-size: 0.88rem;
    line-height: 1.6;
    font-family: var(--font-body);
}

.beta-pricing-note strong {
    color: #4ade80;
    display: block;
    margin-bottom: 2px;
}

.beta-pricing-icon {
    font-size: 1.8rem;
    flex-shrink: 0;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.footer {
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    margin-top: 60px;
}

.footer-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 44px 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    flex-wrap: wrap;
}

.footer-logo-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    text-decoration: none;
}

.footer-logo {
    width: 60px;
    height: 60px;
    object-fit: contain;
    opacity: 0.75;
    filter: drop-shadow(0 0 10px rgba(230, 57, 70, 0.2));
    transition: opacity 0.3s ease, filter 0.3s ease, transform 0.3s ease;
}
.footer-logo-link:hover .footer-logo {
    opacity: 1;
    filter: drop-shadow(0 0 18px rgba(230, 57, 70, 0.5));
    transform: scale(1.08);
}

.footer-logo-url {
    font-size: 0.65rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--red);
    opacity: 0.7;
    font-family: var(--font-body);
}

.footer-brand {
    font-weight: 700;
    letter-spacing: 0.14em;
    font-size: 0.9rem;
    color: var(--text-dim);
}

.footer-made {
    color: var(--text-faint);
    font-size: 0.88rem;
}

.footer-made a {
    color: var(--red);
    text-decoration: none;
    transition: color var(--transition);
}

.footer-made a:hover {
    color: #ff6b76;
}

.footer-links {
    display: flex;
    gap: 24px;
}

.footer-links a {
    color: var(--text-faint);
    text-decoration: none;
    font-size: 0.85rem;
    transition: color var(--transition);
}

.footer-links a:hover {
    color: var(--text);
}

/* ==========================================================================
   Utilities
   ========================================================================== */
.hidden {
    display: none !important;
}

/* ==========================================================================
   Responsive (768px)
   ========================================================================== */
@media (max-width: 768px) {

    .nav-inner {
        padding: 12px 18px;
    }

    .brand-product {
        font-size: 1rem;
    }

    .brand-sep,
    .brand-logo {
        display: none;
    }

    .hero {
        padding: 100px 20px 70px;
    }

    .floating-chord {
        display: none;
    }

    .hero-cta {
        flex-direction: column;
        align-items: center;
    }

    .section {
        padding: 70px 20px;
    }

    .upload-card {
        padding: 24px 18px;
    }

    .dropzone {
        padding: 46px 18px;
    }

    .features-grid,
    .pricing-grid {
        grid-template-columns: 1fr;
    }

    .player {
        flex-wrap: wrap;
        border-radius: var(--radius);
        gap: 12px;
        padding: 16px;
    }

    .progress-wrap {
        order: 5;
        flex: 1 0 100%;
    }

    .current-chord {
        font-size: 4rem;
    }

    .footer-inner {
        flex-direction: column;
        text-align: center;
    }
}

/* ==========================================================================
   Feature Add-ons: Akkorddiagramme, Transpose, Metronom
   ========================================================================== */

/* ---- Chord diagram modal ---- */
.chord-modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.chord-modal.visible {
    opacity: 1;
}

.chord-modal-inner {
    position: relative;
    width: 100%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    background: rgba(8, 8, 15, 0.95);
    border: 1px solid rgba(230, 57, 70, 0.25);
    border-radius: 20px;
    padding: 34px 28px 28px;
    text-align: center;
    box-shadow: 0 24px 80px rgba(0, 0, 0, 0.6),
                0 0 60px rgba(230, 57, 70, 0.12);
    transform: translateY(16px) scale(0.97);
    transition: transform 0.3s ease;
}

.chord-modal.visible .chord-modal-inner {
    transform: translateY(0) scale(1);
}

.chord-modal-close {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 50%;
    background: var(--red);
    color: #fff;
    font-size: 1.3rem;
    line-height: 1;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.chord-modal-close:hover {
    transform: scale(1.1) rotate(90deg);
    box-shadow: 0 0 20px rgba(230, 57, 70, 0.6);
}

.chord-modal-name {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 3rem;
    font-weight: 700;
    color: #fff;
    text-shadow: 0 0 30px rgba(230, 57, 70, 0.5);
    margin-bottom: 10px;
    line-height: 1.1;
}

.chord-modal-tabs {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-bottom: 22px;
}

.chord-tab {
    padding: 8px 22px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 50px;
    background: transparent;
    color: rgba(240, 240, 240, 0.65);
    font-family: 'Space Grotesk', sans-serif;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.25s ease;
}

.chord-tab:hover {
    border-color: rgba(230, 57, 70, 0.5);
    color: #fff;
}

.chord-tab.active {
    background: var(--red);
    border-color: var(--red);
    color: #fff;
    box-shadow: 0 4px 20px rgba(230, 57, 70, 0.35);
}

.guitar-diagram,
.piano-diagram {
    display: flex;
    justify-content: center;
    padding: 8px 0 4px;
}

.guitar-diagram svg {
    width: 200px;
    max-width: 100%;
    height: auto;
}

.piano-diagram svg {
    width: 100%;
    max-width: 340px;
    height: auto;
}

.diagram-missing {
    color: rgba(240, 240, 240, 0.5);
    font-size: 0.9rem;
    padding: 24px 0;
}

/* ---- Transpose bar ---- */
.transpose-bar {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 16px 0;
    padding: 10px 16px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(244, 162, 97, 0.25);
    border-radius: 50px;
    width: fit-content;
}

.transpose-title {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 0.9rem;
    color: var(--gold);
}

.transpose-btn {
    width: 32px;
    height: 32px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.06);
    color: #fff;
    font-size: 0.75rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.transpose-btn:hover:not(:disabled) {
    background: var(--red);
    border-color: var(--red);
    box-shadow: 0 0 16px rgba(230, 57, 70, 0.4);
}

.transpose-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.transpose-value {
    min-width: 66px;
    text-align: center;
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 600;
    font-size: 0.95rem;
    color: #fff;
}

.transpose-hint {
    font-size: 0.75rem;
    color: rgba(240, 240, 240, 0.4);
}

/* ---- Metronome panel ---- */
.metronome-panel {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 200px;
    z-index: 900;
    background: rgba(8, 8, 15, 0.9);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 14px 16px 16px;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
}

.metronome-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
    cursor: grab;
    user-select: none;
}

.metronome-header:active {
    cursor: grabbing;
}

.metronome-title {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 0.85rem;
    font-weight: 600;
    color: rgba(240, 240, 240, 0.85);
}

.metronome-beat {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    border: 2px solid rgba(230, 57, 70, 0.5);
    background: transparent;
    transition: background 0.08s ease, box-shadow 0.08s ease;
}

.metronome-beat.flash {
    background: var(--red);
    border-color: var(--red);
    box-shadow: 0 0 14px rgba(230, 57, 70, 0.9);
}

.metronome-bpm-row {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 12px;
}

.metronome-bpm {
    width: 74px;
    padding: 6px 10px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 8px;
    color: #fff;
    font-family: 'Space Grotesk', sans-serif;
    font-size: 1.05rem;
    font-weight: 600;
    text-align: center;
}

.metronome-bpm:focus {
    outline: none;
    border-color: var(--red);
}

.metronome-bpm-label {
    font-size: 0.75rem;
    color: rgba(240, 240, 240, 0.5);
    letter-spacing: 0.06em;
}

.metronome-actions {
    display: flex;
    gap: 8px;
}

.metro-btn {
    flex: 1;
    padding: 8px 4px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.06);
    color: #fff;
    font-family: 'Space Grotesk', sans-serif;
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.metro-btn:hover {
    border-color: rgba(230, 57, 70, 0.6);
    background: rgba(230, 57, 70, 0.15);
}

.metro-btn-start {
    background: var(--red);
    border-color: var(--red);
}

.metronome-panel.running .metro-btn-start {
    animation: metroPulse 0.9s ease-in-out infinite;
}

@keyframes metroPulse {
    0%, 100% { box-shadow: 0 0 0 rgba(230, 57, 70, 0.5); }
    50%      { box-shadow: 0 0 18px rgba(230, 57, 70, 0.8); }
}

@media (max-width: 768px) {
    .metronome-panel {
        bottom: 14px;
        right: 14px;
        width: 180px;
    }
    .chord-modal-name {
        font-size: 2.3rem;
    }
}

/* ==========================================================================
   Live Diagram Panel
   ========================================================================== */
.live-diagram-panel {
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.09);
    border-radius: 16px;
    padding: 18px 22px 20px;
    margin: 12px 0 20px;
    transition: opacity 0.3s ease;
}
.live-diagram-panel.ldp-hidden { display: none; }

.ldp-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 18px;
}

.ldp-chord-name {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--red);
    min-width: 60px;
    letter-spacing: 0.03em;
}

.ldp-tabs {
    display: flex;
    gap: 8px;
}
.ldp-tab {
    padding: 6px 16px;
    border-radius: 999px;
    border: 1px solid var(--glass-border);
    background: transparent;
    color: var(--text-dim);
    font-size: 0.82rem;
    font-family: var(--font-body);
    transition: all 0.2s ease;
}
.ldp-tab.ldp-tab-active {
    background: var(--red);
    border-color: var(--red);
    color: #fff;
    box-shadow: 0 0 14px rgba(230,57,70,0.4);
}
.ldp-tab:hover:not(.ldp-tab-active) {
    border-color: rgba(230,57,70,0.5);
    color: var(--text);
}

.ldp-nav {
    display: flex;
    align-items: center;
    gap: 10px;
}
.ldp-nav-btn {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    border: 1px solid var(--glass-border);
    background: var(--glass);
    color: var(--text);
    font-size: 0.65rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}
.ldp-nav-btn:hover:not(:disabled) {
    border-color: var(--red);
    color: var(--red);
    box-shadow: 0 0 10px rgba(230,57,70,0.3);
}
.ldp-nav-btn:disabled { opacity: 0.3; }

.ldp-var-label {
    font-size: 0.78rem;
    color: var(--text-dim);
    min-width: 100px;
    text-align: center;
    font-family: var(--font-body);
    letter-spacing: 0.04em;
}

.ldp-body {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 80px;
}
.ldp-body svg {
    max-width: 100%;
    height: auto;
    max-height: 240px;
}
.ldp-body .diagram-missing {
    color: var(--text-faint);
    font-size: 0.85rem;
    padding: 20px;
    text-align: center;
}

@media (max-width: 768px) {
    .ldp-header { flex-direction: column; align-items: flex-start; }
    .ldp-body svg { max-height: 180px; }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    html { scroll-behavior: auto; }
    .reveal { opacity: 1; transform: none; }
}
