/* =========================================================================
   Alien Roommate — shared stylesheet
   Fonts: Fredoka (display/headlines), Nunito (body)
   Palette + spacing rules per DESIGN_SPEC.md
   ========================================================================= */

@import url('../fonts/fonts.css');

:root {
  /* Brand palette (light / default) */
  --ar-mint: #8FC9A9;
  --ar-orange: #E8813A;
  --ar-orange-dark: #CE6B27;
  --ar-navy: #1C2340;
  --ar-lavender: #B7A8D9;
  --ar-cream: #F7F1E4;
  --ar-peach: #F0B39A;
  --ar-sky: #8FC4E0;
  --ar-teal: #3E7C74;

  /* Tints (pale washes of the character colors, for tinted cards) */
  --ar-mint-tint: #E6F3EC;
  --ar-lavender-tint: #ECE7F5;
  --ar-peach-tint: #FBEAE2;
  --ar-sky-tint: #E6F2F9;

  /* Semantic tokens */
  --bg: var(--ar-cream);
  --bg-panel: #FFFFFF;
  --text: var(--ar-navy);
  --text-muted: #4C5372;
  --border-soft: rgba(28, 35, 64, 0.08);
  --shadow-soft: 0 10px 24px rgba(28, 35, 64, 0.10);
  --shadow-lift: 0 16px 32px rgba(28, 35, 64, 0.16);
  --focus-ring: #1C2340;

  --radius-lg: 28px;
  --radius-md: 20px;
  --radius-sm: 14px;
  --radius-pill: 999px;

  --container-w: 1160px;

  --font-display: 'Fredoka', ui-rounded, 'Segoe UI', system-ui, sans-serif;
  --font-body: 'Nunito', ui-rounded, 'Segoe UI', system-ui, sans-serif;
}

/* Dark mode: same hue family, deep navy ground instead of cream (per DESIGN_SPEC) */
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #12162A;
    --bg-panel: #1A2038;
    --text: #F7F1E4;
    --text-muted: #C9CDE0;
    --border-soft: rgba(247, 241, 228, 0.10);
    --shadow-soft: 0 10px 24px rgba(0, 0, 0, 0.35);
    --shadow-lift: 0 16px 36px rgba(0, 0, 0, 0.45);
    --focus-ring: #F7F1E4;

    --ar-mint-tint: #223a30;
    --ar-lavender-tint: #2c2748;
    --ar-peach-tint: #3a2a26;
    --ar-sky-tint: #1f3140;
  }
}

/* =========================================================================
   Reset
   ========================================================================= */

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

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

a { color: inherit; text-decoration: none; }

ul, ol { padding: 0; margin: 0; list-style: none; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  color: var(--text);
  line-height: 1.15;
  margin: 0 0 0.5em;
  font-weight: 600;
}

h1 { font-size: clamp(2.1rem, 4.4vw, 3.4rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.35rem); }
h3 { font-size: 1.35rem; }

p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }

button { font-family: inherit; }

/* Visible focus states everywhere */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible,
summary:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid var(--focus-ring);
  outline-offset: 3px;
  border-radius: 6px;
}

.visually-hidden {
  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: 1rem;
  top: -60px;
  background: var(--ar-navy);
  color: var(--ar-cream);
  padding: 0.75rem 1.25rem;
  border-radius: var(--radius-sm);
  z-index: 200;
  transition: top .15s ease;
}
.skip-link:focus {
  top: 1rem;
}

/* =========================================================================
   Layout helpers
   ========================================================================= */

.container {
  max-width: var(--container-w);
  margin-inline: auto;
  padding-inline: 1.5rem;
}

main { display: block; }

section { padding-block: clamp(3rem, 6vw, 5.5rem); }
section.tight { padding-block: clamp(2rem, 4vw, 3rem); }

