/* ============================================
   THE PATTERN TRAINING — STYLE
   Dark, professional, sleek design
   ============================================ */

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

:root {
    --bg-primary: #060913;
    --bg-secondary: #0f1426;
    --bg-card: rgba(255,255,255,0.06);
    --bg-card-hover: rgba(255,255,255,0.10);
    --border: rgba(255,255,255,0.12);
    --border-glow: rgba(62,226,255,0.55);
    --text-primary: #f7f7fb;
    --text-secondary: rgba(247,247,251,0.72);
    --text-muted: rgba(247,247,251,0.48);
    --accent-3: #3ee2ff;
    --accent-6: #ff7a59;
    --accent-9: #ffd166;
    --accent-primary: #3ee2ff;
    --accent-primary-dim: rgba(62,226,255,0.18);
    --gradient-main: linear-gradient(135deg, #3ee2ff, #ff7a59, #ffd166);
    --gradient-purple: linear-gradient(135deg, #3ee2ff, #97f1ff);
    --gradient-cyan: linear-gradient(135deg, #3ee2ff, #97f1ff);
    --gradient-amber: linear-gradient(135deg, #ffd166, #ffe6a3);
    --glow-purple: 0 0 30px rgba(62,226,255,0.35);
    --glow-cyan: 0 0 30px rgba(62,226,255,0.35);
    --glow-amber: 0 0 30px rgba(255,209,102,0.35);
    --shadow-strong: 0 24px 60px -30px rgba(0,0,0,0.8);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --sidebar-width: 260px;
    --font-main: 'Manrope', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
    --font-display: 'Space Grotesk', 'Manrope', sans-serif;
}


html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-main);
    background-color: var(--bg-primary);
    background-image:
        radial-gradient(1200px 600px at -10% -10%, rgba(62, 226, 255, 0.35) 0%, transparent 60%),
        radial-gradient(900px 600px at 110% -20%, rgba(255, 122, 89, 0.4) 0%, transparent 60%),
        radial-gradient(900px 600px at 50% 120%, rgba(255, 209, 102, 0.18) 0%, transparent 60%);
    background-attachment: fixed;
    color: var(--text-primary);
    line-height: 1.7;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}


.no-scroll {
    overflow: hidden;
}

a {
    color: var(--accent-primary);
    text-decoration: none;
    transition: color 0.2s;
}

a:hover { color: var(--accent-6); }

::selection {
    background: var(--accent-6);
    color: #08111f;
}

/* --- Particles Canvas --- */
#particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
    opacity: 0.25;
}

/* --- Progress Bar --- */
.progress-bar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: rgba(255,255,255,0.08);
    z-index: 1000;
}


.progress-fill {
    height: 100%;
    background: var(--gradient-main);
    width: 0%;
    transition: width 0.3s ease;
    border-radius: 0 2px 2px 0;
}

/* --- Sidebar Navigation --- */
.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: var(--sidebar-width);
    height: 100vh;
    background: rgba(15, 20, 38, 0.88);
    border-right: 1px solid rgba(255,255,255,0.08);
    backdrop-filter: blur(12px) saturate(140%);
    z-index: 100;
    display: flex;
    flex-direction: column;
    padding: 2rem 0;
    transition: transform 0.3s ease;
}


.sidebar-header {
    padding: 0 1.5rem 2rem;
    border-bottom: 1px solid var(--border);
    margin-bottom: 1.5rem;
}

.logo {
    font-size: 1.8rem;
    font-weight: 800;
    background: var(--gradient-main);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: 2px;
}

.nav-links {
    list-style: none;
    flex: 1;
    overflow-y: auto;
    padding: 0 0.75rem;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.65rem 0.75rem;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.2s;
    margin-bottom: 2px;
}

.nav-link:hover {
    background: var(--accent-primary-dim);
    color: var(--text-primary);
}

.nav-link.active {
    background: var(--accent-primary-dim);
    color: var(--accent-primary);
    font-weight: 600;
}

.step-num {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    opacity: 0.5;
}

.sidebar-footer {
    padding: 1.5rem;
    border-top: 1px solid var(--border);
    margin-top: auto;
}

.progress-text {
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-family: var(--font-mono);
}

/* --- Mobile Toggle --- */
.mobile-toggle {
    display: none;
    position: fixed;
    top: 1rem;
    left: 1rem;
    z-index: 200;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    width: 44px;
    height: 44px;
    cursor: pointer;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
}

.mobile-toggle span {
    display: block;
    width: 20px;
    height: 2px;
    background: var(--text-primary);
    border-radius: 2px;
    transition: all 0.3s;
}

/* --- Main Content --- */
.content {
    margin-left: var(--sidebar-width);
    position: relative;
    z-index: 1;
}

/* --- Sections --- */
.section {
    min-height: 100vh;
    display: flex;
    align-items: flex-start;
    padding: 6rem 2rem 4rem;
}

.section-inner {
    max-width: 780px;
    margin: 0 auto;
    width: 100%;
}

/* --- Hero --- */
.hero {
    align-items: center;
    text-align: center;
    padding-top: 4rem;
}

.hero-inner {
    max-width: 800px;
    margin: 0 auto;
}

.hero-badge {
    display: inline-block;
    padding: 0.4rem 1.2rem;
    background: linear-gradient(135deg, rgba(62,226,255,0.25), rgba(255,122,89,0.2));
    border: 1px solid rgba(62,226,255,0.4);
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 700;
    color: #fff;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-bottom: 2rem;
}


.hero-title {
    font-family: var(--font-display);
    font-size: clamp(2.6rem, 5vw, 3.8rem);
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    letter-spacing: -0.03em;
}


