/* Pathways — tokens from thepathways.in UI Style Guide */
:root {
    --pw-sandstone: #F5F0E8;
    --pw-white: #fff;
    --pw-teal: #1E4A48;
    --pw-teal-hover: #163937;
    --pw-sage-mist: #D5DDD7;
    --pw-clay: #B98A72;
    --pw-clay-text: #8A5A44;
    --pw-ink: #1A2524;
    --font-display: 'Cormorant Garamond', Georgia, serif;
    --font-body: 'Jost', Arial, sans-serif;
    --s1: 4px;
    --s2: 8px;
    --s3: 16px;
    --s4: 24px;
    --s5: 32px;
    --s6: 48px;
    --s7: 64px;
    --s8: 96px;
    --s9: 128px;
    --section: 80px;
    --gutter: 20px;
    --header: 64px;
    --ease: 200ms ease
}

@media(min-width:768px) {
    :root {
        --gutter: 40px
    }
}

@media(min-width:1200px) {
    :root {
        --section: 128px;
        --header: 80px
    }
}

*,
*::before,
*::after {
    box-sizing: border-box
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--header) + 16px)
}

body {
    margin: 0;
    background: var(--pw-sandstone);
    color: var(--pw-ink);
    font: 400 16px/26px var(--font-body);
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden
}

@media(min-width:768px) {
    body {
        font-size: 18px;
        line-height: 29px
    }
}

img,
svg {
    max-width: 100%;
    display: block
}

h1,
h2,
h3,
p {
    margin: 0
}

h1,
h2,
h3 {
    font-family: var(--font-display);
    font-weight: 500;
    color: var(--pw-teal)
}

em {
    font-style: italic
}

a {
    color: inherit
}

.wrap {
    width: 100%;
    max-width: calc(1200px + var(--gutter)*2);
    margin: 0 auto;
    padding: 0 var(--gutter)
}

.narrow {
    max-width: 680px
}

.section {
    padding: var(--section) 0;
    position: relative
}

.bg-teal {
    background: var(--pw-teal);
    color: var(--pw-sandstone)
}

.bg-sage {
    background: var(--pw-sage-mist);
    color: var(--pw-ink);
}

.bg-sage h1,
.bg-sage h2,
.bg-sage h3 {
    color: var(--pw-teal);
}

.bg-sage .eyebrow {
    color: var(--pw-clay-text);
}

.bg-sage .muted {
    color: #2B3937;
}

.bg-sage .jstep {
    border-top-color: rgba(138, 90, 68, 0.55);
}

.bg-sage .jstep .n {
    color: var(--pw-clay-text);
}

.bg-teal h1,
.bg-teal h2,
.bg-teal h3 {
    color: var(--pw-sandstone)
}

.bg-teal .muted {
    color: var(--pw-sage-mist)
}

.display {
    font-size: 40px;
    line-height: 46px
}

.h1 {
    font-size: 34px;
    line-height: 40px
}

.h2 {
    font-size: 28px;
    line-height: 34px
}

@media(min-width:768px) {
    .display {
        font-size: 64px;
        line-height: 70px
    }

    .h1 {
        font-size: 48px;
        line-height: 56px
    }

    .h2 {
        font-size: 36px;
        line-height: 44px
    }
}

.lead {
    font-size: 18px;
    line-height: 29px
}

@media(min-width:768px) {
    .lead {
        font-size: 20px;
        line-height: 32px
    }
}

.small {
    font-size: 14px;
    line-height: 21px
}

.label,
.eyebrow {
    font: 500 12px/18px var(--font-body);
    text-transform: uppercase;
    letter-spacing: .14em
}

@media(min-width:768px) {

    .label,
    .eyebrow {
        font-size: 13px
    }
}

.eyebrow {
    color: var(--pw-clay-text);
    margin-bottom: 12px;
    display: block
}

.bg-teal .eyebrow {
    color: var(--pw-sage-mist)
}

.sec-head h2 {
    margin-bottom: 16px
}

.sec-head p {
    max-width: 680px
}

.sec-head {
    margin-bottom: var(--s7)
}

@media(min-width:768px) {
    .sec-head h2 {
        margin-bottom: 24px
    }
}

.quote {
    font: italic 400 24px/32px var(--font-display);
    color: inherit
}

@media(min-width:768px) {
    .quote {
        font-size: 32px;
        line-height: 42px
    }
}

.hair {
    height: 1px;
    background: var(--pw-clay);
    border: 0;
    margin: 0
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 52px;
    padding: 0 28px;
    border-radius: 999px;
    border: 0;
    cursor: pointer;
    font: 500 14px/1 var(--font-body);
    text-transform: uppercase;
    letter-spacing: .14em;
    text-decoration: none;
    background: var(--pw-teal);
    color: var(--pw-sandstone);
    transition: background var(--ease)
}

.btn:hover {
    background: var(--pw-teal-hover)
}

.bg-teal .btn {
    background: var(--pw-sandstone);
    color: var(--pw-teal)
}

.bg-teal .btn:hover {
    background: #EAE2D6
}

.btn[disabled] {
    opacity: .4;
    pointer-events: none
}

.link {
    display: inline-block;
    font: 500 13px/18px var(--font-body);
    text-transform: uppercase;
    letter-spacing: .14em;
    text-decoration: none;
    color: var(--pw-teal);
    background: linear-gradient(var(--pw-clay), var(--pw-clay)) left bottom/40% 1px no-repeat;
    padding-bottom: 6px;
    transition: background-size 400ms ease
}

.link:hover,
.link:focus-visible {
    background-size: 100% 1px
}

.bg-teal .link {
    color: var(--pw-sandstone)
}

.inline-link {
    color: var(--pw-clay-text);
    text-decoration: underline;
    text-underline-offset: 3px
}

:focus-visible {
    outline: 2px solid var(--pw-clay);
    outline-offset: 3px
}

.skip {
    position: absolute;
    left: -999px;
    top: 8px;
    background: var(--pw-sandstone);
    color: var(--pw-teal);
    padding: 12px 16px;
    z-index: 200
}

.skip:focus {
    left: 8px
}

.ico {
    width: 16px;
    height: 16px;
    stroke: currentColor;
    fill: none;
    stroke-width: 1.5;
    stroke-linecap: round;
    stroke-linejoin: round;
    display: inline-block;
    vertical-align: -2px;
    flex: none
}

.vh {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap
}

.header {
    position: fixed;
    inset: 0 0 auto;
    height: var(--header);
    z-index: 100;
    color: var(--pw-sandstone);
    transition: background var(--ease), color var(--ease), border-color var(--ease);
    border-bottom: 1px solid transparent
}

.header.is-light {
    background: var(--pw-sandstone);
    color: var(--pw-teal);
    border-bottom-color: var(--pw-clay)
}

.header .wrap {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%
}

.logo {
    font: 500 28px/1 var(--font-display);
    text-decoration: none;
    letter-spacing: .02em;
    display: inline-flex;
    align-items: center;
    gap: 10px
}

.logo-img {
    height: 32px;
    width: auto;
    display: block;
    flex: none;
    transition: filter var(--ease);
}

/* Invert logo to white when header is on teal (dark) background or in footer */
.header:not(.is-light) .logo-img,
body.menu-open .header .logo-img,
.footer .logo-img {
    filter: invert(1);
}

@media(min-width:1200px) {
    .logo-img {
        height: 38px
    }
}

.nav {
    display: none;
    align-items: center;
    gap: 32px
}

.nav a:not(.btn) {
    font: 500 13px/18px var(--font-body);
    text-transform: uppercase;
    letter-spacing: .14em;
    text-decoration: none;
    padding: 8px 0;
    background: linear-gradient(var(--pw-clay), var(--pw-clay)) left bottom/0 1px no-repeat;
    transition: background-size 400ms ease
}

.nav a:not(.btn):hover,
.nav a[aria-current] {
    background-size: 100% 1px
}

.nav .btn {
    min-height: 44px;
    padding: 0 20px;
    font-size: 12px
}

.header:not(.is-light) .nav .btn {
    background: var(--pw-sandstone);
    color: var(--pw-teal)
}

@media(min-width:960px) {
    .nav {
        display: flex
    }

    .burger {
        display: none !important
    }
}

.burger {
    width: 48px;
    height: 48px;
    background: none;
    border: 0;
    color: inherit;
    cursor: pointer;
    margin-right: -12px
}

.burger span {
    display: block;
    width: 24px;
    height: 1.5px;
    background: currentColor;
    margin: 6px auto;
    transition: transform var(--ease)
}

.menu {
    position: fixed;
    inset: 0;
    background: var(--pw-teal);
    z-index: 99;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 24px;
    padding: 96px var(--gutter) 40px;
    visibility: hidden;
    opacity: 0;
    transition: opacity 300ms ease, visibility 300ms
}

.menu a:not(.btn) {
    font: 500 36px/1.2 var(--font-display);
    color: var(--pw-sandstone);
    text-decoration: none
}

.menu .btn {
    margin-top: auto;
    align-self: stretch;
    width: 100%;
    background: var(--pw-sandstone);
    color: var(--pw-teal);
}

body.menu-open .menu {
    visibility: visible;
    opacity: 1
}

body.menu-open .header {
    color: var(--pw-sandstone);
    background: transparent;
    border-color: transparent
}

body.menu-open {
    overflow: hidden
}

body.menu-open .burger span:first-child {
    transform: translateY(3.75px) rotate(45deg)
}

body.menu-open .burger span:last-child {
    transform: translateY(-3.75px) rotate(-45deg)
}

.hero {
    padding: calc(var(--header) + 48px) 0 64px
}

.hero-grid {
    display: grid;
    gap: 48px;
    align-items: center
}

.hero p.lead {
    margin: 24px 0 32px;
    max-width: 520px
}

.hero .actions {
    display: flex;
    flex-direction: column;
    gap: 20px;
    align-items: flex-start
}

.hero em {
    color: var(--pw-sage-mist)
}

.art {
    border-radius: 16px;
    overflow: hidden;
    background: var(--pw-teal-hover);
    aspect-ratio: 4/3;
    position: relative
}

.art svg {
    width: 100%;
    height: 100%
}

.art img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 900ms ease
}

.art:hover img {
    transform: scale(1.03)
}

@media(min-width:960px) {
    .hero {
        padding: calc(var(--header) + 64px) 0 96px;
        min-height: 100vh;
        display: flex;
        align-items: center
    }

    .hero-grid {
        grid-template-columns: 7fr 5fr;
        gap: 96px;
        width: 100%
    }

    .art {
        aspect-ratio: 4/5
    }
}

