/* cubby.md placeholder — one small page, no scripts, no web fonts, no third-party requests.
   Look follows site/site.css: Cubby Indigo #5b5bd6, the "cubby.md" wordmark with a softer ".md",
   Space Grotesk / Inter if the visitor has them installed, otherwise the system font. */

:root {
  --indigo: #5b5bd6;
  --bg: #fafbff;
  --ink: #1c1e26;
  --ink-soft: #5a6072;
  --pill-bg: #f3f3fc;
  --pill-border: #e1e2f4;
  --glow: rgba(91, 91, 214, 0.15);
  --shadow: rgba(91, 91, 214, 0.26);
  --font-display: "Space Grotesk", "Segoe UI", system-ui, -apple-system, Roboto, Helvetica, Arial, sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --indigo: #8f8ff0;
    --bg: #14151c;
    --ink: #eceef6;
    --ink-soft: #a3a8ba;
    --pill-bg: #1e1f2b;
    --pill-border: #2e3042;
    --glow: rgba(120, 120, 235, 0.20);
    --shadow: rgba(0, 0, 0, 0.45);
  }
}

* { box-sizing: border-box; }

html, body { margin: 0; height: 100%; }

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.55;
  -webkit-text-size-adjust: 100%;
}

main {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 2.5rem 16px 3.5rem;
  overflow: hidden;
}

/* soft glow behind the mascot, same as the site hero */
main::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 560px;
  max-width: 120vw;
  height: 560px;
  transform: translate(-50%, -62%);
  background: radial-gradient(circle closest-side, var(--glow), transparent);
  pointer-events: none;
  z-index: 0;
}
main > * { position: relative; z-index: 1; }

.mascot {
  display: block;
  width: 136px;
  height: 136px;
  margin: 0 auto 1.4rem;
  filter: drop-shadow(0 14px 26px var(--shadow));
}

.wordmark {
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 6vw, 2rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1;
  margin: 0 0 1rem;
  color: var(--indigo);
}

.tagline {
  font-family: var(--font-display);
  font-size: clamp(2rem, 8.5vw, 3.2rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.08;
  margin: 0 auto 1rem;
  max-width: 14em;
  color: var(--ink);
}

.tiles {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem 1.6rem;
  margin: 0 auto 1.8rem;
  padding: 0;
  max-width: 36rem;
}
/* flat labels, not cards: nothing here is clickable, so nothing may look like a button */
.tiles li {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1rem;
  line-height: 1.3;
  color: var(--ink);
  white-space: nowrap;
}
.tiles li::before {                 /* the same little indigo box as the status line */
  content: "";
  display: inline-block;
  width: 0.55rem;
  height: 0.55rem;
  margin-right: 0.5rem;
  border-radius: 2px;
  background: var(--indigo);
  vertical-align: 0.05em;
}
.wordmark .tld { color: var(--ink-soft); font-weight: 600; }

.what {
  max-width: 32rem;
  margin: 0 auto 1.6rem;
  font-size: clamp(1.05rem, 3.6vw, 1.2rem);
  color: var(--ink);
}

.status {
  display: inline-block;
  max-width: 100%;
  margin: 0;
  padding: 0.55rem 1.1rem;
  border-radius: 999px;
  background: var(--pill-bg);
  border: 1px solid var(--pill-border);
  color: var(--ink-soft);
  font-size: 0.98rem;
}
.status::before {
  content: "";
  display: inline-block;
  width: 0.55rem;
  height: 0.55rem;
  margin-right: 0.55rem;
  border-radius: 2px;              /* a little box, the cubby motif */
  background: var(--indigo);
  vertical-align: 0.05em;
}

.back {
  margin-top: 1.6rem;
  font-size: 0.98rem;
}
.back a {
  color: var(--indigo);
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1.5px solid currentColor;
}
.back a:hover, .back a:focus-visible { opacity: 0.8; }

h1.lost {
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 6vw, 2.1rem);
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin: 0 0 0.7rem;
}

@media (max-width: 380px) {
  .mascot { width: 112px; height: 112px; }
  .status { border-radius: 14px; }
}

/* ===== Opening sequence (intro.js; plan in ../opening-sequence.md) =====
   Only while html.intro is set. Removing that class (skip / end / error) shows everything at once. */
.intro [data-type]:not(.split) { visibility: hidden; }        /* until the headline is split into letters */
.intro [data-at], .intro [data-after] {
  opacity: 0;
  transform: translateY(6px);
}
.intro [data-at].in, .intro [data-after].in {
  opacity: 1;
  transform: none;
  transition: opacity 0.4s ease, transform 0.4s ease;
}
.intro .mascot[data-at] { transform: none; }
.intro .mascot[data-at].in { animation: pop 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) both; transition: none; }
@keyframes pop {
  from { opacity: 0; transform: scale(0.8); }
  to   { opacity: 1; transform: scale(1); }
}
.intro main::before { opacity: 0; }
.intro main.glow::before { opacity: 1; transition: opacity 0.6s ease; }

/* Headline letters: each sits in its final place, hidden, and appears one by one. */
.tagline .tw-c { visibility: hidden; }
.tagline .tw-c.tw-on { visibility: visible; }
.tagline .tw-c.tw-caret { position: relative; }
.tagline .tw-c.tw-caret::after {
  content: "";
  position: absolute;
  right: -0.08em;
  top: 0.12em;
  width: 3px;
  height: 0.9em;
  background: var(--indigo);
  animation: tw-blink 1s step-end infinite;
}
@keyframes tw-blink { 50% { opacity: 0; } }
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
