/* ============================================================
   CoreAdmin segment landing pages
   Shared pattern for the five "Who it's for" pages.
   Tokens and component language are inherited from index.html.
   ============================================================ */

@font-face {
    font-family: 'General Sans';
    src: url('../fonts/GeneralSans-Variable.woff2') format('woff2');
    font-weight: 200 700;
    font-display: swap;
}
@font-face {
    font-family: 'IBM Plex Mono';
    src: url('../fonts/ibm-plex-mono-400.woff2') format('woff2');
    font-weight: 400;
    font-display: swap;
}

:root {
    --blurple: #635BFF;
    --blurple-rgb: 99, 91, 255;
    --blurple-deep: #5349E8;
    --navy: #0A2540;
    --navy-rgb: 10, 37, 64;
    --navy-deep-rgb: 7, 26, 48;
    --slate: #425466;
    --slate-light: #6B7C93;
    --cloud: #F6F9FC;
    --hairline: #E6EBF1;
    --emerald: #10B981;
    --mint: #2EE6A8;
    --white: #ffffff;
    --white-muted: rgba(255, 255, 255, 0.55);
    --radius-lg: 16px;
    --radius-pill: 999px;
    --font-sans: 'General Sans', Inter, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-mono: 'IBM Plex Mono', SFMono-Regular, Menlo, monospace;
    --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
    --shadow-card: 0 2px 5px -1px rgba(var(--navy-rgb), 0.08), 0 1px 3px -1px rgba(var(--navy-rgb), 0.06);
    --shadow-lift: 0 24px 48px -20px rgba(var(--navy-rgb), 0.22), 0 8px 20px -12px rgba(var(--navy-rgb), 0.12);
    --measure: 68ch;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    font-family: var(--font-sans);
    font-size: 16.5px;
    line-height: 1.65;
    color: var(--slate);
    background: var(--white);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
    overflow-x: hidden;
}
h1, h2, h3, h4 { color: var(--navy); font-weight: 600; line-height: 1.14; letter-spacing: -0.02em; }
img { max-width: 100%; display: block; }
a { color: var(--blurple); text-decoration: none; }
button { font-family: inherit; cursor: pointer; }

:where(a, button, summary, [tabindex]):focus-visible {
    outline: 2px solid var(--blurple);
    outline-offset: 3px;
    border-radius: 4px;
}
.seg-hero :where(a, button):focus-visible,
.seg-band :where(a, button):focus-visible {
    outline-color: var(--white);
}

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

.seg-wrap { max-width: 1080px; margin: 0 auto; padding: 0 24px; }

/* ---------- Nav (inherited from the existing pages) ---------- */
.nav { border-bottom: 1px solid var(--hairline); background: var(--white); }
.nav-inner { max-width: 1080px; margin: 0 auto; padding: 16px 24px; display: flex; align-items: center; justify-content: space-between; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: 17px; color: var(--navy); text-decoration: none; }
.nav a.back { color: var(--slate); text-decoration: none; font-size: 14.5px; }
.nav a.back:hover { color: var(--blurple); }

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 9px;
    font-size: 15.5px; font-weight: 600; line-height: 1;
    padding: 15px 26px; border-radius: var(--radius-pill); border: 1px solid transparent;
    text-decoration: none; white-space: nowrap;
    transition: background 0.18s ease, border-color 0.18s ease, transform 0.18s ease, color 0.18s ease;
}
.btn:active { transform: scale(0.985); }
.btn-primary { background: var(--blurple); color: var(--white); }
.btn-on-navy { background: var(--white); color: var(--navy); }
.btn-ghost-light { background: transparent; color: var(--white); border-color: rgba(255, 255, 255, 0.4); }
@media (hover: hover) and (pointer: fine) {
    .btn-primary:hover { background: var(--blurple-deep); transform: translateY(-1px); }
    .btn-on-navy:hover { background: var(--cloud); transform: translateY(-1px); }
    .btn-ghost-light:hover { background: rgba(255, 255, 255, 0.12); border-color: var(--white); }
}
.btn svg { flex: none; }

