/* --- DESIGN SYSTEM & CSS VARIABLES --- */
:root {
    --bg-darkest: #07080a;
    --bg-dark: #0d0f13;
    --bg-card: rgba(22, 26, 33, 0.65);
    --bg-card-hover: rgba(29, 34, 43, 0.8);
    --border-premium: rgba(212, 175, 55, 0.15);
    --border-light: rgba(255, 255, 255, 0.08);
    
    /* Brand Colors */
    --gold: #d4af37;
    --gold-dark: #b89323;
    --gold-light: #f5e093;
    --gold-glow: rgba(212, 175, 55, 0.35);
    
    --fire: #e25822;
    --fire-glow: rgba(226, 88, 34, 0.4);
    
    --text-bright: #f8fafc;
    --text-normal: #cbd5e1;
    --text-muted: #64748b;
    
    /* Temperature Colors */
    --color-muerto: #353535;
    --color-frio: #1d4ed8;
    --color-tibio: #c18d00;
    --color-caliente: #d86000;
    --color-ferviente: #8f121b;

    /* Bright counterparts for high contrast text on dark backgrounds */
    --color-muerto-bright: #94a3b8;
    --color-frio-bright: #60a5fa;
    --color-tibio-bright: #facc15;
    --color-caliente-bright: #fb923c;
    --color-ferviente-bright: #f87171;

    /* Glow colors (translucent) for card backgrounds */
    --color-muerto-glow: rgba(53, 53, 53, 0.1);
    --color-frio-glow: rgba(29, 78, 216, 0.12);
    --color-tibio-glow: rgba(193, 141, 0, 0.12);
    --color-caliente-glow: rgba(216, 96, 0, 0.12);
    --color-ferviente-glow: rgba(143, 18, 27, 0.12);
    
    --shadow-premium: 0 15px 35px rgba(0, 0, 0, 0.5), 0 5px 15px rgba(0, 0, 0, 0.3);
}

/* --- RESET & BASE STYLES --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
    background-color: var(--bg-darkest);
    color: var(--text-normal);
    font-family: 'Outfit', sans-serif;
    -webkit-font-smoothing: antialiased;
}

body {
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
}

/* --- AMBIENT EFFECTS --- */
.ambient-glow {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    background: 
        radial-gradient(circle at 10% 20%, rgba(226, 88, 34, 0.05) 0%, transparent 40%),
        radial-gradient(circle at 90% 80%, rgba(212, 175, 55, 0.06) 0%, transparent 50%),
        radial-gradient(circle at 50% 50%, rgba(13, 15, 19, 1) 0%, rgba(7, 8, 10, 1) 100%);
    pointer-events: none;
}

.particles-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
    overflow: hidden;
}

.particle {
    position: absolute;
    bottom: -10px;
    background: radial-gradient(circle, rgba(226, 88, 34, 0.6) 0%, transparent 70%);
    border-radius: 50%;
    filter: blur(1px);
    animation: rise var(--d, 12s) infinite linear;
}

@keyframes rise {
    0% {
        transform: translateY(0) scale(1) rotate(0deg);
        opacity: 0;
    }
    10% {
        opacity: 0.6;
    }
    90% {
        opacity: 0.2;
    }
    100% {
        transform: translateY(-110vh) scale(0.3) rotate(360deg);
        opacity: 0;
    }
}

/* --- TYPOGRAPHY UTILITIES --- */
h1, h2, h3, h4, .serif-font {
    font-family: 'Cinzel', serif;
    letter-spacing: 0.05em;
    color: var(--text-bright);
}