.section-head {
  text-align: center;
  max-width: 640px;
  margin: 0 auto clamp(2rem, 4vw, 3rem);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  font-family: var(--font-display);
  color: var(--ar-teal);
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  margin-bottom: 0.75rem;
}
.eyebrow::before, .eyebrow::after { content: "✦"; opacity: 0.7; font-size: 0.8em; }

.underline {
  position: relative;
  display: inline-block;
}
.underline::after {
  content: "";
  position: absolute;
  left: 2%;
  right: 2%;
  bottom: -0.14em;
  height: 0.28em;
  background: var(--ar-mint);
  border-radius: 999px;
  opacity: 0.7;
  z-index: -1;
}
.underline--orange::after { background: var(--ar-orange); opacity: 0.55; }

.text-center { text-align: center; }
.muted { color: var(--text-muted); }

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

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

/* =========================================================================
   Buttons
   ========================================================================= */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5em;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1rem;
  line-height: 1;
  padding: 0.95em 1.75em;
  border-radius: var(--radius-pill);
  border: none;
  cursor: pointer;
  text-align: center;
  transition: transform .12s ease, box-shadow .12s ease, background-color .12s ease, opacity .12s ease;
}

.btn-primary {
  background: var(--ar-orange);
  color: #fff;
  box-shadow: var(--shadow-soft);
}
.btn-primary:hover { background: var(--ar-orange-dark); transform: translateY(-1px); box-shadow: var(--shadow-lift); }
.btn-primary:active { background: var(--ar-orange-dark); transform: translateY(0); box-shadow: none; }

.btn-secondary {
  background: transparent;
  color: var(--ar-navy);
  border: 2px solid var(--ar-navy);
}
.btn-secondary:hover { background: var(--ar-navy); color: var(--ar-cream); }

@media (prefers-color-scheme: dark) {
  .btn-secondary { color: var(--ar-cream); border-color: var(--ar-cream); }
  .btn-secondary:hover { background: var(--ar-cream); color: var(--ar-navy); }
}

.btn[disabled],
.btn-disabled {
  background: #D9D3C4;
  color: #8A8574;
  box-shadow: none;
  cursor: not-allowed;
  opacity: 0.75;
  pointer-events: none;
}
@media (prefers-color-scheme: dark) {
  .btn-disabled { background: #2b3150; color: #8b90ac; }
}

.btn-loading {
  color: transparent !important;
  position: relative;
}
.btn-loading::after {
  content: "";
  position: absolute;
  inset: 0;
  margin: auto;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: -10px 0 0 0 #fff, 0 0 0 0 #fff, 10px 0 0 0 #fff;
  animation: btn-dots 1s infinite ease-in-out;
}
@keyframes btn-dots {
  0%, 80%, 100% { opacity: 0.25; }
  40% { opacity: 1; }
}

.btn-block { width: 100%; }

/* "Coming soon" store badge (visually a button, honestly inert) */
.store-badge {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.9rem 1.25rem;
  border-radius: var(--radius-md);
  background: var(--bg-panel);
  border: 2px dashed var(--border-soft);
  color: var(--text-muted);
  cursor: not-allowed;
  box-shadow: none;
}
.store-badge__icon {
  width: 34px; height: 34px;
  flex-shrink: 0;
  color: var(--text-muted);
}
.store-badge__text { text-align: left; }
.store-badge__text strong {
  display: block;
  font-family: var(--font-display);
  color: var(--text);
  font-size: 1rem;
}
.store-badge__text span { font-size: 0.85rem; }

/* =========================================================================
   Header / Navigation
   ========================================================================= */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg);
  border-bottom: 1px solid var(--border-soft);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-block: 0.85rem;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--ar-navy);
  letter-spacing: 0.01em;
}
@media (prefers-color-scheme: dark) { .logo { color: var(--ar-cream); } }
.logo img {
  width: 42px; height: 42px;
  border-radius: 12px;
  box-shadow: var(--shadow-soft);
}
.logo-word { line-height: 1.05; }
.logo-word small { display: block; font-family: var(--font-body); font-weight: 700; font-size: 0.6rem; letter-spacing: 0.14em; color: var(--ar-teal); }