/* ---------- Hero ---------- */
.seg-hero {
    position: relative;
    background: var(--navy);
    isolation: isolate;
}
.seg-hero-media {
    position: absolute; inset: 0; z-index: -2;
    overflow: hidden;
}
/* Out of flow, so the hero's own min-height reserves the space and the image
   can never shift the layout as it decodes. */
.seg-hero-media img {
    width: 100%; height: 100%;
    object-fit: cover; object-position: center;
}
.seg-hero::after {
    content: ""; position: absolute; inset: 0; z-index: -1;
    /* The text column never passes ~59% of the viewport, so the scrim only has to
       hold contrast to that point. Measured against the brightest pixel in the
       supplied heroes, white text clears 10:1 there. */
    background: linear-gradient(96deg,
        rgba(var(--navy-deep-rgb), 0.90) 0%,
        rgba(var(--navy-deep-rgb), 0.80) 46%,
        rgba(var(--navy-deep-rgb), 0.52) 74%,
        rgba(var(--navy-deep-rgb), 0.28) 100%);
}
.seg-hero-inner {
    max-width: 1080px; margin: 0 auto;
    padding: 104px 24px 96px;
    min-height: min(66vh, 600px);
    display: flex; flex-direction: column; justify-content: center;
}
.seg-hero-body { max-width: 690px; }
.seg-hero h1 {
    color: var(--white);
    font-size: clamp(2.05rem, 4.5vw, 3.15rem);
    letter-spacing: -0.035em;
    text-wrap: balance;
}
.seg-hero-claim {
    margin-top: 20px;
    color: rgba(255, 255, 255, 0.86);
    font-size: clamp(1.02rem, 1.5vw, 1.18rem);
    line-height: 1.6;
    max-width: 56ch;
}
.seg-hero-actions {
    margin-top: 32px;
    display: flex; flex-wrap: wrap; gap: 14px 18px; align-items: center;
}
.seg-hero-note {
    display: inline-flex; align-items: center; gap: 9px;
    color: rgba(255, 255, 255, 0.72); font-size: 14px;
}
.seg-hero-note::before {
    content: ""; width: 7px; height: 7px; border-radius: 50%; flex: none;
    background: var(--mint); box-shadow: 0 0 0 4px rgba(46, 230, 168, 0.16);
}

/* one authored load moment */
.seg-hero-body > * {
    animation: segRise 0.72s var(--ease-out) both;
}
.seg-hero-body > *:nth-child(1) { animation-delay: 0.04s; }
.seg-hero-body > *:nth-child(2) { animation-delay: 0.13s; }
.seg-hero-body > *:nth-child(3) { animation-delay: 0.22s; }
@keyframes segRise {
    from { opacity: 0; transform: translateY(14px); filter: blur(6px); }
    to { opacity: 1; transform: none; filter: blur(0); }
}

/* ---------- Section shell ---------- */
.seg-section { padding: 84px 0; }
.seg-section + .seg-section { padding-top: 0; }
.seg-section-cloud { background: var(--cloud); border-block: 1px solid var(--hairline); }
.seg-section-cloud + .seg-section { padding-top: 84px; }
.seg-section h2 {
    font-size: clamp(1.6rem, 3vw, 2.15rem);
    letter-spacing: -0.03em;
    text-wrap: balance;
    max-width: 22ch;
}
.seg-lede {
    margin-top: 16px; max-width: var(--measure);
    font-size: 1.03rem; color: var(--slate);
}
.seg-section p, .seg-section li { max-width: var(--measure); }

