/*
 * myupheld.com: UpHeld's informational site.
 * Colors and type follow the app (resources/css/tokens.css): navy ink,
 * royal blue accent, lime for the tagline. Light and dark follow the
 * visitor's setting. Layout: a navy opening band that carries the tagline,
 * then quiet alternating rows of real screens from the sample organization.
 */
@font-face {
    font-family: 'Source Sans 3';
    src: url('fonts/source-sans-3-latin-wght-normal.woff2') format('woff2-variations');
    font-weight: 200 900;
    font-style: normal;
    font-display: swap;
}

:root {
    color-scheme: light;
    --page: #f2f4f8;
    --panel: #ffffff;
    --ink: #172033;
    --muted: #5a6478;
    --line: #d9dee8;
    --accent: #4169e1;
    --accent-text: #2f55c9;
    --accent-ink: #ffffff;
    --navy: #172033;
    --navy-ink: #ffffff;
    --navy-muted: #b9c3d6;
    --lime: #b7e34a;
    --private: #534ab7;
    --private-bg: #eeedfb;
    --late: #a8321f;
    --font: 'Source Sans 3', 'Segoe UI', system-ui, -apple-system, sans-serif;
    --radius: 14px;
    --gutter: clamp(16px, 4vw, 48px);
    --max: 1160px;
    /* Layout: a navy band with the tagline and the Today screen, then rows that alternate screen and words. */
}

@media (prefers-color-scheme: dark) {
    :root:not([data-theme='light']) {
        color-scheme: dark;
        --page: #0f1522;
        --panel: #172033;
        --ink: #e8ecf4;
        --muted: #a3adc2;
        --line: #2c3850;
        --accent: #7c98f0;
        --accent-text: #9db3f5;
        --accent-ink: #0f1522;
        --navy: #0b101b;
        --private: #b3adf2;
        --private-bg: #25234a;
        --late: #f08a76;
    }
}

:root[data-theme='dark'] {
    color-scheme: dark;
    --page: #0f1522;
    --panel: #172033;
    --ink: #e8ecf4;
    --muted: #a3adc2;
    --line: #2c3850;
    --accent: #7c98f0;
    --accent-text: #9db3f5;
    --accent-ink: #0f1522;
    --navy: #0b101b;
    --private: #b3adf2;
    --private-bg: #25234a;
    --late: #f08a76;
}

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

html {
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
}

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

body {
    margin: 0;
    background: var(--page);
    color: var(--ink);
    font: 400 18px/1.55 var(--font);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: var(--accent-text);
}

:focus-visible {
    outline: 3px solid var(--accent);
    outline-offset: 2px;
    border-radius: 4px;
}

h1,
h2,
h3 {
    text-wrap: balance;
    line-height: 1.12;
    margin: 0;
}

.wrap {
    max-width: var(--max);
    margin: 0 auto;
    padding: 0 var(--gutter);
}

.skip {
    position: absolute;
    left: 8px;
    top: -60px;
    padding: 8px 14px;
    background: var(--panel);
    color: var(--ink);
    border-radius: 8px;
    z-index: 10;
}

.skip:focus {
    top: 8px;
}

/* ---------- Navy band: header and opening ---------- */
.band {
    background: var(--navy);
    color: var(--navy-ink);
}

.top {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding-top: 22px;
    padding-bottom: 22px;
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--navy-ink);
    text-decoration: none;
}

.brand__mark {
    width: 44px;
    height: auto;
}

.brand__word {
    width: 96px;
    height: auto;
}

