/* Eat The Frog — a field-guide plate, drawn in line.
   Pale pond water, deep pond ink, outlined glyphs with no fill.
   Colour only where it means something: yellow and red mark drop-dead dates. */

@font-face { font-family: Spectral; font-weight: 200; font-style: normal; font-display: swap; src: url(/fonts/spectral-200.woff2) format("woff2"); }
@font-face { font-family: Spectral; font-weight: 300; font-style: normal; font-display: swap; src: url(/fonts/spectral-300.woff2) format("woff2"); }
@font-face { font-family: Spectral; font-weight: 400; font-style: normal; font-display: swap; src: url(/fonts/spectral-400.woff2) format("woff2"); }
@font-face { font-family: Spectral; font-weight: 600; font-style: normal; font-display: swap; src: url(/fonts/spectral-600.woff2) format("woff2"); }
@font-face { font-family: Spectral; font-weight: 300; font-style: italic; font-display: swap; src: url(/fonts/spectral-300-italic.woff2) format("woff2"); }
@font-face { font-family: Spectral; font-weight: 400; font-style: italic; font-display: swap; src: url(/fonts/spectral-400-italic.woff2) format("woff2"); }

:root {
  --water: #E4E9E2;   /* page */
  --ink: #1B2A24;     /* text and every line */
  --reed: #56665D;    /* quieter text */
  --silt: #C3CDC2;    /* rules, phone edges */
  --leaf: #3D6831;    /* links and the button */
  --dart-yellow: #B9860C; /* due this week */
  --dart-red: #BC3E27;    /* due in two days or less */
  --line: 1.4px;
  --measure: 62ch;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--water);
  color: var(--ink);
  font: 400 1.1875rem/1.62 Spectral, Georgia, serif;
  font-feature-settings: "kern", "liga", "onum";
}
a { color: var(--leaf); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--ink); }
:focus-visible { outline: 2px solid var(--leaf); outline-offset: 3px; border-radius: 3px; }

.glyph { width: 44px; height: 44px; fill: none; stroke: currentColor; stroke-width: var(--line); stroke-linecap: round; stroke-linejoin: round; overflow: visible; }

/* Header and footer */
header, footer, main { max-width: 1120px; margin: 0 auto; padding: 0 28px; }
header { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding-top: 22px; padding-bottom: 22px; }
.brand { white-space: nowrap; display: flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font-weight: 600; font-size: 1.125rem; letter-spacing: -0.005em; }
.brand .glyph { width: 34px; height: 34px; }
nav { display: flex; gap: 22px; font-size: 1rem; }
nav a { color: var(--reed); text-decoration: none; }
nav a:hover, nav a[aria-current="page"] { color: var(--ink); text-decoration: underline; }
footer { display: flex; flex-wrap: wrap; gap: 8px 26px; padding-top: 28px; padding-bottom: 48px; margin-top: 88px;
  background: linear-gradient(var(--silt), var(--silt)) top center / calc(100% - 56px) 1px no-repeat; font-size: 0.9375rem; color: var(--reed); }

/* Type */
h1 {
  font-weight: 200;
  font-size: clamp(3rem, 7.2vw, 5.75rem);
  line-height: 0.98;
  letter-spacing: -0.028em;
  margin: 0;
  max-width: 11ch;
}
h2 { font-weight: 300; font-size: clamp(2rem, 3.6vw, 2.75rem); line-height: 1.08; letter-spacing: -0.018em; margin: 96px 0 18px; max-width: 20ch; }
h3 { font-weight: 600; font-size: 1.1875rem; line-height: 1.3; margin: 0 0 4px; }
p { margin: 0 0 1em; max-width: var(--measure); }
.lede { font-size: 1.3125rem; line-height: 1.55; color: var(--ink); }
.quiet { color: var(--reed); }
.species { font-style: italic; font-weight: 300; }

/* Hero */
.hero { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.08fr); gap: 48px; align-items: center; padding-top: 36px; }
.hero .lede { margin-top: 28px; }

/* The reveal-secrets call to action */
.secret-cta { margin-top: 30px; }
.cta {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 26px; border-radius: 999px;
  background: var(--leaf); color: var(--water);
  font: 600 1.0625rem/1 Spectral, Georgia, serif; text-decoration: none;
  border: var(--line) solid var(--leaf);
}
.cta:hover { background: var(--ink); border-color: var(--ink); color: var(--water); }
.locked .cta { background: transparent; color: var(--reed); border-color: var(--silt); cursor: not-allowed; }
.cta-note { font-size: 0.9375rem; color: var(--reed); margin: 12px 0 0; }
.cta-note code { font: inherit; color: var(--ink); word-break: break-all; }
.reveal, .reveal-form button {
  font: inherit; color: var(--leaf); background: none; border: 0; padding: 0; margin-left: 6px;
  text-decoration: underline; text-underline-offset: 3px; cursor: pointer;
}
.reveal-form[hidden] { display: none; }
.reveal-form { display: flex; flex-wrap: wrap; align-items: end; gap: 10px 14px; margin-top: 14px; font-size: 0.9375rem; }
.reveal-form label { display: grid; gap: 4px; color: var(--reed); }
.reveal-form input {
  font: inherit; color: var(--ink); background: transparent; width: 11em;
  border: 0; border-bottom: var(--line) solid var(--ink); padding: 4px 0; border-radius: 0;
}
.reveal-form button { margin: 0 0 6px; }
.reveal-status { flex-basis: 100%; color: var(--dart-red); min-height: 1em; }

