/* ================================================================
   ENROLLMENT JOURNEY  —  enroll.css

   Shared by /enroll and /enroll/verify. Mirrors the onboarding
   screens of the ParadicShift app (paradicshift_app_v2 · PSBrand:
   forest green + cream + gold) while sitting inside the website's
   existing design language (custom.css tokens, index.css idx-*).

     forest  #0e2818   cream   #f8f4e6   gold  #e2672a
     site primary #002c1b · site bg #fffbe0 · site CTA #e35b11
   ================================================================ */

.enr-main {
    /* PSBrand palette (app parity) */
    --enr-forest-deep: #081a11;
    --enr-forest: #0e2818;
    --enr-forest-light: #1f4a32;
    --enr-sage: #a9c79c;
    --enr-sage-soft: #dce9d2;
    --enr-cream: #f8f4e6;
    --enr-cream-soft: #fbf8ee;
    --enr-gold: #e2672a;
    --enr-gold-deep: #c0501a;
    --enr-gold-light: #f2a24e;
    --enr-green: #3dcc80;

    /* surface tokens — overridden per colour scheme below */
    --enr-card-bg: #ffffff;
    --enr-card-border: rgba(14, 40, 24, 0.10);
    --enr-card-shadow: 0 30px 70px rgba(0, 44, 27, 0.14);
    --enr-ink: #0e2818;
    --enr-ink-soft: rgba(14, 40, 24, 0.66);
    --enr-ink-faint: rgba(14, 40, 24, 0.42);
    --enr-field-bg: #ffffff;
    --enr-field-border: rgba(14, 40, 24, 0.14);
    --enr-field-shadow: 0 10px 24px rgba(14, 40, 24, 0.06);
    --enr-rule: rgba(14, 40, 24, 0.10);
    --enr-danger: #d0402b;

    /* motion */
    --enr-ease: cubic-bezier(0.22, 1, 0.36, 1);
    --enr-ease-soft: cubic-bezier(0.4, 0, 0.2, 1);
}

@media (prefers-color-scheme: dark) {
    .enr-main {
        --enr-card-bg: rgba(30, 34, 30, 0.92);
        --enr-card-border: rgba(140, 220, 170, 0.14);
        --enr-card-shadow: 0 30px 70px rgba(0, 0, 0, 0.45);
        --enr-ink: #eef2ec;
        --enr-ink-soft: rgba(238, 242, 236, 0.68);
        --enr-ink-faint: rgba(238, 242, 236, 0.42);
        --enr-field-bg: rgba(18, 22, 19, 0.85);
        --enr-field-border: rgba(160, 210, 180, 0.18);
        --enr-field-shadow: 0 10px 24px rgba(0, 0, 0, 0.35);
        --enr-rule: rgba(160, 210, 180, 0.14);
        --enr-danger: #ff7565;
    }
}


/* ================================================================
   HERO BAND  (dark forest header carrying the progress rail)
   ================================================================ */

.enr-hero {
    position: relative;
    overflow: hidden;
    isolation: isolate;
    background-color: var(--enr-forest-deep);
    padding: 54px 0 96px;
}

.enr-hero-inner {
    position: relative;
    z-index: 2;
}

.enr-hero .idx-glow-1 {
    width: 720px;
    height: 720px;
    top: 40%;
    left: 50%;
}

.enr-hero .idx-glow-2 {
    right: 4%;
}

.enr-hero-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.09em;
    text-transform: uppercase;
    color: rgba(169, 199, 156, 0.9);
    margin-bottom: 14px;
    animation: enr-rise 700ms var(--enr-ease) both;
}

.enr-hero-title {
    font-size: clamp(1.9rem, 4.4vw, 3rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.1;
    color: #fff;
    margin-bottom: 10px;
    text-shadow: 0 0 60px rgba(0, 200, 100, 0.2), 0 2px 6px rgba(0, 0, 0, 0.35);
    animation: enr-rise 700ms 60ms var(--enr-ease) both;
}


/* ── progress rail ───────────────────────────────────────────── */

.enr-rail {
    list-style: none;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: 0;
    margin: 34px auto 0;
    padding: 0;
    max-width: 720px;
    animation: enr-rise 700ms 180ms var(--enr-ease) both;
}

.enr-rail-step {
    flex: 1 1 0;
    position: relative;
    text-align: center;
    min-width: 0;
}

/* connector line between dots — drawn behind, fills as you advance */
.enr-rail-step::before,
.enr-rail-step::after {
    content: "";
    position: absolute;
    top: 15px;
    height: 2px;
    width: 50%;
    background: rgba(255, 255, 255, 0.13);
}

.enr-rail-step::before { inset-inline-start: 0; }
.enr-rail-step::after  { inset-inline-end: 0; }

.enr-rail-step:first-child::before,
.enr-rail-step:last-child::after { display: none; }

.enr-rail-step.is-done::before,
.enr-rail-step.is-done::after,
.enr-rail-step.is-active::before {
    background: linear-gradient(90deg, rgba(77, 220, 144, 0.75), rgba(77, 220, 144, 0.45));
    box-shadow: 0 0 10px rgba(77, 220, 144, 0.35);
}

.enr-rail-dot {
    position: relative;
    z-index: 1;
    width: 32px;
    height: 32px;
    margin: 0 auto 10px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.5);
    background: var(--enr-forest);
    border: 1.5px solid rgba(255, 255, 255, 0.18);
    transition: transform 320ms var(--enr-ease),
                background 320ms var(--enr-ease-soft),
                border-color 320ms var(--enr-ease-soft),
                color 320ms var(--enr-ease-soft),
                box-shadow 320ms var(--enr-ease-soft);
}

