/* Shared design system for the myPill and Ovu websites. Brand stylesheets override the color tokens. */

@font-face {
    font-family: 'Fraunces';
    src: url('fonts/Fraunces/Fraunces-Variable.woff2') format('woff2');
    font-weight: 100 900;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Fraunces';
    src: url('fonts/Fraunces/Fraunces-Italic-Variable.woff2') format('woff2');
    font-weight: 100 900;
    font-style: italic;
    font-display: swap;
}

@font-face {
    font-family: 'DM Sans';
    src: url('fonts/DMSans/DMSans-Variable.woff2') format('woff2');
    font-weight: 100 1000;
    font-style: normal;
    font-display: swap;
}

:root {
    color-scheme: light dark;

    --font: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-display: 'Fraunces', ui-serif, 'New York', Georgia, serif;

    --bg: #fdfaf6;
    --surface: #f6f0e9;
    --surface-raised: #ffffff;
    --text: #1f2a28;
    --text-muted: #5b6765;
    --border: #ebe3d9;
    --shadow: 0 1px 2px rgb(60 40 30 / 4%), 0 18px 44px rgb(60 40 30 / 8%);
    --shadow-float: 0 2px 6px rgb(60 40 30 / 6%), 0 22px 48px rgb(60 40 30 / 14%);

    --accent: #0b7f6f;
    --accent-strong: #08594e;
    --accent-soft: #e3f3f0;
    --accent-fill: #0b7f6f;
    --accent-fill-hover: #08594e;
    --accent-contrast: #ffffff;
    --accent-glow: rgb(11 127 111 / 22%);
    --accent-gradient: linear-gradient(135deg, #17a18d, #075247);
    --accent-text: linear-gradient(100deg, var(--accent), var(--accent-strong));

    /* Pastel card tones, each with a matching ink for icons and numerals */
    --tone-1: #dff2ec;
    --tone-1-ink: #0b6f61;
    --tone-2: #fbe3ea;
    --tone-2-ink: #b03d6b;
    --tone-3: #fbefd2;
    --tone-3-ink: #8a5f14;
    --tone-4: #ece4fa;
    --tone-4-ink: #6a4bb0;
    --tone-badge: rgb(255 255 255 / 75%);

    /* Soft color washes behind the top of every page */
    --aura-1: rgb(11 127 111 / 16%);
    --aura-2: rgb(240 130 160 / 16%);
    --aura-3: rgb(250 200 120 / 14%);

    --text-caption: 0.8125rem;
    --text-body: 1.0625rem;
    --text-title: 1.1875rem;
    --text-heading: clamp(2rem, 1.3rem + 2.6vw, 3.1rem);
    --text-display: clamp(2.9rem, 1.6rem + 5.2vw, 5.1rem);

    --radius-sm: 12px;
    --radius: 24px;
    --radius-lg: 40px;
    --max-width: 1120px;
    --gutter: 20px;
    --header-height: 60px;
}

@media (prefers-color-scheme: dark) {
    :root {
        --bg: #111514;
        --surface: #171d1b;
        --surface-raised: #1e2523;
        --text: #eef2f0;
        --text-muted: #a5b1ae;
        --border: #2a3331;
        --shadow: 0 1px 2px rgb(0 0 0 / 30%), 0 18px 44px rgb(0 0 0 / 36%);
        --shadow-float: 0 2px 6px rgb(0 0 0 / 30%), 0 22px 48px rgb(0 0 0 / 50%);
        --tone-badge: rgb(255 255 255 / 8%);
    }
}

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

html { scroll-padding-top: calc(var(--header-height) + 36px); -webkit-text-size-adjust: 100%; }

body.site {
    position: relative;
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font);
    font-size: var(--text-body);
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    overflow-x: clip;
}

