/* ==========================================================================
   MINO — DAILY FOCUS FOLIO & TASK LEDGER
   Curated Atelier Design System: Burgundy, Brown, Beige & Cream
   Tactile Micro-Interactions • Fluid Motion • Editorial Typography
   ========================================================================== */

/* ==========================================================================
   1. DESIGN TOKENS & ATELIER PALETTE (Burgundy, Brown, Beige, Cream)
   ========================================================================== */

:root {
    /* Cream & Parchment Base Layers */
    --paper-base: #FAF7F2;          /* Soft warm cream unbleached Japanese paper */
    --paper-surface: #F3ECE1;       /* Warm oat cream for panels & secondary elements */
    --paper-surface-muted: #EADFCF; /* Deeper cream-beige for inputs & active tab highlights */
    --paper-card: #FFFFFF;          /* Pure warm ivory white for primary content cards */
    --paper-white: #FFFFFF;
    --paper-elevated: #FFFDF9;      /* Elevated omnibar & modal surface */

    /* Roasted Brown & Walnut Inks */
    --ink-primary: #26160F;         /* Deep Roasted Espresso Brown (16.2:1 contrast) */
    --ink-secondary: #4E3425;       /* Warm Walnut Brown (9.1:1 contrast) */
    --ink-tertiary: #6E4D38;        /* Chestnut Umber (6.2:1 contrast) */
    --ink-muted: #7E6250;           /* Warm Sepia Hazelnut (4.8:1 contrast) */
    --ink-faint: #B39B88;           /* Faint Cafe-au-Lait for brackets & metadata */

    /* Burgundy & Wine Accents (Bordeaux, Oxblood, Ruby) */
    --pigment-burgundy: #751425;        /* Deep Royal Burgundy — Primary Accent & Brand */
    --pigment-burgundy-hover: #921E33;  /* Luminous Wine Crimson */
    --pigment-burgundy-deep: #540D1A;   /* Velvet Bordeaux */
    --pigment-burgundy-tint: rgba(117, 20, 37, 0.08); /* 8% Wine Wash */
    --pigment-burgundy-tint-strong: rgba(117, 20, 37, 0.16);
    --pigment-burgundy-glow: rgba(117, 20, 37, 0.28);

    /* Backwards compatibility aliases */
    --pigment-cinnabar: var(--pigment-burgundy);
    --pigment-cinnabar-tint: var(--pigment-burgundy-tint);
    --pigment-crimson: var(--pigment-burgundy-hover);

    /* Warm Earthy Accents */
    --pigment-amber: #9E5616;           /* Caramel / Warm Amber for Medium Priority */
    --pigment-amber-tint: rgba(158, 86, 22, 0.09);
    --pigment-ochre: #8D541E;           /* Roasted Ochre for Sandbox / Dev tags */
    --pigment-ochre-tint: rgba(141, 84, 30, 0.1);
    --pigment-forest: #245A3A;          /* Deep Forest Pine for Cleared Tasks */
    --pigment-forest-tint: rgba(36, 90, 58, 0.09);

    /* Architectural Hairlines & Rules (Warm Umber/Beige Tones) */
    --rule-hairline: rgba(78, 52, 37, 0.14); /* Refined warm rule */
    --rule-medium: rgba(78, 52, 37, 0.28);
    --rule-solid: #DECDBB;                   /* Warm beige border */
    --rule-heavy: #3D2619;                   /* Deep espresso border */

    /* Shadows & Warm Depth */
    --shadow-subtle: 2px 2px 0px rgba(38, 22, 15, 0.05);
    --shadow-soft: 0 4px 16px rgba(50, 30, 20, 0.06);
    --shadow-card: 3px 3px 0px rgba(38, 22, 15, 0.08);
    --shadow-hover: 4px 6px 18px rgba(117, 20, 37, 0.12), 3px 3px 0px rgba(38, 22, 15, 0.12);
    --shadow-heavy: 0 16px 40px rgba(38, 22, 15, 0.2), 4px 4px 0px rgba(38, 22, 15, 0.12);
    --shadow-burgundy: 0 6px 20px rgba(117, 20, 37, 0.28);

    /* Typographic System */
    --font-serif: 'Newsreader', Georgia, serif;
    --font-sans: 'Space Grotesk', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-mono: 'JetBrains Mono', monospace;

    /* Systematic Scale */
    --text-2xs: 0.6875rem; /* 11px */
    --text-xs: 0.75rem;    /* 12px */
    --text-sm: 0.8438rem;  /* 13.5px */
    --text-base: 0.9375rem;/* 15px */
    --text-md: 1.0625rem;  /* 17px */
    --text-lg: 1.25rem;    /* 20px */
    --text-xl: 1.625rem;   /* 26px */
    --text-2xl: clamp(1.85rem, 3.8vw, 2.75rem); /* Editorial Headline */

    /* Strict Spacing Scale */
    --space-1: 4px;
    --space-2: 8px;
    --space-3: 12px;
    --space-4: 16px;
    --space-5: 24px;
    --space-6: 32px;
    --space-8: 48px;
    --space-10: 64px;

    /* Transitions & Motion Physics */
    --transition-fast: 0.14s cubic-bezier(0.16, 1, 0.3, 1);
    --transition-medium: 0.24s cubic-bezier(0.16, 1, 0.3, 1);
    --transition-smooth: 0.38s cubic-bezier(0.16, 1, 0.3, 1);
    --transition-spring: 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* ==========================================================================
   2. RESET, BASE & AMBIENT BACKDROP
   ========================================================================== */

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
    background-color: var(--paper-base);
}

body.folio-theme {
    min-height: 100vh;
    background-color: var(--paper-base);
    color: var(--ink-primary);
    font-family: var(--font-sans);
    font-size: var(--text-base);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    position: relative;
    overflow-x: hidden;
}

/* Ambient Decorative Background Glow Orbs */
.ambient-backdrop {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.ambient-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.45;
    will-change: transform;
    animation: ambientFloat 18s ease-in-out infinite alternate;
}

.ambient-orb-1 {
    top: -80px;
    right: 5%;
    width: 480px;
    height: 480px;
    background: radial-gradient(circle, rgba(117, 20, 37, 0.15) 0%, rgba(243, 236, 225, 0) 70%);
}

.ambient-orb-2 {
    top: 40%;
    left: -120px;
    width: 540px;
    height: 540px;
    background: radial-gradient(circle, rgba(234, 223, 207, 0.6) 0%, rgba(250, 247, 242, 0) 70%);
    animation-duration: 24s;
    animation-delay: -6s;
}

.ambient-orb-3 {
    bottom: -100px;
    right: 15%;
    width: 420px;
    height: 420px;
    background: radial-gradient(circle, rgba(158, 86, 22, 0.1) 0%, rgba(250, 247, 242, 0) 70%);
    animation-duration: 20s;
    animation-delay: -12s;
}

@keyframes ambientFloat {
    0% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(25px, 20px) scale(1.05); }
    100% { transform: translate(-20px, 35px) scale(0.96); }
}

::selection {
    background: var(--pigment-burgundy);
    color: var(--paper-white);
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* ==========================================================================
   3. SCROLL PROGRESS BAR & KEYFRAME ANIMATIONS
   ========================================================================== */

.scroll-progress-bar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--pigment-burgundy) 0%, #A52B42 50%, var(--ink-secondary) 100%);
    transform-origin: 0 50%;
    transform: scaleX(0);
    z-index: 1000;
    pointer-events: none;
    box-shadow: 0 0 10px rgba(117, 20, 37, 0.5);
    transition: transform 0.08s ease-out;
}

