/* MyPayHours. One stylesheet, no framework. Fonts are self-hosted (OFL, see /assets/fonts/). */
@font-face { font-family: "Inter"; src: url("/assets/fonts/inter-var.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }
@font-face { font-family: "Manrope"; src: url("/assets/fonts/manrope-800.woff2") format("woff2"); font-weight: 800; font-display: swap; }

:root {
  --bg: #f5f7f6; --surface: #ffffff; --surface-2: #eef3f1; --ink: #0e1a18; --muted: #56655f; --line: #dce3e0;
  --brand: #0b7a62; --brand-hover: #09664f; --brand-ink: #ffffff; --brand-soft: #e3f2ec;
  --hero: #0d2622; --hero-2: #12332d; --hero-ink: #f1f7f5; --hero-muted: #a9c2ba; --hero-line: rgba(255,255,255,.12);
  --accent: #f2b53a; --warn-bg: #fff4de; --warn: #9a5b00; --focus: #2f6feb;
  --radius: 14px; --radius-s: 10px;
  --shadow: 0 1px 2px rgba(14,26,24,.06), 0 8px 24px -6px rgba(14,26,24,.12);
  --shadow-l: 0 2px 4px rgba(14,26,24,.05), 0 24px 48px -12px rgba(13,38,34,.28);
  --display: "Manrope", "Inter", system-ui, sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0c1312; --surface: #141d1b; --surface-2: #1a2522; --ink: #e8efec; --muted: #9fb0aa; --line: #263431;
    --brand: #3cc29c; --brand-hover: #5ad3b0; --brand-ink: #04201a; --brand-soft: #16302a;
    --hero: #0a1d1a; --hero-2: #0f2723; --warn-bg: #33260f; --warn: #ffc56b; --focus: #7db4ff;
    --shadow: 0 1px 2px rgba(0,0,0,.4), 0 8px 24px -6px rgba(0,0,0,.5);
    --shadow-l: 0 24px 48px -12px rgba(0,0,0,.6);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0c1312; --surface: #141d1b; --surface-2: #1a2522; --ink: #e8efec; --muted: #9fb0aa; --line: #263431;
  --brand: #3cc29c; --brand-hover: #5ad3b0; --brand-ink: #04201a; --brand-soft: #16302a;
  --hero: #0a1d1a; --hero-2: #0f2723; --warn-bg: #33260f; --warn: #ffc56b; --focus: #7db4ff;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 16px; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 16.5px/1.6 "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-feature-settings: "cv11", "ss01"; -webkit-font-smoothing: antialiased;
}
.wrap { max-width: 1160px; margin: 0 auto; padding: 0 20px; }
a { color: var(--brand); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { color: var(--brand-hover); }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 4px; }
.skip { position: absolute; left: -999px; top: 0; background: var(--surface); padding: 8px 12px; z-index: 50; }
.skip:focus { left: 8px; }
[hidden] { display: none !important; }
.sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.icon { flex: none; }
.hint, .unit { font-weight: 400; color: var(--muted); }

/* ---------- Header ---------- */
.site-header { background: var(--hero); color: var(--hero-ink); position: relative; z-index: 20; }
.bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 64px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: inherit; text-decoration: none; font-family: var(--display); font-weight: 800; font-size: 1.2rem; letter-spacing: -.02em; }
.brand:hover { color: inherit; }
.brand b { color: var(--accent); font-weight: 800; }
.site-header .logo, .site-footer .logo { color: #0b7a62; }
.nav { display: flex; align-items: center; gap: 4px; }
.nav-link, .dd > summary {
  display: inline-flex; align-items: center; gap: 4px; color: var(--hero-ink); text-decoration: none; font-weight: 500; font-size: .95rem;
  padding: 8px 12px; border-radius: 8px; cursor: pointer; list-style: none; min-height: 40px;
}
.dd > summary::-webkit-details-marker { display: none; }
.nav-link:hover, .dd > summary:hover, .dd[open] > summary { background: var(--hero-line); color: #fff; }
.nav-link[aria-current], .dd[data-active] > summary { color: var(--accent); }
.dd { position: relative; }
.dd[open] > summary .icon { transform: rotate(180deg); }
.dd-panel {
  position: absolute; top: calc(100% + 8px); right: -8px; width: 340px; background: var(--surface); color: var(--ink);
  border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-l); padding: 8px;
}
.dd-panel a { display: flex; gap: 12px; align-items: flex-start; padding: 10px 12px; border-radius: var(--radius-s); color: var(--ink); text-decoration: none; }
.dd-panel a .icon { margin-top: 2px; color: var(--brand); }
.dd-panel a:hover, .dd-panel a[aria-current] { background: var(--surface-2); }
.dd-panel b { display: block; font-weight: 600; font-size: .95rem; }
.dd-panel small { display: block; color: var(--muted); font-size: .84rem; line-height: 1.4; }

.mobile-menu { display: none; }
.mobile-menu > summary { list-style: none; cursor: pointer; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 10px; }
.mobile-menu > summary::-webkit-details-marker { display: none; }
.mobile-menu[open] > summary { background: var(--hero-line); }
.mm-panel {
  position: absolute; left: 0; right: 0; top: 100%; background: var(--surface); color: var(--ink); padding: 8px 16px 20px;
  border-bottom: 1px solid var(--line); box-shadow: var(--shadow-l); max-height: calc(100vh - 64px); overflow-y: auto;
}
.mm-title { margin: 14px 0 4px; font-size: .75rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); font-weight: 600; }
.mm-panel a { display: flex; align-items: center; gap: 12px; padding: 10px 8px; min-height: 44px; color: var(--ink); text-decoration: none; border-radius: 8px; font-weight: 500; }
.mm-panel a .icon { color: var(--brand); }
.mm-panel a[aria-current] { background: var(--surface-2); }
@media (max-width: 760px) {
  .nav { display: none; }
  .mobile-menu { display: block; }
}

/* ---------- Hero ---------- */
.hero { background: var(--hero); color: var(--hero-ink); padding: 28px 0 44px; position: relative; overflow: hidden; }
.hero::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(900px 400px at 85% -10%, rgba(60,194,156,.22), transparent 60%), radial-gradient(600px 300px at -10% 120%, rgba(242,181,58,.08), transparent 60%);
}
.hero .wrap { position: relative; }
.hero.has-tool { padding-bottom: 112px; }
.hero h1 {
  font-family: var(--display); font-weight: 800; font-size: clamp(1.9rem, 1.2rem + 2.6vw, 3rem); line-height: 1.08;
  letter-spacing: -.03em; margin: 10px 0 12px; max-width: 20ch; text-wrap: balance;
}
.hero .lede { font-size: 1.1rem; line-height: 1.55; color: var(--hero-ink); opacity: .92; max-width: 64ch; margin: 0 0 12px; }
.hero .lede strong { color: #fff; }
.hero .byline { color: var(--hero-muted); font-size: .88rem; margin: 0; }
.hero .byline a, .hero .crumbs a { color: var(--hero-ink); }
.crumbs { font-size: .85rem; color: var(--hero-muted); display: flex; flex-wrap: wrap; gap: 6px; }
.crumbs a { text-decoration: none; }
.crumbs a:hover { text-decoration: underline; }
.chips { list-style: none; padding: 0; margin: 18px 0 0; display: flex; flex-wrap: wrap; gap: 8px; }
.chips li { display: inline-flex; align-items: center; gap: 6px; font-size: .84rem; font-weight: 500; padding: 5px 12px 5px 9px; border-radius: 999px; background: rgba(255,255,255,.07); border: 1px solid var(--hero-line); color: var(--hero-ink); }
.chips .icon { color: var(--accent); }
.lift { margin-top: -84px; position: relative; z-index: 2; }

/* ---------- Controls ---------- */
input, select, button, textarea { font: inherit; color: inherit; }
input, select {
  width: 100%; min-height: 44px; padding: 9px 12px; border: 1px solid var(--line); border-radius: var(--radius-s);
  background: var(--surface); transition: border-color .15s, box-shadow .15s;
}
input:hover, select:hover { border-color: color-mix(in srgb, var(--brand) 40%, var(--line)); }
input:focus, select:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 22%, transparent); }
input[type="time"] { min-width: 0; }
input[type="checkbox"] { width: 18px; height: 18px; min-height: 0; accent-color: var(--brand); vertical-align: -3px; margin-right: 6px; }
select {
  appearance: none; padding-right: 34px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' stroke='%2356655f' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M4 6l4 4 4-4'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 12px center;
}
.field label, .field > .label { display: block; font-size: .85rem; font-weight: 600; margin-bottom: 6px; }
.field label .hint { font-size: .8rem; }
.money { position: relative; }
.money span { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
.money input { padding-left: 26px; }

button, .button {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 10px 18px;
  border-radius: var(--radius-s); border: 1px solid var(--brand); background: var(--brand); color: var(--brand-ink);
  font-weight: 600; cursor: pointer; text-decoration: none; line-height: 1.3; transition: background .15s, border-color .15s, transform .05s;
}
button:hover, .button:hover { background: var(--brand-hover); border-color: var(--brand-hover); color: var(--brand-ink); }
button:active { transform: translateY(1px); }
button.quiet { background: var(--surface); color: var(--ink); border-color: var(--line); }
button.quiet:hover { background: var(--surface-2); border-color: var(--line); color: var(--ink); }
button.small { min-height: 40px; padding: 8px 14px; font-size: .9rem; }

.seg { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius-s); padding: 3px; gap: 3px; min-height: 44px; }
.seg button { min-height: 36px; padding: 4px 10px; border: 0; background: transparent; color: var(--muted); font-weight: 600; font-size: .92rem; border-radius: 8px; }
.seg button:hover { background: transparent; color: var(--ink); }
.seg button[aria-checked="true"] { background: var(--surface); color: var(--ink); box-shadow: 0 1px 3px rgba(14,26,24,.15); }

