:root {
  --bg: #F6F6F3;
  --surface: #FFFFFF;
  --ink: #17171B;
  --text: #3A3A42;
  --muted: #5C5C64;
  --line: #E4E4DF;
  --field: #CFCFC9;
  --accent: #2F3FB5;
  --accent-ink: #1E2A85;
  --tint: #E9E8FB;
  /* one typeface everywhere: Poppins; hierarchy comes from size and weight */
  --display: 'Poppins', system-ui, sans-serif;
  --sans: 'Poppins', system-ui, sans-serif;
  --typed: 'Poppins', system-ui, sans-serif;
  --type: 'Poppins', system-ui, sans-serif;
  --hand: 'Poppins', system-ui, sans-serif;
}

* { box-sizing: border-box; }

[hidden] { display: none !important; }

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

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  line-height: 1.5;
}

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-ink); text-decoration: underline; }

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

.wrap { width: 100%; max-width: 628px; margin: 0 auto; padding-inline: 24px; } /* 580px column for everything */

.sr-only {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

/* header / footer */
.site-header {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; flex-wrap: wrap; padding-block: 28px;
}
.logo { display: flex; align-items: center; gap: 10px; color: var(--ink); }
.logo:hover { color: var(--ink); text-decoration: none; }
.logo span { font-family: var(--display); font-weight: 700; font-size: 20px; letter-spacing: -0.02em; }
.site-header nav { display: flex; gap: 20px; }

.site-footer {
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  padding-block: 24px 40px; font-size: 14px; color: var(--muted);
}
.site-footer a { color: var(--muted); }

main.wrap { flex: 1; padding-block: 48px 64px; display: flex; flex-direction: column; gap: 56px; }

/* today's check */
.check { display: flex; flex-direction: column; gap: 28px; }

.eyebrow {
  margin: 0; display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  font-size: 14px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--accent);
}
.eyebrow .muted { color: var(--muted); }
.replay {
  margin-inline-start: auto; width: 36px; height: 36px; display: inline-grid; place-items: center; flex: none;
  border: 1px solid var(--line); border-radius: 50%; background: var(--surface); color: var(--accent); cursor: pointer;
}
.replay:hover { color: var(--accent-ink); border-color: var(--accent); }
.replay:active svg { transform: rotate(-90deg); }
.replay svg { transition: transform 0.25s ease; }
/* "Today's check": a handwritten note, like "Remember this…" */
.eyebrow > span:first-child { font-family: var(--hand); font-size: 26px; font-weight: 500; letter-spacing: 0; text-transform: none; line-height: 1; }
.dot { width: 4px; height: 4px; border-radius: 50%; background: #9A9AA2; }

h1 {
  margin: 0; font-family: var(--typed); font-weight: 500;
  font-size: clamp(38px, 7.5vw, 58px); line-height: 1.12; letter-spacing: -0.01em;
}

.body { display: flex; flex-direction: column; gap: 16px; max-width: 580px; font-family: var(--type); font-size: 21px; line-height: 1.55; color: var(--text); }
.body p { margin: 0; }

.quote {
  margin: 0; padding: 28px; border-radius: 20px; background: var(--tint);
  display: flex; flex-direction: column; gap: 14px;
}
.quote svg { fill: var(--accent); }
.quote blockquote {
  margin: 0; font-family: var(--typed); font-weight: 400;
  font-size: clamp(24px, 4.5vw, 28px); line-height: 1.3; letter-spacing: 0; color: var(--ink);
}
.quote figcaption { font-family: var(--type); font-size: 15px; font-weight: 500; color: var(--text); }

.move {
  background: var(--surface); border: 1px solid var(--line); border-radius: 16px;
  padding: 24px; display: flex; flex-direction: column; gap: 8px;
}
.move-label { font-family: var(--hand); font-size: 24px; font-weight: 500; line-height: 1.1; color: var(--accent); }
.move p { margin: 0; font-family: var(--type); font-size: 22px; line-height: 1.45; font-weight: 600; color: var(--ink); }

.actions { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; position: relative; }

/* buttons */
.btn {
  min-height: 48px; padding: 0 24px; border-radius: 999px; border: none;
  background: var(--ink); color: #fff; font: 600 16px/1 var(--sans);
  display: inline-flex; align-items: center; gap: 10px; cursor: pointer;
  transition: background-color .2s ease;
}
.btn:hover { background: #2C2C33; }
.btn[disabled] { opacity: .6; cursor: default; }

[data-check] .icon-done { display: none; }
[data-check][aria-pressed="true"] { background: var(--accent); }
[data-check][aria-pressed="true"]:hover { background: var(--accent-ink); }
[data-check][aria-pressed="true"] .icon-open { display: none; }
[data-check][aria-pressed="true"] .icon-done { display: block; }

.draw-check { stroke-dasharray: 12; stroke-dashoffset: 0; }
[data-check].just-checked .draw-check { animation: draw .45s ease-out .05s both; }
@keyframes draw { from { stroke-dashoffset: 12; } to { stroke-dashoffset: 0; } }

.share, .link-btn {
  background: none; border: none; padding: 8px 0; min-height: 44px; cursor: pointer;
  font: 500 15px/1 var(--sans); color: var(--accent);
  display: inline-flex; align-items: center; gap: 8px;
}
.share:hover, .link-btn:hover { color: var(--accent-ink); text-decoration: underline; }
.site-header .link-btn { color: var(--ink); }

/* newsletter */
.newsletter { border-top: 1px solid var(--line); padding-top: 40px; }
.newsletter > div { display: flex; flex-direction: column; gap: 16px; }
.newsletter h2, .signin h2 {
  margin: 0; font-family: var(--typed); font-weight: 400; font-size: 28px; letter-spacing: 0;
}
.newsletter p { margin: 0; font-size: 17px; line-height: 1.55; color: #45454D; max-width: 520px; }
.newsletter form { display: flex; gap: 12px; flex-wrap: wrap; max-width: 520px; }

input[type="email"] {
  flex: 1 1 240px; min-height: 48px; padding: 0 18px; border-radius: 999px;
  border: 1px solid var(--field); background: var(--surface);
  font: 16px var(--sans); color: var(--ink); width: 100%;
}
input[type="email"]::placeholder { color: #7A7A80; }
input[type="email"]:focus { outline: 2px solid var(--accent); outline-offset: 2px; }

.fine { font-size: 14px !important; color: var(--muted) !important; }
.fine.error { color: #A3261B !important; }

/* sign-in dialog */
.signin {
  border: none; border-radius: 20px; padding: 0; width: min(440px, calc(100vw - 32px));
  background: var(--surface); color: var(--ink); box-shadow: 0 24px 64px rgba(23, 23, 27, .18);
}
.signin::backdrop { background: rgba(23, 23, 27, .35); }
.signin form { padding: 28px; display: flex; flex-direction: column; gap: 12px; }
.signin p { margin: 0; color: var(--text); }
.signin label { font-size: 14px; font-weight: 600; }
.signin .consent { display: flex; align-items: center; gap: 10px; font-weight: 400; font-size: 15px; color: var(--text); min-height: 44px; }
.signin .consent input { width: 18px; height: 18px; accent-color: var(--accent); }
.dialog-actions { display: flex; justify-content: flex-end; align-items: center; gap: 16px; margin-top: 8px; flex-wrap: wrap; }

.notfound { padding-block: 96px; }

/* language menu */
.site-header nav { align-items: center; }
.lang-menu { position: relative; }
.lang-menu summary {
  list-style: none; cursor: pointer; min-height: 44px; padding: 0 4px;
  display: inline-flex; align-items: center; gap: 8px;
  font: 500 15px/1 var(--sans); color: var(--ink);
}
.lang-menu summary::-webkit-details-marker { display: none; }
.lang-menu summary:hover span { text-decoration: underline; }
.lang-menu ul {
  position: absolute; inset-inline-end: 0; top: calc(100% + 6px); z-index: 20;
  margin: 0; padding: 6px; list-style: none; min-width: 168px;
  background: var(--surface); border: 1px solid var(--line); border-radius: 14px;
  box-shadow: 0 16px 40px rgba(23, 23, 27, .12);
}
.lang-menu a {
  display: flex; align-items: center; min-height: 44px; padding: 0 12px; border-radius: 10px;
  color: var(--ink); font-size: 16px;
}
.lang-menu a:hover { background: var(--bg); text-decoration: none; }
.lang-menu a[aria-current="page"] { color: var(--accent); font-weight: 600; }

.tr-note { color: var(--muted); font-weight: 400; }
.newsletter .note { font-size: 15px; color: var(--muted); }

/* scripts the brand fonts don't cover: fall back per glyph to a matching face */
:root:lang(hi) {
  --display: 'Poppins', system-ui, sans-serif;
  --sans: 'Poppins', system-ui, sans-serif;
  --typed: 'Poppins', system-ui, sans-serif;
  --type: 'Poppins', system-ui, sans-serif;
  --hand: 'Poppins', system-ui, sans-serif;
}
:root:lang(ar) {
  --display: 'IBM Plex Sans Arabic', 'Poppins', system-ui, sans-serif;
  --sans: 'IBM Plex Sans Arabic', 'Poppins', system-ui, sans-serif;
  --typed: 'IBM Plex Sans Arabic', 'Poppins', system-ui, sans-serif;
  --type: 'IBM Plex Sans Arabic', 'Poppins', system-ui, sans-serif;
  --hand: 'IBM Plex Sans Arabic', 'Poppins', system-ui, sans-serif;
}
/* Letter-spacing breaks Arabic joining and crowds Devanagari; these scripts also need taller lines. */
:lang(hi) h1, :lang(ar) h1, :lang(hi) h2, :lang(ar) h2,
:lang(hi) .eyebrow, :lang(ar) .eyebrow, :lang(hi) .move-label, :lang(ar) .move-label,
:lang(hi) .quote blockquote, :lang(ar) .quote blockquote { letter-spacing: normal; }
:lang(hi) h1, :lang(ar) h1 { line-height: 1.35; font-weight: 700; }
:lang(hi) .quote blockquote, :lang(ar) .quote blockquote { line-height: 1.6; }
:lang(hi) .body, :lang(ar) .body { line-height: 1.75; }
:lang(ar) h1 { font-size: clamp(34px, 7vw, 54px); }
:lang(ar) .eyebrow, :lang(ar) .move-label { font-size: 15px; }

/* email addresses always read left to right */
input[type="email"] { direction: ltr; }
[dir="rtl"] input[type="email"]:placeholder-shown { text-align: right; }

/* mirror the quote mark for right-to-left */
[dir="rtl"] .quote svg { transform: scaleX(-1); }

@media (max-width: 520px) {
  main.wrap { padding-block: 24px 48px; gap: 44px; }
  .check { gap: 22px; }
  .body { font-size: 19px; }
  .quote { padding: 22px; }
  .move p { font-size: 18px; }
}



/* typewriter entrance */
.tw-pending .check h1, .tw-pending .check .body, .tw-pending .check .quote blockquote,
.tw-pending .check .quote figcaption, .tw-pending .check .move p {
  visibility: hidden;
  /* safety net: show the text even if the script never runs */
  animation: tw-reveal 0s 5s forwards;
}
@keyframes tw-reveal { to { visibility: visible; } }
.tw-w { opacity: 0; }
.tw-w.on { opacity: 1; transition: opacity 0.32s ease-out; }

/* Boxes sit inside the column: their edges line up with the text above and below. */

/* previous / next, and the link to every past check */
.past { display: flex; flex-direction: column; gap: 16px; margin-top: -16px; }
.check-nav { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.check-nav a {
  display: flex; flex-direction: column; gap: 6px; padding: 16px 18px; min-height: 44px;
  border: 1px solid var(--line); border-radius: 14px; background: var(--surface); color: var(--ink);
}
.check-nav a:hover { border-color: var(--ink); text-decoration: none; }
.check-nav .next { text-align: end; }
.nav-label { font-size: 13px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }
.nav-title { font-family: var(--typed); font-size: 18px; line-height: 1.3; overflow-wrap: anywhere; }
.all-checks { align-self: flex-start; font-weight: 500; min-height: 44px; display: inline-flex; align-items: center; }
@media (max-width: 520px) {
  .check-nav { grid-template-columns: 1fr; }
  .check-nav span.prev, .check-nav span.next { display: none; }
  .check-nav .next { text-align: start; }
}

/* past checks page */
.archive { gap: 32px; }
.archive-head { display: flex; flex-direction: column; gap: 10px; }
.archive-head p { margin: 0; color: var(--text); font-size: 18px; }
.archive-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.archive-list li { border-bottom: 1px solid var(--line); }
.archive-list a { display: flex; flex-direction: column; gap: 6px; padding-block: 18px; color: var(--ink); }
.archive-list a:hover { text-decoration: none; }
.archive-list a:hover .archive-title { color: var(--accent); }
.archive-date { font-size: 13px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); display: flex; align-items: center; gap: 10px; }
.archive-title { font-family: var(--typed); font-size: 24px; line-height: 1.25; overflow-wrap: anywhere; }
.badge { font-size: 11px; letter-spacing: 0.06em; padding: 3px 8px; border-radius: 999px; background: var(--accent); color: #fff; }
:lang(hi) .nav-label, :lang(ar) .nav-label, :lang(hi) .archive-date, :lang(ar) .archive-date { letter-spacing: normal; }

/* highlighter: a soft, slightly uneven yellow stroke behind key words */
mark.hl {
  color: inherit;
  background-color: transparent;
  background-image:
    linear-gradient(100deg, rgba(255, 221, 64, 0) 0.6%, rgba(255, 221, 64, 0.85) 2.2%, rgba(255, 221, 64, 0.62) 7%, rgba(255, 221, 64, 0.52) 90%, rgba(255, 221, 64, 0.8) 96.5%, rgba(255, 221, 64, 0) 99.4%),
    linear-gradient(183deg, rgba(255, 221, 64, 0) 0%, rgba(255, 221, 64, 0.32) 12%, rgba(255, 221, 64, 0) 26%);
  background-repeat: no-repeat;
  background-size: 100% 64%;
  background-position: 0 88%;
  padding-inline: 0.14em;
  margin-inline: -0.14em;
  border-radius: 0.35em 0.6em 0.45em 0.7em;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
  transition: background-size 0.65s cubic-bezier(0.3, 0.7, 0.25, 1);
}
[dir="rtl"] mark.hl { background-position: 100% 88%; }
/* hidden while the text types; the sweep starts when typing ends */
.tw-pending mark.hl, .tw-typing mark.hl { background-size: 0% 64%; transition: none; }
/* a part's highlight sweeps in as soon as that part has been typed */
.tw-typing mark.hl.hl-on { background-size: 100% 64%; transition: background-size 0.65s cubic-bezier(0.3, 0.7, 0.25, 1); }

/* script fonts have no handwritten style: keep their labels a little smaller */
:lang(hi) .eyebrow > span:first-child, :lang(ar) .eyebrow > span:first-child { font-size: 16px; font-weight: 600; }
:lang(hi) .move-label, :lang(ar) .move-label { font-size: 16px; font-weight: 600; }

/* ---- Poppins sizing: one family, hierarchy by size and weight ---- */
.logo span { font-weight: 600; font-size: 19px; letter-spacing: -0.02em; }
h1 { font-weight: 600; font-size: clamp(32px, 6.4vw, 48px); line-height: 1.18; letter-spacing: -0.025em; }
.eyebrow > span:first-child, .move-label {
  font-family: var(--sans); font-size: 13px; font-weight: 600; line-height: 1.3;
  letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent);
}
.body { font-size: 18px; line-height: 1.7; }
.quote blockquote { font-weight: 500; font-size: clamp(20px, 3.8vw, 23px); line-height: 1.45; letter-spacing: -0.01em; }
.quote figcaption { font-size: 14px; font-weight: 400; }
.move p { font-size: 18px; line-height: 1.6; font-weight: 600; }
.newsletter h2, .signin h2 { font-weight: 600; font-size: 24px; letter-spacing: -0.02em; }
.nav-title { font-size: 16px; font-weight: 500; line-height: 1.4; }
.archive-title { font-size: 20px; font-weight: 600; line-height: 1.35; letter-spacing: -0.01em; }
@media (max-width: 520px) { .body { font-size: 17px; } .move p { font-size: 17px; } }
:lang(hi) h1, :lang(ar) h1 { letter-spacing: normal; line-height: 1.45; }
:lang(hi) .eyebrow > span:first-child, :lang(ar) .eyebrow > span:first-child, :lang(hi) .move-label, :lang(ar) .move-label { letter-spacing: normal; font-size: 14px; }

/* the day's stick-figure scene (drawn and animated by scene.js) */
.scene { margin: 0; width: 100%; max-width: 560px; aspect-ratio: 560 / 190; }
.scene svg { display: block; width: 100%; height: 100%; overflow: visible; }
.scene .ground, .scene .fig path, .scene .fig circle, .scene .prop path {
  fill: none; stroke: var(--ink); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round;
}
.scene .fig circle { fill: var(--bg); }
.scene .prop { opacity: 0; transition: opacity 0.4s ease; }
.scene .prop.on, .scene .bench, .scene .laptop, .scene .tree { opacity: 1; }
.scene .tree path { fill: var(--bg); }
.scene .leaf.on { animation: leaf-fall 3.6s cubic-bezier(.4,.1,.6,.9) forwards; }
.scene .leaf path { fill: var(--accent); stroke: var(--accent); stroke-width: 1.5; }
@keyframes leaf-fall {
  0% { transform: translate(var(--lx), 80px) rotate(0deg); opacity: 0; }
  8% { opacity: 1; }
  30% { transform: translate(calc(var(--lx) + 22px), 108px) rotate(60deg); }
  55% { transform: translate(calc(var(--lx) + 4px), 138px) rotate(-30deg); }
  100% { transform: translate(calc(var(--lx) + 26px), 168px) rotate(40deg); opacity: 1; }
}
.scene .plane path { fill: var(--bg); }
.scene .plane .dot { fill: var(--accent); stroke: none; }
.scene .cart, .scene .pile { opacity: 1; }
.scene .gold path { fill: #F4C542; }
.scene .cart circle { fill: var(--bg); }
.scene .cart .hub { fill: var(--ink); }
.scene .pile.on { animation: strain 0.32s ease-in-out infinite; }
@keyframes strain { 0%, 100% { transform: translateX(0); } 50% { transform: translateX(-1.6px); } }
.scene .list { opacity: 1; }
.scene .list path { fill: var(--surface); }
.scene .list .row { fill: none; stroke: #9A9A92; stroke-width: 2; }
.scene .list-use, .scene .pieces { opacity: 1; }
.scene .list > path:not(.row) { stroke: var(--ink); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.scene .slash { opacity: 1; }
.scene .slash path { fill: none; stroke: var(--accent); stroke-width: 5; stroke-linecap: round; stroke-dasharray: 1; stroke-dashoffset: 1; opacity: 0; }
.scene .slash.on path { animation: slash 0.6s ease-out forwards; }
@keyframes slash { 0% { stroke-dashoffset: 1; opacity: 1; } 30% { stroke-dashoffset: 0; opacity: 1; } 100% { stroke-dashoffset: 0; opacity: 0; } }
.scene .band path { fill: none; stroke: var(--accent); stroke-width: 4.2; stroke-linecap: round; }
.scene .band .tails { stroke-width: 3; }
.scene .sword .blade { fill: #EEF0F8; stroke: var(--ink); stroke-width: 2; stroke-linejoin: round; }
.scene .sword .hilt { stroke: var(--ink); stroke-width: 4.5; }
.scene .sword .guard { stroke: var(--accent); stroke-width: 3.6; }
.scene .list .paper { fill: var(--surface); stroke: #9A9A92; stroke-width: 1.4; }
.scene .list .row { stroke-width: 1.6; }
.scene .glasses path { fill: #F4C542; stroke: var(--ink); stroke-width: 1.5; stroke-linejoin: round; }
.scene .glasses path.bridge { fill: none; }
.scene .burst { opacity: 0; transform-box: fill-box; transform-origin: center; }
.scene .burst path { fill: none; stroke: currentColor; stroke-width: 3; stroke-linecap: round; }
.scene .burst circle { fill: currentColor; stroke: none; }
.scene .burst.y { color: #F4C542; }
.scene .burst.b { color: var(--accent); }
.scene .burst.r { color: #E5484D; }
.scene .burst.on { animation: burst 1.4s cubic-bezier(.1, .7, .3, 1) forwards; }
@keyframes burst { 0% { opacity: 0; transform: scale(0.15); } 12% { opacity: 1; } 70% { opacity: 1; transform: scale(1); } 100% { opacity: 0; transform: scale(1.12); } }
.scene .strike { opacity: 1; }
.scene .strike path { fill: none; stroke: var(--accent); stroke-width: 3.4; stroke-dasharray: 1; stroke-dashoffset: 1; transition: stroke-dashoffset 0.5s ease-out; }
.scene .strike.on path { stroke-dashoffset: 0; }
.scene .suitg path { stroke: var(--ink); fill: none; stroke-linecap: round; stroke-linejoin: round; }
.scene .suitg path.shirt { fill: var(--bg, #fff); stroke: none; }
.scene .tieg path { fill: var(--accent); stroke: var(--accent); stroke-width: 1px; stroke-linejoin: round; }
.scene .trailpath path { fill: none; stroke: var(--accent); stroke-width: 3.5px; stroke-linecap: round; stroke-dasharray: 0.1 9; }
.scene .trail { opacity: 1; }
.scene .trail circle { fill: var(--accent); opacity: 0; transition: opacity 0.2s ease; }
.scene .trail.on circle { opacity: 1; }
.scene .bulb .glow {
  fill: rgba(255, 221, 64, 0.75); opacity: 0; transform-box: fill-box; transform-origin: center; transform: scale(0.4);
  transition: opacity 0.5s ease, transform 0.6s cubic-bezier(0.3, 1.6, 0.5, 1);
}
.scene .bulb .filament { stroke: var(--accent); }
.scene .bulb .rays path { stroke: #E0B000; stroke-width: 3.5; opacity: 0; transition: opacity 0.3s ease 0.25s; }
.scene .bulb.lit .glow { opacity: 1; transform: scale(1); }
.scene .bulb.lit .rays path { opacity: 1; }
.scene .question { font: 600 26px var(--sans); fill: var(--accent); transition: opacity 0.25s ease; }
[dir="rtl"] .scene svg { transform: scaleX(-1); }
/* waits for its turn in the typing sequence */
.tw-pending .scene, .tw-typing .scene:not(.play) { visibility: hidden; }
/* Bob's ball */
.scene .ball circle { fill: var(--surface); stroke: var(--ink); stroke-width: 2.6; }
.scene .ball .seam { stroke-width: 2; }
/* boxes wait for their text to start typing */
.tw-pending .check .quote, .tw-pending .check .move,
.tw-typing .check .quote:not(.tw-on), .tw-typing .check .move:not(.tw-on) { visibility: hidden; }

/* Bob pulls the title in on a rope */
html, body { overflow-x: clip; }
@supports not (overflow: clip) { html, body { overflow-x: hidden; } }
.check { position: relative; }
.check h1 { will-change: transform; }
.rope-layer { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; z-index: 2; transition: opacity 0.35s ease; }
.rope-layer path { fill: none; stroke: var(--accent); stroke-width: 3; stroke-linecap: round; }
.rope-layer circle { fill: var(--accent); }
.rope-layer.gone { opacity: 0; }


/* a private countdown page */
.secret { display: flex; flex-direction: column; gap: 28px; padding-block: 64px; }
.secret h1 { margin: 0; }
.count { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.count > div { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 18px 8px 14px; text-align: center; }
.count b { display: block; font: 600 34px/1 var(--sans); font-variant-numeric: tabular-nums; color: var(--ink); }
.count span { display: block; margin-top: 8px; font: 500 12px/1 var(--sans); letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.secret .done { font-weight: 600; color: var(--accent-ink); font-size: 22px; }
@media (max-width: 480px) { .count b { font-size: 28px; } .count { gap: 8px; } }

/* new daily scenes: river, shadow, clock, dominoes, big question, plant, friend */
.scene .water .mask { fill: var(--bg); stroke: none; }
.scene .water path { fill: none; stroke: var(--accent); stroke-width: 2.4; stroke-linecap: round; opacity: 0.85; }
.scene .stone { opacity: 0; transform: translateY(10px); transition: opacity 0.25s ease, transform 0.4s cubic-bezier(.3, 1.7, .5, 1); }
.scene .stone.on { opacity: 1; transform: none; }
.scene .stone rect { fill: var(--surface); stroke: var(--ink); stroke-width: 2.4; }
.scene .wall { fill: var(--surface); stroke: #CFCFC8; stroke-width: 2; }
.scene .catbox { opacity: 1; }
.scene .catbox.on { animation: cat-hop 0.5s ease-in-out 3; }
@keyframes cat-hop { 0%, 100% { transform: translate(340px, 172px); } 50% { transform: translate(340px, 158px); } }
.scene .cat * { fill: var(--ink); stroke: var(--ink); stroke-width: 1; stroke-linejoin: round; }
.scene .cat .tail { fill: none; stroke-width: 3; stroke-linecap: round; }
.scene .cat .eye { fill: #fff; stroke: none; }
.scene .cat .teeth { fill: none; stroke: #fff; stroke-width: 0.5; }
.scene .pulse { transform-origin: 482px 172px; animation: shadow-pulse 0.8s ease-in-out infinite; }
.scene .pulse.calm { animation: none; }
@keyframes shadow-pulse { 0%, 100% { transform: scale(1) rotate(0deg); } 50% { transform: scale(1.05) rotate(-0.6deg); } }
.scene .lamp .glow { fill: #F4C542; opacity: 0.3; stroke: none; }
.scene .lamp .glass { fill: #FBE9A6; stroke: var(--ink); stroke-width: 2; }
.scene .lamp .h { fill: none; stroke: var(--ink); stroke-width: 2; stroke-linecap: round; }
.scene .clock path { fill: none; stroke: var(--ink); stroke-width: 3; stroke-linecap: round; }
.scene .clock .face { fill: var(--surface); stroke: var(--ink); stroke-width: 3; }
.scene .clock .tick { stroke-width: 2; }
.scene .clock .hh { stroke-width: 4.6; }
.scene .clock .mh { stroke-width: 3; }
.scene .clock .hub { fill: var(--ink); }
.scene .crank path { fill: none; stroke: var(--ink); stroke-width: 3.4; stroke-linecap: round; }
.scene .crank circle { fill: var(--accent); stroke: var(--ink); stroke-width: 2; }
.scene .crank .axle { fill: var(--ink); }
.scene .rarrow path { fill: none; stroke: var(--accent); stroke-width: 3.2; stroke-linecap: round; stroke-linejoin: round; }
.scene .zzz { opacity: 1; }
.scene .zzz text { font: 600 18px var(--sans); fill: var(--accent); opacity: 0; }
.scene .zzz.on text { animation: z-float 2.4s ease-in-out infinite; }
@keyframes z-float { 0% { opacity: 0; transform: translate(0, 6px); } 25% { opacity: 1; } 100% { opacity: 0; transform: translate(10px, -14px); } }
.scene .domino rect { fill: var(--surface); stroke: var(--ink); stroke-width: 2.2; }
.scene .domino path { fill: none; stroke: var(--ink); stroke-width: 1.6; }
.scene .bigq text { font: 700 150px var(--sans); fill: var(--accent); opacity: 0.92; }
.scene .bigq.ans text { fill: #F4C542; stroke: var(--ink); stroke-width: 6px; paint-order: stroke; }
.scene .mound { opacity: 1; }
.scene .mound path { fill: var(--bg); stroke: var(--ink); stroke-width: 3; }
.scene .mound ellipse { fill: var(--ink); }
.scene .plantg path { fill: none; stroke: var(--ink); stroke-width: 3; stroke-linecap: round; }
.scene .plantg .leaf2 { fill: #BFE3C6; stroke-width: 2.2; }
.scene .flower { opacity: 0; transform: scale(0.1); transform-box: view-box; transition: opacity 0.4s ease, transform 0.8s cubic-bezier(.3, 1.6, .5, 1); }
.scene .flower.on { opacity: 1; transform: scale(1); }
.scene .flower .petal { fill: var(--surface); stroke: var(--ink); stroke-width: 2; }
.scene .flower .core { fill: #F4C542; stroke: var(--ink); stroke-width: 2; }
.scene .butterfly .w { fill: var(--accent); stroke: none; transform-box: fill-box; transform-origin: right center; animation: wing-flap 0.22s ease-in-out infinite alternate; }
.scene .butterfly.on { animation: flutter 6s ease-in-out infinite; }
@keyframes wing-flap { from { transform: scaleX(1); } to { transform: scaleX(0.35); } }
@keyframes flutter { 0%, 100% { transform: translate(0, 0); } 25% { transform: translate(-26px, 14px); } 50% { transform: translate(-6px, 30px); } 75% { transform: translate(-34px, 20px); } }
.scene .friend { opacity: 1; }
.scene .friend path, .scene .friend circle { stroke: var(--ink); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; fill: none; }
.scene .friend circle { fill: var(--bg); }
.scene .friend .scarf { stroke: var(--accent); stroke-width: 4.2; }
.scene .friend.on { animation: friend-hop 0.45s ease-in-out 3; }
@keyframes friend-hop { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-9px); } }
.scene .friend.on .a1 { animation: cheer-a 0.7s ease-out forwards; }
.scene .friend.on .a2 { animation: cheer-b 0.7s ease-out forwards; }
@keyframes cheer-a { to { transform: rotate(125deg); } }
@keyframes cheer-b { to { transform: rotate(-125deg); } }
.scene .heart path { fill: #E5484D; stroke: none; }
.scene .heart.on { opacity: 1; }
.scene .heart.h1.on { animation: heart-pop 0.8s ease-out both; }
@keyframes heart-pop { 0% { opacity: 0; transform: translateY(0) scale(0.2); } 45% { opacity: 1; transform: translateY(-6px) scale(1.3); } 100% { opacity: 1; transform: translateY(-4px) scale(1); } }
.scene .shoutg text { font: 700 15px var(--sans); fill: var(--accent); }
.scene .shoutg path { fill: none; stroke: var(--accent); stroke-width: 3; stroke-linecap: round; }
.scene .mega path { fill: var(--surface); stroke: var(--ink); stroke-width: 2.5; stroke-linejoin: round; }
.scene .mega .ring { fill: none; stroke: var(--accent); stroke-width: 3.6; stroke-linecap: round; }

.share-menu {
  position: absolute; bottom: calc(100% + 6px); z-index: 20; min-width: 190px; padding: 6px;
  background: var(--surface); border: 1px solid var(--line); border-radius: 14px;
  box-shadow: 0 10px 30px rgba(26, 26, 26, 0.14);
}
.share-menu[hidden] { display: none; }
.share-menu a, .share-menu button {
  display: block; width: 100%; box-sizing: border-box; text-align: start; padding: 11px 14px; border: 0; border-radius: 9px;
  background: none; color: var(--ink); font: 500 15px/1.2 var(--sans); cursor: pointer; text-decoration: none;
}
.share-menu a:hover, .share-menu button:hover, .share-menu a:focus-visible, .share-menu button:focus-visible { background: var(--bg); color: var(--accent-ink); outline: none; }

/* November scenes: kite, room and sunrise, desk and phone, paper planes, shoes, race, black cat */
.scene .wind path { fill: none; stroke: #9AA3C7; stroke-width: 2.4; stroke-linecap: round; stroke-dasharray: 28 140; }
.scene .wind.on path { animation: wind-blow 1.1s linear infinite; }
.scene .wind.on path:nth-child(2) { animation-delay: 0.3s; }
.scene .wind.on path:nth-child(3) { animation-delay: 0.6s; }
@keyframes wind-blow { from { stroke-dashoffset: 168; } to { stroke-dashoffset: 0; } }
.scene .kstring { fill: none; stroke: var(--ink); stroke-width: 1.2; opacity: 0.7; }
.scene .ktail { fill: none; stroke: var(--ink); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.scene .kbody { fill: #F4C542; stroke: var(--ink); stroke-width: 2.6; stroke-linejoin: round; }
.scene .kcross { fill: none; stroke: var(--ink); stroke-width: 1.6; }
.scene .kbow { fill: var(--accent); stroke: none; }
.scene .laugh { font: 700 20px var(--sans); fill: var(--accent); }
.scene .room .rfill { fill: #C9CCD3; opacity: 0.55; stroke: none; }
.scene .room .rwall { fill: none; stroke: var(--ink); stroke-width: 3; stroke-linejoin: round; }
.scene .room .rcloud { fill: #9EA3AD; stroke: none; }
.scene .rdoor { fill: #8E7350; stroke: var(--ink); stroke-width: 1.5; transition: transform 0.5s cubic-bezier(.3, 1.4, .5, 1); transform-box: view-box; }
.scene .rdoor.open { transform: scaleX(7.5); }
.scene .sun { opacity: 0; transform: translateY(70px); transition: opacity 0.6s ease, transform 1.6s cubic-bezier(.2, .8, .3, 1); }
.scene .sun.on { opacity: 1; transform: none; }
.scene .sun circle { fill: #F4C542; stroke: #E0A800; stroke-width: 2; }
.scene .sun .ray { fill: none; stroke: #F4B400; stroke-width: 3; stroke-linecap: round; }
.scene .birds { opacity: 0; }
.scene .birds.on { opacity: 1; animation: birds-fly 6s linear forwards; }
.scene .birds path { fill: none; stroke: var(--ink); stroke-width: 2; stroke-linecap: round; transform-box: fill-box; transform-origin: center; animation: bird-flap 0.35s ease-in-out infinite alternate; }
@keyframes birds-fly { from { transform: translate(0, 0); } to { transform: translate(260px, -30px); } }
@keyframes bird-flap { from { transform: scaleY(1); } to { transform: scaleY(-0.6); } }
.scene .bloom { opacity: 1; }
.scene .bloom g { transform: scale(0); transition: transform 0.5s cubic-bezier(.3, 1.6, .5, 1); }
.scene .bloom.on g { transform: scale(1); }
.scene .bloom .stem { fill: none; stroke: #3E9B5B; stroke-width: 2.4; }
.scene .bloom .petal.y { fill: #F4C542; stroke: var(--ink); stroke-width: 1.5; }
.scene .bloom .petal.b { fill: var(--accent); stroke: var(--ink); stroke-width: 1.5; }
.scene .window .wsky { fill: #DCE6F7; }
.scene .window .wframe { fill: none; stroke: var(--ink); stroke-width: 3; stroke-linejoin: round; }
.scene .sun.small { transform: translateY(50px); }
.scene .sun.small.on { transform: translateY(-10px); }
.scene .desk { fill: none; stroke: var(--ink); stroke-width: 3; stroke-linecap: round; }
.scene .drawer rect { fill: var(--surface); stroke: var(--ink); stroke-width: 2.4; }
.scene .drawer circle { fill: var(--ink); }
.scene .drawer { transition: transform 0.4s ease; }
.scene .drawer.open { transform: translateX(-24px); }
.scene .phone .pbody { fill: var(--ink); }
.scene .phone .buzz { fill: none; stroke: var(--accent); stroke-width: 1.8; stroke-linecap: round; opacity: 0; }
.scene .phone.buzzing .buzz { animation: buzz-blink 0.5s steps(2) infinite; }
.scene .phone.buzzing .pbody { transform-box: fill-box; transform-origin: center bottom; animation: buzz-shake 0.12s linear infinite alternate; }
@keyframes buzz-blink { 50% { opacity: 1; } }
@keyframes buzz-shake { from { transform: rotate(-7deg) translateY(-1px); } to { transform: rotate(7deg) translateY(0); } }
.scene .umbrella .canopy { fill: var(--accent); stroke: var(--ink); stroke-width: 2.4; stroke-linejoin: round; }
.scene .umbrella .shaft { fill: none; stroke: var(--ink); stroke-width: 2.4; stroke-linecap: round; }
.scene .pplane { fill: var(--surface); stroke: var(--ink); stroke-width: 1.6; stroke-linejoin: round; }
.scene .pplane.gold { fill: #F4C542; }
.scene .nightsky { fill: #1F2547; opacity: 0.16; transition: opacity 1.4s ease; }
.scene .nightsky.day { opacity: 0; }
.scene .moon { fill: #F7E7A6; stroke: #C9B65E; stroke-width: 1.5; transition: transform 1.4s ease, opacity 1.4s ease; }
.scene .moon.set { transform: translateY(60px); opacity: 0; }
.scene .hdoor { fill: none; stroke: var(--ink); stroke-width: 3; stroke-linejoin: round; stroke-linecap: round; }
.scene .shoe { fill: var(--accent); stroke: var(--ink); stroke-width: 1.4; stroke-linejoin: round; }
.scene .posts { fill: none; stroke: var(--ink); stroke-width: 3; stroke-linecap: round; }
.scene .banner { fill: var(--ink); }
.scene .bannertxt { font: 700 10px var(--sans); fill: #fff; text-anchor: middle; letter-spacing: 0.08em; }
.scene .tape path { fill: none; stroke: #E5484D; stroke-width: 3; stroke-linecap: round; transition: transform 0.6s cubic-bezier(.3, 1.4, .5, 1); transform-box: view-box; }
.scene .tape.broken .tl { transform: rotate(70deg); }
.scene .tape.broken .tr { transform: rotate(-70deg); }
.scene .tortoise { opacity: 1; }
.scene .tortoise.on { animation: tortoise-walk 14s linear forwards; }
.scene .tortoise .shell { fill: #7FBF8E; stroke: var(--ink); stroke-width: 2; }
.scene .tortoise .tbits { fill: none; stroke: var(--ink); stroke-width: 2; stroke-linecap: round; }
@keyframes tortoise-walk { from { transform: translateX(0); } to { transform: translateX(64px); } }
.scene .rival circle { fill: var(--bg); stroke: var(--ink); stroke-width: 3; }
.scene .rival path { fill: none; stroke: var(--ink); stroke-width: 3; stroke-linecap: round; }
.scene .rival .rband { stroke: #E5484D; stroke-width: 3.4; }
.scene .rival .speed { stroke: #9AA3C7; stroke-width: 2; }
.scene .rival .rleg.a, .scene .rival .rarm.b { animation: run-swing 0.22s ease-in-out infinite alternate; }
.scene .rival .rleg.b, .scene .rival .rarm.a { animation: run-swing 0.22s ease-in-out infinite alternate-reverse; }
@keyframes run-swing { from { transform: rotate(38deg); } to { transform: rotate(-38deg); } }
.scene .calpage .calbody { fill: var(--surface); stroke: var(--ink); stroke-width: 2; }
.scene .calpage .calhead { fill: #E5484D; stroke: var(--ink); stroke-width: 2; }
.scene .calpage .calday { font: 700 9px var(--sans); fill: #fff; text-anchor: middle; letter-spacing: 0.08em; }
.scene .calpage .calnum { font: 700 22px var(--sans); fill: var(--ink); text-anchor: middle; }
.scene .bcat.purr { animation: cat-purr 0.4s ease-in-out 3; }
@keyframes cat-purr { 50% { opacity: 0.85; } }
.scene .catheart.on { opacity: 1; animation: heart-float 1.6s ease-out forwards; }
.scene .catheart path, .scene path.catheart { fill: #E5484D; stroke: none; }
@keyframes heart-float { 0% { opacity: 0; } 20% { opacity: 1; } 80% { opacity: 1; } 100% { opacity: 0; } }
.scene .bcat .cat .eye { fill: #F4C542; stroke: none; }

/* late-November scenes */
[dir="rtl"] .scene svg text { transform-box: fill-box; transform-origin: center; transform: scaleX(-1); }
.scene .mitem .mi { fill: var(--surface); stroke: var(--ink); stroke-width: 2; stroke-linejoin: round; }
.scene .mitem .mi.sock { fill: #E5484D; }
.scene .mitem .mi.book { fill: var(--accent); }
.scene .mline { fill: none; stroke: var(--ink); stroke-width: 1.6; stroke-linecap: round; }
.scene .mbox .mfront { fill: #E8C99A; stroke: var(--ink); stroke-width: 2.4; stroke-linejoin: round; }
.scene .mbox .mflap { fill: none; stroke: var(--ink); stroke-width: 2.4; stroke-linecap: round; }
.scene .sparkle path { fill: #F4C542; stroke: #E0A800; stroke-width: 1.2; }
.scene .sparkle.on path { animation: twinkle 0.9s ease-in-out infinite alternate; }
@keyframes twinkle { from { transform: scale(0.4) rotate(0deg); opacity: 0.4; } to { transform: scale(1.15) rotate(25deg); opacity: 1; } }
.scene .boulder circle { fill: #C9C4BA; stroke: var(--ink); stroke-width: 3; }
.scene .boulder .crack { fill: none; stroke: var(--ink); stroke-width: 2; stroke-linecap: round; }
.scene .boulder .wig.on { animation: wiggle 0.12s linear infinite alternate; }
@keyframes wiggle { from { transform: rotate(-2deg); } to { transform: rotate(2deg); } }
.scene .sweat { fill: #8FB3F2; stroke: none; }
.scene .cstring { fill: none; stroke: var(--ink); stroke-width: 1.4; }
.scene .rcloud2 .cbody { fill: #A9ADB7; stroke: var(--ink); stroke-width: 2.2; stroke-linejoin: round; }
.scene .rcloud2 .crain path { fill: none; stroke: #6C8FD6; stroke-width: 2; stroke-linecap: round; animation: rain-drop 0.7s linear infinite; }
.scene .rcloud2.dry .crain { opacity: 0; transition: opacity 0.4s ease; }
@keyframes rain-drop { from { transform: translateY(0); opacity: 1; } to { transform: translateY(26px); opacity: 0; } }
.scene .jball { stroke: var(--ink); stroke-width: 1.6; }
.scene .tada { font: 700 18px var(--sans); fill: var(--accent); }
.scene .ringline { fill: none; stroke: var(--accent); stroke-width: 2; stroke-dasharray: 2 7; stroke-linecap: round; opacity: 0; }
.scene .ringline.on { opacity: 1; animation: ring-flow 0.6s linear infinite; }
.scene .ringline.done { opacity: 0; transition: opacity 0.5s ease 0.6s; }
@keyframes ring-flow { to { stroke-dashoffset: -18; } }
.scene .cphone rect { fill: var(--ink); }
.scene .cphone.ringing rect { animation: buzz-shake 0.1s linear infinite alternate; transform-box: fill-box; transform-origin: center; }
.scene .bubble rect, .scene .bubble path { fill: var(--surface); stroke: var(--ink); stroke-width: 2; stroke-linejoin: round; }
.scene .bubble path { stroke: none; }
.scene .bubble text { font: 700 13px var(--sans); fill: var(--ink); text-anchor: middle; }
.scene .hearts path { fill: #E5484D; opacity: 0; }
.scene .hearts.on path { animation: heart-rise 1.8s ease-out infinite; }
@keyframes heart-rise { 0% { opacity: 0; transform: translateY(10px); } 25% { opacity: 1; } 100% { opacity: 0; transform: translateY(-26px); } }
.scene .boombox .bbody { fill: var(--accent); stroke: var(--ink); stroke-width: 2.4; }
.scene .boombox .spk { fill: var(--surface); stroke: var(--ink); stroke-width: 2; }
.scene .boombox .handle { fill: none; stroke: var(--ink); stroke-width: 2.4; stroke-linejoin: round; }
.scene .music path { fill: none; stroke: var(--ink); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.scene .music ellipse { fill: var(--ink); }
.scene .music.on g { animation: note-rise 1.4s ease-out infinite; opacity: 0; }
@keyframes note-rise { 0% { opacity: 0; transform: translate(0, 6px); } 30% { opacity: 1; } 100% { opacity: 0; transform: translate(8px, -22px); } }
.scene .bigrock { fill: #C9C4BA; stroke: var(--ink); stroke-width: 3; stroke-linejoin: round; }
.scene .rockline { fill: none; stroke: var(--ink); stroke-width: 2; stroke-linecap: round; }
.scene .pebble { fill: #C9C4BA; stroke: var(--ink); stroke-width: 2; }
.scene .flag .pole { fill: none; stroke: var(--ink); stroke-width: 2.4; stroke-linecap: round; }
.scene .flag .cloth { fill: #E5484D; stroke: var(--ink); stroke-width: 1.6; stroke-linejoin: round; }
.scene .flag { transform-box: fill-box; transform-origin: bottom left; transform: scaleY(0); transition: transform 0.5s cubic-bezier(.3, 1.6, .5, 1), opacity 0.2s; }
.scene .flag.on { transform: scaleY(1); }
.scene .mate circle { fill: #FFE1B3; }

/* newsletter honeypot: hidden from people, bots fill it in */
.newsletter .hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
