:root {
  color-scheme: dark;
  --ink: #080d0c;
  --ink-soft: #101715;
  --panel: #141d1a;
  --panel-2: #1a2521;
  --line: rgba(229, 218, 190, 0.14);
  --bone: #f1ead8;
  --bone-muted: #b8b2a4;
  --gold: #d6aa6d;
  --gold-deep: #8c6537;
  --moss: #6f8b77;
  --ocean: #547f85;
  --sky: #8b839f;
  --rust: #a4674f;
  --danger: #d67d6d;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.38);
  --radius-lg: 28px;
  --radius-md: 20px;
  --radius-sm: 14px;
  --safe-bottom: max(16px, env(safe-area-inset-bottom));
}

* {
  box-sizing: border-box;
}

html {
  background: var(--ink);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  background:
    radial-gradient(circle at 10% -10%, rgba(108, 141, 117, 0.16), transparent 34rem),
    radial-gradient(circle at 90% 22%, rgba(140, 101, 55, 0.11), transparent 30rem),
    var(--ink);
  color: var(--bone);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}

button,
input,
a {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  color: inherit;
}

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

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1,
h2,
h3 {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 500;
  letter-spacing: -0.025em;
}

h1 em,
h2 em,
h3 em {
  font-weight: inherit;
}

a {
  color: inherit;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
dialog:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 3px;
}

.skip-link {
  position: fixed;
  z-index: 999;
  top: 10px;
  left: 10px;
  transform: translateY(-150%);
  border-radius: 10px;
  background: var(--bone);
  color: var(--ink);
  padding: 10px 14px;
  text-decoration: none;
}

.skip-link:focus {
  transform: translateY(0);
}

.visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

.app-shell {
  width: min(100%, 1240px);
  margin: 0 auto;
  min-height: 100vh;
}

.topbar {
  position: sticky;
  z-index: 30;
  top: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px clamp(16px, 4vw, 48px);
  border-bottom: 1px solid transparent;
  background: linear-gradient(to bottom, rgba(8, 13, 12, 0.96), rgba(8, 13, 12, 0.78));
  backdrop-filter: blur(18px);
}

.topbar.is-scrolled {
  border-bottom-color: var(--line);
}

.brand-button {
  display: flex;
  align-items: center;
  gap: 11px;
  border: 0;
  background: transparent;
  padding: 0;
  text-align: left;
  cursor: pointer;
}

.brand-button img {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid rgba(241, 234, 216, 0.22);
  background: white;
}

.brand-copy {
  display: grid;
  gap: 1px;
}

.brand-copy span {
  color: var(--bone-muted);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.brand-copy strong {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1rem;
  font-weight: 500;
}

.icon-button {
  position: relative;
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.035);
  cursor: pointer;
}

.notification-dot {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 7px;
  height: 7px;
  border: 1px solid var(--ink);
  border-radius: 50%;
  background: var(--gold);
}

main {
  padding: 10px clamp(16px, 4vw, 48px) calc(112px + var(--safe-bottom));
}

.view {
  animation: view-in 300ms ease both;
}

@keyframes view-in {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

.hero-grid {
  display: grid;
  gap: 22px;
  padding: 8px 0 32px;
}

.cinematic-card {
  position: relative;
  min-height: 430px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: #111;
  box-shadow: var(--shadow);
}

.cinematic-card video {
  width: 100%;
  height: 100%;
  min-height: 430px;
  object-fit: cover;
}

.cinematic-shade {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(3, 7, 6, 0.15), transparent 48%),
    linear-gradient(0deg, rgba(3, 7, 6, 0.92), transparent 48%);
}

.cinematic-label {
  position: absolute;
  top: 18px;
  left: 18px;
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  background: rgba(8, 13, 12, 0.56);
  padding: 7px 10px;
  color: rgba(255, 255, 255, 0.86);
  font-size: 0.67rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  backdrop-filter: blur(12px);
}

.live-mark {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #d39c78;
  box-shadow: 0 0 0 4px rgba(211, 156, 120, 0.14);
}