.gold-text {
    color: var(--gold);
    background: linear-gradient(135deg, var(--gold-light) 0%, var(--gold) 50%, var(--gold-dark) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 0 10px rgba(212, 175, 55, 0.1);
}

.red-text {
    color: var(--fire);
}

.uppercase {
    text-transform: uppercase;
}

.font-semibold {
    font-weight: 600;
}

/* --- BUTTONS --- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.875rem 2rem;
    font-family: 'Outfit', sans-serif;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-decoration: none;
    letter-spacing: 0.05em;
    gap: 10px;
}

.btn-primary {
    background: linear-gradient(135deg, var(--gold) 0%, var(--gold-dark) 100%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #000;
    box-shadow: 0 4px 15px rgba(212, 175, 55, 0.25);
}

.btn-primary:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(212, 175, 55, 0.4), 0 0 10px rgba(212, 175, 55, 0.2);
    background: linear-gradient(135deg, var(--gold-light) 0%, var(--gold) 100%);
}

.btn-primary:active:not(:disabled) {
    transform: translateY(0);
}

.btn-outline {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: var(--text-bright);
}

.btn-outline:hover:not(:disabled) {
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--gold);
    color: var(--gold-light);
}

.btn:disabled {
    opacity: 0.35;
    cursor: not-allowed;
    transform: none !important;
    box-shadow: none !important;
}

.btn-arrow {
    width: 18px;
    height: 18px;
    transition: transform 0.3s ease;
}

.btn-primary:hover .btn-arrow {
    transform: translateX(4px);
}

/* --- APP LAYOUT --- */
.app-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 1.5rem;
    min-height: 90vh;
    display: flex;
    flex-direction: column;
}

.app-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0 2rem 0;
    border-bottom: 1px solid var(--border-light);
    margin-bottom: 2rem;
}

.header-logo {
    font-size: 1.75rem;
    font-weight: 900;
    font-family: 'Cinzel', serif;
}

.pdf-header {
    display: none;
}

.header-tag {
    font-size: 0.875rem;
    color: var(--text-muted);
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

/* --- SCREEN TRANSITIONS --- */
.screen {
    display: none;
    opacity: 0;
    transform: translateY(15px);
    transition: opacity 0.5s ease, transform 0.5s ease;
    flex-grow: 1;
}

.screen.active {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

/* Flex active screen fallback */
#quiz-section.screen.active {
    display: block;
}

/* --- SECTION 1: HERO / LANDING --- */
#home-section {
    text-align: center;
    max-width: 900px;
    margin: 0 auto;
    align-self: center;
    padding: 2rem 0;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 900;
    line-height: 1.1;
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    background: linear-gradient(135deg, #fff 30%, var(--gold-light) 70%, var(--gold) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-subtitle {
    font-size: 1.5rem;
    color: var(--text-normal);
    text-transform: uppercase;
    letter-spacing: 0.2em;
    font-weight: 300;
    margin-bottom: 2rem;
}

.divider-gold {
    height: 2px;
    width: 80px;
    background: linear-gradient(90deg, transparent, var(--gold), transparent);
    margin: 0 auto 2.5rem auto;
}

.hero-description {
    font-size: 1.15rem;
    line-height: 1.8;
    color: var(--text-normal);
    margin-bottom: 3.5rem;
    font-weight: 300;
}

/* Pillars Grid */
.pillars-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-bottom: 4rem;
}

.pillar-card {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: 12px;
    padding: 2rem 1.5rem;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(10px);
}

.pillar-card:hover {
    transform: translateY(-5px);
    border-color: var(--border-premium);
    box-shadow: 0 10px 25px rgba(212, 175, 55, 0.05);
    background: var(--bg-card-hover);
}

.pillar-icon {
    width: 60px;
    height: 60px;
    margin: 0 auto 1.5rem auto;
    color: var(--gold);
    display: flex;
    align-items: center;
    justify-content: center;
}

.pillar-icon svg {
    width: 100%;
    height: 100%;
}

.pillar-card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.05em;
}

.pillar-card p {
    font-size: 0.925rem;
    line-height: 1.6;
    color: var(--text-muted);
}

.cta-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

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

/* --- SECTION 2: QUIZ LAYOUT --- */
.quiz-grid {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 2.5rem;
    align-items: start;
}

/* Thermometer Sidebar */
.thermometer-sidebar {
    position: sticky;
    top: 2rem;
}

.thermo-card {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: 12px;
    padding: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-premium);
}