.cards {
    display: grid;
    gap: 16px;
    align-items: stretch;
}

@media(min-width:768px) {
    .cards {
        grid-template-columns: repeat(3, 1fr);
        gap: 24px;
        align-items: stretch;
    }
}

@media(min-width:1200px) {
    .cards {
        gap: 32px;
    }
}

.card {
    position: relative;
    background: var(--pw-white);
    border: 1px solid var(--pw-clay);
    border-radius: 16px;
    padding: 32px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
    height: 100%;
    margin-top: 0;
    transition: border-color var(--ease), transform var(--ease), box-shadow var(--ease);
}

@media(min-width:1200px) {
    .card {
        padding: 48px;
    }
}

.card:hover,
.card:focus-within {
    border-color: var(--pw-teal);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(26, 37, 36, .08);
}

.card .num {
    font: 500 56px/1 var(--font-display);
    color: var(--pw-clay);
}

.card .it {
    font: italic 400 22px/30px var(--font-display);
    color: var(--pw-clay-text);
}

.card .link {
    margin-top: auto;
    padding-top: 8px;
}

.card .link::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 16px;
}

.feels {
    display: grid;
    gap: 40px;
    margin-top: var(--s7)
}

.feels>div {
    border-top: 1px solid var(--pw-clay);
    padding-top: 24px
}

.feels h3 {
    font-size: 36px;
    line-height: 1.1;
    margin: 0 0 12px;
    letter-spacing: .01em
}

@media(min-width:768px) {
    .feels {
        grid-template-columns: repeat(4, 1fr);
        gap: 32px
    }

    .feels>div:nth-child(even) {
        padding-top: 72px
    }
}

.steps {
    display: grid
}

.step {
    position: relative;
    padding: 0 0 48px 56px;
    border-left: 1px solid var(--pw-clay);
    margin-left: 12px
}

.step::before {
    content: "";
    position: absolute;
    left: -7px;
    top: 12px;
    width: 13px;
    height: 13px;
    border-radius: 50%;
    background: var(--pw-sandstone);
    border: 1px solid var(--pw-clay)
}

.step .letter {
    font: 500 72px/1 var(--font-display);
    color: var(--pw-teal)
}

.step h3 {
    font: 500 13px/18px var(--font-body);
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--pw-clay-text);
    margin: 12px 0
}

@media(min-width:960px) {
    .steps {
        grid-template-columns: repeat(4, 1fr);
        gap: 32px
    }

    .step {
        padding: 40px 0 0;
        border-left: 0;
        border-top: 1px solid var(--pw-clay);
        margin: 0
    }

    .step::before {
        left: 0;
        top: -7px
    }

    .step .letter {
        font-size: 96px
    }
}

/* PATH Method Section Responsive Refinement */
#method .sec-head {
    margin-bottom: 40px;
}

.method-steps {
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
}

.method-steps .step {
    padding: 24px 0 0;
    border-left: 0;
    border-top: 1px solid rgba(138, 90, 68, 0.55);
    margin: 0;
}

.method-steps .step::before {
    left: 0;
    top: -7px;
    background: var(--pw-sage-mist);
    border-color: var(--pw-clay-text);
}

.method-steps .step .letter {
    font-size: 52px;
    line-height: 1;
}

.method-copy {
    margin-top: 32px;
    max-width: 740px;
    color: var(--pw-ink);
    line-height: 1.65;
}

@media(min-width:640px) {
    .method-steps {
        gap: 24px;
    }

    .method-steps .step {
        padding-top: 32px;
    }

    .method-steps .step .letter {
        font-size: 72px;
    }
}

@media(min-width:768px) {
    #method .sec-head {
        margin-bottom: 56px;
    }

    .method-copy {
        margin-top: 48px;
    }
}

@media(min-width:960px) {
    .method-steps {
        gap: 32px;
    }

    .method-steps .step {
        padding-top: 40px;
    }

    .method-steps .step .letter {
        font-size: 96px;
    }
}

.tiles {
    display: grid;
    gap: 32px 24px
}

@media(min-width:768px) {
    .tiles {
        grid-template-columns: repeat(3, 1fr)
    }
}

.tile {
    border-top: 1px solid var(--pw-clay);
    padding-top: 24px
}

.tile h3 {
    font-size: 28px;
    line-height: 34px;
    margin-bottom: 8px
}

/* Mobile Enhancement: What we bring credential cards */
@media(max-width:767px) {
    #what-we-bring .sec-head {
        margin-bottom: 36px;
    }

    #what-we-bring .sec-head h2 {
        font-size: 32px;
        line-height: 38px;
    }

    .tiles {
        gap: 14px;
        counter-reset: bring-tile;
    }

    .tile {
        counter-increment: bring-tile;
        position: relative;
        display: flex;
        align-items: flex-start;
        gap: 14px;
        background: var(--pw-white);
        border: 1px solid #E5DDD0;
        border-left: 3px solid var(--pw-clay);
        border-radius: 12px;
        padding: 18px;
        box-shadow: 0 4px 16px rgba(26, 37, 36, 0.04);
    }

    .tile::before {
        content: "0" counter(bring-tile);
        font: 500 22px/1.2 var(--font-display);
        color: var(--pw-clay-text);
        flex: none;
        min-width: 26px;
        padding-top: 2px;
    }
/* 
    .tile:last-child {
        background: #EDF3F1;
        border-color: #C8D4CE;
        border-left-color: var(--pw-teal);
    }

    .tile:last-child::before {
        color: var(--pw-teal);
    } */

    .tile h3 {
        font-size: 21px;
        line-height: 27px;
        margin: 0;
        color: var(--pw-teal);
    }
}

.ph {
    color: var(--pw-clay-text);
    font-size: 15px;
    line-height: 22px;
    margin-top: 8px
}

/* ============================================================
   WHERE WE GUIDE — GLOBAL REACH MAP
   ============================================================ */
.where-we-guide {
    --wwg-bg: var(--pw-sandstone);
    --wwg-ink: var(--pw-teal);
    --wwg-body: var(--pw-ink);
    --wwg-muted: #c2c8bd;
    --wwg-accent: #b88770;
    --wwg-line: #bd927e;
    box-sizing: border-box;
    width: 100%;
    padding: 88px var(--gutter) 80px;
    background: var(--wwg-bg);
    color: var(--wwg-body);
    overflow: hidden;
    font-family: var(--font-body);
    text-align: center;
}

.where-we-guide * {
    box-sizing: border-box;
}

.wwg-inner {
    width: min(100%, 1120px);
    margin: 0 auto;
}

.wwg-eyebrow {
    margin: 0 0 16px;
    color: var(--pw-clay-text);
    font-size: 12px;
    font-weight: 500;
    letter-spacing: .16em;
    line-height: 1.2;
    text-transform: uppercase;
}

.wwg-heading {
    max-width: 720px;
    margin: 0 auto;
    color: var(--wwg-ink);
    font-family: var(--font-display);
    font-size: 44px;
    font-weight: 400;
    line-height: 1.12;
    letter-spacing: -0.015em;
}

@media(min-width:1200px) {
    .where-we-guide {
        padding: 112px var(--gutter) 96px;
    }

    .wwg-heading {
        font-size: 48px;
        line-height: 54px;
    }
}

.wwg-subtitle {
    margin: 18px auto 0;
    max-width: 560px;
    font-size: 16px;
    line-height: 1.5;
    color: var(--pw-ink);
}

.wwg-map-wrap {
    width: min(100%, 920px);
    margin: 48px auto 0;
}

.wwg-map {
    display: block;
    width: 100%;
    height: auto;
    overflow: visible;
}

.wwg-map .base-dots {
    fill: var(--wwg-muted);
}

.wwg-map .highlight-dots {
    fill: var(--wwg-accent);
}

.wwg-country-dots {
    fill: var(--wwg-accent);
    transition: fill 250ms ease, opacity 250ms ease;
    cursor: pointer;
}

.where-we-guide.has-selection .wwg-country-dots {
    opacity: 0.35;
}

.where-we-guide.has-selection .wwg-country-dots.is-selected {
    opacity: 1;
    fill: var(--wwg-ink);
}

.wwg-country-label {
    font-family: var(--font-display);
    font-size: 18px;
    font-weight: 500;
    fill: #171b19;
    letter-spacing: -0.01em;
    paint-order: stroke;
    stroke: var(--wwg-bg);
    stroke-width: 5px;
    stroke-linejoin: round;
    transition: fill 250ms ease;
}

.wwg-marker-ring {
    fill: var(--wwg-bg);
    stroke: #9c7966;
    stroke-width: 1.3;
    transition: stroke .2s ease, stroke-width .2s ease, fill .2s ease;
}

.wwg-marker-core {
    fill: #9c7966;
    transition: fill .2s ease;
}

.wwg-marker {
    transition: opacity 250ms ease, transform 200ms ease;
    cursor: pointer;
}

.where-we-guide.has-selection .wwg-marker {
    opacity: 0.42;
}

.where-we-guide.has-selection .wwg-marker.is-selected {
    opacity: 1;
}

.wwg-marker:hover .wwg-marker-ring,
.wwg-marker.is-selected .wwg-marker-ring {
    stroke: var(--wwg-ink);
    stroke-width: 2.2;
    fill: #E7EEEB;
}

.wwg-marker:hover .wwg-marker-core,
.wwg-marker.is-selected .wwg-marker-core {
    fill: var(--wwg-ink);
}

.wwg-marker.is-selected .wwg-country-label {
    fill: var(--wwg-ink);
    font-weight: 600;
}

.wwg-buttons {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    margin: 44px auto 0;
}

.wwg-country-button {
    appearance: none;
    border: 1px solid var(--wwg-line);
    border-radius: 0;
    background: transparent;
    color: var(--pw-ink);
    min-width: 82px;
    height: 43px;
    padding: 0 20px;
    font: 500 13px/1 var(--font-body);
    letter-spacing: .04em;
    cursor: pointer;
    transition: background .2s ease, color .2s ease, border-color .2s ease;
}

.wwg-country-button:hover,
.wwg-country-button:focus-visible {
    background: #eee5d9;
    border-color: var(--pw-clay-text);
    outline: none;
}

.wwg-country-button[aria-pressed="true"] {
    background: var(--wwg-ink);
    border-color: var(--wwg-ink);
    color: var(--wwg-bg);
}