.video-play {
  position: absolute;
  top: 50%;
  left: 50%;
  display: grid;
  width: 66px;
  height: 66px;
  transform: translate(-50%, -50%);
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.38);
  border-radius: 50%;
  background: rgba(8, 13, 12, 0.56);
  color: white;
  cursor: pointer;
  backdrop-filter: blur(12px);
  transition: transform 180ms ease, background 180ms ease;
}

.video-play span {
  margin-left: 4px;
}

.video-play:hover {
  transform: translate(-50%, -50%) scale(1.06);
  background: rgba(8, 13, 12, 0.74);
}

.cinematic-card.is-playing .video-play,
.cinematic-card.is-playing .cinematic-caption,
.cinematic-card.is-playing .cinematic-shade {
  opacity: 0;
  pointer-events: none;
}

.cinematic-caption {
  position: absolute;
  right: 20px;
  bottom: 20px;
  left: 20px;
  transition: opacity 180ms ease;
}

.cinematic-caption p {
  margin-bottom: 2px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.55rem, 6vw, 2.4rem);
}

.cinematic-caption span {
  color: rgba(255, 255, 255, 0.68);
  font-size: 0.82rem;
}

.featured-copy {
  min-width: 0;
  align-self: center;
  padding: 8px 2px;
}

.eyebrow {
  margin-bottom: 9px;
  color: var(--gold);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.featured-copy h1,
.page-intro h1 {
  margin-bottom: 14px;
  line-height: 0.95;
}

.page-intro h1 {
  font-size: clamp(2.45rem, 9vw, 5.6rem);
}

.featured-copy h1 {
  max-width: 100%;
  font-size: clamp(2.55rem, 7vw, 3.4rem);
  line-height: 0.98;
}

.lead,
.page-intro > p:last-child {
  max-width: 46rem;
  color: var(--bone-muted);
  font-size: clamp(1rem, 2.5vw, 1.14rem);
  line-height: 1.7;
}

.feature-facts {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  margin: 26px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.feature-facts span {
  display: grid;
  gap: 4px;
  padding: 15px 10px;
  font-size: 0.82rem;
  font-weight: 650;
}

.feature-facts span + span {
  border-left: 1px solid var(--line);
}

.feature-facts small {
  color: var(--bone-muted);
  font-size: 0.62rem;
  font-weight: 750;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.primary-button,
.ghost-button,
.light-button {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 12px 20px;
  font-size: 0.84rem;
  font-weight: 780;
  text-decoration: none;
  cursor: pointer;
  transition: transform 160ms ease, background 160ms ease, border-color 160ms ease;
}

.primary-button {
  border: 1px solid var(--gold);
  background: var(--gold);
  color: #15100a;
}

.primary-button:hover,
.light-button:hover {
  transform: translateY(-2px);
}

.ghost-button {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.025);
  color: var(--bone);
}

.ghost-button:hover {
  border-color: rgba(214, 170, 109, 0.6);
  background: rgba(214, 170, 109, 0.08);
}

.ghost-button:disabled {
  cursor: not-allowed;
  opacity: 0.58;
}

.light-button {
  border: 1px solid var(--bone);
  background: var(--bone);
  color: var(--ink);
}

.wide-button {
  width: 100%;
}

.section-block {
  padding: 34px 0;
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
}

.section-heading h2 {
  margin: 0;
  font-size: clamp(1.8rem, 5.5vw, 2.9rem);
}

.text-button {
  flex: 0 0 auto;
  border: 0;
  background: transparent;
  color: var(--bone-muted);
  padding: 8px 0;
  font-size: 0.78rem;
  font-weight: 720;
  cursor: pointer;
}

.text-button:hover {
  color: var(--gold);
}

.progress-panel {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 18px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background:
    linear-gradient(120deg, rgba(111, 139, 119, 0.09), transparent 45%),
    var(--panel);
  padding: clamp(18px, 4vw, 28px);
}

.progress-ring,
.large-progress-ring {
  --progress: 0deg;
  position: relative;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 50%;
  background: conic-gradient(var(--gold) var(--progress), rgba(255, 255, 255, 0.08) 0);
}

.progress-ring {
  width: 82px;
  height: 82px;
}

.progress-ring::after,
.large-progress-ring::after {
  position: absolute;
  inset: 7px;
  border-radius: inherit;
  background: var(--panel);
  content: "";
}

.progress-ring span,
.large-progress-ring span,
.large-progress-ring small {
  position: relative;
  z-index: 1;
}

.progress-ring span {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.2rem;
}

.progress-copy strong {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.2rem;
  font-weight: 500;
}

.progress-copy p {
  margin: 5px 0 12px;
  color: var(--bone-muted);
  font-size: 0.83rem;
  line-height: 1.5;
}

.milestone-track {
  height: 5px;
  overflow: hidden;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.08);
}

.milestone-track span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--gold-deep), var(--gold));
  transition: width 300ms ease;
}