/* ---------- Calculator shell (all three tools) ---------- */
.calc { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow-l); padding: 20px; margin: 0 0 32px; container-type: inline-size; }
.prose .calc { box-shadow: var(--shadow); margin: 20px 0 28px; }
.settings { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(180px, 100%), 1fr)); gap: 14px; }
.settings .field.wide { grid-column: span 2; }
@container (max-width: 420px) { .settings .field.wide { grid-column: 1 / -1; } }
.settings.meta { margin-top: 14px; }
.tip { font-size: .9rem; color: var(--muted); margin: 12px 0; }
.errors { background: var(--warn-bg); color: var(--ink); border-left: 3px solid var(--warn); border-radius: 8px; padding: 6px 12px; margin: 0 0 12px; font-size: .92rem; }
.errors p { margin: 4px 0; }
.status { color: var(--muted); font-size: .88rem; min-height: 1.3em; margin: 8px 0 0; }
.saved-note { font-size: .82rem; color: var(--muted); margin: 8px 0 0; }

/* Time card */
.calc-grid { display: grid; gap: 20px; }
@container (min-width: 860px) {
  .calc-grid { grid-template-columns: minmax(0, 1fr) 320px; gap: 28px; }
  .calc-side { position: sticky; top: 16px; align-self: start; }
}
.calc-head { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(190px, 100%), 1fr)); gap: 14px; }
@container (min-width: 560px) { .calc-head { grid-template-columns: 1fr 1.25fr 1fr; } }
.more-opts { margin-top: 14px; border: 1px solid var(--line); border-radius: var(--radius-s); background: var(--surface-2); }
.more-opts > summary { padding: 10px 14px; font-weight: 600; font-size: .92rem; cursor: pointer; list-style: none; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.more-opts > summary::-webkit-details-marker { display: none; }
.more-opts > summary::before { content: ""; width: 8px; height: 8px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(-45deg); transition: transform .15s; margin-right: 2px; }
.more-opts[open] > summary::before { transform: rotate(45deg); }
.more-opts > summary .hint { font-size: .84rem; }
.more-opts .settings { padding: 4px 14px 14px; }
.toolbar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px 16px; margin: 18px 0 4px; }
.toolbar .tip { margin: 0; flex: 1 1 260px; }
.toolbar-btns { display: flex; flex-wrap: wrap; gap: 8px; }