.thermo-glass {
    width: 100%;
    display: flex;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.thermometer-svg {
    width: 100%;
    max-width: 240px;
    height: auto;
}

.thermo-status {
    width: 100%;
    border-top: 1px solid var(--border-light);
    padding-top: 1.25rem;
    text-align: center;
}

.status-label {
    display: block;
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.25rem;
}

.status-value {
    font-family: 'Cinzel', serif;
    font-size: 1.25rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    transition: color 0.3s ease;
}

/* Quiz Content Area */
.quiz-content {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.quiz-progress-wrapper {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: 8px;
    padding: 1rem 1.5rem;
    backdrop-filter: blur(10px);
}

.quiz-progress-text {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9rem;
    margin-bottom: 0.75rem;
}

.progress-bar-bg {
    height: 6px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 3px;
    overflow: hidden;
}

.progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--gold-dark), var(--gold));
    border-radius: 3px;
    transition: width 0.4s ease;
    box-shadow: 0 0 8px var(--gold-glow);
}

.question-card {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: 12px;
    padding: 2.5rem;
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-premium);
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    min-height: 400px;
}

.question-header {
    display: flex;
    gap: 1.25rem;
    align-items: flex-start;
}

.question-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: rgba(212, 175, 55, 0.1);
    border: 1px solid var(--gold);
    color: var(--gold);
    font-family: 'Cinzel', serif;
    border-radius: 50%;
    font-weight: 700;
    flex-shrink: 0;
}

.question-title {
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1.3;
}

.question-desc {
    font-size: 1.05rem;
    line-height: 1.6;
    color: var(--text-normal);
    font-style: italic;
    font-weight: 300;
    padding-left: 3.25rem;
}

/* Options Rating Controls */
.options-container {
    padding-left: 3.25rem;
    margin-top: 1rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.options-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 1rem;
}

.option-btn {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-light);
    border-radius: 8px;
    padding: 1.25rem 0.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    gap: 0.5rem;
}

.option-btn:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.option-num {
    font-family: 'Cinzel', serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-bright);
}

.option-level {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
}

/* Active option states based on score value */
.option-btn.active[data-value="0"] {
    border-color: var(--color-muerto);
    background: rgba(53, 53, 53, 0.15);
    box-shadow: 0 0 15px rgba(53, 53, 53, 0.2);
}
.option-btn.active[data-value="0"] .option-num { color: var(--color-muerto); }

.option-btn.active[data-value="1"] {
    border-color: var(--color-frio);
    background: rgba(29, 78, 216, 0.15);
    box-shadow: 0 0 15px rgba(29, 78, 216, 0.2);
}
.option-btn.active[data-value="1"] .option-num { color: var(--color-frio); }

.option-btn.active[data-value="2"] {
    border-color: var(--color-tibio);
    background: rgba(193, 141, 0, 0.15);
    box-shadow: 0 0 15px rgba(193, 141, 0, 0.2);
}
.option-btn.active[data-value="2"] .option-num { color: var(--color-tibio); }

.option-btn.active[data-value="3"] {
    border-color: var(--color-caliente);
    background: rgba(216, 96, 0, 0.15);
    box-shadow: 0 0 15px rgba(216, 96, 0, 0.2);
}
.option-btn.active[data-value="3"] .option-num { color: var(--color-caliente); }

.option-btn.active[data-value="4"] {
    border-color: var(--color-ferviente);
    background: rgba(143, 18, 27, 0.15);
    box-shadow: 0 0 15px rgba(143, 18, 27, 0.2);
}
.option-btn.active[data-value="4"] .option-num { color: var(--gold-light); }

/* Option Meaning details card */
.option-meaning-panel {
    background: rgba(0, 0, 0, 0.25);
    border: 1px solid var(--border-light);
    border-radius: 8px;
    padding: 1rem 1.25rem;
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    min-height: 80px;
    transition: border-color 0.3s ease;
}

.meaning-indicator {
    width: 6px;
    height: 100%;
    min-height: 40px;
    background-color: var(--text-muted);
    border-radius: 3px;
    flex-shrink: 0;
    transition: background-color 0.3s ease;
}

.meaning-content h4 {
    font-size: 0.95rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
}

.meaning-content p {
    font-size: 0.85rem;
    line-height: 1.5;
    color: var(--text-normal);
}

/* Alert Boxes */
.alert-box {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.875rem 1.25rem;
    border-radius: 6px;
    font-size: 0.85rem;
    line-height: 1.5;
}

