/* ============================================================
   SITE V2 PUBLIC PAGES
   Tokens and patterns from docs/design/site-v2 (HANDOFF §4): red band with a charcoal,
   red-embossed headline; white cards whose first one rises into the band; uppercase grey
   card headings with the last word red; charcoal call-to-action buttons.
   Scoped under .site-page so older pages are untouched until they move over.
   ============================================================ */

.site-page {
    --site-red: #a43337;
    --site-red-accent: #c54549;
    --site-red-dark: #7d2629;
    --site-red-tint: #fdf2f2;
    --site-ink: #282828;
    --site-text: #4a4a4a;
    --site-muted: #6b6b6b;
    --site-heading: #737373;
    --site-bg: #f0f0f0;
    --site-line: #ececec;
    --site-shadow: 0 1px 2px rgba(0, 0, 0, .06), 0 4px 16px rgba(0, 0, 0, .05);
    --site-blue: #3b7dd8;

    font-family: 'Helvetica Neue', 'Lucida Grande', Helvetica, sans-serif;
    font-size: 15px;
    line-height: 1.6;
    color: var(--site-text);
    background: var(--site-bg);
    padding-bottom: 8px;
}

.site-page *, .site-page *::before, .site-page *::after { box-sizing: border-box; }
.site-page a { color: var(--site-red); }
.site-page a:hover { color: var(--site-red-dark); }
.site-page a.dv2-btn-primary, .site-page a.dv2-btn-primary:hover { color: var(--dv2-primary-ink); text-decoration: none; }
.site-page :focus-visible { outline: 3px solid var(--site-red); outline-offset: 2px; }