.progress-copy small {
  display: block;
  margin-top: 8px;
  color: var(--bone-muted);
  font-size: 0.68rem;
}

.realm-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.realm-card {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 13px;
  align-items: center;
  min-height: 82px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--panel);
  padding: 14px;
  text-align: left;
  cursor: pointer;
  transition: transform 160ms ease, border-color 160ms ease;
}

.realm-card:hover {
  transform: translateY(-2px);
  border-color: rgba(241, 234, 216, 0.27);
}

.realm-card > span:nth-child(2) {
  display: grid;
  gap: 3px;
}

.realm-card strong {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1rem;
  font-weight: 500;
}

.realm-card small {
  color: var(--bone-muted);
  font-size: 0.68rem;
}

.realm-icon {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.35rem;
}

.realm-dinosaurs .realm-icon { color: var(--gold); }
.realm-ocean .realm-icon { color: #8fbfc5; }
.realm-sky .realm-icon { color: #bbb2d1; }
.realm-mammals .realm-icon { color: #c58d75; }

.creature-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.creature-card {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--panel);
  cursor: pointer;
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

.creature-card:hover {
  transform: translateY(-3px);
  border-color: rgba(214, 170, 109, 0.35);
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.24);
}

.creature-card button.card-open {
  width: 100%;
  border: 0;
  background: transparent;
  padding: 0;
  text-align: left;
  cursor: pointer;
}

.creature-image-wrap {
  position: relative;
  aspect-ratio: 0.79;
  overflow: hidden;
  background: #d8d7d0;
}

.creature-image-wrap::after {
  position: absolute;
  inset: auto 0 0;
  height: 30%;
  background: linear-gradient(transparent, rgba(7, 11, 10, 0.5));
  content: "";
}

.creature-image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 350ms ease;
}

.creature-card:hover .creature-image-wrap img {
  transform: scale(1.025);
}

.owned-mark {
  position: absolute;
  z-index: 2;
  top: 10px;
  right: 10px;
  display: none;
  min-width: 30px;
  height: 30px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 50%;
  background: rgba(9, 14, 12, 0.74);
  color: var(--gold);
  backdrop-filter: blur(8px);
}

.creature-card.is-owned .owned-mark {
  display: grid;
}

.creature-card-copy {
  padding: 13px 13px 15px;
}

.card-editions,
.dialog-editions {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.card-editions {
  margin-bottom: 9px;
}

.dialog-editions {
  margin: -10px 0 20px;
}

.edition-pill {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  min-height: 28px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 4px 8px;
  font-size: 0.6rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.pioneer-pill {
  border-color: rgba(214, 170, 109, 0.46);
  background: rgba(214, 170, 109, 0.12);
  color: var(--gold);
}

.fossil-pill {
  border-color: rgba(224, 218, 203, 0.24);
  color: var(--bone-muted);
}

.preview-pill {
  border-color: rgba(126, 129, 122, 0.42);
  background: repeating-linear-gradient(135deg, rgba(126, 129, 122, 0.1) 0 5px, transparent 5px 10px);
  color: var(--bone-muted);
}

.creature-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 6px;
  color: var(--bone-muted);
  font-size: 0.6rem;
  font-weight: 750;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.category-dot {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.category-dot::before {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--gold);
  content: "";
}

.category-dot[data-category="Marine reptile"]::before { background: var(--ocean); }
.category-dot[data-category="Pterosaur"]::before { background: var(--sky); }
.category-dot[data-category="Prehistoric mammal"]::before { background: var(--rust); }

.creature-card h3 {
  min-height: 2.35em;
  margin: 0;
  font-size: clamp(1rem, 4vw, 1.28rem);
  line-height: 1.15;
}

.creature-card h3 em {
  font-size: inherit;
}

.subscription-banner {
  display: grid;
  gap: 20px;
  margin: 36px 0 12px;
  overflow: hidden;
  border: 1px solid rgba(214, 170, 109, 0.32);
  border-radius: var(--radius-lg);
  background:
    radial-gradient(circle at 90% 10%, rgba(214, 170, 109, 0.16), transparent 20rem),
    linear-gradient(135deg, #171f1b, #121714);
  padding: clamp(24px, 6vw, 50px);
}

.subscription-banner h2 {
  margin-bottom: 10px;
  font-size: clamp(2rem, 6.5vw, 3.4rem);
}

.subscription-banner p:not(.eyebrow) {
  max-width: 42rem;
  margin-bottom: 0;
  color: var(--bone-muted);
  line-height: 1.65;
}

.subscription-banner .light-button {
  justify-self: start;
}

.page-intro {
  padding: 28px 0 22px;
}

.page-intro h1 {
  margin-bottom: 12px;
}

.search-wrap {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel);
  padding: 0 17px;
}

.search-wrap span {
  color: var(--bone-muted);
  font-size: 1.35rem;
}

.search-wrap input {
  width: 100%;
  height: 54px;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--bone);
}

.search-wrap input::placeholder {
  color: #817f77;
}

.filter-row {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  margin: 16px calc(clamp(16px, 4vw, 48px) * -1) 8px;
  padding: 0 clamp(16px, 4vw, 48px) 8px;
  scrollbar-width: none;
}

.filter-row::-webkit-scrollbar {
  display: none;
}

.filter-chip {
  display: inline-flex;
  flex: 0 0 auto;
  gap: 7px;
  align-items: center;
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  padding: 8px 13px;
  color: var(--bone-muted);
  font-size: 0.74rem;
  font-weight: 700;
  cursor: pointer;
}

.filter-chip span {
  display: grid;
  min-width: 20px;
  height: 20px;
  place-items: center;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.06);
  font-size: 0.62rem;
}

.filter-chip.is-active {
  border-color: var(--gold);
  background: var(--gold);
  color: #171109;
}

.filter-chip.is-active span {
  background: rgba(0, 0, 0, 0.11);
}

.results-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin: 18px 0 14px;
  color: var(--bone-muted);
  font-size: 0.67rem;
}

