/* Tealdraft homepage. Brand: docs/brand/README.md (teal #22e3dc on dark / #0fb3ad on light, deep teal-navy
   #0d3440 -> #05161c, ink #0d1b20). Headings in Montserrat ExtraBold like the wordmark (SIL Open Font License,
   self-hosted), body in the system UI face. Light sections by default, `.dark` bands redefine the same tokens,
   and the whole page goes dark when the OS asks. */
@font-face {
  font-family: "Montserrat";
  src: url(/home/fonts/montserrat-latin.woff2) format("woff2");
  font-weight: 700 800;
  font-style: normal;
  font-display: swap;
}

:root, .light {
  --bg: #f3f6f6;
  --bg-2: #e8eeef;
  --card: #ffffff;
  --ink: #0d1b20;
  --ink-2: #3b4f55;
  --ink-3: #5a6e74;
  --rule: #d6e0e2;
  --teal: #22e3dc;
  --teal-2: #5ff5ee;
  --teal-ink: #08736f;
  --on-teal: #05161c;
  --no: #c2412d;
  --shadow: 0 1px 2px rgba(13, 27, 32, 0.06), 0 22px 50px -24px rgba(13, 27, 32, 0.45);
}
.dark {
  --bg: #05161c;
  --bg-2: #0a2028;
  --card: #0b222a;
  --ink: #e8f0f1;
  --ink-2: #a9bec3;
  --ink-3: #87a0a6;
  --rule: #183740;
  --teal-ink: #5ff5ee;
  --no: #ff8f7a;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 28px 60px -28px rgba(0, 0, 0, 0.9);
}
:root {
  --font: Inter, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --display: Montserrat, var(--font);
  --max: 1120px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root, .light {
    --bg: #05161c; --bg-2: #081c23; --card: #0b222a; --ink: #e8f0f1; --ink-2: #a9bec3; --ink-3: #87a0a6; --rule: #183740;
    --teal-ink: #5ff5ee; --no: #ff8f7a; --shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 28px 60px -28px rgba(0, 0, 0, 0.9);
    color-scheme: dark;
  }
  .light { --bg: #081c23; }
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { transition: none !important; } }
body { margin: 0; font-family: var(--font); color: var(--ink); background: var(--bg); line-height: 1.6; font-size: 17px; overflow-x: hidden; -webkit-font-smoothing: antialiased; }
section, .site-header, .site-footer { background: var(--bg); color: var(--ink); }
img, svg { max-width: 100%; display: block; }
img { height: auto; }
a { color: var(--teal-ink); text-underline-offset: 3px; }
:focus-visible { outline: 3px solid var(--teal); outline-offset: 3px; border-radius: 6px; }
.skip { position: absolute; left: 16px; top: -60px; background: var(--teal); color: var(--on-teal); padding: 10px 14px; border-radius: 8px; z-index: 50; font-weight: 650; text-decoration: none; }
.skip:focus { top: 12px; }
.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; }
.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 16px; }
.wrap.narrow { max-width: 820px; }
@media (min-width: 720px) { .wrap { padding: 0 32px; } }

h1, h2, h3 { font-family: var(--display); line-height: 1.08; letter-spacing: -0.02em; margin: 0; font-weight: 800; }
h1 { font-size: clamp(2.3rem, 5.6vw, 4rem); letter-spacing: -0.03em; }
h2 { font-size: clamp(1.75rem, 4vw, 2.7rem); letter-spacing: -0.025em; }
h3 { font-size: 1.22rem; font-weight: 700; line-height: 1.25; }
p { margin: 0; }
.eyebrow { font-size: .78rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--teal-ink); margin-bottom: 16px; }
.lead { font-size: clamp(1.08rem, 2.2vw, 1.26rem); color: var(--ink-2); max-width: 38em; }
.section-head { margin-bottom: 48px; max-width: 46em; }
.section-head .lead { margin-top: 18px; }
section { padding: 96px 0; }
[id] { scroll-margin-top: 68px; }
@media (max-width: 720px) { section { padding: 72px 0; } .section-head { margin-bottom: 36px; } }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 24px; border-radius: 999px; font: inherit; font-weight: 650; text-decoration: none; border: 2px solid transparent; cursor: pointer; transition: transform .15s, background-color .15s, border-color .15s, color .15s, box-shadow .15s; }
.btn-primary { background: var(--teal); color: var(--on-teal); }
.btn-primary:hover { background: var(--teal-2); transform: translateY(-1px); box-shadow: 0 8px 24px -10px rgba(34, 227, 220, .6); }
.btn-primary:disabled { opacity: .6; cursor: progress; transform: none; box-shadow: none; }
.btn-quiet { color: var(--ink); border-color: var(--rule); }
.btn-quiet:hover { border-color: var(--teal-ink); color: var(--teal-ink); }

