:root {
  --color-ink: #1c1c1e;
  --color-ink-soft: #5f5f64;
  --color-muted: #9a9a9e;
  --color-surface: #ffffff;
  --color-surface-dim: #f5f5f4;
  --color-border: #e4e4e7;
  --color-border-strong: #d4d4d8;
  --color-theme: #0ea5e9;
  --color-theme-dark: #0284c7;
  --color-theme-soft: #e0f2fe;
  --color-accent: #e4572e;
  --color-holiday: #ffaaaa;
  --color-holiday-text: #dc2626;
  --color-live: #10b981;
  --color-travel: #f59e0b;
  --color-badge-01: #DB4F60;
  --color-badge-02: #D77250;
  --color-badge-03: #E0923E;
  --color-badge-04: #F2B84B;
  --color-badge-05: #D7D750;
  --color-badge-06: #B6D750;
  --color-badge-07: #8FBB4C;
  --color-badge-08: #72D750;
  --color-badge-09: #50D750;
  --color-badge-10: #50D772;
  --color-badge-11: #4CBB8A;
  --color-badge-12: #50D7B6;
  --color-badge-13: #3EC6C6;
  --color-badge-14: #50B6D7;
  --color-badge-15: #3E9DE0;
  --color-badge-16: #6C7FE0;
  --color-badge-17: #5050D7;
  --color-badge-18: #7250D7;
  --color-badge-19: #8F5FD1;
  --color-badge-20: #B650D7;
  --color-badge-21: #D750D7;
  --color-badge-22: #D750B6;
  --color-badge-23: #D75094;
  --color-badge-24: #E0748A;
}

/* Inter (variable: wght 100-900, opsz 14-32, upright + italic) and Michroma,
   self-hosted from public/fonts/ instead of Google Fonts: no extra origins
   and no render-blocking stylesheet from fonts.googleapis.com, and the
   pages can <link rel="preload"> the files they draw first.

   Files come from the @fontsource-variable/inter (opsz-* = both axes) and
   @fontsource/michroma npm packages, split by script like Google serves
   them, so a browser downloads only the subsets a page actually uses.
   vercel.json caches /fonts/* as immutable: an updated font goes in under
   a new file name.

   Imported by src/app.css (SPA, extension side panel) and prepended to
   /site.css by scripts/site-css.js (static pages). */

@font-face {
  font-family: Inter;
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  src: url(/fonts/inter-cyrillic-ext-opsz-normal.woff2) format('woff2');
  unicode-range: U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F;
}

@font-face {
  font-family: Inter;
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  src: url(/fonts/inter-cyrillic-opsz-normal.woff2) format('woff2');
  unicode-range: U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116;
}

@font-face {
  font-family: Inter;
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  src: url(/fonts/inter-greek-ext-opsz-normal.woff2) format('woff2');
  unicode-range: U+1F00-1FFF;
}

@font-face {
  font-family: Inter;
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  src: url(/fonts/inter-greek-opsz-normal.woff2) format('woff2');
  unicode-range: U+0370-0377,U+037A-037F,U+0384-038A,U+038C,U+038E-03A1,U+03A3-03FF;
}

@font-face {
  font-family: Inter;
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  src: url(/fonts/inter-vietnamese-opsz-normal.woff2) format('woff2');
  unicode-range: U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB;
}

@font-face {
  font-family: Inter;
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  src: url(/fonts/inter-latin-ext-opsz-normal.woff2) format('woff2');
  unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
}

@font-face {
  font-family: Inter;
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  src: url(/fonts/inter-latin-opsz-normal.woff2) format('woff2');
  unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
}

@font-face {
  font-family: Inter;
  font-style: italic;
  font-display: swap;
  font-weight: 100 900;
  src: url(/fonts/inter-cyrillic-ext-opsz-italic.woff2) format('woff2');
  unicode-range: U+0460-052F,U+1C80-1C8A,U+20B4,U+2DE0-2DFF,U+A640-A69F,U+FE2E-FE2F;
}

@font-face {
  font-family: Inter;
  font-style: italic;
  font-display: swap;
  font-weight: 100 900;
  src: url(/fonts/inter-cyrillic-opsz-italic.woff2) format('woff2');
  unicode-range: U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116;
}