.results-line strong {
  color: var(--bone);
  font-size: 0.75rem;
}

.codex-grid {
  padding-bottom: 32px;
}

.empty-state {
  display: grid;
  justify-items: center;
  border: 1px dashed var(--line);
  border-radius: var(--radius-md);
  padding: 50px 24px;
  text-align: center;
}

.empty-state[hidden] {
  display: none;
}

.empty-state > span {
  display: grid;
  width: 64px;
  height: 64px;
  place-items: center;
  margin-bottom: 16px;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--gold);
  font-size: 1.7rem;
}

.empty-state h2 {
  margin-bottom: 6px;
}

.empty-state p {
  max-width: 25rem;
  color: var(--bone-muted);
  line-height: 1.55;
}

.collection-summary {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 22px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background:
    radial-gradient(circle at 20% 0%, rgba(214, 170, 109, 0.12), transparent 22rem),
    var(--panel);
  padding: clamp(22px, 5vw, 34px);
}

.large-progress-ring {
  width: 112px;
  height: 112px;
}

.large-progress-ring::after {
  inset: 9px;
}

.large-progress-ring span {
  margin-top: -10px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 2.25rem;
}

.large-progress-ring small {
  position: absolute;
  top: 65px;
  color: var(--bone-muted);
  font-size: 0.62rem;
}

.collection-summary h2 {
  margin-bottom: 6px;
  font-size: clamp(1.45rem, 4vw, 2.2rem);
}

.collection-summary div > p:not(.eyebrow) {
  margin-bottom: 13px;
  color: var(--bone-muted);
  font-size: 0.78rem;
  line-height: 1.5;
}

.edition-summary {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  align-items: stretch;
  margin-top: 10px;
}

.edition-summary span,
.edition-summary a {
  display: flex;
  min-height: 58px;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--panel);
  padding: 10px 13px;
  color: var(--bone);
  text-decoration: none;
}