/* Keyframe Animations */
@keyframes ledgerRowIn {
    0% {
        opacity: 0;
        transform: translateY(8px) scale(0.99);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes taskExit {
    0% {
        opacity: 1;
        transform: translateX(0);
        max-height: 80px;
    }
    100% {
        opacity: 0;
        transform: translateX(30px);
        max-height: 0;
        padding-top: 0;
        padding-bottom: 0;
        margin-bottom: 0;
        border-color: transparent;
    }
}

@keyframes checkPop {
    0% {
        transform: scale(0.4);
        opacity: 0;
    }
    70% {
        transform: scale(1.2);
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

@keyframes timerPulse {
    0%, 100% {
        color: var(--pigment-burgundy);
        text-shadow: 0 0 16px rgba(117, 20, 37, 0.25);
    }
    50% {
        color: var(--ink-primary);
        text-shadow: none;
    }
}

@keyframes modalSpringIn {
    0% {
        opacity: 0;
        transform: translateY(20px) scale(0.97);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes toastIn {
    0% {
        opacity: 0;
        transform: translateX(20px) scale(0.95);
    }
    100% {
        opacity: 1;
        transform: translateX(0) scale(1);
    }
}

@keyframes toastOut {
    0% {
        opacity: 1;
        transform: translateX(0);
    }
    100% {
        opacity: 0;
        transform: translateX(20px);
    }
}

@keyframes floatBob {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-4px); }
}

@keyframes badgePulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

/* ==========================================================================
   4. SCROLL REVEAL UTILITY CLASSES & MOTION PHYSICS
   ========================================================================== */

[data-reveal] {
    opacity: 0;
    transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.7s cubic-bezier(0.16, 1, 0.3, 1),
                filter 0.7s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: opacity, transform, filter;
}

[data-reveal="fade-up"] {
    transform: translateY(28px);
    filter: blur(3px);
}

[data-reveal="fade-down"] {
    transform: translateY(-24px);
    filter: blur(3px);
}

[data-reveal="fade-in"] {
    transform: translateY(0);
    filter: blur(4px);
}

[data-reveal="fade-left"] {
    transform: translateX(28px);
    filter: blur(3px);
}

[data-reveal="fade-right"] {
    transform: translateX(-28px);
    filter: blur(3px);
}

[data-reveal="scale-up"],
[data-reveal="zoom-in"] {
    transform: scale(0.94);
    filter: blur(3px);
}

[data-reveal="blur-in"] {
    transform: none;
    filter: blur(8px);
}

[data-reveal].revealed {
    opacity: 1;
    transform: translate(0, 0) scale(1);
    filter: blur(0);
}

.reveal-delay-1 { transition-delay: 0.08s; }
.reveal-delay-2 { transition-delay: 0.16s; }
.reveal-delay-3 { transition-delay: 0.24s; }
.reveal-delay-4 { transition-delay: 0.32s; }
.reveal-delay-5 { transition-delay: 0.40s; }
.reveal-delay-6 { transition-delay: 0.48s; }

/* ==========================================================================
   5. EDITORIAL MASTHEAD HEADER
   ========================================================================== */

.masthead-wrapper {
    position: sticky;
    top: 0;
    background: var(--paper-base);
    border-bottom: 1px solid var(--rule-hairline);
    z-index: 100;
    padding: var(--space-2) 0;
    transition: background 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease, backdrop-filter 0.3s ease;
}

.masthead-wrapper.navbar-scrolled {
    background: rgba(250, 247, 242, 0.92);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid rgba(117, 20, 37, 0.16);
    box-shadow: 0 4px 20px rgba(38, 22, 15, 0.06);
}

.masthead-container {
    max-width: 1160px;
    margin: 0 auto;
    padding: 0 var(--space-5);
}

.masthead-topline {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-4);
    min-height: 38px;
}

.masthead-brand {
    display: flex;
    align-items: center;
}

.brand-link {
    display: inline-flex;
    align-items: baseline;
    gap: 6px;
    text-decoration: none;
    color: var(--ink-primary);
    transition: transform var(--transition-fast);
}

.brand-link:hover {
    transform: scale(1.02);
}

.brand-monogram {
    font-family: var(--font-mono);
    font-weight: 700;
    font-size: var(--text-md);
    color: var(--pigment-burgundy);
    transition: color var(--transition-fast);
}

.brand-title {
    font-family: var(--font-serif);
    font-size: var(--text-lg);
    font-weight: 600;
    font-style: italic;
    letter-spacing: -0.02em;
    color: var(--ink-primary);
}

.brand-edition {
    font-family: var(--font-mono);
    font-size: var(--text-2xs);
    font-weight: 600;
    color: var(--ink-muted);
    border-left: 1px solid var(--rule-hairline);
    padding-left: 6px;
    margin-left: 2px;
}

.masthead-center-meta {
    display: flex;
    align-items: center;
    gap: 6px;
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    color: var(--ink-secondary);
}

.meta-label {
    font-weight: 700;
    color: var(--ink-muted);
}

.meta-value {
    font-weight: 600;
    color: var(--ink-primary);
}

.meta-sep {
    color: var(--ink-faint);
}

.meta-date {
    color: var(--ink-secondary);
}

.masthead-actions {
    display: flex;
    align-items: center;
    gap: var(--space-2);
}

.folio-btn-meta {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: transparent;
    border: 1px solid var(--rule-hairline);
    color: var(--ink-secondary);
    font-family: var(--font-mono);
    font-size: var(--text-2xs);
    font-weight: 600;
    padding: 4px 8px;
    cursor: pointer;
    border-radius: 2px;
    transition: all var(--transition-fast);
}

.folio-btn-meta svg {
    width: 13px;
    height: 13px;
    transition: transform var(--transition-fast);
}

.folio-btn-meta kbd {
    background: var(--paper-surface);
    border: 1px solid var(--rule-hairline);
    padding: 1px 4px;
    font-size: 0.65rem;
    font-family: var(--font-mono);
    color: var(--ink-primary);
}

.folio-btn-meta:hover {
    border-color: var(--pigment-burgundy);
    color: var(--pigment-burgundy);
    background: var(--paper-surface);
    transform: translateY(-1px);
}

.folio-btn-meta:hover svg {
    transform: scale(1.1);
}

.folio-btn-meta.playing {
    border-color: var(--pigment-burgundy);
    color: var(--pigment-burgundy);
    background: var(--pigment-burgundy-tint);
}

/* ==========================================================================
   6. MAIN EDITORIAL WORKSPACE & HERO BANNER
   ========================================================================== */

.main-content {
    position: relative;
    z-index: 1;
    padding: var(--space-6) 0 var(--space-10);
}

.folio-container {
    max-width: 1160px;
    margin: 0 auto;
    padding: 0 var(--space-5);
}

.folio-hero-banner {
    margin-bottom: var(--space-8);
}

.hero-edition-row {
    display: flex;
    align-items: center;
    gap: var(--space-4);
    margin-bottom: var(--space-3);
    flex-wrap: wrap;
}

.folio-stamp {
    font-family: var(--font-mono);
    font-size: var(--text-2xs);
    font-weight: 700;
    letter-spacing: 0.08em;
    color: var(--pigment-burgundy);
    border: 1px solid var(--pigment-burgundy);
    background: var(--pigment-burgundy-tint);
    padding: 2px 6px;
    border-radius: 2px;
    white-space: nowrap;
    transition: all var(--transition-fast);
}

.folio-rule-line {
    flex: 1;
    height: 1px;
    background: var(--rule-hairline);
    min-width: 30px;
}

.starter-links-wrap {
    display: flex;
    align-items: center;
    gap: 6px;
    font-family: var(--font-mono);
    font-size: var(--text-xs);
}

.starters-label {
    font-weight: 700;
    color: var(--ink-muted);
}

.starter-text-btn {
    background: none;
    border: none;
    color: var(--ink-secondary);
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    font-weight: 500;
    cursor: pointer;
    padding: 2px 5px;
    border-radius: 2px;
    transition: all var(--transition-fast);
}

.starter-text-btn:hover {
    color: var(--pigment-burgundy);
    background: var(--paper-surface);
    transform: translateY(-1px);
    text-decoration: underline;
}

.starter-sep {
    color: var(--ink-faint);
}

.folio-headline {
    font-family: var(--font-serif);
    font-size: var(--text-2xl);
    font-weight: 400;
    line-height: 1.18;
    letter-spacing: -0.02em;
    color: var(--ink-primary);
    margin-bottom: var(--space-4);
    max-width: 880px;
}

.folio-headline em {
    font-style: italic;
    font-weight: 600;
    color: var(--pigment-burgundy);
}

/* 5-Second Value Pillars (Cream & Beige Card Containers) */
.folio-value-pillars {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-4);
    margin-bottom: var(--space-5);
    padding: var(--space-3) var(--space-4);
    background: var(--paper-surface);
    border: 1px solid var(--rule-solid);
    border-radius: 2px;
    box-shadow: var(--shadow-subtle);
    transition: transform var(--transition-medium), box-shadow var(--transition-medium);
}

.folio-value-pillars:hover {
    box-shadow: var(--shadow-card);
}

.pillar-item {
    display: flex;
    align-items: flex-start;
    gap: var(--space-3);
    transition: transform var(--transition-fast);
}

.pillar-item:hover {
    transform: translateY(-1px);
}

.pillar-num {
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    font-weight: 700;
    color: var(--pigment-burgundy);
    padding-top: 1px;
}

.pillar-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.pillar-text strong {
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    font-weight: 700;
    color: var(--ink-primary);
    letter-spacing: 0.02em;
}

.pillar-text span {
    font-size: var(--text-xs);
    color: var(--ink-muted);
    line-height: 1.35;
}

/* 5-Second Next Step Indicator */
.capture-desk-wrapper {
    display: flex;
    flex-direction: column;
    gap: var(--space-2);
}

.capture-instruction-bar {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    flex-wrap: wrap;
    padding: 0 var(--space-1);
}

.next-step-badge {
    font-weight: 700;
    color: var(--pigment-burgundy);
    letter-spacing: 0.04em;
}

.next-step-text {
    color: var(--ink-secondary);
}

.next-step-text kbd {
    background: var(--paper-surface);
    border: 1px solid var(--rule-hairline);
    padding: 1px 5px;
    font-size: 0.68rem;
    color: var(--ink-primary);
}

/* ==========================================================================
   7. CAPTURE DESK (Warm Parchment & Burgundy Focus)
   ========================================================================== */

.capture-desk {
    background: var(--paper-white);
    border: 1.5px solid var(--rule-heavy);
    border-radius: 2px;
    box-shadow: var(--shadow-card);
    padding: var(--space-4) var(--space-5);
    transition: box-shadow var(--transition-fast), border-color var(--transition-fast), transform var(--transition-fast);
}

.capture-desk:focus-within {
    border-color: var(--pigment-burgundy);
    box-shadow: 4px 4px 0px rgba(117, 20, 37, 0.18), 0 8px 24px rgba(38, 22, 15, 0.06);
    transform: translateY(-1px);
}

.capture-form {
    display: flex;
    flex-direction: column;
    gap: var(--space-3);
}

.capture-input-line {
    display: flex;
    align-items: baseline;
    gap: var(--space-3);
}

.prompt-symbol {
    font-family: var(--font-mono);
    font-size: var(--text-lg);
    font-weight: 700;
    color: var(--pigment-burgundy);
    user-select: none;
    transition: transform var(--transition-fast);
}

.capture-desk:focus-within .prompt-symbol {
    transform: translateX(2px);
}

.capture-input-line input {
    width: 100%;
    border: none;
    outline: none;
    background: transparent;
    font-family: var(--font-serif);
    font-size: var(--text-lg);
    font-weight: 400;
    color: var(--ink-primary);
    padding: 2px 0;
}

.capture-input-line input::placeholder {
    color: var(--ink-muted);
    font-style: italic;
}

.capture-meta-line {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-4);
    padding-top: var(--space-3);
    border-top: 1px dashed var(--rule-hairline);
    flex-wrap: wrap;
}

.meta-selectors-group {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    flex-wrap: wrap;
}

.editorial-select-wrap {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: var(--paper-surface);
    border: 1px solid var(--rule-solid);
    padding: 3px 8px;
    border-radius: 2px;
    font-family: var(--font-mono);
    font-size: var(--text-2xs);
    transition: border-color var(--transition-fast), background var(--transition-fast);
}

.editorial-select-wrap:hover,
.editorial-select-wrap:focus-within {
    border-color: var(--pigment-burgundy);
    background: var(--paper-surface-muted);
}

.select-label {
    font-weight: 700;
    color: var(--ink-muted);
}

.editorial-select-wrap select,
.editorial-select-wrap input {
    background: transparent;
    border: none;
    outline: none;
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    font-weight: 600;
    color: var(--ink-primary);
    cursor: pointer;
}

/* Primary Action Button — Burgundy Power */
.folio-submit-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--pigment-burgundy);
    color: var(--paper-white);
    border: 1px solid var(--pigment-burgundy);
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    padding: 8px 16px;
    cursor: pointer;
    border-radius: 2px;
    box-shadow: var(--shadow-subtle);
    transition: all var(--transition-fast);
}