.note-alert {
    background: rgba(212, 175, 55, 0.03);
    border: 1px solid rgba(212, 175, 55, 0.15);
    color: var(--text-normal);
}

.alert-icon {
    width: 18px;
    height: 18px;
    color: var(--gold);
    flex-shrink: 0;
}

/* Nav Footer */
.quiz-nav {
    display: flex;
    justify-content: space-between;
    margin-top: 1rem;
}

/* --- SECTION 3: RESULTS LAYOUT --- */
.results-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 1rem 0;
}

.results-title {
    text-align: center;
    font-size: 2.75rem;
    text-transform: uppercase;
}

.result-badge-card {
    background: radial-gradient(circle at center, rgba(22, 26, 33, 0.85) 0%, rgba(13, 15, 19, 0.95) 100%);
    border: 2px solid var(--border-premium);
    border-radius: 12px;
    padding: 2.5rem 2rem;
    text-align: center;
    margin-bottom: 2.5rem;
    box-shadow: 0 0 35px rgba(212, 175, 55, 0.08);
    position: relative;
    overflow: hidden;
}

.result-badge-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at center, var(--glow-color, rgba(212, 175, 55, 0.05)) 0%, transparent 70%);
    pointer-events: none;
    z-index: 1;
}

.result-badge-subtitle {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
    position: relative;
    z-index: 2;
}

.result-badge-title {
    font-size: 3rem;
    font-weight: 900;
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    position: relative;
    z-index: 2;
}

.result-badge-value {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 70px;
    height: 70px;
    border-radius: 50%;
    border: 2px solid currentColor;
    font-family: 'Cinzel', serif;
    font-size: 2.25rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    position: relative;
    z-index: 2;
}

.result-badge-meaning {
    font-size: 1.15rem;
    line-height: 1.7;
    max-width: 700px;
    margin: 0 auto;
    color: var(--text-bright);
    font-weight: 300;
    position: relative;
    z-index: 2;
}


/* Results Grid System */
.results-grid {
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    gap: 2.5rem;
    margin-bottom: 3.5rem;
}

.results-chart-card, .results-remedy-card {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: 12px;
    padding: 2.5rem;
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-premium);
}

.results-chart-card h3, .results-remedy-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    border-bottom: 1px solid var(--border-light);
    padding-bottom: 0.75rem;
}

.chart-desc {
    font-size: 0.925rem;
    line-height: 1.6;
    color: var(--text-muted);
    margin-bottom: 2rem;
}

/* HTML/CSS Bar Chart */
.bar-chart-container {
    height: 250px;
    position: relative;
    margin: 2.5rem 0 3rem 0;
    padding-top: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}

.bars-wrapper {
    height: 100%;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    align-items: end;
    padding: 0 1rem;
}

.chart-column {
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    align-items: center;
}

.bar-wrapper {
    width: 50px;
    height: 100%;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 4px 4px 0 0;
    position: relative;
    display: flex;
    align-items: flex-end;
}

.bar-fill {
    width: 100%;
    height: 0; /* Animated dynamically by JS */
    border-radius: 4px 4px 0 0;
    position: relative;
    transition: height 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    justify-content: center;
}

.bar-value {
    position: absolute;
    top: -24px;
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--text-bright);
}

.gold-bar {
    background: linear-gradient(to top, var(--gold-dark), var(--gold));
    box-shadow: 0 0 15px rgba(212, 175, 55, 0.25);
}

.white-bar {
    background: linear-gradient(to top, #475569, #cbd5e1);
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.15);
}

.eye-bar {
    background: linear-gradient(to top, #0f766e, #2dd4bf);
    box-shadow: 0 0 15px rgba(45, 212, 191, 0.25);
}

.bar-label {
    text-align: center;
    margin-top: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
}

.bar-label strong {
    font-size: 0.875rem;
    color: var(--text-bright);
}

.bar-label span {
    font-size: 0.75rem;
    color: var(--text-muted);
}

/* Audit Table Card */
.audit-table-card {
    margin-top: 2rem;
    border-top: 1px solid var(--border-light);
    padding-top: 1.5rem;
}

.audit-table-card h4 {
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--gold);
    margin-bottom: 1rem;
}