.edition-summary small {
  color: var(--bone-muted);
  font-size: 0.62rem;
  font-weight: 750;
}

.edition-summary strong {
  color: var(--gold);
}

.edition-summary a {
  grid-column: 1 / -1;
  padding-inline: 18px;
  color: var(--gold);
  font-size: 0.7rem;
  font-weight: 800;
}

.badge-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.badge-token {
  display: flex;
  min-width: 0;
  min-height: 54px;
  align-items: center;
  gap: 7px;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 8px;
  color: #6f716b;
  font-weight: 800;
}

.badge-token strong {
  flex: 0 0 auto;
  font-size: 0.8rem;
}

.badge-token small {
  color: inherit;
  font-size: 0.52rem;
  line-height: 1.25;
}

.badge-token.is-earned {
  border-color: var(--gold);
  background: rgba(214, 170, 109, 0.12);
  color: var(--gold);
}

.segmented-control {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  margin: 24px 0 18px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel);
  padding: 4px;
}

.segmented-control button {
  min-height: 43px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--bone-muted);
  font-size: 0.78rem;
  font-weight: 750;
  cursor: pointer;
}

.segmented-control button[aria-selected="true"] {
  background: var(--bone);
  color: var(--ink);
}

.segmented-control span {
  opacity: 0.68;
}

.collection-empty {
  margin-top: 8px;
}

.club-grid {
  display: grid;
  gap: 14px;
  padding-bottom: 30px;
}

.club-card {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--panel);
  padding: clamp(20px, 5vw, 30px);
}

.club-card h2 {
  margin-bottom: 8px;
  font-size: clamp(1.5rem, 5vw, 2.2rem);
}

.club-card > p:not(.eyebrow) {
  color: var(--bone-muted);
  line-height: 1.6;
}

.subscription-card {
  background:
    radial-gradient(circle at 95% 5%, rgba(214, 170, 109, 0.18), transparent 18rem),
    var(--panel);
}