@media(max-width:700px) {
    .where-we-guide {
        min-height: 0;
        padding: 64px 17px 56px;
    }

    .wwg-eyebrow {
        font-size: 11px;
        letter-spacing: .15em;
        margin-bottom: 14px;
    }

    .wwg-heading {
        font-size: clamp(30px, 7.2vw, 38px);
        letter-spacing: -0.015em;
        max-width: 540px;
    }

    .wwg-desktop-break {
        display: none;
    }

    .wwg-subtitle {
        font-size: 14px;
        margin-top: 14px;
    }

    .wwg-map-wrap {
        width: 100%;
        max-width: none;
        margin: 32px auto 0;
    }

    .wwg-country-label {
        font-size: 20px;
    }

    .wwg-buttons {
        gap: 8px;
        margin-top: 28px;
    }

    .wwg-country-button {
        height: 40px;
        min-width: 0;
        padding: 0 14px;
        font-size: 12px;
    }
}

@media(max-width:390px) {
    .wwg-country-button {
        padding: 0 11px;
    }
}

.stories {
    display: grid;
    gap: 48px
}

@media(min-width:960px) {
    .stories {
        grid-template-columns: repeat(3, 1fr)
    }

    .stories figure:nth-child(2) {
        margin-top: 64px
    }
}

.stories figure {
    margin: 0;
    border-top: 1px solid var(--pw-clay);
    padding-top: 24px
}

.stories .mark {
    font: 500 56px/.6 var(--font-display);
    color: var(--pw-clay);
    display: block;
    height: 28px
}

.stories figcaption {
    margin-top: 24px;
    color: var(--pw-sage-mist)
}

.note {
    font-size: 14px;
    line-height: 21px;
    margin-top: 40px
}

.logos {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    margin: 48px 0
}

@media(min-width:768px) {
    .logos {
        grid-template-columns: repeat(4, 1fr)
    }
}

.logo-ph {
    border: 1px dashed var(--pw-clay);
    border-radius: 16px;
    min-height: 80px;
    display: grid;
    place-items: center;
    color: var(--pw-clay-text)
}

.areas {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 32px;
    margin: 0 0 48px;
    list-style: none;
    padding: 0
}

.areas li {
    font: italic 400 24px/32px var(--font-display);
    color: var(--pw-teal)
}

.journey {
    display: grid;
    gap: 32px;
    margin: 48px 0;
    align-items: start;
}

.jstep {
    border-top: 1px solid var(--pw-clay);
    padding-top: 24px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.jstep .n {
    font: 500 40px/1 var(--font-display);
    color: var(--pw-clay);
    display: block;
    margin-bottom: 14px;
}

.jstep h3 {
    font: 500 13px/18px var(--font-body);
    letter-spacing: .14em;
    text-transform: uppercase;
    margin-bottom: 10px;
}

.jstep p {
    max-width: 34ch;
    line-height: 25px;
}

@media(min-width:768px) {
    .journey {
        grid-template-columns: repeat(3, 1fr);
        gap: 48px;
        margin: 56px 0;
    }

    .jstep .n {
        font-size: 56px;
    }
}

.form {
    display: grid;
    gap: 24px;
    max-width: 680px
}

.field > label:not(.contact-pref-card):not(.source-tag):not(.check-card):not(.check-pill):not(.journey-card):not(.option-pill):not(.scale-pill):not(.consent-check-pill),
.field label:not(.contact-pref-card):not(.source-tag):not(.check-card):not(.check-pill):not(.journey-card):not(.option-pill):not(.scale-pill):not(.consent-check-pill) {
    display: block;
    font-size: 15px;
    line-height: 22px;
    margin-bottom: 8px
}

.field input:not([type="radio"]):not([type="checkbox"]),
.field select,
.field textarea {
    width: 100%;
    min-height: 52px;
    background: var(--pw-white);
    border: 1px solid var(--pw-sage-mist);
    border-radius: 8px;
    padding: 12px 16px;
    font: 400 16px/26px var(--font-body);
    color: var(--pw-ink)
}

.field textarea {
    min-height: 140px;
    resize: vertical
}

.field input:focus,
.field select:focus,
.field textarea:focus {
    border: 1.5px solid var(--pw-teal);
    box-shadow: 0 0 0 3px rgba(30, 74, 72, 0.12);
    outline: 0;
}

.field[data-invalid] input,
.field[data-invalid] select {
    border-color: var(--pw-clay-text)
}

.err {
    display: none;
    gap: 8px;
    align-items: center;
    color: var(--pw-clay-text);
    font-size: 15px;
    line-height: 22px;
    margin-top: 8px
}

.field[data-invalid] .err {
    display: flex;
    gap: 8px;
    align-items: center
}

.radios {
    display: flex;
    gap: 24px;
    flex-wrap: wrap;
    border: 0;
    padding: 0;
    margin: 0
}

.radios legend {
    font-size: 15px;
    margin-bottom: 8px;
    padding: 0
}

.radios label {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 48px
}

.radios input {
    accent-color: var(--pw-teal);
    width: 20px;
    height: 20px
}

.status {
    font-size: 16px
}

.status.ok {
    color: var(--pw-teal)
}

.status.bad {
    color: var(--pw-clay-text)
}

.page-hero {
    padding: calc(var(--header) + 64px) 0 var(--section)
}

.page-hero .display {
    max-width: 760px;
    margin-top: 12px
}

.prose p+p {
    margin-top: 24px
}

.prose .big {
    font: 400 28px/1.3 var(--font-display);
    color: var(--pw-teal)
}

.founder {
    display: grid;
    gap: 48px;
    align-items: center
}

.portrait {
    aspect-ratio: 4/5;
    border-radius: 16px;
    background: var(--pw-sandstone);
    display: grid;
    place-items: center;
    color: var(--pw-sage-mist);
    text-align: center;
}

@media(min-width:960px) {
    .founder {
        grid-template-columns: 5fr 7fr;
        gap: 96px
    }
}

.pv {
    display: grid;
    gap: 64px
}

.pv>div {
    border-top: 1px solid var(--pw-clay);
    padding-top: 24px
}

.pv .big {
    font: 500 28px/1.25 var(--font-display);
    color: var(--pw-sandstone);
    margin-top: 16px
}

@media(min-width:768px) {
    .pv .big {
        font-size: 40px
    }
}

@media(min-width:960px) {
    .pv {
        grid-template-columns: 1fr 1fr;
        gap: 96px
    }
}

.commit {
    display: grid;
    gap: 32px
}

.commit>div {
    border-top: 1px solid var(--pw-clay);
    padding-top: 24px
}

.commit h3 {
    font: 500 13px/18px var(--font-body);
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--pw-clay-text);
    margin-bottom: 12px
}

.commit .n {
    font: 500 40px/1 var(--font-display);
    color: var(--pw-clay);
    display: block;
    margin-bottom: 8px
}

@media(min-width:768px) {
    .commit {
        grid-template-columns: repeat(6, 1fr);
        gap: 48px 32px
    }

    .commit>div {
        grid-column: span 2
    }

    .commit>div:nth-child(4) {
        grid-column: 2/span 2
    }
}

.footer {
    background: var(--pw-teal-hover);
    color: var(--pw-sandstone);
    padding: 64px 0 32px;
    border-top: 1px solid var(--pw-clay)
}

.footer .grid {
    display: grid;
    gap: 40px
}

@media(min-width:768px) {
    .footer .grid {
        grid-template-columns: 2fr 1fr 1fr
    }
}

.footer ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 4px
}

.footer li a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 44px;
    text-decoration: none;
    font-size: 16px
}

.footer li a:hover {
    text-decoration: underline;
    text-decoration-color: var(--pw-clay);
    text-underline-offset: 4px
}

.footer .muted {
    color: var(--pw-sage-mist)
}

.footer .legal {
    margin-top: 48px;
    padding-top: 24px;
    border-top: 1px solid rgba(213, 221, 215, .25);
    display: flex;
    flex-wrap: wrap;
    gap: 16px 32px;
    justify-content: space-between
}

.js .reveal {
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 600ms ease, transform 600ms ease;
    transition-delay: var(--d, 0ms)
}

.js .reveal.in {
    opacity: 1;
    transform: none
}

.js .load {
    animation: up 800ms ease both;
    animation-delay: var(--d, 0ms)
}

@keyframes up {
    from {
        opacity: 0;
        transform: translateY(16px)
    }

    to {
        opacity: 1;
        transform: none
    }
}

body.leaving {
    opacity: 0;
    transition: opacity 250ms ease
}

@media(prefers-reduced-motion:reduce) {
    html {
        scroll-behavior: auto
    }

    .js .reveal,
    .js .load {
        opacity: 1;
        transform: none;
        animation: none;
        transition: none
    }

    * {
        transition-duration: .01ms !important
    }
}

/* ==========================================================================
   Custom Onboarding Form Experience — Multi-Step & Stepper Design
   ========================================================================== */

.onboarding-page-wrap {
    padding: calc(var(--header) + 40px) 0 var(--section);
    position: relative;
    background: radial-gradient(circle at 50% 0%, rgba(213, 221, 215, 0.45) 0%, transparent 60%);
}

.onboarding-intro {
    text-align: center;
    max-width: 720px;
    margin: 0 auto 40px;
}

.onboarding-intro .display {
    margin: 12px 0 16px;
    font-size: 32px;
    line-height: 44px;
}

@media(min-width: 768px) {
    .onboarding-intro .display {
        font-size: 52px;
        line-height: 58px;
    }
}

/* Stepper Navigation */
.stepper-nav {
    max-width: 780px;
    margin: 0 auto 36px;
    padding: 0 16px;
}

.stepper-track {
    position: relative;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.stepper-line-track {
    position: absolute;
    top: 18px;
    left: 18px;
    right: 18px;
    height: 2px;
    background: var(--pw-sage-mist);
    z-index: 1;
    overflow: hidden;
    border-radius: 999px;
}

.stepper-progress-fill {
    height: 100%;
    background: var(--pw-teal);
    z-index: 2;
    transition: width 400ms cubic-bezier(0.16, 1, 0.3, 1);
    width: 0%;
    border-radius: 999px;
}

.stepper-nodes {
    display: flex;
    width: 100%;
    justify-content: space-between;
    position: relative;
    z-index: 3;
}

.step-node {
    position: relative;
    z-index: 3;
    background: none;
    border: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: default;
    color: var(--pw-clay-text);
    text-decoration: none;
    font-family: var(--font-body);
    transition: all var(--ease);
}

.step-node:focus {
    outline: none;
}

.step-node:focus-visible .step-node-disc {
    outline: 2px solid var(--pw-teal);
    outline-offset: 3px;
}

.step-node.is-completed {
    cursor: pointer;
}

.step-node-disc {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--pw-sandstone);
    border: 2px solid var(--pw-sage-mist);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 500;
    color: var(--pw-clay-text);
    transition: all var(--ease);
    margin-bottom: 8px;
}