.gradient-text {
    background: var(--gradient-main);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.hero-description {
    font-size: 1rem;
    color: var(--text-muted);
    margin-bottom: 2.5rem;
    max-width: 550px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.8;
}

.hero-steps-preview {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-top: 3rem;
    padding-top: 3rem;
    border-top: 1px solid var(--border);
}

.preview-step {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.preview-num {
    font-family: var(--font-mono);
    font-size: 0.7rem;
    background: var(--bg-card);
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    color: var(--accent-primary);
}

.preview-arrow {
    color: var(--text-muted);
    font-size: 0.75rem;
}

/* --- Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.25s ease;
    border: none;
    text-decoration: none;
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent-6), var(--accent-9));
    color: #1a120c;
    box-shadow: 0 10px 24px rgba(255, 122, 89, 0.35);
}


.btn-primary:hover {
    filter: brightness(1.05);
    color: #1a120c;
    transform: translateY(-2px);
    box-shadow: 0 14px 28px rgba(255, 122, 89, 0.5);
}


.btn-secondary {
    background: rgba(255,255,255,0.06);
    border: 1px solid var(--border);
    color: var(--text-primary);
}


.btn-secondary:hover {
    background: rgba(255,255,255,0.12);
    border-color: rgba(62,226,255,0.6);
    color: #fff;
}


.btn-ghost {
    background: transparent;
    color: var(--text-secondary);
}

.btn-ghost:hover {
    color: var(--text-primary);
}

/* --- Step Header --- */
.step-header {
    text-align: center;
    margin-bottom: 3rem;
}

.step-badge {
    display: inline-block;
    padding: 0.35rem 1rem;
    background: linear-gradient(135deg, rgba(62,226,255,0.22), rgba(255,122,89,0.18));
    border: 1px solid rgba(62,226,255,0.35);
    border-radius: 50px;
    font-family: var(--font-mono);
    font-size: 0.75rem;
    font-weight: 600;
    color: #fff;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 1.25rem;
}


.section-title {
    font-family: var(--font-display);
    font-size: 2.2rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 0.5rem;
}


.section-subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
}

/* --- Quick Start --- */
.quick-start {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin: 0 auto 2rem;
    max-width: 980px;
}

.qs-item {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 0.75rem;
    align-items: start;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 1rem 1.1rem;
}

.qs-num {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-mono);
    font-weight: 700;
    color: var(--text-primary);
    background: var(--accent-primary-dim);
    border: 1px solid #3ee2ff40;
}

.qs-item h4 {
    margin: 0 0 0.35rem;
    font-size: 1rem;
}

.qs-item p {
    margin: 0;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* --- Cards --- */
.card {
    background: linear-gradient(180deg, rgba(255,255,255,0.10), rgba(255,255,255,0.04));
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 2rem;
    margin-bottom: 1.5rem;
    transition: all 0.3s ease;
    backdrop-filter: blur(14px) saturate(140%);
    box-shadow: var(--shadow-strong);
}


.card:hover {
    border-color: var(--border-glow);
}

.card-icon {
    font-size: 1.5rem;
    margin-bottom: 0.75rem;
}

.card h3 {
    font-size: 1.35rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
}

.card p {
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: 0.75rem;
}

.card p:last-child { margin-bottom: 0; }

.card-explain {
    border-left: 3px solid var(--accent-6);
}

.card-highlight {
    border-left: 3px solid var(--accent-primary);
    background: linear-gradient(135deg, var(--bg-card), #101628);
}

.card-why {
    border-left: 3px solid var(--accent-9);
    background: linear-gradient(135deg, var(--bg-card), #10131f);
}

.card-interactive {
    border-left: 3px solid var(--accent-6);
}

.card-final {
    text-align: center;
    background: linear-gradient(135deg, #101628, #0f1729);
    border: 1px solid #3ee2ff40;
}

.image-card .image-frame {
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 0.75rem;
    margin: 1rem 0;
}

.image-card img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: var(--radius-sm);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.35);
}

/* --- Inline Image Frame --- */
.inline-image-frame {
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 0.75rem;
    margin: 1rem 0;
}

.inline-image-frame img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: var(--radius-sm);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.35);
}

.lightbox-trigger {
    cursor: zoom-in;
}

/* --- Example Box --- */
.example-box {
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 1.25rem;
    margin: 1rem 0;
}

.example-label {
    font-family: var(--font-mono);
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--accent-6);
    margin-bottom: 0.75rem;
    font-weight: 600;
}

.example-flow {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    font-size: 1.1rem;
}

.flow-num {
    font-family: var(--font-mono);
    font-weight: 700;
    color: var(--accent-primary);
    font-size: 1.3rem;
}

.flow-arrow {
    color: var(--text-muted);
}

.flow-calc {
    font-family: var(--font-mono);
    color: var(--text-secondary);
}

.example-result {
    margin-top: 0.75rem;
    color: var(--text-primary) !important;
    font-weight: 500;
}

.mini-note {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: 0.5rem;
}

/* --- Tesla Quote --- */
.tesla-quote {
    border-left: 3px solid var(--accent-9);
    padding: 1.25rem 1.5rem;
    margin: 1rem 0;
    background: var(--bg-primary);
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    font-style: italic;
    color: var(--text-primary);
    font-size: 1.05rem;
    line-height: 1.8;
}

.tesla-quote cite {
    display: block;
    margin-top: 0.5rem;
    font-style: normal;
    font-size: 0.85rem;
    color: var(--accent-9);
    font-weight: 600;
}

/* --- Pattern Table --- */
.pattern-table {
    margin: 1rem 0;
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 1px solid var(--border);
}

.pattern-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    padding: 0.65rem 1.25rem;
    border-bottom: 1px solid var(--border);
    align-items: center;
    transition: background 0.2s;
}

.pattern-row:last-child { border-bottom: none; }

.pattern-row:hover { background: var(--bg-card-hover); }