@font-face {
  font-family: Inter;
  font-style: italic;
  font-display: swap;
  font-weight: 100 900;
  src: url(/fonts/inter-greek-ext-opsz-italic.woff2) format('woff2');
  unicode-range: U+1F00-1FFF;
}

@font-face {
  font-family: Inter;
  font-style: italic;
  font-display: swap;
  font-weight: 100 900;
  src: url(/fonts/inter-greek-opsz-italic.woff2) format('woff2');
  unicode-range: U+0370-0377,U+037A-037F,U+0384-038A,U+038C,U+038E-03A1,U+03A3-03FF;
}

@font-face {
  font-family: Inter;
  font-style: italic;
  font-display: swap;
  font-weight: 100 900;
  src: url(/fonts/inter-vietnamese-opsz-italic.woff2) format('woff2');
  unicode-range: U+0102-0103,U+0110-0111,U+0128-0129,U+0168-0169,U+01A0-01A1,U+01AF-01B0,U+0300-0301,U+0303-0304,U+0308-0309,U+0323,U+0329,U+1EA0-1EF9,U+20AB;
}

@font-face {
  font-family: Inter;
  font-style: italic;
  font-display: swap;
  font-weight: 100 900;
  src: url(/fonts/inter-latin-ext-opsz-italic.woff2) format('woff2');
  unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
}

@font-face {
  font-family: Inter;
  font-style: italic;
  font-display: swap;
  font-weight: 100 900;
  src: url(/fonts/inter-latin-opsz-italic.woff2) format('woff2');
  unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
}

@font-face {
  font-family: 'Michroma';
  font-style: normal;
  font-display: swap;
  font-weight: 400;
  src: url(/fonts/michroma-latin-ext-400-normal.woff2) format('woff2');
  unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
}

@font-face {
  font-family: 'Michroma';
  font-style: normal;
  font-display: swap;
  font-weight: 400;
  src: url(/fonts/michroma-latin-400-normal.woff2) format('woff2');
  unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
}

/* Styles of the static pages: about, privacy policy, terms of service
   (/about.html, the legal pages: content/pages/) and the public-calendar section pages (/categories,
   /sports, ... - scripts/section-page.js). Served as /site.css.

   No color literals here: every color is a var(--color-*) token, which
   scripts/build-site-css.js defines on :root from src/lib/colors.js -
   the same palette and names the SPA gets through Tailwind. Pages link
   this file; they have no <style> blocks or style attributes of their own.

   Page-specific rules are scoped by the <body> class:
   .about - /about.html (and /ai, with .ai), .sections - section pages,
   .legal - privacy policy and terms of service. */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--color-surface-dim);
  color: var(--color-ink);
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  font-weight: 400;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--color-theme-dark);
}

.wrap {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 16px;
}

/* The logo's two colors (inline SVG). */
.fill-ink {
  fill: var(--color-ink);
}

.fill-theme {
  fill: var(--color-theme);
}

/* An inline SVG sprite: <symbol>s only, takes no room. */
.sprite {
  position: absolute;
}

svg.i {
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: color-mix(in srgb, var(--color-surface) 85%, transparent);
  backdrop-filter: saturate(1.4) blur(10px);
  -webkit-backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--color-border);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
  gap: 16px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--color-ink);
  text-decoration: none;
  font-family: Michroma, Inter, sans-serif;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
}

.brand svg {
  width: 28px;
  height: 28px;
}

.nav {
  display: flex;
  align-items: center;
  gap: 24px;
  font-size: 0.9rem;
}

.nav a {
  color: var(--color-ink-soft);
  text-decoration: none;
}

.nav a:hover,
.nav a[aria-current] {
  color: var(--color-ink);
}

.nav .btn {
  color: var(--color-surface);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 999px;
  font-weight: 500;
  font-size: 0.95rem;
  text-decoration: none;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
  white-space: nowrap;
}

.btn svg {
  width: 18px;
  height: 18px;
}

.btn-primary {
  background: var(--color-theme);
  color: var(--color-surface);
}

.btn-primary:hover {
  background: var(--color-theme-dark);
}

.btn-secondary {
  background: var(--color-surface);
  color: var(--color-ink);
  border: 1px solid var(--color-border-strong);
}