.step-node.active .step-node-disc {
    background: var(--pw-teal);
    border-color: var(--pw-teal);
    color: var(--pw-sandstone);
    box-shadow: 0 0 0 4px rgba(30, 74, 72, 0.15);
    transform: scale(1.08);
}

.step-node.is-completed .step-node-disc {
    background: var(--pw-teal);
    border-color: var(--pw-teal);
    color: var(--pw-sandstone);
}

.step-node .step-check {
    display: none;
    width: 16px;
    height: 16px;
    stroke: currentColor;
    stroke-width: 2.5;
    fill: none;
}

.step-node.is-completed .step-num {
    display: none;
}

.step-node.is-completed .step-check {
    display: block;
}

.step-node-label {
    font-size: 12px;
    line-height: 16px;
    font-weight: 500;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--pw-clay-text);
    transition: color var(--ease);
    display: none;
}

@media(min-width: 600px) {
    .step-node-label {
        display: block;
    }
}

.step-node.active .step-node-label {
    color: var(--pw-teal);
    font-weight: 600;
}

.step-node.is-completed .step-node-label {
    color: var(--pw-teal);
}

/* Mobile Mini Progress Indicator */
.mobile-step-summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: .12em;
    font-weight: 500;
    margin-bottom: 12px;
    padding: 0 4px;
}

@media(min-width: 600px) {
    .mobile-step-summary {
        display: none;
    }
}

.mobile-step-summary .step-indicator-text {
    color: var(--pw-clay-text);
}

.mobile-step-summary .step-name-text {
    color: var(--pw-teal);
}

/* The Main Card */
.onboarding-card {
    background: var(--pw-white);
    border: 1px solid rgba(185, 138, 114, 0.45);
    border-radius: 20px;
    padding: 28px 20px;
    box-shadow: 0 12px 40px rgba(30, 74, 72, 0.06);
    max-width: 820px;
    margin: 0 auto;
    position: relative;
    transition: box-shadow var(--ease);
}

@media(min-width: 768px) {
    .onboarding-card {
        padding: 48px;
        border-radius: 24px;
    }
}

/* Step Animations */
.form-step {
    display: none;
}