body.site::before {
    content: '';
    position: absolute;
    inset: 0 0 auto;
    z-index: -1;
    height: min(940px, 100%);
    background:
        radial-gradient(52% 58% at 88% 8%, var(--aura-1), transparent 72%),
        radial-gradient(46% 52% at 4% 0%, var(--aura-2), transparent 72%),
        radial-gradient(40% 44% at 46% 62%, var(--aura-3), transparent 72%);
    -webkit-mask-image: linear-gradient(#000 55%, transparent);
    mask-image: linear-gradient(#000 55%, transparent);
    pointer-events: none;
}

body.site:has(.bare-page)::before { display: none; }

/* Element defaults use :where() so any component class overrides them. */
:where(.site) img { max-width: 100%; height: auto; }

:where(.site) :is(h1, h2, h3) { margin: 0; color: var(--text); line-height: 1.15; }
:where(.site) :is(h1, h2) { font-family: var(--font-display); font-weight: 400; font-variation-settings: 'SOFT' 100, 'WONK' 0; text-wrap: balance; }
:where(.site) h1 { font-size: var(--text-display); letter-spacing: -0.035em; line-height: 1; }
:where(.site) h2 { font-size: var(--text-heading); letter-spacing: -0.025em; line-height: 1.08; }
:where(.site) h3 { font-size: var(--text-title); font-weight: 600; letter-spacing: -0.01em; }
:where(.site) p { margin: 0 0 1em; }
:where(.site) p:where(:last-child) { margin-bottom: 0; }

:where(.site) :is(h1, h2) em {
    font-style: italic;
    font-weight: 300;
    background: var(--accent-text);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    /* Keeps the italic overhang from being clipped by the background box */
    padding-inline-end: 0.08em;
}

:where(.site) a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 3px; }
:where(.site) a:where(:hover) { color: var(--accent-strong); }
.site :focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 8px; }
.site ::selection { background: var(--accent-soft); color: var(--accent-strong); }

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

.skip-link { position: absolute; left: var(--gutter); top: -100px; z-index: 100; }
.skip-link:focus { top: 12px; }

.container { width: 100%; max-width: var(--max-width); margin-inline: auto; padding-inline: var(--gutter); }

/* Buttons */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 54px;
    padding: 14px 28px;
    border: 1px solid transparent;
    border-radius: 999px;
    font: inherit;
    font-weight: 600;
    line-height: 1.2;
    text-decoration: none;
    cursor: pointer;
    transition: background-color 120ms ease, border-color 120ms ease, color 120ms ease, transform 120ms ease, box-shadow 120ms ease;
}

.btn svg { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.btn svg.icon-solid { fill: currentColor; stroke: none; }
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(1px); }
.btn:disabled, .btn[aria-disabled='true'] { opacity: 0.5; cursor: not-allowed; transform: none; }

.site .btn-primary { background: var(--accent-fill); color: var(--accent-contrast); box-shadow: 0 10px 26px var(--accent-glow); }
.site .btn-primary:hover { background: var(--accent-fill-hover); color: var(--accent-contrast); }

.site .btn-secondary { background: var(--surface-raised); border-color: var(--border); color: var(--text); }
.site .btn-secondary:hover { border-color: var(--accent); color: var(--accent); }

