/* zweitaps – landing styles (04.09.2026 redesign, hero reflow 04.09. evening)
   Tokens first, then page sections top to bottom, legal pages at the end.
   No external resources (CSP), system font stack only. */

:root {
  --paper: #f7f5f0;        /* page ground, warm off-white */
  --paper-2: #ffffff;
  --band-a: #f3f5ee;       /* hero / steps band, off-white with a green tint */
  --band-b: #e5ede3;
  --ink: #1a1c1a;
  --ink-2: #4a504c;
  --ink-3: #636b65;
  --line: #e3e1d9;
  --green: #2f7d5b;        /* accent from the app (src/theme.ts) */
  --green-deep: #256548;   /* hover and small green text (AA on the bands) */
  --green-soft: #e3efe7;
  --clay: #9e4524;         /* warm terracotta from the plates, small labels only */
  --clay-soft: #f6e9e2;
  --danger: #b4322d;
  --radius: 16px;
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  /* hero stage: the phone sits left of centre (--phone-x), plates pass fully visible on its right */
  --phone-w: 150px;
  --phone-x: 26%;
  --plate: 160px;
  --plate-gap: 14px;
  --stage-h: 340px;
  --stage-fade: 5%;
  --phone-shadow: 0 26px 44px -22px rgba(20, 30, 22, .5), 0 8px 18px -10px rgba(20, 30, 22, .3);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.5;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
a { color: var(--green-deep); text-underline-offset: 3px; }
a:hover { color: var(--green); }
h1, h2, h3 { line-height: 1.1; letter-spacing: -0.02em; margin: 0; text-wrap: balance; }
p { margin: 0; }
img { max-width: 100%; display: block; }
:focus-visible { outline: 3px solid var(--green); outline-offset: 3px; }

.wrap { width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 20px; }

/* Header ------------------------------------------------------------- */
.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 0 8px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-weight: 800;
  font-size: 21px;
  letter-spacing: -0.03em;
  color: var(--green-deep);
  text-decoration: none;
}
.brand .mark {
  width: 22px; height: 22px;
  border-radius: 7px;
  background: var(--green);
  display: inline-grid;
  place-items: center;
  grid-auto-flow: column;
  gap: 3px;
}
.brand .mark i { width: 5px; height: 5px; border-radius: 50%; background: #fff; }
.tag {
  font-size: 13px;
  font-weight: 600;
  color: var(--clay);
  border: 1px solid #ead7cb;
  background: var(--clay-soft);
  border-radius: 999px;
  padding: 5px 12px;
  white-space: nowrap;
}

/* Hero band ---------------------------------------------------------- */
.hero-band {
  background: linear-gradient(180deg, var(--band-a) 0%, var(--band-b) 100%);
  border-bottom: 1px solid #dbe4d8;
  overflow: hidden;
}
/* Mobile order: headline + sub, then the stage, then qualifier / lead / CTA.
   From 900 px: text left (vertically centred by the two 1fr rows), stage right. */
.hero {
  display: grid;
  grid-template-areas: "head" "visual" "rest";
  padding: 14px 0 0;
}
.hero-head { grid-area: head; padding: 6px 0 4px; }
.hero-visual { grid-area: visual; }
.hero-rest { grid-area: rest; padding: 2px 0 26px; }
.hero h1 {
  font-size: clamp(40px, 10vw, 62px);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1.02;
}
.hero .sub {
  margin-top: 14px;
  text-wrap: balance;
  font-size: clamp(18px, 4.6vw, 22px);
  font-weight: 650;
  color: var(--green-deep);
  letter-spacing: -0.01em;
}
.hero .qualifier {
  margin-top: 12px;
  font-size: 16px;
  color: var(--ink-3);
  max-width: 44ch;
}
.hero .lead {
  margin-top: 16px;
  font-size: 17px;
  color: var(--ink-2);
  max-width: 44ch;
}
.cta-row {
  margin-top: 24px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
}
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font: inherit;
  font-weight: 650;
  font-size: 17px;
  color: #fff;
  background: var(--green);
  border: 0;
  border-radius: 14px;
  padding: 14px 24px;
  text-decoration: none;
  cursor: pointer;
  min-height: 50px;
  box-shadow: 0 8px 20px -10px rgba(47, 125, 91, .8);
  transition: background .15s ease, transform .05s ease;
}
.btn:hover { background: var(--green-deep); color: #fff; }
.btn:active { transform: translateY(1px); }
.btn[disabled] { opacity: .6; cursor: default; }
.cta-note { font-size: 14px; color: var(--ink-3); }

/* Stage: plates sliding behind a phone --------------------------------- */
.stage {
  position: relative;
  height: var(--stage-h);
  margin: 0 -20px;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 var(--stage-fade), #000 calc(100% - var(--stage-fade)), transparent);
  mask-image: linear-gradient(90deg, transparent, #000 var(--stage-fade), #000 calc(100% - var(--stage-fade)), transparent);
}
.track {
  position: absolute;
  top: 50%;
  left: 0;
  display: flex;
  width: max-content;
  transform: translateY(-50%);
  animation: slide 28s linear infinite;
  will-change: transform;
}
.stage:hover .track { animation-play-state: paused; }
.plate {
  flex: 0 0 auto;
  width: var(--plate);
  height: var(--plate);
  margin-right: var(--plate-gap);
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 24px 40px -22px rgba(70, 45, 20, .45), 0 2px 6px rgba(70, 45, 20, .08);
  background: #ece7dd;
}
.plate img { width: 100%; height: 100%; object-fit: cover; }
@keyframes slide {
  from { transform: translate(0, -50%); }
  to   { transform: translate(-50%, -50%); }
}

/* Phone frame (also used small in the steps strip) */
.phone {
  position: absolute;
  left: var(--phone-x);
  top: 50%;
  transform: translate(-50%, -50%);
  width: var(--phone-w);
  background: #141614;
  border-radius: 13.5%/6.2%;
  padding: 3.4%;
  box-shadow: var(--phone-shadow), inset 0 0 0 1.5px rgba(255, 255, 255, .12);
}
.screen {
  position: relative;
  aspect-ratio: 1206 / 2622;
  border-radius: 10.8%/5%;
  overflow: hidden;
  background: #fff;
  container-type: inline-size;
}
.screen > img { width: 100%; height: 100%; object-fit: cover; }

/* Live part of the home screen: covers the date line, the kcal number and the
   list in the screenshot (14.9 %..87 % of the screen height) and redraws them in
   HTML. The date is covered so the hero never shows a stale day. */
.live {
  position: absolute;
  left: 0; right: 0;
  top: 14.9%; bottom: 13%;
  background: #fff;
  padding: 0 4.6%;
  color: #111;
  font-family: var(--font);
  overflow: hidden;
}
.live .total {
  margin-top: 12.3cqw;
  display: flex;
  align-items: baseline;
  gap: 1.6cqw;
  line-height: 1;
}
.live .total b {
  font-size: 15.4cqw;
  font-weight: 800;
  letter-spacing: -0.045em;
  color: var(--green);
  font-variant-numeric: tabular-nums;
}
.live .total span { font-size: 5cqw; color: #6e6e73; font-weight: 500; }
.live .goal { margin-top: 2.4cqw; font-size: 3.65cqw; color: #6e6e73; font-variant-numeric: tabular-nums; }
.live .bar { margin-top: 3.6cqw; height: 1.4cqw; border-radius: 999px; background: #e5e5ea; overflow: hidden; }
.live .bar i { display: block; height: 100%; width: 40%; background: var(--green); border-radius: 999px; transition: width .7s cubic-bezier(.2, .7, .2, 1); }
.live .group {
  margin-top: 7cqw;
  display: flex;
  justify-content: space-between;
  font-size: 2.7cqw;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: #6e6e73;
  padding-bottom: 2.4cqw;
  border-bottom: 1px solid #e5e5ea;
  font-variant-numeric: tabular-nums;
}
.live .rows { display: flex; flex-direction: column; margin: 0; padding: 0; list-style: none; }
.live .row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 3cqw;
  padding: 3.2cqw 0;
  border-bottom: 1px solid #e5e5ea;
  font-size: 3.65cqw;
  line-height: 1.25;
}
.live .row .n { font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.live .row .m { display: block; color: #6e6e73; font-size: 2.8cqw; margin-top: .6cqw; }
.live .row .k { color: #111; white-space: nowrap; font-variant-numeric: tabular-nums; }
.live .row.in { animation: rowin .45s cubic-bezier(.2, .7, .2, 1) both; background: linear-gradient(90deg, var(--green-soft), transparent 70%); margin: 0 -4.6%; padding-left: 4.6%; padding-right: 4.6%; }
@keyframes rowin {
  from { opacity: 0; transform: translateY(-40%); }
  to   { opacity: 1; transform: none; }
}
.tick { display: inline-block; }
.tick.bump { animation: bump .5s ease-out; }
@keyframes bump {
  30% { transform: scale(1.04); }
  100% { transform: none; }
}
.stage-caption {
  text-align: center;
  font-size: 14px;
  color: var(--ink-3);
  padding: 6px 0 14px;
}

@media (min-width: 560px) {
  :root {
    --phone-w: 240px; --phone-x: 34%; --plate: 170px; --plate-gap: 20px; --stage-h: 560px; --stage-fade: 6%;
    --phone-shadow: 0 40px 70px -28px rgba(20, 30, 22, .55), 0 12px 26px -12px rgba(20, 30, 22, .35);
  }
}
@media (min-width: 900px) {
  :root {
    --phone-w: 280px; --phone-x: 36%; --plate: 180px; --plate-gap: 22px; --stage-h: 680px; --stage-fade: 5%;
    --phone-shadow: 0 50px 90px -30px rgba(20, 30, 22, .55), 0 14px 30px -14px rgba(20, 30, 22, .35);
  }
  .hero {
    grid-template-columns: 6fr 6fr;
    grid-template-rows: 1fr auto auto 1fr;
    grid-template-areas: ". visual" "head visual" "rest visual" ". visual";
    column-gap: 32px;
    padding: 0;
  }
  .hero-head, .hero-rest { padding: 0; }
  .hero-visual { padding: 20px 0 28px; }
  /* The stage runs to the right edge of the viewport so the plates get the whole right side of the band. */
  .stage { margin: 0 calc(-1 * max(20px, (100vw - 1080px) / 2)) 0 0; }
  .stage-caption { display: none; }
  .hero-band { border-bottom: 0; }
}

/* Sections ------------------------------------------------------------ */
section { padding: 64px 0; }
.eyebrow {
  font-size: 12.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--clay);
  margin-bottom: 12px;
}
h2 {
  font-size: clamp(28px, 5.4vw, 40px);
  font-weight: 800;
  letter-spacing: -0.03em;
  max-width: 24ch;
}
.section-intro { margin-top: 14px; color: var(--ink-2); max-width: 58ch; }

/* Warum: quotes */
.quotes {
  margin-top: 36px;
  display: grid;
  gap: 28px 40px;
}
@media (min-width: 700px) { .quotes { grid-template-columns: 1fr 1fr; } }
.quote {
  margin: 0;
  padding-left: 22px;
  border-left: 3px solid var(--green-soft);
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.quote p { font-size: 19px; line-height: 1.4; letter-spacing: -0.005em; color: var(--ink); }
.quote p::before { content: "„"; color: var(--clay); }
.quote p::after { content: "“"; color: var(--clay); }
.quote cite { font-style: normal; font-size: 13.5px; color: var(--ink-3); }

/* Drin / nicht drin */
.split {
  margin-top: 32px;
  display: grid;
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
@media (min-width: 700px) { .split { grid-template-columns: 1fr 1fr; } }
.col { padding: 24px 24px 26px; }
.col + .col { border-top: 1px solid var(--line); }
@media (min-width: 700px) { .col + .col { border-top: 0; border-left: 1px solid var(--line); } }
.col h3 { font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--green-deep); margin-bottom: 14px; }
.col.no h3 { color: var(--clay); }
.col ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.col li { display: flex; gap: 12px; align-items: flex-start; color: var(--ink-2); }
.col li::before {
  content: "";
  flex: 0 0 auto;
  width: 20px; height: 20px;
  margin-top: 3px;
  border-radius: 50%;
  background: var(--green-soft) center / 11px no-repeat;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'><path d='M2 6.5l2.6 2.5L10 3.5' fill='none' stroke='%23256548' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'/></svg>");
}
.col.no li::before {
  background-color: var(--clay-soft);
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'><path d='M3 3l6 6M9 3l-6 6' fill='none' stroke='%239e4524' stroke-width='1.9' stroke-linecap='round'/></svg>");
}

/* Steps strip: Öffnen. Tippen. Fertig. ------------------------------- */
.steps-band {
  background: linear-gradient(180deg, var(--band-b) 0%, var(--band-a) 100%);
  border-top: 1px solid #dbe4d8;
  border-bottom: 1px solid #dbe4d8;
}
.steps-band h2 { max-width: none; }
.steps {
  margin: 36px -20px 0;
  padding: 10px 20px 8px;
  display: flex;
  gap: 22px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.steps::-webkit-scrollbar { display: none; }
.step {
  flex: 0 0 min(72vw, 250px);
  scroll-snap-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
}
.step .phone { position: relative; left: auto; top: auto; transform: none; width: 100%; }
.step figcaption { text-align: center; max-width: 26ch; }
.step figcaption b { display: block; font-size: 20px; font-weight: 800; letter-spacing: -0.02em; color: var(--ink); }
.step figcaption span { display: block; font-size: 15px; color: var(--ink-2); margin-top: 4px; }
.tap {
  position: absolute;
  width: 11%;
  aspect-ratio: 1;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: var(--clay);
  color: #fff;
  font-weight: 800;
  font-size: 5cqw;
  display: grid;
  place-items: center;
  box-shadow: 0 0 0 3px #fff, 0 6px 14px -4px rgba(0,0,0,.4);
  z-index: 2;
}
.tap::after {
  content: "";
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 2px solid var(--clay);
  animation: pulse 1.8s ease-out infinite;
}
@keyframes pulse {
  0% { transform: scale(.7); opacity: .9; }
  100% { transform: scale(1.7); opacity: 0; }
}
/* Positions in percent of the screen: plus button, the Apfel row in Zuletzt, the new Apfel row on Heute */
.tap.t1 { left: 41%; top: 91.3%; }
.tap.t2 { left: 52%; top: 58%; }
.tap.t3 { left: 70%; top: 74%; }
.tap.done { background: var(--green); width: 12%; }
.tap.done::after { display: none; }
.tap.done svg { width: 55%; height: 55%; }
@media (min-width: 820px) {
  .steps { margin: 40px 0 0; padding: 0; overflow: visible; justify-content: center; gap: 40px; }
  .step { flex: 0 1 260px; }
}

/* Form ---------------------------------------------------------------- */
.signup {
  margin-top: 30px;
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px 20px;
  max-width: 580px;
  box-shadow: 0 20px 40px -30px rgba(40, 60, 45, .3);
}
@media (min-width: 700px) { .signup { padding: 32px 34px; } }
.field { display: flex; flex-direction: column; gap: 7px; margin-bottom: 18px; border: 0; padding: 0; min-width: 0; }
.field label, .field .lbl { font-weight: 600; font-size: 15px; padding: 0; }
.field .opt { font-weight: 400; color: var(--ink-3); }
input[type="email"], textarea {
  font: inherit;
  font-size: 17px;
  color: var(--ink);
  background: #fff;
  border: 1px solid #cdc9bf;
  border-radius: 12px;
  padding: 12px 14px;
  width: 100%;
  min-height: 50px;
}
textarea { min-height: 100px; resize: vertical; }
input:focus, textarea:focus {
  outline: none;
  border-color: var(--green);
  box-shadow: 0 0 0 3px var(--green-soft);
}
.radios { display: flex; flex-wrap: wrap; gap: 8px; }
.radios label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid #cdc9bf;
  border-radius: 999px;
  padding: 9px 15px;
  cursor: pointer;
  font-weight: 500;
  font-size: 15px;
  background: #fff;
  min-height: 44px;
}
.radios input { accent-color: var(--green); margin: 0; width: 16px; height: 16px; }
.radios label:has(input:checked) { border-color: var(--green); background: var(--green-soft); }
.hp { position: absolute; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; opacity: 0; }
.form-foot { margin-top: 12px; font-size: 14px; color: var(--ink-3); }
.msg { margin-top: 14px; font-size: 15px; }
.msg.err { color: var(--danger); }
.thanks { padding: 8px 0; }
.thanks h3 { font-size: 22px; font-weight: 800; letter-spacing: -0.02em; margin-bottom: 8px; }
.thanks p { color: var(--ink-2); }

/* Footer -------------------------------------------------------------- */
footer {
  border-top: 1px solid var(--line);
  padding: 26px 0 44px;
  font-size: 14px;
  color: var(--ink-3);
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  justify-content: space-between;
}
footer nav { display: flex; flex-wrap: wrap; gap: 18px; }
footer a { color: var(--ink-2); }

/* Legal pages --------------------------------------------------------- */
.legal { max-width: 680px; margin: 0 auto; padding: 32px 20px 64px; }
.legal h1 { font-size: 32px; font-weight: 800; letter-spacing: -0.025em; margin-bottom: 18px; }
.legal h2 { font-size: 20px; margin: 28px 0 8px; max-width: none; }
.legal p { margin: 0 0 12px; color: var(--ink-2); }
.legal .back { display: inline-block; margin-bottom: 26px; font-size: 15px; }
.legal ul { margin: 0 0 12px; padding-left: 22px; color: var(--ink-2); }
.legal li { margin-bottom: 6px; }
.legal .stand { font-size: 14px; color: var(--ink-3); margin-top: 28px; }
.legal-page { max-width: 680px; margin: 0 auto; padding: 0 20px; }
.legal-page .legal { padding-left: 0; padding-right: 0; }

/* Motion off ---------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn { transition: none; }
  .track { animation: none; transform: translate(-25%, -50%); }
  .live .row.in { animation: none; background: none; margin: 0; padding-left: 0; padding-right: 0; }
  .live .bar i { transition: none; }
  .tick.bump { animation: none; }
  .tap::after { animation: none; transform: scale(1.3); opacity: .6; }
}