.folio-submit-btn kbd {
    background: rgba(255, 255, 255, 0.2);
    font-family: var(--font-mono);
    font-size: 0.68rem;
    padding: 0 4px;
    border-radius: 2px;
    color: var(--paper-white);
}

.folio-submit-btn:hover {
    background: var(--pigment-burgundy-hover);
    border-color: var(--pigment-burgundy-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-burgundy);
}

.folio-submit-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(117, 20, 37, 0.2);
}

/* ==========================================================================
   8. FOLIO ASYMMETRIC GRID (68% LEDGER / 32% CADENCE)
   ========================================================================== */

.folio-layout-grid {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: var(--space-6);
    align-items: start;
}

/* ==========================================================================
   9. LEDGER COLUMN (LEFT REGISTER)
   ========================================================================== */

.ledger-column {
    display: flex;
    flex-direction: column;
    background: var(--paper-white);
    border: 1px solid var(--rule-solid);
    border-radius: 2px;
    box-shadow: var(--shadow-card);
    padding: var(--space-5);
    transition: box-shadow var(--transition-medium);
}

.ledger-column:hover {
    box-shadow: 4px 6px 20px rgba(38, 22, 15, 0.08);
}

/* Ledger Toolbar & Ruled Tabs */
.ledger-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-4);
    flex-wrap: wrap;
    padding-bottom: var(--space-4);
    border-bottom: 1px solid var(--rule-hairline);
    margin-bottom: var(--space-4);
}

.ledger-tabs {
    display: flex;
    align-items: center;
    gap: var(--space-1);
    flex-wrap: wrap;
}

.ledger-tab {
    background: transparent;
    border: 1px solid transparent;
    color: var(--ink-muted);
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    font-weight: 600;
    padding: 5px 10px;
    cursor: pointer;
    border-radius: 2px;
    transition: all var(--transition-fast);
}

.ledger-tab .tab-index {
    color: var(--ink-faint);
    margin-right: 2px;
}

.ledger-tab:hover {
    color: var(--ink-primary);
    background: var(--paper-surface);
    transform: translateY(-1px);
}

.ledger-tab.active {
    background: var(--paper-surface);
    color: var(--pigment-burgundy);
    border-color: var(--rule-solid);
    border-bottom: 2px solid var(--pigment-burgundy);
    font-weight: 700;
}

.ledger-tab.active .tab-index {
    color: var(--pigment-burgundy);
}

.ledger-toolbar-meta {
    display: flex;
    align-items: center;
    gap: var(--space-3);
}

.ledger-search-box {
    display: flex;
    align-items: center;
    gap: 4px;
    background: var(--paper-surface);
    border: 1px solid var(--rule-solid);
    padding: 4px 8px;
    border-radius: 2px;
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    transition: border-color var(--transition-fast), background var(--transition-fast);
}

.ledger-search-box:focus-within {
    border-color: var(--pigment-burgundy);
    background: var(--paper-surface-muted);
}

.search-bracket {
    color: var(--pigment-burgundy);
    font-weight: 700;
}

.ledger-search-box input {
    border: none;
    outline: none;
    background: transparent;
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    color: var(--ink-primary);
    width: 120px;
}

.ledger-clear-btn {
    background: transparent;
    border: 1px solid var(--rule-solid);
    color: var(--ink-muted);
    font-family: var(--font-mono);
    font-size: var(--text-2xs);
    font-weight: 700;
    text-transform: uppercase;
    padding: 4px 8px;
    cursor: pointer;
    border-radius: 2px;
    transition: all var(--transition-fast);
}

.ledger-clear-btn:hover {
    color: var(--pigment-burgundy);
    border-color: var(--pigment-burgundy);
    background: var(--pigment-burgundy-tint);
    transform: translateY(-1px);
}

/* Ledger Header */
.ledger-header-row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    margin-bottom: var(--space-3);
    padding-bottom: var(--space-2);
    border-bottom: 2px solid var(--ink-primary);
}

.ledger-header-left {
    display: flex;
    align-items: baseline;
    gap: var(--space-3);
}

.ledger-section-title {
    font-family: var(--font-serif);
    font-size: var(--text-lg);
    font-weight: 600;
    color: var(--ink-primary);
}

.ledger-sub-tag {
    font-family: var(--font-mono);
    font-size: var(--text-2xs);
    font-weight: 700;
    letter-spacing: 0.06em;
    color: var(--ink-muted);
}

.ledger-count-num {
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    font-weight: 700;
    color: var(--pigment-burgundy);
    background: var(--pigment-burgundy-tint);
    padding: 2px 6px;
    border-radius: 2px;
}

/* Scrollable Task List */
.ledger-list-wrapper {
    min-height: 340px;
    max-height: 560px;
    overflow-y: auto;
    padding-right: 4px;
}

.folio-task-list {
    list-style: none;
    display: flex;
    flex-direction: column;
}

/* Individual Folio Task Item (Ruled Ledger Row) */
.task-item {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: baseline;
    gap: var(--space-4);
    padding: var(--space-3) var(--space-2);
    border-bottom: 1px solid var(--rule-hairline);
    background: transparent;
    transition: background var(--transition-fast), transform var(--transition-fast), padding var(--transition-fast);
    animation: ledgerRowIn 0.28s cubic-bezier(0.16, 1, 0.3, 1) both;
    position: relative;
}

.task-item:hover {
    background: var(--paper-surface);
    transform: translateX(3px);
}

.task-item.task-exiting {
    animation: taskExit 0.25s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.task-item.completed {
    opacity: 0.55;
}

.task-item.completed .task-text {
    text-decoration: line-through;
    text-decoration-color: var(--pigment-burgundy);
    color: var(--ink-muted);
}

/* Custom Checkbox (Cream/Brown/Forest) */
.custom-checkbox-wrap {
    position: relative;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    padding-top: 2px;
}

.task-checkbox {
    position: absolute;
    opacity: 0;
    width: 16px;
    height: 16px;
    cursor: pointer;
}

.checkbox-custom {
    width: 16px;
    height: 16px;
    border: 1.5px solid var(--ink-primary);
    border-radius: 2px;
    background: var(--paper-white);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast);
}

.checkbox-custom svg {
    width: 10px;
    height: 10px;
    color: var(--paper-white);
    opacity: 0;
    transform: scale(0.5);
    transition: all var(--transition-fast);
}

.task-checkbox:checked + .checkbox-custom {
    background: var(--pigment-forest);
    border-color: var(--pigment-forest);
    animation: checkPop 0.22s ease-out;
}

.task-checkbox:checked + .checkbox-custom svg {
    opacity: 1;
    transform: scale(1);
}

/* Task Details & Metadata */
.task-details {
    display: flex;
    flex-direction: column;
    gap: 4px;
    overflow: hidden;
}

.task-text {
    font-family: var(--font-sans);
    font-size: var(--text-base);
    font-weight: 500;
    color: var(--ink-primary);
    line-height: 1.4;
    word-break: break-word;
    transition: color var(--transition-fast);
}