.site .btn-on-accent { background: #ffffff; color: var(--on-accent-ink, var(--accent-strong)); box-shadow: 0 10px 26px rgb(0 0 0 / 12%); }
.site .btn-on-accent:hover { background: rgb(255 255 255 / 90%); color: var(--on-accent-ink, var(--accent-strong)); }

.btn-sm { min-height: 40px; padding: 8px 20px; font-size: 0.9375rem; }

/* Header: a floating capsule */

.site-header { position: sticky; top: 0; z-index: 50; padding: 12px var(--gutter) 0; pointer-events: none; }

.site-header__inner {
    display: flex;
    align-items: center;
    gap: 20px;
    max-width: calc(var(--max-width) - 2 * var(--gutter));
    height: var(--header-height);
    margin-inline: auto;
    padding: 0 10px 0 14px;
    border: 1px solid color-mix(in srgb, var(--border) 70%, transparent);
    border-radius: 999px;
    background: color-mix(in srgb, var(--surface-raised) 78%, transparent);
    box-shadow: 0 1px 2px rgb(40 20 30 / 4%), 0 10px 30px rgb(40 20 30 / 7%);
    -webkit-backdrop-filter: saturate(170%) blur(18px);
    backdrop-filter: saturate(170%) blur(18px);
    pointer-events: auto;
}

.site .brand { display: inline-flex; align-items: center; gap: 10px; color: var(--text); font-family: var(--font-display); font-size: 1.375rem; font-weight: 500; font-variation-settings: 'SOFT' 100, 'WONK' 0; letter-spacing: -0.02em; line-height: 1; text-decoration: none; }
.brand img { width: 34px; height: 34px; border-radius: 10px; }
.brand sup { margin-left: 1px; font-family: var(--font); font-size: 0.5em; font-weight: 400; }
.brand-by { color: var(--text-muted); font-family: var(--font); font-size: var(--text-caption); font-weight: 400; letter-spacing: 0; }

.site-nav { margin-left: auto; }
.site-nav ul { display: flex; gap: 2px; margin: 0; padding: 0; list-style: none; }
.site .site-nav a, .site .site-menu a:not(.btn) {
    display: block;
    padding: 8px 14px;
    border-radius: 999px;
    color: var(--text-muted);
    font-size: 0.9375rem;
    font-weight: 500;
    text-decoration: none;
    transition: background-color 120ms ease, color 120ms ease;
}
.site .site-nav a:hover, .site .site-menu a:not(.btn):hover { background: var(--accent-soft); color: var(--accent-strong); }
.site .site-nav a[aria-current='page'], .site .site-menu a:not(.btn)[aria-current='page'] { background: var(--accent-soft); color: var(--accent-strong); font-weight: 600; }

.site-menu { display: none; position: relative; margin-left: auto; }
.site-menu summary {
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    color: var(--text);
    cursor: pointer;
    list-style: none;
}
.site-menu summary::-webkit-details-marker { display: none; }
.site-menu summary:hover { background: var(--accent-soft); }
.site-menu summary svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.site-menu .icon-close { display: none; }
.site-menu[open] .icon-open { display: none; }
.site-menu[open] .icon-close { display: block; }
.site-menu__panel {
    position: absolute;
    right: -10px;
    top: calc(100% + 16px);
    width: min(300px, calc(100vw - 2 * var(--gutter)));
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface-raised);
    box-shadow: var(--shadow-float);
    animation: menu-in 200ms ease;
}
.site-menu__panel ul { margin: 0 0 10px; padding: 0; list-style: none; }
.site .site-menu__panel a:not(.btn) { padding: 12px 16px; font-size: var(--text-body); }
.site-menu__panel .btn { width: 100%; }

@keyframes menu-in { from { opacity: 0; transform: translateY(-6px); } }

/* Sections */

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 22px;
    padding: 7px 14px 7px 12px;
    border: 1px solid color-mix(in srgb, var(--accent) 16%, transparent);
    border-radius: 999px;
    background: color-mix(in srgb, var(--surface-raised) 70%, transparent);
    color: var(--accent-strong);
    font-size: var(--text-caption);
    font-weight: 600;
    letter-spacing: 0.01em;
    line-height: 1.3;
}
.eyebrow::before { content: ''; flex: none; width: 7px; height: 7px; border-radius: 50%; background: var(--accent-fill); }

.lead { color: var(--text-muted); font-size: var(--text-title); line-height: 1.6; }
h2 + .lead { margin-top: 20px; }
.muted { color: var(--text-muted); }
.caption { color: var(--text-muted); font-size: var(--text-caption); }

.hero { display: grid; grid-template-columns: 1.05fr 0.95fr; align-items: center; gap: 48px; padding-block: 72px 96px; }
.hero h1 { margin-bottom: 26px; }
.hero .lead { max-width: 32em; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 34px; }
.hero-note { margin-top: 16px; }

.section { padding-block: 104px; }
.section--tinted { margin-inline: 12px; border-radius: var(--radius-lg); background: var(--surface); }
.section-heading { max-width: 700px; margin-bottom: 52px; }
.section-heading--center { margin-inline: auto; text-align: center; }
.section-heading h2 + p { margin-top: 18px; }

.card { padding: 30px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface-raised); }
.section--tinted .card { border-color: transparent; }

/* Features: a bento grid of pastel cards */