.enr-rail-step.is-active .enr-rail-dot {
    color: #fff;
    background: linear-gradient(135deg, var(--enr-gold), var(--enr-gold-deep));
    border-color: rgba(242, 162, 78, 0.65);
    box-shadow: 0 0 0 6px rgba(226, 103, 42, 0.16), 0 8px 20px rgba(226, 103, 42, 0.32);
    transform: scale(1.14);
    animation: enr-dot-pop 520ms var(--enr-ease) both;
}

.enr-rail-step.is-done .enr-rail-dot {
    color: var(--enr-forest-deep);
    background: var(--enr-green);
    border-color: rgba(77, 220, 144, 0.75);
    box-shadow: 0 0 14px rgba(77, 220, 144, 0.35);
}

.enr-rail-step.is-done .enr-rail-num { display: none; }

.enr-rail-check {
    display: none;
    width: 15px;
    height: 15px;
}

.enr-rail-step.is-done .enr-rail-check { display: block; }

.enr-rail-check path {
    stroke-dasharray: 20;
    stroke-dashoffset: 20;
    animation: enr-draw 420ms 60ms var(--enr-ease) forwards;
}

.enr-rail-label {
    display: block;
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.045em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.38);
    padding: 0 4px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    transition: color 320ms var(--enr-ease-soft);
}

.enr-rail-step.is-active .enr-rail-label { color: rgba(255, 255, 255, 0.94); }
.enr-rail-step.is-done   .enr-rail-label { color: rgba(169, 199, 156, 0.8); }

@media (max-width: 575.98px) {
    .enr-rail-label { font-size: 0.58rem; letter-spacing: 0; padding: 0 1px; }
    .enr-rail-dot { width: 27px; height: 27px; font-size: 0.72rem; }
    .enr-rail-step::before,
    .enr-rail-step::after { top: 13px; }
}

@media (max-width: 399.98px) {
    .enr-rail-label { font-size: 0.53rem; }
}


/* ================================================================
   BODY  ·  the floating card that holds every step panel
   ================================================================ */

.enr-body {
    position: relative;
    padding-bottom: 72px;
    min-height: auto;
}

.enr-stage {
    position: relative;
    margin-top: -60px;
    z-index: 3;
}

.enr-card {
    position: relative;
    overflow: hidden;
    background: var(--enr-card-bg);
    border: 1px solid var(--enr-card-border);
    border-top: 1px solid rgba(80, 200, 120, 0.32);
    border-radius: 22px;
    box-shadow: var(--enr-card-shadow);
    padding: 40px 32px 36px;
    color: var(--enr-ink);
    animation: enr-card-in 720ms var(--enr-ease) both;
    /* height animates between panels of different size */
    transition: height 420ms var(--enr-ease);
}

.enr-card::before {
    /* soft light source at the top edge, echoing .idx-cap-glow */
    content: "";
    position: absolute;
    top: -70px;
    left: 50%;
    transform: translateX(-50%);
    width: 320px;
    height: 180px;
    border-radius: 50%;
    background: radial-gradient(ellipse at center, rgba(60, 200, 110, 0.16) 0%, transparent 70%);
    pointer-events: none;
}

@media (max-width: 575.98px) {
    .enr-card { padding: 30px 20px 28px; border-radius: 18px; }
    .enr-stage { margin-top: -48px; }
    .enr-hero { padding: 40px 0 84px; }
}


/* ── panels & their transitions ──────────────────────────────── */

.enr-panels { position: relative; }

.enr-panel {
    display: none;
    position: relative;
}

.enr-panel.is-current { display: block; }

.enr-panel.is-entering {
    animation: enr-panel-in 480ms var(--enr-ease) both;
}

.enr-panel.is-entering-back {
    animation: enr-panel-in-back 480ms var(--enr-ease) both;
}

.enr-panel.is-leaving {
    position: absolute;
    inset: 0;
    pointer-events: none;
    animation: enr-panel-out 260ms var(--enr-ease-soft) both;
}

.enr-panel.is-leaving-back {
    position: absolute;
    inset: 0;
    pointer-events: none;
    animation: enr-panel-out-back 260ms var(--enr-ease-soft) both;
}


/* ── panel heading (mirrors each app screen's display heading) ── */

.enr-panel-head { margin-bottom: 26px; }