.form-step.active {
    display: block;
    animation: stepSlideIn 320ms cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes stepSlideIn {
    from {
        opacity: 0;
        transform: translateY(12px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Step Header Elements */
.step-banner {
    margin-bottom: 32px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--pw-sage-mist);
}

.step-badge {
    display: inline-block;
    font-size: 11px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: .16em;
    color: var(--pw-clay-text);
    background: rgba(185, 138, 114, 0.12);
    padding: 4px 10px;
    border-radius: 999px;
    margin-bottom: 12px;
}

.step-heading {
    font-family: var(--font-display);
    font-size: 32px;
    line-height: 38px;
    color: var(--pw-teal);
    font-weight: 500;
    margin: 0 0 8px;
}

@media(min-width: 768px) {
    .step-heading {
        font-size: 38px;
        line-height: 44px;
    }
}

.step-lead {
    font-size: 15px;
    line-height: 24px;
    color: #4A5B5A;
    margin: 0;
}

/* Field Grid & Inputs */
.field-row {
    display: grid;
    gap: 20px;
    margin-bottom: 20px;
}

@media(min-width: 640px) {
    .field-row.cols-2 {
        grid-template-columns: 1fr 1fr;
    }
}

.field {
    margin-bottom: 20px;
    position: relative;
}

.field:last-child {
    margin-bottom: 0;
}

.field > label:not(.contact-pref-card):not(.source-tag):not(.check-card):not(.check-pill):not(.journey-card):not(.option-pill):not(.scale-pill):not(.consent-check-pill),
.field label:not(.contact-pref-card):not(.source-tag):not(.check-card):not(.check-pill):not(.journey-card):not(.option-pill):not(.scale-pill):not(.consent-check-pill) {
    display: block;
    font-size: 14px;
    font-weight: 500;
    line-height: 20px;
    margin-bottom: 8px;
    color: var(--pw-ink);
}

.field label .req {
    color: var(--pw-clay-text);
    margin-left: 2px;
}

.field input:not([type="radio"]):not([type="checkbox"]),
.field select,
.field textarea {
    width: 100%;
    min-height: 52px;
    background: var(--pw-white);
    border: 1px solid var(--pw-sage-mist);
    border-radius: 10px;
    padding: 13px 16px;
    font: 400 16px/26px var(--font-body);
    color: var(--pw-ink);
    transition: border-color var(--ease), box-shadow var(--ease);
}

.field input::placeholder,
.field textarea::placeholder {
    color: #9AA7A5;
}

.field input:not([type="radio"]):not([type="checkbox"]):focus,
.field select:focus,
.field textarea:focus {
    border: 1.5px solid var(--pw-teal);
    box-shadow: 0 0 0 3px rgba(30, 74, 72, 0.12);
    outline: 0;
}

.field[data-invalid] input,
.field[data-invalid] select,
.field[data-invalid] textarea {
    border-color: #B24338;
}

.field[data-invalid] .err {
    display: flex;
    gap: 8px;
    align-items: center;
    color: #B24338;
    font-size: 13px;
    line-height: 18px;
    margin-top: 6px;
}

.field-helper {
    font-size: 12px;
    line-height: 16px;
    color: #6C7A79;
    margin-top: 6px;
}

/* STEP 2: Option Cards (Myself vs My Child) */
.journey-cards-grid {
    display: grid;
    gap: 20px;
    margin: 28px 0 16px;
}

@media(min-width: 600px) {
    .journey-cards-grid {
        grid-template-columns: 1fr 1fr;
    }
}

.journey-card {
    border: 1.5px solid var(--pw-sage-mist);
    border-radius: 16px;
    background: var(--pw-white);
    padding: 28px 24px;
    cursor: pointer;
    position: relative;
    transition: all var(--ease);
    display: flex;
    flex-direction: column;
}

.journey-card input[type="radio"] {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.journey-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 16px;
}

.journey-icon-circle {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: rgba(30, 74, 72, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--pw-teal);
    transition: all var(--ease);
}

.journey-icon-circle svg {
    width: 24px;
    height: 24px;
    stroke: currentColor;
    stroke-width: 1.75;
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.journey-radio-indicator {
    width: 22px;
    height: 22px;
    min-width: 22px;
    min-height: 22px;
    max-width: 22px;
    max-height: 22px;
    aspect-ratio: 1 / 1;
    border-radius: 50%;
    border: 2px solid var(--pw-sage-mist);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all var(--ease);
    box-sizing: border-box;
}

.journey-radio-indicator::after {
    content: "";
    width: 10px;
    height: 10px;
    min-width: 10px;
    min-height: 10px;
    max-width: 10px;
    max-height: 10px;
    aspect-ratio: 1 / 1;
    border-radius: 50%;
    background: var(--pw-teal);
    opacity: 0;
    transform: scale(0.5);
    transition: all var(--ease);
    box-sizing: border-box;
}

.journey-card:hover {
    border-color: var(--pw-clay);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(30, 74, 72, 0.08);
}

.journey-card.is-checked,
.journey-card:has(input:checked) {
    border-color: var(--pw-teal);
    background: #FAF7F2;
    box-shadow: 0 0 0 1px var(--pw-teal), 0 8px 28px rgba(30, 74, 72, 0.1);
}

.journey-card.is-checked .journey-icon-circle,
.journey-card:has(input:checked) .journey-icon-circle {
    background: var(--pw-teal);
    color: var(--pw-sandstone);
}

.journey-card.is-checked .journey-radio-indicator,
.journey-card:has(input:checked) .journey-radio-indicator {
    border-color: var(--pw-teal);
}

.journey-card.is-checked .journey-radio-indicator::after,
.journey-card:has(input:checked) .journey-radio-indicator::after {
    opacity: 1;
    transform: scale(1);
}

.journey-card-tag {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .12em;
    font-weight: 500;
    color: var(--pw-clay-text);
    margin-bottom: 6px;
    display: block;
}

.journey-card-title {
    font-family: var(--font-display);
    font-size: 26px;
    line-height: 32px;
    color: var(--pw-teal);
    font-weight: 500;
    margin-bottom: 8px;
    display: block;
}

.journey-card-desc {
    font-size: 14px;
    line-height: 22px;
    color: #4A5B5A;
    margin: 0;
}

/* STEP 3: Question Blocks & Custom Checkbox Cards */
.question-group {
    margin-bottom: 32px;
}

.question-group:last-child {
    margin-bottom: 0;
}

.question-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 14px;
    flex-wrap: wrap;
    gap: 6px;
}

.question-title {
    font-size: 16px;
    font-weight: 500;
    color: var(--pw-ink);
    line-height: 24px;
    margin: 0;
}

.question-subtitle {
    font-size: 13px;
    color: #6C7A79;
}

.check-cards-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.check-card {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    background: var(--pw-white);
    border: 1px solid var(--pw-sage-mist);
    border-radius: 12px;
    padding: 14px 18px;
    cursor: pointer;
    transition: all var(--ease);
    font-size: 15px;
    line-height: 22px;
    color: var(--pw-ink);
    user-select: none;
    position: relative;
}

.check-card input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.check-card-box {
    width: 22px;
    height: 22px;
    border-radius: 6px;
    border: 1.5px solid var(--pw-sage-mist);
    background: var(--pw-white);
    display: flex;
    align-items: center;
    justify-content: center;
    flex: none;
    margin-top: 1px;
    transition: all var(--ease);
}

.check-card-box svg {
    width: 14px;
    height: 14px;
    stroke: var(--pw-sandstone);
    stroke-width: 2.5;
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
    opacity: 0;
    transform: scale(0.6);
    transition: all var(--ease);
}

.check-card:hover {
    border-color: var(--pw-clay);
    background: #FCFAF7;
}

.check-card.is-checked,
.check-card:has(input:checked) {
    border-color: var(--pw-teal);
    background: rgba(30, 74, 72, 0.05);
    color: var(--pw-teal);
    font-weight: 500;
}

.check-card.is-checked .check-card-box,
.check-card:has(input:checked) .check-card-box {
    background: var(--pw-teal);
    border-color: var(--pw-teal);
}

.check-card.is-checked .check-card-box svg,
.check-card:has(input:checked) .check-card-box svg {
    opacity: 1;
    transform: scale(1);
}

/* Follow-up Cards */
.sub-panel-card {
    background: #FAF7F2;
    border: 1px solid var(--pw-clay);
    border-radius: 14px;
    padding: 24px;
    margin-top: 24px;
    animation: stepSlideIn 280ms ease;
}

.sub-panel-eyebrow {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .14em;
    font-weight: 500;
    color: var(--pw-clay-text);
    display: block;
    margin-bottom: 6px;
}

.sub-panel-title {
    font-size: 16px;
    font-weight: 500;
    color: var(--pw-ink);
    margin: 0 0 16px;
    line-height: 24px;
}

/* STEP 4: Reflection Box */
.reflection-prompt-box {
    display: flex;
    gap: 16px;
    padding: 18px 20px;
    background: rgba(30, 74, 72, 0.04);
    border-left: 3px solid var(--pw-teal);
    border-radius: 0 12px 12px 0;
    margin-bottom: 24px;
}

.reflection-prompt-box svg {
    width: 22px;
    height: 22px;
    stroke: var(--pw-teal);
    flex: none;
    margin-top: 2px;
}

.reflection-prompt-text {
    font-size: 14px;
    line-height: 22px;
    color: #384A49;
    font-style: italic;
    margin: 0;
}

/* STEP 5: Source Tag Chips & Contact Preferences */
.tag-chips-wrap {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 10px;
}

.source-tag {
    display: inline-flex;
    align-items: center;
    padding: 10px 16px;
    background: var(--pw-white);
    border: 1px solid var(--pw-sage-mist);
    border-radius: 999px;
    font-size: 14px;
    color: var(--pw-ink);
    cursor: pointer;
    transition: all var(--ease);
    user-select: none;
}

.source-tag input[type="radio"] {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.source-tag:hover {
    border-color: var(--pw-clay);
    background: #FCFAF7;
}

.source-tag.is-checked,
.source-tag:has(input:checked) {
    background: var(--pw-teal);
    border-color: var(--pw-teal);
    color: var(--pw-sandstone);
    font-weight: 500;
}

.contact-pref-row {
    display: grid;
    gap: 16px;
    margin-top: 12px;
}

@media(min-width: 600px) {
    .contact-pref-row {
        grid-template-columns: 1fr 1fr;
    }
}

.field .contact-pref-card,
.contact-pref-card {
    display: flex !important;
    align-items: flex-start;
    gap: 14px;
    padding: 16px 20px;
    border: 1.5px solid var(--pw-sage-mist);
    border-radius: 12px;
    background: var(--pw-white);
    cursor: pointer;
    transition: all var(--ease);
    margin-bottom: 0 !important;
    position: relative;
    user-select: none;
    box-sizing: border-box;
}

/* Visually hide native radio, keeping accessible for screen readers & form submission */
.contact-pref-card input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
    min-height: 0 !important;
    max-height: 1px !important;
    min-width: 0 !important;
    max-width: 1px !important;
    padding: 0 !important;
    margin: 0 !important;
    border: 0 !important;
    outline: 0 !important;
    pointer-events: none;
}

/* Custom 100% circular radio indicator that can NEVER stretch into an oval */
.contact-pref-radio {
    width: 20px;
    height: 20px;
    min-width: 20px;
    min-height: 20px;
    max-width: 20px;
    max-height: 20px;
    aspect-ratio: 1 / 1;
    border-radius: 50%;
    border: 2px solid var(--pw-sage-mist);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    background: var(--pw-white);
    margin-top: 2px;
    transition: all var(--ease);
    box-sizing: border-box;
}

.contact-pref-radio::after {
    content: "";
    width: 10px;
    height: 10px;
    min-width: 10px;
    min-height: 10px;
    max-width: 10px;
    max-height: 10px;
    aspect-ratio: 1 / 1;
    border-radius: 50%;
    background: var(--pw-teal);
    opacity: 0;
    transform: scale(0.5);
    transition: all var(--ease);
    box-sizing: border-box;
}

.contact-pref-card:hover {
    border-color: var(--pw-clay);
}

.contact-pref-card:hover .contact-pref-radio {
    border-color: var(--pw-clay);
}

.contact-pref-card.is-checked,
.contact-pref-card:has(input:checked) {
    border-color: var(--pw-teal);
    background: #FAF7F2;
    box-shadow: 0 0 0 1px var(--pw-teal);
}

.contact-pref-card.is-checked .contact-pref-card-title,
.contact-pref-card:has(input:checked) .contact-pref-card-title {
    color: var(--pw-teal);
}

.contact-pref-card.is-checked .contact-pref-radio,
.contact-pref-card:has(input:checked) .contact-pref-radio {
    border-color: var(--pw-teal);
}

.contact-pref-card.is-checked .contact-pref-radio::after,
.contact-pref-card:has(input:checked) .contact-pref-radio::after {
    opacity: 1;
    transform: scale(1);
}

.contact-pref-card input[type="radio"]:focus-visible ~ .contact-pref-radio {
    outline: 2px solid var(--pw-teal);
    outline-offset: 2px;
}

.contact-pref-card-title {
    font-weight: 500;
    font-size: 15px;
    color: var(--pw-ink);
}

/* Universal radio safeguarding rule: guarantees perfect roundness across all browsers */
input[type="radio"] {
    box-sizing: border-box;
    aspect-ratio: 1 / 1;
    border-radius: 50%;
    flex-shrink: 0;
}

/* Privacy Banner */
.privacy-banner {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    padding: 16px 20px;
    background: rgba(30, 74, 72, 0.05);
    border-radius: 12px;
    margin-top: 24px;
    font-size: 13px;
    line-height: 20px;
    color: var(--pw-ink);
}

.privacy-banner svg {
    width: 18px;
    height: 18px;
    stroke: var(--pw-teal);
    flex: none;
    margin-top: 2px;
}

/* General Standalone Validation Error */
.general-err {
    display: none;
    color: #B24338;
    font-size: 14px;
    line-height: 20px;
    margin-top: 12px;
    align-items: center;
    gap: 8px;
}

.general-err.active {
    display: flex;
}

/* Hidden Attribute Enforcement */
[hidden],
.form-step[hidden],
.journey-branch[hidden],
.sub-panel-card[hidden],
#otherSourceWrap[hidden],
.form-success-card[hidden] {
    display: none !important;
}

/* iOS Date Input Normalization */
.field input[type="date"] {
    appearance: none;
    -webkit-appearance: none;
    font-family: inherit;
    color: var(--pw-ink);
}

/* Bottom Navigation Actions */
.step-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 36px;
    padding-top: 24px;
    border-top: 1px solid var(--pw-sage-mist);
    gap: 16px;
}

@media(max-width: 520px) {
    .step-actions {
        flex-direction: column-reverse;
        gap: 12px;
    }

    .btn-arrow,
    .btn-ghost-arrow {
        width: 100%;
        text-align: center;
    }
}

.btn-ghost-arrow,
.btn-prev {
    background: transparent;
    border: 1px solid var(--pw-clay);
    color: var(--pw-teal);
    padding: 0 24px;
    min-height: 48px;
    border-radius: 999px;
    font: 500 13px/1 var(--font-body);
    text-transform: uppercase;
    letter-spacing: .12em;
    cursor: pointer;
    transition: all var(--ease);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    text-decoration: none;
}

.btn-ghost-arrow:hover {
    border-color: var(--pw-teal);
    color: var(--pw-teal-hover);
    background: rgba(30, 74, 72, 0.04);
}

.btn-arrow,
.btn-next {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 52px;
    padding: 0 32px;
    border-radius: 999px;
    border: 0;
    cursor: pointer;
    font: 500 14px/1 var(--font-body);
    text-transform: uppercase;
    letter-spacing: .14em;
    text-decoration: none;
    background: var(--pw-teal);
    color: var(--pw-sandstone);
    transition: all var(--ease);
}

.btn-arrow:hover {
    background: var(--pw-teal-hover);
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(30, 74, 72, 0.2);
}

.btn-arrow[disabled] {
    opacity: .5;
    pointer-events: none;
}

/* Status Notifications */
.status {
    font-size: 15px;
    line-height: 24px;
    margin-top: 20px;
    border-radius: 10px;
    display: none;
}

.status.ok {
    display: block;
    background: rgba(30, 74, 72, 0.08);
    border: 1px solid var(--pw-teal);
    color: var(--pw-teal);
    padding: 16px 20px;
}

.status.bad {
    display: block;
    background: #FDF3F2;
    border: 1px solid #E4A29B;
    color: #932D23;
    padding: 16px 20px;
}

/* Success Card */
.form-success-card {
    text-align: center;
    padding: 48px 24px;
    background: var(--pw-white);
    border-radius: 20px;
    animation: stepSlideIn 400ms ease;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.success-icon-wrap {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: rgba(30, 74, 72, 0.1);
    color: var(--pw-teal);
    display: grid;
    place-items: center;
    margin-bottom: 20px;
}

.success-icon-wrap svg {
    width: 32px;
    height: 32px;
    stroke: var(--pw-teal);
    stroke-width: 2.25;
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* ============================================================
   AEO FAQ SECTION (Questions & Clarity)
   ============================================================ */
.faq-list {
    max-width: 820px;
    border-top: 1px solid var(--pw-clay);
}

.faq-item {
    border-bottom: 1px solid var(--pw-clay);
}

.faq-q {
    list-style: none;
    cursor: pointer;
    padding: 24px 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    font: 500 22px/30px var(--font-display);
    color: var(--pw-teal);
    transition: color var(--ease);
}

.faq-q::-webkit-details-marker {
    display: none;
}

.faq-q:hover,
.faq-q:focus-visible {
    color: var(--pw-clay-text);
    outline: none;
}

.faq-icon {
    flex: none;
    width: 24px;
    height: 24px;
    position: relative;
    color: var(--pw-clay-text);
}

.faq-icon::before,
.faq-icon::after {
    content: "";
    position: absolute;
    left: 50%;
    top: 50%;
    background: currentColor;
    transform: translate(-50%, -50%);
    transition: transform 250ms ease, opacity 250ms ease;
}

.faq-icon::before {
    width: 14px;
    height: 1.5px;
}

.faq-icon::after {
    width: 1.5px;
    height: 14px;
}

.faq-item[open] .faq-icon::after {
    transform: translate(-50%, -50%) rotate(90deg);
    opacity: 0;
}

.faq-a {
    padding: 0 36px 24px 0;
    color: var(--pw-ink);
    font-size: 16px;
    line-height: 26px;
}

.faq-a p {
    margin: 0;
}

@media(min-width:768px) {
    .faq-q {
        font-size: 26px;
        line-height: 34px;
        padding: 28px 0;
    }

    .faq-a {
        font-size: 17px;
        line-height: 28px;
        padding: 0 56px 28px 0;
    }
}

/* ==========================================================================
   TEENAGER (AGES 14–17) & AGE-DETECTION ONBOARDING STYLES
   ========================================================================== */

/* Inline Age Detected Callout (Step 1) */
.age-detected-badge {
    margin-top: 14px;
    padding: 12px 16px;
    background: #FAF7F2;
    border: 1px solid var(--pw-clay);
    border-radius: 10px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 13px;
    line-height: 20px;
    color: var(--pw-teal);
    animation: stepSlideIn 240ms ease;
}

.age-detected-badge .badge-icon {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: rgba(196, 139, 113, 0.2);
    color: var(--pw-clay);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.age-detected-badge p {
    margin: 0;
    font-weight: 500;
}

/* Under 14 Notice */
.under14-box {
    margin-top: 20px;
    padding: 22px 24px;
    background: #FDF5F3;
    border: 1.5px solid #E6B5AC;
    border-radius: 14px;
    display: flex;
    gap: 16px;
    align-items: flex-start;
    animation: stepSlideIn 260ms ease;
}

.under14-box .under14-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #F5D3CD;
    color: #B24338;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.under14-box h4 {
    font-family: var(--font-body);
    font-size: 16px;
    font-weight: 600;
    color: #7D261E;
    margin: 0 0 6px;
    line-height: 22px;
}

.under14-box p {
    font-size: 14px;
    line-height: 22px;
    color: #5A1E18;
    margin: 0 0 14px;
}

/* Parent / Guardian Consent Wrapper (Ages 14–17) */
.parent-consent-wrapper {
    margin-top: 24px;
    padding: 24px;
    background: rgba(30, 74, 72, 0.035);
    border: 1.5px solid var(--pw-sage-mist);
    border-radius: 16px;
    animation: stepSlideIn 280ms ease;
}

.parent-consent-notice {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 14px 18px;
    background: var(--pw-white);
    border-left: 3px solid var(--pw-clay);
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(30, 74, 72, 0.04);
    margin-bottom: 22px;
}

.parent-consent-notice .notice-icon {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(196, 139, 113, 0.15);
    color: var(--pw-clay);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin-top: 1px;
}

.parent-consent-notice p {
    font-size: 14px;
    line-height: 22px;
    color: var(--pw-ink);
    margin: 0;
    font-weight: 500;
}

/* Grids for Relationship, Grade & Board Selectors */
.relationship-options-grid,
.grade-options-grid,
.board-options-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-top: 6px;
}

@media(min-width: 600px) {
    .relationship-options-grid {
        grid-template-columns: repeat(4, 1fr);
    }
    .grade-options-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .board-options-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.option-pill {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px 14px;
    background: var(--pw-white);
    border: 1.5px solid var(--pw-sage-mist);
    border-radius: 10px;
    font-size: 14px;
    font-weight: 500;
    color: var(--pw-ink);
    cursor: pointer;
    text-align: center;
    transition: all var(--ease);
    user-select: none;
    position: relative;
    box-sizing: border-box;
}

.option-pill input[type="radio"],
.option-pill input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
    pointer-events: none;
}

.option-pill:hover {
    border-color: var(--pw-clay);
}

.option-pill.is-checked,
.option-pill:has(input:checked) {
    border-color: var(--pw-teal);
    background: #FAF7F2;
    color: var(--pw-teal);
    box-shadow: 0 0 0 1px var(--pw-teal);
}

/* Consent Checkbox Pill */
.consent-check-field {
    margin-top: 18px;
    margin-bottom: 0;
}

.consent-check-pill {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 14px 18px;
    background: var(--pw-white);
    border: 1.5px solid var(--pw-sage-mist);
    border-radius: 12px;
    cursor: pointer;
    transition: all var(--ease);
    user-select: none;
}

.consent-check-pill input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
    pointer-events: none;
}

.consent-check-pill .check-card-box {
    width: 22px;
    height: 22px;
    min-width: 22px;
    min-height: 22px;
    border: 2px solid var(--pw-sage-mist);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin-top: 1px;
    transition: all var(--ease);
}

.consent-check-pill .check-card-box svg {
    width: 13px;
    height: 13px;
    stroke: var(--pw-sandstone);
    stroke-width: 2.5;
    fill: none;
    opacity: 0;
    transform: scale(0.6);
    transition: all var(--ease);
}

.consent-check-pill.is-checked,
.consent-check-pill:has(input:checked) {
    border-color: var(--pw-teal);
    background: #FAF7F2;
}

.consent-check-pill.is-checked .check-card-box,
.consent-check-pill:has(input:checked) .check-card-box {
    background: var(--pw-teal);
    border-color: var(--pw-teal);
}

.consent-check-pill.is-checked .check-card-box svg,
.consent-check-pill:has(input:checked) .check-card-box svg {
    opacity: 1;
    transform: scale(1);
}

.consent-label-text {
    font-size: 14px;
    line-height: 22px;
    color: var(--pw-ink);
}

/* 1 to 5 Confidence Rating Scale */
.teen-confidence-scale {
    margin-top: 12px;
}

.teen-scale-track {
    display: flex;
    gap: 10px;
    justify-content: space-between;
}

.scale-pill {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 50px;
    background: var(--pw-white);
    border: 1.5px solid var(--pw-sage-mist);
    border-radius: 10px;
    font-size: 17px;
    font-weight: 600;
    color: var(--pw-ink);
    cursor: pointer;
    transition: all var(--ease);
    user-select: none;
    position: relative;
    box-sizing: border-box;
}

.scale-pill input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
    pointer-events: none;
}

.scale-pill:hover {
    border-color: var(--pw-clay);
    transform: translateY(-1px);
}

.scale-pill.is-checked,
.scale-pill:has(input:checked) {
    border-color: var(--pw-teal);
    background: var(--pw-teal);
    color: var(--pw-sandstone);
    box-shadow: 0 4px 14px rgba(30, 74, 72, 0.22);
}

.scale-labels {
    display: flex;
    justify-content: space-between;
    margin-top: 8px;
    font-size: 13px;
    color: #5F7371;
    font-weight: 500;
}

/* Sub-section Dividers in Teen Conditional Sections */
.teen-sub-card {
    background: var(--pw-white);
    border: 1.5px solid var(--pw-sage-mist);
    border-radius: 16px;
    padding: 24px 20px;
    margin-bottom: 24px;
    transition: all var(--ease);
}

@media(min-width: 640px) {
    .teen-sub-card {
        padding: 30px;
    }
}

.teen-sub-card:last-child {
    margin-bottom: 0;
}

.teen-sub-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--pw-sage-mist);
}

