/* ============================================================================
 * Heliomath APP — the authenticated (logged-in) brand layer.
 *
 * Carved VERBATIM from the retired brand override (brands/heliomath.css): these
 * were the only rules it still uniquely provided, all on logged-in surfaces —
 *   - .learner-profile-area   — account / settings / subscription pages
 *   - .interstitial           — answer-history-consent + account-dissolution
 *   - .onboarding-survey-area — post-signup "how did you hear about us"
 *   - .start-free-trial-area / .payment-details-area — the post-signup funnel
 *   - .ghelp_grokkoli_icon* / .icon_grokkoli_logo    — the question-page icons
 *
 * Loaded on alpha_base for Heliomath at the OLD brand-override slot: after
 * figureone.css (so the !important icon rules win) and before the account-access
 * flow (so the funnel rules that account_access.css also sets resolve to
 * account_access, exactly as they did against the override). Gated OFF the public
 * solid-nav content pages, which carry none of these classes.
 *
 * SELF-CONTAINED PALETTE: these rules consume the legacy --helio-* tokens, and the
 * alpha_base app pages do NOT load the marketing layer (heliomath_marketing.css), so
 * the raw palette is declared here (verbatim from the old override :root). This is the
 * exploration palette, kept AS-IS so the logged-in pages render pixel-identically;
 * migrating these onto the Sunset tokens is a later step (with the app foundation).
 * ========================================================================== */

:root {
    /* Solar — CTAs, highlights, progress, achievement, logo */
    --helio-sunlight: #FFC44D;
    --helio-solar-gold: #F6B21A;
    --helio-amber: #E89611;

    /* Navy — headings, icons, nav, graphs */
    --helio-midnight: #0D1B2A;
    --helio-slate: #31475E;
    --helio-steel: #5F7388;

    /* Backgrounds — keep slightly sunlit (no pure gray) */
    --helio-cream: #FCF6E9;
    --helio-cloud: #F7F5F0;
    --helio-white: #FFFFFF;

    /* Blue accent — links, secondary buttons, active states, math viz */
    --helio-sky: #4A90E2;
    --helio-soft-sky: #87BFFF;

    /* Text */
    --helio-muted: #7A8A99;

    /* Semantic */
    --helio-success: #2EAD72;
    --helio-warning: #F59E0B;
    --helio-error: #E05252;
    --helio-info: #4A90E2;
}

/* --- Account section (.learner-profile-area): the logged-in account pages —
 *     learners (learner_profiles.html), account settings (account_settings.html)
 *     and subscription (subscription.html). All three extend alpha_base. The
 *     shared chrome is Grokkoli blue/green (blue primary buttons, green setting
 *     labels + "on" toggles, green free-trial card); re-theme to the Heliomath
 *     ramp. Scoped to .learner-profile-area so nothing leaks. --- */
.learner-profile-area h1 { color: var(--helio-midnight); }
.learner-profile-area .settings-box h3 { color: var(--helio-midnight); }

/* Setting labels are Grokkoli green — recolor to navy. */
.learner-profile-area .setting-set h5,
.learner-profile-area .setting-set.global h5 { color: var(--helio-slate); }

/* Primary buttons are Grokkoli blue with white text → brand gold gradient + navy
 * text (matches the auth/scholarship primaries). Two classes out-specify base. */
.learner-profile-area .btn-grokkoli-primary {
    background-color: var(--helio-solar-gold);
    background-image: linear-gradient(180deg, var(--helio-sunlight), var(--helio-solar-gold));
    color: var(--helio-midnight);
    border: none;
}
.learner-profile-area .btn-grokkoli-primary:hover,
.learner-profile-area .btn-grokkoli-primary:focus,
.learner-profile-area .btn-grokkoli-primary:active {
    background-color: var(--helio-amber);
    background-image: linear-gradient(180deg, var(--helio-solar-gold), var(--helio-amber));
    color: var(--helio-midnight);
}
/* Non-colour focus/press affordance (WCAG 1.4.1 "use of colour" + 2.4.7 focus visible):
 * the gradient shift above is colour-only, so add a SHAPE signal — a detached ring on focus
 * plus a press nudge. Ring is SKY-BLUE (--helio-sky), not the button's gold: gold on this
 * layer's light page (--helio-cloud) is only ~1.7:1 — too faint to be a reliable indicator —
 * whereas sky clears ~3:1 AND matches the focus hue this layer already uses on its form
 * inputs (.form-control:focus below), so buttons and fields indicate focus the same way.
 * (Only fires on focusable elements: the <button>/<input>/<a> primary buttons — a bare
 * non-focusable <div class="btn"> can't receive :focus.) */