.btn-secondary:hover {
  border-color: var(--color-ink);
}

.btn-sm {
  padding: 7px 14px;
  font-size: 0.85rem;
}

/* ---------- Type ---------- */
.kicker {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-theme-dark);
  margin: 0 0 10px;
}

h1 {
  font-size: clamp(2rem, 4.4vw, 3.1rem);
  line-height: 1.12;
  letter-spacing: -0.025em;
  font-weight: 650;
  margin: 0 0 20px;
}

h2 {
  font-size: clamp(1.5rem, 3vw, 2.1rem);
  line-height: 1.2;
  letter-spacing: -0.02em;
  font-weight: 650;
  margin: 0 0 12px;
}

h3 {
  font-size: 1.05rem;
  font-weight: 600;
  margin: 0 0 6px;
  line-height: 1.35;
}

.lead {
  font-size: 1.12rem;
  color: var(--color-ink-soft);
  margin: 0 0 10px;
}

/* ---------- Cards and icons ---------- */
.card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 4px;
}

.card p {
  margin: 0;
  color: var(--color-ink-soft);
  font-size: 0.95rem;
}

.icon {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 4px;
  background: var(--color-theme-soft);
  color: var(--color-theme-dark);
}

.icon svg {
  width: 22px;
  height: 22px;
}

/* ---------- Footer ---------- */
.site-footer {
  font-size: 0.85rem;
}

.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
}

.site-footer nav {
  display: flex;
  flex-wrap: wrap;
}

.site-footer a {
  color: var(--color-ink-soft);
  text-decoration: none;
}

.site-footer a:hover {
  color: var(--color-ink);
}

/* ======================================================================
   About (/about.html, src/pages/AboutPage.svelte)
   ====================================================================== */

@media (max-width: 720px) {
  .about:not(.ai) .nav a:not(.btn) {
    display: none;
  }
}

/* Hero */
.about .hero {
  padding: 72px 0 48px;
  max-width: 760px;
  margin: 0 auto;
  text-align: center;
}

.about .eyebrow {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--color-theme-soft);
  color: var(--color-theme-dark);
  font-size: 0.8rem;
  font-weight: 500;
  margin-bottom: 20px;
}

.about h1 .hl {
  color: var(--color-theme);
}

.about .lead {
  margin: 0 auto 28px;
  max-width: 36em;
}

.about .cta-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
}

.about .perks {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  margin: 24px 0 0;
  padding: 0;
  justify-content: center;
  list-style: none;
  font-size: 0.88rem;
  color: var(--color-ink-soft);
}

.about .perks li {
  display: flex;
  align-items: center;
  gap: 6px;
}

.about .perks svg {
  width: 16px;
  height: 16px;
  color: var(--color-live);
}

@media (max-width: 860px) {
  .about .hero {
    padding: 48px 0 36px;
  }
}

/* App screenshot */
.about .shot {
  padding: 8px 0 24px;
}

.about .shot-frame {
  margin: 0;
  border-radius: 16px;
  overflow: hidden;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  box-shadow:
    0 2px 4px color-mix(in srgb, var(--color-ink) 4%, transparent),
    0 24px 48px -12px color-mix(in srgb, var(--color-ink) 14%, transparent);
}

.about .shot-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  height: 34px;
  padding: 0 14px;
  background: var(--color-surface-dim);
  border-bottom: 1px solid var(--color-border);
}

.about .shot-bar i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--color-border-strong);
}

.about .shot-bar span {
  margin: 0 auto;
  padding-right: 42px;
  font-size: 0.75rem;
  color: var(--color-muted);
}

.about .shot-frame img {
  display: block;
  width: 100%;
  height: auto;
}

.about .shot-caption {
  margin: 16px auto 0;
  max-width: 44em;
  text-align: center;
  font-size: 0.9rem;
  color: var(--color-ink-soft);
}

@media (max-width: 560px) {
  .about .shot-bar {
    height: 26px;
  }

  .about .shot-bar i {
    width: 8px;
    height: 8px;
  }

  .about .shot-bar span {
    display: none;
  }
}

/* Sections */
.about section {
  padding: 64px 0;
}

