/* ==========================================================================
   VerbaPop — content pages (answer archive + answer pages)
   Loaded after styles.css, which supplies the tokens, fonts, .btn and .brand.
   ========================================================================== */

/* ---------- Site header ---------- */

.site-head {
  width: 100%;
  max-width: 960px;
  margin: 0 auto;
  padding: calc(12px + env(safe-area-inset-top)) 20px 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.site-head .brand { text-decoration: none; color: inherit; }
.site-nav {
  display: inline-flex;
  padding: 4px;
  border-radius: 999px;
  background: var(--bg-2);
}
.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0 14px;
  border-radius: 999px;
  color: var(--ink-2);
  font-weight: 700;
  font-size: .92rem;
  text-decoration: none;
  transition: background-color .2s, color .2s;
}
.site-nav a:hover { color: var(--ink); }
.site-nav a[aria-current="page"] {
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow);
}
.site-nav .site-nav__play {
  background: var(--ink);
  color: var(--bg);
}
.site-nav .site-nav__play:hover { color: var(--bg); }

/* ---------- Page shell ---------- */

.page {
  width: 100%;
  max-width: 960px;
  margin: 0 auto;
  padding: 12px 20px calc(48px + env(safe-area-inset-bottom));
}
.page a:not(.btn):not(.archive-card) { color: var(--ink); text-underline-offset: 3px; }

.crumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0 0 18px;
  padding: 0;
  list-style: none;
  font-size: .88rem;
  color: var(--ink-2);
}
.crumbs a { color: var(--ink-2) !important; text-decoration: none; }
.crumbs a:hover { color: var(--ink) !important; text-decoration: underline; }
.crumbs li + li::before { content: '/'; margin-right: 6px; opacity: .5; }

/* ---------- Hero ---------- */

.hero {
  position: relative;
  padding: 28px 24px;
  margin-bottom: 28px;
  border-radius: 24px;
  background: var(--surface);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.hero__bubbles { position: absolute; inset: 0; pointer-events: none; }
.hero__bubbles span {
  position: absolute;
  border-radius: 50%;
  border: 2px solid hsl(var(--hue) 70% 58% / .45);
  background:
    radial-gradient(circle at 30% 27%, rgb(255 255 255 / .9) 0 6%, rgb(255 255 255 / 0) 13%),
    radial-gradient(circle, hsl(var(--hue) 95% 88% / .2), hsl(var(--hue) 90% 72% / .5) 70%);
}
.hero__bubbles span:nth-child(1) { --hue: 4; width: 150px; height: 150px; right: -30px; top: -40px; }
.hero__bubbles span:nth-child(2) { --hue: 198; width: 84px; height: 84px; right: 110px; top: 34px; }
.hero__bubbles span:nth-child(3) { --hue: 46; width: 54px; height: 54px; right: 40px; bottom: 18px; }
.hero > :not(.hero__bubbles) { position: relative; }
@media (max-width: 640px) {
  .hero__bubbles span:nth-child(2), .hero__bubbles span:nth-child(3) { display: none; }
  .hero__bubbles span:nth-child(1) { opacity: .5; width: 110px; height: 110px; right: -46px; top: -54px; }
}

.page__eyebrow {
  margin: 0;
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.page__title {
  margin: 6px 0 10px;
  max-width: 18ch;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2rem, 6vw, 3.1rem);
  line-height: 1.04;
  letter-spacing: -.01em;
}
.page__lede {
  margin: 0 0 20px;
  max-width: 58ch;
  color: var(--ink-2);
  font-size: 1.06rem;
}
.page__lede b { color: var(--ink); }
.page__cta { display: flex; flex-wrap: wrap; gap: 10px; }
.page__cta .btn { text-decoration: none; height: 48px; }

.section-title {
  margin: 0 0 14px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.4rem;
}

/* ---------- Archive grid ---------- */

.archive-grid {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 200px), 1fr));
}
@media (max-width: 640px) {
  .archive-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .archive-card { min-height: 116px; padding: 14px; }
  .archive-card__anchor { font-size: 1.05rem; }
  .archive-card::after { width: 64px; height: 64px; right: -18px; top: -18px; }
}
.archive-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-height: 132px;
  padding: 18px 18px 16px;
  border-radius: 18px;
  background: var(--surface);
  box-shadow: var(--shadow);
  color: var(--ink);
  text-decoration: none;
  overflow: hidden;
  transition: transform .15s ease, box-shadow .15s ease;
}
.archive-card:hover { transform: translateY(-2px); box-shadow: 0 18px 34px -16px rgb(40 30 10 / .35); }
.archive-card::after {
  content: '';
  position: absolute;
  right: -22px;
  top: -22px;
  width: 86px;
  height: 86px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 30% 30%, rgb(255 255 255 / .6) 0 8%, rgb(255 255 255 / 0) 16%),
    radial-gradient(circle, hsl(var(--hue) 88% 80%), hsl(var(--hue) 80% 66%));
  opacity: .9;
}
.archive-card__num {
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.archive-card__anchor {
  position: relative;
  z-index: 1;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.45rem;
  line-height: 1.1;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}
.archive-card__meta { color: var(--ink-2); font-size: .9rem; }
.archive-card__go {
  margin-top: auto;
  padding-top: 8px;
  font-weight: 700;
  font-size: .9rem;
}
.archive-card.is-latest { outline: 2px solid var(--ink); outline-offset: -2px; }

/* ---------- Empty state ---------- */

.empty {
  display: grid;
  justify-items: center;
  gap: 8px;
  padding: 40px 24px;
  border: 2px dashed var(--line);
  border-radius: 24px;
  text-align: center;
}
.empty__bubbles { display: flex; align-items: flex-end; gap: 8px; margin-bottom: 8px; }
.empty__bubbles span {
  border-radius: 50%;
  border: 2px solid hsl(var(--hue) 70% 58% / .55);
  background:
    radial-gradient(circle at 30% 27%, rgb(255 255 255 / .95) 0 6%, rgb(255 255 255 / 0) 13%),
    radial-gradient(circle, hsl(var(--hue) 95% 88% / .25), hsl(var(--hue) 90% 76% / .5) 62%, hsl(var(--hue) 85% 62% / .75));
  animation: float 5s ease-in-out infinite;
}
.empty__bubbles span:nth-child(1) { --hue: 145; width: 44px; height: 44px; animation-delay: -1s; }
.empty__bubbles span:nth-child(2) { --hue: 256; width: 64px; height: 64px; animation-delay: -2.5s; }
.empty__bubbles span:nth-child(3) { --hue: 28; width: 36px; height: 36px; animation-delay: -4s; }
.empty h2 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.4rem;
}
.empty p { margin: 0 0 10px; max-width: 46ch; color: var(--ink-2); }
.empty .btn { text-decoration: none; }