/* ── Band ─────────────────────────────────────────────────── */
.site-band { background: var(--site-red); padding: 48px 0 96px; }
.site-band.no-overlap { padding-bottom: 48px; }
.site-band-eyebrow { margin: 0 0 6px; font-size: 12px; font-weight: bold; letter-spacing: .08em; text-transform: uppercase; color: #f6dfe0; }
.site-band h1 { margin: 0; font-size: 44px; line-height: 1.1; font-weight: bold; color: var(--site-ink); text-shadow: 0 1px 1px var(--site-red-accent); letter-spacing: -1px; }
.site-band-tagline { margin: 10px 0 0; font-size: 18px; color: #f6dfe0; }

/* ── Cards ────────────────────────────────────────────────── */
.site-cards { position: relative; max-width: 780px; margin: -48px auto 0; padding: 0 16px; display: flex; flex-direction: column; gap: 24px; }
.site-cards.wide { max-width: 860px; }
.site-band.no-overlap + .site-cards { margin-top: 24px; }
.site-card { background: #fff; border-radius: 16px; box-shadow: var(--site-shadow); padding: 28px; min-width: 0; }
.site-card-title { margin: 0 0 14px; font-size: 22px; line-height: 1.25; font-weight: bold; text-transform: uppercase; color: var(--site-heading); letter-spacing: -1px; }
.site-card-title .hl { color: var(--site-red-accent); }
.site-card p { margin: 0 0 12px; }
.site-card p:last-child { margin-bottom: 0; }
.site-grid-2 { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px; }

/* ── Buttons and links ────────────────────────────────────── */
.site-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 22px; border: none; border-radius: 12px; background: var(--site-ink); color: #fff !important; font-size: 15px; font-weight: bold; text-decoration: none; cursor: pointer; }
.site-btn:hover { background: #000; color: #fff !important; }
.site-btn.ghost { background: transparent; border: 1px solid #cfcfcf; color: var(--site-ink) !important; }
.site-btn.ghost:hover { border-color: var(--site-red); color: var(--site-red) !important; background: transparent; }
.site-link { font-weight: bold; text-decoration: none; }
.site-link:hover { text-decoration: underline; }

/* ── Phone ────────────────────────────────────────────────── */
@media (max-width: 767.98px) {
    .site-band { padding: 32px 0 64px; }
    .site-band h1 { font-size: 32px; }
    .site-band-tagline { font-size: 16px; }
    .site-cards { margin-top: -28px; gap: 16px; }
    .site-card { padding: 22px 20px; }
    .site-card-title { font-size: 20px; }
    .site-grid-2 { grid-template-columns: minmax(0, 1fr); gap: 16px; }
    .site-btn { min-height: 48px; }
}
.site-page p, .site-page li, .site-page dd { color: var(--site-text); }

/* ── Region map (docs/design/site-v2 §8). Global: used on public pages and in the dashboard. ── */
.rmap { width: 100%; font-family: 'Helvetica Neue', 'Lucida Grande', Helvetica, sans-serif; color: #282828; }
.rmap-figure { position: relative; margin: 0; border-radius: 12px; background: #f7f7f7; overflow: hidden; }
.rmap-svg { display: block; width: 100%; height: auto; }
.rmap-zone { fill: none; stroke-width: 5.5; stroke-linecap: round; }
.rmap-zone.none { stroke: #e6e6e6; }
.rmap-zone.blue { stroke: #3b7dd8; }
.rmap-zone.red { stroke: #a43337; }
.rmap-zone.soft { stroke: #9cc0ee; }
.rmap-zone.grey { stroke: #6f6f6f; }
.rmap-pin { position: absolute; width: 0; height: 0; }
.rmap-dot { position: absolute; left: 0; top: 0; transform: translate(-50%, -50%); box-sizing: border-box; border-radius: 50%; width: 16px; height: 16px; border: 3px solid #fff; box-shadow: 0 1px 3px rgba(0,0,0,.3); }
.rmap-dot.blue { background: #3b7dd8; }
.rmap-dot.red { background: #a43337; }
.rmap-dot.soft { background: #9cc0ee; }
.rmap-dot.grey { background: #6f6f6f; }
.rmap-dot.home-status, .rmap-dot.home-create { width: 26px; height: 26px; background: #fff; border: 5px solid #282828; box-shadow: 0 0 0 3px #fff; }
.rmap-dot.home-create { border-color: #a43337; }
@keyframes rmap-ping { 0% { transform: translate(-50%, -50%) scale(.7); opacity: .9; } 100% { transform: translate(-50%, -50%) scale(2.1); opacity: 0; } }
.rmap-pulse { position: absolute; left: 0; top: 0; width: 34px; height: 34px; border-radius: 50%; border: 3px solid #a43337; box-sizing: border-box; transform: translate(-50%, -50%); animation: rmap-ping 2.2s ease-out infinite; }
.rmap-pulse.ink { border-color: #282828; }
@media (prefers-reduced-motion: reduce) { .rmap-pulse { animation: none; opacity: .5; } }
.rmap-label { position: absolute; top: 0; left: 22px; transform: translateY(-50%); white-space: nowrap; background: rgba(255,255,255,.94); border-radius: 8px; padding: 4px 9px; box-shadow: 0 1px 4px rgba(0,0,0,.12); line-height: 1.25; }
.rmap-label.left { left: auto; right: 22px; text-align: right; }
.rmap-label.ring-ink { outline: 2px solid #282828; }
.rmap-label.ring-red { outline: 2px solid #a43337; }
.rmap-label strong { display: block; font-size: 15px; color: #282828; }
.rmap-sub { font-size: 12px; font-weight: bold; }
.rmap-sub.blue { color: #084298; }
.rmap-sub.red { color: #a43337; }
.rmap-sub.ink { color: #282828; }
.rmap-sub.muted { color: #6b6b6b; }
.rmap-legend { display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 10px; font-size: 13px; color: #4a4a4a; }
.rmap-legend > span { display: inline-flex; align-items: center; gap: 6px; }
.rmap-swatch { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }
.rmap-swatch.blue { background: #3b7dd8; }
.rmap-swatch.red { background: #a43337; }
.rmap-swatch.soft { background: #9cc0ee; }
.rmap-swatch.grey { background: #6f6f6f; }
.rmap-swatch.home { background: #fff; box-sizing: border-box; border: 3px solid #282828; }

/* ── Home ─────────────────────────────────────────────────── */
.home-hero { padding: 56px 0 96px; }
.home-hero-inner { display: flex; align-items: center; gap: 40px; }
.home-hero-text { flex: 1; min-width: 0; }
.home-hero h1 { font-size: 46px; }
.home-hero-art { flex: none; width: 240px; height: auto; }
.home-cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.home-cta, .home-cta-dark { min-height: 52px; padding: 0 26px; font-size: 16px; }
.home-cta-dark { margin-top: 20px; }
.home-steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 18px; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.home-steps li { display: flex; gap: 12px; align-items: flex-start; }
.home-steps .num { flex: none; width: 28px; height: 28px; border-radius: 50%; background: var(--site-red-tint); color: var(--site-red); font-weight: bold; display: flex; align-items: center; justify-content: center; font-size: 14px; }
.home-steps strong { display: block; color: var(--site-ink); }
.home-steps li span:not(.num) { display: block; font-size: 14px; color: var(--site-muted); }
.home-map { margin-top: 14px; }
.home-features { display: grid; gap: 12px; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.home-features > div { background: #f7f7f7; border-radius: 12px; padding: 16px; }
.home-features strong { display: block; color: var(--site-ink); }
.home-features span { display: block; font-size: 14px; color: var(--site-muted); }
.home-faq details { border-top: 1px solid var(--site-line); }
.home-faq summary { list-style: none; cursor: pointer; padding: 12px 0; font-weight: bold; color: var(--site-ink); display: flex; gap: 10px; align-items: center; }
.home-faq summary::-webkit-details-marker { display: none; }
.home-faq .chev { color: var(--site-red); font-size: 18px; line-height: 1; transition: transform .15s; display: inline-block; }
.home-faq details[open] .chev { transform: rotate(90deg); }
.home-faq details p { margin: 0 0 14px 22px; }
.site-page .dv2-phone-only { display: none; }
@media (max-width: 767.98px) {
    .home-hero { padding: 32px 0 56px; }
    .home-hero h1 { font-size: 32px; }
    .home-hero-art { display: none; }
    .home-cta-row { flex-direction: column; }
    .home-cta-row .site-btn, .home-cta-dark { width: 100%; }
    .home-steps, .home-features { grid-template-columns: minmax(0, 1fr); }
    .site-page .dv2-phone-only { display: block; }
    .site-page .dv2-hide-phone { display: none; }
}
.site-page .site-band p.site-band-tagline, .site-page .site-band .site-band-eyebrow { color: #f6dfe0; }

/* ── Long-form pages (rules, privacy, developer) ───────────── */
.site-subhead { margin: 20px 0 8px; font-size: 17px; font-weight: bold; color: var(--site-ink); }
.site-card-title + .site-subhead { margin-top: 0; }
.site-note { margin: 14px 0 6px; padding: 14px 16px; border-radius: 12px; background: var(--site-red-tint); border: 1px solid #e3a9ab; color: var(--site-ink); }
.site-note strong { display: block; color: var(--site-red); }
.site-card ul { margin: 0 0 12px; padding-left: 20px; }
.site-card li { margin-bottom: 4px; }
.site-meta { font-size: 13px; color: var(--site-muted); }
.site-table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.site-table { width: 100%; border-collapse: collapse; font-size: 14px; min-width: 560px; }
.site-table th, .site-table td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--site-line); vertical-align: top; }
.site-table thead th { color: var(--site-ink); font-weight: bold; border-bottom: 2px solid var(--site-line); }
.site-table tbody th { color: var(--site-ink); font-weight: bold; }
.site-table td:nth-child(2) { background: var(--site-red-tint); }

/* ── Developer docs ───────────────────────────────────────── */
.dev-layout { max-width: 1080px; margin: -48px auto 0; padding: 0 16px; display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 24px; align-items: start; position: relative; }
.dev-toc { position: sticky; top: 74px; padding: 18px 20px; display: flex; flex-direction: column; gap: 4px; }
.dev-toc-title { margin: 0 0 6px !important; font-size: 11px; font-weight: bold; letter-spacing: .08em; text-transform: uppercase; color: var(--site-muted) !important; }
.dev-toc a { color: var(--site-ink); text-decoration: none; font-size: 14px; padding: 3px 0; }
.dev-toc a:hover { color: var(--site-red); }
.dev-main { display: flex; flex-direction: column; gap: 24px; min-width: 0; }
.dev-main section { scroll-margin-top: 74px; }
.dev-code { margin: 6px 0 14px; padding: 14px 16px; border-radius: 10px; background: #282828; color: #f0f0f0; font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 13px; line-height: 1.5; overflow-x: auto; white-space: pre; }
.site-page code { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 13px; background: #f3f3f3; color: var(--site-ink); padding: 1px 5px; border-radius: 5px; }
.dev-label { margin: 10px 0 0 !important; font-size: 12px; font-weight: bold; color: var(--site-muted) !important; }
.dev-endpoint { margin: 22px 0 6px; font-size: 16px; font-family: ui-monospace, Menlo, Consolas, monospace; color: var(--site-ink); display: flex; align-items: center; gap: 8px; }
.dev-verb { font-family: 'Helvetica Neue', Helvetica, sans-serif; font-size: 11px; font-weight: bold; padding: 2px 7px; border-radius: 6px; background: #e3f5ea; color: #1f7a4c; }
.dev-verb.post { background: #e7f1ff; color: #084298; }
.dev-callout { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin: 0 0 14px; padding: 12px 16px; border-radius: 12px; background: #e7f1ff; color: #084298; font-size: 14px; }
.dev-callout code { background: rgba(255,255,255,.6); }
.dev-callout-btn { min-height: 40px; padding: 0 16px; font-size: 14px; }
.dev-table { min-width: 480px; }
.dev-table td:nth-child(2) { background: none; }
@media (max-width: 991.98px) {
    .dev-layout { grid-template-columns: minmax(0, 1fr); margin-top: -28px; }
    .dev-toc { position: static; flex-direction: row; flex-wrap: wrap; gap: 6px 14px; }
    .dev-toc-title { flex-basis: 100%; }
}

/* Dashboard controls (buttons, inputs, loaders) reused on public pages need their tokens. */
.site-page {
    --dv2-red: #a43337;
    --dv2-red-dark: #7d2629;
    --dv2-red-accent: #c54549;
    --dv2-red-tint: #fdf2f2;
    --dv2-red-border: #e3a9ab;
    --dv2-ink: #282828;
    --dv2-text: #4a4a4a;
    --dv2-muted: #6b6b6b;
    --dv2-faint: #b5b5b5;
    --dv2-bg: #f0f0f0;
    --dv2-card: #ffffff;
    --dv2-line: #ececec;
    --dv2-line-2: #e2e2e2;
    --dv2-input: #cfcfcf;
    --dv2-primary: #58cb8e;
    --dv2-primary-hover: #3dd375;
    --dv2-primary-ink: #1d1d1d;
    --dv2-ok: #2fb35f;
    --dv2-ok-text: #1f7a4c;
    --dv2-ok-tint: #e3f5ea;
    --dv2-warn-text: #7a4a00;
    --dv2-warn: #b45309;
    --dv2-warn-tint: #fff4e5;
    --dv2-amber: #e0a100;
    --dv2-info: #084298;
    --dv2-info-tint: #e7f1ff;
    --dv2-shadow: 0 1px 2px rgba(0, 0, 0, .06), 0 4px 16px rgba(0, 0, 0, .05);
    --dv2-radius-card: 16px;
    --dv2-radius: 10px;
}

.home-all-full { margin: 14px 0 0; color: var(--site-red); font-weight: bold; }

/* ── Create server ────────────────────────────────────────── */
.site-card-title.plain-title { text-transform: none; color: var(--site-ink); letter-spacing: -0.5px; }
.site-page .mono { font-family: ui-monospace, Menlo, Consolas, monospace; }
.create-pick { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-top: 14px; }
.create-pick-item { text-align: left; padding: 16px; border: 1px solid #cfcfcf; border-radius: 12px; background: #fff; cursor: pointer; font-family: inherit; }
.create-pick-item:hover:not(:disabled) { border-color: var(--site-red); }
.create-pick-item:disabled { opacity: .5; cursor: not-allowed; }
.create-pick-item strong { display: block; color: var(--site-ink); font-size: 16px; }
.create-pick-item span { display: block; font-size: 13px; color: var(--site-muted); }
.create-check { display: flex; align-items: center; gap: 16px; padding: 16px; border-radius: 12px; background: #f7f7f7; font-size: 14px; }
.create-check .site-btn { flex: none; min-height: 44px; }
.create-notice { padding: 12px 16px; border-radius: 12px; background: #fff4e5; border: 1px solid #f0c48a; color: #7a4a00; font-size: 14px; }
.create-notice.soft { margin-top: 16px; background: #e7f1ff; border-color: #c5dbfb; color: #084298; }
.create-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; }
.create-go { height: 48px; font-size: 15px; padding: 0 22px; }
.create-hint { font-size: 14px; color: var(--site-muted); }
.create-steps { list-style: none; margin: 14px 0 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.create-steps li { position: relative; padding-left: 30px; color: var(--site-muted); }
.create-steps li::before { content: ""; position: absolute; left: 0; top: 2px; width: 20px; height: 20px; border-radius: 50%; border: 2px solid #cfcfcf; box-sizing: border-box; }
.create-steps li.active { color: var(--site-ink); font-weight: bold; }
.create-steps li.active::before { border-color: #e2e2e2; border-top-color: var(--site-red); animation: dv2-spin .8s linear infinite; }
.create-steps li.done { color: var(--site-ink); }
.create-steps li.done::before { content: "✓"; border: none; background: #2fb35f; color: #fff; font-size: 12px; font-weight: bold; display: flex; align-items: center; justify-content: center; }
.create-facts { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 6px 16px; margin: 14px 0 0; }
.create-facts dt { color: var(--site-muted); font-weight: normal; }
.create-facts dd { margin: 0; }
.create-next { list-style: none; counter-reset: step; margin: 14px 0 0; padding: 0; display: flex; flex-direction: column; gap: 14px; }
.create-next li { counter-increment: step; position: relative; padding-left: 38px; color: #4a4a4a; }
.create-next li::before { content: counter(step); position: absolute; left: 0; top: 0; width: 26px; height: 26px; border-radius: 50%; background: #fbeaea; color: var(--site-red); font-size: 13px; font-weight: bold; display: flex; align-items: center; justify-content: center; }
.create-next strong { display: block; color: var(--site-ink); }
.create-later { display: flex; align-items: center; justify-content: space-between; gap: 12px 16px; flex-wrap: wrap; margin-top: 16px; padding-top: 16px; border-top: 1px solid #e6e6e6; }
.create-later .site-btn { min-height: 44px; }
.create-ready-head { display: flex; align-items: flex-start; gap: 14px; }
.create-ready-head p { margin: 2px 0 0; color: var(--site-muted); font-size: 14px; }
.create-ok { flex: none; width: 44px; height: 44px; border-radius: 50%; background: #e3f5ea; color: #1f8a4c; font-size: 20px; font-weight: bold; display: flex; align-items: center; justify-content: center; }
.create-name { margin-top: 20px; }
.create-details { margin: 16px 0 0; padding: 6px 16px; border-radius: 12px; background: #f5f5f5; }
.create-details > div { display: flex; align-items: center; gap: 8px 16px; min-height: 52px; padding: 4px 0; }
.create-details dt { flex: 0 0 90px; color: var(--site-muted); font-weight: normal; font-size: 14px; }
.create-details dd { margin: 0; flex: 1; min-width: 0; overflow-wrap: anywhere; }
.create-details dd .mono { white-space: nowrap; }
.create-details dd.create-details-btns { flex: none; display: flex; gap: 8px; }
.create-keep { display: flex; gap: 12px; align-items: flex-start; padding: 14px 18px; border-radius: 12px; background: #fff7e8; border: 1px solid #f0c48a; color: #7a4a00; font-size: 14px; }
.create-keep p { margin: 0; }
.create-keep-icon { flex: none; font-size: 18px; line-height: 1.1; }
@media (max-width: 767.98px) {
    .create-pick { grid-template-columns: minmax(0, 1fr); }
    .create-check { flex-direction: column; align-items: flex-start; }
    .create-actions .site-btn, .create-go { width: 100%; }
    .create-later .site-btn { width: 100%; }
    .create-details > div { flex-wrap: wrap; padding: 10px 0; gap: 4px 12px; }
    .create-details > div + div { border-top: 1px solid #e6e6e6; }
    .create-details dt { flex-basis: 100%; }
}