.about .section-head {
  max-width: 640px;
  margin: 0 0 36px;
}

.about .section-head.center {
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

.about .section-head p {
  color: var(--color-ink-soft);
  margin: 0;
  font-size: 1.05rem;
}

.about .card {
  padding: 24px;
}

.about .icon {
  margin-bottom: 16px;
}

.about .grid {
  display: grid;
  gap: 16px;
}

.about .grid-3 {
  grid-template-columns: repeat(3, 1fr);
}

.about .grid-4 {
  grid-template-columns: repeat(4, 1fr);
}

.about .grid-5 {
  grid-template-columns: repeat(5, 1fr);
}

.about .grid-5 .card {
  padding: 20px;
}

@media (max-width: 1000px) {
  .about .grid-5 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 900px) {
  .about .grid-4,
  .about .grid-3 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 560px) {
  .about .grid-5,
  .about .grid-4,
  .about .grid-3 {
    grid-template-columns: 1fr;
  }
}

/* Steps */
.about .step {
  position: relative;
}

.about .step-num {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--color-ink);
  color: var(--color-surface);
  font-family: Michroma, ui-monospace, monospace;
  font-size: 0.8rem;
  margin-bottom: 16px;
}

/* Spotlight blocks */
.about .spotlights {
  display: grid;
  gap: 16px;
}

.about .spotlight {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 32px;
  align-items: start;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 16px;
  padding: 32px;
}

.about .spotlight h3 {
  font-size: 1.25rem;
  margin-bottom: 10px;
}

.about .spotlight > div:first-child p {
  color: var(--color-ink-soft);
  margin: 0;
}

.about .checklist {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 14px;
}

.about .checklist li {
  display: grid;
  grid-template-columns: 24px 1fr;
  gap: 12px;
  align-items: start;
}

.about .checklist svg {
  width: 20px;
  height: 20px;
  margin-top: 3px;
  color: var(--color-theme);
}

@media (max-width: 760px) {
  .about .spotlight {
    grid-template-columns: 1fr;
    gap: 20px;
    padding: 24px;
  }
}

/* Shortcuts */
.about .shortcuts {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0 32px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 16px;
  padding: 8px 28px;
}

.about .shortcut {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px solid var(--color-border);
  font-size: 0.95rem;
}

.about .shortcut:nth-last-child(-n + 2) {
  border-bottom: 0;
}

.about .keys {
  display: flex;
  gap: 6px;
  flex-shrink: 0;
}

.about kbd {
  display: inline-grid;
  place-items: center;
  min-width: 30px;
  height: 30px;
  padding: 0 8px;
  border: 1px solid var(--color-border-strong);
  border-bottom-width: 2px;
  border-radius: 8px;
  background: var(--color-surface-dim);
  font-family: Inter, sans-serif;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--color-ink);
}

@media (max-width: 640px) {
  .about .shortcuts {
    grid-template-columns: 1fr;
    padding: 4px 20px;
  }

  .about .shortcut:nth-last-child(2) {
    border-bottom: 1px solid var(--color-border);
  }
}

/* Audience */
.about .audience .card {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.about .audience .icon {
  flex-shrink: 0;
  margin: 0;
  background: var(--color-surface-dim);
  color: var(--color-ink);
}

.about .audience-note {
  margin: 20px 0 0;
  text-align: center;
  color: var(--color-ink-soft);
}

/* Sections of the public calendars, under the audience cards */
.about .sections-strip {
  margin: 28px auto 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 10px;
}

.about .sections-strip a.section {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border: 1px solid var(--color-border);
  border-radius: 999px;
  background: var(--color-surface);
  color: var(--color-ink);
  text-decoration: none;
  font-size: 15px;
}

.about .sections-strip a.section:hover {
  border-color: var(--color-theme);
}

.about .sections-strip a.section svg {
  width: 18px;
  height: 18px;
  color: var(--color-theme-dark);
}

.about .sections-strip .count {
  color: var(--color-ink-soft);
}

.about .sections-strip a.all {
  font-weight: 600;
}

/* FAQ */
.about .faq {
  max-width: 760px;
  margin: 0 auto;
  display: grid;
  gap: 10px;
}

.about .faq details {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 14px;
  padding: 0 22px;
}

.about .faq details[open] {
  border-color: var(--color-border-strong);
}

.about .faq summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 18px 0;
  font-weight: 500;
}