.nav-toggle {
  display: none;
  width: 44px; height: 44px;
  border-radius: var(--radius-sm);
  border: 2px solid var(--border-soft);
  background: var(--bg-panel);
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  width: 20px; height: 2px;
  background: var(--text);
  border-radius: 2px;
  position: relative;
  transition: transform .2s ease, opacity .2s ease;
}
.nav-toggle span::before, .nav-toggle span::after {
  content: "";
  position: absolute; left: 0;
  width: 20px; height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform .2s ease, top .2s ease;
}
.nav-toggle span::before { top: -6px; }
.nav-toggle span::after { top: 6px; }
.nav-toggle[aria-expanded="true"] span { background: transparent; }
.nav-toggle[aria-expanded="true"] span::before { top: 0; transform: rotate(45deg); }
.nav-toggle[aria-expanded="true"] span::after { top: 0; transform: rotate(-45deg); }

.primary-nav {
  display: flex;
  align-items: center;
  gap: 1.75rem;
}
.primary-nav ul {
  display: flex;
  align-items: center;
  gap: 1.75rem;
}
.primary-nav a:not(.btn) {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 0.98rem;
  color: var(--text);
  padding: 0.35rem 0.1rem;
  border-bottom: 2px solid transparent;
}
.primary-nav a:not(.btn):hover { color: var(--ar-teal); }
.primary-nav a:not(.btn)[aria-current="page"] {
  color: var(--ar-orange);
  border-bottom-color: var(--ar-orange);
}
.primary-nav a.btn[aria-current="page"] {
  box-shadow: 0 0 0 3px var(--ar-navy), var(--shadow-soft);
}
@media (prefers-color-scheme: dark) {
  .primary-nav a.btn[aria-current="page"] { box-shadow: 0 0 0 3px var(--ar-cream), var(--shadow-soft); }
}

@media (max-width: 860px) {
  .nav-toggle { display: inline-flex; }
  .primary-nav {
    position: fixed;
    inset: 68px 0.9rem auto 0.9rem;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--bg-panel);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lift);
    padding: 0.5rem;
    transform: translateY(-12px);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity .18s ease, transform .18s ease, visibility .18s;
  }
  .primary-nav.is-open {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }
  .primary-nav ul {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
  }
  .primary-nav ul li a { display: block; padding: 0.9rem 0.75rem; border-bottom: 1px solid var(--border-soft); }
  .primary-nav ul li:last-child a { border-bottom: none; }
  .nav-cta { margin: 0.6rem 0.25rem 0.25rem; }
}

/* =========================================================================
   Hero
   ========================================================================= */

.hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(180deg, #FBE7D0 0%, #F7C9A8 32%, #E9A98B 55%, #D98B72 72%, var(--ar-cream) 100%);
  border-bottom: 1px solid var(--border-soft);
}
@media (prefers-color-scheme: dark) {
  .hero { background: linear-gradient(180deg, #23264a 0%, #33305a 40%, #4a3654 68%, var(--bg) 100%); }
}

.hero::before {
  /* soft "hill" silhouette */
  content: "";
  position: absolute;
  left: -10%; right: -10%; bottom: -4%;
  height: 38%;
  background: var(--ar-cream);
  border-radius: 50% 50% 0 0 / 100% 100% 0 0;
  opacity: 0.9;
}
@media (prefers-color-scheme: dark) {
  .hero::before { background: var(--bg); opacity: 0.95; }
}

.hero-inner {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  align-items: end;
  gap: 2rem;
  padding-block: clamp(2.5rem, 6vw, 4.5rem) 0;
  min-height: clamp(420px, 62vw, 620px);
}

.hero-copy {
  padding-bottom: clamp(2rem, 6vw, 4rem);
  position: relative;
  z-index: 3;
}

.hero-tagline {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.05rem, 1.6vw, 1.3rem);
  color: var(--ar-navy);
  background: rgba(255,255,255,0.6);
  padding: 0.4em 0.9em;
  border-radius: var(--radius-pill);
  margin-bottom: 1.1rem;
}
@media (prefers-color-scheme: dark) {
  .hero-tagline { background: rgba(0,0,0,0.25); color: var(--ar-cream); }
}

.hero h1 { color: var(--ar-navy); text-shadow: 0 2px 0 rgba(255,255,255,0.35); }
@media (prefers-color-scheme: dark) { .hero h1 { color: var(--ar-cream); text-shadow: none; } }

.hero p.lede {
  font-size: 1.15rem;
  max-width: 34ch;
  color: var(--ar-navy);
}
@media (prefers-color-scheme: dark) { .hero p.lede { color: var(--ar-cream); opacity: 0.9; } }

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  margin-top: 1.5rem;
  align-items: center;
}

