:root {
  --jade-dark: #2b2b2b;
  --jade-mid: #3a3842;
  --jade-light: #4a4654;
  --album-brown: #5c4033;
  --lucky-gold: #ffd700;
  --lucky-gold-deep: #ffa500;
  --fortune-purple: #800080;
  --fortune-pink: #ff1493;
  --imperial-red: #d22b2b;
  --zen-blue: #4cc9f0;
  --neko-white: #fdfdfd;
  --parchment: #c8c2b4;
  --success: #5eead4;
  --header-h: 4.25rem;
  --radius: 1.25rem;
  --shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
  font-size: 16px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "DM Sans", system-ui, sans-serif;
  color: var(--neko-white);
  background: var(--jade-dark);
  line-height: 1.6;
  overflow-x: hidden;
}

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

a {
  color: var(--zen-blue);
}

a:hover {
  color: var(--lucky-gold);
}

h1,
h2,
h3 {
  font-family: "Crimson Pro", Georgia, serif;
  font-weight: 700;
  line-height: 1.15;
  margin: 0 0 0.75rem;
}

h1 {
  font-size: clamp(2.25rem, 5vw, 3.35rem);
}

h2 {
  font-size: clamp(1.85rem, 3.5vw, 2.5rem);
}

h3 {
  font-size: 1.25rem;
}

p {
  margin: 0 0 1rem;
  color: var(--parchment);
}

.perforation-strip {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 10px;
  z-index: 100;
  background: repeating-linear-gradient(
    90deg,
    var(--jade-dark) 0 6px,
    var(--lucky-gold) 6px 8px,
    var(--jade-dark) 8px 14px
  );
  opacity: 0.85;
}

.site-header {
  position: sticky;
  top: 10px;
  z-index: 90;
  padding: 0 1rem;
  margin-bottom: -var(--header-h);
}

.header-inner {
  max-width: 72rem;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.65rem 1.25rem;
  background: rgba(43, 43, 43, 0.82);
  backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 215, 0, 0.22);
  border-radius: 999px;
  box-shadow: var(--shadow);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  text-decoration: none;
  color: var(--neko-white);
  font-weight: 700;
  font-family: "Crimson Pro", serif;
  font-size: 1.1rem;
}

.brand-mark {
  border-radius: 12px;
  box-shadow: 0 0 0 2px rgba(255, 215, 0, 0.35);
}

.site-nav {
  display: flex;
  gap: 1.25rem;
}

.site-nav a {
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--parchment);
  transition: color 0.2s;
}

.site-nav a.is-active,
.site-nav a:hover {
  color: var(--lucky-gold);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 6px;
  background: none;
  border: none;
  padding: 0.5rem;
  cursor: pointer;
}

.nav-toggle-bar {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--neko-white);
  border-radius: 2px;
}

.hero {
  position: relative;
  min-height: min(92vh, 900px);
  padding: calc(var(--header-h) + 2rem) 1.25rem 4rem;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background: url("assets/hero-bg.png") center / cover no-repeat;
  opacity: 0.35;
}

.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(43, 43, 43, 0.92) 0%,
    rgba(128, 0, 128, 0.55) 45%,
    rgba(43, 43, 43, 0.95) 100%
  );
}

.hero-glow {
  position: absolute;
  width: 50vmax;
  height: 50vmax;
  top: -20%;
  right: -10%;
  background: radial-gradient(circle, rgba(255, 215, 0, 0.12), transparent 65%);
  pointer-events: none;
}

.hero-inner {
  position: relative;
  max-width: 72rem;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2.5rem;
  align-items: center;
  width: 100%;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--zen-blue);
  margin-bottom: 0.75rem;
}

.lead {
  font-size: 1.05rem;
  max-width: 36rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin: 1.5rem 0;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.35rem;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.92rem;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}

.btn-primary {
  background: linear-gradient(135deg, var(--lucky-gold), var(--lucky-gold-deep));
  color: var(--jade-dark);
  box-shadow: 0 8px 28px rgba(255, 165, 0, 0.35);
}

.btn-primary:hover {
  transform: translateY(-2px);
  color: var(--jade-dark);
}

.btn-ghost {
  background: transparent;
  color: var(--neko-white);
  border: 1px solid rgba(253, 253, 253, 0.35);
}

.btn-ghost:hover {
  border-color: var(--lucky-gold);
  color: var(--lucky-gold);
}

.hero-stats {
  list-style: none;
  padding: 0;
  margin: 1.25rem 0 0;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 1.5rem;
  font-size: 0.85rem;
  color: var(--parchment);
}

.hero-stats strong {
  display: block;
  color: var(--lucky-gold);
  font-size: 1rem;
}

.hero-visual {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 320px;
}

.device-frame {
  padding: 1.25rem;
  background: linear-gradient(145deg, var(--jade-mid), var(--jade-dark));
  border-radius: 2rem;
  border: 2px solid rgba(255, 215, 0, 0.4);
  box-shadow: var(--shadow), 0 0 40px rgba(128, 0, 128, 0.25);
}

