/* Public site (landing, policy pages, account deletion).
   Hand-written, no build step. Tokens follow the app's design system "Warm Editorial Romance"
   (stitch/DESIGN.md, crushly_app/lib/core/theme/tokens.dart): warm ivory canvas, white surfaces,
   deep plum structure, raspberry reserved for the primary action, Manrope throughout. */

@font-face {
    font-family: 'Manrope';
    src: url('../fonts/manrope/Manrope.ttf') format('truetype');
    font-weight: 200 800;
    font-style: normal;
    font-display: swap;
}

:root {
    color-scheme: light;
    --canvas: #fff8f5;
    --surface: #ffffff;
    --surface-low: #fdf1ee;
    --ink: #24212a;
    --ink-soft: #594044;
    --muted: #6f6a76;
    --plum: #352238;
    --primary: #b11b4c;
    --primary-press: #900039;
    --raspberry: #e74772;
    --rose: #f8e3e9;
    --line: #f0dce2;
    --success: #1b7a52;
    --danger: #b3261e;
    --r-md: 12px;
    --r-lg: 16px;
    --r-xl: 24px;
    --shadow-1: 0 4px 20px -2px rgba(53, 34, 56, .05), 0 2px 6px -1px rgba(53, 34, 56, .03);
    --shadow-2: 0 12px 32px -4px rgba(53, 34, 56, .10), 0 4px 12px -2px rgba(53, 34, 56, .04);
    --shadow-cta: 0 8px 24px -2px rgba(177, 27, 76, .25);
    --wrap: 70rem;
    --gutter: clamp(1rem, 4vw, 2rem);
}

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

html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 5rem; }

body {
    margin: 0;
    background: var(--canvas);
    color: var(--ink);
    font: 400 1rem/1.625 'Manrope', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
    -webkit-font-smoothing: antialiased;
}

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

a { color: var(--primary); text-underline-offset: .18em; text-decoration-thickness: .08em; }
a:hover { color: var(--primary-press); }

:focus-visible { outline: 3px solid var(--plum); outline-offset: 3px; border-radius: 6px; }

h1, h2, h3 { color: var(--plum); text-wrap: balance; margin: 0; }

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

.skip {
    position: absolute; left: 1rem; top: -4rem; z-index: 100;
    padding: .75rem 1.1rem; border-radius: 999px; background: var(--plum); color: #fff; font-weight: 600; text-decoration: none;
}
.skip:focus { top: 1rem; color: #fff; }

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

/* ---------- Header ---------- */

.site-header {
    position: sticky; top: 0; z-index: 50;
    background: rgba(255, 248, 245, .9);
    -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--line);
}
.site-header .wrap { display: flex; align-items: center; gap: 1rem; min-height: 4rem; }
.brand { display: inline-flex; align-items: center; gap: .6rem; color: var(--plum); text-decoration: none; font-weight: 800; font-size: 1.25rem; letter-spacing: -.03em; }
.brand:hover { color: var(--plum); }
.brand img { width: 36px; height: 36px; }
.site-nav { margin-left: auto; display: flex; align-items: center; gap: .25rem; }
.site-nav a { padding: .6rem .8rem; border-radius: 999px; color: var(--ink-soft); font-weight: 600; font-size: .9rem; text-decoration: none; }
.site-nav a:hover { background: var(--rose); color: var(--plum); }
.site-nav a[aria-current='page'] { color: var(--plum); background: var(--rose); }
.age-pill {
    display: inline-flex; align-items: center; height: 1.75rem; padding: 0 .6rem; border-radius: 999px;
    background: var(--plum); color: #fff; font-size: .72rem; font-weight: 700; letter-spacing: .06em; white-space: nowrap;
}
@media (max-width: 47.99rem) {
    .site-nav a.nav-optional { display: none; }
}

/* ---------- Buttons, chips ---------- */