.pattern-header-row {
    background: var(--bg-primary);
    font-weight: 700;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-secondary);
}

.root-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    font-weight: 700;
    font-family: var(--font-mono);
    font-size: 0.9rem;
    background: var(--bg-primary);
    color: var(--text-secondary);
    border: 1px solid var(--border);
}

.root-3 {
    background: #3ee2ff20;
    color: var(--accent-3);
    border-color: #3ee2ff40;
    box-shadow: var(--glow-purple);
}

.root-6 {
    background: #3ee2ff20;
    color: var(--accent-6);
    border-color: #3ee2ff40;
    box-shadow: var(--glow-cyan);
}

.root-9 {
    background: #ffd16620;
    color: var(--accent-9);
    border-color: #ffd16640;
    box-shadow: var(--glow-amber);
}

/* --- Insight Box --- */
.insight-box {
    background: linear-gradient(135deg, #101628, #0f1729);
    border: 1px solid #3ee2ff40;
    border-radius: var(--radius-md);
    padding: 1.25rem;
    margin-top: 1rem;
    color: var(--text-primary);
}

.pattern-cycle {
    font-family: var(--font-mono);
    font-weight: 700;
    letter-spacing: 2px;
}

.c3 { color: var(--accent-3); }
.c6 { color: var(--accent-6); }
.c9 { color: var(--accent-9); }

/* --- Key Point --- */
.key-point {
    color: var(--text-primary) !important;
    font-weight: 600;
    font-size: 1.05rem;
    padding: 1rem;
    background: var(--bg-primary);
    border-radius: var(--radius-sm);
    border-left: 3px solid var(--accent-primary);
}

/* --- Calculator --- */
.calculator {
    display: flex;
    gap: 0.75rem;
    margin: 1rem 0;
}

.calc-input {
    flex: 1;
    padding: 0.75rem 1rem;
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-family: var(--font-mono);
    font-size: 1rem;
    outline: none;
    transition: border-color 0.2s;
}

.calc-input:focus {
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px var(--accent-primary-dim);
}

.calc-input::placeholder { color: var(--text-muted); }

.calc-result {
    min-height: 60px;
    padding: 1rem;
    background: var(--bg-primary);
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    font-family: var(--font-mono);
    font-size: 0.95rem;
    line-height: 2;
    color: var(--text-secondary);
}

.calc-step {
    display: inline-block;
    padding: 0.15rem 0.5rem;
    background: var(--bg-card);
    border-radius: 4px;
    margin: 0.15rem;
    color: var(--text-primary);
}

.calc-final {
    display: block;
    margin-top: 0.5rem;
    font-weight: 700;
    font-size: 1.1rem;
}

.calc-final .root-badge {
    display: inline-flex;
    vertical-align: middle;
    margin-left: 0.5rem;
}

/* --- Fibonacci --- */
.fib-toolbar {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin: 0.75rem 0 0.25rem;
}

.fib-scroll {
    overflow-x: auto;
    padding: 0.5rem 0.25rem 0.75rem;
    margin: 0.25rem 0 0.5rem;
    scroll-behavior: smooth;
    border-bottom: 1px dashed var(--border);
    scroll-snap-type: x mandatory;
}

.fib-scroll::-webkit-scrollbar {
    height: 8px;
}

.fib-scroll::-webkit-scrollbar-thumb {
    background: var(--border-glow);
    border-radius: 999px;
}

.fibonacci-sequence {
    display: inline-flex;
    gap: 0.4rem;
    flex-wrap: nowrap;
    margin: 0;
    padding-bottom: 0.25rem;
}

.fib-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 48px;
    height: 40px;
    padding: 0 0.6rem;
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-family: var(--font-mono);
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.3s;
    position: relative;
    cursor: pointer;
    scroll-snap-align: center;
}

.fib-num:nth-child(4), /* 3 */
.fib-num:nth-child(9), /* 21 */
.fib-num:nth-child(13) /* 144 */ {
    background: var(--accent-primary-dim);
    border-color: #3ee2ff40;
    color: var(--accent-primary);
}

.fib-num::after {
    content: attr(data-root);
    position: absolute;
    bottom: -14px;
    right: 6px;
    font-size: 0.7rem;
    font-weight: 700;
    font-family: var(--font-mono);
    color: var(--text-muted);
    opacity: 0;
    transform: translateY(4px);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.fibonacci-sequence.show-roots .fib-num::after {
    opacity: 1;
    transform: translateY(0);
}

.fib-num.fib-root-3::after { color: var(--accent-3); }
.fib-num.fib-root-6::after { color: var(--accent-6); }
.fib-num.fib-root-9::after { color: var(--accent-9); }

.fib-num.active {
    border-color: var(--accent-primary);
    box-shadow: 0 0 12px var(--accent-primary-dim);
    transform: translateY(-2px);
}

.fib-num.fib-repeat {
    border-style: dashed;
    border-color: var(--accent-6);
}

/* --- Wheel Controls --- */
.wheel-controls {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin: 0.75rem 0 1rem;
}

.wheel-speed {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-secondary);
    font-size: 0.85rem;
}

.wheel-speed input[type="range"] {
    accent-color: var(--accent-primary);
}

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

/* --- Quiz --- */
.quiz-card {
    border-left: 3px solid var(--accent-3);
}

.quiz-question {
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.75rem;
}

.quiz-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 0.6rem;
}

.quiz-option {
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    padding: 0.6rem 0.75rem;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: var(--font-main);
}

.quiz-option:hover {
    border-color: var(--accent-primary);
    color: var(--text-primary);
}

.quiz-option.correct {
    border-color: var(--accent-6);
    background: #3ee2ff20;
    color: var(--accent-6);
}

.quiz-option.wrong {
    border-color: var(--accent-9);
    background: #ffd16620;
    color: var(--accent-9);
}