/* Plates: line drawings with a caption, like a field guide */
.plate { margin: 0; }
.plate svg { display: block; width: 100%; height: auto; }
.plate figcaption { font-size: 0.9375rem; line-height: 1.5; color: var(--reed); margin-top: 12px; max-width: 54ch; }
.plate figcaption b { font-weight: 600; color: var(--ink); margin-right: 6px; }
.pond-plate text { font: italic 300 13.5px Spectral, Georgia, serif; fill: var(--ink); }
.pond-plate text.sub { font-style: normal; font-weight: 400; font-size: 11.5px; fill: var(--reed); }
.pond-plate .leader { stroke: var(--reed); stroke-width: 0.8; fill: none; }
.pond-plate .pad { fill: none; stroke: var(--ink); stroke-width: var(--line); }
.pond-plate .pad.y { stroke: var(--dart-yellow); }
.pond-plate .pad.r { stroke: var(--dart-red); }
.pond-plate .ripple { fill: none; stroke: var(--ink); stroke-width: 0.8; opacity: 0; transform-box: fill-box; transform-origin: center; }

@media (prefers-reduced-motion: no-preference) {
  .pond-plate .ripple { animation: ripple 2.8s cubic-bezier(.2,.6,.3,1) .6s 1 both; }
  .pond-plate .ripple.two { animation-delay: 1.1s; }
}
@keyframes ripple { 0% { opacity: .9; transform: scale(1); } 100% { opacity: 0; transform: scale(1.9); } }

/* The saying */
.saying { margin: 88px 0 0; padding: 0; max-width: 40ch; }
.saying p { font-weight: 300; font-style: italic; font-size: clamp(1.5rem, 2.6vw, 2rem); line-height: 1.3; letter-spacing: -0.01em; margin: 0; max-width: none; }
.saying footer, .saying cite { display: block; margin: 14px 0 0; padding: 0; border: 0; font-style: normal; font-size: 0.9375rem; color: var(--reed); max-width: 60ch; }

/* Field-guide entries */
.entries { list-style: none; margin: 34px 0 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 56px; }
.entries li { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 20px; padding: 26px 0; border-top: 1px solid var(--silt); }
.entries .glyph { margin-top: 2px; }
.entries p { margin: 0; font-size: 1.0625rem; color: var(--reed); }

/* Outlined phones */
.phones { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; margin-top: 36px; }
.phones figure { margin: 0; }
.phone {
  aspect-ratio: 9 / 16.5; border: var(--line) solid var(--ink); border-radius: 38px;
  padding: 44px 20px 22px; position: relative; display: flex; flex-direction: column; gap: 10px;
  font-size: 0.8125rem; line-height: 1.35;
}
.phone::before { content: ""; position: absolute; top: 13px; left: 50%; width: 30%; height: 15px; transform: translateX(-50%); border: 1px solid var(--ink); border-radius: 10px; }
.phone .big { font-weight: 200; font-size: 2.6rem; line-height: 1; letter-spacing: -0.03em; }
.phone .title { font-weight: 300; font-size: 1.35rem; line-height: 1.1; letter-spacing: -0.01em; }
.phone .k { color: var(--reed); font-size: 0.6875rem; }
.phone .rows { border-top: 1px solid var(--silt); }
.phone .row { display: flex; justify-content: space-between; gap: 8px; padding: 6px 0; border-bottom: 1px solid var(--silt); }
.phone .row .r { color: var(--dart-red); }
.phone .row .y { color: var(--dart-yellow); }
.phone .btn { margin-top: auto; border: var(--line) solid var(--ink); border-radius: 999px; text-align: center; padding: 9px; font-weight: 600; }
.phone .pads { display: flex; gap: 4px; }
.phone .pads svg { width: 13px; height: 13px; }
.phone .glyph { width: 64px; height: 64px; }
.phone svg.mini-pond { width: 100%; height: auto; }
.phones figcaption { font-size: 0.9375rem; color: var(--reed); margin-top: 14px; }
.phones figcaption b { color: var(--ink); font-weight: 600; margin-right: 6px; }

/* References */
.refs { margin: 26px 0 0; padding-left: 1.4em; max-width: var(--measure); font-size: 1rem; color: var(--reed); }
.refs li { margin-bottom: 10px; padding-left: 4px; }
.refs li::marker { color: var(--ink); }
sup a { text-decoration: none; font-size: 0.8em; padding: 0 1px; }

/* Plain pages: privacy, support, 404 */
.page { max-width: 760px; }
.page h1 { font-size: clamp(2.75rem, 6vw, 4.25rem); max-width: 14ch; margin-top: 40px; }
.page h2 { font-size: 1.75rem; margin-top: 56px; }
.page .updated { color: var(--reed); font-size: 0.9375rem; margin-top: 18px; }
dl.faq { margin: 0; }
dl.faq dt { font-weight: 600; margin-top: 26px; }
dl.faq dd { margin: 4px 0 0; color: var(--reed); max-width: var(--measure); }

@media (max-width: 900px) {
  .hero { grid-template-columns: minmax(0, 1fr); gap: 36px; padding-top: 12px; }
  .entries { grid-template-columns: minmax(0, 1fr); }
  .phones { grid-template-columns: repeat(3, 72%); overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 10px; gap: 20px; }
  .phones figure { scroll-snap-align: start; }
  h2 { margin-top: 72px; }
}
@media (max-width: 520px) {
  header, footer, main { padding-left: 20px; padding-right: 20px; }
  nav { gap: 16px; }
  body { font-size: 1.125rem; }
  footer { background-size: calc(100% - 40px) 1px; }
  .pond-plate text { font-size: 21px; }
  .pond-plate text.sub { display: none; }
  .lede { font-size: 1.1875rem; }
}
