/* ============================================================
   Weckmännchen — Website
   Design tokens mirror Sources/DesignSystem/Theme.swift exactly.
   Aesthetic: warm sunrise picture-book. Rounded, buttery, cozy.
   ============================================================ */

:root {
  /* Sunrise */
  --sunrise-top: #FCE9A8;
  --sunrise-mid: #F8C89B;
  --sunrise-bottom: #F0A57E;
  /* Meerkat */
  --fur: #E3A76A;
  --fur-dark: #CB8B4E;
  --belly: #F6E7CF;
  --cheek: #F0A9A0;
  --outline: #5A3E2B;
  /* Accents */
  --nightcap: #6B9BD1;
  --nightcap-dark: #4F7FB5;
  --bell: #E5544A;
  /* Semantic */
  --card: #FFFDF8;
  --text: #3E2C1E;
  --text-2: #8A6B52;

  --radius: 22px;
  --shadow: 0 10px 24px rgba(90, 62, 43, 0.12);
  --font-display: "Baloo 2", cursive;
  --font-body: "Nunito", sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  color: var(--text);
  background: var(--belly);
  line-height: 1.6;
  overflow-x: hidden;
}

h1, h2, h3, .display {
  font-family: var(--font-display);
  line-height: 1.12;
  color: var(--outline);
  letter-spacing: -0.01em;
}

a { color: var(--nightcap-dark); }

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

.wrap {
  width: min(1080px, 92vw);
  margin-inline: auto;
}

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(252, 233, 168, 0.82);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 2px solid rgba(90, 62, 43, 0.08);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  gap: 28px;
  padding-block: 12px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  margin-right: auto;
}

.brand img {
  width: 40px;
  height: 40px;
  border-radius: 11px;
  box-shadow: 0 3px 8px rgba(90, 62, 43, 0.2);
}

.brand span {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--outline);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 22px;
}

.site-nav a {
  text-decoration: none;
  color: var(--text);
  font-weight: 700;
  font-size: 0.95rem;
}

.site-nav a:hover { color: var(--nightcap-dark); }

.pill-cta {
  background: var(--nightcap);
  color: #fff !important;
  padding: 8px 18px;
  border-radius: 999px;
  box-shadow: 0 4px 0 var(--nightcap-dark);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.pill-cta:hover {
  transform: translateY(2px);
  box-shadow: 0 2px 0 var(--nightcap-dark);
  color: #fff !important;
}

@media (max-width: 640px) {
  .site-nav a:not(.pill-cta) { display: none; }
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  background: linear-gradient(180deg, var(--sunrise-top) 0%, var(--sunrise-mid) 55%, var(--sunrise-bottom) 100%);
  padding: clamp(48px, 8vw, 96px) 0 0;
  overflow: hidden;
}

.hero .wrap {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 32px;
  align-items: center;
  position: relative;
  z-index: 2;
  padding-bottom: clamp(40px, 6vw, 80px);
}

@media (max-width: 800px) {
  .hero .wrap { grid-template-columns: 1fr; text-align: center; }
  .hero-copy { order: 2; }
  .hero-art { order: 1; }
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--nightcap);
  background-image: radial-gradient(rgba(255, 255, 255, 0.55) 1.5px, transparent 1.6px);
  background-size: 14px 14px;
  color: #fff;
  font-weight: 800;
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  padding: 7px 16px;
  border-radius: 999px;
  box-shadow: 0 3px 0 var(--nightcap-dark);
  animation: rise 0.7s ease both;
}

.hero h1 {
  font-size: clamp(2.4rem, 6vw, 4.2rem);
  font-weight: 800;
  margin: 18px 0 14px;
  animation: rise 0.7s 0.08s ease both;
}

.hero h1 .snooze {
  position: relative;
  white-space: nowrap;
  color: var(--fur-dark);
}

.hero h1 .snooze::after {
  content: "";
  position: absolute;
  left: -2%;
  right: -2%;
  top: 54%;
  height: 0.14em;
  background: var(--bell);
  border-radius: 999px;
  transform: rotate(-3deg);
  transform-origin: left center;
  animation: strike 0.5s 0.9s ease both;
}