.quiz-card.answered .quiz-option {
    cursor: default;
}

.quiz-feedback {
    margin-top: 0.75rem;
    padding: 0.75rem 1rem;
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    min-height: 48px;
    font-size: 0.9rem;
}


.fib-tools {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-top: 0.75rem;
}

.fib-hint {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.fib-roots-stack {
    margin: 1rem auto 0.5rem;
    padding: 0.9rem 1rem;
    max-width: 520px;
    text-align: center;
    --root-spacing: 0.16em;
    border: 1px solid rgba(139, 92, 246, 0.2);
    border-radius: var(--radius-md);
    background: rgba(18, 18, 30, 0.45);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.25);
}

.fib-roots-stack .root-line {
    font-family: 'JetBrains Mono', monospace;
    letter-spacing: var(--root-spacing);
    font-size: 1.05rem;
    color: var(--text);
    display: block;
    width: calc(12ch + (11 * var(--root-spacing)));
    margin: 0 auto;
    text-align: left;
    font-variant-numeric: tabular-nums;
    font-feature-settings: "tnum";
}

.fib-roots-stack .root-line + .root-line {
    margin-top: 0.2rem;
}

.fib-roots-stack .root-line-accent {
    color: #fbbf24;
    text-shadow: 0 0 12px rgba(251, 191, 36, 0.35);
}

.fib-roots-stack .root-note {
    margin-top: 0.55rem;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.pyramid-box {
    text-align: center;
}

.pyramid-figure {
    width: 180px;
    height: 120px;
    margin: 0.85rem auto 0;
    position: relative;
    background: linear-gradient(140deg, rgba(245, 158, 11, 0.28), rgba(245, 158, 11, 0.08));
    clip-path: polygon(50% 0%, 0% 100%, 100% 100%);
    border: 1px solid rgba(245, 158, 11, 0.5);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.35);
}

.pyramid-figure::before {
    content: "";
    position: absolute;
    inset: 12px 18px 8px 18px;
    background: linear-gradient(160deg, rgba(245, 158, 11, 0.35), rgba(17, 17, 28, 0.2));
    clip-path: polygon(50% 0%, 0% 100%, 100% 100%);
    opacity: 0.9;
}

.fib-info {
    margin-top: 0.75rem;
    padding: 0.85rem 1rem;
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* --- Journey Slideshow --- */
.slideshow {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 0.75rem;
    align-items: center;
    margin: 1rem 0 0.75rem;
}

.slide-frame {
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 240px;
}

.slide-frame img {
    width: 100%;
    max-height: 420px;
    object-fit: contain;
    cursor: zoom-in;
    border-radius: var(--radius-sm);
}

.slide-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid var(--border);
    background: var(--bg-card);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s ease;
}

.slide-btn:hover {
    border-color: var(--accent-primary);
    color: var(--text-primary);
    transform: translateY(-1px);
}

.slide-caption {
    text-align: center;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.slide-dots {
    display: flex;
    justify-content: center;
    gap: 0.4rem;
    margin-bottom: 0.75rem;
}

.slide-dot {
    width: 10px;
    height: 10px;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: var(--bg-primary);
    cursor: pointer;
    transition: all 0.2s ease;
}

.slide-dot.active {
    background: var(--accent-primary);
    border-color: var(--accent-primary);
    box-shadow: 0 0 10px var(--accent-primary-dim);
}

.slide-thumbs {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(70px, 1fr));
    gap: 0.5rem;
}

.slide-thumb {
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 0.35rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.slide-thumb img {
    width: 100%;
    height: 48px;
    object-fit: cover;
    border-radius: 6px;
}

.slide-thumb.active {
    border-color: var(--accent-6);
    box-shadow: 0 0 12px #3ee2ff20;
}

.slide-hint {
    text-align: center;
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: 0.75rem;
}

/* --- Lightbox --- */
.lightbox {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 2000;
}

.lightbox.open { display: flex; }

.lightbox-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(10, 10, 15, 0.85);
    backdrop-filter: blur(3px);
}

.lightbox-content {
    position: relative;
    z-index: 2;
    max-width: min(90vw, 900px);
    max-height: 85vh;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1rem;
    box-shadow: 0 30px 80px rgba(0,0,0,0.5);
}

.lightbox-content img {
    width: 100%;
    max-height: 70vh;
    object-fit: contain;
    border-radius: var(--radius-md);
}

.lightbox-caption {
    text-align: center;
    margin-top: 0.75rem;
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.lightbox-close {
    position: absolute;
    top: 8px;
    right: 10px;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: 1px solid var(--border);
    background: var(--bg-primary);
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 1.1rem;
}

.lightbox-close:hover {
    color: var(--text-primary);
    border-color: var(--accent-primary);
}

/* --- Glossary Panel --- */
.glossary-toggle {
    position: fixed;
    right: 1.25rem;
    bottom: 1.25rem;
    z-index: 1500;
    background: var(--bg-card);
    color: var(--text-primary);
    border: 1px solid var(--border);
    border-radius: 999px;
    padding: 0.6rem 1rem;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    transition: all 0.2s ease;
}

.glossary-toggle:hover {
    border-color: var(--accent-primary);
    color: var(--accent-primary);
}

.glossary-panel {
    position: fixed;
    right: 1.25rem;
    bottom: 4.5rem;
    width: min(360px, 90vw);
    max-height: 70vh;
    overflow: hidden;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: 0 20px 50px rgba(0,0,0,0.45);
    transform: translateY(20px);
    opacity: 0;
    pointer-events: none;
    transition: all 0.25s ease;
    z-index: 1500;
}

.glossary-panel.open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
}

.glossary-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.85rem 1rem;
    border-bottom: 1px solid var(--border);
    background: linear-gradient(135deg, #151524, #131825);
}

.glossary-header h4 {
    margin: 0;
    font-size: 1rem;
}

