/* ============================================================
   Age & Sleep Calculator — Neo-Brutalist design system
   Single stylesheet for the whole site. No external fonts.
   Light + dark mode via html[data-theme="dark"].
   ============================================================ */

/* ---------- Tokens ---------- */
:root {
  --bg: #f2efe9;
  --surface: #ffffff;
  --ink: #141414;
  --muted: #5f5a50;
  --lime: #c6ff00;
  --purple: #7c3aed;
  --pink: #ff4d9d;
  --lime-soft: #edffb0;
  --purple-soft: #ede4ff;
  --pink-soft: #ffe3ef;
  --error: #c4001d;
  --error-soft: #ffe3e6;
  --border-w: 3px;
  --border: var(--border-w) solid var(--ink);
  --shadow: 6px 6px 0 var(--ink);
  --shadow-sm: 3px 3px 0 var(--ink);
  --font-sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --maxw: 1100px;
  --focus: var(--purple);
}

html[data-theme="dark"] {
  --bg: #131313;
  --surface: #1e1e1e;
  --ink: #f2efe9;
  --muted: #b3ad9f;
  --lime: #c6ff00;
  --purple: #a78bfa;
  --pink: #ff6fb0;
  --lime-soft: #262f00;
  --purple-soft: #2a2144;
  --pink-soft: #3c1124;
  --error: #ff7a7a;
  --error-soft: #3c1115;
  --shadow: 6px 6px 0 #000;
  --shadow-sm: 3px 3px 0 #000;
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--ink);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img,
svg {
  max-width: 100%;
  vertical-align: middle;
}

::selection {
  background: var(--lime);
  color: var(--ink);
}

h1, h2, h3, h4 {
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: -0.02em;
  line-height: 1.08;
  margin: 0 0 0.75rem;
}

h1 { font-size: clamp(2rem, 5.5vw, 3.4rem); }
h2 { font-size: clamp(1.35rem, 3vw, 1.9rem); }
h3 { font-size: 1.15rem; }
h4 { font-size: 1rem; }

p {
  margin: 0 0 1rem;
}

a {
  color: var(--ink);
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
  border-radius: 2px;
}

:focus:not(:focus-visible) {
  outline: none;
}

/* ---------- Utilities ---------- */
.container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: 1.25rem;
}

.section {
  padding: 2.75rem 0;
}

.section-tag {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 0.5rem;
}

.section-title {
  margin-bottom: 1.5rem;
}

.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;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 200;
  background: var(--lime);
  color: var(--ink);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 0.7rem 1.2rem;
  text-decoration: none;
  border: var(--border);
  border-top: none;
}

.skip-link:focus {
  left: 0;
}

.dots {
  background-image: radial-gradient(var(--ink) 1.2px, transparent 1.2px);
  background-size: 24px 24px;
  background-position: center;
}

.hl {
  background: var(--lime);
  color: var(--ink);
  padding: 0 0.12em;
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
}

.hl-pink {
  background: var(--pink);
  color: #fff;
  padding: 0 0.12em;
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
}

.hl-purple {
  background: var(--purple);
  color: #fff;
  padding: 0 0.12em;
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
}

