/* Oilcloth website (design-system 9.6): the whole design system in one
   file, light and dark, no @import and nothing from another server. Colors
   come only from the custom properties in the generated block below. Type:
   Young Serif for the wordmark, Atkinson Hyperlegible Next for everything
   else, sentence case, no letter-spacing, no all-caps (design-system 3).
   Header and footer markup lives in public/index.html, public/404.html,
   public/t/index.html and templates/page.html: change all four. */

/* tokens:start: written by website/tools/build_assets.py from lib/design/tokens.dart (design-system 2.2 roles). Edit the tokens and run the tool, never this block. */
:root {
  color-scheme: light dark;
  --room: #DAE0F4; /* chalk */
  --raised: #E8EEFF; /* chalkLight */
  --text: #24211F; /* soot */
  --text-secondary: #5B5F66; /* pewter */
  --mark: #3C66B0; /* cobaltDeep */
  --focus: #3C66B0; /* cobaltDeep */
  --edge: #24211F; /* soot */
  --mat: #5A2531; /* oxblood */
  --keyline: #8E4A58; /* keyline */
  --on-mat: #DAE0F4; /* chalk */
  --face: #F4F0E8; /* bone */
  --band: #5C86CC; /* cobaltEnamel */
  --ink: #233F7A; /* inkBlue */
  --tile-edge: #24211F; /* soot */
}
@media (prefers-color-scheme: dark) {
  :root {
    --room: #1E0F12; /* late */
    --raised: #2C1B1E; /* lateLight */
    --text: #ECE6DC; /* lamp */
    --text-secondary: #A9A3AE; /* ash */
    --mark: #3C66B0; /* cobaltDeep */
    --focus: #4A74BC; /* cobaltDusk */
    --edge: #A9A3AE; /* ash */
    --mat: #3E1822; /* nightOxblood */
    --keyline: #6B3140; /* nightKeyline */
    --on-mat: #ECE6DC; /* lamp */
    --face: #E2DCD1; /* dimBone */
    --band: #4A74BC; /* cobaltDusk */
    --ink: #213A72; /* nightInk */
    --tile-edge: #221F1D; /* nightSoot */
  }
}
/* tokens:end */

@font-face {
  font-family: "Atkinson Hyperlegible Next";
  src: url("/fonts/atkinson-hyperlegible-next.woff2") format("woff2");
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Young Serif";
  src: url("/fonts/young-serif-regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

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

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

body {
  margin: 0;
  background: var(--room);
  color: var(--text);
  font-family: "Atkinson Hyperlegible Next", system-ui, sans-serif;
  font-size: 1.125rem;
  font-weight: 400;
  line-height: 1.55;
  letter-spacing: 0;
  overflow-wrap: break-word;
}

/* Side margins: 16 px on phones, 24 px from 600 px (design-system 4.1). */
.wrap {
  max-width: 72rem;
  margin: 0 auto;
  padding: 0 1rem;
}

@media (min-width: 600px) {
  .wrap {
    padding: 0 1.5rem;
  }
}

a {
  color: var(--text);
  text-decoration-line: underline;
  text-decoration-color: var(--mark);
  text-decoration-thickness: 0.09em;
  text-underline-offset: 0.18em;
}

a:hover,
a[aria-current="page"] {
  text-decoration-thickness: 0.18em;
}

:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  top: 0.5rem;
  left: 1rem;
  z-index: 10;
  padding: 0.75rem 1rem;
  background: var(--raised);
  border: 1.5px solid var(--edge);
  border-radius: 8px;
  font-weight: 600;
  transform: translateY(-200%);
}

.skip-link:focus {
  transform: none;
}

/* Header: the wordmark top-left, the one action top-right
   (design-system 4.1, "Layout is asymmetric"). */
.site-header {
  padding: 1.25rem 0 0.5rem;
}

.site-header-row {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem 1.5rem;
}

.wordmark {
  margin: 0;
  font-family: "Young Serif", Georgia, serif;
  font-size: 1.75rem;
  font-weight: 400;
  line-height: 1.15;
}

.wordmark a {
  display: inline-block;
  padding: 0.5rem 0;
  text-decoration: none;
}

.site-nav ul,
.footer-nav ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0 1.5rem;
}

.site-nav a,
.footer-nav a {
  display: inline-block;
  padding: 0.6rem 0;
  font-weight: 600;
}

/* Policy and help pages: Atkinson 400 at 18 px, lines of 70 characters at
   most (design-system 9.6). */
.doc {
  max-width: 70ch;
  padding: 1rem 0 2.5rem;
}

.doc h1 {
  margin: 0.5rem 0 0.5rem;
  font-size: 2rem;
  font-weight: 700;
  line-height: 1.2;
}

.doc h2 {
  margin: 2.5rem 0 0.75rem;
  font-size: 1.375rem;
  font-weight: 700;
  line-height: 1.3;
}