.enr-panel-title {
    font-size: clamp(1.5rem, 3.4vw, 2.05rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.14;
    color: var(--enr-ink);
    margin-bottom: 8px;
}

.enr-panel-sub {
    font-size: 0.95rem;
    line-height: 1.7;
    color: var(--enr-ink-soft);
    margin-bottom: 0;
    max-width: 56ch;
}

.enr-panel-kicker {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--enr-gold);
    margin-bottom: 12px;
}

.enr-panel-kicker::before {
    content: "";
    width: 18px;
    height: 2px;
    border-radius: 2px;
    background: linear-gradient(90deg, var(--enr-gold), transparent);
}


/* ================================================================
   FORM CONTROLS  (app parity: white rounded card fields)
   ================================================================ */

.enr-fields {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px 20px;
}

.enr-field { position: relative; }
.enr-field.enr-col-full { grid-column: 1 / -1; }

@media (max-width: 767.98px) {
    .enr-fields { grid-template-columns: minmax(0, 1fr); }
}

/* staggered entrance — --i is set per field by enroll.js */
.enr-anim {
    animation: enr-rise 560ms var(--enr-ease) both;
    animation-delay: calc(var(--i, 0) * 70ms + 90ms);
}

.enr-label {
    display: block;
    font-size: 0.82rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    color: var(--enr-ink-soft);
    margin: 0 0 8px 2px;
    transition: color 200ms var(--enr-ease-soft);
}

.enr-label .enr-opt {
    font-weight: 400;
    font-size: 0.76rem;
    color: var(--enr-ink-faint);
    margin-inline-start: 5px;
}

.enr-field:focus-within .enr-label { color: var(--enr-gold); }

/* the control shell — border, shadow, animated accent bar */
.enr-control {
    position: relative;
    background: var(--enr-field-bg);
    border: 1.4px solid var(--enr-field-border);
    border-radius: 16px;
    box-shadow: var(--enr-field-shadow);
    overflow: hidden;
    transition: border-color 220ms var(--enr-ease-soft),
                box-shadow 260ms var(--enr-ease-soft),
                transform 260ms var(--enr-ease);
}

.enr-control::after {
    /* accent bar that scales out from the centre on focus */
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--enr-gold-light), var(--enr-gold), var(--enr-gold-deep));
    transform: scaleX(0);
    transform-origin: center;
    transition: transform 320ms var(--enr-ease);
}

.enr-control:focus-within {
    border-color: rgba(226, 103, 42, 0.55);
    box-shadow: 0 0 0 4px rgba(226, 103, 42, 0.12), 0 14px 30px rgba(14, 40, 24, 0.10);
    transform: translateY(-1px);
}

.enr-control:focus-within::after { transform: scaleX(1); }

.enr-control:hover:not(:focus-within) { border-color: rgba(14, 40, 24, 0.24); }

@media (prefers-color-scheme: dark) {
    .enr-control:hover:not(:focus-within) { border-color: rgba(160, 210, 180, 0.34); }
}

.enr-input,
.enr-select,
.enr-textarea {
    display: block;
    width: 100%;
    border: 0;
    outline: 0;
    background: transparent;
    color: var(--enr-ink);
    font-family: inherit;
    font-size: 1rem;
    font-weight: 500;
    line-height: 1.5;
    padding: 16px 18px;
    appearance: none;
    -webkit-appearance: none;
}

.enr-input.enr-lg { font-size: 1.12rem; padding: 20px; }

.enr-textarea { resize: vertical; min-height: 96px; }

.enr-input::placeholder,
.enr-textarea::placeholder { color: var(--enr-ink-faint); font-weight: 400; }

.enr-input:-webkit-autofill {
    -webkit-text-fill-color: var(--enr-ink);
    -webkit-box-shadow: 0 0 0 60px var(--enr-field-bg) inset;
    transition: background-color 100000s ease-in-out 0s;
}

.enr-select {
    padding-inline-end: 44px;
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%230e2818' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' opacity='0.55'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 18px center;
    background-size: 16px;
}

html[dir="rtl"] .enr-select { background-position: left 18px center; }

