/* Whenna — product styles */
:root {
  --bg: #fbfaf8;
  --card: #ffffff;
  --ink: #1a1c1e;
  --muted: #6b7078;
  --line: #e7e4de;
  --accent: #2f6df6;
  --accent-rgb: 47, 109, 246;
  --accent-ink: #ffffff;
  --accent-soft: #e8effe;
  --good: #1c8a4c;
  --heat0: #f4f2ee;
  --shadow: 0 1px 2px rgba(20,22,25,.05), 0 8px 24px rgba(20,22,25,.06);
  --radius: 14px;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #121417; --card: #1b1e22; --ink: #eceef0; --muted: #9aa1a9;
    --line: #2b2f34; --accent: #6b9bff; --accent-rgb: 107, 155, 255;
    --accent-ink: #0d1524; --accent-soft: #1e2c4a;
    --good: #4cc47f; --heat0: #23262b;
    --shadow: 0 1px 2px rgba(0,0,0,.4), 0 8px 24px rgba(0,0,0,.35);
  }
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  background: var(--bg); color: var(--ink);
  font: 16px/1.5 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  min-height: 100dvh; display: flex; flex-direction: column;
  -webkit-tap-highlight-color: transparent;
}
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 6px; }
main { flex: 1; width: 100%; max-width: 720px; margin: 0 auto; padding: 20px 16px 40px; }
h1 { font-size: clamp(28px, 6vw, 42px); line-height: 1.12; letter-spacing: -.02em; margin: 24px 0 10px; }
h1 .hl { color: var(--accent); }
.sub { color: var(--muted); font-size: 17px; margin: 0 0 26px; max-width: 46ch; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px; }
label.f { display: block; font-size: 13px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; margin: 16px 0 6px; }
label.f:first-child { margin-top: 0; }
input[type=text] {
  width: 100%; font: inherit; font-size: 17px; color: var(--ink);
  background: var(--bg); border: 1.5px solid var(--line); border-radius: 10px; padding: 12px 14px; outline: none;
}
input[type=text]:focus { border-color: var(--accent); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  font: inherit; font-size: 14px; padding: 10px 13px; border-radius: 999px; cursor: pointer;
  border: 1.5px solid var(--line); background: var(--card); color: var(--ink); user-select: none;
  -webkit-user-select: none; touch-action: manipulation; min-height: 40px;
}
@media (hover: hover) { .chip:not(.on):hover { border-color: var(--accent); } }
.chip.on { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); font-weight: 600; }
.hours { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.chip.small { font-size: 13px; padding: 7px 11px; min-height: 34px; }
select {
  font: inherit; font-size: 16px; padding: 10px 12px; border-radius: 10px;
  border: 1.5px solid var(--line); background: var(--card); color: var(--ink);
}
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: inherit; font-size: 17px; font-weight: 700; cursor: pointer;
  background: var(--accent); color: var(--accent-ink); border: none;
  border-radius: 12px; padding: 14px 22px; width: 100%; margin-top: 20px;
  touch-action: manipulation; min-height: 48px;
}
.btn:active { transform: scale(.99); }
@media (hover: hover) { .btn:hover { filter: brightness(1.06); } }
.btn.secondary { background: var(--accent-soft); color: var(--accent); }
.btn[disabled] { opacity: .5; cursor: default; }
.err { color: #c0392b; font-size: 14px; margin-top: 10px; }

/* meeting page */
.mtitle { font-size: clamp(24px, 5.5vw, 34px); letter-spacing: -.02em; margin: 14px 0 2px; }
.msub { color: var(--muted); font-size: 14px; margin: 0 0 14px; }
.namebar { display: flex; gap: 10px; margin: 12px 0 16px; }
.namebar input { flex: 1; }
.best {
  border-radius: var(--radius); padding: 14px 16px; margin: 0 0 16px;
  background: var(--accent-soft); color: var(--ink); border: 1px solid var(--line);
  font-size: 15px;
}
.best b { color: var(--accent); }
.best .who { color: var(--muted); font-size: 13px; margin-top: 2px; word-break: break-all; }
.best .calbtn {
  display: inline-flex; align-items: center; gap: 6px; margin-top: 10px;
  font: inherit; font-size: 14px; font-weight: 700; cursor: pointer;
  background: var(--accent); color: var(--accent-ink); border: none;
  border-radius: 999px; padding: 9px 16px; touch-action: manipulation; min-height: 40px;
}

/* calendar chooser sheet */
.sheetback {
  position: fixed; inset: 0; background: rgba(10, 12, 16, .45); z-index: 90;
  display: flex; align-items: flex-end; justify-content: center;
}
@media (min-width: 560px) { .sheetback { align-items: center; } }
.sheet {
  background: var(--card); border: 1px solid var(--line); border-radius: 18px 18px 0 0;
  width: 100%; max-width: 430px; padding: 18px 18px calc(18px + env(safe-area-inset-bottom));
  box-shadow: var(--shadow);
}
@media (min-width: 560px) { .sheet { border-radius: 18px; padding-bottom: 18px; } }
.sheet h3 { margin: 0 0 2px; font-size: 17px; letter-spacing: -.01em; }
.sheet .when { color: var(--muted); font-size: 14px; margin: 0 0 14px; }
.calopt {
  display: flex; align-items: center; gap: 12px; width: 100%; text-align: left;
  font: inherit; font-size: 16px; font-weight: 600; color: var(--ink);
  background: var(--bg); border: 1.5px solid var(--line); border-radius: 12px;
  padding: 13px 14px; margin-top: 8px; cursor: pointer; text-decoration: none;
  touch-action: manipulation; min-height: 50px;
}
@media (hover: hover) { .calopt:hover { border-color: var(--accent); } }
.calopt .ic { font-size: 20px; width: 26px; text-align: center; }
.calopt .hint { margin-left: auto; font-size: 12px; font-weight: 400; color: var(--muted); }
.sheet .cancel {
  width: 100%; margin-top: 12px; font: inherit; font-size: 15px; font-weight: 600;
  color: var(--muted); background: none; border: none; padding: 10px; cursor: pointer;
}
.gridwrap {
  overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--card); box-shadow: var(--shadow);
  overscroll-behavior-x: contain; -webkit-overflow-scrolling: touch;
}
table.grid { border-collapse: collapse; width: 100%; min-width: 340px; }
table.grid th {
  font-size: 12px; font-weight: 600; color: var(--muted); padding: 10px 4px 8px;
  position: sticky; top: 0; background: var(--card); z-index: 1; text-align: center;
}
table.grid th .d { display: block; font-size: 15px; color: var(--ink); font-weight: 700; }
table.grid td.hr { font-size: 11px; color: var(--muted); padding: 0 8px; text-align: right; white-space: nowrap; width: 1%; }
table.grid td.hr.subhr { font-size: 10px; opacity: .75; }
table.grid.half td.cell { height: 32px; }
td.cell {
  height: 44px; min-width: 44px; border: 1px solid var(--line); cursor: pointer;
  background: var(--heat0); position: relative; touch-action: manipulation;
  user-select: none; -webkit-user-select: none;
}
@media (hover: hover) { td.cell:not(.mine):hover { outline: 2px solid var(--accent); outline-offset: -2px; opacity: .9; } }
td.cell .n { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 11px; color: var(--muted); pointer-events: none; }
td.cell.mine { outline: 3px solid var(--accent); outline-offset: -3px; }
td.cell.best { box-shadow: inset 0 0 0 2px var(--good); }
.legend { display: flex; align-items: center; gap: 14px; color: var(--muted); font-size: 13px; margin: 12px 2px; flex-wrap: wrap; }
.legend .sw { display: inline-block; width: 14px; height: 14px; border-radius: 4px; vertical-align: -2px; margin-right: 5px; border: 1px solid var(--line); }
.people { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 18px; }
.pill { font-size: 13px; padding: 5px 11px; border-radius: 999px; background: var(--card); border: 1px solid var(--line); color: var(--muted); }
.pill.me { border-color: var(--accent); color: var(--accent); font-weight: 600; }
.sharebar { display: flex; gap: 10px; margin: 16px 0; }
.sharebar .btn { margin-top: 0; }
.toast {
  position: fixed; left: 50%; bottom: 84px; transform: translateX(-50%);
  background: var(--ink); color: var(--bg); padding: 10px 18px; border-radius: 999px;
  font-size: 14px; font-weight: 600; opacity: 0; transition: opacity .25s; pointer-events: none; z-index: 50;
}
.toast.show { opacity: 1; }
.saving-row { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-top: 8px; }
.saving { font-size: 12px; color: var(--muted); min-height: 18px; }
.linklike {
  font: inherit; font-size: 12px; color: var(--muted); background: none; border: none;
  cursor: pointer; text-decoration: underline; padding: 4px; white-space: nowrap;
}
.linklike:hover { color: var(--accent); }
.best .linklike { margin-left: 10px; vertical-align: middle; }
.best.locked { border-color: var(--good); }
.calbtn.lock { background: var(--good); color: #fff; margin-left: 8px; }
.makeown { text-align: center; color: var(--muted); font-size: 14px; margin: 24px 0 8px; }
.makeown a { color: var(--accent); font-weight: 700; text-decoration: none; }
.msub a { color: var(--accent); }

/* how it works */
.how { display: grid; gap: 12px; margin-top: 28px; }
.how .step { display: flex; gap: 12px; align-items: baseline; color: var(--muted); font-size: 15px; }
.how .step b { color: var(--ink); }
.how .num {
  flex: none; width: 24px; height: 24px; border-radius: 999px; background: var(--accent-soft); color: var(--accent);
  display: inline-flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700;
}

footer.foot {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  max-width: 720px; width: 100%; margin: 0 auto; padding: 14px 16px calc(14px + env(safe-area-inset-bottom));
  color: var(--muted); font-size: 13px;
}
.wordmark { display: inline-flex; align-items: center; gap: 7px; font-weight: 800; color: var(--ink); text-decoration: none; letter-spacing: -.01em; }
.wordmark .dot { width: 12px; height: 12px; border-radius: 999px; background: var(--accent); display: inline-block; }
.tag { text-align: right; }
@media (max-width: 480px) { .tag { display: none; } }