.learner-profile-area .btn-grokkoli-primary:focus {
    outline: 2px solid var(--helio-sky);
    outline-offset: 3px;
    box-shadow: none;   /* clear Bootstrap's .btn:focus glow */
}
.learner-profile-area .btn-grokkoli-primary:active {
    transform: translateY(1px);
}

/* Secondary buttons keep the grey fill but their text is Grokkoli blue → slate. */
.learner-profile-area .btn-grokkoli-secondary { color: var(--helio-slate); }
.learner-profile-area .btn-grokkoli-secondary:hover,
.learner-profile-area .btn-grokkoli-secondary:active { color: var(--helio-midnight); }

/* On/off toggles: the active segment is Grokkoli green → Heliomath success green
 * (keeps the "on = green" affordance, on-brand). */
.learner-profile-area .setting-option .btn-secondary:not(:disabled).active {
    background-color: var(--helio-success);
}

/* Learner selector pills: active/hover green → Heliomath success green. */
.learner-profile-area .learner-tab:hover {
    border-color: var(--helio-success);
    color: var(--helio-success);
}
.learner-profile-area .learner-tab.active {
    background-color: var(--helio-success);
    border-color: var(--helio-success);
    color: var(--helio-white);
}
/* Save buttons (enabled): Grokkoli green fill → Heliomath success green. */
.learner-profile-area .profile-save-btn:not(.profile-save-disabled) {
    background-color: var(--helio-success);
}

/* In-card subsection headings (PROFILE, LOGIN PIN, …): neutral grey → steel. */
.learner-profile-area .setting-subhead {
    color: var(--helio-steel);
}

/* Name-pronunciation controls are Grokkoli blue → Heliomath sky (its blue accent). */
.learner-profile-area .pronunciation-volume-icon {
    color: var(--helio-sky);
}
.learner-profile-area .pronunciation-preview-btn:hover .pronunciation-volume-icon {
    color: var(--helio-slate);
}
.learner-profile-area .pronunciation-save-btn:not(.pronunciation-save-disabled) {
    background-color: var(--helio-success);
}

/* Override dropdowns (answer-time / max-questions) are Grokkoli green → success. */
.learner-profile-area .drop-down-selector-container select,
.learner-profile-area .drop-down-selector-container select.success {
    color: var(--helio-success);
    border-color: var(--helio-success);
}

/* Login-PIN and skip-question buttons are Grokkoli purple → slate. */
.learner-profile-area .account_settings_password_button {
    color: var(--helio-slate);
}
.learner-profile-area .skip_question_button {
    color: var(--helio-slate);
}

/* Settings success/error copy: Grokkoli green/orange → Heliomath success/error.
 * (error rules come last so they win over the success colour on the PIN message,
 * which carries both classes.) */
.learner-profile-area .account_settings_message,
.learner-profile-area .profile-field-message {
    color: var(--helio-success);
}
.learner-profile-area .account_settings_message_error,
.learner-profile-area .profile-field-message.profile-field-error {
    color: var(--helio-error);
}

/* Inline green/gold/winter-green accent text → Solar Gold. */
.learner-profile-area .accent-color-green,
.learner-profile-area .accent-color-gold,
.learner-profile-area .accent-color-winter-green {
    color: var(--helio-solar-gold) !important;
}
.learner-profile-area p .accent-color-green,
.learner-profile-area li .accent-color-green {
    color: var(--helio-solar-gold) !important;
}

