:root {
  color-scheme: dark;
  --ink: #fff8ec;
  --ink-soft: #d8cddd;
  --paper: #120a19;
  --paper-deep: #21152a;
  --white: #fffdf8;
  --surface: #1a1022;
  --purple: #c982ff;
  --purple-deep: #2d0b49;
  --purple-bright: #e0b0ff;
  --gold: #f2b72f;
  --gold-soft: #ffe7a6;
  --line: rgba(255, 248, 236, 0.14);
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.34);
  --body-start: #1b0c25;
  --prose: #f0e8f2;
  --gold-ink: #59461e;
  --trust-ink: #e9deed;
  --quiet: #c2b6c7;
  --header-bg: rgba(18, 10, 25, 0.94);
  --cta-bg: #f6c84b;
  --cta-bg-hover: #ffdc7d;
  --cta-ink: #241028;
  --radius: 18px;
  --serif: Georgia, "Times New Roman", serif;
  --sans: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

html[data-theme="light"] {
  color-scheme: light;
  --ink: #1b1025;
  --ink-soft: #4f4658;
  --paper: #f7f2e9;
  --paper-deep: #eee5d7;
  --white: #fffdf8;
  --surface: #fffdf8;
  --purple: #4b1675;
  --purple-deep: #2d0b49;
  --purple-bright: #7c2bc4;
  --line: rgba(27, 16, 37, 0.16);
  --shadow: 0 24px 70px rgba(45, 11, 73, 0.12);
  --body-start: #f5eee3;
  --prose: #352b3d;
  --gold-ink: #59461e;
  --trust-ink: #43344e;
  --quiet: #716877;
  --header-bg: rgba(247, 242, 233, 0.94);
  --cta-bg: #e9ad19;
  --cta-bg-hover: #f2bd35;
  --cta-ink: #241028;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: radial-gradient(circle at 86% 4%, rgba(124, 43, 196, 0.2), transparent 28rem), linear-gradient(180deg, var(--body-start) 0, var(--paper) 32rem);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--purple); text-decoration-thickness: 1.5px; text-underline-offset: 0.18em; }
a:hover { color: var(--purple-bright); }
a:focus-visible { outline: 3px solid var(--gold); outline-offset: 4px; border-radius: 4px; }
.paper-grain {
  position: fixed;
  z-index: -1;
  inset: 0;
  pointer-events: none;
  opacity: 0.45;
  background-image: repeating-linear-gradient(90deg, rgba(27, 16, 37, 0.016) 0 1px, transparent 1px 4px), repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.18) 0 1px, transparent 1px 5px);
}
.skip-link {
  position: fixed;
  z-index: 100;
  top: 12px;
  left: 12px;
  padding: 10px 14px;
  color: var(--white);
  background: var(--purple-deep);
  transform: translateY(-180%);
}
.skip-link:focus { transform: translateY(0); }
.site-header {
  position: sticky;
  z-index: 50;
  top: 0;
  width: min(1180px, calc(100% - 40px));
  min-height: 86px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  padding: 0 12px;
  background: var(--header-bg);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.12);
  backdrop-filter: blur(16px) saturate(1.15);
}
.brand { display: inline-flex; align-items: center; gap: 11px; color: var(--ink); text-decoration: none; }
.brand img { width: 48px; height: 48px; filter: drop-shadow(0 8px 14px rgba(45, 11, 73, 0.18)); }
.brand span { display: grid; line-height: 1.05; }
.brand b { font-family: var(--serif); font-size: 1.25rem; }
.brand small {
  margin-top: 5px;
  color: var(--ink-soft);
  font-size: 0.75rem;
  font-weight: 750;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.site-header nav, .site-footer nav { display: flex; align-items: center; gap: 22px; }
.site-header nav a, .site-footer nav a { font-size: 0.82rem; font-weight: 760; text-decoration: none; }
.theme-toggle {
  min-height: 42px;
  padding: 8px 12px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 999px;
  font: 780 0.75rem/1 var(--sans);
  cursor: pointer;
}
.theme-toggle:hover { color: var(--purple-bright); border-color: var(--purple); }
.theme-toggle:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }
.theme-toggle svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-linecap: round; stroke-width: 1.8; }
.nav-cta, .visit-cityspin-button {
  min-height: 44px;
  padding: 10px 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  color: var(--cta-ink) !important;
  background: var(--cta-bg);
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 999px;
  box-shadow: 0 8px 0 rgba(87, 52, 0, 0.32), 0 16px 28px rgba(242, 183, 47, 0.2);
  font-size: 0.8rem;
  font-weight: 880;
  text-decoration: none;
  transition: background 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}