@media (prefers-color-scheme: dark) {
    .enr-select {
        background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23eef2ec' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' opacity='0.6'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    }
    .enr-select option { background: #1e221e; color: var(--enr-ink); }
}

/* prefix (e.g. the @ in front of an account id) */
.enr-control.has-prefix .enr-input { padding-inline-start: 6px; }

.enr-prefix {
    position: absolute;
    inset-inline-start: 18px;
    top: 50%;
    transform: translateY(-50%);
    font-weight: 600;
    color: var(--enr-ink-faint);
    pointer-events: none;
}

.enr-control.has-prefix { display: flex; align-items: center; }
.enr-control.has-prefix .enr-prefix { position: static; transform: none; }

/* trailing action (password reveal) */
.enr-control.has-suffix .enr-input { padding-inline-end: 52px; }

.enr-suffix {
    position: absolute;
    inset-inline-end: 6px;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: var(--enr-ink-faint);
    cursor: pointer;
    transition: color 180ms var(--enr-ease-soft), background 180ms var(--enr-ease-soft);
}

.enr-suffix:hover { color: var(--enr-gold); background: rgba(226, 103, 42, 0.10); }
.enr-suffix svg { width: 19px; height: 19px; }

/* checkbox */
.enr-check {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 15px 18px;
    background: var(--enr-field-bg);
    border: 1.4px solid var(--enr-field-border);
    border-radius: 16px;
    box-shadow: var(--enr-field-shadow);
    cursor: pointer;
    transition: border-color 220ms var(--enr-ease-soft), box-shadow 220ms var(--enr-ease-soft);
}

.enr-check:hover { border-color: rgba(226, 103, 42, 0.35); }

.enr-check input {
    flex: 0 0 auto;
    width: 20px;
    height: 20px;
    margin-top: 1px;
    accent-color: var(--enr-gold);
    cursor: pointer;
}

.enr-check span {
    font-size: 0.92rem;
    line-height: 1.5;
    color: var(--enr-ink);
}

/* hint + inline error */
.enr-hint {
    font-size: 0.78rem;
    line-height: 1.55;
    color: var(--enr-ink-faint);
    margin: 7px 0 0 2px;
}

.enr-error-text {
    display: none;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--enr-danger);
    margin: 7px 0 0 2px;
}

.enr-field.is-invalid .enr-error-text {
    display: block;
    animation: enr-rise 260ms var(--enr-ease) both;
}

.enr-field.is-invalid .enr-control,
.enr-field.is-invalid .enr-check {
    border-color: var(--enr-danger);
    box-shadow: 0 0 0 4px rgba(208, 64, 43, 0.12);
    animation: enr-shake 460ms var(--enr-ease-soft) both;
}

.enr-field.is-invalid .enr-label { color: var(--enr-danger); }

.enr-security {
    grid-column: 1 / -1;
    display: grid;
    gap: 18px;
    margin-top: 6px;
    padding: 20px;
    border: 1px solid rgba(8, 145, 178, 0.28);
    border-radius: 18px;
    background:
        linear-gradient(135deg, rgba(207, 250, 254, 0.72), rgba(204, 251, 241, 0.48));
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

.enr-security-head h3 {
    margin: 0 0 4px;
    color: var(--enr-ink);
    font-size: 1rem;
}

.enr-security-head p {
    margin: 0;
    color: var(--enr-ink-faint);
    font-size: 0.82rem;
    line-height: 1.5;
}

.enr-security-row {
    display: flex;
    align-items: stretch;
    gap: 10px;
    margin-top: 8px;
}

.enr-security-row .enr-control { flex: 1 1 auto; }
.enr-security-copy {
    display: flex;
    align-items: center;
    min-height: 48px;
    padding: 0 14px;
    color: var(--enr-ink-soft);
    font-size: 0.84rem;
    line-height: 1.45;
}
.enr-security-row .enr-btn {
    flex: 0 0 auto;
    min-width: 112px;
    padding: 0 18px;
}

.enr-phone-row {
    display: grid;
    grid-template-columns: minmax(210px, 0.9fr) minmax(180px, 1.1fr) auto;
    align-items: stretch;
    gap: 10px;
    margin-top: 8px;
}

.enr-country-select {
    min-width: 0;
    cursor: pointer;
}

.enr-phone-row .enr-control { min-width: 0; }
.enr-phone-row .enr-btn {
    min-width: 112px;
    padding: 0 18px;
}

@media (prefers-color-scheme: dark) {
    .enr-security {
        border-color: rgba(34, 211, 238, 0.26);
        background:
            linear-gradient(135deg, rgba(8, 145, 178, 0.16), rgba(13, 148, 136, 0.10));
        box-shadow: inset 0 1px 0 rgba(165, 243, 252, 0.08);
    }
}

@media (max-width: 520px) {
    .enr-security-row { flex-direction: column; }
    .enr-security-row .enr-btn { min-height: 48px; }
    .enr-phone-row { grid-template-columns: 1fr; }
    .enr-phone-row .enr-btn { min-height: 48px; }
}


/* ================================================================
   BUTTONS
   ================================================================ */

.enr-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 30px;
}

.enr-actions.enr-actions-center { justify-content: center; }

.enr-btn {
    position: relative;
    overflow: hidden;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    border: 0;
    border-radius: 14px;
    padding: 15px 30px;
    font-family: inherit;
    font-size: 1rem;
    font-weight: 600;
    line-height: 1.2;
    cursor: pointer;
    text-decoration: none;
    transition: transform 200ms var(--enr-ease),
                box-shadow 260ms var(--enr-ease-soft),
                background 220ms var(--enr-ease-soft),
                opacity 200ms var(--enr-ease-soft);
}

.enr-btn:disabled { cursor: not-allowed; opacity: 0.62; }
.enr-btn:not(:disabled):hover { transform: translateY(-2px); }
.enr-btn:not(:disabled):active { transform: translateY(0) scale(0.985); }