.about .faq summary::-webkit-details-marker {
  display: none;
}

.about .faq summary::after {
  content: "";
  flex-shrink: 0;
  width: 10px;
  height: 10px;
  border-right: 2px solid var(--color-muted);
  border-bottom: 2px solid var(--color-muted);
  transform: rotate(45deg) translate(-2px, -2px);
  transition: transform 0.2s;
}

.about .faq details[open] summary::after {
  transform: rotate(-135deg) translate(-2px, -2px);
}

.about .faq details p {
  margin: 0 0 18px;
  color: var(--color-ink-soft);
}

/* Final CTA */
.about .final {
  text-align: center;
  background: var(--color-ink);
  color: var(--color-surface);
  border-radius: 24px;
  padding: 56px 24px;
}

.about .final h2 {
  color: var(--color-surface);
}

.about .final p {
  color: var(--color-border-strong);
  margin: 0 auto 28px;
  max-width: 32em;
}

.about .final .cta-row {
  justify-content: center;
}

.about .final .btn-secondary {
  background: transparent;
  color: var(--color-surface);
  border-color: var(--color-ink-soft);
}

.about .final .btn-secondary:hover {
  border-color: var(--color-surface);
}

/* Footer */
.about .site-footer {
  padding: 32px 0 48px;
  color: var(--color-muted);
}

.about .site-footer .wrap {
  gap: 16px;
}

.about .site-footer nav {
  gap: 20px;
}

/* ======================================================================
   ChatGPT and Claude app (/ai, src/pages/AiPage.svelte): body class
   "about ai" - the about page's rules above, plus these; header and
   footer as on the section pages (footer rules there)
   ====================================================================== */

/* Example conversation, in the screenshot frame */
.ai .chat-body {
  display: grid;
  /* minmax(0, ...): the table scrolls inside its box instead of widening the column */
  grid-template-columns: minmax(0, 1fr);
  gap: 14px;
  padding: 28px;
  text-align: left;
}

.ai .msg {
  margin: 0;
  font-size: 0.95rem;
}

.ai .msg-user {
  justify-self: end;
  max-width: 34em;
  padding: 12px 16px;
  border-radius: 16px 16px 4px 16px;
  background: var(--color-surface-dim);
  border: 1px solid var(--color-border);
}

.ai .tool-call {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  justify-self: start;
  margin: 0;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--color-theme-soft);
  color: var(--color-theme-dark);
  font-size: 0.8rem;
  font-weight: 500;
}

.ai .tool-call svg {
  width: 14px;
  height: 14px;
}

.ai .msg-reply p {
  margin: 0 0 14px;
}

.ai .schedule-scroll {
  overflow-x: auto;
}

.ai .schedule {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
  font-variant-numeric: tabular-nums;
}

.ai .schedule th,
.ai .schedule td {
  padding: 8px 12px;
  border-bottom: 1px solid var(--color-border);
  text-align: left;
  white-space: nowrap;
}

.ai .schedule thead th {
  font-weight: 600;
  border-bottom-color: var(--color-border-strong);
}

.ai .schedule tbody th {
  font-weight: 500;
  color: var(--color-ink-soft);
}

.ai .schedule td.off {
  color: var(--color-holiday-text);
}

.ai .notes {
  margin: 14px 0 0;
  padding: 12px 16px 12px 32px;
  border-radius: 4px;
  background: var(--color-surface-dim);
  font-size: 0.88rem;
  color: var(--color-ink-soft);
}

.ai .chat-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

@media (max-width: 560px) {
  .ai .chat-body {
    padding: 16px;
  }
}

/* How to add it */
.ai .grid-2 {
  grid-template-columns: repeat(2, 1fr);
}

@media (max-width: 760px) {
  .ai .grid-2 {
    grid-template-columns: 1fr;
  }
}

.ai .server-url {
  display: inline-block;
  margin-top: 6px;
  padding: 2px 8px;
  border-radius: 4px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  color: var(--color-ink);
  font-size: 0.9rem;
  user-select: all;
}

