/* CrossClock — time zone meeting planner
   Single stylesheet, no external fonts or images (system UI stack only), so the
   whole app renders offline and no request leaves the page. */

:root {
  --bg: #070b16;
  --bg-2: #0b1224;
  --panel: rgba(19, 27, 48, 0.82);
  --panel-solid: #111a2e;
  --line: rgba(148, 163, 184, 0.16);
  --line-strong: rgba(148, 163, 184, 0.3);
  --text: #eaf0fb;
  --text-dim: #a7b3c9;
  --text-faint: #7c8aa3;
  --accent: #ffb84d;
  --accent-soft: rgba(255, 184, 77, 0.16);
  --accent-line: rgba(255, 184, 77, 0.55);
  --teal: #5eead4;
  --teal-soft: rgba(94, 234, 212, 0.26);
  --indigo: #8b9cff;
  --indigo-soft: rgba(139, 156, 255, 0.18);
  --off: rgba(148, 163, 184, 0.09);
  --danger: #ff8080;
  --ok: #6ee7b7;
  --radius: 18px;
  --radius-sm: 12px;
  --shadow: 0 18px 50px rgba(2, 6, 20, 0.5);
  --lw: 176px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Liberation Sans", system-ui, sans-serif;
}

@media (prefers-color-scheme: light) {
  :root {
    --bg: #f4f6fb;
    --bg-2: #e9eef8;
    --panel: rgba(255, 255, 255, 0.9);
    --panel-solid: #ffffff;
    --line: rgba(15, 23, 42, 0.12);
    --line-strong: rgba(15, 23, 42, 0.24);
    --text: #101a2e;
    --text-dim: #475569;
    --text-faint: #64748b;
    --accent: #b45309;
    --accent-soft: rgba(245, 158, 11, 0.16);
    --accent-line: rgba(180, 83, 9, 0.5);
    --teal: #0f766e;
    --teal-soft: rgba(13, 148, 136, 0.2);
    --indigo: #4338ca;
    --indigo-soft: rgba(99, 102, 241, 0.14);
    --off: rgba(100, 116, 139, 0.12);
    --danger: #b91c1c;
    --ok: #047857;
    --shadow: 0 16px 40px rgba(15, 23, 42, 0.1);
  }
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background:
    radial-gradient(900px 500px at 12% -10%, rgba(94, 234, 212, 0.14), transparent 60%),
    radial-gradient(800px 520px at 92% 0%, rgba(255, 184, 77, 0.12), transparent 62%),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-2) 100%);
  background-attachment: fixed;
  min-height: 100vh;
  line-height: 1.55;
  font-size: 16px;
  overflow-x: hidden;
}

h1, h2, h3, h4 { line-height: 1.2; margin: 0 0 .5em; letter-spacing: -0.02em; font-weight: 650; }
p { margin: 0 0 1em; }
a { color: var(--teal); text-underline-offset: 2px; }
a:hover { color: var(--accent); }
code, kbd { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .92em; }
img, svg { max-width: 100%; }

.wrap { width: min(1200px, 100% - 32px); margin-inline: auto; }

.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--accent); color: #14100a; padding: 10px 16px; border-radius: 0 0 10px 0;
  font-weight: 600;
}
.skip-link:focus { left: 0; }

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

/* ---------------------------------------------------------------- header */