.glossary-close {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    border: 1px solid var(--border);
    background: var(--bg-primary);
    color: var(--text-secondary);
    cursor: pointer;
}

.glossary-close:hover {
    color: var(--text-primary);
    border-color: var(--accent-primary);
}

.glossary-list {
    padding: 0.85rem 1rem 1rem;
    overflow-y: auto;
    max-height: 55vh;
}

.glossary-item {
    padding: 0.5rem 0;
    border-bottom: 1px dashed var(--border);
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.5;
}

.glossary-item:last-child {
    border-bottom: none;
}

.fib-explanation {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    font-family: var(--font-mono);
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* --- Triangle Visual --- */
.triangle-visual {
    display: flex;
    justify-content: center;
    margin: 1.5rem 0;
}

.triangle-controls {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin: 0.5rem 0 0.35rem;
}

.triangle-controls label {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.triangle-controls input[type="range"] {
    accent-color: var(--accent-primary);
}

.triangle-scale-value {
    font-family: var(--font-mono);
    font-weight: 700;
    color: var(--text-primary);
}

.triangle-sides {
    font-family: var(--font-mono);
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
}

#triangleCanvas {
    max-width: 100%;
    height: auto;
}

.equation {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    font-family: var(--font-mono);
    font-size: 1.15rem;
    color: var(--text-primary);
}

.eq-part {
    padding: 0.3rem 0;
}

/* --- Clean List --- */
.clean-list {
    list-style: none;
    padding: 0;
}

.clean-list li {
    padding: 0.4rem 0;
    padding-left: 1.5rem;
    position: relative;
    color: var(--text-secondary);
}

.clean-list li::before {
    content: '→';
    position: absolute;
    left: 0;
    color: var(--accent-primary);
}

/* --- Slope Comparison --- */
.slope-comparison {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin: 1.5rem 0;
}

.slope-card {
    padding: 1.5rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
}

.slope-card h4 {
    font-size: 1rem;
    margin-bottom: 0.75rem;
    font-weight: 700;
}

.slope-card ul {
    list-style: none;
    padding: 0;
}

.slope-card li {
    padding: 0.3rem 0;
    font-size: 0.9rem;
    color: var(--text-secondary);
    padding-left: 1.25rem;
    position: relative;
}

.slope-down {
    background: linear-gradient(135deg, #101a2a, #0f1624);
    border-color: #3b82f640;
}

.slope-down h4 { color: #3b82f6; }

.slope-down li::before {
    content: '↘';
    position: absolute;
    left: 0;
    color: #3b82f6;
}

.slope-up {
    background: linear-gradient(135deg, #0a1a15, #0a1a18);
    border-color: #22c55e40;
}

.slope-up h4 { color: #22c55e; }

.slope-up li::before {
    content: '↗';
    position: absolute;
    left: 0;
    color: #22c55e;
}

/* --- Options Grid --- */
.options-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin: 1.5rem 0;
}

.option-card {
    text-align: center;
    padding: 1.5rem 1rem;
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    transition: all 0.3s;
}

.option-card:hover {
    border-color: var(--accent-primary);
    transform: translateY(-3px);
}

.option-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    font-family: var(--font-mono);
    font-weight: 800;
    font-size: 1.3rem;
    margin-bottom: 0.75rem;
}

.option-card:nth-child(1) .option-num {
    background: #3ee2ff20;
    color: var(--accent-3);
    border: 2px solid #3ee2ff40;
}

.option-card:nth-child(2) .option-num {
    background: #3ee2ff20;
    color: var(--accent-6);
    border: 2px solid #3ee2ff40;
}

.option-card:nth-child(3) .option-num {
    background: #ffd16620;
    color: var(--accent-9);
    border: 2px solid #ffd16640;
}

.option-card h4 {
    font-size: 0.95rem;
    margin-bottom: 0.3rem;
}

.option-card p {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.option-note {
    text-align: center;
    margin-top: 1.5rem;
    color: var(--text-secondary);
    font-weight: 500;
}

/* --- Journey Map --- */
.journey-map {
    display: flex;
    flex-direction: column;
    gap: 0;
    margin: 1.5rem 0;
}

.journey-item {
    padding: 1.5rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    position: relative;
}

.journey-item h4 { margin-bottom: 0.5rem; }

.journey-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-family: var(--font-mono);
    font-weight: 800;
    font-size: 1.2rem;
    margin-bottom: 0.75rem;
}

.journey-3 {
    border-color: #3ee2ff40;
    background: linear-gradient(135deg, var(--bg-card), #101628);
}

.journey-3 .journey-num {
    background: #3ee2ff20;
    color: var(--accent-3);
    border: 2px solid #3ee2ff40;
}

.journey-4 {
    border-color: #3ee2ff40;
    background: linear-gradient(135deg, var(--bg-card), #0a1a20);
}

.journey-4 .journey-num {
    background: #3ee2ff20;
    color: var(--accent-6);
    border: 2px solid #3ee2ff40;
}

.journey-5 {
    border-color: #ffd16640;
    background: linear-gradient(135deg, var(--bg-card), #1a1810);
}

.journey-5 .journey-num {
    background: #ffd16620;
    color: var(--accent-9);
    border: 2px solid #ffd16640;
}

.journey-arrow {
    text-align: center;
    font-size: 1.5rem;
    color: var(--text-muted);
    padding: 0.25rem 0;
}

/* --- Why 36 Grid --- */
.why-36-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin: 1rem 0;
}

.why-36-item {
    text-align: center;
    padding: 1.25rem;
    background: var(--bg-primary);
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
}

.why-calc {
    display: block;
    font-family: var(--font-mono);
    font-size: 1rem;
    color: var(--accent-primary);
    margin-bottom: 0.5rem;
}

.why-36-item p {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* --- Timeline --- */
.journey-timeline {
    position: relative;
    padding-left: 2rem;
}

.journey-timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--gradient-main);
    border-radius: 2px;
}

.timeline-block {
    position: relative;
    margin-bottom: 2rem;
    padding-left: 1.5rem;
}

.timeline-block::before {
    content: '';
    position: absolute;
    left: -2rem;
    top: 0.5rem;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--accent-primary);
    border: 2px solid var(--bg-card);
    margin-left: -5px;
}

.timeline-range {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--accent-primary);
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.timeline-content h4 {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

.timeline-content ul {
    list-style: none;
    padding: 0;
}

.timeline-content li {
    padding: 0.25rem 0;
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* --- Day Grid --- */
.day-grid {
    display: grid;
    grid-template-columns: repeat(9, 1fr);
    gap: 6px;
    margin: 1rem 0;
}

.day-cell {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
    font-family: var(--font-mono);
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    border: 1px solid var(--border);
    background: var(--bg-primary);
    color: var(--text-secondary);
    transition: all 0.2s;
}

.day-cell:hover {
    border-color: var(--accent-primary);
    transform: scale(1.05);
}

.day-cell.active {
    border-color: var(--accent-primary);
    box-shadow: 0 0 15px var(--accent-primary-dim);
}

.day-cell.key-day-3 {
    background: #3ee2ff20;
    border-color: #3ee2ff40;
    color: var(--accent-3);
}

.day-cell.key-day-1 {
    background: rgba(232, 232, 240, 0.08);
    border-color: rgba(232, 232, 240, 0.35);
    color: var(--text-primary);
}

.day-cell.key-day-6 {
    background: #3ee2ff20;
    border-color: #3ee2ff40;
    color: var(--accent-6);
}

.day-cell.key-day-9 {
    background: #ffd16620;
    border-color: #ffd16640;
    color: var(--accent-9);
}

.day-info {
    padding: 1rem;
    background: var(--bg-primary);
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    min-height: 60px;
}

.day-info p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.date-planner {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-top: 1rem;
}

.date-planner label {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.date-output {
    margin-top: 0.75rem;
    padding: 0.85rem 1rem;
    background: var(--bg-primary);
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    color: var(--text-secondary);
    font-size: 0.9rem;
    min-height: 56px;
}

.date-line {
    padding: 0.2rem 0;
    border-bottom: 1px dashed var(--border);
}

.date-line:last-child {
    border-bottom: none;
}

/* --- Why Works Grid --- */
.why-works-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin: 1rem 0;
}

.why-item {
    padding: 1.25rem;
    background: var(--bg-primary);
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
}

.why-item h4 {
    font-size: 0.95rem;
    margin-bottom: 0.5rem;
    color: var(--accent-primary);
}

.why-item p {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* --- Connection Flow --- */
.connection-flow {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
    padding: 1rem 0;
}

/* --- Clock Wheel --- */
.clock-wheel {
    display: flex;
    justify-content: center;
    margin: 1.25rem 0 0.75rem;
}

#clockWheelCanvas {
    width: 100%;
    max-width: 520px;
    height: auto;
    background: radial-gradient(circle at center, #0f0f17 0%, #0b0b12 55%, #0a0a0f 100%);
    border: 1px solid var(--border);
    border-radius: 50%;
}

.clock-caption {
    text-align: center;
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 1rem;
}

.connection-node {
    text-align: center;
    padding: 1.25rem 2.5rem;
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    width: 100%;
    max-width: 360px;
    transition: all 0.3s;
}

.connection-node:hover {
    border-color: var(--accent-primary);
    transform: scale(1.02);
}

.node-final {
    border-color: #3ee2ff60 !important;
    background: linear-gradient(135deg, var(--bg-primary), #101628);
    box-shadow: var(--glow-purple);
}

.conn-label {
    display: block;
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--text-primary);
}

.conn-desc {
    display: block;
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-top: 0.25rem;
}

.connection-line {
    font-size: 1.5rem;
    color: var(--accent-primary);
    padding: 0.25rem 0;
    opacity: 0.6;
}

/* --- Final Equation --- */
.final-equation {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin: 1.5rem 0;
    padding: 1.5rem;
    background: var(--bg-primary);
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
}

.eq-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.05rem;
    color: var(--text-secondary);
}

.eq-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-family: var(--font-mono);
    font-weight: 800;
    font-size: 1.2rem;
}

.eq-item:nth-child(1) .eq-num {
    background: #3ee2ff20;
    color: var(--accent-3);
    border: 2px solid #3ee2ff40;
}

.eq-item:nth-child(2) .eq-num {
    background: #3ee2ff20;
    color: var(--accent-6);
    border: 2px solid #3ee2ff40;
}

.eq-item:nth-child(3) .eq-num {
    background: #ffd16620;
    color: var(--accent-9);
    border: 2px solid #ffd16640;
}

.eq-tag {
    font-size: 0.85rem;
    color: var(--text-muted);
    font-style: italic;
}

/* --- Takeaways --- */
.takeaway-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 2rem;
}

.takeaway-card {
    display: flex;
    align-items: flex-start;
    gap: 1.25rem;
    padding: 1.5rem;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    transition: all 0.3s;
}

.takeaway-card:hover {
    border-color: var(--accent-primary);
    transform: translateX(5px);
}

.takeaway-num {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--accent-primary-dim);
    border: 2px solid #3ee2ff40;
    font-family: var(--font-mono);
    font-weight: 800;
    font-size: 1.1rem;
    color: var(--accent-primary);
}

.takeaway-card h4 {
    font-size: 1.05rem;
    margin-bottom: 0.25rem;
}

.takeaway-card p {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* --- Final Message --- */
.final-message {
    font-size: 1.3rem !important;
    font-weight: 600;
    color: var(--text-primary) !important;
    line-height: 1.6;
    padding: 1rem 0;
}

/* --- Section Nav --- */
.section-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border);
}

/* --- Anchor Trio (3-6-9 Interface) --- */
.anchor-trio {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin: 1.5rem 0;
}

.anchor-item {
    padding: 1.5rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    text-align: center;
}

.anchor-item h4 {
    font-size: 0.95rem;
    margin-bottom: 0.4rem;
}

.anchor-item p {
    font-size: 0.85rem;
}

.anchor-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    font-family: var(--font-mono);
    font-weight: 800;
    font-size: 1.5rem;
    margin-bottom: 0.75rem;
}