.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
    min-height: 3.25rem; padding: .75rem 1.6rem; border: 0; border-radius: 999px;
    font: inherit; font-weight: 700; font-size: .95rem; letter-spacing: .01em; text-decoration: none; cursor: pointer;
    transition: transform .15s ease, background-color .15s ease, box-shadow .15s ease;
}
.btn:active { transform: scale(.97); }
.btn-primary { background: var(--primary); color: #fff; box-shadow: var(--shadow-cta); }
.btn-primary:hover { background: var(--primary-press); color: #fff; }
.btn-soft { background: var(--rose); color: var(--plum); }
.btn-soft:hover { background: #f3d3dc; color: var(--plum); }
.btn svg { width: 1.25rem; height: 1.25rem; flex: none; }

.chip {
    display: inline-flex; align-items: center; min-height: 2.1rem; padding: .35rem .95rem; border-radius: 999px;
    background: var(--rose); color: var(--plum); font-size: .78rem; font-weight: 600; letter-spacing: .02em;
}
.eyebrow { display: block; margin-bottom: .9rem; color: var(--primary); font-size: .72rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }

/* ---------- Landing: hero ---------- */

.hero { padding-block: clamp(2.5rem, 7vw, 5.5rem) clamp(3rem, 7vw, 5rem); }
.hero .wrap { display: grid; gap: clamp(2.5rem, 6vw, 4rem); align-items: center; }
@media (min-width: 60rem) { .hero .wrap { grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); } }
.hero-wordmark { width: min(15rem, 60%); margin-bottom: 1.5rem; }
.hero h1 { font-size: clamp(2.25rem, 5.4vw, 3.6rem); font-weight: 800; line-height: 1.08; letter-spacing: -.035em; }
.hero h1 em { font-style: normal; color: var(--primary); }
.lede { margin: 1.4rem 0 0; max-width: 34rem; color: var(--ink-soft); font-size: clamp(1.05rem, 1.6vw, 1.2rem); line-height: 1.6; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 2rem; }
.hero-note { margin: 1.25rem 0 0; color: var(--muted); font-size: .88rem; max-width: 32rem; }

/* Illustrative app fragments: real prompt and interest names from the app's catalogue, no people. */
.scene { position: relative; max-width: 24rem; margin-inline: auto; width: 100%; padding: 1rem 0 1rem 1.5rem; }
.scene::before {
    content: ''; position: absolute; inset: 0 2.5rem 3rem 0; border-radius: 2.5rem;
    background: linear-gradient(140deg, #e8265c 0%, #c2255f 55%, #8f2a78 100%); transform: rotate(-4deg);
}
.card { position: relative; background: var(--surface); border-radius: var(--r-xl); box-shadow: var(--shadow-2); padding: 1.25rem; }
.card + .card { margin-top: 1rem; }
.card-label { display: block; color: var(--muted); font-size: .72rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.card-title { margin: .35rem 0 0; color: var(--plum); font-size: 1.15rem; font-weight: 700; line-height: 1.35; letter-spacing: -.015em; }
.card .chips { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .9rem; }
.badge-ok { display: inline-flex; align-items: center; gap: .35rem; height: 1.6rem; padding: 0 .65rem; border-radius: 999px; background: rgba(27, 122, 82, .1); color: var(--success); font-size: .7rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.badge-ok svg { width: .85rem; height: .85rem; }
.card-shift { margin-left: 2rem; }
.checkin-options { display: grid; gap: .45rem; margin-top: .9rem; }
.checkin-options span { display: flex; align-items: center; min-height: 2.6rem; padding: 0 1rem; border-radius: var(--r-lg); border: 1px solid var(--line); color: var(--plum); font-size: .88rem; font-weight: 600; }
.checkin-options span:first-child { background: var(--plum); border-color: var(--plum); color: #fff; }

/* ---------- Landing: sections ---------- */

.section { padding-block: clamp(3rem, 7vw, 5.5rem); }
.section-alt { background: var(--surface); border-block: 1px solid var(--line); }
.section-head { max-width: 40rem; margin-bottom: clamp(2rem, 4vw, 3rem); }
.section-head h2 { font-size: clamp(1.7rem, 3.4vw, 2.4rem); font-weight: 800; line-height: 1.15; letter-spacing: -.03em; }
.section-head p { margin: 1rem 0 0; color: var(--ink-soft); font-size: 1.05rem; }

.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; counter-reset: step; }
.steps li { counter-increment: step; display: grid; grid-template-columns: 3.5rem minmax(0, 1fr); gap: 0 1rem; padding: 1.5rem 0; border-top: 1px solid var(--line); }
.steps li:last-child { border-bottom: 1px solid var(--line); }
.steps li::before { content: counter(step, decimal-leading-zero); grid-row: span 2; color: var(--raspberry); font-size: 1.5rem; font-weight: 800; letter-spacing: -.03em; line-height: 1.3; font-variant-numeric: tabular-nums; }
.steps h3 { font-size: 1.2rem; font-weight: 700; letter-spacing: -.015em; }
.steps p { margin: .35rem 0 0; color: var(--ink-soft); max-width: 44rem; }
@media (min-width: 60rem) {
    .steps li { grid-template-columns: 5rem 16rem minmax(0, 1fr); align-items: baseline; }
    .steps li::before { grid-row: auto; font-size: 1.75rem; }
    .steps p { margin: 0; }
}

.safety-grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 17rem), 1fr)); }
.safety-item { background: var(--canvas); border-radius: var(--r-xl); padding: 1.5rem; }
.safety-item svg { width: 1.75rem; height: 1.75rem; color: var(--primary); }
.safety-item h3 { margin-top: .9rem; font-size: 1.1rem; font-weight: 700; letter-spacing: -.01em; }
.safety-item p { margin: .45rem 0 0; color: var(--ink-soft); font-size: .95rem; }

.limits { margin-top: 2rem; padding: 1.5rem; border-radius: var(--r-xl); background: var(--plum); color: #f5eefb; }
.limits h3 { color: #fff; font-size: 1.1rem; font-weight: 700; }
.limits ul { margin: .75rem 0 0; padding-left: 1.2rem; }
.limits li + li { margin-top: .35rem; }
.limits a { color: #ffd9de; }
.limits a:hover { color: #fff; }
.limits :focus-visible { outline-color: #fff; }

.split { display: grid; gap: clamp(1.5rem, 4vw, 3rem); }
@media (min-width: 60rem) { .split { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: start; } }
.facts { list-style: none; margin: 0; padding: 0; }
.facts li { display: grid; grid-template-columns: 1.5rem minmax(0, 1fr); gap: .75rem; padding: .9rem 0; border-top: 1px solid var(--line); color: var(--ink-soft); }
.facts li:last-child { border-bottom: 1px solid var(--line); }
.facts svg { width: 1.25rem; height: 1.25rem; margin-top: .2rem; color: var(--success); }
.facts strong { color: var(--plum); }

.download { background: var(--surface); border-radius: var(--r-xl); box-shadow: var(--shadow-1); padding: clamp(1.5rem, 4vw, 2.5rem); display: grid; gap: 2rem; }
@media (min-width: 60rem) { .download { grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); align-items: center; } }
.download h2 { font-size: clamp(1.6rem, 3vw, 2.1rem); font-weight: 800; letter-spacing: -.03em; line-height: 1.15; }
.download p { color: var(--ink-soft); margin: .9rem 0 0; }
.download .btn { margin-top: 1.5rem; }
.download small { display: block; margin-top: .9rem; color: var(--muted); font-size: .85rem; }
.soon { margin-top: 1.5rem; display: inline-flex; align-items: center; min-height: 3.25rem; padding: .75rem 1.4rem; border-radius: 999px; border: 1px dashed #d9b9c3; color: var(--ink-soft); font-weight: 600; }
.stores { list-style: none; margin: 0; padding: 0; }
.stores li { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: 1rem 0; border-top: 1px solid var(--line); font-weight: 600; color: var(--plum); }
.stores li:last-child { border-bottom: 1px solid var(--line); }
.stores span { color: var(--muted); font-weight: 600; font-size: .85rem; }

/* ---------- Policy pages and account deletion ---------- */

.doc { padding-block: clamp(2rem, 5vw, 3.5rem) clamp(3rem, 6vw, 5rem); }
.doc-inner { max-width: 46rem; margin-inline: auto; }
.doc-head { margin-bottom: 1.75rem; }
.doc-head h1, .doc-inner > h1 { font-size: clamp(1.9rem, 4.4vw, 2.75rem); font-weight: 800; line-height: 1.12; letter-spacing: -.03em; }
.doc-meta { margin: .9rem 0 0; color: var(--muted); font-size: .88rem; }
.crumb { display: inline-block; margin-bottom: 1.25rem; font-size: .88rem; font-weight: 600; text-decoration: none; }
.crumb:hover { text-decoration: underline; }

.sheet { background: var(--surface); border-radius: var(--r-xl); box-shadow: var(--shadow-1); padding: clamp(1.25rem, 4vw, 2.5rem); }
.prose > :first-child { margin-top: 0; }
.prose > :last-child { margin-bottom: 0; }
.prose h2 { margin: 2.25rem 0 .75rem; font-size: 1.35rem; font-weight: 700; line-height: 1.3; letter-spacing: -.015em; }
.prose h3 { margin: 1.75rem 0 .5rem; font-size: 1.1rem; font-weight: 700; letter-spacing: -.01em; }
.prose p, .prose ul, .prose ol { margin: 0 0 1rem; }
.prose ul, .prose ol { padding-left: 1.25rem; }
.prose li + li { margin-top: .4rem; }
.prose li::marker { color: var(--raspberry); }
.prose strong { color: var(--plum); font-weight: 700; }
.prose a { overflow-wrap: anywhere; }
.prose blockquote { margin: 0 0 1rem; padding: .9rem 1.1rem; border-left: 3px solid var(--raspberry); background: var(--canvas); border-radius: 0 var(--r-md) var(--r-md) 0; }
.prose table { display: block; width: 100%; overflow-x: auto; border-collapse: collapse; margin: 0 0 1.25rem; font-size: .94rem; }
.prose th, .prose td { text-align: left; vertical-align: top; padding: .7rem .9rem .7rem 0; border-bottom: 1px solid var(--line); min-width: 9rem; }
.prose th { color: var(--plum); font-size: .75rem; letter-spacing: .06em; text-transform: uppercase; }
.prose hr { border: 0; border-top: 1px solid var(--line); margin: 2rem 0; }
mark.pending { background: #fff1c9; color: #5c4300; padding: .05em .4em; border-radius: 6px; font-weight: 600; white-space: nowrap; }

.doc-foot { margin-top: 1.5rem; color: var(--muted); font-size: .88rem; }

.callout { margin: 0 0 1.5rem; padding: 1rem 1.15rem; border-radius: var(--r-lg); background: var(--canvas); border: 1px solid var(--line); }
.callout > :last-child { margin-bottom: 0; }
.keep-table { width: 100%; border-collapse: collapse; margin: 0 0 1.25rem; font-size: .94rem; }
.keep-table th, .keep-table td { text-align: left; vertical-align: top; padding: .75rem .9rem .75rem 0; border-bottom: 1px solid var(--line); }
.keep-table thead th { color: var(--plum); font-size: .75rem; letter-spacing: .06em; text-transform: uppercase; }
.keep-table tbody th { font-weight: 600; color: var(--ink); }
.keep-table td { color: var(--ink-soft); }
@media (max-width: 40rem) {
    .keep-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
    .keep-table tr { display: block; padding: .75rem 0; border-bottom: 1px solid var(--line); }
    .keep-table th, .keep-table td { display: block; padding: 0; border: 0; }
    .keep-table td { margin-top: .25rem; }
}
.timeline { list-style: none; margin: 0 0 1.25rem; padding: 0; }
.timeline li { position: relative; padding: 0 0 1.1rem 1.75rem; }
.timeline li::before { content: ''; position: absolute; left: .3rem; top: .55rem; width: .6rem; height: .6rem; border-radius: 50%; background: var(--raspberry); }
.timeline li::after { content: ''; position: absolute; left: .56rem; top: 1.3rem; bottom: 0; width: 2px; background: var(--line); }
.timeline li:last-child { padding-bottom: 0; }
.timeline li:last-child::after { display: none; }
.timeline strong { display: block; color: var(--plum); }

/* Forms (account deletion). Element selectors on purpose: the form markup stays plain. */
.sheet form { margin: 0 0 1rem; }
.sheet label { display: block; margin: 1.1rem 0 .4rem; color: var(--plum); font-weight: 600; font-size: .92rem; }
.sheet input:not([type='hidden']):not([type='checkbox']):not([type='radio']), .sheet select, .sheet textarea {
    width: 100%; min-height: 3.25rem; padding: .8rem 1rem; font: inherit; color: var(--ink);
    background: var(--surface); border: 1px solid #d9b9c3; border-radius: var(--r-lg);
}
.sheet input:focus-visible, .sheet select:focus-visible, .sheet textarea:focus-visible { outline: 0; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(177, 27, 76, .22); }
.sheet button {
    display: inline-flex; align-items: center; justify-content: center; min-height: 3.25rem; margin-top: 1.25rem; padding: .75rem 1.6rem;
    border: 0; border-radius: 999px; background: var(--primary); color: #fff; font: inherit; font-weight: 700; font-size: .95rem; cursor: pointer;
}
.sheet button:hover { background: var(--primary-press); }
.sheet button:disabled { opacity: .55; cursor: not-allowed; }
.sheet button.link { min-height: 2.75rem; margin-top: .25rem; padding: 0; background: none; color: var(--primary); font-weight: 600; text-decoration: underline; border-radius: 6px; }
.sheet button.link:hover { background: none; color: var(--primary-press); }
.error { margin: .45rem 0 0; color: var(--danger); font-weight: 600; font-size: .92rem; }
.muted { color: var(--muted); font-size: .92rem; }
.notice { padding: 1rem 1.15rem; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--canvas); }
.notice > :first-child { margin-top: 0; }
.notice > :last-child { margin-bottom: 0; }

/* ---------- Footer ---------- */

.site-footer { background: var(--plum); color: #dccfe0; padding-block: clamp(2.5rem, 6vw, 4rem) 2rem; font-size: .92rem; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; color: #fff; }
.site-footer :focus-visible { outline-color: #fff; }
.footer-grid { display: grid; gap: 2rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 12rem), 1fr)); }
.footer-brand { display: flex; align-items: center; gap: .6rem; color: #fff; font-weight: 800; font-size: 1.2rem; letter-spacing: -.03em; }
.footer-brand img { width: 32px; height: 32px; }
.footer-grid p { margin: .9rem 0 0; max-width: 20rem; }
.footer-grid h2 { color: #fff; font-size: .72rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.footer-grid ul { list-style: none; margin: .9rem 0 0; padding: 0; }
.footer-grid li + li { margin-top: .15rem; }
.footer-grid li a { display: inline-block; padding: .3rem 0; }
.footer-base { margin-top: 2.5rem; padding-top: 1.5rem; border-top: 1px solid rgba(255, 255, 255, .16); display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; justify-content: space-between; color: #c9b9ce; font-size: .85rem; }
.footer-base p { margin: 0; }
.footer-contact { margin-top: 2.5rem; padding-top: 1.5rem; border-top: 1px solid rgba(255, 255, 255, .16); display: flex; flex-wrap: wrap; align-items: baseline; gap: .35rem 1.5rem; font-style: normal; }
.footer-contact-label { color: #fff; font-size: .72rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.footer-contact a { padding: .3rem 0; }
.footer-contact + .footer-base { margin-top: 1.25rem; }

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { transition: none !important; animation: none !important; }
    .btn:active { transform: none; }
}

@media print {
    .site-header, .site-footer, .skip, .crumb { display: none; }
    body { background: #fff; }
    .sheet { box-shadow: none; padding: 0; }
}

/* Late additions */
main:focus { outline: none; }
.prose h1 { font-size: clamp(1.9rem, 4.4vw, 2.75rem); font-weight: 800; line-height: 1.12; letter-spacing: -.03em; margin: 0 0 1rem; }
.sheet + .sheet { margin-top: 1.25rem; }
.sheet > h2:first-child { margin-top: 0; }
.site-nav a { white-space: nowrap; }
.safety-item { background: var(--surface); box-shadow: var(--shadow-1); }
@media (max-width: 26rem) { .site-nav a { padding-inline: .55rem; } .site-header .wrap { gap: .5rem; } }