.site-head {
  position: sticky; top: 0; z-index: 40;
  backdrop-filter: blur(14px);
  background: color-mix(in srgb, var(--bg) 72%, transparent);
  border-bottom: 1px solid var(--line);
}
.site-head .wrap {
  display: flex; align-items: center; gap: 18px;
  min-height: 62px;
}
.brand {
  display: inline-flex; align-items: center; gap: 10px;
  color: var(--text); text-decoration: none; font-weight: 700; letter-spacing: -0.02em;
  font-size: 1.05rem;
}
.brand-mark {
  width: 30px; height: 30px; display: grid; place-items: center;
  border-radius: 9px;
  background: linear-gradient(145deg, rgba(94, 234, 212, 0.28), rgba(255, 184, 77, 0.3));
  border: 1px solid var(--line-strong);
}
.brand-mark svg { width: 18px; height: 18px; }
.site-nav { display: flex; gap: 4px; margin-left: auto; align-items: center; }
.site-nav a {
  color: var(--text-dim); text-decoration: none; font-size: .9rem; font-weight: 520;
  padding: 7px 11px; border-radius: 9px;
}
.site-nav a:hover, .site-nav a[aria-current="page"] { color: var(--text); background: rgba(148, 163, 184, 0.12); }
.head-cta {
  display: inline-flex; align-items: center; gap: 7px;
  background: var(--accent); color: #17110a; border: 0;
  font: inherit; font-weight: 650; font-size: .88rem;
  padding: 9px 14px; border-radius: 10px; cursor: pointer; text-decoration: none;
}
.head-cta:hover { filter: brightness(1.06); color: #17110a; }

@media (max-width: 720px) {
  .site-nav a { padding: 6px 8px; font-size: .84rem; }
  .site-nav a.opt { display: none; }
  .site-head .wrap { min-height: 56px; gap: 10px; }
}

/* ---------------------------------------------------------------- hero */

.hero { padding: 46px 0 26px; text-align: center; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: .78rem; letter-spacing: .08em; text-transform: uppercase;
  color: var(--text-dim); border: 1px solid var(--line);
  padding: 6px 12px; border-radius: 999px; margin-bottom: 18px;
  background: rgba(148, 163, 184, 0.06);
}
.eyebrow .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--teal); box-shadow: 0 0 0 4px var(--teal-soft); }
.hero h1 { font-size: clamp(2rem, 4.6vw, 3.3rem); margin-bottom: 14px; }
.hero h1 em { font-style: normal; color: var(--accent); }
.hero p.lede { color: var(--text-dim); font-size: clamp(1rem, 1.5vw, 1.14rem); max-width: 62ch; margin: 0 auto 18px; }
.hero-points { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-bottom: 6px; }
.pill {
  font-size: .78rem; color: var(--text-dim); border: 1px solid var(--line);
  padding: 5px 11px; border-radius: 999px; background: rgba(148, 163, 184, 0.05);
}

/* ---------------------------------------------------------------- planner */

.planner { padding: 8px 0 34px; }

.toolbar {
  display: flex; flex-wrap: wrap; align-items: center; gap: 10px;
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 12px 14px; margin-bottom: 16px; box-shadow: var(--shadow);
}
.tool-group { display: flex; align-items: center; gap: 6px; flex: 0 0 auto; min-width: max-content; }
.tool-group.grow { flex: 1 1 240px; }
.segctl.right { margin-left: auto; }
@media (max-width: 720px) { .segctl.right { margin-left: 0; } }
.tool-sep { width: 1px; align-self: stretch; background: var(--line); margin: 2px 4px; }
@media (max-width: 640px) { .tool-sep { display: none; } }