.week { border: 0; padding: 0; margin: 14px 0 0; min-width: 0; }
.week legend { font-weight: 700; font-size: .8rem; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); padding: 0; margin-bottom: 6px; }
.calc[data-store] .week[data-week-block="1"]:has(~ .week[hidden]) legend { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
table { border-collapse: collapse; width: 100%; }
.card { border: 1px solid var(--line); border-radius: var(--radius-s); border-collapse: separate; border-spacing: 0; overflow: hidden; }
.card thead th { font-size: .78rem; color: var(--muted); font-weight: 600; text-align: left; padding: 10px 8px; background: var(--surface-2); border-bottom: 1px solid var(--line); }
.card thead th:first-child { padding-left: 14px; }
.card thead th:last-child { text-align: right; padding-right: 14px; }
.card tbody th, .card tbody td { padding: 6px 4px; border-bottom: 1px solid var(--line); }
.card tbody th { padding-left: 14px; }
.card tbody tr:hover { background: color-mix(in srgb, var(--surface-2) 50%, transparent); }
.card .day { font-weight: 600; font-size: .94rem; white-space: nowrap; text-align: left; width: 22%; }
.card td input { min-height: 42px; }
.card .out, .card tfoot td { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; min-width: 4.5em; padding-right: 14px; font-weight: 600; }
.card .out { color: var(--muted); }
.card tr.has-value .out, .card .out:not(:has(span[aria-hidden])) { color: var(--ink); }
.card tfoot th, .card tfoot td { padding: 12px 14px; font-weight: 700; text-align: left; background: var(--surface-2); }
.card tfoot td { text-align: right; font-size: 1.05rem; color: var(--ink); }
.card tr.has-error input { border-color: var(--warn); }
.card tr.has-error .out { color: var(--warn); }
.tag { display: inline-block; font-size: .68rem; font-weight: 600; background: var(--brand-soft); color: var(--brand); border-radius: 4px; padding: 1px 5px; vertical-align: middle; margin-right: 4px; }

/* Results card */
.calc-side .results { background: var(--hero); color: var(--hero-ink); border-radius: var(--radius); padding: 20px; position: relative; overflow: hidden; }
.calc-side .results::before { content: ""; position: absolute; inset: 0; background: radial-gradient(400px 200px at 100% 0, rgba(60,194,156,.25), transparent 70%); pointer-events: none; }
.calc-side .results > * { position: relative; }
.results h2 { font-size: .78rem; text-transform: uppercase; letter-spacing: .08em; font-weight: 700; margin: 0 0 12px; color: var(--hero-muted); font-family: inherit; }
.big, .paybox { display: flex; flex-direction: column; }
.big .label, .paybox .label { font-size: .85rem; color: var(--hero-muted); }
.big .num { font-family: var(--display); font-weight: 800; font-size: 3rem; line-height: 1.05; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.big .sub, .paybox .sub { font-size: .85rem; color: var(--hero-muted); }
.breakdown { margin: 16px 0; padding: 0; border-top: 1px solid var(--hero-line); }
.breakdown > div { display: flex; justify-content: space-between; padding: 9px 0; border-bottom: 1px solid var(--hero-line); }
.breakdown dt { color: var(--hero-muted); font-size: .92rem; }
.breakdown dd { margin: 0; font-weight: 700; font-variant-numeric: tabular-nums; }
.paybox { background: rgba(255,255,255,.06); border: 1px solid var(--hero-line); border-radius: var(--radius-s); padding: 12px 14px; }
.paybox .num { font-family: var(--display); font-weight: 800; font-size: 2rem; color: var(--accent); font-variant-numeric: tabular-nums; line-height: 1.15; }
.paybox.empty { margin: 0; color: var(--hero-muted); font-size: .9rem; border-style: dashed; }
.paybox[hidden] { display: none; }
.taxline { margin-top: 12px; display: grid; grid-template-columns: 1fr auto; gap: 2px 8px; font-size: .9rem; }
.taxline small { grid-column: 1 / -1; color: var(--hero-muted); }
.calc-side a { color: var(--hero-ink); }
.rule-note, .weeks-detail { font-size: .86rem; color: var(--hero-muted); margin: 12px 0 0; }
.weeks-detail p { margin: 4px 0; }
.calc-side .errors { background: rgba(242,181,58,.14); color: var(--hero-ink); border-left-color: var(--accent); }
.calc-side .actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 16px; }
.calc-side .actions [data-copy] { grid-column: 1 / -1; background: var(--accent); border-color: var(--accent); color: #2a1c00; }
.calc-side .actions [data-copy]:hover { background: #f6c561; }
.calc-side .actions .quiet { background: transparent; color: var(--hero-ink); border-color: var(--hero-line); }
.calc-side .actions .quiet:hover { background: var(--hero-line); }
.calc-side .status, .calc-side .saved-note { color: var(--hero-muted); }

/* Sticky summary on phones */
.sticky-sum {
  position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 30; display: flex; align-items: center; gap: 12px;
  background: var(--hero); color: var(--hero-ink); border-radius: 14px; padding: 8px 8px 8px 16px; box-shadow: var(--shadow-l); font-size: .95rem;
}
.sticky-sum[hidden] { display: none; }
.sticky-sum b { font-family: var(--display); font-size: 1.2rem; }
.sticky-sum [data-s="pay"] { color: var(--accent); font-weight: 700; }
.sticky-sum a { margin-left: auto; background: var(--accent); color: #2a1c00; text-decoration: none; font-weight: 700; padding: 10px 14px; border-radius: 10px; min-height: 44px; display: inline-flex; align-items: center; }
@media (min-width: 900px) { .sticky-sum { display: none !important; } }

/* Tax and blended results: stat tiles */
.calc > .results { margin-top: 20px; padding-top: 20px; border-top: 1px solid var(--line); }
.calc > .results h2 { color: var(--muted); }
.totals { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(170px, 100%), 1fr)); gap: 10px; margin: 0; }
.totals > div { background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius-s); padding: 12px 14px; }
.totals > div:last-child { background: var(--hero); border-color: var(--hero); color: var(--hero-ink); }
.totals > div:last-child dt, .totals > div:last-child .sub { color: var(--hero-muted); }
.totals > div:last-child dd:not(.sub) { color: var(--accent); }
.totals dt { font-size: .82rem; color: var(--muted); font-weight: 500; }
.totals dd { margin: 2px 0 0; font-family: var(--display); font-weight: 800; font-size: 1.55rem; line-height: 1.2; font-variant-numeric: tabular-nums; }
.totals dd.sub { font-family: inherit; font-size: .8rem; font-weight: 400; color: var(--muted); }
.math { margin-top: 14px; }
.math ol { font-size: .9rem; font-variant-numeric: tabular-nums; margin: 8px 0 0; }
.presets { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 16px; }
.chip { min-height: 36px; padding: 6px 14px; font-size: .86rem; font-weight: 500; border-radius: 999px; }
.jobs { border: 1px solid var(--line); border-radius: var(--radius-s); border-collapse: separate; border-spacing: 0; overflow: hidden; }
.jobs th { font-size: .78rem; color: var(--muted); font-weight: 600; text-align: left; padding: 10px 8px; background: var(--surface-2); border-bottom: 1px solid var(--line); }
.jobs td { padding: 6px; border-bottom: 1px solid var(--line); }
.jobs tr:last-child td { border-bottom: 0; }
.jobs td:first-child { width: 40%; }

/* ---------- Article + sidebar ---------- */
.content-grid { display: grid; gap: 40px; padding-top: 12px; padding-bottom: 56px; }
.content-grid.no-tool { padding-top: 36px; }
@media (min-width: 980px) {
  .content-grid { grid-template-columns: minmax(0, 1fr) 280px; gap: 56px; }
  .side { position: sticky; top: 16px; align-self: start; }
}
.prose { max-width: 720px; min-width: 0; }
.prose > :first-child { margin-top: 0; }
.prose h2 { font-family: var(--display); font-weight: 800; font-size: 1.6rem; line-height: 1.2; letter-spacing: -.02em; margin: 2.2em 0 .6em; scroll-margin-top: 16px; text-wrap: balance; }
.prose h3 { font-size: 1.12rem; margin: 1.6em 0 .4em; }
.prose p, .prose li { color: color-mix(in srgb, var(--ink) 88%, var(--bg)); }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li { margin: .4em 0; }
.prose li::marker { color: var(--brand); font-weight: 600; }
.prose strong { color: var(--ink); }
.lede { font-size: 1.1rem; }
.byline { color: var(--muted); font-size: .9rem; }

.side { display: grid; gap: 16px; font-size: .92rem; }
.side-box { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.side-title { margin: 0 0 8px; font-size: .75rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); font-weight: 700; }
.toc ol { list-style: none; padding: 0; margin: 0; counter-reset: toc; }
.toc li { margin: 0; }
.toc a { display: block; padding: 6px 0 6px 12px; border-left: 2px solid var(--line); color: var(--ink); text-decoration: none; line-height: 1.35; }
.toc a:hover { border-left-color: var(--brand); color: var(--brand); }
.side-links { list-style: none; padding: 0; margin: 0; }
.side-links a { display: flex; align-items: center; gap: 10px; padding: 8px; margin: 0 -8px; border-radius: 8px; color: var(--ink); text-decoration: none; font-weight: 500; }
.side-links a:hover { background: var(--surface-2); }
.side-links .icon { color: var(--brand); }

.note { background: var(--brand-soft); border-radius: var(--radius-s); padding: 14px 18px; margin: 20px 0; }
.note p { margin: .3em 0; }
.warn { background: var(--warn-bg); color: var(--ink); border-left: 3px solid var(--warn); border-radius: 8px; padding: 12px 16px; margin: 20px 0; }
.data { font-size: .94rem; margin: 16px 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-s); border-collapse: separate; border-spacing: 0; overflow: hidden; }
.data th, .data td { border-bottom: 1px solid var(--line); padding: 9px 12px; text-align: left; vertical-align: top; }
.data thead th { background: var(--surface-2); font-size: .82rem; color: var(--muted); font-weight: 600; }
.data tbody tr:last-child td, .data tbody tr:last-child th { border-bottom: 0; }
.data tfoot th, .data tfoot td { border-bottom: 0; border-top: 1px solid var(--line); background: var(--surface-2); }
.data td.num, .data th.num { text-align: right; font-variant-numeric: tabular-nums; }
.scroll { overflow-x: auto; }
.scroll .data { margin: 0; }
.prose .scroll { margin: 16px 0; }