/* ---------- Obligation to module map ---------- */
.seg-map { margin-top: 34px; }
.seg-table {
    width: 100%;
    border-collapse: separate; border-spacing: 0;
    border: 1px solid var(--hairline);
    border-radius: var(--radius-lg);
    overflow: hidden;
    background: var(--white);
    box-shadow: var(--shadow-card);
    text-align: left;
}
.seg-table th, .seg-table td { padding: 20px 24px; vertical-align: top; max-width: none; }
.seg-table thead th {
    background: var(--navy); color: var(--white);
    font-size: 12.5px; font-weight: 600;
    font-family: var(--font-mono);
    letter-spacing: 0.08em; text-transform: uppercase;
    padding-block: 15px;
}
.seg-table tbody tr + tr th,
.seg-table tbody tr + tr td { border-top: 1px solid var(--hairline); }
.seg-table tbody th {
    width: 47%;
    color: var(--navy); font-size: 15.5px; font-weight: 600; line-height: 1.5;
    letter-spacing: -0.005em;
}
.seg-table tbody td { color: var(--slate); font-size: 15px; }
.seg-table tbody tr:nth-child(even) th,
.seg-table tbody tr:nth-child(even) td { background: rgba(var(--navy-rgb), 0.018); }
.seg-mod {
    display: block; margin-bottom: 5px;
    font-family: var(--font-mono); font-size: 11.5px;
    letter-spacing: 0.07em; text-transform: uppercase;
    color: var(--blurple-deep);
}
.seg-map-foot {
    margin-top: 16px; font-size: 14px; color: var(--slate);
    max-width: var(--measure);
}

/* ---------- Regime tabs ---------- */
.seg-tablist {
    display: inline-flex; gap: 4px; margin-top: 28px; padding: 4px;
    background: var(--white); border: 1px solid var(--hairline);
    border-radius: var(--radius-pill);
}
.seg-tablist button {
    appearance: none; border: 0; background: transparent;
    padding: 10px 20px; border-radius: var(--radius-pill);
    font-size: 14.5px; font-weight: 600; color: var(--slate);
    transition: background 0.18s ease, color 0.18s ease;
}
.seg-tablist button:hover { color: var(--navy); }
.seg-tablist button[aria-selected="true"] {
    background: var(--navy); color: var(--white);
}
.seg-tabpanel:focus { outline: none; }
.seg-tabpanel:focus-visible { outline: 2px solid var(--blurple); outline-offset: 6px; border-radius: var(--radius-lg); }

/* ---------- Proof cards ---------- */
.seg-cards {
    margin-top: 40px;
    display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 26px;
}
.seg-card {
    border: 1px solid var(--hairline); border-radius: var(--radius-lg);
    overflow: hidden; background: var(--white);
    box-shadow: var(--shadow-card);
    transition: box-shadow 0.26s var(--ease-out), transform 0.26s var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
    .seg-card:hover { box-shadow: var(--shadow-lift); transform: translateY(-3px); }
}
.seg-card figure { margin: 0; background: var(--cloud); }
/* height:auto is required: the intrinsic width/height attributes otherwise
   supply a used height and aspect-ratio never applies. */
.seg-card img { width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; }
.seg-card-body { padding: 22px 24px 26px; }
.seg-card h3 { font-size: 17px; letter-spacing: -0.015em; }
.seg-card p { margin-top: 8px; font-size: 14.8px; line-height: 1.6; color: var(--slate); }