.top nav ul {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 22px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.top nav a {
    color: var(--navy-ink);
    text-decoration: none;
    font-weight: 600;
    font-size: 16px;
}

.top nav a:hover {
    text-decoration: underline;
    text-underline-offset: 4px;
}

.hero {
    display: grid;
    grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
    gap: clamp(28px, 5vw, 64px);
    align-items: end;
    padding-top: clamp(24px, 5vw, 56px);
}

.hero__words {
    padding-bottom: clamp(32px, 6vw, 80px);
}

.eyebrow {
    margin: 0 0 18px;
    color: var(--navy-muted);
    font-size: 15px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.hero h1 {
    color: var(--lime);
    font-size: clamp(44px, 7vw, 84px);
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 0.98;
}

.hero h1::after {
    content: '';
    display: block;
    width: 72px;
    height: 6px;
    margin-top: 22px;
    border-radius: 3px;
    background: var(--lime);
}

.hero__lede {
    max-width: 34em;
    margin: 22px 0 30px;
    font-size: clamp(18px, 2vw, 21px);
    color: var(--navy-ink);
}

.button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 13px 22px;
    border: 0;
    border-radius: 10px;
    background: var(--lime);
    color: #172033;
    font: inherit;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
}

.button:hover {
    background: #c6ec62;
}


.hero__shot {
    align-self: end;
    border-radius: var(--radius) var(--radius) 0 0;
    overflow: hidden;
    box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-bottom: 0;
}

/* ---------- Sections ---------- */
main section {
    padding: clamp(56px, 8vw, 96px) 0 0;
}

.section-head {
    max-width: 40em;
    margin-bottom: clamp(28px, 4vw, 44px);
}

.section-head h2 {
    font-size: clamp(30px, 4vw, 44px);
    font-weight: 800;
    letter-spacing: -0.01em;
}

.section-head p {
    margin: 14px 0 0;
    color: var(--muted);
    font-size: 20px;
}

.rows {
    display: grid;
    gap: clamp(44px, 7vw, 88px);
}

.row {
    display: grid;
    grid-template-columns: minmax(0, 4fr) minmax(0, 7fr);
    gap: clamp(24px, 4vw, 56px);
    align-items: center;
}

.row:nth-child(even) {
    grid-template-columns: minmax(0, 7fr) minmax(0, 4fr);
}

.row:nth-child(even) .row__words {
    order: 2;
}

.row__words h3 {
    font-size: 28px;
    font-weight: 750;
}

.row__words p {
    margin: 12px 0 0;
    max-width: 30em;
}

.row__words ul {
    margin: 14px 0 0;
    padding-left: 1.1em;
    color: var(--muted);
}

.row__words li + li {
    margin-top: 6px;
}

.shot {
    border-radius: var(--radius);
    overflow: hidden;
    border: 1px solid var(--line);
    background: var(--panel);
    box-shadow: 0 18px 40px rgba(23, 32, 51, 0.1);
}

/* ---------- Private by design ---------- */
.rules {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 18px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.rules li {
    padding: 22px 22px 24px;
    border-radius: var(--radius);
    background: var(--panel);
    border: 1px solid var(--line);
}

.rules li:first-child {
    background: var(--private-bg);
    border: 2px dashed var(--private);
}

.rules b {
    display: block;
    margin-bottom: 6px;
    font-size: 19px;
}

.rules span {
    color: var(--muted);
}

.rules .tag {
    display: inline-block;
    margin-bottom: 10px;
    padding: 1px 9px;
    border-radius: 999px;
    background: var(--private);
    color: var(--panel);
    width: max-content;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

/* ---------- Fit ---------- */
.fit {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 18px 40px;
    margin: 0;
}

.fit div {
    padding-top: 16px;
    border-top: 3px solid var(--accent);
}

.fit dt {
    font-weight: 750;
    font-size: 20px;
}

.fit dd {
    margin: 6px 0 0;
    color: var(--muted);
}

/* ---------- Footer ---------- */
.foot {
    margin-top: clamp(64px, 9vw, 112px);
    padding: 32px 0 40px;
    background: var(--navy);
    color: var(--navy-muted);
    font-size: 16px;
}

.foot .wrap {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 12px 24px;
}

.foot a {
    color: var(--navy-ink);
}

.foot p {
    margin: 0;
}

/* ---------- Privacy page ---------- */
.doc {
    max-width: 44em;
    padding-top: clamp(40px, 6vw, 72px);
}

.doc h1 {
    font-size: clamp(34px, 5vw, 52px);
    font-weight: 800;
}

.doc h2 {
    margin-top: 36px;
    font-size: 24px;
}

.doc p,
.doc li {
    max-width: 65ch;
}

/* ---------- Narrow screens ---------- */
@media (max-width: 860px) {
    .hero,
    .row,
    .row:nth-child(even) {
        grid-template-columns: 1fr;
    }

    .row:nth-child(even) .row__words {
        order: 0;
    }

    .hero__words {
        padding-bottom: 8px;
    }
}

@media (max-width: 520px) {
    .top nav a {
        font-size: 15px;
    }
}