/* Header (always on the dark brand color, like the hero under it) */
.site-header { position: sticky; top: 0; z-index: 20; background: rgba(13, 52, 64, .92); backdrop-filter: saturate(1.4) blur(10px); -webkit-backdrop-filter: saturate(1.4) blur(10px); border-bottom: 1px solid rgba(95, 245, 238, .1); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; height: 68px; gap: 12px; }
.brand { display: inline-flex; border-radius: 8px; }
.brand img { height: 30px; width: auto; }
.nav { display: flex; align-items: center; gap: 2px; }
.nav a { color: var(--ink-2); text-decoration: none; padding: 10px 12px; border-radius: 8px; font-weight: 550; font-size: .95rem; }
.nav a:hover { color: var(--ink); }
.nav .btn { min-height: 40px; padding: 0 18px; margin-left: 6px; border-radius: 999px; color: var(--on-teal); font-size: .95rem; }
.nav .btn:hover { color: var(--on-teal); }
@media (max-width: 860px) { .nav a:not(.btn):not(.login) { display: none; } }
.nav a { white-space: nowrap; }
@media (max-width: 440px) { .brand img { height: 24px; } .nav .btn { padding: 0 14px; font-size: .9rem; } .nav a.login { padding: 10px 8px; } }
@media (max-width: 400px) { .nav a.login { display: none; } }