.task-tags-row {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

/* Bracketed Typographic Stamps */
.task-pill {
    font-family: var(--font-mono);
    font-size: var(--text-2xs);
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    display: inline-flex;
    align-items: center;
    gap: 3px;
    padding: 1px 5px;
    border-radius: 2px;
}

.task-pill svg {
    width: 10px;
    height: 10px;
}

.pill-prio-high {
    color: var(--pigment-burgundy);
    background: var(--pigment-burgundy-tint);
    border: 1px solid rgba(117, 20, 37, 0.3);
}

.pill-prio-medium {
    color: var(--pigment-amber);
    background: var(--pigment-amber-tint);
    border: 1px solid rgba(158, 86, 22, 0.3);
}

.pill-prio-low {
    color: var(--pigment-forest);
    background: var(--pigment-forest-tint);
    border: 1px solid rgba(36, 90, 58, 0.3);
}

.pill-category {
    color: var(--ink-secondary);
    background: var(--paper-surface);
    border: 1px solid var(--rule-solid);
}

.pill-due {
    color: var(--ink-muted);
    background: transparent;
    border: 1px dashed var(--rule-solid);
}

.pill-due.overdue {
    color: var(--pigment-burgundy);
    border-color: var(--pigment-burgundy);
    background: var(--pigment-burgundy-tint);
    font-weight: 700;
}

.pill-due.due-soon {
    color: var(--pigment-amber);
    border-color: var(--pigment-amber);
    background: var(--pigment-amber-tint);
}

/* Task Context Actions */
.task-actions {
    display: flex;
    align-items: center;
    gap: 4px;
    opacity: 0.6;
    transition: opacity var(--transition-fast);
}

.task-item:hover .task-actions {
    opacity: 1;
}

.task-action-btn {
    background: transparent;
    border: 1px solid var(--rule-solid);
    color: var(--ink-muted);
    width: 24px;
    height: 24px;
    border-radius: 2px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.task-action-btn svg {
    width: 11px;
    height: 11px;
}

.task-action-btn:hover {
    color: var(--ink-primary);
    border-color: var(--ink-primary);
    background: var(--paper-white);
    transform: scale(1.08);
}

.btn-delete:hover {
    color: var(--pigment-burgundy);
    border-color: var(--pigment-burgundy);
    background: var(--pigment-burgundy-tint);
}

.inline-edit-input {
    width: 100%;
    background: var(--paper-white);
    border: 1.5px solid var(--pigment-burgundy);
    border-radius: 2px;
    color: var(--ink-primary);
    padding: 4px 8px;
    font-family: var(--font-sans);
    font-size: var(--text-base);
    outline: none;
    box-shadow: 0 0 0 2px var(--pigment-burgundy-tint);
}

/* Empty State */
.folio-empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: var(--space-8) var(--space-4);
}

.empty-mark {
    font-family: var(--font-serif);
    font-size: 2.2rem;
    color: var(--ink-faint);
    margin-bottom: var(--space-2);
}

.empty-title {
    font-family: var(--font-serif);
    font-size: var(--text-md);
    font-weight: 600;
    color: var(--ink-primary);
    margin-bottom: var(--space-1);
}

.empty-text {
    font-family: var(--font-sans);
    font-size: var(--text-xs);
    color: var(--ink-muted);
    max-width: 280px;
}

/* Footnote Strip */
.folio-footnote-bar {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    padding-top: var(--space-3);
    margin-top: var(--space-3);
    border-top: 1px solid var(--rule-hairline);
    font-family: var(--font-mono);
    font-size: var(--text-2xs);
    color: var(--ink-muted);
    flex-wrap: wrap;
}

.fn-sep {
    color: var(--ink-faint);
}

kbd {
    background: var(--paper-surface);
    border: 1px solid var(--rule-solid);
    font-family: var(--font-mono);
    font-size: 0.65rem;
    padding: 1px 4px;
    border-radius: 2px;
    color: var(--ink-primary);
}

/* ==========================================================================
   10. CADENCE COLUMN (RIGHT ARCHITECTURAL COMPANION)
   ========================================================================== */

.cadence-column {
    display: flex;
    flex-direction: column;
    gap: var(--space-5);
}

.cadence-box {
    background: var(--paper-white);
    border: 1px solid var(--rule-solid);
    border-radius: 2px;
    box-shadow: var(--shadow-card);
    padding: var(--space-4) var(--space-5);
    transition: transform var(--transition-medium), box-shadow var(--transition-medium);
}

.cadence-box:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}

.cadence-box-header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    margin-bottom: var(--space-3);
    padding-bottom: var(--space-2);
    border-bottom: 1px solid var(--rule-hairline);
}

.box-num {
    font-family: var(--font-mono);
    font-size: var(--text-2xs);
    font-weight: 700;
    color: var(--pigment-burgundy);
}

.box-title {
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--ink-primary);
}

/* Velocity Tally Gauge */
.tally-gauge-wrap {
    display: flex;
    align-items: center;
    gap: var(--space-4);
    margin-bottom: var(--space-3);
}

.tally-progress-ring-box {
    position: relative;
    width: 76px;
    height: 76px;
    flex-shrink: 0;
}

.progress-ring {
    transform: rotate(-90deg);
}

.progress-ring-bg {
    fill: transparent;
    stroke: var(--paper-surface);
}

.progress-ring-bar {
    fill: transparent;
    stroke: var(--pigment-burgundy);
    stroke-linecap: square;
    stroke-dasharray: 263.89;
    stroke-dashoffset: 263.89;
    transition: stroke-dashoffset 0.5s cubic-bezier(0.16, 1, 0.3, 1), stroke 0.3s ease;
}

.progress-ring-text {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.progress-percent {
    font-family: var(--font-mono);
    font-size: var(--text-md);
    font-weight: 700;
    color: var(--ink-primary);
}

.tally-metrics-column {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
}

.tally-metric-row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    font-family: var(--font-mono);
    font-size: var(--text-xs);
}

.tally-label {
    color: var(--ink-muted);
}

.tally-val {
    font-weight: 700;
    color: var(--ink-primary);
}

.text-cleared {
    color: var(--pigment-forest);
}

.cadence-status-text {
    font-family: var(--font-serif);
    font-style: italic;
    font-size: var(--text-xs);
    color: var(--ink-muted);
    border-top: 1px dashed var(--rule-hairline);
    padding-top: var(--space-2);
}

/* Focus Cadence Timer */
.cadence-timer-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-3);
}

.cadence-time-readout {
    font-family: var(--font-mono);
    font-size: 2.2rem;
    font-weight: 700;
    letter-spacing: -0.04em;
    color: var(--ink-primary);
    transition: color 0.3s ease;
}

.cadence-time-readout.is-ticking {
    animation: timerPulse 2s ease-in-out infinite;
}

.cadence-intervals-row {
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
    justify-content: center;
}

.cadence-interval-btn {
    background: transparent;
    border: 1px solid var(--rule-solid);
    color: var(--ink-muted);
    font-family: var(--font-mono);
    font-size: var(--text-2xs);
    font-weight: 600;
    padding: 3px 6px;
    cursor: pointer;
    border-radius: 2px;
    transition: all var(--transition-fast);
}

.cadence-interval-btn:hover {
    color: var(--pigment-burgundy);
    border-color: var(--pigment-burgundy);
    background: var(--paper-surface);
}

.cadence-interval-btn.active {
    background: var(--pigment-burgundy);
    color: var(--paper-white);
    border-color: var(--pigment-burgundy);
}

.cadence-controls-row {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    width: 100%;
}

.cadence-btn-action {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    background: var(--pigment-burgundy);
    color: var(--paper-white);
    border: 1px solid var(--pigment-burgundy);
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    font-weight: 700;
    text-transform: uppercase;
    padding: 8px 12px;
    cursor: pointer;
    border-radius: 2px;
    box-shadow: var(--shadow-subtle);
    transition: all var(--transition-fast);
}

.cadence-btn-action svg {
    width: 12px;
    height: 12px;
}

.cadence-btn-action:hover {
    background: var(--pigment-burgundy-hover);
    border-color: var(--pigment-burgundy-hover);
    box-shadow: var(--shadow-burgundy);
    transform: translateY(-1px);
}

.cadence-btn-secondary {
    background: transparent;
    border: 1px solid var(--rule-solid);
    color: var(--ink-secondary);
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    font-weight: 600;
    padding: 8px 12px;
    cursor: pointer;
    border-radius: 2px;
    transition: all var(--transition-fast);
}

.cadence-btn-secondary:hover {
    color: var(--ink-primary);
    border-color: var(--ink-primary);
    background: var(--paper-surface);
}

/* Manifesto Box */
.folio-manifesto-box {
    border-left: 3px solid var(--pigment-burgundy);
    padding-left: var(--space-3);
    font-family: var(--font-serif);
    background: var(--paper-surface);
    padding: var(--space-3) var(--space-4);
    border-radius: 0 2px 2px 0;
    box-shadow: var(--shadow-subtle);
}

.manifesto-lead {
    font-weight: 600;
    font-style: italic;
    font-size: var(--text-sm);
    color: var(--ink-primary);
    margin-bottom: 2px;
}

.manifesto-body {
    font-size: var(--text-xs);
    color: var(--ink-muted);
    line-height: 1.45;
}

/* ==========================================================================
   11. EDITORIAL MINIMAL FOOTER
   ========================================================================== */

.folio-footer {
    border-top: 1px solid var(--rule-solid);
    padding: var(--space-6) 0 var(--space-5);
    background: var(--paper-surface);
    position: relative;
    z-index: 1;
}