.ai .setup-card {
  scroll-margin-top: 80px;
}

.ai .setup-card h3 {
  font-size: 1.25rem;
  margin-bottom: 14px;
}

.ai .setup-steps {
  margin: 0 0 16px;
  padding-left: 20px;
  display: grid;
  gap: 8px;
  color: var(--color-ink);
}

.ai .setup-card .setup-manual {
  margin-bottom: 16px;
  font-size: 0.88rem;
}

/* Example prompts */
.ai .prompt {
  display: grid;
  grid-template-columns: 20px 1fr;
  gap: 12px;
  margin: 0;
}

.ai .prompt svg {
  width: 20px;
  height: 20px;
  margin-top: 3px;
  color: var(--color-theme);
}

.ai .prompt p {
  color: var(--color-ink);
}

/* ======================================================================
   Page not found (/404.html, src/pages/NotFoundPage.svelte): body class
   "about ai notfound" - the about and /ai rules above, plus these
   ====================================================================== */

.notfound .hero {
  padding-bottom: 32px;
}

/* Two ways to a schedule: the app and ChatGPT / Claude */
.notfound .way {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 32px;
}

.notfound .way .icon {
  margin: 0;
  color: var(--color-theme);
}

.notfound .way .icon svg {
  width: 28px;
  height: 28px;
}

.notfound .way h2 {
  font-size: 1.35rem;
  margin: 0;
}

.notfound .way .checklist {
  gap: 10px;
  font-size: 0.95rem;
}

.notfound .way .prompt {
  padding: 14px 16px;
  border-radius: 4px;
  background: var(--color-surface-dim);
  border: 1px solid var(--color-border);
}

.notfound .way .prompt p {
  font-size: 0.95rem;
}

/* The buttons sit at the bottom of both cards, left-aligned */
.notfound .way .cta-row {
  margin-top: auto;
  justify-content: flex-start;
  gap: 8px;
}

@media (max-width: 560px) {
  .notfound .way {
    padding: 24px;
  }
}

/* Public calendars by category */
.notfound .section-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.notfound .section-links a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  color: var(--color-ink);
  text-decoration: none;
  font-size: 0.93rem;
}

.notfound .section-links a:hover {
  border-color: var(--color-theme);
  color: var(--color-theme-dark);
}

.notfound .section-links svg {
  width: 18px;
  height: 18px;
  color: var(--color-theme-dark);
}

.notfound .section-links a.all {
  font-weight: 500;
  color: var(--color-theme-dark);
}

/* ======================================================================
   Section pages (scripts/section-page.js): /categories, /sports, ...
   ====================================================================== */

/* Breadcrumbs and page head */
.sections .crumbs {
  padding-top: 24px;
  font-size: 0.85rem;
}

.sections .crumbs ol {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
  color: var(--color-ink-soft);
}

.sections .crumbs li + li::before {
  content: "›";
  margin-right: 6px;
  color: var(--color-muted);
}

.sections .crumbs a {
  color: var(--color-ink-soft);
  text-decoration: none;
}

.sections .crumbs a:hover {
  color: var(--color-ink);
}

.sections .crumbs [aria-current] {
  color: var(--color-ink);
}

.sections .page-head {
  max-width: 760px;
  padding: 28px 0 32px;
}

.sections h1 {
  margin: 0 0 18px;
}

.sections h3 {
  margin: 0;
}

.sections .jump {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 40px;
  padding: 0;
  list-style: none;
}

.sections .jump a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px 6px 8px;
  border-radius: 999px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  color: var(--color-ink);
  font-size: 0.88rem;
  font-weight: 500;
  text-decoration: none;
}

.sections .jump a:hover {
  border-color: var(--color-border-strong);
}

.sections .jump .icon {
  width: 26px;
  height: 26px;
  border-radius: 13px;
  margin: 0;
}

.sections .jump .icon svg {
  width: 15px;
  height: 15px;
}

/* Groups */
.sections .group {
  margin: 0 0 64px;
  scroll-margin-top: 76px;
}

.sections .banner {
  position: relative;
  overflow: hidden;
  margin: 0 0 16px;
  border-radius: 4px;
  background: var(--color-ink);
  color: var(--color-surface);
}