.prose details:not(.more-opts):not(.math) { border: 1px solid var(--line); background: var(--surface); border-radius: var(--radius-s); margin: 8px 0; padding: 0; }
.prose details:not(.more-opts):not(.math) > summary { cursor: pointer; font-weight: 600; padding: 14px 44px 14px 16px; list-style: none; position: relative; color: var(--ink); }
.prose details:not(.more-opts):not(.math) > summary::-webkit-details-marker { display: none; }
.prose details:not(.more-opts):not(.math) > summary::after { content: "+"; position: absolute; right: 16px; top: 50%; transform: translateY(-50%); font-size: 1.4rem; font-weight: 400; color: var(--brand); }
.prose details:not(.more-opts):not(.math)[open] > summary::after { content: "−"; }
.prose details:not(.more-opts):not(.math) > :not(summary) { padding: 0 16px; }
.prose details:not(.more-opts):not(.math) > :last-child { padding-bottom: 14px; margin-bottom: 0; }
.prose details:not(.more-opts):not(.math) > p:first-of-type { margin-top: 0; }
.math > summary { cursor: pointer; font-weight: 600; color: var(--brand); }

.prose .cards, .cards { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(240px, 100%), 1fr)); gap: 12px; margin: 16px 0; }
.cards li { position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-s); padding: 16px; margin: 0; transition: border-color .15s, box-shadow .15s, transform .15s; }
.cards li:hover { border-color: var(--brand); box-shadow: var(--shadow); transform: translateY(-1px); }
.cards a { font-weight: 700; color: var(--ink); text-decoration: none; }
.cards a::after { content: ""; position: absolute; inset: 0; }
.cards p { margin: 4px 0 0; color: var(--muted); font-size: .9rem; }