.feature-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 16px; }
.feature { display: flex; flex-direction: column; grid-column: span 2; min-height: 236px; padding: 28px; border: 0; border-radius: var(--radius); background: var(--tone); transition: transform 200ms ease; }
.feature:hover { transform: translateY(-3px); }
.feature--span-3 { grid-column: span 3; }
.feature--span-4 { grid-column: span 4; }
.site .feature h3 { margin: auto 0 8px; padding-top: 36px; font-family: var(--font-display); font-size: 1.625rem; font-weight: 400; font-variation-settings: 'SOFT' 100, 'WONK' 0; letter-spacing: -0.02em; }
.feature p { max-width: 30em; color: var(--text-muted); }

.tone-1 { --tone: var(--tone-1); --tone-ink: var(--tone-1-ink); }
.tone-2 { --tone: var(--tone-2); --tone-ink: var(--tone-2-ink); }
.tone-3 { --tone: var(--tone-3); --tone-ink: var(--tone-3-ink); }
.tone-4 { --tone: var(--tone-4); --tone-ink: var(--tone-4-ink); }

.icon-badge { display: grid; place-items: center; flex: none; width: 52px; height: 52px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); }
.feature .icon-badge { background: var(--tone-badge); color: var(--tone-ink); }
.icon-badge svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

.split { display: grid; grid-template-columns: 1fr 1fr; align-items: start; gap: 64px; }

.steps { display: grid; margin: 0; padding: 0; list-style: none; counter-reset: step; }
.steps li { position: relative; padding: 26px 0 26px 76px; border-top: 1px solid var(--border); counter-increment: step; }
.steps li:first-child { padding-top: 6px; border-top: 0; }
.steps li:last-child { padding-bottom: 0; }
.steps li::before {
    content: '0' counter(step);
    position: absolute;
    left: 0;
    top: 20px;
    color: var(--accent);
    font-family: var(--font-display);
    font-size: 2.25rem;
    font-style: italic;
    font-weight: 300;
    font-variation-settings: 'SOFT' 100, 'WONK' 0;
    line-height: 1.1;
}
.steps li:first-child::before { top: 0; }
.steps h3 { margin-bottom: 6px; }
.steps p { color: var(--text-muted); }

.note { margin-top: 28px; padding: 16px 20px; border-radius: var(--radius-sm); background: var(--accent-soft); color: var(--text-muted); font-size: var(--text-caption); }