.enr-btn-primary {
    flex: 1 1 auto;
    color: #fff;
    background: linear-gradient(135deg, var(--enr-gold-light) -10%, var(--enr-gold) 45%, var(--enr-gold-deep) 100%);
    box-shadow: 0 10px 26px rgba(226, 103, 42, 0.28);
}

.enr-btn-primary:not(:disabled):hover {
    box-shadow: 0 16px 34px rgba(226, 103, 42, 0.4), 0 0 0 1px rgba(242, 162, 78, 0.4);
}

/* sheen sweep on hover */
.enr-btn-primary::after {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    width: 40%;
    left: -60%;
    background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.35), transparent);
    transform: skewX(-18deg);
    transition: left 620ms var(--enr-ease);
}

.enr-btn-primary:not(:disabled):hover::after { left: 130%; }

.enr-btn-ghost {
    color: var(--enr-ink-soft);
    background: transparent;
    border: 1.4px solid var(--enr-field-border);
}

.enr-btn-ghost:not(:disabled):hover {
    color: var(--enr-ink);
    border-color: rgba(14, 40, 24, 0.3);
    background: rgba(14, 40, 24, 0.04);
}

@media (prefers-color-scheme: dark) {
    .enr-btn-ghost:not(:disabled):hover {
        border-color: rgba(160, 210, 180, 0.4);
        background: rgba(255, 255, 255, 0.05);
    }
}

.enr-btn-quiet {
    background: none;
    border: 0;
    padding: 10px 6px;
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--enr-ink-soft);
    cursor: pointer;
    border-radius: 8px;
    transition: color 180ms var(--enr-ease-soft);
}

.enr-btn-quiet:not(:disabled):hover { color: var(--enr-gold); }
.enr-btn-quiet:disabled { opacity: 0.5; cursor: default; }

/* spinner shown inside a busy button */
.enr-spin {
    display: none;
    width: 19px;
    height: 19px;
    border-radius: 50%;
    border: 2.2px solid rgba(255, 255, 255, 0.35);
    border-top-color: #fff;
    animation: enr-spin 720ms linear infinite;
}

.enr-btn.is-busy .enr-spin { display: block; }
.enr-btn.is-busy .enr-btn-label { opacity: 0.75; }


/* ================================================================
   ALERTS
   ================================================================ */

.enr-alert {
    display: none;
    gap: 12px;
    align-items: flex-start;
    border-radius: 14px;
    padding: 14px 16px;
    font-size: 0.9rem;
    line-height: 1.6;
    margin-bottom: 20px;
}

.enr-alert.is-shown {
    display: flex;
    animation: enr-rise 380ms var(--enr-ease) both;
}

.enr-alert svg { flex: 0 0 auto; width: 19px; height: 19px; margin-top: 2px; }

.enr-alert-danger {
    color: var(--enr-danger);
    background: rgba(208, 64, 43, 0.10);
    border: 1px solid rgba(208, 64, 43, 0.28);
}

.enr-alert-info {
    color: var(--enr-ink);
    background: rgba(60, 200, 110, 0.10);
    border: 1px solid rgba(60, 200, 110, 0.28);
}


/* ================================================================
   E-MAIL SENT PANEL  (the app's "check your e-mail" moment)
   ================================================================ */

.enr-sent { text-align: center; }

.enr-envelope {
    position: relative;
    width: 108px;
    height: 108px;
    margin: 4px auto 26px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.enr-envelope-ring {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    border: 1.5px solid rgba(226, 103, 42, 0.35);
    animation: enr-ripple 2.8s var(--enr-ease-soft) infinite;
}

.enr-envelope-ring:nth-child(2) { animation-delay: 0.9s; }
.enr-envelope-ring:nth-child(3) { animation-delay: 1.8s; }

.enr-envelope-body {
    position: relative;
    width: 74px;
    height: 74px;
    border-radius: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    background: linear-gradient(135deg, var(--enr-gold-light), var(--enr-gold-deep));
    box-shadow: 0 16px 34px rgba(226, 103, 42, 0.34);
    animation: enr-float 3.6s ease-in-out infinite;
}

.enr-envelope-body svg { width: 34px; height: 34px; }

.enr-email-chip {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    max-width: 100%;
    padding: 9px 18px;
    margin: 4px 0 18px;
    border-radius: 999px;
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--enr-ink);
    background: rgba(60, 200, 110, 0.12);
    border: 1px solid rgba(60, 200, 110, 0.3);
    word-break: break-all;
}

.enr-email-chip svg { flex: 0 0 auto; width: 16px; height: 16px; color: var(--enr-green); }

.enr-sent .enr-panel-sub { margin-inline: auto; }

.enr-sent-help {
    font-size: 0.86rem;
    line-height: 1.7;
    color: var(--enr-ink-faint);
    max-width: 46ch;
    margin: 0 auto;
}

.enr-resend-row {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    margin-top: 26px;
    padding-top: 22px;
    border-top: 1px solid var(--enr-rule);
}


/* ================================================================
   "WHAT HAPPENS NEXT"  ·  preview of the remaining app steps
   ================================================================ */