.teen-sub-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: rgba(30, 74, 72, 0.08);
    color: var(--pw-teal);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.teen-sub-icon svg {
    width: 20px;
    height: 20px;
    stroke: currentColor;
    stroke-width: 1.75;
    fill: none;
}

.teen-sub-title {
    font-family: var(--font-display);
    font-size: 24px;
    line-height: 28px;
    color: var(--pw-teal);
    font-weight: 500;
    margin: 0;
}

/* Crisis Support Alert & Helpline Panel */
.teen-crisis-card {
    margin-top: 18px;
    padding: 24px;
    background: #FAF7F2;
    border: 2px solid var(--pw-clay);
    border-radius: 16px;
    animation: stepSlideIn 260ms ease;
    box-shadow: 0 8px 24px rgba(196, 139, 113, 0.12);
}

.teen-crisis-header {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    margin-bottom: 14px;
}

.crisis-icon-badge {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(196, 139, 113, 0.2);
    color: #9E5637;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin-top: 2px;
}

.teen-crisis-card h3 {
    font-family: var(--font-display);
    font-size: 24px;
    line-height: 30px;
    color: #7D381E;
    margin: 0 0 6px;
    font-weight: 500;
}

.teen-crisis-card p {
    font-size: 14px;
    line-height: 22px;
    color: #4A5B5A;
    margin: 0 0 12px;
}

.crisis-helpline-box {
    margin-top: 16px;
    padding: 20px 24px;
    background: var(--pw-white);
    border: 1.5px solid rgba(196, 139, 113, 0.5);
    border-radius: 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
}

.crisis-helpline-tag {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .12em;
    color: var(--pw-clay);
    margin-bottom: 4px;
}

.crisis-helpline-number {
    font-family: var(--font-display);
    font-size: 30px;
    line-height: 1;
    color: var(--pw-teal);
    font-weight: 600;
    letter-spacing: .04em;
}

.crisis-helpline-desc {
    font-size: 13px;
    color: #5F7371;
    margin-top: 4px;
}

/* Privacy Text Card */
.teen-privacy-card {
    padding: 20px 24px;
    background: rgba(30, 74, 72, 0.04);
    border: 1px solid var(--pw-sage-mist);
    border-radius: 14px;
    margin: 22px 0;
}

.teen-privacy-title {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--pw-teal);
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: .12em;
}

.teen-privacy-card p {
    font-size: 14px;
    line-height: 22px;
    color: var(--pw-ink);
    margin: 0;
}


/* ==========================================================================
   ONBOARDING FORM — DESIGN FIXES (checkboxes, rating scale, pills, errors)
   ========================================================================== */

/* --- Multi-select checkbox pills (Teen Step 4) — previously unstyled --- */
.checkbox-pills-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
    margin-top: 4px;
}

@media(min-width: 640px) {
    .checkbox-pills-grid {
        grid-template-columns: 1fr 1fr;
    }
}

.check-pill {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 14px 16px;
    min-height: 52px;
    background: var(--pw-white);
    border: 1.5px solid var(--pw-sage-mist);
    border-radius: 12px;
    font-size: 14px;
    line-height: 21px;
    font-weight: 400;
    color: var(--pw-ink);
    cursor: pointer;
    user-select: none;
    position: relative;
    box-sizing: border-box;
    margin: 0;
    transition: border-color var(--ease), background var(--ease), box-shadow var(--ease), color var(--ease);
}

.check-pill input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
    margin: 0;
    pointer-events: none;
}

.check-pill .check-card-box {
    width: 20px;
    height: 20px;
    min-width: 20px;
    min-height: 20px;
    aspect-ratio: 1 / 1;
    border: 1.5px solid #B9C4C1;
    border-radius: 6px;
    background: var(--pw-white);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin-top: 1px;
    box-sizing: border-box;
    transition: all var(--ease);
}

.check-pill .check-card-box svg {
    width: 12px;
    height: 12px;
}

.check-pill:hover {
    border-color: var(--pw-clay);
    background: #FCFAF7;
}

.check-pill.is-checked,
.check-pill:has(input:checked) {
    border-color: var(--pw-teal);
    background: rgba(30, 74, 72, 0.05);
    color: var(--pw-teal);
    font-weight: 500;
}