.sections .banner-photo {
  display: block;
  width: 100%;
  height: 260px;
  object-fit: cover;
}

.sections .banner::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    color-mix(in srgb, var(--color-ink) 72%, transparent),
    color-mix(in srgb, var(--color-ink) 35%, transparent) 60%,
    color-mix(in srgb, var(--color-ink) 10%, transparent)
  );
}

.sections .banner-text {
  position: absolute;
  z-index: 1;
  left: 32px;
  right: 32px;
  bottom: 28px;
  max-width: 600px;
}

.sections .banner h2 {
  margin: 0 0 8px;
  color: var(--color-surface);
}

.sections .banner p {
  margin: 0;
  color: color-mix(in srgb, var(--color-surface) 88%, transparent);
  font-size: 1.02rem;
}

@media (max-width: 560px) {
  .sections .banner-photo {
    height: 240px;
  }

  .sections .banner-text {
    left: 20px;
    right: 20px;
    bottom: 20px;
  }

  .sections .banner p {
    font-size: 0.95rem;
  }
}

/* Cards */
.sections .cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin: 0;
  padding: 0;
  list-style: none;
}

@media (max-width: 900px) {
  .sections .cards {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 560px) {
  .sections .cards {
    grid-template-columns: 1fr;
  }
}

.sections .card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.sections .card-photo {
  display: block;
  aspect-ratio: 16 / 9;
  background: var(--color-surface-dim);
}

.sections .card-photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.sections .card-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 20px 24px 24px;
}

.sections .card-title {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 10px;
}

.sections .card-title a {
  color: var(--color-ink);
  text-decoration: none;
}

.sections .card-title a:hover {
  color: var(--color-theme-dark);
}

.sections .card-title h2 {
  font-size: 1.3rem;
  margin: 0;
}

.sections .card p {
  flex: 1;
  margin: 0 0 18px;
}

.sections .icon {
  flex: none;
}

.sections .card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
}

.sections .tags {
  font-size: 0.8rem;
  color: var(--color-muted);
}

.sections .tag {
  display: inline-block;
  margin-left: 4px;
  padding: 1px 9px;
  border-radius: 999px;
  background: var(--color-theme-soft);
  color: var(--color-theme-dark);
  font-weight: 500;
  text-decoration: none;
}

/* /categories and "More public calendars" */
.sections .card p.desc {
  flex: none;
}

.sections .cal-list {
  flex: 1;
  margin: -6px 0 18px;
  padding: 0;
  list-style: none;
}

.sections .cal-list a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 5px 0;
  color: var(--color-ink);
  text-decoration: none;
  font-size: 0.93rem;
}

.sections .cal-list a:hover {
  color: var(--color-theme-dark);
}

.sections .cal-list svg {
  flex: none;
  width: 18px;
  height: 18px;
  color: var(--color-theme-dark);
}

.sections .more-link {
  font-weight: 500;
  text-decoration: none;
}

.sections .sections-grid {
  margin-bottom: 64px;
}

/* Footer - also /ai's (after the .about rules it would otherwise get) */
.sections .site-footer,
.ai .site-footer {
  padding: 0;
  border-top: 1px solid var(--color-border);
  background: var(--color-surface);
  color: var(--color-ink-soft);
}

.sections .site-footer .wrap,
.ai .site-footer .wrap {
  gap: 12px 24px;
  padding-top: 24px;
  padding-bottom: 24px;
}

.sections .site-footer nav,
.ai .site-footer nav {
  gap: 8px 20px;
}

/* ======================================================================
   Privacy policy, terms of service (content/pages/*.md): a plain text page.
   ====================================================================== */

.legal {
  max-width: 680px;
  margin: 0 auto;
  padding: 2rem 1.25rem 4rem;
  background: var(--color-surface);
}

.legal h1 {
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: normal;
  margin: 0.67em 0;
}

.legal h2 {
  font-size: 1.1rem;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: normal;
  margin: 2rem 0 0.83em;
}

.legal code {
  background: var(--color-surface-dim);
  padding: 0.1em 0.35em;
  border-radius: 4px;
  font-size: 0.9em;
}

.legal .updated {
  color: var(--color-muted);
  font-size: 0.9rem;
}