.hero-note {
  display: flex;
  align-items: center;
  gap: 0.5em;
  margin-top: 1rem;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.hero-cast {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: clamp(-18px, -1vw, -6px);
  height: 100%;
  padding-bottom: 0;
}
.hero-cast img { filter: drop-shadow(0 18px 20px rgba(28,35,64,0.25)); width: auto; }
/* Sized by height (not width) since each cutout has a different natural aspect ratio —
   this keeps relative character scale under our control per DESIGN_SPEC (Zee largest/
   forward, Glom shortest/roundest, Lumi tallest/slimmest, Orby tall/thin). */
.hero-cast .c-zee { height: clamp(200px, 27vw, 360px); z-index: 4; }
.hero-cast .c-glom { height: clamp(120px, 16vw, 205px); z-index: 3; margin-bottom: 2%; }
.hero-cast .c-lumi { height: clamp(180px, 24vw, 320px); z-index: 2; margin-bottom: 4%; }
.hero-cast .c-orby { height: clamp(190px, 25vw, 340px); z-index: 1; margin-bottom: 0; }

.hero-lights {
  position: absolute;
  top: 6%;
  left: 0; right: 0;
  height: 3px;
  z-index: 2;
  background-image: radial-gradient(circle, #FFE9B0 0 3px, transparent 4px);
  background-size: 46px 3px;
  opacity: 0.85;
}

@media (max-width: 860px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-cast { order: -1; padding-top: 1.5rem; }
  .hero-copy { text-align: left; }
}

/* Smaller page hero (interior pages) */
.hero-sm {
  background: linear-gradient(180deg, #FBE7D0 0%, var(--ar-cream) 100%);
  border-bottom: 1px solid var(--border-soft);
  text-align: center;
}
@media (prefers-color-scheme: dark) {
  .hero-sm { background: linear-gradient(180deg, #23264a 0%, var(--bg) 100%); }
}
.hero-sm .container { padding-block: clamp(2.5rem, 6vw, 4rem); }
.hero-sm p.lede { max-width: 52ch; margin-inline: auto; font-size: 1.1rem; }

/* =========================================================================
   Cards
   ========================================================================= */

.card {
  background: var(--bg-panel);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
  padding: 1.75rem;
}

.card--tint-mint { background: var(--ar-mint-tint); }
.card--tint-lavender { background: var(--ar-lavender-tint); }
.card--tint-peach { background: var(--ar-peach-tint); }
.card--tint-sky { background: var(--ar-sky-tint); }

.cast-card {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.65rem;
}
.cast-card img {
  height: 128px;
  width: auto;
  margin-bottom: 0.25rem;
}
.cast-card h3 { margin-bottom: 0.1rem; }
.cast-card .role { font-family: var(--font-display); font-size: 0.85rem; color: var(--ar-teal); letter-spacing: 0.03em; }
.cast-card a.card-link {
  margin-top: 0.4rem;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.92rem;
  color: var(--ar-navy);
  text-decoration: underline;
  text-underline-offset: 3px;
}
@media (prefers-color-scheme: dark) { .cast-card a.card-link { color: var(--ar-cream); } }

.feature-card {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}
.feature-card .icon-wrap {
  width: 64px; height: 64px;
  display: flex; align-items: center; justify-content: center;
  border-radius: var(--radius-md);
  background: rgba(255,255,255,0.6);
  margin-bottom: 0.4rem;
}
.feature-card .icon-wrap img { width: 40px; height: 40px; object-fit: contain; }
.feature-card .status-chip {
  display: inline-block;
  font-family: var(--font-display);
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.25em 0.75em;
  border-radius: var(--radius-pill);
  width: fit-content;
  letter-spacing: 0.03em;
}
.status-chip--live { background: rgba(143,201,169,0.35); color: #1f5a3c; }
.status-chip--dev { background: rgba(232,129,58,0.18); color: var(--ar-orange-dark); }
@media (prefers-color-scheme: dark) {
  .status-chip--live { background: rgba(143,201,169,0.22); color: #a9e2c2; }
  .status-chip--dev { background: rgba(232,129,58,0.22); color: #f3ab77; }
}

/* Icon feature row (one purchase / no ads / no subscription) */
.value-row {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.75rem;
}
.value-row img { height: 110px; width: auto; }
.value-row h3 { margin-bottom: 0.15rem; }

/* =========================================================================
   Crew profile blocks (crew.html)
   ========================================================================= */

.crew-block {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 2rem;
  align-items: center;
  border-radius: var(--radius-lg);
  padding: clamp(1.5rem, 4vw, 2.75rem);
  box-shadow: var(--shadow-soft);
  margin-bottom: 2rem;
}
.crew-block:nth-child(even) { direction: rtl; }
.crew-block:nth-child(even) > * { direction: ltr; }

.crew-portrait {
  display: flex;
  align-items: center;
  justify-content: center;
}
.crew-portrait img { height: 220px; width: auto; filter: drop-shadow(0 12px 16px rgba(28,35,64,0.18)); }

.crew-name {
  font-family: var(--font-display);
  font-size: 2rem;
  margin-bottom: 0.15rem;
}
.crew-traits {
  font-family: var(--font-display);
  font-weight: 500;
  color: var(--ar-teal);
  margin-bottom: 0.75rem;
}
.crew-joke {
  margin-top: 1rem;
  padding: 0.9rem 1.1rem;
  background: rgba(255,255,255,0.55);
  border-radius: var(--radius-md);
  font-size: 0.98rem;
}
@media (prefers-color-scheme: dark) { .crew-joke { background: rgba(0,0,0,0.2); } }
.crew-joke strong { font-family: var(--font-display); display: block; margin-bottom: 0.25rem; }

@media (max-width: 720px) {
  .crew-block, .crew-block:nth-child(even) { grid-template-columns: 1fr; direction: ltr; text-align: center; }
  .crew-portrait img { height: 180px; }
}

/* =========================================================================
   Accordion (FAQ) — native <details>/<summary>
   ========================================================================= */

.accordion { display: flex; flex-direction: column; gap: 0.75rem; }

.accordion-item {
  background: var(--bg-panel);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-soft);
  overflow: hidden;
}

.accordion-item summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.15rem 1.35rem;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.02rem;
}
.accordion-item summary::-webkit-details-marker { display: none; }

.accordion-item summary .chev {
  flex-shrink: 0;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: var(--ar-cream);
  display: flex; align-items: center; justify-content: center;
  transition: transform .2s ease;
}
@media (prefers-color-scheme: dark) { .accordion-item summary .chev { background: var(--bg); } }
.accordion-item[open] summary .chev { transform: rotate(180deg); }

.accordion-item .accordion-body {
  padding: 0 1.35rem 1.25rem;
  color: var(--text-muted);
}

.accordion-item[open] summary { color: var(--ar-orange-dark); }

.accordion-item.is-hidden { display: none; }

/* =========================================================================
   Forms
   ========================================================================= */

.field {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-bottom: 1.1rem;
}
.field label {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 0.92rem;
}
.field input,
.field textarea,
.field select {
  font-family: var(--font-body);
  font-size: 1rem;
  padding: 0.85em 1em;
  border-radius: var(--radius-sm);
  border: 2px solid var(--border-soft);
  background: var(--bg-panel);
  color: var(--text);
}
.field textarea { resize: vertical; min-height: 120px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media (max-width: 600px) { .field-row { grid-template-columns: 1fr; } }

.form-note {
  font-size: 0.9rem;
  color: var(--text-muted);
  background: rgba(143,196,224,0.18);
  border-radius: var(--radius-sm);
  padding: 0.85em 1em;
  margin-bottom: 1.25rem;
}
@media (prefers-color-scheme: dark) { .form-note { background: rgba(143,196,224,0.12); } }

.form-status {
  margin-top: 1rem;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--ar-teal);
}
.form-status[hidden] { display: none; }

.search-field {
  position: relative;
  max-width: 560px;
  margin: 0 auto clamp(1.5rem, 3vw, 2.5rem);
}
.search-field input {
  width: 100%;
  padding: 1em 1.25em 1em 2.75em;
  border-radius: var(--radius-pill);
  border: 2px solid var(--border-soft);
  background: var(--bg-panel);
  font-size: 1rem;
  color: var(--text);
}
.search-field svg {
  position: absolute;
  left: 1em; top: 50%;
  transform: translateY(-50%);
  width: 20px; height: 20px;
  color: var(--text-muted);
}

/* =========================================================================
   Support category cards
   ========================================================================= */

.support-cat {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.5rem;
}
.support-cat img { width: 64px; height: 64px; object-fit: contain; }
.support-cat h3 { margin-bottom: 0.15rem; font-size: 1.1rem; }
.support-cat p { font-size: 0.92rem; color: var(--text-muted); }

/* =========================================================================
   Devices list (download.html)
   ========================================================================= */

.device-list {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}
@media (max-width: 760px) { .device-list { grid-template-columns: repeat(2, 1fr); } }
.device-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
  text-align: center;
  padding: 1.25rem 0.75rem;
}
.device-item svg { width: 42px; height: 42px; color: var(--ar-navy); }
@media (prefers-color-scheme: dark) { .device-item svg { color: var(--ar-cream); } }
.device-item strong { font-family: var(--font-display); font-size: 0.95rem; }

/* Purchase includes checklist */
.check-list { display: flex; flex-direction: column; gap: 0.85rem; }
.check-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
}
.check-list .tick {
  flex-shrink: 0;
  width: 26px; height: 26px;
  border-radius: 50%;
  background: var(--ar-mint);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.85rem;
  margin-top: 0.1rem;
}

/* =========================================================================
   Night band (CTA banners)
   ========================================================================= */

.night-band {
  position: relative;
  overflow: hidden;
  background: radial-gradient(120% 140% at 20% 0%, #2b2f57 0%, var(--ar-navy) 55%, #10142a 100%);
  color: var(--ar-cream);
  text-align: center;
}
.night-band .container { position: relative; z-index: 2; padding-block: clamp(2.75rem, 6vw, 4rem); }
.night-band h2 { color: #fff; }
.night-band p { color: rgba(247,241,228,0.85); }
.night-band .stars {
  position: absolute; inset: 0;
  background-image:
    radial-gradient(1.5px 1.5px at 10% 20%, #fff, transparent),
    radial-gradient(1.5px 1.5px at 30% 60%, #fff, transparent),
    radial-gradient(1.5px 1.5px at 50% 15%, #fff, transparent),
    radial-gradient(1.5px 1.5px at 70% 70%, #fff, transparent),
    radial-gradient(1.5px 1.5px at 85% 30%, #fff, transparent),
    radial-gradient(1.5px 1.5px at 95% 55%, #fff, transparent),
    radial-gradient(1.5px 1.5px at 15% 85%, #fff, transparent),
    radial-gradient(1.5px 1.5px at 60% 45%, #fff, transparent);
  opacity: 0.7;
}

/* =========================================================================
   Footer
   ========================================================================= */

.site-footer {
  background: var(--ar-navy);
  color: rgba(247,241,228,0.88);
  padding-block: 2.5rem 1.5rem;
}
.footer-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid rgba(247,241,228,0.14);
}
.footer-logo {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  color: #fff;
}
.footer-brand p { margin-top: 0.4rem; color: rgba(247,241,228,0.65); font-size: 0.92rem; max-width: 32ch; }
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
}
.footer-links a { font-family: var(--font-display); font-size: 0.95rem; }
.footer-links a:hover { color: var(--ar-orange); }
.footer-copy {
  margin: 1.25rem auto 0;
  max-width: var(--container-w);
  padding-inline: 1.5rem;
  font-size: 0.8rem;
  color: rgba(247,241,228,0.55);
}
.footer-copy .placeholder {
  background: rgba(255,255,255,0.16);
  color: #FFD9B8;
  padding: 0.05em 0.4em;
  border-radius: 5px;
  font-weight: 700;
}

/* =========================================================================
   404 page
   ========================================================================= */

.error-page {
  text-align: center;
  padding-block: clamp(3rem, 8vw, 6rem);
}
.error-page img { height: 180px; margin: 0 auto 1.5rem; }
.error-page .code {
  font-family: var(--font-display);
  font-size: 5rem;
  color: var(--ar-orange);
  line-height: 1;
  margin-bottom: 0.5rem;
}

/* =========================================================================
   Series page
   ========================================================================= */

.series-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--ar-teal);
  background: var(--ar-mint-tint);
  padding: 0.5em 1.1em;
  border-radius: var(--radius-pill);
  margin-bottom: 1.25rem;
}

/* =========================================================================
   Legal pages (privacy/terms)
   ========================================================================= */

.legal-content {
  max-width: 760px;
  margin-inline: auto;
}
.legal-content h2 { margin-top: 2.25rem; }
.legal-content h2:first-child { margin-top: 0; }
.legal-content ul { list-style: disc; padding-left: 1.4em; margin-bottom: 1em; }
.legal-content ul li { margin-bottom: 0.4em; }
.legal-content .placeholder {
  background: rgba(232,129,58,0.16);
  color: var(--ar-orange-dark);
  padding: 0.1em 0.4em;
  border-radius: 6px;
  font-weight: 700;
}
.legal-updated {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 2rem;
}

/* =========================================================================
   Misc
   ========================================================================= */

.divider-props {
  display: flex;
  justify-content: center;
  gap: 1.25rem;
  flex-wrap: wrap;
  margin-block: 1rem 0;
  opacity: 0.9;
}
.divider-props img { height: 46px; width: auto; }

.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}
@media (max-width: 800px) {
  .two-col { grid-template-columns: 1fr; }
  .two-col.reverse-mobile { display: flex; flex-direction: column-reverse; }
}
.two-col img { border-radius: var(--radius-lg); }

.screenshot-note {
  display: flex;
  align-items: center;
  gap: 0.6em;
  font-size: 0.88rem;
  color: var(--text-muted);
  background: rgba(28,35,64,0.05);
  border-radius: var(--radius-sm);
  padding: 0.7em 1em;
  margin-top: 0.75rem;
}
@media (prefers-color-scheme: dark) { .screenshot-note { background: rgba(247,241,228,0.06); } }

.concept-frame {
  border-radius: var(--radius-lg);
  background: var(--bg-panel);
  box-shadow: var(--shadow-soft);
  padding: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  min-height: 220px;
}
.concept-frame img { height: 84px; width: auto; }
