/* Kite website: dark, flat and quiet. One accent color, no glows or gradients. */
:root {
  --bg: #0e0e10;
  --bg-2: #141416;
  --panel: #161618;
  --panel-2: #1e1e21;
  --line: #2a2a2e;
  --line-soft: #222225;
  --text: #f2f2f3;
  --muted: #a1a1a8;
  --faint: #6e6e76;
  --blue: #0a84ff;
  --blue-hover: #3396ff;
  --green: #30d158;
  --red: #ff453a;
  --radius: 14px;
  --max: 1080px;
  --ease: cubic-bezier(.2,.8,.2,1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.6 -apple-system, BlinkMacSystemFont, "SF Pro Text", "Inter", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
[hidden] { display: none !important; }
.wrap { width: min(var(--max), 100% - 40px); margin: 0 auto; }
::selection { background: rgba(10,132,255,.35); }

/* ── nav ─────────────────────────────────────────────────────────────── */
.nav {
  position: sticky; top: 0; z-index: 50;
  /* Inside the iPhone app the page runs under the clock, so keep clear of it. */
  padding-top: env(safe-area-inset-top);
  background: rgba(14,14,16,.92);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line-soft);
}
.nav .wrap { display: flex; align-items: center; gap: 28px; height: 60px; }
.brand { display: flex; align-items: center; gap: 9px; font-weight: 650; font-size: 17px; letter-spacing: -.01em; }
.brand-mark { width: 22px; height: 22px; display: grid; grid-template: 1fr 1fr / 1fr 1fr; gap: 2.5px; }
.brand-mark i { border-radius: 2.5px; background: var(--text); }
.brand-mark i:nth-child(2), .brand-mark i:nth-child(3) { opacity: .55; }
.nav-links { display: flex; gap: 24px; margin-left: 8px; font-size: 14.5px; color: var(--muted); }
.nav-links a { transition: color .15s; }
.nav-links a:hover { color: var(--text); }
.nav-right { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.avatar { width: 30px; height: 30px; border-radius: 50%; object-fit: cover; background: var(--panel-2); display: grid; place-items: center; font-weight: 600; font-size: 13px; }

/* ── buttons ─────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 42px; padding: 0 18px; border-radius: 10px;
  font: inherit; font-size: 15px; font-weight: 560;
  border: 1px solid transparent; cursor: pointer;
  transition: background .15s, border-color .15s, opacity .15s;
}
.btn:disabled { opacity: .5; cursor: default; }
.btn:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.btn-primary { background: var(--blue); color: #fff; }
.btn-primary:hover { background: var(--blue-hover); }
.btn-ghost { background: transparent; border-color: var(--line); color: var(--text); }
.btn-ghost:hover { background: var(--panel-2); }
.btn-danger { background: transparent; border-color: rgba(255,69,58,.45); color: var(--red); }
.btn-danger:hover { background: rgba(255,69,58,.08); }
.btn-lg { height: 48px; padding: 0 22px; font-size: 16px; }
.btn-sm { height: 34px; padding: 0 12px; font-size: 14px; border-radius: 8px; }
.btn svg { width: 17px; height: 17px; }

/* ── hero ────────────────────────────────────────────────────────────── */
.hero { padding: 88px 0 40px; }
.hero-top { text-align: center; max-width: 720px; margin: 0 auto; }
.hero-top .lede { margin-left: auto; margin-right: auto; }
.hero-top .hero-cta { justify-content: center; }
.eyebrow { display: inline-block; color: var(--muted); font-size: 14px; font-weight: 500; }
.eyebrow b { display: none; }
h1 { font-size: clamp(38px, 5.4vw, 60px); line-height: 1.05; letter-spacing: -.035em; margin: 14px 0 18px; font-weight: 650; }
.grad { color: var(--muted); }
.lede { font-size: 18px; color: var(--muted); max-width: 540px; margin: 0 0 30px; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.hero-note { margin-top: 14px; font-size: 13.5px; color: var(--faint); }

/* ── sections ────────────────────────────────────────────────────────── */
section { padding: 72px 0; }
.section-head { max-width: 620px; margin-bottom: 40px; }
.kicker { color: var(--muted); font-size: 14px; font-weight: 500; margin-bottom: 10px; }
h2 { font-size: clamp(28px, 3.4vw, 38px); line-height: 1.12; letter-spacing: -.025em; margin: 0 0 12px; font-weight: 650; }
.section-head p { color: var(--muted); font-size: 17px; margin: 0; }

.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; counter-reset: step; }
.step { position: relative; padding: 26px; border-radius: var(--radius); background: var(--panel); border: 1px solid var(--line-soft); }
.step::before { counter-increment: step; content: counter(step); display: block; margin-bottom: 14px; color: var(--faint); font-weight: 600; font-size: 14px; font-variant-numeric: tabular-nums; }
.step h3 { margin: 0 0 6px; font-size: 18px; font-weight: 600; letter-spacing: -.01em; }
.step p { margin: 0; color: var(--muted); font-size: 15px; }

.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px 36px; }
.feature { padding: 0; }
.feature svg { width: 22px; height: 22px; color: var(--text); margin-bottom: 12px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.feature h3 { margin: 0 0 4px; font-size: 16.5px; font-weight: 600; }
.feature p { margin: 0; color: var(--muted); font-size: 15px; }

.security { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.checks { list-style: none; padding: 0; margin: 0; display: grid; gap: 18px; }
.checks li { display: flex; gap: 12px; }
.checks li::before { content: ""; flex: none; width: 18px; height: 18px; margin-top: 3px; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23a1a1a8' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center/18px no-repeat; }
.checks b { display: block; font-weight: 600; }
.checks span { color: var(--muted); font-size: 15px; }
.code-card { padding: 28px; border-radius: var(--radius); background: var(--panel); border: 1px solid var(--line); text-align: center; }
.code-card small { color: var(--muted); font-size: 14px; }
.code-card .code { font-size: 46px; font-weight: 600; letter-spacing: .04em; margin: 8px 0 18px; font-variant-numeric: tabular-nums; color: var(--text); }
.code-card .pair { display: flex; gap: 8px; justify-content: center; }

.cta-band { text-align: center; padding: 56px 28px; border-radius: var(--radius); background: var(--panel); border: 1px solid var(--line-soft); }
.cta-band h2 { margin-bottom: 10px; }
.cta-band p { color: var(--muted); margin: 0 0 24px; font-size: 17px; }

/* ── footer ──────────────────────────────────────────────────────────── */
footer { padding: 40px 0 calc(56px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line-soft); margin-top: 40px; color: var(--faint); font-size: 14px; }
footer .wrap { display: flex; flex-wrap: wrap; gap: 20px; align-items: center; }
footer nav { display: flex; flex-wrap: wrap; gap: 22px; margin-left: auto; }
footer a:hover { color: var(--text); }

/* ── forms & cards (sign in, account, download) ──────────────────────── */
.page { padding: 64px 0 40px; }
.narrow { width: min(420px, 100% - 40px); margin: 0 auto; }
.card { padding: 30px; border-radius: var(--radius); background: var(--panel); border: 1px solid var(--line-soft); }
.card h1 { font-size: 26px; margin: 0 0 6px; letter-spacing: -.02em; }
.card .sub { color: var(--muted); margin: 0 0 24px; font-size: 15px; }
.tabs { display: grid; grid-template-columns: 1fr 1fr; padding: 3px; border-radius: 10px; background: var(--bg); border: 1px solid var(--line-soft); margin-bottom: 22px; }
.tabs button { height: 34px; border: 0; border-radius: 8px; background: none; color: var(--muted); font: inherit; font-size: 14.5px; font-weight: 550; cursor: pointer; }
.tabs button.on { background: var(--panel-2); color: var(--text); }
.field { display: block; margin-bottom: 14px; }
.field span { display: block; font-size: 13.5px; font-weight: 500; color: var(--muted); margin: 0 0 6px; }
.field input { width: 100%; height: 44px; padding: 0 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); color: var(--text); font: inherit; font-size: 16px; outline: none; transition: border-color .15s; }
.field input:focus { border-color: var(--blue); }
.field small { display: block; margin: 6px 0 0; color: var(--faint); font-size: 12.5px; }
.form .btn { width: 100%; margin-top: 6px; }
.divider { display: flex; align-items: center; gap: 12px; color: var(--faint); font-size: 13px; margin: 20px 0; }
.divider::before, .divider::after { content: ""; flex: 1; height: 1px; background: var(--line-soft); }
.google-slot { min-height: 44px; display: flex; justify-content: center; }
.google-fallback { width: 100%; }
.error { margin: 14px 0 0; padding: 10px 12px; border-radius: 10px; background: rgba(255,69,58,.08); border: 1px solid rgba(255,69,58,.25); color: #ff8a80; font-size: 14px; }
.note { padding: 12px 14px; border-radius: 10px; background: var(--panel-2); border: 1px solid var(--line); color: var(--text); font-size: 14px; }
.note.warn { border-color: rgba(255,159,10,.35); color: #ffd08a; background: rgba(255,159,10,.06); }
.fine { color: var(--faint); font-size: 13px; text-align: center; margin-top: 18px; }
.fine a { color: var(--muted); text-decoration: underline; text-underline-offset: 2px; }

.dl-hero { text-align: center; padding: 40px 0 10px; }
.dl-hero img { width: 88px; height: 88px; border-radius: 20px; margin: 0 auto 20px; }
.dl-hero h1 { margin: 0 0 10px; font-size: clamp(32px, 4.6vw, 44px); }
.dl-hero p { color: var(--muted); margin: 0 0 26px; font-size: 17px; }
.dl-meta { color: var(--faint); font-size: 13.5px; margin-top: 14px; }
.guide { display: grid; gap: 0; margin-top: 56px; border-top: 1px solid var(--line-soft); }
.guide-step { display: grid; grid-template-columns: 36px 1fr; gap: 16px; padding: 22px 4px; border-bottom: 1px solid var(--line-soft); }
.guide-step .n { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; font-weight: 600; font-size: 14px; color: var(--text); border: 1px solid var(--line); margin-top: 2px; }
.guide-step h3 { margin: 2px 0 4px; font-size: 17px; font-weight: 600; }
.guide-step p { margin: 0; color: var(--muted); font-size: 15px; }
.kbd { display: inline-block; padding: 1px 7px; border-radius: 6px; background: var(--panel-2); border: 1px solid var(--line); font-size: 13px; color: var(--text); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; }

.account-head { display: flex; align-items: center; gap: 14px; margin-bottom: 24px; }
.account-head .avatar { width: 52px; height: 52px; font-size: 20px; }
.account-head h1 { margin: 0; font-size: 24px; }
.account-head p { margin: 2px 0 0; color: var(--muted); }
.rows { border-radius: 10px; border: 1px solid var(--line-soft); overflow: hidden; margin-bottom: 22px; }
.row { display: flex; justify-content: space-between; gap: 16px; padding: 12px 14px; font-size: 15px; }
.row + .row { border-top: 1px solid var(--line-soft); }
.row span:first-child { color: var(--muted); }
.actions { display: flex; flex-wrap: wrap; gap: 8px; }
dialog { border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); color: var(--text); padding: 24px; width: min(400px, 100% - 40px); }
dialog::backdrop { background: rgba(0,0,0,.6); }
dialog h2 { font-size: 20px; margin: 0 0 8px; }
dialog p { color: var(--muted); margin: 0 0 16px; }

/* ── prose (FAQ, privacy) ────────────────────────────────────────────── */
.prose { width: min(720px, 100% - 40px); margin: 0 auto; padding: 64px 0 20px; }
.prose h1 { font-size: clamp(32px, 4.6vw, 44px); margin: 0 0 10px; }
.prose .updated { color: var(--faint); margin-bottom: 32px; }
.prose h2 { font-size: 21px; margin: 36px 0 8px; }
.prose p, .prose li { color: #c7c7cc; }
.prose ul { padding-left: 20px; }
.faq details { border-bottom: 1px solid var(--line-soft); padding: 16px 0; }
.faq summary { cursor: pointer; font-size: 17px; font-weight: 550; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--faint); font-size: 22px; line-height: 1; transition: transform .2s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { margin: 10px 0 0; color: var(--muted); }

.center-page { min-height: 60vh; display: grid; place-items: center; text-align: center; }
.spinner { width: 26px; height: 26px; border-radius: 50%; border: 2.5px solid var(--line); border-top-color: var(--muted); animation: spin .8s linear infinite; margin: 0 auto; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ── responsive ──────────────────────────────────────────────────────── */
/* Remote tab: a text link in the desktop menu, a button where the menu hides. */
.nav-remote-link { color: var(--text) !important; }
.nav-remote-btn { display: none !important; }

@media (max-width: 900px) {
  body.signed-in .nav-remote-btn:not([hidden]) { display: inline-flex !important; }
  /* On a phone the remote is what matters; the Mac download can't install here. */
  body.signed-in .nav-download { display: none; }
  .hero { padding-top: 48px; }
  .security { grid-template-columns: 1fr; }
  .steps, .features { grid-template-columns: 1fr; }
  .nav-links { display: none; }
}
@media (max-width: 520px) {
  .card { padding: 24px; }
  footer nav { margin-left: 0; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }

/* Utility classes (the pages' CSP forbids inline style attributes) */
.narrow-wide { width: min(720px, 100% - 40px); }
.narrow-mid { width: min(560px, 100% - 40px); }
.note-spaced { margin-top: 28px; }
.fine-spaced { margin-top: 36px; }
.card-spaced { margin-top: 18px; }
.card-title { font-size: 18px; margin: 0 0 6px; }
.sub-tight { margin-bottom: 16px !important; }
.actions-end { justify-content: flex-end; margin-top: 8px; }
.big-title { font-size: 48px; margin: 0 0 10px; }
.big-sub { color: var(--muted); margin: 0 0 26px; }

.phone-note { max-width: 520px; margin: 0 auto 22px; text-align: left; }
.phone-note a { color: var(--blue); text-decoration: underline; text-underline-offset: 2px; }

/* Account emails and legal pages */
.check { display: flex; gap: 10px; align-items: flex-start; margin: 4px 2px 16px; font-size: 14px; color: var(--muted); cursor: pointer; }
.check input { width: 18px; height: 18px; margin: 1px 0 0; flex: none; accent-color: var(--blue); }
.check a, .form-link a, .note a { color: var(--text); text-decoration: underline; text-underline-offset: 2px; }
.form-link { text-align: center; margin: 16px 0 0; font-size: 14px; }
.btn-block { width: 100%; }
.center-block { text-align: center; padding: 20px 0; }
.center-block .sub { margin: 16px 0 0 !important; }
.confirm-note { margin-bottom: 18px; }
.confirm-note .actions { margin-top: 12px; align-items: center; }
.inline-status { font-size: 13.5px; color: var(--text); }
.prose h3 { font-size: 18px; margin: 26px 0 6px; }
.prose a { color: var(--blue); text-decoration: underline; text-underline-offset: 2px; }
.prose .summary { padding: 16px 18px; border-radius: 10px; background: var(--panel); border: 1px solid var(--line-soft); }
.prose .summary ul { margin: 8px 0 0; }