.audit-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr 1fr;
    gap: 1px;
    background: var(--border-light);
    border-radius: 6px;
    overflow: hidden;
    font-size: 0.825rem;
}

.audit-header {
    background: rgba(255, 255, 255, 0.05);
    padding: 0.75rem;
    font-weight: 600;
    color: var(--text-bright);
    text-align: center;
}

.audit-label {
    padding: 0.75rem;
    font-weight: 600;
    background: rgba(255, 255, 255, 0.02);
}

.audit-val {
    background: rgba(0, 0, 0, 0.15);
    padding: 0.75rem;
    text-align: center;
    color: var(--text-normal);
}

.audit-val.red-text {
    color: #f87171;
}

/* Remedy Card Detail */
.verdict-theological {
    font-size: 1.05rem;
    line-height: 1.7;
    color: var(--text-normal);
    font-weight: 300;
    margin-bottom: 2rem;
}

.verdict-theological p {
    margin-bottom: 1rem;
}

.verdict-theological blockquote {
    border-left: 2px solid var(--gold);
    padding-left: 1rem;
    margin: 1.25rem 0;
    font-style: italic;
    color: var(--text-bright);
}

/* Roadmap Plan Steps */
.roadmap-card {
    border-top: 1px solid var(--border-light);
    padding-top: 1.5rem;
}

.roadmap-subtitle {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}

.roadmap-steps {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    position: relative;
}

.roadmap-steps::before {
    content: '';
    position: absolute;
    left: 17px;
    top: 15px;
    bottom: 15px;
    width: 2px;
    background: linear-gradient(to bottom, var(--border-light) 70%, transparent 100%);
}

.roadmap-step {
    display: flex;
    gap: 1.25rem;
    position: relative;
    z-index: 1;
}

.step-num {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #1e293b;
    border: 2px solid var(--border-light);
    color: var(--text-muted);
    font-family: 'Cinzel', serif;
    font-weight: 700;
    font-size: 0.95rem;
    flex-shrink: 0;
    transition: all 0.3s ease;
}

.step-content {
    padding-top: 0.25rem;
}

.step-content h4 {
    font-size: 1.05rem;
    margin-bottom: 0.25rem;
    font-weight: 700;
    transition: color 0.3s ease;
}

.step-content p {
    font-size: 0.875rem;
    line-height: 1.5;
    color: var(--text-muted);
    transition: color 0.3s ease;
}

/* Highlighted focus roadmap step classes */
.roadmap-step.focus .step-num {
    background: rgba(212, 175, 55, 0.15);
    border-color: var(--gold);
    color: var(--gold);
    box-shadow: 0 0 10px var(--gold-glow);
}

.roadmap-step.focus .step-content h4 {
    color: var(--gold-light);
}

.roadmap-step.focus .step-content p {
    color: var(--text-normal);
}

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

/* --- FOOTER --- */
.app-footer-text {
    text-align: center;
    padding: 3rem 0;
    border-top: 1px solid var(--border-light);
    margin-top: auto;
    font-size: 0.8rem;
    color: var(--text-muted);
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.5;
}

/* --- CHURCH SELECTION SECTION --- */
.church-selection-card {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: 12px;
    padding: 2.5rem;
    max-width: 800px;
    margin: 0 auto;
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-premium);
    text-align: center;
}

.church-title {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.church-subtitle {
    font-size: 0.95rem;
    color: var(--text-normal);
    margin-bottom: 1.5rem;
    font-weight: 300;
}

.church-options-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
    gap: 0.75rem;
    margin-bottom: 2rem;
    max-height: 350px;
    overflow-y: auto;
    padding-right: 0.5rem;
}

/* Scrollbar styling for options */
.church-options-list::-webkit-scrollbar {
    width: 6px;
}
.church-options-list::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.02);
    border-radius: 3px;
}
.church-options-list::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
}
.church-options-list::-webkit-scrollbar-thumb:hover {
    background: var(--gold-dark);
}

.church-option {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-light);
    border-radius: 6px;
    padding: 1rem;
    color: var(--text-normal);
    font-family: 'Outfit', sans-serif;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.25s ease;
    text-align: center;
}