.anchor-9 {
    background: linear-gradient(135deg, var(--bg-card), #1a1810);
    border-color: #ffd16640;
}

.anchor-9 .anchor-num {
    background: #ffd16620;
    color: var(--accent-9);
    border: 2px solid #ffd16640;
}

.anchor-36 {
    background: linear-gradient(135deg, var(--bg-card), #101628);
    border-color: #3ee2ff40;
}

.anchor-36 .anchor-num {
    background: #3ee2ff20;
    color: var(--accent-3);
    border: 2px solid #3ee2ff40;
}

.anchor-36b {
    background: linear-gradient(135deg, var(--bg-card), #0a1a20);
    border-color: #3ee2ff40;
}

.anchor-36b .anchor-num {
    background: #3ee2ff20;
    color: var(--accent-6);
    border: 2px solid #3ee2ff40;
}

/* --- Last Digit Sequence --- */
.last-digit-sequence {
    display: flex;
    flex-wrap: wrap;
    gap: 3px;
    margin: 0.5rem 0;
}

.ld-digit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 4px;
    font-family: var(--font-mono);
    font-weight: 600;
    font-size: 0.75rem;
    background: var(--bg-card);
    border: 1px solid var(--border);
    color: var(--text-secondary);
    transition: all 0.2s;
}

.ld-digit:hover {
    transform: scale(1.2);
    z-index: 2;
}

.ld-digit.ld-zero {
    background: #ffd16620;
    border-color: #ffd16650;
    color: var(--accent-9);
    font-weight: 800;
}

.ld-digit.ld-five {
    background: #3ee2ff20;
    border-color: #3ee2ff50;
    color: var(--accent-6);
    font-weight: 800;
}

/* --- Wheel Canvas --- */
.wheel-container {
    display: flex;
    justify-content: center;
    margin: 1.5rem 0;
    position: relative;
}

#wheelCanvas {
    max-width: 100%;
    height: auto;
}

.wheel-tooltip {
    position: absolute;
    background: var(--bg-card);
    border: 1px solid var(--accent-primary);
    border-radius: var(--radius-sm);
    padding: 0.5rem 0.75rem;
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--text-primary);
    pointer-events: none;
    display: none;
    z-index: 10;
    white-space: nowrap;
}