/* Hero: deep teal-navy with one soft glow behind the poster */
.hero { padding: 72px 0 0; position: relative; overflow: hidden; background:
  radial-gradient(38% 46% at 76% 34%, rgba(34, 227, 220, .13), transparent 70%),
  linear-gradient(180deg, #0d3440 0%, #082029 46%, #05161c 100%); }
.hero-grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: 56px; align-items: center; }
.hero h1 { max-width: 13em; text-wrap: balance; }
.hl { color: var(--teal); white-space: nowrap; padding-bottom: .12em; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 300 14' preserveAspectRatio='none'%3E%3Cpath d='M3 11C80 4 190 2 297 5' fill='none' stroke='%2322e3dc' stroke-width='4' stroke-linecap='round'/%3E%3C/svg%3E") left bottom / 100% .28em no-repeat; }
.hero .lead { margin-top: 26px; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 34px; }
.hero-note { margin-top: 20px; font-size: .92rem; color: var(--ink-3); max-width: 34em; }
@media (max-width: 960px) {
  .hero { padding-top: 48px; background: radial-gradient(70% 30% at 50% 62%, rgba(34, 227, 220, .12), transparent 70%), linear-gradient(180deg, #0d3440 0%, #082029 46%, #05161c 100%); }
  .hero-grid { grid-template-columns: 1fr; gap: 56px; }
}

/* The poster on its "sheet", with crop marks and notes */
.hero-art { margin: 0; justify-self: center; width: min(400px, 74vw); }
.sheet { position: relative; }
.sheet img { width: 100%; border-radius: 3px; box-shadow: 0 30px 70px -30px rgba(0, 0, 0, .9), 0 0 0 1px rgba(95, 245, 238, .08); transform: rotate(1.2deg); }
.sheet::before, .sheet::after { content: ""; position: absolute; width: 26px; height: 26px; border-color: rgba(169, 190, 195, .55); border-style: solid; }
.sheet::before { left: -18px; top: -18px; border-width: 0 1px 1px 0; }
.sheet::after { right: -18px; bottom: -18px; border-width: 1px 0 0 1px; }
.note { position: absolute; z-index: 2; display: inline-flex; align-items: center; gap: 8px; padding: 7px 12px 7px 8px; border-radius: 999px; background: #0d2b34; color: #e8f0f1; font-size: .84rem; font-weight: 600; white-space: nowrap; box-shadow: 0 10px 30px -12px rgba(0, 0, 0, .8); border: 1px solid rgba(95, 245, 238, .22); }
.note i { display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--teal); color: var(--on-teal); font-style: normal; font-size: .75rem; font-weight: 800; flex: none; }
.note u { text-decoration: none; color: #5ff5ee; margin-left: 4px; padding-left: 8px; border-left: 1px solid rgba(95, 245, 238, .25); }
.n1 { right: -24%; top: 9%; }
.n2 { left: -22%; top: 47%; }
.n3 { right: -18%; bottom: -5%; }
.hero-art figcaption { margin-top: 44px; font-size: .88rem; color: var(--ink-3); text-align: center; }
@media (max-width: 1180px) { .n1 { right: -10%; } .n2 { left: -12%; } .n3 { right: -6%; } }
@media (max-width: 560px) {
  .n1 { right: -4%; top: -3%; }
  .n2 { left: -5%; top: 46%; }
  .n3 { right: -3%; bottom: -5%; }
  .note { font-size: .74rem; padding: 5px 10px 5px 6px; gap: 6px; }
  .note i { width: 18px; height: 18px; font-size: .65rem; }
}

/* Editor screenshot, still on the hero's dark band */
.showcase { padding: 88px 0 96px; }
.shot { margin: 0; }
.shot-frame { border-radius: 14px; overflow: hidden; background: #0d1619; border: 1px solid var(--rule); box-shadow: var(--shadow), 0 0 80px -30px rgba(34, 227, 220, .25); }
.shot-frame img { width: 100%; }
.shot figcaption { margin-top: 18px; color: var(--ink-3); font-size: .95rem; max-width: 52em; }

/* How the AI works */
.does { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 104px; }
.does .col { background: var(--card); border: 1px solid var(--rule); border-radius: 14px; padding: 28px 30px 30px; }
.does h3 { font-size: 1.1rem; margin-bottom: 16px; display: flex; align-items: center; gap: 10px; }
.does h3::before { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--teal); flex: none; }
.does .no h3::before { background: transparent; border: 2px solid var(--no); }
.does ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.does li { color: var(--ink-2); padding-left: 26px; position: relative; }
.does li::before { position: absolute; left: 0; top: 0; font-weight: 800; }
.does .yes li::before { content: "✓"; color: var(--teal-ink); }
.does .no li::before { content: "✕"; color: var(--no); }
@media (max-width: 760px) { .does { grid-template-columns: 1fr; margin-bottom: 72px; } .does .col { padding: 24px 22px; } }

.pillars { display: grid; gap: 104px; }
.pillar { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; }
.pillar.flip .pillar-text { order: 2; }
.pillar-text p { color: var(--ink-2); margin-top: 14px; max-width: 32em; }
.pillar-text strong { color: var(--ink); }
.pillar-text h3 { font-size: clamp(1.45rem, 2.8vw, 1.9rem); line-height: 1.15; letter-spacing: -0.02em; font-weight: 800; }
.num { display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; border: 1.5px solid var(--teal-ink); color: var(--teal-ink); font-family: var(--display); font-weight: 800; margin-bottom: 18px; }
.pillar-img { margin: 0; justify-self: center; width: 100%; max-width: 460px; }
.pillar-img img { width: 100%; border-radius: 12px; box-shadow: var(--shadow); }
.pillar-img.tall { max-width: 300px; }
.pillar-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; justify-self: center; width: 100%; max-width: 460px; }
.pillar-list li { display: flex; gap: 16px; align-items: flex-start; padding: 18px 20px; border-radius: 12px; background: var(--card); border: 1px solid var(--rule); }
.pillar-list b { flex: none; display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 8px; background: rgba(34, 227, 220, .16); color: var(--teal-ink); font-family: var(--display); }
.pillar-list span { color: var(--ink-2); font-size: .95rem; line-height: 1.45; }
.pillar-list strong { display: block; color: var(--ink); font-size: 1.02rem; margin-bottom: 2px; }
@media (max-width: 860px) {
  .pillars { gap: 72px; }
  .pillar { grid-template-columns: 1fr; gap: 32px; }
  .pillar.flip .pillar-text { order: 0; }
  .pillar-img.tall { max-width: 260px; }
}

/* Features */
.features-sec { background: var(--bg-2); }
.grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.card { background: var(--card); border: 1px solid var(--rule); border-radius: 14px; padding: 24px 22px 26px; }
.card h3 { font-size: 1.05rem; margin-bottom: 10px; }
.card p { color: var(--ink-2); font-size: .95rem; line-height: 1.55; }
@media (max-width: 1000px) { .grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .grid { grid-template-columns: 1fr; } }
.soon { margin-top: 28px; display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; padding: 18px 22px; border: 1px dashed var(--rule); border-radius: 14px; }
.soon h3 { font-size: .78rem; font-family: var(--font); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3); }
.soon ul { margin: 0; padding: 0; list-style: none; display: flex; flex-wrap: wrap; gap: 8px; }
.soon li { padding: 5px 12px; border-radius: 999px; background: var(--card); border: 1px solid var(--rule); color: var(--ink-2); font-size: .9rem; }

/* Tealcut */
.tealcut { padding: 80px 0; background: radial-gradient(50% 120% at 100% 100%, rgba(34, 227, 220, .08), transparent 70%), var(--bg); }
.tealcut-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: end; }
@media (max-width: 860px) { .tealcut-grid { grid-template-columns: 1fr; gap: 20px; } }

/* FAQ */
.faq { border-top: 1px solid var(--rule); }
.faq details { border-bottom: 1px solid var(--rule); }
.faq summary { cursor: pointer; list-style: none; padding: 20px 40px 20px 0; font-weight: 650; font-size: 1.08rem; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 6px; top: 50%; transform: translateY(-50%); font-size: 1.5rem; font-weight: 400; color: var(--teal-ink); }
.faq details[open] summary::after { content: "−"; }
.faq details p { color: var(--ink-2); padding: 0 0 22px; max-width: 42em; }

/* Early access */
.signup { background: radial-gradient(60% 80% at 50% 0%, rgba(34, 227, 220, .1), transparent 70%), linear-gradient(180deg, #0d3440, #05161c); }
.signup .lead { margin-top: 14px; }
.wl { margin-top: 36px; display: grid; gap: 22px; }
.wl .row { display: grid; grid-template-columns: 1.3fr 1fr; gap: 16px; }
@media (max-width: 640px) { .wl .row { grid-template-columns: 1fr; } }
.field { display: grid; gap: 8px; font-weight: 600; font-size: .95rem; }
.field input, .field select { font: inherit; font-weight: 400; min-height: 52px; padding: 0 16px; border-radius: 12px; border: 1.5px solid #24505b; background: rgba(5, 22, 28, .7); color: var(--ink); width: 100%; }
.field select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--ink-2) 50%), linear-gradient(135deg, var(--ink-2) 50%, transparent 50%); background-position: calc(100% - 22px) 50%, calc(100% - 16px) 50%; background-size: 6px 6px; background-repeat: no-repeat; padding-right: 40px; }
.field select option { background: #0b222a; color: #e8f0f1; }
.field input::placeholder { color: #7f9aa1; }
.field input:focus-visible, .field select:focus-visible { outline: none; border-color: var(--teal); box-shadow: 0 0 0 3px rgba(34, 227, 220, .3); }
.makes { border: 0; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.makes legend { font-weight: 600; font-size: .95rem; margin-bottom: 10px; padding: 0; }
.makes legend span { color: var(--ink-2); font-weight: 400; }
.makes label { position: relative; cursor: pointer; }
.makes input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.makes label span { display: inline-flex; align-items: center; min-height: 40px; padding: 0 16px; border-radius: 999px; border: 1.5px solid #24505b; color: var(--ink-2); font-size: .93rem; transition: background-color .12s, border-color .12s, color .12s; }
.makes label:hover span { border-color: #3d7480; }
.makes input:checked + span { background: rgba(34, 227, 220, .16); border-color: var(--teal); color: var(--ink); }
.makes input:checked + span::before { content: "✓"; margin-right: 6px; color: var(--teal); font-weight: 800; }
.makes input:focus-visible + span { outline: 3px solid var(--teal); outline-offset: 2px; }
.wl .btn { justify-self: start; min-width: 220px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.wl-msg { min-height: 1.6em; color: var(--ink-2); }
.wl-msg.ok { color: var(--teal-2); font-weight: 600; }
.wl-msg.err { color: #ff9a88; }
@media (max-width: 640px) { .wl .btn { justify-self: stretch; } }

/* Footer */
.site-footer { padding: 48px 0 40px; border-top: 1px solid var(--rule); font-size: .93rem; color: var(--ink-2); }
.site-footer .wrap { display: grid; grid-template-columns: 1fr auto; gap: 24px 32px; align-items: start; }
.foot-brand img { height: 28px; width: auto; }
.foot-brand p { margin-top: 10px; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 6px 20px; }
.site-footer nav a { color: var(--ink); text-decoration: none; }
.site-footer nav a:hover { color: var(--teal); }
.legal { grid-column: 1 / -1; font-size: .82rem; color: var(--ink-3); }
@media (max-width: 640px) { .site-footer .wrap { grid-template-columns: 1fr; } }
