/* === Variables === */
:root {
  --ink: #101521;
  --muted: #4a5a6b;
  --cream: #e7f4fb;
  --sun: #c9f36b;
  --coral: #3fb8ff;
  --mint: #5ee6cf;
  --ink-strong: #0b0f1a;
  --card: rgba(255, 255, 255, 0.75);
  --line: rgba(17, 16, 23, 0.12);
}

/* === Reset === */
* { box-sizing: border-box; }

/* === Base === */
body {
  margin: 0;
  font-family: "Bricolage Grotesque", "Segoe UI", sans-serif;
  color: var(--ink);
  background: radial-gradient(circle at 10% 10%, rgba(63, 184, 255, 0.28), transparent 45%),
    radial-gradient(circle at 90% 0%, rgba(201, 243, 107, 0.3), transparent 40%),
    repeating-linear-gradient(135deg, rgba(16, 21, 33, 0.04) 0px, rgba(16, 21, 33, 0.04) 2px, transparent 2px, transparent 8px),
    var(--cream);
  min-height: 100vh;
}
.wrap {
  max-width: 1280px;
  margin: 0 auto;
  padding: 36px 6vw 80px;
}
header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
h1 {
  font-family: "DM Serif Display", "Times New Roman", serif;
  font-size: clamp(2.8rem, 5vw, 4.8rem);
  line-height: 1.03;
  margin: 16px 0;
}
h1 span { color: var(--coral); }
h2 {
  margin: 28px 0 10px;
  font-size: 1.15rem;
}
p {
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.7;
  margin: 0 0 18px;
}
ul { padding-left: 20px; color: var(--muted); }
a { color: var(--ink-strong); }
.meta { color: var(--muted); font-size: 0.95rem; }

/* === Legal pages === */
body.page-legal {
  background: radial-gradient(circle at 10% 10%, rgba(63, 184, 255, 0.18), transparent 45%),
    radial-gradient(circle at 90% 0%, rgba(201, 243, 107, 0.2), transparent 40%),
    repeating-linear-gradient(135deg, rgba(16, 21, 33, 0.04) 0px, rgba(16, 21, 33, 0.04) 2px, transparent 2px, transparent 8px),
    var(--cream);
}
body.page-legal .wrap {
  max-width: 1080px;
  padding: 48px 6vw 80px;
}
body.page-legal header {
  align-items: baseline;
  gap: 16px;
  margin-bottom: 22px;
}
body.page-legal h1 {
  margin: 0;
  font-size: clamp(2rem, 4vw, 3rem);
}
.paper {
  background: #fff;
  border: 3px solid var(--ink-strong);
  border-radius: 22px;
  padding: 28px;
  box-shadow: 12px 14px 0 rgba(11, 15, 26, 0.16);
  position: relative;
}
.paper::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 6px;
  border-radius: 18px 18px 0 0;
  background: linear-gradient(90deg, var(--coral), var(--sun));
}

/* === Index: Logo & Nav === */
.logo {
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  color: inherit;
}
.logo img {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  border: 2px solid var(--ink-strong);
  background: #fff;
}
.logo span {
  font-family: "DM Serif Display", "Times New Roman", serif;
  font-size: 26px;
}
nav a {
  color: var(--ink);
  text-decoration: none;
  margin-left: 18px;
  font-weight: 600;
}
nav a:last-child {
  padding: 10px 18px;
  background: var(--ink-strong);
  color: #fff;
  border-radius: 999px;
}

/* === Index: Hero === */
.hero {
  margin-top: 40px;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: 36px;
  align-items: center;
}
.tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid var(--line);
  font-size: 0.9rem;
}
.cta {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 16px;
}
.purchase {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
  margin-top: 14px;
}
.consent {
  margin-top: 14px;
  font-size: 0.95rem;
  color: var(--muted);
}
.consent label {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}
.consent .hint {
  display: block;
  font-size: 0.85rem;
  color: var(--ink-strong);
  margin-top: 4px;
}
.consent input { margin-top: 4px; }
.buy-disabled {
  opacity: 0.55;
  pointer-events: none;
}