.status-pill {
  position: absolute;
  top: 18px;
  right: 18px;
  border: 1px solid rgba(111, 139, 119, 0.42);
  border-radius: 99px;
  background: rgba(111, 139, 119, 0.12);
  padding: 6px 9px;
  color: #aac2ae;
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.price-line {
  display: flex;
  align-items: baseline;
  gap: 7px;
  margin: 20px 0;
}

.price-line strong {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 2.6rem;
  font-weight: 500;
}

.price-line span {
  color: var(--bone-muted);
  font-size: 0.78rem;
}

.product-spec-list {
  margin: 18px 0 0;
}

.product-spec-list div {
  display: grid;
  grid-template-columns: minmax(90px, 0.6fr) 1.4fr;
  gap: 16px;
  padding: 12px 0;
  border-top: 1px solid var(--line);
}

.product-spec-list dt {
  color: var(--bone-muted);
  font-size: 0.68rem;
  font-weight: 750;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.product-spec-list dd {
  margin: 0;
  font-size: 0.8rem;
  line-height: 1.45;
}

.toggle-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 18px;
  align-items: center;
  padding: 15px 0;
  border-top: 1px solid var(--line);
  cursor: pointer;
}

.toggle-row span {
  display: grid;
  gap: 3px;
}

.toggle-row strong {
  font-size: 0.84rem;
}

.toggle-row small {
  color: var(--bone-muted);
  font-size: 0.68rem;
}

.toggle-row input {
  position: absolute;
  opacity: 0;
}

.toggle-row i {
  position: relative;
  width: 42px;
  height: 24px;
  border-radius: 99px;
  background: #303632;
  transition: background 160ms ease;
}

.toggle-row i::after {
  position: absolute;
  top: 4px;
  left: 4px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #a8aba5;
  content: "";
  transition: transform 160ms ease, background 160ms ease;
}

.toggle-row input:checked + i {
  background: var(--gold-deep);
}

.toggle-row input:checked + i::after {
  transform: translateX(18px);
  background: var(--bone);
}

.bottom-nav {
  position: fixed;
  z-index: 35;
  right: 10px;
  bottom: max(10px, env(safe-area-inset-bottom));
  left: 10px;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  max-width: 640px;
  margin: 0 auto;
  border: 1px solid rgba(241, 234, 216, 0.16);
  border-radius: 24px;
  background: rgba(15, 22, 20, 0.92);
  padding: 7px;
  box-shadow: 0 18px 55px rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(20px);
}

.nav-item,
.scan-nav {
  display: grid;
  min-height: 56px;
  place-items: center;
  align-content: center;
  gap: 3px;
  border: 0;
  border-radius: 17px;
  background: transparent;
  color: #898c84;
  cursor: pointer;
}

.nav-item span,
.scan-nav span {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.15rem;
  line-height: 1;
}

.nav-item small,
.scan-nav small {
  font-size: 0.57rem;
  font-weight: 720;
}

.nav-item.is-active {
  background: rgba(214, 170, 109, 0.11);
  color: var(--gold);
}

.scan-nav {
  position: relative;
  align-self: center;
  width: 58px;
  height: 58px;
  justify-self: center;
  border: 1px solid var(--gold);
  border-radius: 50%;
  background: var(--gold);
  color: #171109;
  transform: translateY(-17px);
  box-shadow: 0 8px 26px rgba(214, 170, 109, 0.24);
}

dialog {
  color: var(--bone);
}

dialog::backdrop {
  background: rgba(2, 5, 4, 0.76);
  backdrop-filter: blur(8px);
}

.creature-dialog {
  width: min(100% - 12px, 880px);
  max-height: calc(100vh - 12px);
  margin: auto;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 28px;
  background: var(--ink-soft);
  padding: 0;
  box-shadow: var(--shadow);
}

.creature-dialog[open] {
  animation: dialog-in 220ms ease both;
}

@keyframes dialog-in {
  from { opacity: 0; transform: translateY(16px) scale(0.985); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.dialog-hero {
  position: relative;
  display: grid;
  min-height: 390px;
  align-items: end;
  overflow: hidden;
  background: #d8d7d0;
}

.dialog-hero > img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.dialog-hero::after {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(6, 10, 9, 0.98), rgba(6, 10, 9, 0.04) 65%);
  content: "";
}

.dialog-scene-label {
  position: absolute;
  z-index: 3;
  top: 16px;
  left: 16px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  background: rgba(7, 11, 10, 0.66);
  padding: 7px 10px;
  color: rgba(255, 255, 255, 0.88);
  font-size: 0.58rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  backdrop-filter: blur(10px);
}

.dialog-title {
  position: relative;
  z-index: 2;
  padding: 80px 22px 22px;
}

.dialog-title h2 {
  max-width: 700px;
  margin: 0;
  font-size: clamp(2.25rem, 9vw, 4.8rem);
  line-height: 0.96;
}

.dialog-title p {
  margin: 8px 0 0;
  color: rgba(241, 234, 216, 0.72);
  font-size: 0.8rem;
  font-style: italic;
}

.dialog-close {
  position: absolute;
  z-index: 5;
  top: 14px;
  right: 14px;
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 50%;
  background: rgba(7, 11, 10, 0.62);
  color: white;
  font-size: 1.4rem;
  cursor: pointer;
  backdrop-filter: blur(10px);
}

.dialog-body {
  padding: 20px clamp(18px, 5vw, 36px) 34px;
}

.dialog-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
  margin-bottom: 22px;
}

.dialog-tabs {
  display: flex;
  gap: 5px;
  overflow-x: auto;
  margin: 0 -4px 20px;
  padding: 4px;
  border-bottom: 1px solid var(--line);
}

.dialog-tabs button {
  flex: 0 0 auto;
  border: 0;
  border-bottom: 2px solid transparent;
  background: transparent;
  padding: 10px 11px;
  color: var(--bone-muted);
  font-size: 0.74rem;
  font-weight: 750;
  cursor: pointer;
}

.dialog-tabs button.is-active {
  border-bottom-color: var(--gold);
  color: var(--gold);
}

.dialog-panel[hidden] {
  display: none;
}

.quick-fact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
}

.quick-fact {
  min-height: 92px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--panel);
  padding: 14px;
}