.enr-next { margin-top: 34px; }

.enr-next-title {
    font-size: 0.74rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--enr-ink-faint);
    text-align: center;
    margin-bottom: 18px;
}

.enr-next-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

@media (max-width: 991.98px) {
    .enr-next-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .enr-next-card:last-child { grid-column: 1 / -1; }
}

@media (max-width: 767.98px) {
    .enr-next-grid { grid-template-columns: minmax(0, 1fr); }
    .enr-next-card:last-child { grid-column: auto; }
}

.enr-next-card {
    position: relative;
    overflow: hidden;
    border-radius: 14px;
    padding: 22px 20px;
    /* deliberately lighter than the site's .idx-cap-card so the enrollment
       card above stays the focal point of the page */
    background: rgba(255, 255, 255, 0.6);
    border: 1px solid rgba(14, 40, 24, 0.1);
    border-top: 1px solid rgba(80, 200, 120, 0.45);
    transition: transform 240ms var(--enr-ease), box-shadow 240ms var(--enr-ease-soft),
                border-top-color 240ms var(--enr-ease-soft);
}

@media (prefers-color-scheme: dark) {
    .enr-next-card {
        background: rgba(255, 255, 255, 0.045);
        border-color: rgba(160, 210, 180, 0.12);
        border-top-color: rgba(80, 200, 120, 0.35);
    }
}

.enr-next-card:hover {
    transform: translateY(-4px);
    border-top-color: rgba(80, 200, 120, 0.7);
    box-shadow: 0 16px 40px rgba(0, 44, 27, 0.14);
}

.enr-next-icon {
    width: 46px;
    height: 46px;
    border-radius: 13px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 14px;
    color: #16794a;
    background: rgba(0, 44, 27, 0.09);
    transition: transform 240ms var(--enr-ease), background 240ms var(--enr-ease-soft);
}

.enr-next-card:hover .enr-next-icon { transform: translateY(-2px) rotate(-4deg); }
.enr-next-icon svg { width: 23px; height: 23px; }

@media (prefers-color-scheme: dark) {
    .enr-next-icon { color: var(--enr-green); background: rgba(60, 200, 110, 0.1); }
}

.enr-next-step {
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--enr-gold);
    margin-bottom: 6px;
}

.enr-next-card h3 {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 6px;
    color: var(--text-color);
}

.enr-next-card p {
    font-size: 0.85rem;
    line-height: 1.65;
    opacity: 0.72;
    margin-bottom: 0;
    color: var(--text-color);
}


/* ── trust row ───────────────────────────────────────────────── */

.enr-trust {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px 26px;
    margin-top: 26px;
    padding-top: 22px;
    border-top: 1px solid var(--enr-rule);
}

.enr-trust span {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--enr-ink-faint);
}

.enr-trust svg { width: 15px; height: 15px; color: var(--enr-green); }


/* ================================================================
   LOADING SKELETON  (verify form fetch)
   ================================================================ */

.enr-skeleton { display: grid; gap: 18px; }

.enr-sk {
    height: 58px;
    border-radius: 16px;
    background: linear-gradient(100deg,
        var(--enr-field-bg) 30%,
        rgba(169, 199, 156, 0.22) 50%,
        var(--enr-field-bg) 70%);
    background-size: 260% 100%;
    border: 1px solid var(--enr-field-border);
    animation: enr-shimmer 1.5s linear infinite;
}

.enr-sk.enr-sk-title { height: 26px; width: 46%; border-radius: 8px; }
.enr-sk.enr-sk-sub { height: 14px; width: 72%; border-radius: 8px; margin-bottom: 10px; }


/* ================================================================
   REVIEW LIST
   ================================================================ */

.enr-review {
    border: 1px solid var(--enr-field-border);
    border-radius: 16px;
    overflow: hidden;
    background: var(--enr-field-bg);
    box-shadow: var(--enr-field-shadow);
}

.enr-review-group {
    padding: 13px 18px;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--enr-gold);
    background: rgba(226, 103, 42, 0.07);
    border-bottom: 1px solid var(--enr-rule);
}

.enr-review-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 18px;
    padding: 13px 18px;
    border-bottom: 1px solid var(--enr-rule);
    animation: enr-rise 420ms var(--enr-ease) both;
    animation-delay: calc(var(--i, 0) * 45ms + 60ms);
}

.enr-review-row:last-child { border-bottom: 0; }

.enr-review-key {
    font-size: 0.85rem;
    color: var(--enr-ink-soft);
    flex: 0 0 auto;
    max-width: 50%;
}

.enr-review-val {
    font-size: 0.92rem;
    font-weight: 600;
    color: var(--enr-ink);
    text-align: end;
    word-break: break-word;
}


/* ================================================================
   SUCCESS PANEL
   ================================================================ */

.enr-done { text-align: center; }

.enr-done-mark {
    position: relative;
    width: 96px;
    height: 96px;
    margin: 6px auto 26px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(60, 200, 110, 0.22), rgba(60, 200, 110, 0.08));
    border: 1.5px solid rgba(60, 200, 110, 0.45);
    animation: enr-pop 620ms var(--enr-ease) both;
}