.church-option:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(212, 175, 55, 0.3);
    color: var(--text-bright);
}

.church-option.selected {
    background: rgba(212, 175, 55, 0.1);
    border-color: var(--gold);
    color: var(--gold-light);
    box-shadow: 0 0 10px rgba(212, 175, 55, 0.15);
}

.church-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--border-light);
    padding-top: 1.5rem;
}

/* --- QUIZ MODE & MANUAL INPUT SECTIONS --- */
.mode-options-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 2.5rem;
}

.mode-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-light);
    border-radius: 12px;
    padding: 2.5rem 1.5rem;
    color: var(--text-normal);
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    font-family: 'Outfit', sans-serif;
    width: 100%;
}

.mode-card:hover {
    background: rgba(212, 175, 55, 0.03);
    border-color: var(--gold);
    transform: translateY(-4px);
    box-shadow: 0 10px 25px rgba(212, 175, 55, 0.1);
}

.mode-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.03);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gold-light);
    margin-bottom: 1.5rem;
    border: 1px solid rgba(212, 175, 55, 0.2);
    transition: all 0.3s ease;
}

.mode-card:hover .mode-icon {
    background: rgba(212, 175, 55, 0.1);
    border-color: var(--gold);
    transform: scale(1.1);
    box-shadow: 0 0 15px rgba(212, 175, 55, 0.2);
}

.mode-card h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    color: var(--text-bright);
}

.mode-card p {
    font-size: 0.875rem;
    line-height: 1.5;
    color: var(--text-muted);
}

/* Manual Sliders styling */
.manual-sliders-container {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    margin-bottom: 2.5rem;
}

.slider-group {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    background: rgba(255, 255, 255, 0.01);
    border: 1px solid rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    padding: 1.25rem 1.5rem;
}

.slider-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.slider-label {
    font-size: 1rem;
    font-weight: 600;
}

.slider-value {
    font-size: 1.25rem;
    font-weight: 700;
    font-family: 'Cinzel', serif;
}

.manual-slider {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: rgba(255, 255, 255, 0.1);
    outline: none;
    cursor: pointer;
}

/* Thumb customizations */
.manual-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    cursor: pointer;
    transition: transform 0.1s ease, box-shadow 0.1s ease;
}

.manual-slider::-webkit-slider-thumb:hover {
    transform: scale(1.15);
}

.gold-slider::-webkit-slider-thumb {
    background: var(--gold);
    box-shadow: 0 0 8px rgba(212, 175, 55, 0.4);
}
.gold-slider::-webkit-slider-thumb:active {
    box-shadow: 0 0 15px rgba(212, 175, 55, 0.7);
}

.white-slider::-webkit-slider-thumb {
    background: #cbd5e1;
    box-shadow: 0 0 8px rgba(255, 255, 255, 0.4);
}
.white-slider::-webkit-slider-thumb:active {
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.7);
}

.eye-slider::-webkit-slider-thumb {
    background: #2dd4bf;
    box-shadow: 0 0 8px rgba(45, 212, 191, 0.4);
}
.eye-slider::-webkit-slider-thumb:active {
    box-shadow: 0 0 15px rgba(45, 212, 191, 0.7);
}

.slider-limits {
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
    color: var(--text-muted);
}

.eye-text {
    color: #2dd4bf;
}
.white-text {
    color: #cbd5e1;
}

.results-church-display {
    text-align: center;
    font-size: 1.1rem;
    color: var(--gold-light);
    margin-top: -0.5rem;
    margin-bottom: 1.5rem;
    letter-spacing: 0.05em;
    font-weight: 500;
}

.results-db-status {
    text-align: center;
    font-size: 0.9rem;
    margin-top: -1.2rem;
    margin-bottom: 1.5rem;
    letter-spacing: 0.05em;
    font-weight: 500;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 0;
    transform: translateY(-5px);
}

.results-db-status.active {
    opacity: 1;
    transform: translateY(0);
}

.results-db-status.saving {
    color: var(--text-muted);
}

.results-db-status.success {
    color: #2dd4bf;
    text-shadow: 0 0 8px rgba(45, 212, 191, 0.25);
}

.results-db-status.error {
    color: #f87171;
    text-shadow: 0 0 8px rgba(248, 113, 113, 0.25);
}