.nav-cta:hover, .visit-cityspin-button:hover { color: var(--cta-ink); background: var(--cta-bg-hover); transform: translateY(-2px); }
.nav-cta:active, .visit-cityspin-button:active { box-shadow: 0 3px 0 rgba(87, 52, 0, 0.32); transform: translateY(3px); }
.nav-cta span, .visit-cityspin-button span { font-size: 1rem; transition: transform 160ms ease; }
.nav-cta:hover span, .visit-cityspin-button:hover span { transform: translateX(3px); }
.button {
  min-height: 44px;
  padding: 10px 17px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--white) !important;
  background: var(--purple-deep);
  border: 1px solid var(--purple-deep);
  border-radius: 999px;
  font-weight: 800;
  text-decoration: none;
}
main { display: block; }
.index-hero {
  width: min(1180px, calc(100% - 40px));
  margin: 74px auto 0;
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  gap: 52px;
}
.issue-rail {
  min-height: 420px;
  padding: 18px 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  color: var(--white);
  background: var(--purple-deep);
  border-radius: 3px;
  box-shadow: 12px 18px 0 var(--gold);
}
.issue-rail span {
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  font-size: 0.66rem;
  font-weight: 820;
  letter-spacing: 0.21em;
}
.issue-rail b { font-family: var(--serif); font-size: 2.35rem; line-height: 1; }
.hero-copy { max-width: 880px; padding: 30px 0 54px; }
.eyebrow {
  margin: 0 0 16px;
  color: var(--purple);
  font-size: 0.75rem;
  font-weight: 820;
  letter-spacing: 0.17em;
  text-transform: uppercase;
}
h1, h2, h3 {
  margin-top: 0;
  font-family: var(--serif);
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1.04;
}
.index-hero h1 { max-width: 900px; margin-bottom: 26px; font-size: clamp(3.35rem, 8vw, 7.35rem); }
.dek {
  max-width: 790px;
  margin: 0;
  color: var(--ink-soft);
  font-family: var(--serif);
  font-size: clamp(1.3rem, 2.2vw, 1.72rem);
  line-height: 1.48;
}
.trust-strip {
  margin-top: 40px;
  padding-top: 18px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px 26px;
  border-top: 1px solid var(--line);
}
.index-actions { margin-top: 34px; display: flex; align-items: center; flex-wrap: wrap; gap: 18px; }
.index-actions > span { color: var(--ink-soft); font-size: 0.76rem; font-weight: 760; }
.trust-strip span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--ink-soft);
  font-size: 0.76rem;
  font-weight: 760;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.trust-strip span::before {
  width: 8px;
  height: 8px;
  content: "";
  background: var(--gold);
  border: 2px solid var(--purple-deep);
  border-radius: 50%;
}
.featured-section, .method-section { width: min(1180px, calc(100% - 40px)); margin: 96px auto 0; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 30px; }
.section-heading h2, .method-section h2 { max-width: 720px; margin-bottom: 0; font-size: clamp(2.25rem, 5vw, 4.5rem); }
.article-card {
  margin-top: 34px;
  display: grid;
  grid-template-columns: 104px minmax(0, 1.3fr) minmax(260px, 0.7fr);
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.card-index {
  padding: 27px 16px;
  color: var(--gold-soft);
  background: var(--purple-deep);
  font-size: 0.75rem;
  font-weight: 820;
  letter-spacing: 0.14em;
  text-align: center;
  writing-mode: vertical-rl;
  transform: rotate(180deg);
}
.card-body, .article-card aside { padding: clamp(28px, 5vw, 52px); }
.card-meta { margin: 0 0 12px; color: var(--purple); font-size: 0.75rem; font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase; }
.card-body h3 { margin-bottom: 18px; font-size: clamp(2rem, 4vw, 3.6rem); }
.card-body h3 a { color: var(--ink); text-decoration: none; }
.card-body > p:not(.card-meta) { max-width: 680px; color: var(--ink-soft); }
.text-link { display: inline-flex; align-items: center; gap: 8px; font-weight: 800; }
.article-card aside {
  color: var(--white);
  background: linear-gradient(160deg, rgba(124, 43, 196, 0.34), transparent 55%), var(--purple-deep);
}
.article-card aside strong { color: var(--gold); font-size: 0.75rem; letter-spacing: 0.14em; text-transform: uppercase; }
.article-card aside ul { margin: 20px 0 0; padding-left: 20px; }
.method-section {
  margin-bottom: 110px;
  padding: 54px;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 60px;
  background: var(--gold-soft);
  border: 1px solid rgba(99, 62, 0, 0.16);
  border-radius: var(--radius);
}
.method-section h2 { color: var(--purple-deep); }
.method-section > p { margin: 10px 0 0; color: #59461e; font-family: var(--serif); font-size: 1.3rem; }
.article-page { width: min(1180px, calc(100% - 40px)); margin: 58px auto 110px; }
.article-hero {
  padding: 58px clamp(24px, 7vw, 82px) 46px;
  color: var(--white);
  background: linear-gradient(140deg, rgba(124, 43, 196, 0.54), transparent 54%), var(--purple-deep);
  border-radius: var(--radius);
  box-shadow: 16px 18px 0 var(--gold);
}
.article-hero h1 { max-width: 930px; margin-bottom: 24px; font-size: clamp(3rem, 7vw, 6.3rem); }
.article-page--simple { max-width: 980px; }
.article-hero--simple { padding-block: clamp(46px, 8vw, 76px); }
.article-hero--simple h1 { max-width: 850px; margin: 0; font-size: clamp(3rem, 7vw, 5.8rem); }
.article-answer { width: min(760px, 100%); margin: 68px auto 0; }
.prose { min-width: 0; max-width: 76ch; font-family: var(--serif); font-size: 1.08rem; }
.prose--answer { max-width: none; }
.prose--answer > p { margin: 0 0 28px; }
.prose > p:first-of-type {
  margin-top: 0;
  padding: 25px 27px;
  background: var(--gold-soft);
  border-left: 5px solid var(--gold);
  color: #352b3d;
  font-size: 1.18rem;
  line-height: 1.55;
}
.prose p, .prose li { color: var(--prose); }
.prose a[href^="https://cityspin.io/"]:not(.visit-cityspin-button) {
  padding: 1px 5px;
  color: var(--purple-deep);
  background: var(--gold-soft);
  border-radius: 4px;
  font-family: var(--sans);
  font-weight: 820;
}
.inline-cityspin-promo {
  margin: 50px 0;
  padding: 20px;
  display: grid;
  grid-template-columns: 176px minmax(0, 1fr) auto;
  align-items: center;
  gap: 22px;
  color: var(--white);
  background: linear-gradient(135deg, rgba(124, 43, 196, 0.7), transparent 58%), var(--purple-deep);
  border: 1px solid rgba(246, 200, 75, 0.7);
  border-radius: var(--radius);
  box-shadow: 10px 12px 0 var(--gold);
  font-family: var(--sans);
}
.inline-cityspin-promo__visuals { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.inline-cityspin-promo__visuals img { width: 84px; height: 84px; object-fit: cover; border-radius: 11px; }
.inline-cityspin-promo__copy { display: grid; gap: 5px; }
.inline-cityspin-promo__copy > span { color: var(--gold); font-size: 0.7rem; font-weight: 900; letter-spacing: 0.16em; }
.inline-cityspin-promo__copy strong { font-family: var(--serif); font-size: 1.18rem; line-height: 1.25; }
.inline-cityspin-promo__copy p { margin: 0; color: var(--white); font-size: 0.82rem; font-weight: 800; }
.inline-cityspin-promo__copy i { padding: 0 4px; color: var(--gold); font-style: normal; }
.inline-cityspin-promo__copy small { color: rgba(255, 255, 255, 0.75); font-size: 0.7rem; line-height: 1.35; }
.inline-cityspin-promo .visit-cityspin-button { min-width: 150px; }
.site-footer {
  padding: 48px max(20px, calc((100% - 1180px) / 2));
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 28px 50px;
  color: rgba(255, 255, 255, 0.72);
  background: var(--purple-deep);
}
.site-footer b { color: var(--white); font-family: var(--serif); font-size: 1.2rem; }
.site-footer p { margin: 5px 0 0; font-size: 0.8rem; }
.site-footer a { color: var(--gold-soft); }
.footer-note { grid-column: 1 / -1; padding-top: 24px; border-top: 1px solid rgba(255, 255, 255, 0.16); }
.not-found {
  width: min(720px, calc(100% - 40px));
  min-height: 100vh;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.not-found h1 { margin-bottom: 16px; font-size: clamp(3rem, 8vw, 6rem); }
.not-found div { margin-top: 20px; display: flex; align-items: center; gap: 22px; }

.engagement-dialog {
  width: min(620px, calc(100% - 32px));
  max-height: min(780px, calc(100dvh - 32px));
  margin: auto;
  padding: 0;
  overflow: hidden auto;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid rgba(45, 11, 73, 0.24);
  border-radius: var(--radius);
  box-shadow: 0 32px 100px rgba(27, 16, 37, 0.42);
}
.engagement-dialog[open] { animation: dialog-enter 240ms ease-out; }
.engagement-dialog::backdrop { background: rgba(27, 16, 37, 0.66); backdrop-filter: blur(5px); }
.engagement-dialog__accent { height: 9px; background: var(--gold); }
.engagement-dialog__body { padding: 35px 38px 31px; }
.engagement-dialog__topline { display: flex; align-items: center; justify-content: space-between; gap: 18px; }
.engagement-dialog__topline .eyebrow { margin: 0; }
.engagement-dialog__badge {
  padding: 6px 10px;
  color: var(--purple-deep);
  background: var(--gold-soft);
  border: 1px solid rgba(99, 62, 0, 0.18);
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 820;
  letter-spacing: 0.03em;
  white-space: nowrap;
}
.engagement-dialog h2 { margin: 21px 44px 15px 0; font-size: clamp(2rem, 7vw, 3.25rem); }
.engagement-dialog h2 + p { margin: 0; color: var(--ink-soft); line-height: 1.58; }
.engagement-dialog__benefits {
  margin-top: 23px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.engagement-dialog__benefits article {
  min-width: 0;
  overflow: hidden;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 13px;
}
.engagement-dialog__benefits img { width: 100%; height: 112px; display: block; object-fit: cover; }
.engagement-dialog__benefits div { padding: 13px 14px 15px; }
.engagement-dialog__benefits strong { color: var(--ink); font-size: 0.83rem; line-height: 1.25; }
.engagement-dialog__benefits p { margin: 6px 0 0; color: var(--ink-soft); font-size: 0.75rem; line-height: 1.42; }
.engagement-dialog__close {
  position: absolute;
  z-index: 1;
  top: 21px;
  right: 18px;
  width: 38px;
  height: 38px;
  padding: 0;
  color: var(--ink-soft);
  background: transparent;
  border: 0;
  border-radius: 50%;
  font: 400 1.75rem/1 var(--sans);
  cursor: pointer;
}
.engagement-dialog__close:hover { color: var(--purple-deep); background: var(--paper-deep); }
.engagement-dialog__close:focus-visible, .engagement-dialog__actions button:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }
.engagement-dialog__trust {
  margin: 23px 0 0;
  padding: 14px 16px;
  display: flex;
  gap: 10px;
  color: var(--trust-ink);
  background: var(--paper);
  border-left: 4px solid var(--purple);
  font-size: 0.83rem;
  line-height: 1.45;
}
.engagement-dialog__trust span { color: var(--purple); font-weight: 900; }
.engagement-dialog__actions { margin-top: 25px; display: flex; align-items: center; gap: 20px; }
.engagement-dialog__cta {
  min-height: 48px;
  padding: 12px 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--cta-ink) !important;
  background: var(--cta-bg);
  border-radius: 999px;
  box-shadow: 0 7px 0 rgba(87, 52, 0, 0.32), 0 14px 26px rgba(242, 183, 47, 0.22);
  font-size: 0.83rem;
  font-weight: 820;
  text-decoration: none;
}
.engagement-dialog__cta:hover { color: var(--cta-ink); background: var(--cta-bg-hover); transform: translateY(-2px); }
.engagement-dialog__actions button {
  padding: 8px 0;
  color: var(--purple);
  background: transparent;
  border: 0;
  font: 800 0.82rem/1.2 var(--sans);
  text-decoration: underline;
  text-underline-offset: 0.2em;
  cursor: pointer;
}
.engagement-dialog__scope { margin: 17px 0 0; color: var(--quiet); font-size: 0.75rem; font-weight: 720; letter-spacing: 0.08em; text-transform: uppercase; }

@keyframes dialog-enter {
  from { opacity: 0; transform: translateY(18px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@media (max-width: 900px) {
  .index-hero { grid-template-columns: 54px minmax(0, 1fr); gap: 30px; }
  .issue-rail { min-height: 350px; box-shadow: 8px 12px 0 var(--gold); }
  .article-card, .method-section { grid-template-columns: 1fr; }
  .card-index { padding: 11px 18px; text-align: left; writing-mode: horizontal-tb; transform: none; }
  .article-card aside { padding-top: 30px; }
  .inline-cityspin-promo { grid-template-columns: 176px minmax(0, 1fr); }
  .inline-cityspin-promo .visit-cityspin-button { grid-column: 1 / -1; width: 100%; }
}

@media (max-width: 640px) {
  body { font-size: 16px; }
  .site-header { width: min(100% - 16px, 1180px); min-height: 74px; padding: 0 6px; gap: 8px; }
  .site-header nav { gap: 7px; }
  .site-header nav > a:first-child { display: none; }
  .theme-toggle span { display: none; }
  .theme-toggle { width: 42px; padding: 0; justify-content: center; }
  .nav-cta { min-height: 42px; padding: 9px 12px; font-size: 0.76rem; box-shadow: 0 5px 0 rgba(87, 52, 0, 0.32), 0 11px 20px rgba(242, 183, 47, 0.18); }
  .nav-cta span { display: none; }
  .brand img { width: 42px; height: 42px; }
  .index-hero { width: min(100% - 28px, 1180px); margin-top: 42px; display: block; }
  .issue-rail { min-height: 0; padding: 10px 13px; flex-direction: row; box-shadow: 6px 7px 0 var(--gold); }
  .issue-rail span { writing-mode: horizontal-tb; transform: none; }
  .issue-rail b { font-size: 1.45rem; }
  .hero-copy { padding-top: 42px; }
  .index-hero h1 { font-size: clamp(3rem, 15vw, 5rem); }
  .featured-section, .method-section, .article-page { width: min(100% - 28px, 1180px); }
  .featured-section, .method-section { margin-top: 70px; }
  .card-body, .article-card aside, .method-section { padding: 25px; }
  .method-section { margin-bottom: 72px; gap: 26px; }
  .article-page { margin-top: 28px; }
  .article-hero { padding: 32px 22px 30px; box-shadow: 7px 9px 0 var(--gold); }
  .article-hero--simple { padding-block: 42px; }
  .article-hero--simple h1 { font-size: clamp(2.55rem, 12vw, 3.6rem); }
  .article-answer { margin-top: 48px; }
  .prose { font-size: 1.02rem; }
  .prose > p:first-of-type { padding: 20px; }
  .inline-cityspin-promo { margin: 44px 0; padding: 18px; grid-template-columns: 1fr; gap: 18px; box-shadow: 7px 8px 0 var(--gold); }
  .inline-cityspin-promo__visuals { grid-template-columns: 1fr 1fr; }
  .inline-cityspin-promo__visuals img { width: 100%; height: 104px; }
  .inline-cityspin-promo .visit-cityspin-button { grid-column: auto; }
  .site-footer { grid-template-columns: 1fr; }
  .site-footer nav { align-items: flex-start; flex-direction: column; gap: 12px; }
  .engagement-dialog { width: min(100% - 20px, 620px); max-height: calc(100dvh - 20px); }
  .engagement-dialog__body { padding: 29px 23px 24px; }
  .engagement-dialog__topline { align-items: flex-start; flex-direction: column; gap: 10px; }
  .engagement-dialog h2 { margin-top: 17px; font-size: clamp(2rem, 10vw, 2.65rem); }
  .engagement-dialog__benefits { gap: 9px; }
  .engagement-dialog__benefits img { height: 94px; }
  .engagement-dialog__benefits div { padding: 11px 12px 13px; }
  .engagement-dialog__actions { align-items: stretch; flex-direction: column; gap: 10px; }
  .engagement-dialog__cta { width: 100%; }
  .engagement-dialog__actions button { min-height: 40px; }
}

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