@keyframes strike {
  from { transform: rotate(-3deg) scaleX(0); }
  to   { transform: rotate(-3deg) scaleX(1); }
}

.hero p.lead {
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  max-width: 34em;
  color: var(--text);
  animation: rise 0.7s 0.16s ease both;
}

.hero-ctas {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-top: 28px;
  animation: rise 0.7s 0.24s ease both;
}

@media (max-width: 800px) { .hero-ctas { justify-content: center; } }

.store-badge {
  display: inline-flex;
  flex-direction: column;
  line-height: 1.15;
  text-decoration: none;
  background: var(--outline);
  color: var(--belly);
  padding: 12px 26px;
  border-radius: 16px;
  box-shadow: var(--shadow);
  transition: transform 0.15s ease;
}

.store-badge:hover { transform: translateY(-2px) rotate(-1deg); }

.store-badge small { font-size: 0.72rem; opacity: 0.8; font-weight: 600; }
.store-badge strong { font-family: var(--font-display); font-size: 1.2rem; }

.hero-note { font-size: 0.85rem; color: var(--text-2); font-weight: 700; }

/* Hero art: mascot on sunrise arcs */

.hero-art {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 340px;
}

.arcs {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  pointer-events: none;
}

.arcs span {
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 253, 248, 0.22);
}

.arcs span:nth-child(1) { width: 560px; height: 560px; }
.arcs span:nth-child(2) { width: 420px; height: 420px; background: rgba(255, 253, 248, 0.26); }
.arcs span:nth-child(3) { width: 290px; height: 290px; background: rgba(255, 253, 248, 0.3); }

.hero-art img.mascot {
  width: min(320px, 70vw);
  border-radius: 36px;
  box-shadow: 0 24px 48px rgba(90, 62, 43, 0.28);
  transform: rotate(-2deg);
  animation: float 5s ease-in-out infinite;
  position: relative;
  z-index: 2;
}

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

.zzz {
  position: absolute;
  z-index: 3;
  font-family: var(--font-display);
  font-weight: 800;
  color: var(--nightcap-dark);
  opacity: 0;
  animation: drift 4s ease-in-out infinite;
}

.zzz.z1 { top: 8%;  right: 16%; font-size: 2rem;   animation-delay: 0s; }
.zzz.z2 { top: 16%; right: 8%;  font-size: 1.4rem; animation-delay: 1.3s; }
.zzz.z3 { top: 2%;  right: 26%; font-size: 1.1rem; animation-delay: 2.6s; }

@keyframes drift {
  0%   { opacity: 0; transform: translate(0, 10px) rotate(8deg); }
  30%  { opacity: 0.9; }
  100% { opacity: 0; transform: translate(18px, -34px) rotate(18deg); }
}