.check-pill.is-checked .check-card-box,
.check-pill:has(input:checked) .check-card-box {
    background: var(--pw-teal);
    border-color: var(--pw-teal);
}

.check-pill.is-checked .check-card-box svg,
.check-pill:has(input:checked) .check-card-box svg {
    opacity: 1;
    transform: scale(1);
}

.check-pill:has(input:focus-visible),
.check-card:has(input:focus-visible),
.option-pill:has(input:focus-visible),
.scale-pill:has(input:focus-visible),
.consent-check-pill:has(input:focus-visible) {
    outline: 2px solid var(--pw-teal);
    outline-offset: 2px;
}

/* --- Unified checkbox box (check-card / consent) — crisp square, never distorted --- */
.check-card .check-card-box,
.consent-check-pill .check-card-box {
    width: 20px;
    height: 20px;
    min-width: 20px;
    min-height: 20px;
    aspect-ratio: 1 / 1;
    border: 1.5px solid #B9C4C1;
    border-radius: 6px;
    background: var(--pw-white);
    box-sizing: border-box;
    flex-shrink: 0;
}

.check-card-title {
    display: block;
    font-size: 15px;
    line-height: 22px;
    font-weight: 500;
    color: var(--pw-teal);
}

.teen-help-list {
    margin-top: 4px;
}

.teen-help-list .check-card {
    padding: 16px 18px;
    border-width: 1.5px;
}

/* --- Consent checkbox pill: keep box + text aligned --- */
.consent-check-pill {
    position: relative;
    margin: 0;
    font-weight: 400;
}

.consent-check-pill .consent-label-text {
    flex: 1;
}

/* --- Single-select option pills: consistent height & wrapping --- */
.option-pill {
    min-height: 48px;
    margin: 0;
    line-height: 20px;
}

.option-pill > span {
    display: block;
}

/* --- 1–5 Rating scale: centred, equal, responsive --- */
.teen-scale-track {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 8px;
}

.scale-pill {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 52px;
    margin: 0;
    padding: 0;
    line-height: 1;
    font-family: var(--font-body);
    font-variant-numeric: tabular-nums;
}

.scale-pill > span {
    display: block;
    line-height: 1;
}

.scale-pill:hover {
    transform: none;
    background: #FCFAF7;
}

.scale-pill.is-checked:hover,
.scale-pill:has(input:checked):hover {
    background: var(--pw-teal);
}

.scale-labels {
    gap: 12px;
    font-size: 12px;
    line-height: 16px;
}

.scale-labels span:last-child {
    text-align: right;
}

@media(min-width: 640px) {
    .teen-scale-track {
        gap: 12px;
    }

    .scale-pill {
        min-height: 56px;
        font-size: 18px;
    }

    .scale-labels {
        font-size: 13px;
    }
}

/* --- Teen sub-section cards: question rhythm --- */
.teen-sub-card .field {
    margin-bottom: 0;
}

.teen-sub-card .field + .field {
    margin-top: 26px !important;
    padding-top: 22px;
    border-top: 1px dashed var(--pw-sage-mist);
}

.teen-sub-card .field > label .small,
.field label .small {
    color: #6C7A79;
    font-weight: 400;
    margin-left: 4px;
}

/* --- Unanswered question highlight (Teen Step 4) --- */
.field.is-missing > label {
    color: var(--pw-clay-text);
}

.field.is-missing .option-pill,
.field.is-missing .check-pill,
.field.is-missing .scale-pill {
    border-color: rgba(178, 67, 56, 0.55);
}

.teen-focus-err {
    padding: 12px 16px;
    margin: 0 0 20px;
    background: rgba(178, 67, 56, 0.06);
    border: 1px solid rgba(178, 67, 56, 0.25);
    border-radius: 10px;
    font-size: 14px;
    line-height: 20px;
}

/* --- Inline errors (shown via JS display:flex) --- */
.err .ico {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}

/* ==========================================================================
   ONBOARDING FORM — COMPREHENSIVE MOBILE RESPONSIVENESS
   ========================================================================== */

/* Universal mobile safeguards for form elements */
.field input:not([type="radio"]):not([type="checkbox"]),
.field select,
.field textarea {
    max-width: 100%;
    box-sizing: border-box;
}

input[type="date"],
input[type="email"],
input[type="tel"],
input[type="text"],
select,
textarea {
    -webkit-appearance: none;
    appearance: none;
    font-size: 16px; /* Prevents auto-zoom on focus in iOS Safari */
}

/* --- PHABLETS & TABLETS (<= 640px) --- */
@media(max-width: 640px) {
    .onboarding-page-wrap {
        padding: calc(var(--header) + 24px) 0 48px;
    }

    .onboarding-intro {
        margin: 0 auto 28px;
        padding: 0 4px;
    }

    .onboarding-intro .display {
        font-size: 28px;
        line-height: 36px;
        margin: 10px 0 12px;
    }

    .onboarding-intro .lead {
        font-size: 14px;
        line-height: 22px;
    }

    .onboarding-card {
        padding: 24px 18px;
        border-radius: 18px;
    }

    .step-banner {
        margin-bottom: 24px;
        padding-bottom: 16px;
    }

    .step-heading {
        font-size: 26px;
        line-height: 32px;
    }

    .step-lead {
        font-size: 14px;
        line-height: 22px;
    }

    .field {
        margin-bottom: 18px;
    }

    .field input:not([type="radio"]):not([type="checkbox"]),
    .field select,
    .field textarea {
        min-height: 48px;
        padding: 12px 14px;
        border-radius: 10px;
    }

    .field textarea {
        min-height: 120px;
    }

    .field-row {
        gap: 16px;
        margin-bottom: 16px;
    }

    .teen-sub-card {
        padding: 20px 16px;
        border-radius: 14px;
        margin-bottom: 20px;
    }

    .teen-sub-header {
        margin-bottom: 16px;
        padding-bottom: 12px;
        gap: 10px;
    }

    .teen-sub-title {
        font-size: 20px;
        line-height: 24px;
    }

    .teen-sub-icon {
        width: 32px;
        height: 32px;
        border-radius: 8px;
    }

    .teen-sub-icon svg {
        width: 18px;
        height: 18px;
    }

    .teen-sub-card .field + .field {
        margin-top: 20px !important;
        padding-top: 18px;
    }

    .privacy-banner {
        padding: 14px 16px;
        font-size: 13px;
        line-height: 19px;
        margin-top: 20px;
    }

    .reflection-prompt-box {
        padding: 14px 16px;
        gap: 12px;
        margin-bottom: 20px;
    }

    .journey-card {
        padding: 20px 18px;
    }

    .journey-card-title {
        font-size: 22px;
        line-height: 28px;
    }

    .contact-pref-card {
        padding: 14px 16px !important;
    }
}

/* --- SMARTPHONES (<= 520px) --- */
@media(max-width: 520px) {
    .step-actions {
        flex-direction: column-reverse;
        gap: 12px;
        margin-top: 24px;
        padding-top: 18px;
    }

    .step-actions span:empty {
        display: none;
    }

    .btn-arrow,
    .btn-ghost-arrow,
    .btn-next,
    .btn-prev {
        width: 100%;
        text-align: center;
        justify-content: center;
        box-sizing: border-box;
        min-height: 48px;
        font-size: 13px;
        letter-spacing: .10em;
        padding: 0 20px;
    }

    .crisis-helpline-box {
        flex-direction: column;
        align-items: stretch;
        padding: 16px 14px;
        gap: 12px;
    }

    .crisis-helpline-box .btn-arrow {
        justify-content: center;
        min-height: 46px;
    }

    .crisis-helpline-number {
        font-size: 26px;
    }

    .teen-crisis-card {
        padding: 18px 14px;
        border-radius: 14px;
    }

    .teen-crisis-card h3 {
        font-size: 20px;
        line-height: 26px;
    }

    #btnDismissCrisis {
        width: 100%;
        text-align: center;
        justify-content: center;
    }

    .form-success-card {
        padding: 32px 16px;
    }

    .form-success-card > div:last-child {
        display: flex;
        flex-direction: column;
        width: 100%;
        gap: 10px;
    }

    .form-success-card > div:last-child .btn-arrow,
    .form-success-card > div:last-child .btn-ghost-arrow {
        width: 100%;
        justify-content: center;
    }
}

/* --- COMPACT SMARTPHONES (<= 480px) --- */
@media(max-width: 480px) {
    .wrap {
        padding: 0 14px;
    }

    .onboarding-card {
        padding: 20px 14px;
        border-radius: 16px;
        box-shadow: 0 4px 20px rgba(30, 74, 72, 0.05);
    }

    .onboarding-intro .display {
        font-size: 24px;
        line-height: 32px;
    }

    .step-banner {
        margin-bottom: 18px;
        padding-bottom: 14px;
    }

    .step-badge {
        font-size: 10px;
        letter-spacing: .12em;
        padding: 3px 8px;
        margin-bottom: 8px;
    }

    .step-heading {
        font-size: 23px;
        line-height: 29px;
    }

    .step-lead {
        font-size: 13.5px;
        line-height: 21px;
    }

    .stepper-nav {
        margin: 0 auto 20px;
        padding: 0 4px;
    }

    .stepper-nodes {
        padding: 0;
    }

    .step-node {
        padding: 2px;
    }

    .step-node-disc {
        width: 32px;
        height: 32px;
        font-size: 12px;
        margin-bottom: 0;
    }

    .stepper-line-track {
        top: 16px;
        left: 16px;
        right: 16px;
    }

    .step-node.active .step-node-disc {
        box-shadow: 0 0 0 3px rgba(30, 74, 72, 0.16);
        transform: scale(1.06);
    }

    .step-node .step-check {
        width: 14px;
        height: 14px;
    }

    .mobile-step-summary {
        font-size: 12px;
        margin-bottom: 8px;
    }

    /* Grids & Pills */
    .relationship-options-grid,
    .grade-options-grid,
    .board-options-grid {
        gap: 8px;
    }

    .option-pill {
        padding: 10px 6px;
        font-size: 13px;
        line-height: 17px;
        min-height: 44px;
        border-radius: 10px;
    }

    .check-pill {
        padding: 12px 12px;
        gap: 10px;
        font-size: 13.5px;
        line-height: 19px;
        min-height: 48px;
        border-radius: 10px;
    }

    .check-pill .check-card-box,
    .check-card .check-card-box,
    .consent-check-pill .check-card-box {
        width: 18px;
        height: 18px;
        min-width: 18px;
        min-height: 18px;
        border-radius: 5px;
    }

    .check-pill .check-card-box svg,
    .check-card .check-card-box svg,
    .consent-check-pill .check-card-box svg {
        width: 11px;
        height: 11px;
    }

    .check-card {
        padding: 12px 12px;
        gap: 10px;
        font-size: 14px;
        line-height: 20px;
        border-radius: 10px;
    }

    .consent-check-pill {
        padding: 12px 14px;
        gap: 10px;
        border-radius: 10px;
    }

    .consent-label-text {
        font-size: 13px;
        line-height: 19px;
    }

    /* Rating Scale */
    .teen-scale-track {
        gap: 6px;
    }

    .scale-pill {
        min-height: 46px;
        font-size: 16px;
        border-radius: 8px;
    }

    .scale-labels {
        font-size: 11px;
        line-height: 15px;
        margin-top: 6px;
    }

    /* Notices & Badges */
    .under14-box {
        padding: 14px 12px;
        gap: 10px;
        border-radius: 12px;
    }

    .under14-box h4 {
        font-size: 14px;
        line-height: 20px;
    }

    .under14-box p {
        font-size: 12.5px;
        line-height: 18px;
    }

    .age-detected-badge {
        padding: 10px 12px;
        gap: 8px;
        font-size: 12.5px;
        line-height: 18px;
        border-radius: 10px;
    }

    .parent-consent-notice {
        padding: 10px 12px;
        gap: 10px;
        border-radius: 8px;
    }

    .parent-consent-notice p {
        font-size: 13px;
        line-height: 19px;
    }

    .teen-privacy-card {
        padding: 14px 14px;
        border-radius: 10px;
        margin: 16px 0;
    }

    .teen-privacy-card p {
        font-size: 13px;
        line-height: 19px;
    }

    .teen-focus-err {
        padding: 10px 12px;
        font-size: 13px;
        line-height: 18px;
    }
}