.enr-done-mark::after {
    content: "";
    position: absolute;
    inset: -10px;
    border-radius: 50%;
    border: 1.5px solid rgba(60, 200, 110, 0.35);
    animation: enr-ripple 2.6s var(--enr-ease-soft) infinite;
}

.enr-done-mark svg { width: 44px; height: 44px; color: var(--enr-green); }

.enr-done-mark svg path {
    stroke-dasharray: 48;
    stroke-dashoffset: 48;
    animation: enr-draw 620ms 300ms var(--enr-ease) forwards;
}

.enr-done .enr-panel-sub { margin-inline: auto; }

.enr-destination-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: stretch;
    gap: 18px;
    margin-top: 28px;
    text-align: start;
}

.enr-destination-card {
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    min-width: 0;
    padding: 22px;
    border: 1px solid var(--enr-rule);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.5);
    box-shadow: 0 14px 32px rgba(0, 44, 27, 0.07);
}

.enr-destination-card::before {
    content: "";
    position: absolute;
    inset: 0 0 auto;
    height: 3px;
    background: linear-gradient(90deg, var(--enr-green), rgba(60, 200, 110, 0.1));
}

.enr-destination-user::before {
    background: linear-gradient(90deg, var(--enr-gold), rgba(226, 103, 42, 0.1));
}

.enr-destination-head {
    display: flex;
    align-items: center;
    gap: 13px;
    margin-bottom: 14px;
}

.enr-destination-icon {
    flex: 0 0 auto;
    width: 48px;
    height: 48px;
    display: grid;
    place-items: center;
    border-radius: 14px;
    color: #16794a;
    background: rgba(60, 200, 110, 0.12);
    border: 1px solid rgba(60, 200, 110, 0.2);
}

.enr-destination-user .enr-destination-icon {
    color: var(--enr-gold-deep);
    background: rgba(226, 103, 42, 0.1);
    border-color: rgba(226, 103, 42, 0.18);
}

.enr-destination-icon svg {
    width: 25px;
    height: 25px;
}

.enr-destination-fit {
    display: block;
    margin-bottom: 3px;
    color: var(--enr-ink-faint);
    font-size: 0.66rem;
    font-weight: 700;
    letter-spacing: 0.09em;
    line-height: 1.25;
    text-transform: uppercase;
}

.enr-destination-card h3 {
    margin: 0;
    color: var(--enr-ink);
    font-size: 1.08rem;
    line-height: 1.25;
}

.enr-destination-card > p {
    margin: 0 0 20px;
    color: var(--enr-ink-soft);
    font-size: 0.84rem;
    line-height: 1.6;
}

.enr-store-links {
    display: grid;
    gap: 10px;
    margin-top: auto;
}

.enr-console-store-links {
    margin-top: 10px;
}

.enr-store-badge-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    min-height: 68px;
    padding: 8px 12px;
    border: 1px solid var(--enr-rule);
    border-radius: 14px;
    color: var(--enr-ink-soft);
    background: rgba(255, 255, 255, 0.72);
    text-decoration: none;
    transition: transform 200ms var(--enr-ease), border-color 200ms var(--enr-ease-soft),
                box-shadow 200ms var(--enr-ease-soft);
}

.enr-store-badge-link:hover {
    color: var(--enr-ink);
    transform: translateY(-2px);
    border-color: rgba(60, 200, 110, 0.5);
    box-shadow: 0 12px 28px rgba(0, 44, 27, 0.1);
}

.enr-store-badge-link img {
    display: block;
    flex: 0 0 auto;
    width: 146px;
    max-width: 62%;
    height: 48px;
    object-fit: contain;
    object-position: left center;
}

[dir="rtl"] .enr-store-badge-link img {
    object-position: right center;
}

.enr-store-badge-link span {
    min-width: 0;
    color: var(--enr-ink-soft);
    font-size: 0.78rem;
    font-weight: 700;
    line-height: 1.35;
    text-align: end;
}

.enr-app-link {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
    min-height: 72px;
    margin-top: auto;
    padding: 12px 14px;
    border: 1px solid var(--enr-rule);
    border-radius: 14px;
    color: var(--enr-ink);
    background: rgba(255, 255, 255, 0.72);
    text-decoration: none;
    transition: transform 200ms var(--enr-ease), border-color 200ms var(--enr-ease-soft),
                box-shadow 200ms var(--enr-ease-soft);
}

.enr-app-link:hover {
    color: var(--enr-ink);
    transform: translateY(-2px);
    border-color: rgba(60, 200, 110, 0.5);
    box-shadow: 0 12px 28px rgba(0, 44, 27, 0.1);
}

.enr-app-link-icon,
.enr-store-mark {
    flex: 0 0 46px;
    width: 46px;
    height: 46px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    background: rgba(14, 40, 24, 0.055);
}

