:root {
  color-scheme: light dark;
  --bg: #fbfaf7;
  --surface: #ffffff;
  --text: #1f2430;
  --muted: #566074;
  --accent: #2a4d9b;
  --border: #e1ddd3;
  --fill-bg: #fff4d6;
  --fill-border: #b07a00;
  --fill-text: #5c4000;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #14161b;
    --surface: #1c1f26;
    --text: #e9ebf0;
    --muted: #a3abbb;
    --accent: #9db8f5;
    --border: #2f3441;
    --fill-bg: #3a2f10;
    --fill-border: #e0a82e;
    --fill-text: #ffe2a0;
  }
}

* {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 1.0625rem/1.65 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

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

header.site {
  border-bottom: 1px solid var(--border);
  background: var(--surface);
}

header.site .wrap {
  padding-top: 16px;
  padding-bottom: 12px;
}

.brand {
  display: inline-block;
  font-weight: 700;
  font-size: 1.125rem;
  color: var(--text);
  text-decoration: none;
}

nav.site {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 16px;
  margin-top: 8px;
}

nav.site a {
  color: var(--muted);
  text-decoration: none;
  padding: 6px 0;
}

nav.site a[aria-current="page"] {
  color: var(--text);
  font-weight: 600;
  border-bottom: 2px solid var(--accent);
}

nav.site a:hover {
  color: var(--text);
}

main {
  padding: 32px 0 48px;
}

h1 {
  font-size: 1.875rem;
  line-height: 1.2;
  margin: 0 0 8px;
}

h2 {
  font-size: 1.3125rem;
  line-height: 1.3;
  margin: 2.25rem 0 0.5rem;
}

h3 {
  font-size: 1.0625rem;
  margin: 1.5rem 0 0.25rem;
}

p,
ul,
ol {
  margin: 0 0 1rem;
}

ul,
ol {
  padding-left: 1.25rem;
}

li {
  margin-bottom: 0.4rem;
}

a {
  color: var(--accent);
  text-underline-offset: 2px;
  overflow-wrap: anywhere;
}

a:focus-visible,
summary:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
  border-radius: 2px;
}

.updated {
  color: var(--muted);
  margin: 0 0 1.5rem;
}

.summary {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px 16px 4px;
  margin: 1.25rem 0;
}

.cards {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 12px;
}

.cards li {
  margin: 0;
}

.cards a {
  display: block;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px 16px;
  text-decoration: none;
  color: var(--text);
}

.cards a strong {
  display: block;
  color: var(--accent);
}

.cards a span {
  color: var(--muted);
}

details {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 4px 16px;
  margin: 0 0 12px;
}

summary {
  cursor: pointer;
  font-weight: 600;
  padding: 10px 0;
}

details p:last-child {
  margin-bottom: 1rem;
}

.fill {
  background: var(--fill-bg);
  color: var(--fill-text);
  outline: 1px dashed var(--fill-border);
  outline-offset: 1px;
  padding: 0 4px;
  border-radius: 3px;
}

footer.site {
  border-top: 1px solid var(--border);
  color: var(--muted);
}

/* The size sits on the text, not on the footer: the wrap's max-width is in ch, so a smaller footer font
   would make the footer column narrower than the main column and shift its text to the right. */
footer.site p {
  font-size: 0.9375rem;
}

footer.site .wrap {
  padding-top: 20px;
  padding-bottom: 32px;
}

@media (min-width: 900px) {
  body {
    font-size: 1.125rem;
  }

  h1 {
    font-size: 2.25rem;
  }

  main {
    padding-top: 48px;
  }
}

/* laughter-site additions: brand page app grid and store links. */

.lead {
  font-size: 1.1875rem;
  color: var(--muted);
  margin: 0 0 2rem;
}

.apps {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 16px;
}

.apps li {
  margin: 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px;
}

.apps h2 {
  margin: 0 0 4px;
}

.apps h2 a {
  color: var(--text);
  text-decoration: none;
}

.apps p {
  color: var(--muted);
  margin: 0 0 12px;
}

.stores {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 1rem;
  padding: 0;
  list-style: none;
}

.stores li {
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
}

.stores a {
  display: inline-block;
  border: 1px solid var(--accent);
  border-radius: 999px;
  padding: 6px 14px;
  text-decoration: none;
  font-weight: 600;
}

.soon {
  color: var(--muted);
  font-style: italic;
}

/* Ported policies use tables; they scroll sideways on narrow screens instead of widening the page. */
table {
  display: block;
  max-width: 100%;
  overflow-x: auto;
  border-collapse: collapse;
  margin: 0 0 1rem;
  font-size: 0.9375rem;
}

th,
td {
  border: 1px solid var(--border);
  padding: 8px 10px;
  text-align: left;
  vertical-align: top;
}

th {
  background: var(--surface);
}

hr {
  border: 0;
  border-top: 1px solid var(--border);
  margin: 2rem 0;
}