.footer-grid-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--space-3);
    flex-wrap: wrap;
    gap: var(--space-3);
}

.footer-col-main {
    display: flex;
    align-items: baseline;
    gap: var(--space-3);
}

.footer-mast-name {
    font-family: var(--font-mono);
    font-weight: 700;
    font-size: var(--text-xs);
    color: var(--pigment-burgundy);
}

.footer-stamp-meta {
    font-family: var(--font-mono);
    font-size: var(--text-2xs);
    color: var(--ink-muted);
}

.footer-col-nav {
    display: flex;
    align-items: center;
    gap: var(--space-2);
}

.footer-anchor, .footer-anchor-btn {
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    color: var(--ink-secondary);
    text-decoration: none;
    background: none;
    border: none;
    cursor: pointer;
    transition: color var(--transition-fast);
}

.footer-anchor:hover, .footer-anchor-btn:hover {
    color: var(--pigment-burgundy);
    text-decoration: underline;
}

.footer-sep {
    color: var(--ink-faint);
}

.footer-fineprint {
    font-family: var(--font-mono);
    font-size: var(--text-2xs);
    color: var(--ink-muted);
    border-top: 1px solid var(--rule-hairline);
    padding-top: var(--space-3);
}

/* ==========================================================================
   12. COMMAND MODAL & TOASTS
   ========================================================================== */

.cmd-modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(38, 22, 15, 0.65);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 1000;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding: 90px 20px 40px;
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--transition-fast);
}

.cmd-modal-backdrop.open {
    opacity: 1;
    pointer-events: auto;
}

.folio-cmd-modal {
    width: 100%;
    max-width: 520px;
    background: var(--paper-white);
    border: 2px solid var(--pigment-burgundy);
    border-radius: 2px;
    box-shadow: var(--shadow-heavy);
    overflow: hidden;
    transform: translateY(10px) scale(0.98);
    transition: transform var(--transition-medium);
}