.quick-fact small {
  display: block;
  margin-bottom: 7px;
  color: var(--bone-muted);
  font-size: 0.6rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.quick-fact strong {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 0.96rem;
  font-weight: 500;
  line-height: 1.3;
}

.story-block {
  margin-top: 12px;
  border: 1px solid rgba(214, 170, 109, 0.23);
  border-radius: var(--radius-sm);
  background: rgba(214, 170, 109, 0.055);
  padding: 18px;
}

.story-block h3 {
  margin-bottom: 7px;
  font-size: 1.25rem;
}

.story-block p {
  margin-bottom: 0;
  color: var(--bone-muted);
  font-size: 0.84rem;
  line-height: 1.65;
}

.reconstruction-block {
  display: grid;
  overflow: hidden;
  margin-top: 12px;
  border: 1px solid rgba(214, 170, 109, 0.23);
  border-radius: var(--radius-sm);
  background: #070b0a;
}

.reconstruction-copy {
  padding: 18px;
}

.reconstruction-copy h3 {
  margin: 4px 0 7px;
  font-size: 1.25rem;
}

.reconstruction-copy p:last-child {
  margin: 0;
  color: var(--bone-muted);
  font-size: 0.78rem;
  line-height: 1.6;
}

.reconstruction-block video {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #030605;
  object-fit: cover;
}

.research-note {
  margin: 16px 0 0;
  color: #8f928b;
  font-size: 0.68rem;
  line-height: 1.55;
}

.dossier-research-link {
  width: 100%;
  margin-top: 16px;
}

.fact-card-preview {
  width: min(100%, 520px);
  margin: 0 auto;
  border-radius: 16px;
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.32);
}

.card-caption {
  max-width: 36rem;
  margin: 14px auto 0;
  color: var(--bone-muted);
  font-size: 0.73rem;
  line-height: 1.55;
  text-align: center;
}

.product-tab-grid {
  display: grid;
  gap: 14px;
}

.product-gallery {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.product-gallery img {
  width: 100%;
  border-radius: var(--radius-sm);
  background: #d8d7d0;
}

.model-dimension-note {
  border: 1px dashed var(--line);
  border-radius: var(--radius-sm);
  padding: 13px;
  color: var(--bone-muted);
  font-size: 0.73rem;
  line-height: 1.5;
}

.scan-dialog {
  width: min(100% - 24px, 440px);
  max-height: calc(100dvh - 24px);
  overflow-y: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--ink-soft);
  padding: 28px;
  text-align: center;
}

.scan-dialog .dialog-close {
  top: 12px;
  right: 12px;
}

.scan-dialog h2 {
  margin-bottom: 9px;
  font-size: 2rem;
}

.scan-dialog > p:not(.eyebrow) {
  color: var(--bone-muted);
  line-height: 1.55;
}

.scan-dialog > small {
  display: block;
  margin-top: 13px;
  color: #7e817a;
  font-size: 0.65rem;
  line-height: 1.45;
}

.scan-frame {
  position: relative;
  display: grid;
  width: 190px;
  height: 190px;
  place-items: center;
  overflow: hidden;
  margin: 14px auto 24px;
  border-radius: 24px;
  background:
    radial-gradient(circle, rgba(214, 170, 109, 0.12), transparent 60%),
    #0d1412;
}

.scan-frame > span {
  position: absolute;
  z-index: 4;
  width: 38px;
  height: 38px;
  border-color: var(--gold);
  border-style: solid;
}

.scan-frame > span:nth-child(1) { top: 0; left: 0; border-width: 2px 0 0 2px; border-radius: 18px 0 0; }
.scan-frame > span:nth-child(2) { top: 0; right: 0; border-width: 2px 2px 0 0; border-radius: 0 18px 0 0; }
.scan-frame > span:nth-child(3) { bottom: 0; left: 0; border-width: 0 0 2px 2px; border-radius: 0 0 0 18px; }
.scan-frame > span:nth-child(4) { right: 0; bottom: 0; border-width: 0 2px 2px 0; border-radius: 0 0 18px; }

.scan-frame img {
  position: relative;
  z-index: 1;
  width: 105px;
  height: 105px;
  border-radius: 50%;
  background: white;
  opacity: 0.72;
}