@keyframes rise {
  from { opacity: 0; transform: translateY(18px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Wavy divider */

.wave {
  display: block;
  width: 100%;
  height: 70px;
  margin-bottom: -1px;
}

/* ---------- Sections ---------- */

section.band { padding: clamp(56px, 8vw, 96px) 0; }

.band.cream  { background: var(--belly); }
.band.card-bg { background: var(--card); }

.kicker {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--bell);
  font-size: 1rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

section h2 {
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  margin: 6px 0 12px;
}

.section-lead { max-width: 40em; color: var(--text-2); font-weight: 600; }

/* Mission cards */

.missions {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 40px;
}

@media (max-width: 800px) { .missions { grid-template-columns: 1fr; } }

.mission {
  background: var(--card);
  border-radius: var(--radius);
  border: 2.5px solid rgba(90, 62, 43, 0.12);
  box-shadow: var(--shadow);
  padding: 28px 24px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.mission:nth-child(1) { transform: rotate(-1.3deg); }
.mission:nth-child(2) { transform: rotate(0.8deg) translateY(10px); }
.mission:nth-child(3) { transform: rotate(-0.6deg); }

.mission:hover {
  transform: rotate(0deg) translateY(-6px);
  box-shadow: 0 18px 36px rgba(90, 62, 43, 0.18);
}

.mission .icon {
  width: 64px;
  height: 64px;
  display: grid;
  place-items: center;
  font-size: 2rem;
  border-radius: 18px;
  margin-bottom: 16px;
  box-shadow: inset 0 -4px 0 rgba(90, 62, 43, 0.12);
}

.mission:nth-child(1) .icon { background: var(--sunrise-top); }
.mission:nth-child(2) .icon { background: var(--cheek); }
.mission:nth-child(3) .icon { background: var(--nightcap); }

.mission h3 { font-size: 1.35rem; margin-bottom: 6px; }
.mission p { color: var(--text-2); font-weight: 600; font-size: 0.98rem; }

/* Anti-snooze night band (nightcap world) */

.band.night {
  background: var(--nightcap);
  background-image: radial-gradient(rgba(255, 255, 255, 0.35) 2px, transparent 2.4px);
  background-size: 34px 34px;
  color: #fff;
}

.band.night h2, .band.night .kicker { color: #fff; }
.band.night .kicker { color: var(--sunrise-top); }
.band.night .section-lead { color: rgba(255, 255, 255, 0.85); }

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 40px;
  counter-reset: step;
}

@media (max-width: 800px) { .steps { grid-template-columns: 1fr; } }

.step {
  background: rgba(255, 253, 248, 0.14);
  border: 2px solid rgba(255, 253, 248, 0.35);
  border-radius: var(--radius);
  padding: 26px 22px;
  position: relative;
  backdrop-filter: blur(2px);
}

.step::before {
  counter-increment: step;
  content: counter(step);
  position: absolute;
  top: -18px;
  left: 20px;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  background: var(--bell);
  color: #fff;
  font-family: var(--font-display);
  font-weight: 800;
  border-radius: 50%;
  box-shadow: 0 3px 0 rgba(90, 62, 43, 0.35);
}

.step h3 { color: #fff; font-size: 1.2rem; margin-bottom: 6px; }
.step p { color: rgba(255, 255, 255, 0.88); font-weight: 600; font-size: 0.95rem; }

.escape-note {
  margin-top: 28px;
  font-weight: 700;
  color: var(--sunrise-top);
}

/* Streak / stats */

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}

@media (max-width: 800px) { .split { grid-template-columns: 1fr; } }

.heat {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 8px;
  padding: 26px;
  background: var(--card);
  border-radius: var(--radius);
  border: 2.5px solid rgba(90, 62, 43, 0.12);
  box-shadow: var(--shadow);
  transform: rotate(1.2deg);
}

.heat i {
  aspect-ratio: 1;
  border-radius: 8px;
  background: var(--belly);
}

.heat i.l1 { background: var(--sunrise-top); }
.heat i.l2 { background: var(--sunrise-mid); }
.heat i.l3 { background: var(--sunrise-bottom); }
.heat i.l4 { background: var(--fur-dark); }

.check-list { list-style: none; margin-top: 20px; }

.check-list li {
  padding-left: 34px;
  position: relative;
  margin-bottom: 12px;
  font-weight: 600;
  color: var(--text-2);
}

.check-list li::before {
  content: "☀️";
  position: absolute;
  left: 0;
  top: 0;
}

/* Privacy strip */

.privacy-strip {
  background: var(--card);
  border-radius: var(--radius);
  border: 2.5px solid rgba(90, 62, 43, 0.12);
  box-shadow: var(--shadow);
  padding: clamp(28px, 4vw, 44px);
  display: flex;
  gap: 24px;
  align-items: center;
}

@media (max-width: 640px) { .privacy-strip { flex-direction: column; text-align: center; } }

.privacy-strip .shield {
  font-size: 3rem;
  flex-shrink: 0;
  filter: drop-shadow(0 4px 6px rgba(90, 62, 43, 0.2));
}

.privacy-strip h2 { font-size: 1.6rem; }
.privacy-strip p { color: var(--text-2); font-weight: 600; }

/* Final CTA */

.finale {
  text-align: center;
  background: linear-gradient(180deg, var(--belly) 0%, var(--sunrise-top) 100%);
}

.finale img {
  width: 96px;
  height: 96px;
  border-radius: 24px;
  margin: 0 auto 20px;
  box-shadow: var(--shadow);
}

/* ---------- Footer ---------- */

.site-footer {
  background: var(--outline);
  color: var(--belly);
  padding: 40px 0 32px;
}

.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 18px 32px;
  align-items: center;
  justify-content: space-between;
}

.site-footer a { color: var(--sunrise-top); text-decoration: none; font-weight: 700; }
.site-footer a:hover { text-decoration: underline; }

.footer-links { display: flex; gap: 24px; flex-wrap: wrap; }

.site-footer small { opacity: 0.75; font-weight: 600; }

/* ---------- Subpages (support / legal) ---------- */

.page-hero {
  background: linear-gradient(180deg, var(--sunrise-top), var(--sunrise-mid));
  padding: clamp(40px, 6vw, 72px) 0 clamp(28px, 4vw, 48px);
}

.page-hero h1 { font-size: clamp(2rem, 5vw, 3rem); }
.page-hero p { color: var(--text); font-weight: 600; max-width: 44em; }

.page-body { padding: clamp(40px, 6vw, 72px) 0; }

.page-body .wrap { width: min(820px, 92vw); }

/* FAQ */

.faq details {
  background: var(--card);
  border: 2.5px solid rgba(90, 62, 43, 0.12);
  border-radius: 18px;
  margin-bottom: 14px;
  box-shadow: 0 4px 12px rgba(90, 62, 43, 0.07);
  overflow: hidden;
}

.faq summary {
  cursor: pointer;
  list-style: none;
  padding: 18px 22px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.08rem;
  color: var(--outline);
  position: relative;
  padding-right: 52px;
}

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

.faq summary::after {
  content: "+";
  position: absolute;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  background: var(--sunrise-top);
  border-radius: 50%;
  font-weight: 800;
  color: var(--outline);
  transition: transform 0.2s ease, background 0.2s ease;
}

.faq details[open] summary::after {
  content: "–";
  background: var(--nightcap);
  color: #fff;
}

.faq details > div {
  padding: 0 22px 20px;
  color: var(--text-2);
  font-weight: 600;
}

.contact-card {
  margin-top: 40px;
  background: var(--nightcap);
  background-image: radial-gradient(rgba(255, 255, 255, 0.3) 2px, transparent 2.4px);
  background-size: 30px 30px;
  border-radius: var(--radius);
  color: #fff;
  padding: 32px;
  text-align: center;
  box-shadow: var(--shadow);
}

.contact-card h2 { color: #fff; margin-bottom: 8px; }

.contact-card a.mail {
  display: inline-block;
  margin-top: 14px;
  background: var(--card);
  color: var(--outline);
  font-family: var(--font-display);
  font-weight: 700;
  text-decoration: none;
  padding: 12px 28px;
  border-radius: 999px;
  box-shadow: 0 4px 0 rgba(90, 62, 43, 0.3);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.contact-card a.mail:hover {
  transform: translateY(2px);
  box-shadow: 0 2px 0 rgba(90, 62, 43, 0.3);
}

/* Legal text */

.legal h2 {
  font-size: 1.4rem;
  margin: 36px 0 10px;
}

.legal h3 { font-size: 1.1rem; margin: 22px 0 6px; }

.legal p, .legal li { color: var(--text); font-weight: 500; margin-bottom: 10px; }

.legal ul { padding-left: 24px; }

.legal .highlight {
  background: var(--card);
  border: 2.5px solid var(--nightcap);
  border-radius: 18px;
  padding: 20px 24px;
  margin: 20px 0;
  font-weight: 700;
}

.legal address { font-style: normal; }

/* Reduced motion */

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