/* ---------- Accordions ---------- */
.seg-detail-layout {
    display: grid; grid-template-columns: minmax(220px, 0.72fr) minmax(0, 1.28fr); gap: 64px;
    align-items: start;
}
.seg-detail-layout > h2 { position: sticky; top: 32px; }
.seg-detail-list { border-top: 1px solid var(--hairline); }
.seg-detail-list details { border-bottom: 1px solid var(--hairline); }
.seg-detail-list summary {
    list-style: none;
    display: flex; align-items: center; justify-content: space-between; gap: 20px;
    padding: 22px 2px; cursor: pointer;
    color: var(--navy); font-size: 17px; font-weight: 600; letter-spacing: -0.015em;
}
.seg-detail-list summary::-webkit-details-marker { display: none; }
.seg-detail-list summary::after {
    content: "+"; width: 30px; height: 30px; flex: none;
    display: flex; align-items: center; justify-content: center;
    border: 1px solid var(--hairline); border-radius: 50%;
    color: var(--blurple); font-weight: 500;
    transition: transform 0.2s ease, background 0.2s ease;
}
.seg-detail-list details[open] summary::after {
    transform: rotate(45deg); background: rgba(var(--blurple-rgb), 0.07);
}
.seg-detail-body { padding: 0 52px 26px 2px; }
.seg-detail-body > * + * { margin-top: 13px; }
.seg-detail-body p, .seg-detail-body li { font-size: 15.2px; line-height: 1.7; }
.seg-detail-body ul { list-style: none; }
.seg-detail-body ul li { padding-left: 24px; position: relative; margin-top: 11px; }
.seg-detail-body ul li::before {
    content: ""; position: absolute; left: 0; top: 9px;
    width: 8px; height: 8px; border-radius: 2px;
    background: var(--blurple); opacity: 0.5;
}
.seg-detail-body strong { color: var(--navy); }

/* ---------- CTA band ---------- */
.seg-band {
    background: var(--navy); border-radius: 20px; color: var(--white);
    padding: 40px 42px;
    display: flex; flex-wrap: wrap; gap: 22px 32px;
    align-items: center; justify-content: space-between;
    box-shadow: 0 30px 60px -34px rgba(var(--navy-rgb), 0.6);
}
.seg-band h2 { color: var(--white); max-width: 18ch; font-size: clamp(1.4rem, 2.4vw, 1.85rem); }
.seg-band p { color: rgba(255, 255, 255, 0.74); font-size: 15px; margin-top: 10px; max-width: 52ch; }

/* ---------- Related links ---------- */
.seg-related { padding-bottom: 88px; }
.seg-related h2 { font-size: 1.15rem; letter-spacing: -0.015em; }
.seg-related-grid {
    margin-top: 20px;
    display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 12px;
}
.seg-related-grid a {
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
    padding: 16px 18px; border: 1px solid var(--hairline); border-radius: 12px;
    background: var(--white); color: var(--navy);
    font-size: 14.8px; font-weight: 600; line-height: 1.35;
    transition: border-color 0.18s ease, background 0.18s ease, transform 0.18s ease;
}
.seg-related-grid a::after {
    content: "\2192"; color: var(--blurple); font-weight: 400; flex: none;
    transition: transform 0.18s ease;
}
@media (hover: hover) and (pointer: fine) {
    .seg-related-grid a:hover { border-color: rgba(var(--blurple-rgb), 0.45); background: var(--cloud); }
    .seg-related-grid a:hover::after { transform: translateX(3px); }
}

/* ---------- Sticky CTA bar ---------- */
.seg-sticky {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 70;
    background: rgba(255, 255, 255, 0.97);
    backdrop-filter: saturate(160%) blur(10px);
    border-top: 1px solid var(--hairline);
    box-shadow: 0 -14px 34px -26px rgba(var(--navy-rgb), 0.5);
    transform: translateY(100%);
    transition: transform 0.34s var(--ease-out);
    padding-bottom: env(safe-area-inset-bottom, 0px);
}
.seg-sticky[hidden] { display: none; }
.seg-sticky.is-visible { transform: translateY(0); }
.seg-sticky-inner {
    max-width: 1080px; margin: 0 auto;
    padding: 12px 24px;
    display: flex; align-items: center; gap: 16px;
}
.seg-sticky-copy { min-width: 0; flex: 1 1 auto; }
.seg-sticky-copy strong { display: block; color: var(--navy); font-size: 15px; font-weight: 600; letter-spacing: -0.01em; }
.seg-sticky-copy span { display: block; color: var(--slate); font-size: 13.2px; line-height: 1.45; }
.seg-sticky .btn { padding: 12px 22px; flex: none; }
.seg-sticky-close {
    appearance: none; border: 1px solid var(--hairline); background: var(--white);
    width: 34px; height: 34px; flex: none; border-radius: 50%;
    color: var(--slate); font-size: 17px; line-height: 1;
    display: flex; align-items: center; justify-content: center;
    transition: color 0.18s ease, border-color 0.18s ease;
}
.seg-sticky-close:hover { color: var(--navy); border-color: var(--slate); }
body.has-sticky-cta { padding-bottom: 78px; }