/* ---------- Header / Nav ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: var(--bg);
  border-bottom: var(--border);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding-block: 0.65rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  text-decoration: none;
  color: var(--ink);
  margin-right: auto;
  min-width: 0;
}

.brand-mark {
  flex: none;
  display: block;
  border: 2px solid var(--ink);
  box-shadow: 2px 2px 0 var(--ink);
}

.brand-mark svg {
  display: block;
}

.brand-name {
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: -0.02em;
  font-size: 0.95rem;
  line-height: 1.1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.brand-name em {
  font-style: normal;
  color: var(--purple);
}

.brand-name strong {
  color: var(--pink);
  display: block;
}

.site-nav {
  position: relative;
}

.nav-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--surface);
  border: var(--border);
  box-shadow: var(--shadow-sm);
  padding: 0.45rem 0.6rem;
  cursor: pointer;
  color: var(--ink);
}

.nav-menu {
  display: none;
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-nav.is-open .nav-menu {
  display: flex;
  flex-direction: column;
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 230px;
  background: var(--surface);
  border: var(--border);
  box-shadow: var(--shadow);
  padding: 0.5rem;
  gap: 0.15rem;
  z-index: 70;
}

.nav-menu a {
  display: block;
  padding: 0.55rem 0.75rem;
  font-weight: 800;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  text-decoration: none;
  color: var(--ink);
}

.nav-menu a:hover {
  background: var(--lime);
}

.nav-menu a.is-active {
  background: var(--ink);
  color: var(--bg);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex: none;
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  background: var(--surface);
  border: var(--border);
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  color: var(--ink);
  padding: 0;
}

.theme-toggle:hover {
  background: var(--lime);
}

.icon-moon { display: none; }
html[data-theme="dark"] .icon-sun { display: none; }
html[data-theme="dark"] .icon-moon { display: block; }

.header-cta {
  display: none;
}

@media (min-width: 900px) {
  .nav-toggle { display: none; }
  .nav-menu {
    display: flex;
    gap: 0.15rem;
    align-items: center;
  }
  .site-nav.is-open .nav-menu {
    position: static;
    flex-direction: row;
    min-width: 0;
    background: none;
    border: none;
    box-shadow: none;
    padding: 0;
  }
  .header-cta { display: inline-flex; }
  .brand-name { font-size: 1.05rem; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: inherit;
  font-weight: 900;
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  text-decoration: none;
  color: var(--ink);
  background: var(--surface);
  border: var(--border);
  box-shadow: var(--shadow);
  padding: 0.8rem 1.4rem;
  cursor: pointer;
  transition: transform 0.12s ease, box-shadow 0.12s ease, background 0.12s ease;
  -webkit-tap-highlight-color: transparent;
}

.btn:hover {
  transform: translate(2px, 2px);
  box-shadow: var(--shadow-sm);
}

.btn:active {
  transform: translate(5px, 5px);
  box-shadow: 0 0 0 var(--ink);
}

.btn-primary {
  background: var(--purple);
  color: #fff;
}

.btn-pink {
  background: var(--pink);
  color: #fff;
}

.btn-accent {
  background: var(--lime);
  color: var(--ink);
}

.btn-ghost {
  background: var(--surface);
}

.btn-sm {
  padding: 0.45rem 0.9rem;
  font-size: 0.78rem;
}

.btn-lg {
  padding: 1rem 1.8rem;
  font-size: 1.05rem;
}

.btn[disabled] {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
  box-shadow: var(--shadow);
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
}

/* ---------- Chips / tags ---------- */
.chip {
  display: inline-block;
  border: 2px solid #141414;
  padding: 0.15rem 0.55rem;
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #141414;
}