.scan-frame video {
  position: absolute;
  z-index: 1;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.scan-frame video[hidden] {
  display: none;
}

.scan-line {
  position: absolute;
  z-index: 3;
  right: 8px;
  left: 8px;
  height: 1px;
  background: var(--gold);
  box-shadow: 0 0 13px 2px rgba(214, 170, 109, 0.5);
  animation: scan 2.2s ease-in-out infinite alternate;
}

.collector-code-form {
  display: grid;
  gap: 8px;
  margin-top: 18px;
  text-align: left;
}

.collector-code-form label {
  color: var(--bone-muted);
  font-size: 0.65rem;
  line-height: 1.45;
}

.collector-code-form > div {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
}

.collector-code-form input {
  min-width: 0;
  min-height: 46px;
  border: 1px solid var(--line);
  border-radius: 999px;
  outline: none;
  background: #0b1210;
  padding: 0 16px;
  color: var(--bone);
  font: inherit;
}

.collector-code-form input:focus {
  border-color: var(--gold);
}

@keyframes scan {
  from { transform: translateY(-76px); }
  to { transform: translateY(76px); }
}

.toast {
  position: fixed;
  z-index: 100;
  bottom: calc(96px + var(--safe-bottom));
  left: 50%;
  max-width: calc(100% - 32px);
  transform: translate(-50%, 20px);
  border: 1px solid rgba(214, 170, 109, 0.4);
  border-radius: 999px;
  background: rgba(20, 29, 26, 0.96);
  padding: 11px 16px;
  color: var(--bone);
  font-size: 0.75rem;
  font-weight: 700;
  opacity: 0;
  pointer-events: none;
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.34);
  transition: opacity 180ms ease, transform 180ms ease;
  backdrop-filter: blur(15px);
}

.toast.is-visible {
  transform: translate(-50%, 0);
  opacity: 1;
}

@media (min-width: 620px) {
  .edition-summary {
    grid-template-columns: 1fr 1fr auto;
  }

  .edition-summary a {
    grid-column: auto;
  }

  .realm-grid {
    grid-template-columns: 1fr 1fr;
  }

  .creature-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
  }

  .featured-grid .creature-card:nth-child(n + 4) {
    display: none;
  }

  .club-grid {
    grid-template-columns: 1fr 1fr;
  }

  .subscription-card {
    grid-row: span 2;
  }

  .dialog-body {
    padding-top: 26px;
  }

  .quick-fact-grid {
    grid-template-columns: repeat(4, 1fr);
  }

  .product-tab-grid {
    grid-template-columns: 1.05fr 0.95fr;
    align-items: start;
  }
}

@media (min-width: 860px) {
  .hero-grid {
    grid-template-columns: minmax(0, 1.16fr) minmax(340px, 0.84fr);
    gap: clamp(32px, 6vw, 72px);
    align-items: center;
    min-height: calc(100vh - 130px);
  }

  .cinematic-card,
  .cinematic-card video {
    min-height: min(68vh, 680px);
  }

  .featured-copy {
    padding-right: 18px;
  }

  .creature-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px;
  }

  .featured-grid .creature-card:nth-child(4) {
    display: block;
  }

  .subscription-banner {
    grid-template-columns: 1fr auto;
    align-items: end;
  }

  .bottom-nav {
    right: 22px;
    bottom: 18px;
    left: 22px;
  }

  .dialog-hero {
    min-height: 520px;
  }
}

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

  .club-grid {
    grid-template-columns: 1.2fr 1fr 1fr;
  }

  .subscription-card {
    grid-row: span 2;
  }

  .install-card {
    grid-column: 2 / 4;
  }
}

@media (max-width: 430px) {
  .brand-copy span {
    display: none;
  }

  .featured-copy h1,
  .page-intro h1 {
    font-size: 2.55rem;
  }

  .cinematic-card,
  .cinematic-card video {
    min-height: 390px;
  }

  .feature-facts span {
    padding-inline: 6px;
    font-size: 0.72rem;
  }

  .section-heading .text-button {
    align-self: end;
  }

  .results-line span {
    display: none;
  }

  .collection-summary {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
  }

  .badge-row {
    justify-content: center;
  }

  .dialog-actions {
    grid-template-columns: 1fr;
  }
}

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