.doc h3 {
  margin: 1.75rem 0 0.5rem;
  font-size: 1.125rem;
  font-weight: 700;
  line-height: 1.35;
}

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

.doc li {
  margin: 0 0 0.4rem;
}

.doc li > p {
  margin: 0;
}

.effective {
  color: var(--text-secondary);
}

/* The quiet section link after each h2 and h3, shown on hover or focus. */
.anchor {
  margin-left: 0.4em;
  color: var(--text-secondary);
  font-weight: 400;
  text-decoration: none;
  opacity: 0;
}

h2:hover .anchor,
h3:hover .anchor,
.anchor:focus-visible {
  opacity: 1;
}

.toc {
  margin: 1.5rem 0 2rem;
  padding: 1rem 1.25rem;
  background: var(--raised);
  border: 1.5px solid var(--edge);
  border-radius: 16px;
}

.toc h2 {
  margin: 0 0 0.5rem;
  font-size: 1.125rem;
}

.toc ol,
.toc ul {
  margin: 0;
  padding-left: 1.5rem;
}

.toc li {
  margin: 0.15rem 0;
}

/* Tables scroll inside their own box, never the page. */
.table-wrap {
  margin: 1.25rem 0 1.5rem;
  overflow-x: auto;
  border: 1.5px solid var(--edge);
  border-radius: 8px;
}

table {
  width: 100%;
  min-width: 30rem;
  border-collapse: collapse;
  font-size: 1rem;
  line-height: 1.45;
}

th,
td {
  padding: 0.6rem 0.75rem;
  text-align: left;
  vertical-align: top;
}

th {
  background: var(--raised);
  font-weight: 700;
}

tr + tr td,
tbody tr:first-child td {
  border-top: 1px solid var(--edge);
}

/* Landing page (master prompt Phase 9 step 2; design-system 9.6): the
   wordmark top-left, the words under it, and one real capture of the dark
   board set large and low, to the right on wide screens and under the
   words on phones. No centered stack, no buttons, no gradient or glow;
   the room color fills the rest. */
.home .wordmark {
  font-size: clamp(3rem, 14vw, 5.5rem);
  line-height: 1.05;
}

.hero {
  display: grid;
  gap: 2rem;
  padding-top: 0.5rem;
  padding-bottom: 2.5rem;
}

.tagline {
  margin: 0 0 0.75rem;
  font-size: 1.625rem;
  font-weight: 700;
  line-height: 1.25;
}

.lede {
  max-width: 34ch;
  margin: 0 0 0.75rem;
  font-size: 1.25rem;
}

.platforms {
  margin: 0 0 1.5rem;
  color: var(--text-secondary);
}

.availability-box {
  display: grid;
  grid-template-columns: 4rem minmax(0, 1fr);
  gap: 1rem;
  align-items: start;
  max-width: 30rem;
  padding: 1rem 1.25rem;
  background: var(--raised);
  border: 1.5px solid var(--edge);
  border-radius: 16px;
}

.availability-box p {
  margin: 0;
}

.app-icon {
  display: block;
  width: 4rem;
  height: 4rem;
  border-radius: 14px;
}

.store-title {
  font-weight: 700;
}

.availability {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.3;
}

.price-line {
  color: var(--text-secondary);
}

.see-how {
  margin: 1.25rem 0 0;
  font-weight: 600;
}

figure {
  margin: 0;
}

.shot {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 20px;
}

.hero-shot {
  width: min(100%, 24rem);
}

@media (min-width: 840px) {
  .hero {
    grid-template-columns: minmax(0, 1fr) minmax(0, 24rem);
    gap: 3rem;
    align-items: start;
  }

  .hero-shot {
    margin-top: 5rem;
  }
}

/* Four facts in a row on wide screens, two by two on phones. */
.glance {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 8.5rem), 1fr));
  gap: 1rem 1.5rem;
  margin: 0 0 1rem;
  padding: 1.5rem 0;
  border-top: 1.5px solid var(--edge);
  border-bottom: 1.5px solid var(--edge);
  list-style: none;
}

.glance li {
  margin: 0;
}

.glance strong {
  display: block;
  font-size: 1.25rem;
}

/* One section per screenshot message: the words, then the capture, set
   lower than the words on wide screens. */
.feature {
  padding: 2.5rem 0;
}

.feature-row {
  display: grid;
  gap: 1.5rem;
}

.feature h2,
.faq h2,
.maker h2,
.fine-print h2 {
  margin: 0 0 0.75rem;
  font-size: 1.75rem;
  font-weight: 700;
  line-height: 1.2;
}

.feature-words {
  max-width: 36rem;
}

.feature-words p {
  margin: 0 0 1rem;
}

.feature-shot {
  width: min(100%, 16rem);
}

@media (min-width: 600px) {
  .feature-shot {
    width: 18rem;
  }
}