.chip-lime { background: var(--lime); }
.chip-pink { background: var(--pink); color: #fff; }
.chip-purple { background: var(--purple); color: #fff; }

.tag {
  display: inline-block;
  border: 2px solid var(--ink);
  padding: 0.08rem 0.5rem;
  font-size: 0.7rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink);
}

.tag-lime { background: var(--lime); }
.tag-purple { background: var(--purple); color: #fff; }
.tag-pink { background: var(--pink); color: #fff; }

/* ---------- Hero ---------- */
.hero {
  padding: 3rem 0 2.5rem;
  position: relative;
  overflow: hidden;
}

.hero-inner {
  display: grid;
  gap: 2.25rem;
  align-items: center;
}

.hero-title {
  font-size: clamp(2.3rem, 6.5vw, 4.3rem);
  margin-bottom: 1.1rem;
}

.hero-sub {
  font-size: clamp(1rem, 2vw, 1.2rem);
  font-weight: 500;
  color: var(--muted);
  max-width: 56ch;
}

.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-bottom: 1.2rem;
}

.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  margin-top: 1.4rem;
}

.hero-visual {
  position: relative;
  display: flex;
  justify-content: center;
}

@media (min-width: 900px) {
  .hero-inner {
    grid-template-columns: 1.15fr 0.85fr;
  }
}

.page-hero {
  padding: 2.75rem 0 1.75rem;
}

/* ---------- Grid / cards ---------- */
.grid {
  display: grid;
  gap: 1.4rem;
}

.grid-2,
.grid-3 {
  grid-template-columns: 1fr;
}

@media (min-width: 640px) {
  .grid-2 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 900px) {
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
}

.card {
  background: var(--surface);
  border: var(--border);
  box-shadow: var(--shadow);
  padding: 1.5rem;
}

.feature-card {
  position: relative;
  background: var(--surface);
  border: var(--border);
  box-shadow: var(--shadow);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  transition: transform 0.12s ease, box-shadow 0.12s ease;
}

.feature-card:hover {
  transform: translate(-2px, -2px);
  box-shadow: 8px 8px 0 var(--ink);
}

.feature-icon {
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: var(--border);
  box-shadow: var(--shadow-sm);
  background: var(--lime);
  margin-bottom: 0.25rem;
}

.feature-icon--purple { background: var(--purple); }
.feature-icon--pink { background: var(--pink); }

.feature-title {
  font-size: 1.05rem;
  margin: 0;
}

.card-title {
  font-size: 1.05rem;
  margin: 0 0 0.5rem;
}

.feature-desc {
  color: var(--muted);
  font-size: 0.95rem;
  flex: 1;
}

.feature-link {
  font-weight: 900;
  text-transform: uppercase;
  font-size: 0.82rem;
  letter-spacing: 0.04em;
  text-decoration: none;
  color: var(--ink);
}

.feature-link:hover {
  text-decoration: underline;
  text-decoration-thickness: 3px;
  text-underline-offset: 3px;
}

/* ---------- Stat bar ---------- */
.stat-bar {
  background: var(--lime);
  border: var(--border);
  box-shadow: var(--shadow);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
}

.stat {
  padding: 1.15rem 0.9rem;
  text-align: center;
  border-right: var(--border);
}

.stat:last-child {
  border-right: none;
}

.stat-value {
  display: block;
  font-size: 1.75rem;
  font-weight: 900;
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.stat-label {
  display: block;
  font-size: 0.7rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ink);
  opacity: 0.75;
  margin-top: 0.15rem;
}

/* ---------- Forms ---------- */
.field {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.label {
  font-weight: 800;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--ink);
}

.input,
.select,
.textarea {
  width: 100%;
  font-family: inherit;
  font-size: 1rem;
  color: var(--ink);
  background: var(--surface);
  border: var(--border);
  padding: 0.7rem 0.9rem;
  box-shadow: var(--shadow-sm);
}

.input:focus,
.select:focus,
.textarea:focus {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
  box-shadow: var(--shadow);
}

.input::placeholder {
  color: var(--muted);
}

.textarea {
  min-height: 120px;
  resize: vertical;
}

.checkbox {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-weight: 700;
  cursor: pointer;
  font-size: 0.95rem;
}

.checkbox input {
  width: 1.2rem;
  height: 1.2rem;
  accent-color: var(--purple);
  cursor: pointer;
}

.form-grid {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: 1fr;
}

@media (min-width: 640px) {
  .form-grid--2 {
    grid-template-columns: repeat(2, 1fr);
  }
}

.error {
  color: var(--error);
  font-weight: 800;
  font-size: 0.9rem;
  margin: 0;
}

[aria-invalid="true"] {
  border-color: var(--error);
  box-shadow: 4px 4px 0 var(--error);
}

/* ---------- Mode tabs (sleep calculator) ---------- */
.mode-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.mode-tab {
  position: relative;
}

.mode-tab input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.mode-tab span {
  display: inline-block;
  border: var(--border);
  box-shadow: var(--shadow);
  background: var(--surface);
  padding: 0.75rem 1.1rem;
  font-weight: 900;
  font-size: 0.88rem;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: transform 0.12s ease, box-shadow 0.12s ease;
}

.mode-tab span:hover {
  transform: translate(2px, 2px);
  box-shadow: var(--shadow-sm);
}

.mode-tab input:checked + span {
  background: var(--lime);
  color: var(--ink);
}

.mode-tab input:focus-visible + span {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

/* ---------- Results ---------- */
.result-card {
  background: var(--surface);
  border: var(--border);
  box-shadow: var(--shadow);
  padding: 1.5rem;
}

.result-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}

@media (min-width: 640px) {
  .result-grid {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  }
}

.result-card .stat {
  border: var(--border);
  border-left: 8px solid var(--lime);
  background: var(--bg);
  padding: 0.9rem;
  text-align: left;
}

.result-card .stat-value {
  font-size: clamp(1.4rem, 4vw, 2.1rem);
}

.detail-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  border-top: 2px solid var(--ink);
  padding: 0.65rem 0;
}