/* ---------- Footer (inherited) ---------- */
footer { border-top: 1px solid var(--hairline); }
.foot-inner {
    max-width: 1080px; margin: 0 auto; padding: 28px 24px;
    display: flex; flex-wrap: wrap; gap: 10px 24px; justify-content: space-between;
    color: var(--slate); font-size: 13.5px;
}
.foot-inner a { color: var(--slate); text-decoration: none; margin-right: 16px; }
.foot-inner a:hover { color: var(--blurple); }

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 900px) {
    .seg-hero::after {
        background: linear-gradient(to top,
            rgba(var(--navy-deep-rgb), 0.93) 0%,
            rgba(var(--navy-deep-rgb), 0.84) 58%,
            rgba(var(--navy-deep-rgb), 0.70) 100%);
    }
    .seg-hero-inner { padding: 72px 24px 68px; min-height: 0; }
    .seg-section { padding: 62px 0; }
    .seg-section-cloud + .seg-section { padding-top: 62px; }
    .seg-cards { grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 20px; }
    .seg-detail-layout { grid-template-columns: minmax(0, 1fr); gap: 26px; }
    .seg-detail-layout > h2 { position: static; }
    .seg-band { padding: 32px 28px; }
    .seg-related { padding-bottom: 66px; }
}

@media (max-width: 700px) {
    body { font-size: 16px; }
    .seg-hero-actions .btn { width: 100%; }
    .seg-detail-body { padding-right: 8px; }
    .seg-detail-list summary { font-size: 16px; gap: 14px; }
    .seg-band { flex-direction: column; align-items: flex-start; }
    .seg-band .btn { width: 100%; }
    .seg-cards { grid-template-columns: minmax(0, 1fr); }
    .seg-tablist { display: flex; width: 100%; }
    .seg-tablist button { flex: 1 1 0; padding-inline: 10px; }

    /* Table becomes a card stack. Explicit ARIA roles in the markup keep
       the table semantics that the display change would otherwise drop. */
    .seg-table {
        border: 0; border-radius: 0; box-shadow: none; background: transparent;
        display: block;
    }
    .seg-table thead { display: none; }
    .seg-table tbody { display: grid; gap: 12px; }
    .seg-table tbody tr {
        display: block;
        border: 1px solid var(--hairline); border-radius: 14px;
        background: var(--white); box-shadow: var(--shadow-card);
        overflow: hidden;
    }
    .seg-table tbody th, .seg-table tbody td {
        display: block; width: auto; padding: 16px 18px; background: none;
    }
    .seg-table tbody tr th { padding-bottom: 0; }
    .seg-table tbody tr + tr th, .seg-table tbody tr + tr td { border-top: 0; }
    .seg-table tbody td { border-top: 0; padding-top: 12px; }
    .seg-table tbody tr:nth-child(even) th,
    .seg-table tbody tr:nth-child(even) td { background: none; }

    .seg-sticky-inner { padding: 10px 16px; gap: 12px; }
    .seg-sticky-copy span { display: none; }
    .seg-sticky .btn { padding: 12px 18px; font-size: 14.5px; }
    body.has-sticky-cta { padding-bottom: 72px; }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    .seg-hero-body > * { animation: none; }
}

/* Jersey page carries a second related row. */
.seg-related .seg-related-more { margin-top: 36px; }