.device-frame img {
  border-radius: 1.5rem;
  width: min(280px, 70vw);
}

.float-envelope,
.float-gavel {
  position: absolute;
  filter: drop-shadow(0 12px 24px rgba(0, 0, 0, 0.5));
  animation: float 4.5s ease-in-out infinite;
}

.float-envelope {
  left: 0;
  bottom: 8%;
  animation-delay: -1s;
}

.float-gavel {
  right: 5%;
  top: 12%;
  animation-delay: -2.2s;
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0) rotate(-2deg);
  }
  50% {
    transform: translateY(-12px) rotate(2deg);
  }
}

.section {
  padding: 4.5rem 1.25rem;
  max-width: 72rem;
  margin: 0 auto;
}

.section-head {
  text-align: center;
  max-width: 40rem;
  margin: 0 auto 2.5rem;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}

.feature-card {
  background: linear-gradient(160deg, rgba(58, 56, 66, 0.95), rgba(43, 43, 43, 0.98));
  border: 1px solid rgba(76, 201, 240, 0.2);
  border-radius: var(--radius);
  padding: 1.25rem;
  box-shadow: var(--shadow);
}

.feature-art {
  border-radius: calc(var(--radius) - 4px);
  overflow: hidden;
  margin-bottom: 1rem;
  background: rgba(0, 0, 0, 0.25);
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.feature-art img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 0.5rem;
}

.loop-banner {
  margin-top: 2rem;
  display: flex;
  align-items: center;
  gap: 1.25rem;
  padding: 1.25rem 1.5rem;
  border-radius: var(--radius);
  background: linear-gradient(90deg, rgba(128, 0, 128, 0.35), rgba(43, 43, 43, 0.9));
  border: 1px solid rgba(255, 20, 147, 0.35);
}

.loop-banner h3 {
  margin-bottom: 0.35rem;
}

.loop-banner p {
  margin: 0;
}

.legal-card {
  background: rgba(58, 56, 66, 0.6);
  border: 1px solid rgba(255, 215, 0, 0.18);
  border-radius: var(--radius);
  padding: clamp(1.5rem, 4vw, 2.5rem);
  box-shadow: var(--shadow);
}

.legal-meta {
  font-size: 0.88rem;
  color: var(--zen-blue);
  margin-bottom: 1.5rem;
}

.legal h3 {
  margin-top: 1.75rem;
  color: var(--lucky-gold);
}

.legal ul {
  padding-left: 1.25rem;
  color: var(--parchment);
}

.support-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 2rem;
  align-items: start;
}

.support-note {
  font-size: 0.85rem;
  margin-top: 1rem;
}

.support-note code {
  background: rgba(0, 0, 0, 0.35);
  padding: 0.15rem 0.4rem;
  border-radius: 6px;
  font-size: 0.8rem;
}

.faq details {
  background: rgba(43, 43, 43, 0.85);
  border: 1px solid rgba(76, 201, 240, 0.15);
  border-radius: 12px;
  padding: 0.85rem 1rem;
  margin-bottom: 0.65rem;
}

.faq summary {
  cursor: pointer;
  font-weight: 600;
  color: var(--neko-white);
  list-style: none;
}

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

.faq summary::after {
  content: "+";
  float: right;
  color: var(--lucky-gold);
}

.faq details[open] summary::after {
  content: "−";
}

.faq details p {
  margin: 0.75rem 0 0;
  font-size: 0.95rem;
}

.site-footer {
  border-top: 1px solid rgba(255, 215, 0, 0.15);
  padding: 2rem 1.25rem 3rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
}

.site-footer img {
  border-radius: 10px;
  opacity: 0.9;
}

.site-footer p {
  margin: 0;
  font-size: 0.85rem;
}

.site-footer nav {
  display: flex;
  gap: 1.25rem;
  flex-wrap: wrap;
  justify-content: center;
}

.site-footer nav a {
  font-size: 0.85rem;
  text-decoration: none;
}

.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.65s ease, transform 0.65s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal[data-delay="1"] {
  transition-delay: 0.12s;
}

.reveal[data-delay="2"] {
  transition-delay: 0.24s;
}

@media (max-width: 900px) {
  .hero-inner {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .lead,
  .hero-stats {
    margin-left: auto;
    margin-right: auto;
  }

  .hero-actions {
    justify-content: center;
  }

  .hero-visual {
    order: -1;
    min-height: 260px;
  }

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

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

  .nav-toggle {
    display: flex;
  }

  .site-nav {
    position: absolute;
    top: calc(100% + 0.5rem);
    right: 1rem;
    left: 1rem;
    flex-direction: column;
    background: rgba(43, 43, 43, 0.98);
    border: 1px solid rgba(255, 215, 0, 0.2);
    border-radius: var(--radius);
    padding: 1rem;
    display: none;
  }

  .site-nav.is-open {
    display: flex;
  }

  .header-inner {
    position: relative;
    flex-wrap: wrap;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .float-envelope,
  .float-gavel {
    animation: none;
  }
}