.detail-row:first-child {
  border-top: none;
}

.detail-label {
  font-weight: 700;
  text-transform: uppercase;
  font-size: 0.82rem;
  letter-spacing: 0.04em;
}

.detail-value {
  font-weight: 900;
  text-align: right;
  font-size: 1.05rem;
}

/* Sleep recommendations */
.rec {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  border: var(--border);
  box-shadow: var(--shadow);
  background: var(--surface);
  padding: 1rem 1.2rem;
  margin-bottom: 0.9rem;
}

.rec--best {
  background: var(--lime);
  color: var(--ink);
}

.rec-time {
  font-size: clamp(1.3rem, 4vw, 1.8rem);
  font-weight: 900;
  letter-spacing: -0.01em;
}

.rec-meta {
  font-weight: 800;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.rec-badge {
  display: inline-block;
  border: 2px solid #141414;
  background: #fff;
  color: #141414;
  font-size: 0.68rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 0.12rem 0.5rem;
}

.rec--best .rec-badge {
  background: var(--purple);
  color: #fff;
}

.time-big {
  font-size: clamp(2.2rem, 7vw, 3.2rem);
  font-weight: 900;
  line-height: 1;
  letter-spacing: -0.02em;
}

.time-sub {
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: 0.8rem;
  color: var(--muted);
}

/* ---------- Notices ---------- */
.notice {
  border: var(--border);
  border-left-width: 10px;
  border-left-color: var(--ink);
  background: var(--surface);
  box-shadow: var(--shadow);
  padding: 1rem 1.25rem;
  margin: 1.25rem 0;
}

.notice-title {
  font-weight: 900;
  text-transform: uppercase;
  font-size: 0.95rem;
  letter-spacing: 0.04em;
  margin-bottom: 0.35rem;
}

.notice p:last-child {
  margin-bottom: 0;
}

.notice-warn {
  background: var(--pink-soft);
  border-left-color: var(--pink);
}

.notice-info {
  background: var(--purple-soft);
  border-left-color: var(--purple);
}

.notice-lime {
  background: var(--lime-soft);
  border-left-color: var(--lime);
}

.notice-error {
  background: var(--error-soft);
  border-left-color: var(--error);
}

/* ---------- Breadcrumbs ---------- */
.breadcrumbs {
  margin: 1.1rem auto;
  font-size: 0.85rem;
}

.breadcrumbs ol {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
  list-style: none;
  padding: 0;
  margin: 0;
}

.breadcrumbs li + li::before {
  content: "/";
  margin-right: 0.4rem;
  font-weight: 900;
  color: var(--muted);
}

.breadcrumbs a {
  color: var(--ink);
  font-weight: 700;
  text-decoration: none;
}

.breadcrumbs a:hover {
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 2px;
}

.breadcrumbs [aria-current="page"] {
  color: var(--muted);
  font-weight: 800;
  text-transform: uppercase;
  font-size: 0.78rem;
  letter-spacing: 0.06em;
}

/* ---------- Ad placeholders (AdSense-ready, no external code) ---------- */
.ad-slot {
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 1.75rem auto;
  border: 3px dashed var(--ink);
  background:
    repeating-linear-gradient(45deg, var(--surface) 0 12px, var(--bg) 12px 24px);
  color: var(--muted);
}

.ad-slot--leaderboard {
  min-height: 100px;
  max-width: 970px;
}

.ad-slot--rectangle {
  min-height: 250px;
  max-width: 336px;
}

.ad-slot--mobile {
  min-height: 100px;
  max-width: 320px;
}

.ad-slot-label {
  font-size: 0.68rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  text-align: center;
}

/* ---------- Typographic content ---------- */
.prose {
  max-width: 72ch;
}

.prose h2 {
  margin-top: 2.6rem;
  font-size: clamp(1.3rem, 2.6vw, 1.7rem);
}

.prose h3 {
  margin-top: 1.8rem;
}

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

.prose li {
  margin: 0.4rem 0;
}

.prose a {
  color: var(--purple);
  font-weight: 700;
  text-decoration-thickness: 3px;
  text-underline-offset: 3px;
}

html[data-theme="dark"] .prose a {
  color: var(--purple);
}

.prose blockquote {
  border-left: 8px solid var(--lime);
  margin: 1.25rem 0;
  padding: 0.6rem 1.2rem;
  font-weight: 700;
  background: var(--surface);
  border: var(--border);
  border-left-width: 8px;
}

/* ---------- Tables ---------- */
.table-wrap {
  overflow-x: auto;
  border: var(--border);
  box-shadow: var(--shadow);
  background: var(--surface);
  margin: 1.25rem 0;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}

.data-table th {
  background: var(--ink);
  color: var(--bg);
  text-align: left;
  text-transform: uppercase;
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  padding: 0.7rem 0.9rem;
}

.data-table td {
  padding: 0.7rem 0.9rem;
  border-top: 2px solid var(--ink);
  vertical-align: top;
}

.data-table tbody tr:nth-child(even) td {
  background: var(--bg);
}

/* ---------- FAQ ---------- */
.faq-item {
  border: var(--border);
  box-shadow: var(--shadow);
  background: var(--surface);
  margin-bottom: 1.1rem;
}

.faq-q {
  list-style: none;
  cursor: pointer;
  padding: 1rem 1.2rem;
  font-weight: 800;
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.faq-q::-webkit-details-marker {
  display: none;
}

.faq-q::after {
  content: "+";
  flex: none;
  font-size: 1.5rem;
  font-weight: 900;
  line-height: 1;
}

.faq-item[open] .faq-q::after {
  content: "\2013";
}

.faq-item[open] .faq-q {
  border-bottom: 2px solid var(--ink);
}

.faq-a {
  padding: 0.9rem 1.2rem 1.2rem;
}

/* ---------- Post meta / blog ---------- */
.post-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.82rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  margin: 0 0 1rem;
}

.post-list-item {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.post-title {
  font-size: 1.05rem;
  margin: 0;
}

.post-title a {
  text-decoration: none;
}

.post-title a:hover {
  text-decoration: underline;
  text-decoration-thickness: 3px;
  text-underline-offset: 3px;
}

.post-excerpt {
  color: var(--muted);
  font-size: 0.92rem;
}

/* ---------- Misc components ---------- */
.kbd {
  display: inline-block;
  border: 2px solid var(--ink);
  border-bottom-width: 4px;
  padding: 0.08rem 0.5rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-weight: 700;
  font-size: 0.85em;
  background: var(--surface);
  box-shadow: 2px 2px 0 var(--ink);
}

.toast {
  position: fixed;
  bottom: 1.25rem;
  left: 50%;
  transform: translateX(-50%) translateY(10px);
  z-index: 120;
  background: var(--ink);
  color: var(--bg);
  font-weight: 800;
  font-size: 0.9rem;
  border: 2px solid var(--ink);
  box-shadow: var(--shadow);
  padding: 0.7rem 1.3rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s ease, transform 0.18s ease;
  max-width: calc(100vw - 2rem);
  text-align: center;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.hero-card-sticker {
  position: absolute;
  border: var(--border);
  box-shadow: var(--shadow);
  font-weight: 900;
  text-transform: uppercase;
  font-size: 0.75rem;
  letter-spacing: 0.05em;
  padding: 0.4rem 0.7rem;
  background: var(--lime);
  color: var(--ink);
}

.hero-card-sticker--pink {
  background: var(--pink);
  color: #fff;
}

.hero-card-sticker--purple {
  background: var(--purple);
  color: #fff;
}

.centered {
  text-align: center;
}

.mt-1 { margin-top: 1rem; }
.mt-2 { margin-top: 2rem; }
.mb-0 { margin-bottom: 0; }

/* ---------- Footer ---------- */
.site-footer {
  margin-top: 3.5rem;
  background: var(--ink);
  color: var(--bg);
  border-top: var(--border);
}

.footer-grid {
  display: grid;
  gap: 2rem;
  padding: 2.75rem 0 2rem;
  grid-template-columns: 1fr;
}

.footer-col ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.footer-col li {
  margin: 0.4rem 0;
}

.footer-col a {
  color: var(--bg);
  text-decoration: none;
  font-weight: 600;
}

.footer-col a:hover {
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

.footer-title {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--bg);
  opacity: 0.65;
  margin-bottom: 0.9rem;
}

.footer-brand p {
  opacity: 0.85;
  max-width: 34ch;
}

.footer-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1rem;
}

.footer-socials {
  display: flex;
  gap: 0.6rem;
  margin-top: 1rem;
}

.footer-social {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border: 2px solid var(--bg);
  color: var(--bg);
}

.footer-social:hover {
  background: var(--lime);
  border-color: #141414;
  color: #141414;
  text-decoration: none;
}

.footer-bottom p a {
  color: var(--bg);
  font-weight: 800;
}

.footer-bottom {
  border-top: 3px solid var(--bg);
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem 1.5rem;
  justify-content: space-between;
  align-items: center;
  padding: 1.1rem 0;
  font-size: 0.85rem;
}

.footer-bottom p {
  margin: 0;
}

.footer-bottom-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1.1rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.footer-bottom-links a {
  color: var(--bg);
  font-weight: 800;
  text-transform: uppercase;
  font-size: 0.78rem;
  letter-spacing: 0.05em;
  text-decoration: none;
}

.footer-bottom-links a:hover {
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

@media (min-width: 640px) {
  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 900px) {
  .footer-grid {
    grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
  }
}

/* ---------- Print ---------- */
@media print {
  .site-header,
  .site-footer,
  .ad-slot,
  .breadcrumbs,
  .nav-toggle,
  .theme-toggle,
  .header-cta,
  .btn-row,
  .skip-link {
    display: none !important;
  }

  body {
    background: #fff;
    color: #000;
    font-size: 12pt;
  }

  .card,
  .result-card,
  .rec,
  .feature-card,
  .notice,
  .faq-item {
    border: 2px solid #000;
    box-shadow: none;
    background: #fff;
    break-inside: avoid;
  }

  .hero,
  .page-hero,
  .section {
    padding: 0.5rem 0;
  }

  .stat-bar,
  .stat {
    border-color: #000;
    background: #fff;
  }

  a {
    color: #000;
    text-decoration: underline;
  }

  a[href^="http"]::after {
    content: " (" attr(href) ")";
    font-size: 0.8em;
  }

  .container {
    max-width: 100%;
    padding-inline: 0;
  }

  .result-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ---------- Small screens ---------- */
@media (max-width: 479px) {
  .brand-name {
    font-size: 0.8rem;
  }

  .btn-row .btn {
    flex: 1 1 auto;
  }

  .hero-ctas .btn {
    width: 100%;
  }
}

/* ---------- Tablet polish (768px+) ---------- */
@media (min-width: 768px) {
  .hero {
    padding: 3.5rem 0 3rem;
  }

  .page-hero {
    padding: 3rem 0 2rem;
  }

  .stat-value {
    font-size: 2rem;
  }
}
