/* Corvela website, "Daybreak Glass" look (the same look as the app).
   A sunrise sky behind everything, frosted glass panels floating on it, a floating pill menu at the top,
   and a warm orange-to-gold gradient for the main actions. Geist font, served from this site. */

/* ---------- Fonts (self-hosted, no outside requests) ---------- */
@font-face { font-family: "Geist"; src: url("fonts/Geist-Variable.woff2") format("woff2"); font-weight: 100 900; font-style: normal; font-display: swap; }
@font-face { font-family: "Geist Mono"; src: url("fonts/GeistMono-Regular.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }

/* ---------- Colours: light ("Daybreak") ---------- */
:root {
  color-scheme: light;
  --sky1: #CFE6FF; --sky2: #FFE3CC; --sky3: #FFF4DA;
  --sun: rgba(255, 176, 120, .55);
  --card: #FFFFFF;
  --line: #E6E3DD;
  --ink: #121316;
  --ink-muted: #4F535C;
  --ink-faint: #6A6F79;
  --ink-body: #2B2D33;
  --on-ink: #FFFFFF;
  --ink-hover: #2A2C31;
  --select: #0F9E6E;
  --handle: #3DF5B0;
  --accent-text: #08694A;
  --success: #0B7A55;
  --danger: #B4381A;
  --mark: #FFF2B8;
  --hover: rgba(18, 19, 22, .05);
  --field: #FFFFFF;
  --field-line: #D9D5CE;
  --chip-bg: #F2F3F5;
  --th: #F6F4F0;
  --ok-bg: #E6F7F0;
  --err-bg: #FCEBE5;
  --tint-mint: #DDF7EC; --tint-sky: #DDEFFF; --tint-peach: #FFE6D6; --tint-lemon: #FFF3C4; --tint-lilac: #ECE6FF;
  --glass: rgba(255, 255, 255, .58);
  --glass-bar: rgba(255, 255, 255, .62);
  --glass-solid: rgba(255, 255, 255, .86);
  --glass-strong: rgba(255, 255, 255, .96);
  --glass-line: rgba(255, 255, 255, .85);
  --glass-shadow: 0 1px 0 rgba(255, 255, 255, .6) inset, 0 22px 50px -26px rgba(70, 45, 20, .38);
  --window-shadow: 0 30px 70px -30px rgba(60, 40, 20, .5);
  --menu-shadow: 0 2px 4px rgba(18, 19, 22, .05), 0 24px 60px rgba(18, 19, 22, .16);
  --cta-a: #E8652B; --cta-b: #E5A800; --cta-ink: #FFFFFF;
  --knob: #FFFFFF;
  --nav-pill: #FFFFFF;

  --sans: "Geist", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "Geist Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --max: 1160px;
  --ease-out: cubic-bezier(.2, .8, .2, 1);
}

/* ---------- Colours: dark ("Night"). An explicit choice wins; otherwise follow the system. ---------- */
:root[data-mode="dark"] {
  color-scheme: dark;
  --sky1: #121A2E; --sky2: #2A1D2C; --sky3: #3A2417;
  --sun: rgba(232, 101, 43, .28);
  --card: #1F2024; --line: #33353C;
  --ink: #F4F5F7; --ink-muted: #B0B5C0; --ink-faint: #9298A6; --ink-body: #D5D8DE; --on-ink: #121316; --ink-hover: #D9DBE0;
  --select: #3DF5B0; --handle: #3DF5B0; --accent-text: #5CF2BC;
  --success: #7BE3A6; --danger: #F59A7C; --mark: #4A3F12;
  --hover: rgba(255, 255, 255, .07);
  --field: #232428; --field-line: #3A3C43; --chip-bg: #2A2B31; --th: #26272C; --ok-bg: #12392C; --err-bg: #3D1F17;
  --tint-mint: #143A30; --tint-sky: #16304A; --tint-peach: #3D2719; --tint-lemon: #3A3216; --tint-lilac: #2A2347;
  --glass: rgba(30, 31, 36, .55); --glass-bar: rgba(30, 31, 36, .62); --glass-solid: rgba(30, 31, 36, .9); --glass-strong: rgba(28, 29, 34, .97);
  --glass-line: rgba(255, 255, 255, .10);
  --glass-shadow: 0 1px 0 rgba(255, 255, 255, .05) inset, 0 26px 60px -26px rgba(0, 0, 0, .7);
  --window-shadow: 0 30px 70px -30px rgba(0, 0, 0, .75);
  --menu-shadow: 0 2px 4px rgba(0, 0, 0, .4), 0 24px 60px rgba(0, 0, 0, .55);
  --knob: #3A3C44; --nav-pill: #2C2E35;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-mode="light"]) {
    color-scheme: dark;
    --sky1: #121A2E; --sky2: #2A1D2C; --sky3: #3A2417;
    --sun: rgba(232, 101, 43, .28);
    --card: #1F2024; --line: #33353C;
    --ink: #F4F5F7; --ink-muted: #B0B5C0; --ink-faint: #9298A6; --ink-body: #D5D8DE; --on-ink: #121316; --ink-hover: #D9DBE0;
    --select: #3DF5B0; --handle: #3DF5B0; --accent-text: #5CF2BC;
    --success: #7BE3A6; --danger: #F59A7C; --mark: #4A3F12;
    --hover: rgba(255, 255, 255, .07);
    --field: #232428; --field-line: #3A3C43; --chip-bg: #2A2B31; --th: #26272C; --ok-bg: #12392C; --err-bg: #3D1F17;
    --tint-mint: #143A30; --tint-sky: #16304A; --tint-peach: #3D2719; --tint-lemon: #3A3216; --tint-lilac: #2A2347;
    --glass: rgba(30, 31, 36, .55); --glass-bar: rgba(30, 31, 36, .62); --glass-solid: rgba(30, 31, 36, .9); --glass-strong: rgba(28, 29, 34, .97);
    --glass-line: rgba(255, 255, 255, .10);
    --glass-shadow: 0 1px 0 rgba(255, 255, 255, .05) inset, 0 26px 60px -26px rgba(0, 0, 0, .7);
    --window-shadow: 0 30px 70px -30px rgba(0, 0, 0, .75);
    --menu-shadow: 0 2px 4px rgba(0, 0, 0, .4), 0 24px 60px rgba(0, 0, 0, .55);
    --knob: #3A3C44; --nav-pill: #2C2E35;
  }
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; overflow-x: clip; }
body {
  margin: 0; min-height: 100vh; min-height: 100dvh; overflow-x: clip;
  background: var(--sky1); color: var(--ink);
  font-family: var(--sans); font-size: 16px; line-height: 1.6;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
/* The sky sits on its own fixed layer (cheap to scroll), with the sun glowing up from the bottom. */
body::before { content: ""; position: fixed; inset: 0; z-index: -2; pointer-events: none;
  background: linear-gradient(180deg, var(--sky1) 0%, var(--sky2) 62%, var(--sky3) 100%); }
body::after { content: ""; position: fixed; z-index: -1; left: 50%; bottom: -55vh; width: 120vmax; height: 110vh; transform: translateX(-50%); border-radius: 50%;
  background: radial-gradient(closest-side, var(--sun), transparent 72%); pointer-events: none; will-change: transform; }
img, svg { max-width: 100%; }
a { color: var(--ink); text-underline-offset: 3px; }
a:hover { color: var(--accent-text); }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--select); outline-offset: 3px; border-radius: 6px; }
h1, h2, h3 { text-wrap: balance; margin: 0; }
p { margin: 0; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip { position: fixed; left: 16px; top: -64px; z-index: 100; background: var(--ink); color: var(--on-ink); padding: 12px 18px; border-radius: 999px; font-weight: 600; text-decoration: none; transition: top .2s var(--ease-out); }
.skip:focus { top: 14px; color: var(--on-ink); }
.gutter { padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
.container { max-width: var(--max); margin: 0 auto; }
.grow { flex: 1; }
.grad.warm { background: linear-gradient(90deg, var(--cta-a), var(--cta-b)); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 46px; padding: 0 22px; border-radius: 999px; border: 1px solid transparent;
  font: 600 15px/1 var(--sans); text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: transform .15s ease, background-color .2s ease, border-color .2s ease, box-shadow .2s ease, color .2s ease;
}
.btn:active { transform: scale(.98); }
.btn svg { flex-shrink: 0; }
/* Main actions: the warm gradient pill */
.cta { background: linear-gradient(135deg, var(--cta-a), var(--cta-b)); color: var(--cta-ink); border: 0; box-shadow: 0 8px 18px -8px rgba(232, 101, 43, .7); text-shadow: 0 1px 1px rgba(122, 52, 0, .35); }
.cta:hover { background: linear-gradient(135deg, #F07436, #EDB414); color: var(--cta-ink); box-shadow: 0 10px 22px -8px rgba(232, 101, 43, .8); }
/* Secondary: a light glass pill */
.btn-glass { background: var(--glass-solid); color: var(--ink); border-color: var(--line); }
.btn-glass:hover { background: var(--card); color: var(--ink); border-color: var(--ink-faint); }
.btn[disabled], .btn[aria-busy="true"] { opacity: .65; cursor: progress; }

/* ---------- Floating pill top bar ---------- */
.site-header { position: sticky; top: 0; z-index: 40; display: flex; justify-content: center; pointer-events: none;
  padding: calc(14px + env(safe-area-inset-top, 0px)) max(12px, env(safe-area-inset-right, 0px)) 0 max(12px, env(safe-area-inset-left, 0px)); }
.topbar { pointer-events: auto; display: flex; align-items: center; gap: 6px; height: 58px; max-width: 100%; padding: 0 8px 0 16px; border-radius: 999px;
  background: var(--glass-bar); border: 1px solid var(--glass-line); box-shadow: var(--glass-shadow);
  -webkit-backdrop-filter: blur(16px) saturate(1.3); backdrop-filter: blur(16px) saturate(1.3);
  transition: background-color .25s ease, box-shadow .25s ease; }
.site-header.scrolled .topbar { background: var(--glass-solid); }
.logo { display: inline-flex; align-items: center; gap: 9px; font-size: 17px; font-weight: 700; letter-spacing: -.02em; text-decoration: none; color: var(--ink); flex-shrink: 0; min-height: 40px; }
.logo:hover { color: var(--ink); }
.logo-box { stroke: currentColor; }
.logo-dot { fill: var(--select); }
.topbar .logo { margin-right: 8px; }
.navlinks { position: relative; display: flex; gap: 2px; list-style: none; margin: 0; padding: 0; }
.navlinks a { position: relative; z-index: 1; height: 40px; padding: 0 15px; display: inline-flex; align-items: center; border-radius: 999px; font-size: 14px; font-weight: 500; color: var(--ink-muted); text-decoration: none; transition: color .2s ease, background-color .2s ease; }
.navlinks a:hover { color: var(--ink); background: var(--hover); }
.navlinks a.on { color: var(--ink); }
.navlinks a.on:hover { background: transparent; }
/* Sliding pill behind the section you're looking at (homepage) */
.nav-pill { position: absolute; left: 0; top: 0; height: 40px; width: 0; border-radius: 999px; background: var(--nav-pill); box-shadow: 0 1px 3px rgba(0, 0, 0, .1);
  opacity: 0; pointer-events: none; z-index: 0; transition: transform .38s var(--ease-out), width .38s var(--ease-out), opacity .2s ease; }
.nav-pill.instant { transition: none; }
.bar-sep { width: 1px; height: 24px; background: var(--line); margin: 0 6px; flex-shrink: 0; }
.nav-cta { min-height: 42px; padding: 0 18px; font-size: 14px; margin-left: 4px; }
@media (max-width: 920px) { .navlinks, .bar-sep { display: none; } .topbar .logo { margin-right: auto; } .topbar { width: 100%; max-width: 560px; } }
@media (max-width: 400px) { .topbar { padding-left: 12px; gap: 4px; } .nav-cta { padding: 0 14px; } }
@media (max-width: 359px) { .logo-word { display: none; } }

/* Theme switch: a sliding sun/moon (same as the app) */
.theme-switch { display: inline-flex; align-items: center; min-height: 44px; padding: 0 2px; border: 0; background: none; cursor: pointer; color: var(--ink); border-radius: 999px; flex-shrink: 0; }
.theme-switch .track { position: relative; width: 58px; height: 32px; border-radius: 999px; background: var(--chip-bg); border: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; padding: 0 8px; transition: background-color .25s ease, border-color .25s ease; }
.theme-switch .track svg { position: relative; z-index: 1; color: var(--ink-faint); }
.theme-switch .knob { position: absolute; z-index: 2; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 50%; background: var(--knob); box-shadow: 0 1px 3px rgba(0, 0, 0, .28); display: flex; align-items: center; justify-content: center; transition: transform .26s cubic-bezier(.3, .7, .4, 1); }
.theme-switch .knob svg { color: var(--ink); }
.theme-switch .knob .k-moon { display: none; }
.theme-switch[aria-checked="true"] .knob { transform: translateX(26px); }
.theme-switch[aria-checked="true"] .knob .k-sun { display: none; }
.theme-switch[aria-checked="true"] .knob .k-moon { display: block; }
.theme-switch:hover .track { border-color: var(--ink-faint); }

/* ---------- Glass surfaces ---------- */
.glass-card { background: var(--glass-solid); border: 1px solid var(--glass-line); box-shadow: var(--glass-shadow); }

/* ---------- Hero: feels like the app's home ---------- */
.hero { padding-top: clamp(44px, 9vh, 96px); padding-bottom: 16px; }
.hero-inner { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 22px; }
.pill { display: inline-flex; align-items: center; gap: 8px; padding: 7px 14px; border-radius: 999px; border: 1px solid var(--glass-line); background: var(--glass-solid); box-shadow: var(--glass-shadow); font-size: 13px; font-weight: 500; line-height: 1.3; color: var(--ink); }
.pill i { width: 8px; height: 8px; border-radius: 50%; background: linear-gradient(135deg, var(--cta-a), var(--cta-b)); flex-shrink: 0; }
.display { font-size: clamp(42px, 7.6vw, 86px); line-height: 1.02; font-weight: 700; letter-spacing: -.05em; }
.lede { font-size: clamp(17px, 2vw, 20px); color: var(--ink-muted); max-width: 600px; letter-spacing: -.01em; }

/* The glass prompt box */
.composer { position: relative; width: 100%; max-width: 760px; margin-top: 10px; text-align: left; border-radius: 28px; padding: 18px 18px 14px; display: flex; flex-direction: column; gap: 12px;
  background: var(--glass); border: 1px solid var(--glass-line); box-shadow: var(--glass-shadow);
  -webkit-backdrop-filter: blur(16px) saturate(1.3); backdrop-filter: blur(16px) saturate(1.3);
  transition: border-color .2s ease, box-shadow .2s ease; }
.composer:focus-within { border-color: var(--select); box-shadow: var(--glass-shadow), 0 0 0 4px color-mix(in srgb, var(--select) 16%, transparent); }
.composer:has(.pk-menu:not([hidden])) { z-index: 10; }
.composer textarea { width: 100%; resize: none; border: 0; background: transparent; color: var(--ink); font: 400 17px/1.5 var(--sans); padding: 4px 6px; min-height: 60px; }
.composer textarea::placeholder { color: var(--ink-faint); opacity: 1; }
.composer textarea:focus { outline: none; }
.crow { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; min-width: 0; }
.chips button { min-height: 32px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--card); color: var(--ink-muted); font: 400 12.5px var(--sans); cursor: pointer; transition: color .15s ease, border-color .15s ease; }
.chips button:hover { color: var(--ink); border-color: var(--ink-faint); }
.crow-end { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.est { font-size: 12.5px; color: var(--ink-muted); white-space: nowrap; font-variant-numeric: tabular-nums; }
.send { min-height: 42px; padding: 0 16px 0 18px; border-radius: 999px; font-size: 14.5px; }
.ai-note { font-size: 13px; color: var(--ink-muted); }
@media (max-width: 560px) {
  .composer { border-radius: 24px; padding: 14px 14px 12px; }
  .crow .chips { order: 3; flex-basis: 100%; }
}

/* Menus built from a native <select> (AI level picker and form pickers). Never the native popup. */
.picker { position: relative; }
.pk-btn { height: 36px; padding: 0 10px; border-radius: 10px; border: 1px solid var(--line); background: var(--field); display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; color: var(--ink); cursor: pointer; transition: border-color .15s ease; }
.pk-btn:hover { border-color: var(--ink-faint); }
.pk-btn[aria-expanded="true"] { border-color: var(--select); }
.pk-btn .chev { color: var(--ink-faint); transition: transform .18s ease; flex-shrink: 0; }
.pk-btn[aria-expanded="true"] .chev { transform: rotate(180deg); }
.pk-menu { position: absolute; left: 0; top: calc(100% + 8px); width: 340px; max-width: calc(100vw - 48px); max-height: min(480px, 75vh); overflow-y: auto; overscroll-behavior: contain;
  background: var(--card); border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--menu-shadow); padding: 6px; z-index: 30; outline: none; text-align: left; }
.pk-menu:focus-visible { outline: 2px solid var(--select); outline-offset: 2px; }
.pk-head { padding: 8px 10px 6px; font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-faint); }
.pk-opt { display: flex; gap: 12px; align-items: flex-start; padding: 10px; border-radius: 11px; cursor: pointer; }
.pk-opt.active { background: var(--hover); }
.pk-opt .bars { margin-top: 4px; }
.pk-text { flex: 1; min-width: 0; }
.pk-text b { display: block; font-size: 14px; font-weight: 600; }
.pk-text small { display: block; font-size: 12px; line-height: 1.45; color: var(--ink-muted); margin-top: 1px; }
.pk-end { flex-shrink: 0; align-self: center; display: inline-flex; align-items: center; gap: 6px; }
.pk-check { color: var(--accent-text); visibility: hidden; }
.pk-opt[aria-selected="true"] .pk-check { visibility: visible; }
.pk-tag { font-size: 11px; font-weight: 700; padding: 3px 8px; border-radius: 999px; background: var(--chip-bg); color: var(--ink-muted); white-space: nowrap; }
.pk-tag.rec { color: #fff; background: linear-gradient(135deg, #E8652B, #E5A800); }
.pk-foot { margin: 4px 4px 2px; padding: 8px 8px 4px; border-top: 1px solid var(--line); font-size: 12px; color: var(--ink-muted); }
.picker.up .pk-menu { top: auto; bottom: calc(100% + 8px); }
@media (prefers-reduced-motion: no-preference) { .pk-menu:not([hidden]) { animation: cv-pop-in .18s var(--ease-out) both; transform-origin: top left; } }
@keyframes cv-pop-in { from { opacity: 0; transform: translateY(-4px) scale(.97); } to { opacity: 1; transform: none; } }

/* AI level bars (same as the app) */
.bars { display: inline-flex; align-items: flex-end; gap: 2px; height: 14px; flex-shrink: 0; }
.bars i { width: 3px; border-radius: 1px; background: var(--line); }
.bars i:nth-child(1) { height: 5px; } .bars i:nth-child(2) { height: 8px; } .bars i:nth-child(3) { height: 11px; } .bars i:nth-child(4) { height: 14px; }
.bars.l1 i:nth-child(-n+1), .bars.l2 i:nth-child(-n+2), .bars.l3 i:nth-child(-n+3), .bars.l4 i:nth-child(-n+4) { background: var(--bar-color); }
.bars.l1 { --bar-color: #2BBF8A; } .bars.l2 { --bar-color: #3A9BE8; } .bars.l3 { --bar-color: #8B6CF0; } .bars.l4 { --bar-color: #E8652B; }

/* ---------- Live preview window (Mac style, like the app) ---------- */
.window { width: 100%; max-width: 880px; margin: 30px 0 0; border-radius: 18px; border: 1px solid var(--glass-line); background: var(--card); box-shadow: var(--window-shadow); text-align: left; }
.chrome { height: 44px; padding: 0 10px 0 14px; display: flex; align-items: center; gap: 10px; border-bottom: 1px solid var(--line); }
.dots { display: inline-flex; gap: 7px; flex-shrink: 0; }
.dots i { width: 11px; height: 11px; border-radius: 50%; background: #FF5F57; }
.dots i:nth-child(2) { background: #FEBC2E; } .dots i:nth-child(3) { background: #28C840; }
.url { flex: 1; min-width: 0; max-width: 360px; margin: 0 auto; height: 28px; border-radius: 999px; background: var(--chip-bg); display: flex; align-items: center; justify-content: center; padding: 0 12px; font-size: 12px; color: var(--ink-muted); overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.live { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; color: var(--success); flex-shrink: 0; }
.live i { width: 7px; height: 7px; border-radius: 50%; background: #16A36F; }
.publish { height: 30px; padding: 0 14px; border-radius: 999px; background: linear-gradient(135deg, var(--cta-a), var(--cta-b)); color: #FFFFFF; font: 600 12px var(--sans); display: inline-flex; align-items: center; flex-shrink: 0; text-shadow: 0 1px 1px rgba(122, 52, 0, .35); }
@media (max-width: 520px) { .live { display: none; } .dots i { width: 9px; height: 9px; } }
.demo-site { background: #F3EEE6; color: #1B1714; padding: clamp(20px, 4vw, 34px) clamp(18px, 5vw, 44px) clamp(24px, 4vw, 38px); border-radius: 0 0 17px 17px; display: flex; flex-direction: column; gap: 18px; }
.demo-nav { display: flex; align-items: center; gap: 18px; font-size: 13px; }
.demo-nav b { font-size: 16px; letter-spacing: -.02em; flex: 1; }
@media (max-width: 520px) { .demo-nav span { display: none; } }
.demo-copy { display: flex; flex-direction: column; gap: 10px; padding-top: 6px; }
.demo-h { font-size: clamp(30px, 6vw, 48px); line-height: 1.02; font-weight: 700; letter-spacing: -.035em; }
.demo-p { font-size: 14px; color: #5E544A; }
.sel { position: relative; align-self: flex-start; margin-top: 10px; }
.sel .book { display: inline-block; padding: 12px 22px; border-radius: 999px; background: var(--sel-bg, #1B1714); color: #F3EEE6; font-size: 14px; font-weight: 600; transition: background-color .3s ease; }
.sel .box { position: absolute; inset: -6px; border: 2px dashed #0F9E6E; border-radius: 6px; pointer-events: none; }
.sel .h { position: absolute; width: 8px; height: 8px; background: #3DF5B0; border: 1px solid #121316; pointer-events: none; }
.sel .h1 { left: -10px; top: -10px; } .sel .h2 { right: -10px; top: -10px; } .sel .h3 { left: -10px; bottom: -10px; } .sel .h4 { right: -10px; bottom: -10px; }
.toolbar { position: absolute; left: calc(100% + 28px); top: 50%; transform: translateY(-50%); display: flex; align-items: center; gap: 8px; padding: 5px 5px 5px 6px; border-radius: 999px; background: #16171A; color: #F1F2F4; font-size: 12px; white-space: nowrap; box-shadow: 0 10px 30px -10px rgba(0, 0, 0, .5); }
.toolbar .cap-tag { display: inline-flex; align-items: center; gap: 5px; padding: 3px 8px; border-radius: 999px; background: rgba(61, 245, 176, .14); color: var(--handle); font-weight: 600; }
.toolbar .ask { color: #F1F2F4; }
.toolbar .ask-send { width: 28px; height: 28px; border-radius: 50%; border: 0; padding: 0; display: inline-flex; align-items: center; justify-content: center; cursor: pointer; color: #FFFFFF; background: linear-gradient(135deg, #E8652B, #E5A800); transition: filter .15s ease, transform .15s ease; }
.toolbar .ask-send:hover { filter: brightness(1.08); }
.toolbar .ask-send:active { transform: scale(.94); }
.toolbar .ask-send:focus-visible { outline-color: #3DF5B0; }
.toolbar b { color: var(--handle); padding-right: 6px; }
.toolbar .cap-tag svg, .toolbar .ask-send svg { flex-shrink: 0; max-width: none; }
@media (max-width: 640px) { .toolbar { left: -6px; top: calc(100% + 18px); transform: none; } .sel { margin-bottom: 52px; } }
.demo-prices { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.demo-prices div { background: #FFFFFF; border-radius: 12px; padding: 14px 16px; display: flex; flex-direction: column; gap: 2px; }
.demo-prices span { font-size: 13px; color: #5E544A; }
.demo-prices strong { font-size: 20px; }
@media (max-width: 520px) { .demo-prices { grid-template-columns: 1fr; } }
.window-caption { font-size: 14px; color: var(--ink-muted); max-width: 560px; }

/* ---------- Sections ---------- */
.section { padding-top: clamp(80px, 11vw, 140px); }
section[id] { scroll-margin-top: 92px; }
.section-head { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 14px; max-width: 700px; margin: 0 auto clamp(36px, 5vw, 56px); }
.eyebrow { display: inline-flex; align-items: center; gap: 7px; padding: 5px 12px; border-radius: 999px; background: var(--glass-solid); border: 1px solid var(--glass-line); font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--accent-text); }
.title { font-size: clamp(32px, 4.8vw, 52px); line-height: 1.05; font-weight: 700; letter-spacing: -.04em; }
.sub { color: var(--ink-muted); font-size: clamp(16px, 1.8vw, 18px); max-width: 600px; }

/* How it works */
.steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; list-style: none; padding: 0; margin: 0; }
.steps li { border-radius: 26px; padding: 28px; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.step-num { width: 40px; height: 40px; margin-bottom: 8px; border-radius: 13px; display: inline-flex; align-items: center; justify-content: center; font-weight: 700; font-size: 17px; color: #FFFFFF; background: linear-gradient(135deg, var(--cta-a), var(--cta-b)); box-shadow: 0 8px 18px -8px rgba(232, 101, 43, .7); text-shadow: 0 1px 1px rgba(122, 52, 0, .35); }
.steps h3 { font-size: 21px; font-weight: 650; letter-spacing: -.02em; }
.steps p { color: var(--ink-muted); font-size: 15.5px; }
@media (max-width: 860px) { .steps { grid-template-columns: 1fr; max-width: 560px; margin: 0 auto; } }

/* What you can do */
.can-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; list-style: none; padding: 0; margin: 0; }
.can-grid li { border-radius: 22px; padding: 22px; display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.can-ic { width: 42px; height: 42px; margin-bottom: 6px; border-radius: 13px; display: grid; place-items: center; background: var(--tint, var(--tint-peach)); color: var(--ink); }
.can-ic svg { width: 21px; height: 21px; }
.can-grid h3 { font-size: 16.5px; font-weight: 650; letter-spacing: -.015em; }
.can-grid p { color: var(--ink-muted); font-size: 14.5px; line-height: 1.55; }
.t-mint { --tint: var(--tint-mint); } .t-sky { --tint: var(--tint-sky); } .t-peach { --tint: var(--tint-peach); } .t-lemon { --tint: var(--tint-lemon); } .t-lilac { --tint: var(--tint-lilac); }
@media (max-width: 1040px) { .can-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .can-grid { grid-template-columns: 1fr; } }

/* Why Corvela */
.features { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.feature { position: relative; overflow: hidden; border-radius: 26px; padding: 30px; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.feature::before { content: ""; position: absolute; inset: 0 0 auto; height: 70%; background: linear-gradient(180deg, var(--tint), transparent); opacity: .85; pointer-events: none; }
.feature > * { position: relative; }
.feature h3 { font-size: 23px; font-weight: 700; letter-spacing: -.025em; }
.feature p { color: var(--ink-muted); }
.feature .tag { align-self: flex-start; font-size: 12px; font-weight: 600; padding: 4px 10px; border-radius: 999px; background: var(--ink); color: var(--on-ink); }
@media (max-width: 760px) { .features { grid-template-columns: 1fr; } }

/* Pricing: glass plan cards */
.plans { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; align-items: stretch; }
.plan { border-radius: 28px; padding: 30px; display: flex; flex-direction: column; gap: 18px; min-width: 0; }
.plan.featured { border: 2px solid transparent; background: linear-gradient(var(--card), var(--card)) padding-box, linear-gradient(135deg, var(--cta-a), var(--cta-b)) border-box;
  box-shadow: 0 30px 60px -30px rgba(232, 101, 43, .55); }
.plan h3 { font-size: 19px; font-weight: 650; }
.plan .who { color: var(--ink-muted); font-size: 14.5px; margin-top: -10px; }
.price { display: flex; align-items: baseline; gap: 6px; }
.price strong { font-size: 50px; line-height: 1.05; font-weight: 700; letter-spacing: -.045em; font-variant-numeric: tabular-nums; }
.plan.featured .price strong { background: linear-gradient(90deg, var(--cta-a), var(--cta-b)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.price span { color: var(--ink-muted); font-size: 15px; }
.plan ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 11px; font-size: 15px; }
.plan li { display: flex; gap: 10px; align-items: flex-start; }
.plan li svg { flex-shrink: 0; margin-top: 4px; color: var(--select); }
.plan .btn { margin-top: auto; }
.plans-note { margin: 24px auto 0; max-width: 680px; text-align: center; font-size: 14px; color: var(--ink-muted); }
@media (max-width: 900px) { .plans { grid-template-columns: 1fr; max-width: 480px; margin: 0 auto; } }

/* FAQ */
.faq { max-width: 820px; margin: 0 auto; display: flex; flex-direction: column; gap: 12px; }
.faq details { border-radius: 20px; padding: 0 22px; }
.faq summary { cursor: pointer; list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 64px; font-weight: 600; font-size: 16.5px; border-radius: 12px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary .plus { position: relative; width: 28px; height: 28px; flex-shrink: 0; border-radius: 50%; background: var(--chip-bg); transition: transform .3s var(--ease-out), background-color .2s ease; }
.faq summary .plus::before, .faq summary .plus::after { content: ""; position: absolute; left: 50%; top: 50%; width: 12px; height: 2px; margin: -1px 0 0 -6px; border-radius: 1px; background: var(--ink-muted); }
.faq summary .plus::after { transform: rotate(90deg); }
.faq details[open] summary .plus { transform: rotate(45deg); background: color-mix(in srgb, var(--cta-a) 18%, transparent); }
.faq details p { padding-bottom: 20px; color: var(--ink-muted); max-width: 680px; }
@media (prefers-reduced-motion: no-preference) { .faq details[open] p { animation: cv-drop .3s var(--ease-out) both; } }
@keyframes cv-drop { from { opacity: 0; transform: translateY(-6px); } }

/* Waitlist panel */
.wl-panel { position: relative; overflow: hidden; border-radius: 36px; padding: clamp(24px, 5vw, 60px); display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 480px); gap: clamp(24px, 4vw, 56px); align-items: center;
  background: var(--glass); border: 1px solid var(--glass-line); box-shadow: var(--glass-shadow); }
.wl-panel::before { content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(60% 80% at 0% 100%, color-mix(in srgb, var(--cta-a) 18%, transparent), transparent 70%), radial-gradient(50% 70% at 100% 0%, color-mix(in srgb, var(--sky1) 70%, transparent), transparent 70%); }
.wl-panel > * { position: relative; }
.wl-copy { display: flex; flex-direction: column; align-items: flex-start; gap: 14px; }
@media (max-width: 900px) { .wl-panel { grid-template-columns: 1fr; border-radius: 28px; } }

/* ---------- Forms ---------- */
.form-card { border-radius: 26px; padding: clamp(20px, 3vw, 28px); display: flex; flex-direction: column; gap: 18px; min-width: 0; }
.field { display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.field label, .field .label { font-size: 14px; font-weight: 600; }
.hint { font-size: 13px; color: var(--ink-muted); font-weight: 400; }
.form-note { font-size: 13px; color: var(--ink-muted); }
.input, .textarea, .select, .select-btn {
  width: 100%; min-height: 48px; padding: 12px 15px; border-radius: 14px;
  border: 1px solid var(--field-line); background: var(--field); color: var(--ink); font: 400 16px/1.4 var(--sans);
  transition: border-color .15s ease, box-shadow .15s ease;
}
.input::placeholder, .textarea::placeholder { color: var(--ink-faint); opacity: 1; }
.textarea { min-height: 120px; resize: vertical; }
.textarea.mono { font-family: var(--mono); font-size: 13px; }
.select { appearance: none; -webkit-appearance: none; padding-right: 40px; }
.input:hover, .textarea:hover, .select-btn:hover { border-color: var(--ink-faint); }
.input:focus, .textarea:focus, .select:focus { outline: none; border-color: var(--select); box-shadow: 0 0 0 4px color-mix(in srgb, var(--select) 18%, transparent); }
.select-btn { display: flex; align-items: center; justify-content: space-between; gap: 10px; text-align: left; cursor: pointer; }
.select-btn:focus-visible { outline: none; border-color: var(--select); box-shadow: 0 0 0 4px color-mix(in srgb, var(--select) 18%, transparent); }
.select-btn[aria-expanded="true"] { border-color: var(--select); }
.select-btn .sb-label { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.select-btn.empty .sb-label { color: var(--ink-faint); }
.select-btn .chev { color: var(--ink-muted); flex-shrink: 0; transition: transform .18s ease; }
.select-btn[aria-expanded="true"] .chev { transform: rotate(180deg); }
.field .picker .pk-menu { width: 100%; max-width: none; min-width: 240px; }
.field .pk-opt { padding: 10px 12px; align-items: center; }
.field .pk-opt .pk-text b { font-weight: 500; }
.input[aria-invalid="true"], .textarea[aria-invalid="true"], .select[aria-invalid="true"], .select-btn[aria-invalid="true"] { border-color: var(--danger); }
.field-error { font-size: 13px; color: var(--danger); }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; color: var(--ink-muted); cursor: pointer; }
.check input { width: 20px; height: 20px; margin: 1px 0 0; accent-color: var(--cta-a); flex-shrink: 0; cursor: pointer; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-status { font-size: 14px; border-radius: 14px; padding: 12px 14px; }
.form-status.ok { background: var(--ok-bg); color: var(--success); }
.form-status.err { background: var(--err-bg); color: var(--danger); }
.form-card .cta { align-self: flex-start; min-width: 200px; }
@media (max-width: 560px) { .form-card .cta { align-self: stretch; } }
.row2 { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 18px; }
@media (max-width: 600px) { .row2 { grid-template-columns: 1fr; } }

/* ---------- Simple pages (contact, bug, legal, 404) ---------- */
.page-head { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 14px; padding-block: clamp(40px, 7vw, 80px) clamp(28px, 4vw, 44px); }
.page-head .display { font-size: clamp(38px, 6vw, 64px); }
.page-head p { color: var(--ink-muted); max-width: 640px; font-size: clamp(16px, 1.8vw, 18px); }
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 340px); gap: 24px; align-items: start; }
@media (max-width: 900px) { .split { grid-template-columns: 1fr; max-width: 680px; margin: 0 auto; } }
.aside { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.aside-card { border-radius: 22px; padding: 22px; display: flex; flex-direction: column; gap: 8px; }
.aside-card h2 { font-size: 16px; font-weight: 650; }
.aside-card p { font-size: 14px; color: var(--ink-muted); }
.aside-card > a { font-size: 14px; font-weight: 600; color: var(--accent-text); }
.copy-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.copy-row code { font-family: var(--mono); font-size: 13.5px; background: var(--chip-bg); padding: 5px 10px; border-radius: 8px; user-select: all; overflow-wrap: anywhere; }
.copy-btn { min-height: 34px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--card); font: 500 13px var(--sans); cursor: pointer; color: var(--ink); }
.copy-btn:hover { border-color: var(--ink-faint); }

/* Legal pages: table of contents and the text, each on glass */
.legal { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 24px; align-items: start; }
.toc { position: sticky; top: calc(92px + env(safe-area-inset-top, 0px)); align-self: start; font-size: 14px; padding: 18px 20px; border-radius: 22px; max-height: calc(100vh - 110px); overflow-y: auto; }
.toc p { font-weight: 650; margin-bottom: 10px; }
.toc ol { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 7px; color: var(--ink-muted); }
.toc a { color: var(--ink-muted); text-decoration: none; }
.toc a:hover { color: var(--ink); text-decoration: underline; }
.prose { min-width: 0; padding: 8px clamp(18px, 4vw, 44px) clamp(18px, 3vw, 32px); border-radius: 28px; font-size: 15.5px; line-height: 1.7; }
.prose h2 { font-size: 21px; font-weight: 700; letter-spacing: -.02em; margin: 32px 0 10px; scroll-margin-top: 96px; }
.prose h3 { font-size: 17px; font-weight: 650; margin: 22px 0 8px; }
.prose p, .prose ul, .prose ol { margin: 0 0 14px; color: var(--ink-body); }
.prose ul, .prose ol { padding-left: 22px; }
.prose li { margin-bottom: 6px; }
.prose a { color: var(--accent-text); }
.prose table { width: 100%; border-collapse: collapse; font-size: 14px; }
.prose th, .prose td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.prose tr:last-child td { border-bottom: 0; }
.prose th { font-weight: 600; background: var(--th); }
.table-wrap { overflow-x: auto; margin: 0 0 16px; border: 1px solid var(--line); border-radius: 14px; background: var(--card); }
.fill { background: var(--mark); color: var(--ink); padding: 0 4px; border-radius: 4px; }
.notice { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 14px 16px; font-size: 14px; color: var(--ink-muted); margin-bottom: 24px; }
@media (max-width: 860px) { .legal { grid-template-columns: 1fr; gap: 16px; } .toc { position: static; max-height: none; } }

/* 404 */
.lost { min-height: calc(100vh - 180px); display: flex; align-items: center; justify-content: center; padding-block: 48px; }
.lost .hero-inner { gap: 20px; }
.btn-row { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; }

/* ---------- Footer: a glass card floating at the bottom ---------- */
.site-footer { margin-top: clamp(80px, 11vw, 140px); padding: 0 max(16px, env(safe-area-inset-right, 0px)) calc(16px + env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px)); }
.footer-card { max-width: var(--max); margin: 0 auto; border-radius: 30px; padding: clamp(26px, 4vw, 44px) clamp(22px, 4vw, 44px) 26px; }
.footer-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) repeat(3, minmax(0, 1fr)); gap: 32px; }
.footer-grid h2 { font-size: 13px; font-weight: 650; color: var(--ink); margin-bottom: 12px; }
.footer-grid ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 4px; }
.footer-grid ul a { display: inline-flex; min-height: 30px; align-items: center; color: var(--ink-muted); text-decoration: none; font-size: 14px; }
.footer-grid ul a:hover { color: var(--ink); text-decoration: underline; }
.footer-brand p { color: var(--ink-muted); font-size: 14px; margin-top: 10px; max-width: 290px; }
.footer-base { margin-top: 32px; padding-top: 20px; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; font-size: 13px; color: var(--ink-muted); }
@media (max-width: 760px) { .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; } .footer-brand { grid-column: 1 / -1; } }

/* ===== Smooth light/dark switch =====
   Blocks fade out and lift back in (animated from the script) while the sky blends between dawn and night.
   With reduced motion on, the theme cross-fades; browsers without View Transitions blend every colour. */
@keyframes cv-fade-in { from { opacity: 0; } }
@keyframes cv-fade-out { to { opacity: 0; } }
html.theme-fade::view-transition-old(root) { animation: cv-fade-out .4s ease both !important; }
html.theme-fade::view-transition-new(root) { animation: cv-fade-in .4s ease both !important; }
@property --sky1 { syntax: '<color>'; inherits: true; initial-value: #CFE6FF; }
@property --sky2 { syntax: '<color>'; inherits: true; initial-value: #FFE3CC; }
@property --sky3 { syntax: '<color>'; inherits: true; initial-value: #FFF4DA; }
@property --sun { syntax: '<color>'; inherits: true; initial-value: rgba(255, 176, 120, .55); }
html.theme-sky, html.theme-blend { transition: --sky1 .5s ease, --sky2 .5s ease, --sky3 .5s ease, --sun .5s ease !important; }
html.theme-blend body, html.theme-blend *, html.theme-blend *::before, html.theme-blend *::after {
  transition: background-color .5s ease, color .5s ease, border-color .5s ease, box-shadow .5s ease, fill .5s ease, stroke .5s ease, outline-color .5s ease !important; }
html.theme-blend .theme-switch .knob { transition: transform .26s cubic-bezier(.3, .7, .4, 1), background-color .5s ease !important; }

/* Page load: the top blocks lift into place one after another (CSS only, so nothing flashes). */
@keyframes cv-lift { from { opacity: 0; transform: translateY(22px) scale(.97); } }
@media (prefers-reduced-motion: no-preference) {
  .hero-inner > *, .page-head > *, .split > *, .legal > * { animation: cv-lift .7s cubic-bezier(.16, 1, .3, 1) backwards; }
  .hero-inner > :nth-child(2), .page-head > :nth-child(2), .split > :nth-child(2), .legal > :nth-child(2) { animation-delay: .06s; }
  .hero-inner > :nth-child(3), .page-head > :nth-child(3) { animation-delay: .12s; }
  .hero-inner > :nth-child(4) { animation-delay: .18s; }
  .hero-inner > :nth-child(n+5) { animation-delay: .26s; }
}

/* ---------- Reduced motion: nothing moves ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}

/* Phone menu */
.nav-menu-btn { display: none; width: 42px; height: 42px; border-radius: 999px; border: 1px solid var(--glass-line, rgba(0,0,0,.08)); background: transparent; color: var(--ink); place-items: center; cursor: pointer; flex-shrink: 0; }
.nav-menu-btn:hover { background: var(--hover); }
.nav-menu-btn path { transition: transform .2s ease; transform-origin: 12px 12px; }
.topbar.menu-open .nav-menu-btn .l1 { transform: translateY(4px) rotate(45deg); }
.topbar.menu-open .nav-menu-btn .l2 { transform: translateY(-4px) rotate(-45deg); }
.nav-sheet { pointer-events: auto; position: fixed; z-index: 49; top: 76px; left: 16px; right: 16px; max-width: 560px; margin: 0 auto; padding: 8px; border-radius: 22px; background: var(--card, #fff); border: 1px solid var(--line); box-shadow: 0 24px 60px -24px rgba(40, 30, 60, .45); }
.nav-sheet ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.nav-sheet a { display: flex; align-items: center; min-height: 48px; padding: 0 16px; border-radius: 14px; font-size: 16px; font-weight: 500; color: var(--ink); text-decoration: none; }
.nav-sheet a:hover, .nav-sheet a:focus-visible { background: var(--hover); }
@media (max-width: 920px) { .nav-menu-btn { display: grid; } }
@media (min-width: 921px) { .nav-sheet { display: none; } }
@media (max-width: 400px) { .nav-cta { font-size: 13px; } }

/* Logo: the Sunrise mark + lowercase "corvela" wordmark */
.logo-word { text-transform: lowercase; font-weight: 620; letter-spacing: -0.045em; font-size: 1.08em; }
.cv-mark { flex-shrink: 0; display: block; }

/* Pricing: questions about plans, under the plan cards */
.pricing-faq { max-width: 980px; margin: 46px auto 0; }
.pricing-faq-title { margin: 0 0 16px; text-align: center; font-size: 20px; letter-spacing: -.02em; }
.faq.faq-2 { max-width: none; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; align-items: start; }
.faq.faq-2 summary { font-size: 15.5px; min-height: 58px; }
@media (max-width: 760px) { .faq.faq-2 { grid-template-columns: minmax(0, 1fr); } }