.cmd-modal-backdrop.open .folio-cmd-modal {
    transform: translateY(0) scale(1);
    animation: modalSpringIn 0.3s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.cmd-modal-header {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    padding: 12px var(--space-4);
    border-bottom: 1px solid var(--rule-hairline);
    background: var(--paper-base);
}

.cmd-prompt-glyph {
    font-family: var(--font-mono);
    font-weight: 700;
    color: var(--pigment-burgundy);
}

.cmd-modal-header input {
    flex: 1;
    border: none;
    outline: none;
    background: transparent;
    font-family: var(--font-sans);
    font-size: var(--text-md);
    color: var(--ink-primary);
}

.cmd-esc-key {
    font-family: var(--font-mono);
    font-size: 0.65rem;
}

.cmd-modal-body {
    max-height: 320px;
    overflow-y: auto;
    padding: var(--space-2);
}

.cmd-section {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.cmd-section-label {
    font-family: var(--font-mono);
    font-size: var(--text-2xs);
    font-weight: 700;
    color: var(--ink-muted);
    letter-spacing: 0.08em;
    padding: 4px 8px;
}

.cmd-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 12px;
    border-radius: 2px;
    cursor: pointer;
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    color: var(--ink-secondary);
    transition: all var(--transition-fast);
}

.cmd-item-left {
    display: flex;
    align-items: center;
    gap: 8px;
}

.cmd-glyph {
    color: var(--pigment-burgundy);
    font-weight: 700;
}

.cmd-item:hover, .cmd-item:focus {
    background: var(--paper-surface);
    color: var(--pigment-burgundy);
    outline: none;
    transform: translateX(3px);
}

.cmd-modal-footer {
    padding: 8px var(--space-4);
    background: var(--paper-surface);
    border-top: 1px solid var(--rule-hairline);
    font-family: var(--font-mono);
    font-size: var(--text-2xs);
    color: var(--ink-muted);
    text-align: center;
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    bottom: var(--space-5);
    right: var(--space-5);
    display: flex;
    flex-direction: column;
    gap: 6px;
    z-index: 2000;
    pointer-events: none;
}

.toast {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    border-radius: 2px;
    background: var(--paper-white);
    border: 1.5px solid var(--pigment-burgundy);
    color: var(--ink-primary);
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    font-weight: 600;
    box-shadow: 4px 4px 0px rgba(117, 20, 37, 0.18), 0 8px 24px rgba(38, 22, 15, 0.12);
    pointer-events: auto;
    animation: toastIn 0.25s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.toast svg {
    width: 14px;
    height: 14px;
    color: var(--pigment-burgundy);
}

.toast.toast-success svg {
    color: var(--pigment-forest);
}

.toast.toast-exit {
    animation: toastOut 0.2s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

/* Back to Top Floating Button with Circular SVG Progress */
.folio-back-top {
    position: fixed;
    bottom: var(--space-5);
    right: var(--space-5);
    width: 40px;
    height: 40px;
    background: var(--paper-white);
    border: 1.5px solid var(--pigment-burgundy);
    border-radius: 2px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 99;
    opacity: 0;
    pointer-events: none;
    box-shadow: var(--shadow-card);
    transition: opacity var(--transition-fast), transform var(--transition-fast), background var(--transition-fast);
}

.folio-back-top.visible {
    opacity: 1;
    pointer-events: auto;
    animation: floatBob 3s ease-in-out infinite;
}

.folio-back-top:hover {
    transform: translateY(-4px) scale(1.08);
    background: var(--paper-surface);
    box-shadow: var(--shadow-burgundy);
}

.progress-ring-top {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.ring-bg {
    fill: transparent;
    stroke: var(--paper-surface);
}

.ring-fill {
    fill: transparent;
    stroke: var(--pigment-burgundy);
    stroke-linecap: square;
    stroke-dasharray: 113.1;
    stroke-dashoffset: 113.1;
    transition: stroke-dashoffset 0.1s ease-out;
}

.top-glyph {
    font-family: var(--font-mono);
    font-size: var(--text-sm);
    font-weight: 700;
    color: var(--pigment-burgundy);
    z-index: 2;
}

/* ==========================================================================
   13. AUTHENTICATION & SECURITY DESK STYLES
   ========================================================================== */

.folio-btn-auth {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--paper-white);
    border: 1px solid var(--pigment-burgundy);
    color: var(--pigment-burgundy);
    padding: 6px 12px;
    font-family: var(--font-mono);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.04em;
    border-radius: 2px;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.folio-btn-auth:hover {
    background: var(--pigment-burgundy);
    color: var(--paper-white);
    transform: translateY(-1px);
    box-shadow: var(--shadow-burgundy);
}

.folio-btn-auth.is-authenticated {
    background: var(--pigment-burgundy);
    color: var(--paper-white);
    border-color: var(--pigment-burgundy);
}

.auth-icon-shield {
    width: 14px;
    height: 14px;
}

.dev-mailbox-btn {
    border-color: var(--pigment-amber) !important;
    color: var(--pigment-amber) !important;
}

.dev-mailbox-btn:hover {
    background: var(--pigment-amber) !important;
    color: var(--paper-white) !important;
}

/* Unverified Banner */
.unverified-banner {
    background: var(--paper-surface-muted);
    border-bottom: 1px solid var(--pigment-amber);
    padding: 8px 16px;
    position: sticky;
    top: 57px;
    z-index: 900;
}

.unverified-banner-inner {
    max-width: 1280px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    font-family: var(--font-sans);
    font-size: 13px;
    color: var(--ink-secondary);
}

.unverified-badge {
    font-family: var(--font-mono);
    font-size: 10px;
    font-weight: 700;
    background: var(--pigment-amber-tint);
    border: 1px solid var(--pigment-amber);
    color: var(--pigment-amber);
    padding: 2px 6px;
    border-radius: 2px;
    white-space: nowrap;
}

.unverified-text {
    flex: 1;
}

.unverified-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.btn-resend-inline {
    background: transparent;
    border: 1px solid var(--pigment-amber);
    color: var(--pigment-amber);
    font-family: var(--font-mono);
    font-size: 11px;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 2px;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.btn-resend-inline:hover {
    background: var(--pigment-amber);
    color: var(--paper-white);
}

.btn-close-banner {
    background: transparent;
    border: none;
    font-size: 14px;
    color: var(--ink-secondary);
    cursor: pointer;
    padding: 2px 6px;
}

/* Auth Modal Backdrop & Container */
.auth-modal-backdrop,
.dev-mailbox-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(38, 22, 15, 0.65);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    padding: 20px;
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--transition-medium);
}

.auth-modal-backdrop.is-open,
.dev-mailbox-backdrop.is-open {
    opacity: 1;
    pointer-events: auto;
}

.folio-auth-modal,
.folio-mailbox-modal {
    background: var(--paper-white);
    border: 1.5px solid var(--pigment-burgundy);
    width: 100%;
    max-width: 520px;
    box-shadow: var(--shadow-heavy);
    display: flex;
    flex-direction: column;
    max-height: 90vh;
    border-radius: 2px;
    transform: translateY(14px) scale(0.98);
    transition: transform var(--transition-medium);
}

.auth-modal-backdrop.is-open .folio-auth-modal,
.dev-mailbox-backdrop.is-open .folio-mailbox-modal {
    transform: translateY(0) scale(1);
    animation: modalSpringIn 0.3s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.auth-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--rule-solid);
    background: var(--paper-base);
    padding: 0 16px;
}

.auth-tabs {
    display: flex;
    gap: 4px;
}

.auth-tab-btn {
    background: transparent;
    border: none;
    border-bottom: 2px solid transparent;
    padding: 14px 12px;
    font-family: var(--font-mono);
    font-size: 11px;
    font-weight: 600;
    color: var(--ink-secondary);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.auth-tab-btn:hover {
    color: var(--pigment-burgundy);
}

.auth-tab-btn.active {
    color: var(--pigment-burgundy);
    border-bottom-color: var(--pigment-burgundy);
    font-weight: 700;
}

.auth-close-btn {
    background: transparent;
    border: 1px solid var(--rule-solid);
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    color: var(--ink-secondary);
    cursor: pointer;
    border-radius: 2px;
    transition: all var(--transition-fast);
}

.auth-close-btn:hover {
    background: var(--pigment-burgundy);
    color: var(--paper-white);
    border-color: var(--pigment-burgundy);
}

.auth-modal-body {
    padding: 24px;
    overflow-y: auto;
}

.auth-panel-heading {
    margin-bottom: 20px;
    border-bottom: 1px solid var(--rule-hairline);
    padding-bottom: 14px;
}

.auth-panel-stamp {
    font-family: var(--font-mono);
    font-size: 10px;
    font-weight: 700;
    color: var(--pigment-burgundy);
    letter-spacing: 0.08em;
    display: block;
    margin-bottom: 4px;
}

.auth-panel-title {
    font-family: var(--font-serif);
    font-size: 22px;
    font-weight: 600;
    color: var(--ink-primary);
    margin: 0 0 4px 0;
}

.auth-panel-sub {
    font-size: 12px;
    color: var(--ink-secondary);
    margin: 0;
    line-height: 1.5;
}

/* Form Styles */
.auth-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.form-group-folio {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-label-folio {
    font-family: var(--font-mono);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.06em;
    color: var(--ink-secondary);
}

.label-split {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.btn-text-link {
    background: transparent;
    border: none;
    font-family: var(--font-mono);
    font-size: 10px;
    color: var(--pigment-burgundy);
    cursor: pointer;
    text-decoration: underline;
    padding: 0;
}

.btn-text-link:hover {
    color: var(--pigment-burgundy-hover);
}

.form-input-folio {
    background: var(--paper-white);
    border: 1px solid var(--rule-solid);
    padding: 10px 12px;
    font-family: var(--font-sans);
    font-size: 13px;
    color: var(--ink-primary);
    border-radius: 2px;
    outline: none;
    transition: all var(--transition-fast);
}

.form-input-folio:focus {
    border-color: var(--pigment-burgundy);
    box-shadow: 0 0 0 2px var(--pigment-burgundy-tint);
}

.password-input-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.password-input-wrap input {
    width: 100%;
    padding-right: 36px;
}

.btn-toggle-pw {
    position: absolute;
    right: 8px;
    background: transparent;
    border: none;
    cursor: pointer;
    color: var(--ink-muted);
    font-size: 14px;
    padding: 4px;
}

.btn-toggle-pw:hover {
    color: var(--pigment-burgundy);
}

/* Password Strength Meter */
.pw-strength-container {
    background: var(--paper-base);
    border: 1px solid var(--rule-solid);
    padding: 12px;
    border-radius: 2px;
    margin-top: 6px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.pw-strength-meter {
    height: 4px;
    background: var(--paper-surface-muted);
    border-radius: 2px;
    overflow: hidden;
}

.pw-strength-bar {
    height: 100%;
    width: 0%;
    background: var(--pigment-burgundy);
    transition: width 0.3s ease, background 0.3s ease;
}

.pw-strength-bar.weak { width: 25%; background: var(--pigment-burgundy); }
.pw-strength-bar.fair { width: 50%; background: var(--pigment-amber); }
.pw-strength-bar.good { width: 75%; background: #68422A; }
.pw-strength-bar.strong { width: 100%; background: var(--pigment-forest); }

.pw-strength-label {
    font-family: var(--font-mono);
    font-size: 10px;
    font-weight: 600;
    color: var(--ink-secondary);
}

.pw-requirements-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
}

.req-item {
    font-size: 11px;
    color: var(--ink-muted);
    display: flex;
    align-items: center;
    gap: 5px;
    transition: color var(--transition-fast);
}

.req-item.met {
    color: var(--pigment-forest);
    font-weight: 500;
}

.req-item.met .req-glyph {
    color: var(--pigment-forest);
}

.req-item.met .req-glyph::before {
    content: "✓";
}

/* Auth Alert Box */
.auth-alert-box {
    padding: 10px 14px;
    border-radius: 2px;
    font-size: 12px;
    line-height: 1.5;
    font-family: var(--font-sans);
}

.auth-alert-box.error {
    background: var(--pigment-burgundy-tint);
    border: 1px solid var(--pigment-burgundy);
    color: var(--pigment-burgundy);
}

.auth-alert-box.success {
    background: var(--pigment-forest-tint);
    border: 1px solid var(--pigment-forest);
    color: var(--pigment-forest);
}

.auth-alert-box.warning {
    background: var(--pigment-amber-tint);
    border: 1px solid var(--pigment-amber);
    color: var(--pigment-amber);
}

.auth-actions-row {
    margin-top: 8px;
}

.auth-switch-note {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 6px;
    font-size: 11px;
    color: var(--ink-secondary);
    font-family: var(--font-sans);
}

.auth-switch-note .btn-text-link {
    font-size: 11px;
    font-weight: 600;
}

.btn-folio-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--pigment-burgundy);
    color: var(--paper-white);
    border: 1px solid var(--pigment-burgundy);
    font-family: var(--font-mono);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.04em;
    padding: 10px 18px;
    cursor: pointer;
    border-radius: 2px;
    box-shadow: var(--shadow-subtle);
    transition: all var(--transition-fast);
}

.btn-folio-primary:hover {
    background: var(--pigment-burgundy-hover);
    border-color: var(--pigment-burgundy-hover);
    transform: translateY(-1px);
    box-shadow: var(--shadow-burgundy);
}

.btn-folio-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: 1px solid var(--rule-solid);
    color: var(--ink-secondary);
    font-family: var(--font-mono);
    font-size: 12px;
    font-weight: 600;
    padding: 10px 18px;
    cursor: pointer;
    border-radius: 2px;
    transition: all var(--transition-fast);
}

.btn-folio-secondary:hover {
    border-color: var(--ink-primary);
    color: var(--ink-primary);
    background: var(--paper-surface);
}

.auth-submit-btn {
    width: 100%;
    justify-content: center;
    padding: 12px;
}

/* Profile Security Card */
.profile-security-card {
    background: var(--paper-base);
    border: 1px solid var(--rule-solid);
    padding: 16px;
    border-radius: 2px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 20px;
}

.sec-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
}

.sec-label {
    font-family: var(--font-mono);
    font-size: 10px;
    font-weight: 700;
    color: var(--ink-muted);
}

.sec-value {
    font-family: var(--font-mono);
    font-size: 11px;
    font-weight: 600;
    color: var(--ink-primary);
}

.profile-actions-wrap {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.profile-actions-wrap button {
    width: 100%;
    justify-content: center;
}

.auth-modal-footer,
.mailbox-modal-footer {
    border-top: 1px solid var(--rule-solid);
    background: var(--paper-base);
    padding: 12px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.sec-seal {
    font-family: var(--font-mono);
    font-size: 9px;
    color: var(--ink-muted);
    letter-spacing: 0.05em;
}

/* Dev Mailbox Modal */
.folio-mailbox-modal {
    max-width: 680px;
}

.mailbox-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 20px 24px 16px;
    border-bottom: 1px solid var(--rule-solid);
    background: var(--paper-base);
}

.mailbox-stamp {
    font-family: var(--font-mono);
    font-size: 10px;
    font-weight: 700;
    color: var(--pigment-amber);
    display: block;
    margin-bottom: 4px;
}

.mailbox-title {
    font-family: var(--font-serif);
    font-size: 20px;
    color: var(--ink-primary);
    margin: 0;
}

.mailbox-modal-body {
    padding: 20px 24px;
    max-height: 400px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.mailbox-card {
    background: var(--paper-white);
    border: 1px solid var(--rule-solid);
    padding: 16px;
    border-radius: 2px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.mailbox-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--rule-hairline);
    padding-bottom: 8px;
}

.mailbox-badge {
    font-family: var(--font-mono);
    font-size: 10px;
    font-weight: 700;
    background: var(--paper-base);
    border: 1px solid var(--rule-solid);
    padding: 2px 6px;
}

.mailbox-time {
    font-family: var(--font-mono);
    font-size: 10px;
    color: var(--ink-muted);
}

.mailbox-subject {
    font-family: var(--font-sans);
    font-weight: 600;
    font-size: 14px;
    color: var(--ink-primary);
}

.mailbox-recipient {
    font-family: var(--font-mono);
    font-size: 11px;
    color: var(--ink-secondary);
}

.mailbox-action-row {
    display: flex;
    gap: 8px;
    margin-top: 6px;
}

.btn-open-link {
    background: var(--pigment-burgundy);
    color: var(--paper-white);
    font-family: var(--font-mono);
    font-size: 11px;
    font-weight: 600;
    padding: 6px 12px;
    border: none;
    border-radius: 2px;
    cursor: pointer;
    text-decoration: none;
    transition: all var(--transition-fast);
}

.btn-open-link:hover {
    background: var(--pigment-burgundy-hover);
}

.mailbox-note {
    font-family: var(--font-mono);
    font-size: 10px;
    color: var(--ink-muted);
}

/* ==========================================================================
   14. ANTI-BOT HONEYPOT TRAP STYLES
   ========================================================================== */

/* Anti-Bot Honeypot Invisible Trap Field */
.security-hp-field {
    display: none !important;
    opacity: 0 !important;
    position: absolute !important;
    left: -9999px !important;
    width: 0 !important;
    height: 0 !important;
    pointer-events: none !important;
}

/* ==========================================================================
   14A. EDITORIAL SECTIONS (WEEKLY RHYTHM, REFLECTION JOURNAL, MINO CODEX)
   ========================================================================== */

.folio-editorial-section {
    margin-top: var(--space-8);
    padding-top: var(--space-6);
    border-top: 1px dashed var(--rule-solid);
    position: relative;
}

.section-divider-row {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    margin-bottom: var(--space-3);
    flex-wrap: wrap;
}

.section-stamp {
    font-family: var(--font-mono);
    font-size: var(--text-2xs);
    font-weight: 700;
    letter-spacing: 0.08em;
    color: var(--pigment-burgundy);
    background: var(--pigment-burgundy-tint);
    border: 1px solid var(--pigment-burgundy);
    padding: 2px 6px;
    border-radius: 2px;
}

.section-rule-line {
    flex: 1;
    height: 1px;
    background: var(--rule-hairline);
    min-width: 40px;
}

.section-live-tag {
    font-family: var(--font-mono);
    font-size: var(--text-2xs);
    font-weight: 600;
    color: var(--ink-muted);
    letter-spacing: 0.05em;
}

.section-header-wrap {
    margin-bottom: var(--space-5);
}

.section-editorial-title {
    font-family: var(--font-serif);
    font-size: var(--text-xl);
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--ink-primary);
    margin-bottom: 4px;
}

.section-editorial-sub {
    font-size: var(--text-sm);
    color: var(--ink-secondary);
    font-family: var(--font-sans);
}

/* Section 03: Weekly Rhythm Grid */
.rhythm-layout-grid {
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    gap: var(--space-5);
    align-items: stretch;
}

.rhythm-chart-card {
    background: var(--paper-card);
    border: 1px solid var(--rule-solid);
    padding: var(--space-5);
    box-shadow: var(--shadow-card);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: transform var(--transition-medium), box-shadow var(--transition-medium);
}

.rhythm-chart-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}

.card-headline-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--rule-hairline);
    padding-bottom: var(--space-2);
    margin-bottom: var(--space-4);
}