.enr-app-link-icon {
    color: #16794a;
    background: rgba(60, 200, 110, 0.13);
}

.enr-app-link-icon svg {
    width: 23px;
    height: 23px;
}

.enr-store-mark img {
    display: block;
    max-width: 38px;
    max-height: 38px;
}

.enr-app-link-copy {
    min-width: 0;
    flex: 1 1 auto;
    display: grid;
    gap: 3px;
}

.enr-app-link-copy strong {
    font-size: 0.96rem;
    line-height: 1.25;
}

.enr-app-link-copy small {
    color: var(--enr-ink-soft);
    font-size: 0.78rem;
    line-height: 1.35;
}

.enr-app-link-arrow {
    flex: 0 0 auto;
    width: 17px;
    height: 17px;
    color: var(--enr-ink-faint);
    transition: transform 200ms var(--enr-ease);
}

.enr-app-link:hover .enr-app-link-arrow {
    transform: translateX(3px);
}

[dir="rtl"] .enr-app-link-arrow {
    transform: scaleX(-1);
}

[dir="rtl"] .enr-app-link:hover .enr-app-link-arrow {
    transform: scaleX(-1) translateX(3px);
}

.enr-app-link-primary {
    border-color: rgba(60, 200, 110, 0.42);
    background: linear-gradient(135deg, rgba(60, 200, 110, 0.14), rgba(255, 255, 255, 0.54));
}

@media (prefers-color-scheme: dark) {
    .enr-destination-card {
        background: rgba(255, 255, 255, 0.035);
        box-shadow: 0 14px 32px rgba(0, 0, 0, 0.18);
    }

    .enr-app-link {
        background: rgba(255, 255, 255, 0.045);
    }

    .enr-store-badge-link {
        background: rgba(255, 255, 255, 0.045);
    }

    .enr-app-link-primary {
        background: linear-gradient(135deg, rgba(60, 200, 110, 0.14), rgba(255, 255, 255, 0.045));
    }
}

@media (max-width: 767.98px) {
    .enr-destination-grid { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 399.98px) {
    .enr-destination-card { padding: 18px; }
    .enr-app-link { padding: 11px; }
    .enr-app-link-icon,
    .enr-store-mark {
        flex-basis: 42px;
        width: 42px;
        height: 42px;
    }
}


/* ================================================================
   TURNSTILE
   ================================================================ */

.enr-captcha {
    display: flex;
    justify-content: center;
    margin-top: 22px;
    min-height: 66px;
    animation: enr-rise 560ms 260ms var(--enr-ease) both;
}


/* ================================================================
   KEYFRAMES
   ================================================================ */

@keyframes enr-rise {
    from { opacity: 0; transform: translateY(16px); }
    to   { opacity: 1; transform: translateY(0); }
}

@keyframes enr-card-in {
    from { opacity: 0; transform: translateY(28px) scale(0.985); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes enr-panel-in {
    from { opacity: 0; transform: translateX(26px) scale(0.99); }
    to   { opacity: 1; transform: translateX(0) scale(1); }
}

@keyframes enr-panel-in-back {
    from { opacity: 0; transform: translateX(-26px) scale(0.99); }
    to   { opacity: 1; transform: translateX(0) scale(1); }
}

@keyframes enr-panel-out {
    from { opacity: 1; transform: translateX(0); }
    to   { opacity: 0; transform: translateX(-22px); }
}

@keyframes enr-panel-out-back {
    from { opacity: 1; transform: translateX(0); }
    to   { opacity: 0; transform: translateX(22px); }
}

@keyframes enr-shake {
    0%, 100% { transform: translateX(0); }
    18%      { transform: translateX(-7px); }
    38%      { transform: translateX(6px); }
    58%      { transform: translateX(-4px); }
    78%      { transform: translateX(2px); }
}

@keyframes enr-spin { to { transform: rotate(360deg); } }

@keyframes enr-draw { to { stroke-dashoffset: 0; } }

@keyframes enr-dot-pop {
    0%   { transform: scale(0.86); }
    55%  { transform: scale(1.26); }
    100% { transform: scale(1.14); }
}

@keyframes enr-pop {
    0%   { opacity: 0; transform: scale(0.6); }
    60%  { opacity: 1; transform: scale(1.08); }
    100% { opacity: 1; transform: scale(1); }
}

@keyframes enr-ripple {
    0%   { opacity: 0.75; transform: scale(0.72); }
    80%  { opacity: 0;    transform: scale(1.25); }
    100% { opacity: 0;    transform: scale(1.25); }
}

@keyframes enr-float {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50%      { transform: translateY(-9px) rotate(-3deg); }
}

@keyframes enr-shimmer {
    from { background-position: 140% 0; }
    to   { background-position: -40% 0; }
}


/* ================================================================
   REDUCED MOTION
   ================================================================ */

@media (prefers-reduced-motion: reduce) {
    .enr-main *,
    .enr-main *::before,
    .enr-main *::after {
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.001ms !important;
    }

    .enr-main .enr-spin { animation: enr-spin 900ms linear infinite !important; }
}