/* ---------- Answer page ---------- */

.reveal {
  border-radius: 20px;
  background: var(--surface);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.reveal > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 18px 20px;
  cursor: pointer;
  list-style: none;
  font-weight: 700;
  font-size: 1.05rem;
}
.reveal > summary::-webkit-details-marker { display: none; }
.reveal > summary::after {
  content: 'Show';
  flex: none;
  padding: 6px 14px;
  border-radius: 999px;
  background: var(--ink);
  color: var(--bg);
  font-size: .85rem;
}
.reveal[open] > summary::after { content: 'Hide'; background: var(--bg-2); color: var(--ink); }
.reveal > summary small { display: block; font-weight: 500; color: var(--ink-2); font-size: .88rem; }

.answer-grid {
  margin: 0;
  padding: 0 20px 20px;
  list-style: none;
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
}
.answer {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 14px;
  background: hsl(var(--hue) 80% 92%);
  color: hsl(var(--hue) 60% 18%);
}
.answer__dot {
  flex: none;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: .82rem;
  background:
    radial-gradient(circle at 30% 28%, rgb(255 255 255 / .6) 0 10%, rgb(255 255 255 / 0) 22%),
    radial-gradient(circle, hsl(var(--hue) 88% 76%), hsl(var(--hue) 80% 62%));
}
.answer__text { display: grid; gap: 1px; min-width: 0; }
.answer__phrase {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.12rem;
  line-height: 1.15;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}
.answer__phrase .is-anchor { opacity: .5; }
.answer__hint { font-size: .88rem; opacity: .8; }
@media (prefers-color-scheme: dark) {
  .answer { background: hsl(var(--hue) 45% 22%); color: hsl(var(--hue) 70% 90%); }
}

.pager {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 24px;
}
.pager a {
  display: grid;
  gap: 2px;
  padding: 14px 16px;
  border-radius: 16px;
  background: var(--surface);
  box-shadow: var(--shadow);
  text-decoration: none;
}
.pager a small { color: var(--ink-2); font-weight: 700; font-size: .78rem; letter-spacing: .08em; text-transform: uppercase; }
.pager a b { font-family: var(--font-display); font-weight: 600; font-size: 1.1rem; }
.pager .pager__next { text-align: right; grid-column: 2; }

.more { margin-top: 40px; }

/* ---------- Prose (privacy) ---------- */

.prose { max-width: 66ch; font-size: 1.02rem; }
.prose h2 {
  margin: 26px 0 6px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.25rem;
}
.prose h2:first-child { margin-top: 0; }
.prose p { margin: 0 0 12px; color: var(--ink-2); }

/* ---------- Human sitemap ---------- */

.map {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr));
}
.map-col {
  padding: 20px;
  border-radius: 20px;
  background: var(--surface);
  box-shadow: var(--shadow);
}
.map-col h2 {
  margin: 0 0 10px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.2rem;
}
.map-col h2 a { text-decoration: none; }
.map-col ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.map-col li { display: flex; justify-content: space-between; gap: 12px; }
.map-col li span { color: var(--ink-2); font-size: .88rem; font-variant-numeric: tabular-nums; }