.card-micro-label {
    font-family: var(--font-mono);
    font-size: var(--text-2xs);
    font-weight: 700;
    letter-spacing: 0.06em;
    color: var(--ink-muted);
}

.card-micro-status {
    font-family: var(--font-mono);
    font-size: var(--text-2xs);
    font-weight: 600;
    color: var(--pigment-burgundy);
}

.rhythm-bars-container {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: var(--space-2);
    align-items: flex-end;
    height: 160px;
    padding: var(--space-2) 0 var(--space-1);
    margin-bottom: var(--space-3);
    border-bottom: 1px solid var(--rule-hairline);
}

.rhythm-day-col {
    display: flex;
    flex-direction: column;
    align-items: center;
    height: 100%;
    justify-content: flex-end;
    position: relative;
}

.rhythm-bar-track {
    width: 100%;
    max-width: 32px;
    height: 120px;
    background: var(--paper-surface);
    border: 1px solid var(--rule-hairline);
    border-radius: 2px 2px 0 0;
    display: flex;
    align-items: flex-end;
    position: relative;
    overflow: visible;
}

.rhythm-bar-fill {
    width: 100%;
    height: 0%;
    background: linear-gradient(180deg, var(--pigment-burgundy-hover) 0%, var(--pigment-burgundy) 100%);
    border-radius: 1px 1px 0 0;
    position: relative;
    transition: height 1s cubic-bezier(0.16, 1, 0.3, 1);
    cursor: pointer;
}

.rhythm-chart-card.revealed .rhythm-bar-fill,
.folio-editorial-section.revealed .rhythm-bar-fill {
    height: var(--target-height, 50%);
}

.rhythm-bar-fill.today-bar {
    background: linear-gradient(180deg, #A82039 0%, var(--pigment-burgundy-deep) 100%);
    box-shadow: 0 0 10px rgba(117, 20, 37, 0.3);
}

.bar-val-tooltip {
    position: absolute;
    top: -24px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--ink-primary);
    color: var(--paper-white);
    font-family: var(--font-mono);
    font-size: 0.625rem;
    padding: 1px 4px;
    border-radius: 2px;
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--transition-fast), transform var(--transition-fast);
    white-space: nowrap;
}

.rhythm-bar-fill:hover .bar-val-tooltip {
    opacity: 1;
    transform: translateX(-50%) translateY(-2px);
}

.rhythm-day-label {
    font-family: var(--font-mono);
    font-size: var(--text-2xs);
    font-weight: 600;
    color: var(--ink-secondary);
    margin-top: 6px;
}

.rhythm-day-label.bold-day {
    color: var(--pigment-burgundy);
    font-weight: 700;
}

.rhythm-dot-status {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--rule-solid);
    margin-top: 4px;
}

.rhythm-dot-status.active {
    background: var(--pigment-burgundy);
}

.pulse-dot {
    background: var(--pigment-burgundy);
    box-shadow: 0 0 0 0 rgba(117, 20, 37, 0.7);
    animation: pulseGlow 2s infinite;
}

@keyframes pulseGlow {
    0% {
        box-shadow: 0 0 0 0 rgba(117, 20, 37, 0.7);
    }
    70% {
        box-shadow: 0 0 0 6px rgba(117, 20, 37, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(117, 20, 37, 0);
    }
}

.rhythm-footer-legend {
    display: flex;
    gap: var(--space-4);
    font-family: var(--font-mono);
    font-size: var(--text-2xs);
    color: var(--ink-muted);
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 6px;
}

.legend-bullet {
    width: 7px;
    height: 7px;
    border-radius: 50%;
}

.active-bullet {
    background: var(--pigment-burgundy);
}

.rest-bullet {
    background: var(--rule-solid);
}

/* Right Metric Tiles Grid */
.rhythm-metrics-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-3);
}

.rhythm-stat-card {
    background: var(--paper-card);
    border: 1px solid var(--rule-solid);
    padding: var(--space-4);
    box-shadow: var(--shadow-subtle);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: transform var(--transition-fast), border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.rhythm-stat-card:hover {
    transform: translateY(-2px);
    border-color: var(--pigment-burgundy);
    box-shadow: var(--shadow-hover);
}

.stat-card-badge {
    font-family: var(--font-mono);
    font-size: var(--text-2xs);
    font-weight: 700;
    color: var(--ink-faint);
    letter-spacing: 0.06em;
    margin-bottom: 4px;
}

.stat-card-main {
    display: flex;
    align-items: baseline;
    gap: 2px;
    margin: 4px 0;
}

.stat-big-num {
    font-family: var(--font-serif);
    font-size: clamp(1.8rem, 2.8vw, 2.4rem);
    font-weight: 700;
    line-height: 1;
    color: var(--ink-primary);
}

.stat-unit {
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    font-weight: 600;
    color: var(--pigment-burgundy);
}

.stat-card-title {
    font-family: var(--font-sans);
    font-size: var(--text-xs);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--ink-primary);
    margin-bottom: 4px;
}

.stat-card-desc {
    font-size: var(--text-2xs);
    color: var(--ink-muted);
    line-height: 1.4;
}

/* Section 04: Daily Mindful Reflection Journal */
.reflection-split-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-5);
}

.reflection-card {
    background: var(--paper-card);
    border: 1px solid var(--rule-solid);
    padding: var(--space-5);
    box-shadow: var(--shadow-card);
    display: flex;
    flex-direction: column;
    gap: var(--space-3);
    transition: transform var(--transition-medium), box-shadow var(--transition-medium), border-color var(--transition-fast);
}

.reflection-card:hover {
    border-color: var(--pigment-burgundy);
    box-shadow: var(--shadow-hover);
    transform: translateY(-2px);
}

.reflection-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--rule-hairline);
    padding-bottom: var(--space-2);
}

.reflection-badge-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
}

.ref-icon {
    font-size: 1.1rem;
}

.ref-title {
    font-family: var(--font-sans);
    font-size: var(--text-xs);
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--ink-primary);
}

.ref-wordcount {
    font-family: var(--font-mono);
    font-size: var(--text-2xs);
    color: var(--ink-muted);
}

.reflection-prompt {
    font-family: var(--font-serif);
    font-style: italic;
    font-size: var(--text-sm);
    color: var(--ink-secondary);
    line-height: 1.45;
}

.reflection-textarea {
    width: 100%;
    background: var(--paper-surface);
    border: 1px solid var(--rule-solid);
    border-radius: 2px;
    padding: var(--space-3);
    font-family: var(--font-sans);
    font-size: var(--text-sm);
    color: var(--ink-primary);
    line-height: 1.5;
    resize: vertical;
    min-height: 100px;
    transition: border-color var(--transition-fast), background var(--transition-fast), box-shadow var(--transition-fast);
}