.btn {
  font: inherit; font-size: .88rem; font-weight: 560; color: var(--text);
  background: rgba(148, 163, 184, 0.12); border: 1px solid transparent;
  border-radius: 10px; padding: 8px 12px; cursor: pointer; white-space: nowrap;
  display: inline-flex; align-items: center; gap: 7px;
  transition: background .15s, border-color .15s, transform .1s;
}
.btn:hover { background: rgba(148, 163, 184, 0.2); }
.btn:active { transform: translateY(1px); }
.btn.ghost { background: transparent; border-color: var(--line); }
.btn.ghost:hover { border-color: var(--line-strong); background: rgba(148, 163, 184, 0.1); }
.btn.primary { background: var(--accent); color: #17110a; font-weight: 680; }
.btn.primary:hover { background: #ffc76a; }
.btn.icon { padding: 8px; width: 36px; height: 36px; justify-content: center; }
.btn svg { width: 16px; height: 16px; flex: none; }
.btn:disabled { opacity: .45; cursor: not-allowed; }

.field { display: inline-flex; align-items: center; gap: 7px; }
.field > label { font-size: .78rem; color: var(--text-faint); text-transform: uppercase; letter-spacing: .06em; }
select, input[type="date"], input[type="text"], input[type="number"], input[type="search"] {
  font: inherit; font-size: .9rem; color: var(--text);
  background: rgba(10, 16, 30, 0.6); border: 1px solid var(--line-strong);
  border-radius: 10px; padding: 8px 10px; min-height: 38px;
}
@media (prefers-color-scheme: light) {
  select, input[type="date"], input[type="text"], input[type="number"], input[type="search"] {
    background: #fff;
  }
}
select:focus, input:focus { border-color: var(--accent-line); outline: none; }
input[type="date"] { min-width: 148px; }
.segctl {
  display: inline-flex; flex: none; background: rgba(10, 16, 30, 0.55); border: 1px solid var(--line);
  border-radius: 10px; padding: 2px; gap: 2px;
}
@media (prefers-color-scheme: light) { .segctl { background: #eef2f9; } }
.segctl button {
  font: inherit; font-size: .8rem; font-weight: 600; color: var(--text-dim);
  background: transparent; border: 0; border-radius: 8px; padding: 6px 9px; cursor: pointer; white-space: nowrap;
}
.segctl button[aria-pressed="true"] { background: var(--panel-solid); color: var(--text); box-shadow: 0 1px 4px rgba(0, 0, 0, .25); }

.planner-grid {
  display: grid; grid-template-columns: minmax(0, 1fr) 372px; gap: 16px; align-items: start;
}
@media (max-width: 1040px) { .planner-grid { grid-template-columns: 1fr; } }

.card {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 16px; box-shadow: var(--shadow);
}
.card + .card { margin-top: 16px; }
.card-head {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  margin-bottom: 12px;
}
.card-head h2, .card-head h3 { font-size: 1rem; margin: 0; font-weight: 650; white-space: nowrap; }
.card-sub { font-size: .8rem; color: var(--text-faint); margin: 0; }

/* ---------------------------------------------------------------- timeline */

.timeline-card { padding-bottom: 12px; }

.tl { position: relative; user-select: none; }
.tl-hours {
  position: relative; height: 20px; margin-left: calc(var(--lw) + 10px);
  font-size: .68rem; color: var(--text-faint); letter-spacing: .02em;
}
.tl-hours span { position: absolute; transform: translateX(-50%); white-space: nowrap; }
.tl-hours span:first-child { transform: none; }
.tl-hours span:last-child { transform: translateX(-100%); }

.tl-rows { display: flex; flex-direction: column; gap: 6px; margin-top: 4px; }
.tl-row { display: grid; grid-template-columns: var(--lw) minmax(0, 1fr); gap: 10px; align-items: center; }

.tl-who { min-width: 0; display: flex; flex-direction: column; line-height: 1.25; padding-left: 2px; }
.who-name {
  font-size: .88rem; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.who-meta { font-size: .72rem; color: var(--text-faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.tl-track {
  position: relative; height: 38px; border-radius: 9px;
  background-color: var(--off);
  background-image: repeating-linear-gradient(90deg, var(--line) 0 1px, transparent 1px calc(100% / 24));
  overflow: hidden; cursor: crosshair;
  touch-action: pan-y;
}
.tl-track:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.seg { position: absolute; top: 0; bottom: 0; pointer-events: none; }
.seg.work { background: linear-gradient(180deg, rgba(94, 234, 212, .42), rgba(94, 234, 212, .22)); }
.seg.awake { background: linear-gradient(180deg, rgba(139, 156, 255, .26), rgba(139, 156, 255, .1)); }
.seg.off { background: transparent; }
.seg.edge { box-shadow: inset 1px 0 0 rgba(255, 255, 255, .12); }
.band {
  position: absolute; top: -1px; bottom: -1px; z-index: 3; pointer-events: none;
  background: rgba(255, 184, 77, .2);
  border-left: 2px solid var(--accent);
  border-right: 1px solid var(--accent-line);
  border-radius: 3px;
  box-shadow: 0 0 0 1px rgba(255, 184, 77, .18);
}
.tl-now { position: absolute; top: 0; bottom: 0; width: 1px; background: var(--danger); opacity: .7; pointer-events: none; z-index: 2; }
.tl-now::after {
  content: ""; position: absolute; top: -3px; left: -3px; width: 7px; height: 7px;
  border-radius: 50%; background: var(--danger);
}
.tl.hide-now .tl-now { display: none; }

.legend { display: flex; gap: 10px; flex-wrap: wrap; font-size: .72rem; color: var(--text-faint); }
.legend i { width: 9px; height: 9px; border-radius: 3px; display: inline-block; margin-right: 4px; vertical-align: -1px; }
.legend .l-work { background: rgba(94, 234, 212, .55); }
.legend .l-awake { background: rgba(139, 156, 255, .45); }
.legend .l-off { background: rgba(148, 163, 184, .3); }

.tl-hint { font-size: .76rem; color: var(--text-faint); margin: 10px 0 0; }
.tl-hint kbd {
  border: 1px solid var(--line-strong); border-bottom-width: 2px; border-radius: 5px;
  padding: 0 4px; font-size: .72rem; color: var(--text-dim);
}

.tip {
  position: fixed; z-index: 60; pointer-events: none;
  background: var(--panel-solid); border: 1px solid var(--line-strong);
  border-radius: 10px; padding: 7px 10px; font-size: .78rem; color: var(--text);
  box-shadow: 0 10px 28px rgba(0, 0, 0, .38); white-space: nowrap;
  opacity: 0; transition: opacity .1s;
}
.tip.on { opacity: 1; }
.tip b { font-weight: 650; }
.tip .tip-state { color: var(--text-dim); }
.tip .tip-work { color: var(--teal); }

/* ---------------------------------------------------------------- selected panel */

.selected-time {
  font-size: clamp(1.6rem, 4vw, 2.05rem); font-weight: 680; letter-spacing: -0.03em;
  line-height: 1.1; margin: 2px 0 4px; font-variant-numeric: tabular-nums;
}
.selected-meta { font-size: .84rem; color: var(--text-dim); margin-bottom: 12px; }
.selected-meta .chip {
  display: inline-block; background: rgba(148, 163, 184, .12); border-radius: 999px;
  padding: 2px 8px; font-size: .74rem; margin-right: 6px; color: var(--text-dim);
}

.score-row { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.score-bar { position: relative; flex: 1; height: 7px; border-radius: 99px; background: rgba(148, 163, 184, .18); overflow: hidden; }
.score-fill { position: absolute; inset: 0 auto 0 0; border-radius: 99px; background: linear-gradient(90deg, var(--indigo), var(--teal)); }
.score-label { font-size: .78rem; color: var(--text-dim); white-space: nowrap; }
.score-label b { color: var(--text); }

.people-times { list-style: none; margin: 0 0 14px; padding: 0; display: flex; flex-direction: column; gap: 7px; }
.people-times li {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; align-items: center;
  padding: 8px 10px; border-radius: 11px; background: rgba(148, 163, 184, .07);
  border-left: 3px solid transparent;
}
.people-times li.work { border-left-color: var(--teal); }
.people-times li.awake { border-left-color: var(--indigo); }
.people-times li.off { border-left-color: rgba(148, 163, 184, .35); }
.pt-name { font-size: .85rem; font-weight: 560; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pt-sub { font-size: .72rem; color: var(--text-faint); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pt-time { text-align: right; font-variant-numeric: tabular-nums; }
.pt-time b { font-size: .95rem; font-weight: 640; display: block; }
.pt-time span { font-size: .7rem; color: var(--text-faint); }

.dst-note {
  display: flex; gap: 9px; align-items: flex-start;
  font-size: .8rem; color: var(--text-dim);
  background: var(--accent-soft); border: 1px solid var(--accent-line);
  border-radius: 11px; padding: 9px 11px; margin-bottom: 12px;
}
.dst-note[hidden] { display: none; }
.dst-note svg { width: 16px; height: 16px; flex: none; margin-top: 2px; color: var(--accent); }
.dst-note b { color: var(--text); }

.actions { display: flex; flex-wrap: wrap; gap: 8px; }
.actions .btn { flex: 1 1 auto; justify-content: center; }
@media (max-width: 420px) { .actions .btn { flex: 1 1 100%; } }

/* ---------------------------------------------------------------- best windows */

.best-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.best-list li { display: flex; }
.best-btn {
  flex: 1; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 10px; align-items: center;
  text-align: left; font: inherit; color: var(--text); cursor: pointer;
  background: rgba(148, 163, 184, .07); border: 1px solid var(--line);
  border-radius: 12px; padding: 9px 11px;
}
.best-btn:hover { border-color: var(--accent-line); background: var(--accent-soft); }
.best-btn .bt-time { font-weight: 640; font-size: .9rem; font-variant-numeric: tabular-nums; }
.best-btn .bt-sub { font-size: .74rem; color: var(--text-faint); }
.best-btn .bt-score {
  font-size: .76rem; font-weight: 650; color: var(--teal);
  background: var(--teal-soft); border-radius: 999px; padding: 3px 9px; white-space: nowrap;
}
.best-btn .bt-score.low { color: var(--accent); background: var(--accent-soft); }

/* ---------------------------------------------------------------- people editor */

.add-row { display: flex; gap: 8px; margin-bottom: 12px; }
.combo { position: relative; flex: 1; min-width: 0; }
.combo input { width: 100%; }
.combo-list {
  position: absolute; z-index: 30; left: 0; right: 0; top: calc(100% + 4px);
  margin: 0; padding: 5px; list-style: none;
  background: var(--panel-solid); border: 1px solid var(--line-strong);
  border-radius: 12px; box-shadow: 0 16px 40px rgba(0, 0, 0, .4);
  max-height: 280px; overflow: auto;
}
.combo-list[hidden] { display: none; }
.combo-list li {
  padding: 7px 9px; border-radius: 8px; cursor: pointer; font-size: .86rem;
  display: flex; justify-content: space-between; gap: 10px; align-items: baseline;
}
.combo-list li .ci-country { font-size: .74rem; color: var(--text-faint); }
.combo-list li[aria-selected="true"], .combo-list li:hover { background: rgba(148, 163, 184, .16); }
.combo-list li .ci-off { font-size: .72rem; color: var(--text-faint); font-variant-numeric: tabular-nums; }
.combo-empty { padding: 9px; font-size: .82rem; color: var(--text-faint); }

.people-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.people-list li {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; align-items: center;
  padding: 8px 10px; border-radius: 11px; background: rgba(148, 163, 184, .06);
  border: 1px solid transparent;
}
.people-list li:hover { border-color: var(--line); }
.pl-main { min-width: 0; }
.pl-name { font-size: .88rem; font-weight: 580; display: flex; align-items: center; gap: 7px; }
.pl-city { font-size: .74rem; color: var(--text-faint); }
.pl-actions { display: flex; gap: 4px; }
.pl-actions button {
  background: transparent; border: 1px solid transparent; border-radius: 8px; cursor: pointer;
  color: var(--text-faint); width: 30px; height: 30px; display: grid; place-items: center;
}
.pl-actions button:hover { color: var(--text); border-color: var(--line); background: rgba(148, 163, 184, .12); }
.pl-actions svg { width: 15px; height: 15px; }
.empty-note { font-size: .84rem; color: var(--text-faint); margin: 0; }

/* ---------------------------------------------------------------- cost + teams */

.cost-row { display: flex; gap: 8px; align-items: center; }
.cost-row label { font-size: .8rem; color: var(--text-faint); white-space: nowrap; }
.cost-row input { width: 92px; }
.cost-out { margin: 10px 0 0; font-size: 1.15rem; font-weight: 650; }
.cost-out small { display: block; font-size: .74rem; font-weight: 400; color: var(--text-faint); margin-top: 2px; }

.team-row { display: flex; gap: 8px; flex-wrap: wrap; }
.team-row select { flex: 1 1 160px; min-width: 0; }

/* ---------------------------------------------------------------- marketing */

.section { padding: 40px 0; border-top: 1px solid var(--line); }
.section h2 { font-size: clamp(1.35rem, 2.6vw, 1.9rem); }
.section .lede { color: var(--text-dim); max-width: 68ch; }
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 14px; margin-top: 18px; }
.step { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.step .num {
  width: 26px; height: 26px; border-radius: 8px; display: grid; place-items: center;
  background: var(--accent-soft); color: var(--accent); font-weight: 700; font-size: .82rem; margin-bottom: 10px;
}
.step h3 { font-size: .98rem; margin-bottom: 6px; }
.step p { font-size: .86rem; color: var(--text-dim); margin: 0; }

.feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 14px; margin-top: 18px; }
.feature { padding: 16px; border-radius: var(--radius); border: 1px solid var(--line); background: var(--panel); }
.feature h3 { font-size: .95rem; margin-bottom: 6px; display: flex; align-items: center; gap: 8px; }
.feature h3 svg { width: 17px; height: 17px; color: var(--teal); flex: none; }
.feature p { font-size: .86rem; color: var(--text-dim); margin: 0; }

.faq { margin-top: 16px; display: flex; flex-direction: column; gap: 8px; }
.faq details {
  border: 1px solid var(--line); border-radius: 12px; background: var(--panel); padding: 12px 14px;
}
.faq summary { cursor: pointer; font-weight: 580; font-size: .94rem; }
.faq summary::marker { color: var(--accent); }
.faq details p { margin: 8px 0 0; font-size: .88rem; color: var(--text-dim); }

.guide-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 14px; margin-top: 18px; }
.guide-card {
  display: flex; flex-direction: column; gap: 6px; text-decoration: none; color: var(--text);
  border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; background: var(--panel);
  transition: border-color .15s, transform .15s;
}
.guide-card:hover { border-color: var(--accent-line); transform: translateY(-2px); color: var(--text); }
.guide-card .gc-kicker { font-size: .72rem; text-transform: uppercase; letter-spacing: .08em; color: var(--accent); }
.guide-card h3 { font-size: .98rem; margin: 0; }
.guide-card p { font-size: .84rem; color: var(--text-dim); margin: 0; }

.ad-slot { margin: 26px 0 10px; min-height: 96px; display: flex; justify-content: center; }
.ad-slot ins { display: block; width: 100%; }

/* ---------------------------------------------------------------- footer */

.site-foot { border-top: 1px solid var(--line); padding: 30px 0 40px; margin-top: 20px; }
.foot-grid { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 22px; }
@media (max-width: 760px) { .foot-grid { grid-template-columns: 1fr 1fr; } }
.site-foot h4 { font-size: .78rem; text-transform: uppercase; letter-spacing: .08em; color: var(--text-faint); margin-bottom: 10px; }
.site-foot ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 7px; }
.site-foot a { color: var(--text-dim); text-decoration: none; font-size: .86rem; }
.site-foot a:hover { color: var(--accent); }
.foot-note { font-size: .78rem; color: var(--text-faint); margin: 20px 0 0; }
.foot-brand p { font-size: .84rem; color: var(--text-dim); max-width: 34ch; }

/* ---------------------------------------------------------------- toast + dialog */

#toast {
  position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 20px);
  background: var(--panel-solid); color: var(--text); border: 1px solid var(--line-strong);
  border-radius: 12px; padding: 11px 16px; font-size: .86rem; z-index: 90;
  box-shadow: 0 16px 40px rgba(0, 0, 0, .45); opacity: 0; pointer-events: none;
  transition: opacity .18s, transform .18s; max-width: min(92vw, 420px); text-align: center;
}
#toast.on { opacity: 1; transform: translate(-50%, 0); }

dialog {
  border: 1px solid var(--line-strong); border-radius: var(--radius);
  background: var(--panel-solid); color: var(--text); padding: 0;
  width: min(520px, calc(100vw - 24px)); box-shadow: var(--shadow);
}
dialog::backdrop { background: rgba(4, 8, 18, .62); backdrop-filter: blur(2px); }
.dlg-body { padding: 18px; }
.dlg-body h2 { font-size: 1.05rem; margin-bottom: 4px; }
.dlg-body .card-sub { margin-bottom: 14px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.form-grid .full { grid-column: 1 / -1; }
.form-grid label { font-size: .76rem; text-transform: uppercase; letter-spacing: .06em; color: var(--text-faint); display: block; margin-bottom: 4px; }
.form-grid input, .form-grid select { width: 100%; }
.dlg-foot { display: flex; justify-content: flex-end; gap: 8px; margin-top: 16px; flex-wrap: wrap; }
.dlg-foot .spacer { margin-right: auto; }

/* ---------------------------------------------------------------- content pages */

.doc { padding: 34px 0 40px; }
.doc-head { max-width: 74ch; margin-bottom: 22px; }
.doc-head h1 { font-size: clamp(1.8rem, 3.6vw, 2.5rem); }
.doc-head .lede { color: var(--text-dim); font-size: 1.02rem; }
.prose { max-width: 74ch; }
.prose h2 { font-size: 1.3rem; margin-top: 32px; }
.prose h3 { font-size: 1.06rem; margin-top: 22px; }
.prose p, .prose li { color: var(--text-dim); font-size: .96rem; }
.prose li { margin-bottom: 6px; }
.prose ul, .prose ol { padding-left: 22px; margin-bottom: 16px; }
.prose strong { color: var(--text); }
.prose blockquote {
  margin: 18px 0; padding: 12px 16px; border-left: 3px solid var(--accent);
  background: rgba(148, 163, 184, .07); border-radius: 0 10px 10px 0; color: var(--text-dim);
}
.prose table { width: 100%; border-collapse: collapse; margin: 16px 0; font-size: .88rem; }
@media (max-width: 640px) {
  .prose table { display: block; overflow-x: auto; -webkit-overflow-scrolling: touch; white-space: nowrap; }
}
.prose th, .prose td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--line); }
.prose th { color: var(--text); font-weight: 600; }
.prose td { color: var(--text-dim); }
.prose .callout {
  border: 1px solid var(--accent-line); background: var(--accent-soft);
  border-radius: 12px; padding: 12px 14px; font-size: .9rem; color: var(--text-dim);
}
.toc { border: 1px solid var(--line); border-radius: 12px; padding: 12px 16px; background: var(--panel); margin: 18px 0; }
.toc h2 { font-size: .8rem; text-transform: uppercase; letter-spacing: .08em; color: var(--text-faint); margin: 0 0 8px; }
.toc ol { margin: 0; padding-left: 18px; font-size: .88rem; }
.toc a { color: var(--text-dim); text-decoration: none; }
.toc a:hover { color: var(--accent); }
.cta-band {
  margin: 28px 0 0; padding: 18px; border-radius: var(--radius);
  border: 1px solid var(--line); background: var(--panel);
  display: flex; flex-wrap: wrap; gap: 14px; align-items: center; justify-content: space-between;
}
.cta-band p { margin: 0; font-size: .92rem; color: var(--text-dim); }

.nf { text-align: center; padding: 70px 0; }
.nf h1 { font-size: clamp(2.2rem, 7vw, 3.4rem); }
.nf p { color: var(--text-dim); }

@media (max-width: 600px) {
  .field > span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .tool-group .field { flex: 1 1 auto; min-width: 0; }
  .field select { max-width: 100%; min-width: 0; }
  .tool-group { max-width: 100%; }
  .toolbar { gap: 8px 10px; }
}

@media (max-width: 720px) {
  :root { --lw: 0px; }
  .tl-row { grid-template-columns: 1fr; gap: 3px; }
  .tl-who { flex-direction: row; gap: 8px; align-items: baseline; }
  .who-name { font-size: .82rem; }
  .tl-hours { margin-left: 0; }
  .tl-track { height: 32px; }
  .hero { padding: 32px 0 20px; }
  .card { padding: 14px; }
  .selected-time { font-size: 1.7rem; }
  .planner { padding-bottom: 24px; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}

@media print {
  .site-head, .site-foot, .ad-slot, .actions, .tl-hint, .best-card, .cost-card, .teams-card { display: none !important; }
  body { background: #fff; color: #111; }
}