/* The free-trial highlight card is solid Grokkoli green → navy with white text. */
.learner-profile-area .product-card.free-trial {
    background-color: var(--helio-midnight);
    color: var(--helio-white);
}

/* ClassWallet notice banner is Grokkoli blue → Sky Blue. */
.learner-profile-area .classwallet-msg { background-color: var(--helio-sky); }

/* --- Interstitial pages (.interstitial.grokkoli-gradient): the answer-history
 *     consent page (answer_history_consent.html, shown right after signup) and the
 *     account-dissolution page (dissolve_account.html). Both extend alpha_base. The
 *     shared chrome is a green→blue gradient with white copy, lemon/gold accents and
 *     translucent-white buttons — reflow to a cream field with navy copy, gold
 *     accents and a gold primary button. --- */
.interstitial.grokkoli-gradient {
    background-image: none;
    background-color: var(--helio-cream);
}
.interstitial-message { color: var(--helio-midnight); opacity: 1; }
.interstitial-message h4 { color: var(--helio-slate); opacity: 1; }
.interstitial-message .accent-color-lemon,
.interstitial-message .accent-color-gold { color: var(--helio-amber) !important; }
/* T&S / Privacy links carry an inline light-green color; !important out-ranks the
 * inline style (inline isn't !important). */
.interstitial a { color: var(--helio-sky) !important; }
.interstitial a:hover { color: #357ABD !important; }
.interstitial .btn-grokkoli-primary {
    opacity: 1;
    color: var(--helio-midnight);
    background-color: var(--helio-solar-gold);
    background-image: linear-gradient(180deg, var(--helio-sunlight), var(--helio-solar-gold));
    border: none;
}
.interstitial .btn-grokkoli-primary:hover,
.interstitial .btn-grokkoli-primary:focus,
.interstitial .btn-grokkoli-primary:active {
    color: var(--helio-midnight);
    background-image: linear-gradient(180deg, var(--helio-solar-gold), var(--helio-amber));
}

/* --- Onboarding survey (.onboarding-survey-area.grokkoli-gradient): the "how did
 *     you hear about us" page shown right after signup. Same gradient chrome →
 *     cream field, navy heading + labels, white inputs, gold primary button. The
 *     shared CSS colors the heading mint-green with a dark-bg text-shadow; drop it. */
.onboarding-survey-area.grokkoli-gradient {
    background-image: none;
    background-color: var(--helio-cream);
}
.onboarding-survey-area h2 { color: var(--helio-midnight); text-shadow: none; }
.onboarding-survey-area label { color: var(--helio-slate); }
.onboarding-survey-area .single-option-select-field label:hover {
    background-color: rgba(13, 27, 42, 0.06);   /* --helio-midnight @ 6% */
}
.onboarding-survey-area .form-control {
    background-color: var(--helio-white);
    border: 1px solid rgba(13, 27, 42, 0.28);   /* --helio-midnight @ 28% */
    box-shadow: 0 1px 2px rgba(13, 27, 42, 0.06);
    color: var(--helio-midnight);
}
.onboarding-survey-area .form-control:focus {
    border-color: var(--helio-sky);
    box-shadow: 0 0 0 3px rgba(74, 144, 226, 0.25);   /* --helio-sky @ 25% */
    outline: none;
}
.onboarding-survey-area .btn-grokkoli-primary {
    color: var(--helio-midnight);
    background-color: var(--helio-solar-gold);
    background-image: linear-gradient(180deg, var(--helio-sunlight), var(--helio-solar-gold));
    border: none;
}
.onboarding-survey-area .btn-grokkoli-primary:hover,
.onboarding-survey-area .btn-grokkoli-primary:focus,
.onboarding-survey-area .btn-grokkoli-primary:active {
    color: var(--helio-midnight);
    background-image: linear-gradient(180deg, var(--helio-solar-gold), var(--helio-amber));
}

/* --- Post-signup trial funnel: the "how your free trial works" explainer
 *     (.start-free-trial-area.grokkoli-gradient, start_free_trial.html) and the
 *     card-entry page (.payment-details-area.grokkoli-gradient,
 *     enter_payment_details.html). Both extend alpha_base. The shared chrome is the
 *     green→blue gradient with white copy, lemon accents and a green primary button
 *     → reflow to a cream field with navy copy, gold accents and a gold button. --- */
.start-free-trial-area.grokkoli-gradient,
.payment-details-area.grokkoli-gradient {
    background-image: none;
    background-color: var(--helio-cream);
}
/* Headings/copy are white on the shared dark field; recolor for the light field.
 * (Selectors match the shared rule's specificity and win by load order.) */
.start-free-trial-area h2,
.start-free-trial-area h3,
.start-free-trial-area p,
.payment-details-area h2,
.payment-details-area h3,
.payment-details-area p {
    color: var(--helio-midnight);
    text-shadow: none;
}
/* Free-trial timeline: the shared bar is a lemon→blue gradient with lemon-ringed
 * teal notches and lemon "Today / In N days" headings — rebrand to gold/navy. */
.free-trial-explainer-container h4 {
    color: var(--helio-amber);
}
.free-trial-explainer-container .free-trial-text-block p {
    color: var(--helio-slate);
}
.free-trial-timeline {
    background-color: var(--helio-sunlight);
    background-image: linear-gradient(var(--helio-solar-gold), var(--helio-solar-gold), var(--helio-solar-gold), var(--helio-midnight));
}
.free-trial-timeline-notch {
    background-color: var(--helio-slate);
    border-color: var(--helio-solar-gold);
}
/* Payment page: product-selection labels/copy read on the dark field; recolor.
 * The discount line uses the shared lemon accent → brand amber. */
.payment-details-area label,
.payment-details-area .product-info {
    color: var(--helio-slate);
}
.payment-details-area .accent-color-lemon {
    color: var(--helio-amber) !important;
}
/* Primary buttons (#start-free-trial, #submit-payment-btn) → gold gradient, navy
 * text. Base rule is single-class .btn-grokkoli-primary; these two-class selectors
 * win, and no ID rule sets the button background so class specificity suffices. */
.start-free-trial-area .btn-grokkoli-primary,
.payment-details-area .btn-grokkoli-primary {
    background-color: var(--helio-solar-gold);
    background-image: linear-gradient(180deg, var(--helio-sunlight), var(--helio-solar-gold));
    color: var(--helio-midnight);
    border: none;
}
.start-free-trial-area .btn-grokkoli-primary:hover,
.start-free-trial-area .btn-grokkoli-primary:focus,
.start-free-trial-area .btn-grokkoli-primary:active,
.payment-details-area .btn-grokkoli-primary:hover,
.payment-details-area .btn-grokkoli-primary:focus,
.payment-details-area .btn-grokkoli-primary:active {
    background-color: var(--helio-amber);
    background-image: linear-gradient(180deg, var(--helio-solar-gold), var(--helio-amber));
    color: var(--helio-midnight);
}

/* Brand the question icons. These classes set their background-image in the
   static figureone.css, which is linked AFTER this file, so !important is
   required to win the cascade at equal specificity.
   - .ghelp_grokkoli_icon: top-left help-bubble icon (most questions)
   - .ghelp_grokkoli_icon_white: its white/grey variant (message/decision)
   - .icon_grokkoli_logo: the large logo in honing (honing_intro equation_icon) */
.ghelp_grokkoli_icon {
    background-image: url("/static/img/brands/heliomath/help-icon.261d8b93d7ba.png") !important;
}
.ghelp_grokkoli_icon_white {
    background-image: url("/static/img/brands/heliomath/help-icon-white.55323c6da3e6.png") !important;
}
.icon_grokkoli_logo {
    background-image: url("/static/img/brands/heliomath/honing-logo.f37c6997b781.png") !important;
}