.reflection-textarea:focus {
    outline: none;
    border-color: var(--pigment-burgundy);
    background: var(--paper-white);
    box-shadow: 0 0 0 2px var(--pigment-burgundy-tint);
}

.reflection-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-family: var(--font-mono);
    font-size: var(--text-2xs);
}

.ref-hint {
    color: var(--ink-muted);
}

.btn-clean-action {
    background: transparent;
    border: 1px solid var(--rule-hairline);
    color: var(--ink-muted);
    font-family: var(--font-mono);
    font-size: var(--text-2xs);
    padding: 2px 8px;
    border-radius: 2px;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.btn-clean-action:hover {
    color: var(--pigment-burgundy);
    border-color: var(--pigment-burgundy);
    background: var(--paper-surface);
}

/* Section 05: The Mino Codex Cards */
.codex-cards-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-4);
}

.codex-card {
    background: var(--paper-card);
    border: 1px solid var(--rule-solid);
    padding: var(--space-5);
    box-shadow: var(--shadow-subtle);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: transform var(--transition-medium), border-color var(--transition-fast), box-shadow var(--transition-medium);
}

.codex-card:hover {
    transform: translateY(-4px);
    border-color: var(--pigment-burgundy);
    box-shadow: var(--shadow-hover);
}

.codex-topline {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-3);
}

.codex-number {
    font-family: var(--font-mono);
    font-size: var(--text-sm);
    font-weight: 700;
    color: var(--pigment-burgundy);
}

.codex-tag {
    font-family: var(--font-mono);
    font-size: var(--text-2xs);
    font-weight: 700;
    letter-spacing: 0.08em;
    color: var(--ink-muted);
    background: var(--paper-surface);
    padding: 1px 6px;
    border-radius: 2px;
}

.codex-heading {
    font-family: var(--font-serif);
    font-size: var(--text-md);
    font-weight: 700;
    color: var(--ink-primary);
    margin-bottom: var(--space-2);
}

.codex-body {
    font-size: var(--text-xs);
    color: var(--ink-secondary);
    line-height: 1.55;
    margin-bottom: var(--space-4);
}

.codex-footer-meta {
    border-top: 1px solid var(--rule-hairline);
    padding-top: var(--space-2);
}

.codex-rule-badge {
    font-family: var(--font-mono);
    font-size: 0.65rem;
    font-weight: 600;
    color: var(--ink-muted);
    letter-spacing: 0.04em;
}

/* Footer Session Meta */
.footer-session-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    font-family: var(--font-mono);
    font-size: var(--text-2xs);
    color: var(--ink-muted);
    margin-top: 6px;
}

.meta-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #2E7D32;
    display: inline-block;
}

/* ==========================================================================
   14B. TACTILE FLOATING ACTION DOCK & BACK TO TOP PROGRESS RING
   ========================================================================== */

.floating-dock-wrap {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 900;
    pointer-events: none;
    opacity: 0;
    transform: translateY(16px) scale(0.92);
    transition: opacity 0.35s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.floating-dock-wrap.visible {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: auto;
}

.floating-dock-pill {
    display: flex;
    align-items: center;
    gap: 4px;
    background: rgba(255, 253, 249, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--rule-solid);
    padding: 6px 8px;
    border-radius: 30px;
    box-shadow: var(--shadow-heavy);
}

.dock-action-btn {
    position: relative;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: transparent;
    border: none;
    color: var(--ink-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background var(--transition-fast), color var(--transition-fast), transform var(--transition-fast);
}

.dock-action-btn svg {
    width: 16px;
    height: 16px;
}

.dock-action-btn:hover {
    background: var(--paper-surface);
    color: var(--pigment-burgundy);
    transform: scale(1.1);
}

.dock-btn-top {
    width: 38px;
    height: 38px;
    color: var(--pigment-burgundy);
}

.dock-sep {
    width: 1px;
    height: 18px;
    background: var(--rule-hairline);
    margin: 0 2px;
}

.dock-tooltip {
    position: absolute;
    bottom: calc(100% + 10px);
    right: 50%;
    transform: translateX(50%) translateY(4px);
    background: var(--ink-primary);
    color: var(--paper-white);
    font-family: var(--font-mono);
    font-size: 0.65rem;
    font-weight: 600;
    padding: 4px 8px;
    border-radius: 3px;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--transition-fast), transform var(--transition-fast);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.dock-action-btn:hover .dock-tooltip {
    opacity: 1;
    transform: translateX(50%) translateY(0);
}

.dock-percent-ticker {
    display: none;
}

.progress-ring-top {
    position: absolute;
    inset: 2px;
    transform: rotate(-90deg);
}

.ring-bg {
    fill: none;
    stroke: var(--paper-surface-muted);
}

.ring-fill {
    fill: none;
    stroke: var(--pigment-burgundy);
    stroke-linecap: round;
    stroke-dasharray: 113.1;
    stroke-dashoffset: 113.1;
    transition: stroke-dashoffset 0.1s linear;
}

.top-glyph {
    position: relative;
    z-index: 2;
    font-size: 15px;
    font-weight: 700;
    line-height: 1;
}

/* Task Item Animated Glide In */
.task-item {
    animation: ledgerRowIn 0.35s cubic-bezier(0.16, 1, 0.3, 1) both;
    animation-delay: calc(var(--item-idx, 0) * 0.035s);
}

/* Accessible Reduced Motion Guarantee */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.001ms !important;
        scroll-behavior: auto !important;
    }
    [data-reveal] {
        opacity: 1 !important;
        transform: none !important;
        filter: none !important;
    }
    .rhythm-bar-fill {
        height: var(--target-height, 50%) !important;
        transition: none !important;
    }
}

/* ==========================================================================
   15. RESPONSIVE MEDIA QUERIES
   ========================================================================== */

@media (max-width: 960px) {
    .folio-layout-grid {
        grid-template-columns: 1fr;
        gap: var(--space-5);
    }

    .folio-value-pillars {
        grid-template-columns: 1fr;
        gap: var(--space-3);
    }

    .cadence-column {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: var(--space-4);
    }

    .folio-manifesto-box {
        grid-column: span 2;
    }
}

@media (max-width: 680px) {
    .masthead-center-meta {
        display: none;
    }

    .folio-value-pillars {
        grid-template-columns: 1fr;
    }

    .hero-edition-row {
        flex-direction: column;
        align-items: flex-start;
        gap: var(--space-2);
    }

    .starter-links-wrap {
        overflow-x: auto;
        white-space: nowrap;
        width: 100%;
    }

    .capture-meta-line {
        flex-direction: column;
        align-items: stretch;
    }

    .meta-selectors-group {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 6px;
    }

    .date-wrap {
        grid-column: span 2;
    }

    .folio-submit-btn {
        width: 100%;
        justify-content: center;
    }

    .ledger-toolbar {
        flex-direction: column;
        align-items: stretch;
    }

    .ledger-tabs {
        overflow-x: auto;
        white-space: nowrap;
    }

    .ledger-toolbar-meta {
        justify-content: space-between;
    }

    .cadence-column {
        grid-template-columns: 1fr;
    }

    .folio-manifesto-box {
        grid-column: span 1;
    }

    .folio-footnote-bar {
        display: none;
    }

    input, select {
        font-size: 16px !important;
    }
}

/* Print Styles */
.print-only-header {
    display: none;
}

@media print {
    body {
        background: #ffffff !important;
        color: #000000 !important;
    }

    .ambient-backdrop,
    .masthead-wrapper,
    .scroll-progress-bar,
    .starter-links-wrap,
    .capture-desk,
    .ledger-toolbar,
    .cadence-column,
    .folio-footnote-bar,
    .folio-footer,
    .cmd-modal-backdrop,
    .folio-back-top,
    .toast-container,
    .task-actions {
        display: none !important;
    }

    .print-only-header {
        display: block !important;
        border-bottom: 2px solid #000;
        padding-bottom: 10px;
        margin-bottom: 20px;
    }

    .main-content {
        padding: 0 !important;
    }

    .folio-layout-grid {
        display: block !important;
    }

    .ledger-column {
        border: none !important;
        box-shadow: none !important;
        padding: 0 !important;
    }

    .task-item {
        border-bottom: 1px solid #ccc !important;
        break-inside: avoid;
    }
}

/* Friendly Empty State for Weekly Rhythm Chart */
.rhythm-empty-state {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    min-height: 120px;
    background: var(--paper-surface);
    border: 1px dashed var(--rule-solid);
    border-radius: 2px;
    padding: var(--space-4);
    text-align: center;
}

.rhythm-empty-state p {
    font-family: var(--font-serif);
    font-size: var(--text-sm);
    font-style: italic;
    color: var(--ink-muted);
    margin: 0;
}

/* ==========================================================================
   15. ACCESSIBILITY & PREFERS-REDUCED-MOTION
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }

    [data-reveal] {
        opacity: 1 !important;
        transform: none !important;
        transition: none !important;
    }

    .ambient-orb {
        animation: none !important;
        transform: none !important;
    }

    .pulse-dot,
    .rhythm-dot-status.pulse-dot,
    .meta-dot.pulse-dot {
        animation: none !important;
    }

    .rhythm-bar-fill {
        transition: none !important;
    }
}

