/* ==========================================================================
   LearnLens custom theme â€” layered on top of Bootstrap 5.
   Palette ported from the original Streamlit app's global CSS block.
   ========================================================================== */

:root {
    --ll-navy:        #0D2141;
    --ll-navy-light:  #17335c;
    --ll-slate:       #64748b;
    --ll-fog:         #A9BBCC;
    --ll-mist:        #C3CFDA;
    --ll-line:        #86A0B8;
    --ll-bg:          #F7F8FA;
    --ll-card-border: #e8e4de;

    --ll-novice:      #DC6B2F;
    --ll-developing:  #2F7DDC;
    --ll-proficient:  #2FA35C;

    --ll-radius:      14px;
    --ll-font-serif:  'DM Serif Display', Georgia, serif;
    --ll-font-sans:   'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

body {
    font-family: var(--ll-font-sans);
    background-color: var(--ll-bg);
    color: #1a2433;
}

h1, h2, h3, .ll-serif {
    font-family: var(--ll-font-serif);
    font-weight: 400;
    color: var(--ll-navy);
}

/* â”€â”€ Navbar â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€ */
.ll-navbar {
    background: linear-gradient(100deg, var(--ll-navy) 0%, var(--ll-navy-light) 100%);
    padding: 0.7rem 1.5rem;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.16);
    position: relative;
    z-index: 10;
}
.ll-navbar .navbar-brand {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    font-family: var(--ll-font-serif);
    color: #fff !important;
    font-size: 1.3rem;
    letter-spacing: 0.02em;
}
.ll-navbar-mark {
    display: inline-grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.14);
    color: #fff;
    font-size: 1rem;
    flex: 0 0 auto;
}
.ll-navbar .nav-link {
    color: var(--ll-mist) !important;
    font-weight: 500;
    font-size: 0.88rem;
}
.ll-navbar .nav-link:hover,
.ll-navbar .nav-link.active {
    color: #fff !important;
}
.ll-navbar-user {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.35rem 0.85rem 0.35rem 0.4rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
}
.ll-navbar-avatar {
    display: inline-grid;
    place-items: center;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.18);
    color: #fff;
    font-size: 0.72rem;
    font-weight: 700;
    flex: 0 0 auto;
}
.ll-navbar-email {
    color: var(--ll-mist);
    font-size: 0.82rem;
    max-width: 220px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.ll-navbar-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.45rem 0.9rem;
    border-radius: 999px;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--ll-mist) !important;
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.16);
    transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
    text-decoration: none !important;
}
.ll-navbar-pill:hover,
.ll-navbar-pill:focus-visible {
    color: #fff !important;
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.3);
}
.ll-navbar-pill-signout {
    color: #fff !important;
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.22);
}
.ll-navbar-pill-signout:hover,
.ll-navbar-pill-signout:focus-visible {
    background: #fff;
    color: var(--ll-navy) !important;
    border-color: #fff;
}
@media (max-width: 991.98px) {
    .ll-navbar-user,
    .ll-navbar-pill {
        width: 100%;
        justify-content: flex-start;
    }
    .ll-navbar .navbar-nav {
        gap: 0.5rem;
        padding-top: 0.5rem;
    }
    .ll-navbar-email {
        max-width: none;
    }
}

/* â”€â”€ Login split panel â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€ */
.ll-login-panel {
    background: var(--ll-navy);
    min-height: calc(100vh - 62px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: clamp(2rem, 5vw, 4rem);
    color: #fff;
}
.ll-login-panel .ll-eyebrow {
    font-size: 0.9rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--ll-fog);
}
.ll-login-panel .ll-headline {
    font-family: var(--ll-font-serif);
    font-size: clamp(1.9rem, 3vw + 1.2rem, 3.1rem);
    line-height: 1.15;
    color: #fff;
    margin: 0.75rem 0 1.1rem;
}
.ll-login-panel .ll-desc {
    font-size: clamp(1rem, 0.8vw + 0.85rem, 1.15rem);
    color: var(--ll-mist);
    line-height: 1.8;
    max-width: 34rem;
}
.ll-login-panel .ll-foot {
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--ll-line);
    line-height: 1.7;
    margin-top: 3rem;
}
.ll-login-form-wrap {
    max-width: 440px;
    margin: 0 auto;
    padding: clamp(3rem, 9vh, 6rem) 1.5rem 2rem;
}
.ll-signin-title {
    font-family: var(--ll-font-serif);
    font-size: clamp(1.9rem, 2vw + 1.2rem, 2.4rem);
    color: var(--ll-navy);
}
.ll-signin-sub {
    font-size: 0.9rem;
    color: var(--ll-slate);
    margin-bottom: 1.75rem;
}