/* === Index: Buttons === */
.btn {
  padding: 14px 22px;
  border-radius: 12px;
  text-decoration: none;
  font-weight: 700;
  border: 2px solid var(--ink-strong);
  color: var(--ink-strong);
  background: #fff;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.btn.primary {
  background: var(--sun);
  box-shadow: 6px 6px 0 var(--ink-strong);
}
.btn.ghost {
  background: #fff;
}
.btn:hover { transform: translate(-2px, -2px); }

/* === Index: Stat box === */
.stat {
  display: grid;
  gap: 14px;
  padding: 24px;
  border: 3px solid var(--ink-strong);
  border-radius: 20px;
  background: linear-gradient(140deg, rgba(63, 184, 255, 0.2), rgba(201, 243, 107, 0.2));
  box-shadow: 14px 16px 0 rgba(11, 15, 26, 0.22);
}
.stat h3 {
  margin: 0;
  font-size: 1.3rem;
}
.pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 999px;
  border: 1px dashed var(--ink-strong);
  color: var(--ink-strong);
  font-weight: 600;
  background: rgba(255, 255, 255, 0.8);
}

/* === Index: Card grid === */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 18px;
  margin-top: 50px;
}
.card {
  padding: 20px;
  border-radius: 18px;
  border: 3px solid var(--ink-strong);
  background: #ffffff;
  box-shadow: 10px 12px 0 rgba(11, 15, 26, 0.16);
  position: relative;
}
.card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 6px;
  border-radius: 14px 14px 0 0;
  background: linear-gradient(90deg, var(--coral), var(--sun));
}
.card h4 { margin: 0 0 10px; }
.price {
  font-size: 2.4rem;
  font-weight: 700;
  margin: 10px 0 6px;
}

/* === Index: Strip CTA === */
.strip {
  margin-top: 50px;
  padding: 26px;
  border-radius: 20px;
  background: var(--ink-strong);
  color: #fff;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}
.strip a {
  background: #fff;
  color: var(--ink-strong);
  border: none;
  padding: 12px 20px;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 700;
}

/* === Index: Footer === */
footer {
  margin-top: 50px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.95rem;
}

/* === Index: Decorative floats === */
.float {
  position: absolute;
  width: 140px;
  height: 140px;
  border-radius: 32px;
  background: rgba(255, 93, 87, 0.2);
  transform: rotate(15deg);
  filter: blur(0.5px);
  z-index: -1;
}
.float.one { top: 120px; right: 8%; }
.float.two { bottom: 80px; left: 6%; background: rgba(47, 215, 184, 0.25); }

/* === Index: Reveal animation === */
.reveal {
  opacity: 0;
  transform: translateY(14px);
  animation: rise 0.7s ease forwards;
}
@keyframes rise { to { opacity: 1; transform: translateY(0); } }

/* Animation delays — scoped by structural position */
header.reveal                    { animation-delay: 0.05s; }
.hero > .reveal:first-child      { animation-delay: 0.12s; }
.hero > .reveal:last-child       { animation-delay: 0.22s; }
.hero + .grid .card:nth-child(1) { animation-delay: 0.32s; }
.hero + .grid .card:nth-child(2) { animation-delay: 0.42s; }
.hero + .grid .card:nth-child(3) { animation-delay: 0.52s; }
.grid + .grid .card:nth-child(1) { animation-delay: 0.62s; }
.grid + .grid .card:nth-child(2) { animation-delay: 0.72s; }
.grid + .grid .card:nth-child(3) { animation-delay: 0.82s; }
.strip.reveal                    { animation-delay: 0.9s; }
footer.reveal                    { animation-delay: 0.98s; }

/* === Responsive === */
@media (max-width: 900px) {
  header { flex-direction: column; align-items: flex-start; }
  nav a { margin-left: 0; margin-right: 12px; }
  .hero { grid-template-columns: 1fr; }
  .strip { flex-direction: column; align-items: flex-start; }
}