@media (min-width: 840px) {
  .feature-row {
    grid-template-columns: minmax(0, 1fr) 18rem;
    gap: 3rem;
    align-items: start;
  }

  .feature-row > figure {
    margin-top: 3rem;
  }

  .feature-row-wide {
    grid-template-columns: minmax(0, 1fr) 25rem;
  }
}

/* The rules drawing: an inline SVG on a mat chip, colored only by the
   roles above (design-system 9.1: faces inside tiles, cobalt as bands). */
.rules {
  width: min(100%, 25rem);
}

.rules-art {
  display: block;
  width: 100%;
  height: auto;
}

.rules-art .mat-chip {
  fill: var(--mat);
}

.rules-art .keyline-line {
  fill: none;
  stroke: var(--keyline);
  stroke-width: 1.5;
}

.rules-art .back {
  fill: var(--band);
}

.rules-art .face {
  fill: var(--face);
  stroke: var(--tile-edge);
  stroke-width: 1.5;
}

.rules-art .glyph {
  fill: none;
  stroke: var(--ink);
  stroke-width: 3;
}

.rules-art .free-ring {
  fill: none;
  stroke: var(--on-mat);
  stroke-width: 2.5;
  stroke-dasharray: 6 4;
}

.rules-art .veil {
  fill: var(--mat);
  opacity: 0.55;
}

.rules-key {
  margin: 1rem 0 0;
  padding: 0;
  list-style: none;
}

.rules-key li {
  display: grid;
  grid-template-columns: 1.5rem minmax(0, 1fr);
  gap: 0.75rem;
  margin: 0 0 0.6rem;
}

.key {
  display: block;
  width: 1.25rem;
  height: 1.6rem;
  margin-top: 0.1rem;
  border-radius: 4px;
}

.key-free {
  border: 2px dashed var(--text);
}

/* A blocked tile as the drawing shows it: the face under the mat-colored
   veil (.rules-art .veil), not the bare mat. */
.key-blocked {
  position: relative;
  overflow: hidden;
  background: var(--face);
  border: 1.5px solid var(--edge);
}

.key-blocked::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--mat);
  opacity: 0.55;
}

.fine-print {
  padding: 2rem 0;
}

.fine-print-box,
.closing-box {
  max-width: 44rem;
  padding: 1.5rem 1.25rem;
  background: var(--raised);
  border: 1.5px solid var(--edge);
  border-radius: 16px;
}

.fine-print-box p {
  margin: 0 0 1rem;
}

.fine-print-box p:last-child {
  margin-bottom: 0;
}

/* Questions: native disclosure widgets, 48 px rows at least. */
.faq {
  padding: 2.5rem 0;
}

.faq-list {
  max-width: 44rem;
  border-top: 1.5px solid var(--edge);
}

.faq details {
  border-bottom: 1.5px solid var(--edge);
}

.faq summary {
  min-height: 3rem;
  padding: 0.75rem 0;
  font-weight: 700;
  cursor: pointer;
}

.faq details p {
  margin: 0 0 1rem;
}

.maker {
  padding: 1.5rem 0 2rem;
}

.closing {
  padding: 1rem 0 3rem;
}

.closing-box h2 {
  margin: 0 0 0.5rem;
  font-size: 1.5rem;
  line-height: 1.25;
}

.closing-box p {
  margin: 0 0 0.25rem;
}

/* The table-link page (D10; design-system 9.6): the words, then the mat
   with the icon's two tiles, under them on phones and beside them on wide
   screens. */
.link-page {
  display: grid;
  gap: 2rem;
  padding-top: 1rem;
  padding-bottom: 3rem;
}

.link-page h1 {
  margin: 0.5rem 0 1rem;
  font-size: 2rem;
  font-weight: 700;
  line-height: 1.2;
}

.link-page p {
  max-width: 36rem;
  margin: 0 0 1rem;
}

.mat {
  position: relative;
  display: grid;
  place-items: center;
  padding: 2.5rem 1.5rem;
  background: var(--mat);
  border-radius: 20px;
}

/* The mat's keyline, inset like the in-app mat's. */
.mat::before {
  content: "";
  position: absolute;
  inset: 8px;
  border: 1.5px solid var(--keyline);
  border-radius: 14px;
  pointer-events: none;
}

.mat img {
  display: block;
  width: min(100%, 16rem);
  height: auto;
}

@media (min-width: 840px) {
  .link-page {
    grid-template-columns: minmax(0, 1fr) minmax(0, 0.9fr);
    align-items: start;
  }

  .mat {
    margin-top: 3rem;
    padding: 3rem 2rem;
  }
}

.site-footer {
  margin-top: 1rem;
  padding: 1.5rem 0 3rem;
  border-top: 1.5px solid var(--edge);
  color: var(--text-secondary);
  font-size: 1rem;
}

.footer-nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0 1.5rem;
  margin-bottom: 0.75rem;
}

.site-footer p {
  margin: 0 0 0.5rem;
}