/* â”€â”€ Cards / panels â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€ */
.ll-card {
    background: #fff;
    border: 1px solid var(--ll-card-border);
    border-radius: var(--ll-radius);
    box-shadow: 0 1px 3px rgba(13, 33, 65, 0.06);
}

/* â”€â”€ Tier badges â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€ */
.ll-badge {
    display: inline-block;
    padding: 0.3rem 0.85rem;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 600;
    color: #fff;
}
.ll-badge-novice     { background: var(--ll-novice); }
.ll-badge-developing { background: var(--ll-developing); }
.ll-badge-proficient { background: var(--ll-proficient); }

/* â”€â”€ Buttons â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€ */
.btn-ll-primary {
    background: var(--ll-navy);
    border-color: var(--ll-navy);
    color: #fff;
    font-weight: 600;
    min-height: 46px;
}
.btn-ll-primary:hover {
    background: var(--ll-navy-light);
    border-color: var(--ll-navy-light);
    color: #fff;
}

/* Small pill buttons for the Dashboard / Replay briefing nav row above
   each module's stage strip (module1_nav.php, module2_nav.php, module3_nav.php). */
.nav-pill-btn {
    display: inline-flex; align-items: center; gap: .4rem;
    padding: .35rem .9rem; border-radius: 999px;
    border: 1px solid #E2E8F0; background: #fff; color: #334155;
    font-size: .8rem; font-weight: 600; text-decoration: none;
    transition: background .15s ease, border-color .15s ease, color .15s ease;
}
.nav-pill-btn:hover, .nav-pill-btn:focus-visible {
    background: #F1F5F9; border-color: #94A3B8; color: var(--ll-navy);
}
.nav-pill-btn-ghost { background: transparent; color: #64748B; border-color: transparent; }
.nav-pill-btn-ghost:hover, .nav-pill-btn-ghost:focus-visible {
    background: #F8FAFC; border-color: #E2E8F0; color: #334155;
}

@media (max-width: 767.98px) {
    .ll-login-panel { min-height: auto; padding: 2rem 1.5rem; }
}

/* â”€â”€ Concept-page callouts + step badges (shared across modules) â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€ */
.concept-callout { border-radius: 12px; padding: 1rem 1.25rem; margin: 1.1rem 0; }
.concept-callout strong { display: block; margin-bottom: .4rem; color: var(--ll-navy); }
.concept-callout-blue   { background: #EBF6FC; border-left: 4px solid #1469A8; }
.concept-callout-amber  { background: #FFF4E8; border-left: 4px solid #C96800; }
.concept-callout-teal   { background: #ECF9F3; border-left: 4px solid #138A63; }
.concept-callout-purple { background: #F5F1FC; border-left: 4px solid #534AB7; }
.concept-step { display: flex; gap: .75rem; align-items: flex-start; margin-bottom: .9rem; }
.concept-step-num {
    flex: 0 0 auto; width: 1.9rem; height: 1.9rem; border-radius: 50%;
    display: grid; place-items: center; font-weight: 700; color: #fff; font-size: .9rem;
}
.concept-step-num.n1 { background: #1469A8; }
.concept-step-num.n2 { background: #C96800; }
.concept-step-num.n3 { background: #138A63; }
.concept-step-num.n4 { background: #534AB7; }
/* Shared numbered step-card component (originally Module 3's cf-step-card,
   promoted here so every module's step lists render identically). */
.cf-step-card{border:1px solid #E2E8F0;border-radius:16px;padding:1.25rem 1.4rem;margin-bottom:1.25rem;background:#fff}
.cf-step-head{display:flex;align-items:center;gap:.75rem;margin-bottom:.65rem}
.cf-step-head h2{margin:0}
.cf-step-num{flex:0 0 auto;width:2.15rem;height:2.15rem;border-radius:50%;display:grid;place-items:center;font-family:'DM Serif Display',serif;font-size:1.05rem;color:#fff}
.cf-step-num.n1{background:#1469A8}.cf-step-num.n2{background:#C96800}.cf-step-num.n3{background:#138A63}.cf-step-num.n4{background:#534AB7}
.cf-step-card.s1{background:#F8FCFE}.cf-step-card.s2{background:#FFFBF6}.cf-step-card.s3{background:#F7FDFB}.cf-step-card.s4{background:#FAF8FD}
.concept-mistake { display: flex; gap: .6rem; flex-wrap: wrap; margin-bottom: .6rem; }
.concept-mistake .wrong, .concept-mistake .right {
    flex: 1; min-width: 220px; padding: .6rem .75rem; border-radius: 8px; font-size: .85rem;
}
.concept-mistake .wrong { background: #FEF2F2; color: #991B1B; }
.concept-mistake .right { background: #F0FDF4; color: #166534; }
.concept-formula-box { background: #ECF9F3; border: 1px solid #C8EFDF; border-radius: 12px; padding: 1.1rem 1.25rem; margin: 1.1rem 0; }
.concept-formula-box .fw-semibold { color: #0F5C46; }

/* â”€â”€ Equation chips + click-to-continue step reveal (Back-Door / Front-Door) â”€â”€ */
.eq-step-title { font-weight: 700; font-size: .95rem; margin-bottom: .4rem; }
.eq-row { display: flex; align-items: center; gap: .55rem; flex-wrap: wrap; margin-bottom: .5rem; }
.eq-chip {
    display: inline-block; padding: .4rem .75rem; border-radius: 8px;
    font-family: 'Courier New', monospace; font-size: .8rem; font-weight: 700;
    border: 1.5px solid; line-height: 1.3;
}
.eq-chip.a { background: #F0FDF4; border-color: #16A34A; color: #15803D; }
.eq-chip.b { background: #FEF2F2; border-color: #DC2626; color: #B91C1C; }
.eq-op { font-weight: 700; color: #475569; font-size: 1.05rem; }
.eq-steps .eq-step { border-bottom: 1px dashed #E2E8F0; padding-bottom: 1rem; }
.eq-steps .eq-step:last-of-type { border-bottom: 0; padding-bottom: 0; }
/* Bootstrap's .d-flex carries display:flex !important, which otherwise beats
   the plain [hidden] user-agent rule and keeps "hidden" steps visible. */
.eq-steps .eq-step[hidden] { display: none !important; }
.eq-next-btn {
    border: 0; border-radius: 999px; padding: .5rem 1.15rem; color: #fff;
    font-weight: 700; font-size: .82rem; cursor: pointer; margin-top: .75rem;
}
.eq-next-btn.back:hover, .eq-next-btn.back { background: #1D9E75; }
.eq-next-btn.front:hover, .eq-next-btn.front { background: #534AB7; }
.eq-next-btn:hover { opacity: .88; }

/* Highlighted "step by step guidance" toggle - was plain muted text, easy to miss. */
.eq-guidance-toggle {
    display: inline-flex; align-items: center; gap: .5rem;
    padding: .55rem 1rem; border-radius: 10px; cursor: pointer;
    background: #EBF6FC; border: 1.5px solid #1469A8; color: #0D2141 !important;
    font-weight: 700; font-size: .88rem; list-style: none; margin-bottom: .75rem;
}
.eq-guidance-toggle::-webkit-details-marker { display: none; }
.eq-guidance-toggle:hover { background: #DCEFFA; }
.eq-guidance-toggle .eq-guidance-caret { transition: transform .15s ease; display: inline-block; }
details[open] > .eq-guidance-toggle .eq-guidance-caret { transform: rotate(90deg); }

/* â”€â”€ Feasibility checks (Check 1 / Check 2): equation, given-vs-calculated, pass/fail â”€â”€ */
.feas-check { background: #F7F8FA; border-radius: 12px; padding: 1rem 1.1rem; }
.feas-check-values { display: flex; gap: 1rem; flex-wrap: wrap; margin: .8rem 0; }
.feas-check-value {
    flex: 1; min-width: 180px; padding: .75rem 1rem; border-radius: 10px;
}
.feas-check-value.calc { background: #F0FDF4; border: 1.5px solid #16A34A; }
.feas-check-value.given { background: #FEF2F2; border: 1.5px solid #DC2626; }
.feas-check-value-label {
    font-size: .7rem; font-weight: 700; text-transform: uppercase;
    letter-spacing: .04em; margin-bottom: .3rem;
}
.feas-check-value.calc .feas-check-value-label { color: #15803D; }
.feas-check-value.given .feas-check-value-label { color: #B91C1C; }
.feas-check-editable {
    display: block; font-weight: 400; text-transform: none;
    font-size: .72rem; color: #475569; margin-top: .15rem;
}
.feas-check-value-num { font-size: 1.3rem; font-weight: 700; font-family: 'Courier New', monospace; }
.feas-check-value-sub { font-size: .72rem; color: #64748b; margin-top: .2rem; }
.feas-check-result {
    display: flex; align-items: center; gap: .4rem; flex-wrap: wrap;
    padding: .6rem .9rem; border-radius: 8px; font-weight: 700; font-size: .88rem;
    margin-bottom: .5rem;
}
.feas-check-result.pass { background: #ECFDF5; color: #15803D; }
.feas-check-result.fail { background: #FEF2F2; color: #B91C1C; }
.feas-check-hint summary { color: #1469A8; font-size: .85rem; cursor: pointer; font-weight: 600; }
.feas-check-hint-body { margin-top: .5rem; }

/* Per-step "click to continue" prompt in the Worked Example ledger. */
.ledger-reveal-row {
    cursor: pointer; display: inline-block; margin: .3rem 0 .6rem;
    padding: .4rem .7rem; border-radius: 8px;
    background: #EEF0FC; color: #3730A3; font-size: .8rem; font-weight: 700;
}
.ledger-reveal-row:hover { background: #E0E4FA; }
/* Shared NOESIS wordmark for student modules and administration. */
.ll-navbar .navbar-brand{display:inline-flex;align-items:center;gap:3px;font-family:'Instrument Sans',Arial,sans-serif;font-weight:600;font-size:29px;line-height:1;letter-spacing:-.035em}
.ll-navbar .ll-navbar-mark{display:flex;align-items:center;justify-content:center;width:34px;height:34px;background:transparent;border:0;border-radius:0;box-shadow:none;flex-shrink:0}
.ll-navbar .ll-navbar-mark svg{display:block;width:34px;height:34px}
.ll-navbar .ll-wordmark{display:block;margin:0;line-height:1}

/* Same two-line wordmark on dark student and admin headers. */
.ll-navbar .navbar-brand{align-items:flex-start;gap:3px}
.ll-navbar .ll-navbar-mark{width:32px;height:32px;margin:0}
.ll-navbar .ll-navbar-mark svg{width:32px;height:32px}
.ll-navbar .ll-brand-text{display:flex;flex-direction:column;gap:6px;margin-top:1px}
.ll-navbar .ll-wordmark{font-size:26px;font-weight:600;line-height:1;letter-spacing:-.035em;color:white}
.ll-navbar .ll-brand-subject{font-size:10px;font-weight:500;line-height:1.2;letter-spacing:.085em;color:white}

/* Match the approved homepage wordmark dimensions and spacing exactly. */
.lp-brand,.ll-navbar .navbar-brand{gap:3px;align-items:flex-start}
.lp-brand-mark,.ll-navbar .ll-navbar-mark{width:36px;height:36px;margin:0;flex-shrink:0}
.lp-brand-mark svg,.ll-navbar .ll-navbar-mark svg{width:36px;height:36px;display:block;transform:none}
.lp-brand-text,.ll-navbar .ll-brand-text{margin:1px 0 0;gap:6px}
.lp-brand-name,.ll-navbar .ll-wordmark{font-family:'Instrument Sans',Arial,sans-serif;font-size:31px;font-weight:700;line-height:1.04;letter-spacing:0}
.lp-brand-subject,.ll-navbar .ll-brand-subject{font-size:11px;font-weight:500;letter-spacing:.07em;line-height:1.04}
@media(max-width:1100px){.lp-brand-mark,.ll-navbar .ll-navbar-mark,.lp-brand-mark svg,.ll-navbar .ll-navbar-mark svg{width:32px;height:32px}.lp-brand-name,.ll-navbar .ll-wordmark{font-size:27px}.lp-brand-subject,.ll-navbar .ll-brand-subject{font-size:9px}}
@media(max-width:760px){.lp-brand-name,.ll-navbar .ll-wordmark{font-size:28px}}
/* Tighten N–O spacing while keeping a small optical gap. */
.lp-brand,.ll-navbar .navbar-brand{gap:0}
.lp-brand-text,.ll-navbar .ll-brand-text{margin-left:-2px}
.ll-navbar .ll-brand-subject{display:block!important;visibility:visible;color:#fff;font-size:10px;line-height:1.2}
/* Shared compact help icon for learning modules and future hint controls. */
.fsim-hint-toggle,.fex-hint-toggle,.ll-hint-icon {
 display:inline-flex!important;align-items:center;justify-content:center;position:relative;
 width:20px;min-width:20px;height:20px;padding:0!important;margin:0 3px 0 5px;
 border:0;border-radius:50%;background:#dc2626;color:#fff!important;
 font:700 14px/1 Arial,sans-serif!important;text-decoration:none!important;
 vertical-align:middle;cursor:pointer;box-shadow:none;flex-shrink:0;
}
.fsim-hint-toggle::after,.fex-hint-toggle::after,.ll-hint-icon::after{display:none!important}
.fsim-hint-toggle:hover,.fex-hint-toggle:hover,.ll-hint-icon:hover{background:#b91c1c}
.fsim-hint-toggle:focus-visible,.fex-hint-toggle:focus-visible,.ll-hint-icon:focus-visible{outline:2px solid #0d2141;outline-offset:3px}
.feas-check-hint summary::before{content:'?';display:inline-flex;align-items:center;justify-content:center;width:20px;height:20px;border-radius:50%;background:#dc2626;color:#fff;font:700 14px/1 Arial,sans-serif;margin-right:6px;vertical-align:middle}

/* Shared fluid canvas for the current learning pages. */
.learning-page-shell,.container.briefing-shell,.design-review-banner{width:100%;max-width:none;padding-left:clamp(20px,4vw,72px);padding-right:clamp(20px,4vw,72px)}
@media(max-width:600px){.learning-page-shell,.container.briefing-shell,.design-review-banner{padding-left:15px;padding-right:15px}}

/* Shared module learning navigation. */
.module-stage-card.is-locked{opacity:.55;cursor:not-allowed;box-shadow:none}.module-stage-card.is-locked:hover{flex:1;transform:none;box-shadow:none;border-color:#E2E8F0}
.module-run-nav-badge{padding:.2rem .55rem;border:1px solid #CBD5E1;border-radius:999px;background:#F8FAFC;color:#64748B;font-size:.67rem;font-weight:700}.module-stage-nav{display:flex;gap:.65rem}.module-stage-card{min-width:0;flex:1;display:flex;align-items:center;gap:.65rem;padding:.8rem .9rem;border:1px solid #E2E8F0;border-radius:13px;background:#fff;color:#334155;text-decoration:none;box-shadow:0 3px 12px rgba(13,33,65,.04);transition:flex .2s ease,transform .2s ease,box-shadow .2s ease,border-color .2s ease}.module-stage-card:hover,.module-stage-card:focus-visible{color:#0D2141;flex:1.16;transform:translateY(-2px);box-shadow:0 8px 20px rgba(13,33,65,.1);border-color:#94A3B8}.module-stage-card.is-active{flex:1.18;background:#0D2141;border-color:#0D2141;color:#fff}.module-stage-card.is-done{background:#ECFDF5;border-color:#86EFAC;color:#166534}.stage-icon{width:2rem;height:2rem;flex:0 0 auto;border-radius:9px;display:grid;place-items:center;background:#F1F5F9}.is-active .stage-icon{background:rgba(255,255,255,.15)}.is-done .stage-icon{background:#DCFCE7}.stage-copy{min-width:0}.stage-copy strong,.stage-copy small{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.stage-copy strong{font-size:.78rem}.stage-copy small{font-size:.66rem;margin-top:.12rem;opacity:.72}.stage-check{margin-left:auto;font-size:.85rem}@media(max-width:767.98px){.module-stage-nav{display:grid;grid-template-columns:1fr 1fr}.module-stage-card:hover,.module-stage-card:focus-visible,.module-stage-card.is-active{flex:1;transform:none}}@media(max-width:420px){.module-stage-nav{grid-template-columns:1fr}}
/* Learning cards use spacing and filled surfaces instead of outlined boxes. */
.learning-page-shell .ll-card{border:0!important;box-shadow:none!important}
.learning-page-shell :is(.cf-step-card,.cf-intro,.cf-before,.cf-help,.cf-stat,.cf-expect,.cf-summary-card,.cf-visual-card,.cf-steps>div,.cp-intro,.cp-stats>div,.cp-prediction,.cp-formula,.cf-assessment-intro,.cf-assessment-guide,.cf-submission-summary,.cf-worksheet-feedback,.cf-reflect-feedback,.cf-reflect-service){border:0!important;box-shadow:none!important}
.learning-page-shell .cf-step-card{background:transparent!important;padding:1.25rem 0;margin-bottom:1rem}
.learning-page-shell .cf-help{padding:1.25rem;border-radius:8px}
.learning-page-shell .cf-summary-card{background:#ecf9f3}
.learning-page-shell .cf-visual-card{background:#f3f6fa}
.cf-excel-trace{padding-left:1.4rem}.cf-excel-trace>li{padding:.6rem 0}.cf-excel-trace p{margin:.55rem 0;line-height:1.7}.cf-excel-trace code{overflow-wrap:anywhere}
/* Shared Module 1 palette for the four learning cards. */
.learning-page-shell .module-stage-card{border:0!important;box-shadow:none;border-radius:12px}
.learning-page-shell .module-stage-card.card-concept{background:#dceffd;color:#145b88}
.learning-page-shell .module-stage-card.card-worked_example{background:#ffead4;color:#955000}
.learning-page-shell .module-stage-card.card-simulator{background:#d9f2e5;color:#126849}
.learning-page-shell .module-stage-card.card-reflect{background:#eae2f8;color:#58408c}
.learning-page-shell .module-stage-card.is-active{box-shadow:inset 0 -4px currentColor}
.learning-page-shell .module-stage-card.is-locked{opacity:.65}
.learning-page-shell .cf-step-card{padding:1.25rem 1.4rem;border-radius:12px}
.learning-page-shell .cf-step-card.s1{background:#ebf6fc!important}.learning-page-shell .cf-step-card.s2{background:#fff4e8!important}.learning-page-shell .cf-step-card.s3{background:#ecf9f3!important}.learning-page-shell .cf-step-card.s4{background:#f5f1fc!important}
/* Prominent next action on every card that requires a mastery check. */
.mastery-check-action.btn{display:flex;align-items:center;justify-content:center;width:100%;min-height:60px;padding:16px 24px;font-size:1.125rem;font-weight:700;line-height:1.4;border-radius:10px;text-align:center;white-space:normal}
.mastery-check-action.btn:focus-visible{outline:3px solid #1469a8;outline-offset:4px}
@media(max-width:600px){.mastery-check-action.btn{min-height:56px;padding:14px 18px;font-size:1rem}}

/* Completed stages retain green when active, hovered, or revisited. */
.learning-page-shell .module-stage-card.is-done,
.learning-page-shell .module-stage-card.is-done:hover,
.learning-page-shell .module-stage-card.is-done:focus-visible{background:#d9f2e3;color:#166534}
.learning-page-shell .module-stage-card.is-done .stage-icon{background:#c4e9d0;color:#166534}
.module-row.is-complete,.module-row.is-complete:hover{background:#e4f5eb!important;border-color:#8ac6a2!important;color:#164b2d}

/* Shared reasoning-feedback presentation across all learning modules. */
.feedback-ready-note{display:inline-flex;align-items:center;gap:.4rem;margin:.15rem 0 .65rem;padding:.3rem .6rem;border-radius:6px;background:#e6f0fa;color:#174b78;font-size:.8rem;font-weight:700;line-height:1.4}
.reasoning-feedback-panel[data-feedback-state="partial"],
[data-npv-writing][data-feedback-state="partial"],
.cf-reflect-question[data-feedback-state="partial"]{background:#fff7d6!important;color:#713f12;border:1px solid #d6ad38!important;border-radius:10px;padding:1rem}
.reasoning-feedback-panel[data-feedback-state="complete"]{background:#e4f5eb!important;color:#164b2d;border-radius:10px;padding:1rem}