/* --- Clock Facts --- */
.clock-facts {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin: 1.5rem 0;
}

.clock-fact {
    display: flex;
    align-items: flex-start;
    gap: 1.25rem;
    padding: 1.25rem;
    background: var(--bg-primary);
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
}

.clock-fact-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--bg-card);
    border: 2px solid var(--border);
    font-family: var(--font-mono);
    font-weight: 800;
    font-size: 1.3rem;
}

.clock-fact h4 {
    font-size: 1rem;
    margin-bottom: 0.25rem;
}

.clock-fact p {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

/* --- Arc Grid --- */
.arc-grid {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin: 1.5rem 0;
    flex-wrap: wrap;
}

.arc-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.25rem;
    padding: 1.25rem 1.5rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    background: var(--bg-primary);
    min-width: 140px;
    text-align: center;
}

.arc-label {
    font-family: var(--font-mono);
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: 600;
}

.arc-range {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.arc-sum {
    font-family: var(--font-mono);
    font-size: 1.1rem;
    margin-top: 0.25rem;
}

.arc-1 {
    border-color: #3ee2ff40;
}

.arc-1 .arc-label { color: var(--accent-3); }
.arc-1 .arc-sum { color: var(--accent-3); }

.arc-2 {
    border-color: #3ee2ff40;
}

.arc-2 .arc-label { color: var(--accent-6); }
.arc-2 .arc-sum { color: var(--accent-6); }

.arc-3 {
    border-color: #ffd16640;
}

.arc-3 .arc-label { color: var(--accent-9); }
.arc-3 .arc-sum { color: var(--accent-9); }

.arc-plus {
    font-family: var(--font-mono);
    font-size: 1.5rem;
    color: var(--text-muted);
    font-weight: 300;
}

/* --- Proof Box --- */
.proof-box {
    padding: 1.5rem;
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    margin: 1rem 0;
    text-align: center;
}

.proof-line {
    font-family: var(--font-mono);
    font-size: 1.1rem;
    color: var(--text-secondary);
    padding: 0.3rem 0;
}

.proof-result {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--accent-9) !important;
    margin-top: 0.5rem;
    padding-top: 0.75rem;
    border-top: 1px solid var(--border);
}

/* --- Bridge Flow --- */
.bridge-flow {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
    margin: 1.5rem 0;
}

.bridge-step {
    display: flex;
    align-items: center;
    gap: 1rem;
    width: 100%;
    max-width: 480px;
    padding: 0.75rem 1rem;
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.bridge-num {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--accent-primary-dim);
    border: 1px solid #3ee2ff40;
    font-family: var(--font-mono);
    font-weight: 700;
    font-size: 0.75rem;
    color: var(--accent-primary);
}

.bridge-arrow {
    font-size: 1rem;
    color: var(--accent-primary);
    opacity: 0.5;
    padding: 0.1rem 0;
    text-align: center;
}