/* --- RESPONSIVE ADJUSTMENTS --- */
@media (max-width: 900px) {
    .quiz-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .thermometer-sidebar {
        position: relative;
        top: 0;
    }

    .thermo-card {
        flex-direction: row;
        padding: 1rem;
        gap: 1.5rem;
    }

    .thermo-glass {
        width: auto;
        height: 100px;
        margin-bottom: 0;
    }

    .thermometer-svg {
        height: 100%;
        width: auto;
        max-width: none;
    }

    .thermo-status {
        border-top: none;
        border-left: 1px solid var(--border-light);
        padding-top: 0;
        padding-left: 1.5rem;
        display: flex;
        flex-direction: column;
        justify-content: center;
        text-align: left;
    }

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

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

    .pillars-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
}

@media (max-width: 600px) {
    .header-logo {
        font-size: 1.1rem;
    }
    .mode-options-container {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .options-grid {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }

    .option-btn {
        flex-direction: row;
        justify-content: flex-start;
        padding: 0.875rem 1.25rem;
        gap: 1.25rem;
    }

    .options-container {
        padding-left: 0;
    }

    .question-desc {
        padding-left: 0;
    }

    .question-card {
        padding: 1.5rem;
    }

    .results-actions {
        flex-direction: column;
        gap: 1rem;
    }

    .btn {
        width: 100%;
    }

    .audit-grid {
        grid-template-columns: 1fr;
    }
    
    .audit-header {
        display: none;
    }
}

/* --- PRINT MEDIA FOR PDF EXPORT --- */
@media print {
    body {
        background: #fff;
        color: #111827;
    }

    .ambient-glow, .particles-container, .quiz-nav, .results-actions, .app-header, .app-footer-text {
        display: none !important;
    }

    .app-container {
        max-width: 100%;
        padding: 0;
    }

    .screen {
        display: none !important;
    }

    #results-section.screen {
        display: block !important;
        opacity: 1 !important;
        transform: none !important;
    }

    .results-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .results-chart-card, .results-remedy-card, .result-badge-card {
        background: #fff !important;
        border: 1px solid #d1d5db !important;
        color: #111827 !important;
        box-shadow: none !important;
        page-break-inside: avoid;
    }

    h1, h2, h3, h4 {
        color: #111827 !important;
        text-shadow: none !important;
    }

    .result-badge-title {
        color: #ef4444 !important;
    }

    .result-badge-value {
        color: #111827 !important;
        border-color: #111827 !important;
    }

    .result-badge-meaning {
        color: #374151 !important;
    }

    .bar-wrapper {
        background: #f3f4f6 !important;
        border: 1px solid #d1d5db;
    }

    .gold-bar {
        background: #d4af37 !important;
    }

    .white-bar {
        background: #9ca3af !important;
    }

    .eye-bar {
        background: #0d9488 !important;
    }

    .bar-value {
        color: #111827 !important;
    }

    .audit-grid {
        background: #d1d5db !important;
    }

    .audit-header {
        background: #f3f4f6 !important;
        color: #111827 !important;
    }

    .audit-label {
        background: #f9fafb !important;
    }

    .audit-val {
        background: #fff !important;
        color: #111827 !important;
    }

    .roadmap-steps::before {
        background: #d1d5db !important;
    }

    .step-num {
        background: #f3f4f6 !important;
        border-color: #d1d5db !important;
        color: #4b5563 !important;
    }

    .pdf-header {
        display: block !important;
        text-align: center;
        margin-bottom: 2rem;
    }

    .pdf-logo {
        max-width: 280px;
        height: auto;
        display: inline-block;
    }
}

/* --- SPINNER ANIMATIONS FOR DATABASE SAVING --- */
@keyframes rotate {
    100% {
        transform: rotate(360deg);
    }
}

@keyframes dash {
    0% {
        stroke-dasharray: 1, 150;
        stroke-dashoffset: 0;
    }
    50% {
        stroke-dasharray: 90, 150;
        stroke-dashoffset: -35;
    }
    100% {
        stroke-dasharray: 90, 150;
        stroke-dashoffset: -124;
    }
}