/* --- ULTRA-COMPACT SCREENS (<= 360px) --- */
@media(max-width: 360px) {
    .wrap {
        padding: 0 10px;
    }

    .onboarding-card {
        padding: 16px 10px;
        border-radius: 14px;
    }

    .onboarding-intro .display {
        font-size: 22px;
        line-height: 28px;
    }

    .step-heading {
        font-size: 21px;
        line-height: 26px;
    }

    .step-node-disc {
        width: 28px;
        height: 28px;
        font-size: 11px;
    }

    .stepper-line-track {
        top: 14px;
        left: 14px;
        right: 14px;
    }

    .option-pill {
        padding: 8px 4px;
        font-size: 12px;
        line-height: 16px;
    }

    .scale-pill {
        min-height: 42px;
        font-size: 15px;
    }

    .scale-labels {
        font-size: 10px;
    }

    .btn-arrow,
    .btn-ghost-arrow,
    .btn-next,
    .btn-prev {
        min-height: 44px;
        font-size: 12px;
        letter-spacing: .06em;
        padding: 0 12px;
    }
}

/* ==========================================================================
   PRIVACY POLICY & LEGAL PAGES
   ========================================================================== */

.policy-meta-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--pw-white);
    border: 1px solid var(--pw-sage-mist);
    padding: 6px 14px;
    border-radius: 9999px;
    font-size: 13px;
    font-weight: 500;
    color: var(--pw-clay-text);
    margin-top: 16px;
    letter-spacing: .02em;
}

.policy-meta-pill svg {
    width: 14px;
    height: 14px;
    stroke: currentColor;
    fill: none;
    stroke-width: 2;
}

.policy-layout {
    display: grid;
    gap: 40px;
    align-items: flex-start;
}

@media(min-width: 1024px) {
    .policy-layout {
        grid-template-columns: 280px minmax(0, 1fr);
        gap: 56px;
    }
}

/* Sticky Table of Contents Sidebar */
.policy-sidebar {
    display: none;
}

@media(min-width: 1024px) {
    .policy-sidebar {
        display: block;
        position: sticky;
        top: calc(var(--header) + 24px);
        max-height: calc(100vh - var(--header) - 48px);
        overflow-y: auto;
        padding-right: 8px;
    }
}

.policy-toc-card {
    background: var(--pw-white);
    border: 1.5px solid var(--pw-sage-mist);
    border-radius: 14px;
    padding: 24px 20px;
    box-shadow: 0 4px 16px rgba(26, 37, 36, 0.03);
}

.policy-toc-title {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .12em;
    font-weight: 500;
    color: var(--pw-clay-text);
    margin-bottom: 14px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.policy-toc-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.policy-toc-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 7px 10px;
    border-radius: 8px;
    font-size: 13px;
    line-height: 18px;
    color: var(--pw-ink);
    text-decoration: none;
    transition: all var(--ease);
}

.policy-toc-num {
    font-family: var(--font-display);
    font-size: 15px;
    font-weight: 500;
    color: var(--pw-clay-text);
    min-width: 20px;
}

.policy-toc-link:hover,
.policy-toc-link:focus-visible {
    background: var(--pw-sandstone);
    color: var(--pw-teal);
    transform: translateX(3px);
}

.policy-toc-link.is-active {
    background: #FAF7F2;
    color: var(--pw-teal);
    font-weight: 500;
    border-left: 2px solid var(--pw-teal);
}

/* Mobile Quick Navigation Strip */
.policy-mobile-nav {
    display: block;
    background: var(--pw-white);
    border: 1px solid var(--pw-sage-mist);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 24px;
}

@media(min-width: 1024px) {
    .policy-mobile-nav {
        display: none;
    }
}

.policy-mobile-nav summary {
    font-size: 14px;
    font-weight: 500;
    color: var(--pw-teal);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    list-style: none;
}

.policy-mobile-nav summary::-webkit-details-marker {
    display: none;
}

.policy-mobile-nav summary::after {
    content: "↓";
    font-size: 14px;
    transition: transform var(--ease);
}

.policy-mobile-nav[open] summary::after {
    transform: rotate(180deg);
}

.policy-mobile-nav ul {
    list-style: none;
    padding: 12px 0 0;
    margin: 0;
    display: grid;
    gap: 8px;
    border-top: 1px solid var(--pw-sage-mist);
    margin-top: 12px;
}

.policy-mobile-nav a {
    color: var(--pw-ink);
    text-decoration: none;
    font-size: 13px;
    display: block;
    padding: 4px 0;
}

/* Document Container & Cards */
.policy-document {
    min-width: 0;
}

.policy-card {
    background: var(--pw-white);
    border: 1.5px solid var(--pw-sage-mist);
    border-radius: 16px;
    padding: 28px 24px;
    margin-bottom: 24px;
    box-shadow: 0 4px 20px rgba(26, 37, 36, 0.03);
    scroll-margin-top: calc(var(--header) + 24px);
    transition: border-color var(--ease);
}

@media(min-width: 768px) {
    .policy-card {
        padding: 36px 36px;
        margin-bottom: 32px;
    }
}

.policy-card:hover {
    border-color: #C5D0C9;
}

.policy-header {
    display: flex;
    align-items: baseline;
    gap: 14px;
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--pw-sage-mist);
}

.policy-num {
    font-family: var(--font-display);
    font-size: 32px;
    line-height: 1;
    color: var(--pw-clay);
    font-weight: 500;
}

.policy-h2 {
    font-family: var(--font-display);
    font-size: 26px;
    line-height: 1.25;
    color: var(--pw-teal);
    font-weight: 500;
    margin: 0;
}

@media(min-width: 768px) {
    .policy-num {
        font-size: 36px;
    }
    .policy-h2 {
        font-size: 30px;
    }
}

.policy-h3 {
    font-family: var(--font-display);
    font-size: 20px;
    line-height: 1.35;
    color: var(--pw-teal);
    font-weight: 500;
    margin: 28px 0 10px;
    letter-spacing: .01em;
}

.policy-h3:first-of-type {
    margin-top: 20px;
}

.policy-card p {
    font-size: 15px;
    line-height: 26px;
    color: var(--pw-ink);
    margin: 0 0 16px;
}

.policy-card p:last-child {
    margin-bottom: 0;
}

.policy-lead {
    font-size: 17px !important;
    line-height: 28px !important;
    color: var(--pw-teal) !important;
    font-weight: 450;
    margin-bottom: 20px !important;
}

/* Delicate styled list */
.policy-list {
    list-style: none;
    padding: 0;
    margin: 14px 0 20px 4px;
    display: grid;
    gap: 10px;
}

.policy-list li {
    position: relative;
    padding-left: 24px;
    font-size: 15px;
    line-height: 24px;
    color: var(--pw-ink);
}

.policy-list li::before {
    content: "";
    position: absolute;
    left: 4px;
    top: 9px;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--pw-clay);
    opacity: .85;
}

/* Callout Notice Boxes (Section 3 & Special Disclaimers) */
.policy-callout {
    background: #FAF7F2;
    border: 1px solid var(--pw-clay);
    border-left: 4px solid var(--pw-clay);
    border-radius: 12px;
    padding: 20px 22px;
    margin: 24px 0;
    display: flex;
    gap: 14px;
    align-items: flex-start;
}

.policy-callout svg {
    width: 22px;
    height: 22px;
    stroke: var(--pw-clay-text);
    fill: none;
    stroke-width: 2;
    flex-shrink: 0;
    margin-top: 2px;
}

.policy-callout p {
    font-size: 14px !important;
    line-height: 22px !important;
    color: var(--pw-clay-text) !important;
    margin: 0 !important;
    font-weight: 500;
}

/* Contact Card Box (Section 12) */
.policy-contact-box {
    background: #FAF7F2;
    border: 1.5px solid var(--pw-sage-mist);
    border-radius: 14px;
    padding: 24px;
    margin: 20px 0;
    display: grid;
    gap: 12px;
}

.policy-contact-name {
    font-family: var(--font-display);
    font-size: 22px;
    font-weight: 500;
    color: var(--pw-teal);
}

.policy-contact-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 15px;
    color: var(--pw-ink);
}

.policy-contact-item svg {
    width: 18px;
    height: 18px;
    stroke: var(--pw-teal);
    fill: none;
    stroke-width: 2;
    flex-shrink: 0;
}

.policy-contact-item a {
    color: var(--pw-teal);
    text-decoration: underline;
    text-underline-offset: 3px;
    transition: color var(--ease);
}

.policy-contact-item a:hover {
    color: var(--pw-clay-text);
}

.policy-closing-box {
    background: var(--pw-sandstone);
    border-radius: 14px;
    padding: 24px;
    margin-top: 24px;
    border: 1px dashed var(--pw-sage-mist);
}

.policy-closing-box p {
    font-style: italic;
    color: var(--pw-teal);
    font-size: 16px;
    line-height: 26px;
    margin: 0;
}