/* --- Responsive additions --- */
@media (max-width: 1024px) {
    .anchor-trio {
        grid-template-columns: 1fr;
    }

    .arc-grid {
        flex-direction: column;
    }

    .arc-card {
        width: 100%;
    }

    .arc-plus {
        transform: rotate(90deg);
    }
}

@media (max-width: 640px) {
    .clock-fact {
        flex-direction: column;
        text-align: center;
        align-items: center;
    }

    .bridge-step {
        font-size: 0.8rem;
    }
}

/* --- Fibonacci Rectangle --- */
.fib-spiral-container {
    display: flex;
    justify-content: center;
    margin: 1.5rem 0 0.5rem;
    overflow: hidden;
    border-radius: var(--radius-md);
}

#fibSpiralCanvas {
    max-width: 100%;
    height: auto;
}

/* --- Vortex Math Circle --- */
.vortex-circle-container {
    display: flex;
    justify-content: center;
    margin: 1.5rem 0 0.5rem;
}

#vortexCanvas {
    max-width: 100%;
    height: auto;
}

/* --- Frequency Circle --- */
.freq-buttons {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-top: 1rem;
}

.freq-btn {
    min-width: 72px;
}

.freq-btn.active {
    transform: translateY(-1px);
}

.freq-btn.freq-369 {
    border-color: #ffd16660;
    color: #fbbf24;
}

.freq-btn.freq-369.active {
    background: #ffd16620;
    box-shadow: 0 0 18px #ffd16630;
}

.freq-btn.freq-852 {
    border-color: #3ee2ff60;
    color: #67e8f9;
}

.freq-btn.freq-852.active {
    background: #3ee2ff20;
    box-shadow: 0 0 18px #3ee2ff30;
}

.freq-btn.freq-741 {
    border-color: #3ee2ff60;
    color: #97f1ff;
}

.freq-btn.freq-741.active {
    background: #3ee2ff20;
    box-shadow: 0 0 18px #3ee2ff30;
}

.btn-live {
    background: linear-gradient(135deg, #22c55e, #14b8a6);
    color: #04120b;
    border-color: rgba(34, 197, 94, 0.6);
    box-shadow: 0 10px 24px rgba(20, 184, 166, 0.25);
}

.btn-live:hover {
    filter: brightness(1.05);
    transform: translateY(-1px);
}

/* --- Chakra List --- */
.chakra-list {
    list-style: none;
    padding: 0;
    margin: 1rem 0 0;
    display: grid;
    gap: 0.6rem;
}

.chakra-item {
    --chakra-color: #e8e8f0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.5rem 0.75rem 0.5rem 2rem;
    border-radius: var(--radius-md);
    border: 1px solid rgba(232, 232, 240, 0.08);
    background: rgba(10, 10, 15, 0.55);
    position: relative;
    transition: border-color 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease;
}

.chakra-item::before {
    content: '';
    position: absolute;
    left: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    width: 10px;
    height: 10px;
    border-radius: 999px;
    background: var(--chakra-color);
    box-shadow: 0 0 12px color-mix(in srgb, var(--chakra-color) 70%, transparent);
    opacity: 0.6;
    transition: opacity 0.25s ease, transform 0.25s ease;
}

.chakra-name {
    color: var(--chakra-color);
    font-weight: 600;
}

.chakra-hz {
    font-family: var(--font-mono);
    font-size: 0.9rem;
    color: var(--text-secondary);
    opacity: 0.7;
    transform: translateY(2px);
    transition: opacity 0.25s ease, transform 0.25s ease, color 0.25s ease;
}

.chakra-item:hover,
.chakra-item:focus-within {
    border-color: color-mix(in srgb, var(--chakra-color) 55%, transparent);
    box-shadow: 0 0 18px color-mix(in srgb, var(--chakra-color) 35%, transparent);
    transform: translateY(-1px);
}

.chakra-item:hover::before,
.chakra-item:focus-within::before {
    opacity: 1;
    transform: translateY(-50%) scale(1.1);
}

.chakra-item:hover .chakra-hz,
.chakra-item:focus-within .chakra-hz {
    opacity: 1;
    transform: translateY(0);
    color: var(--chakra-color);
}

.chakra-root { --chakra-color: #ef4444; }
.chakra-sacral { --chakra-color: #f97316; }
.chakra-solar { --chakra-color: #facc15; }
.chakra-heart { --chakra-color: #22c55e; }
.chakra-throat { --chakra-color: #38bdf8; }
.chakra-thirdeye { --chakra-color: #6366f1; }
.chakra-crown { --chakra-color: #a855f7; }

/* --- Reveal Animation --- */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

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

/* --- Responsive --- */
@media (max-width: 1024px) {
    .sidebar {
        transform: translateX(-100%);
    }

    .sidebar.open {
        transform: translateX(0);
    }

    .mobile-toggle {
        display: flex;
    }

    .content {
        margin-left: 0;
    }

    .hero-title { font-size: 2.5rem; }

    .slope-comparison,
    .options-grid,
    .why-36-grid,
    .why-works-grid {
        grid-template-columns: 1fr;
    }

    .day-grid {
        grid-template-columns: repeat(6, 1fr);
    }

    .quick-start {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .section {
        padding: 4rem 1rem 3rem;
    }

    .hero-title { font-size: 2rem; }
    .section-title { font-size: 1.6rem; }
    .card { padding: 1.25rem; }

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

    .hero-steps-preview {
        flex-direction: column;
    }

    .preview-arrow {
        transform: rotate(90deg);
    }

    .calculator {
        flex-direction: column;
    }

    .fib-table .pattern-row {
        grid-template-columns: 1fr auto;
    }

    .slideshow {
        grid-template-columns: 1fr;
    }

    .slide-btn {
        width: 100%;
        border-radius: var(--radius-sm);
    }
}