.cta { display: grid; grid-template-columns: auto 1fr; gap: 12px 16px; align-items: center; background: var(--hero); color: var(--hero-ink); border-radius: var(--radius); padding: 20px; margin: 36px 0; }
.cta-icon { width: 48px; height: 48px; border-radius: 12px; display: grid; place-items: center; background: rgba(255,255,255,.08); color: var(--accent); }
.cta-body p { margin: 0; color: var(--hero-muted); font-size: .94rem; }
.cta .cta-head { color: #fff; font-weight: 700; font-size: 1.05rem; margin-bottom: 4px; }
.cta .button { grid-column: 1 / -1; justify-self: start; background: var(--accent); border-color: var(--accent); color: #2a1c00; }
@media (min-width: 640px) { .cta { grid-template-columns: auto 1fr auto; } .cta .button { grid-column: auto; } }

/* ---------- Footer ---------- */
.site-footer { background: var(--hero); color: var(--hero-muted); font-size: .9rem; padding: 48px 0 32px; }
.site-footer a { color: var(--hero-ink); text-decoration: none; }
.site-footer a:hover { text-decoration: underline; color: #fff; }
.foot-grid { display: grid; gap: 28px; grid-template-columns: repeat(auto-fit, minmax(min(170px, 100%), 1fr)); }
.foot-brand { grid-column: 1 / -1; max-width: 420px; }
@media (min-width: 900px) { .foot-grid { grid-template-columns: 1.6fr 1fr 1fr 1fr; } .foot-brand { grid-column: auto; } }
.foot-brand .brand { color: var(--hero-ink); margin-bottom: 8px; }
.foot-brand p { margin: 8px 0 0; }
.foot-title { color: var(--hero-ink); font-weight: 700; margin: 4px 0 10px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin: 0; }
.site-footer li a { display: inline-block; padding: 5px 0; }
.disclaimer { border-top: 1px solid var(--hero-line); margin: 32px 0 0; padding-top: 20px; font-size: .82rem; }

/* ---------- Phones ---------- */
@media (max-width: 600px) {
  body { font-size: 16px; }
  .wrap { padding: 0 16px; }
  .hero { padding: 18px 0 32px; }
  .hero.has-tool { padding-bottom: 84px; }
  .lift { margin-top: -64px; }
  .lift { padding: 0 10px; }
  .calc { padding: 16px 14px; border-radius: 16px; }
  .chips li { font-size: .8rem; }
  .card { border: 0; border-radius: 0; overflow: visible; }
  .card, .card tbody, .card tfoot { display: block; }
  .card thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .card tbody tr { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr) 64px; grid-template-areas: "day day out" "s e b"; gap: 4px 6px; padding: 10px 0; border-bottom: 1px solid var(--line); }
  .card tbody tr:hover { background: none; }
  .card tbody th, .card tbody td { padding: 0; border: 0; }
  .card .day { width: auto; }
  .card tbody td:nth-of-type(1) { grid-area: s; }
  .card tbody td:nth-of-type(2) { grid-area: e; }
  .card tbody td:nth-of-type(3) { grid-area: b; }
  .card tbody td.out { grid-area: out; min-width: 0; align-self: end; padding: 0; }
  .card input[type="time"] { padding: 8px 6px; }
  .card input[type="time"]::-webkit-calendar-picker-indicator { display: none; }
  .card tbody td:nth-of-type(1)::before { content: "Start"; }
  .card tbody td:nth-of-type(2)::before { content: "End"; }
  .card tbody td:nth-of-type(3)::before { content: "Break min"; }
  .card tbody td:not(.out)::before { display: block; font-size: .72rem; color: var(--muted); margin-bottom: 2px; }
  .card tfoot tr { display: flex; justify-content: space-between; }
  .card tfoot th, .card tfoot td { padding: 12px 10px; border-radius: 8px; }
  .card tfoot tr { background: var(--surface-2); border-radius: 8px; margin-top: 8px; }
  .toolbar-btns { width: 100%; }
  .toolbar-btns { gap: 6px; }
  .toolbar-btns button { flex: 1 1 auto; padding: 8px 10px; font-size: .86rem; }
  .big .num { font-size: 2.6rem; }
  .prose h2 { font-size: 1.4rem; }
  .settings .field.wide { grid-column: 1 / -1; }
}

/* ---------- Print: just the time card ---------- */
@media print {
  .site-header, .site-footer, .hero, .content-grid, .sticky-sum, .actions, .toolbar, .more-opts, .saved-note, .status { display: none !important; }
  .lift { margin: 0; padding: 0; }
  .calc { border: 0; box-shadow: none; padding: 0; }
  .calc-grid { display: block; }
  .calc-side .results { background: #fff; color: #000; border: 1px solid #000; }
  .calc-side .results::before { display: none; }
  .big .label, .big .sub, .breakdown dt, .results h2, .paybox .label, .paybox .sub { color: #333; }
  .paybox .num { color: #000; }
  body { background: #fff; color: #000; }
}

/* App launch list signup */
.waitlist { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0 0; }
.waitlist .wl-field { flex: 1 1 220px; margin: 0; }
.waitlist input { min-height: 46px; }
.waitlist button { flex: 0 0 auto; min-height: 46px; }
.wl-note { flex-basis: 100%; margin: 2px 0 0; font-size: .8rem; color: var(--muted); }
.cta.wl { grid-template-columns: auto 1fr; }
.cta.wl .waitlist { grid-column: 1 / -1; margin: 0; }
.cta .waitlist input { background: rgba(255,255,255,.96); color: #0e1a18; border-color: transparent; }
.cta .waitlist button { background: var(--accent); border-color: var(--accent); color: #2a1c00; }
.cta .waitlist button:hover { background: #f6c561; }
.cta .wl-note, .cta .wl-note a, .cta-body a { color: var(--hero-muted); }
.cta-body a:hover { color: #fff; }
.note.launch .waitlist { max-width: 520px; }
@media print { .waitlist { display: none; } }
@media (max-width: 600px) { .waitlist button { flex: 1 1 100%; } }