.cta-band { position: relative; overflow: hidden; margin-top: 104px; padding: 88px 32px; border-radius: var(--radius-lg); background: var(--accent-gradient); color: #ffffff; text-align: center; isolation: isolate; }
.cta-band::before, .cta-band::after { content: ''; position: absolute; z-index: -1; border-radius: 50%; background: rgb(255 255 255 / 14%); filter: blur(4px); }
.cta-band::before { width: 420px; height: 420px; left: -140px; top: -220px; }
.cta-band::after { width: 520px; height: 520px; right: -200px; bottom: -340px; }
.site .cta-band h2 { color: #ffffff; }
.site .cta-band h2 em { background: none; color: inherit; }
.cta-band p { max-width: 36em; margin: 16px auto 0; color: rgb(255 255 255 / 90%); }
.cta-band .hero-actions { justify-content: center; }
.cta-band__icon { width: 84px; height: 84px; margin-bottom: 26px; border-radius: 22px; box-shadow: 0 14px 34px rgb(0 0 0 / 22%); }
.cta-band .caption { color: rgb(255 255 255 / 86%); }

/* Footer */

.site-footer { margin: 104px 12px 12px; padding-block: 56px 36px; border-radius: var(--radius-lg); background: var(--surface); color: var(--text-muted); font-size: 0.9375rem; }
.site-footer__inner { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 28px; }
.site-footer .brand { margin-bottom: 10px; }
.site-footer nav ul { display: flex; flex-wrap: wrap; gap: 8px 24px; margin: 0; padding: 0; list-style: none; }
.site .site-footer nav a { color: var(--text-muted); font-weight: 500; text-decoration: none; }
.site .site-footer nav a:hover { color: var(--accent); }
.site-footer__copyright { width: 100%; margin-top: 12px; padding-top: 22px; border-top: 1px solid var(--border); font-size: var(--text-caption); }

/* Single-message pages: download placeholder, not found, support */

.message { display: grid; justify-items: center; gap: 4px; max-width: 600px; min-height: 62vh; margin-inline: auto; padding: 88px var(--gutter) 40px; text-align: center; align-content: center; }
.message img { width: 116px; height: 116px; margin-bottom: 28px; border-radius: 28px; box-shadow: 0 18px 44px var(--accent-glow); }
.message h1 { margin-bottom: 16px; font-size: var(--text-heading); line-height: 1.08; }
.message .hero-actions { justify-content: center; }

/* Long-form pages: privacy, terms, press */

.page-header { padding-block: 72px 36px; }
.page-header h1 { font-size: var(--text-heading); line-height: 1.08; }
.page-header .lead { max-width: 38em; margin-top: 16px; }

.prose { max-width: 760px; }

.legal { max-width: 760px; padding-bottom: 24px; }
.legal h2 { margin: 0 0 24px; font-size: var(--text-heading); }
.legal h3 { margin: 40px 0 12px; }
.legal p, .legal li { color: var(--text-muted); }
.legal b, .legal .strong { color: var(--text); font-weight: 600; }
.legal ol { margin: 0 0 16px; padding-left: 0; list-style: none; counter-reset: item; }
.legal li ol { padding-left: 1.25em; }
.legal li { padding: 6px 0; }
.legal li::before { content: counters(item, '.') '. '; counter-increment: item; padding-right: 6px; color: var(--text); font-weight: 600; }
.legal .topList > li { margin-top: 20px; }
.legal-section { display: inline; color: var(--text); font-size: var(--text-title); font-weight: 600; }
.legal .gray { color: var(--text-muted); font-size: var(--text-caption); }
.legal .mt-sm { margin-top: 8px; }
.legal .mt { margin-top: 14px; }
.legal .mt-lg { margin-top: 32px; }
.legal .inline { display: inline; }

.gtranslate, .gtranslate-mobile { display: flex; justify-content: flex-end; min-height: 28px; margin-bottom: 8px; }

.bare-page { padding-block: 24px 40px; }

/* Floating chips used in hero artwork */

.chip {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 18px 12px 12px;
    border: 1px solid color-mix(in srgb, var(--border) 60%, transparent);
    border-radius: 20px;
    background: color-mix(in srgb, var(--surface-raised) 88%, transparent);
    box-shadow: var(--shadow-float);
    -webkit-backdrop-filter: blur(14px);
    backdrop-filter: blur(14px);
    color: var(--text);
    font-size: 0.9375rem;
    font-weight: 600;
    line-height: 1.25;
    text-align: left;
}
.chip small { display: block; color: var(--text-muted); font-size: var(--text-caption); font-weight: 400; }
.chip .icon-badge { width: 40px; height: 40px; }
.chip .icon-badge svg { width: 20px; height: 20px; }

/* Responsive */

@media (max-width: 960px) {
    .hero { grid-template-columns: 1fr; gap: 56px; padding-block: 48px 72px; text-align: center; }
    .hero .lead { margin-inline: auto; }
    .hero-actions { justify-content: center; }
    .split { grid-template-columns: 1fr; gap: 44px; }
    .feature-grid { grid-template-columns: repeat(2, 1fr); }
    .feature, .feature--span-3, .feature--span-4 { grid-column: span 1; }
    .feature:last-child:nth-child(odd) { grid-column: span 2; }
}

@media (max-width: 760px) {
    :root { --radius-lg: 30px; }
    .site-nav, .site-header__cta, .brand-by { display: none; }
    .site-menu { display: block; }
    .site-header__inner { padding-right: 8px; }
    .section { padding-block: 72px; }
    .section--tinted { margin-inline: 8px; }
    .section-heading { margin-bottom: 36px; }
    .cta-band { margin-top: 72px; padding: 64px 22px; }
    .site-footer { margin: 72px 8px 8px; }
    .page-header { padding-block: 44px 20px; }
}

@media (max-width: 600px) {
    .feature-grid { grid-template-columns: 1fr; }
    .feature, .feature:last-child:nth-child(odd) { grid-column: span 1; min-height: 0; }
}

@media (max-width: 420px) {
    .hero-actions .btn { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
}
