/* Postwerk – Landingpage.
   Gestaltung nach postwerk-design-paket/postwerk-landingpage.html, Abstände auf dem 4-px-Raster
   und mit mehr Weißraum (Sektionen 112 px, mobil 64 px). */

:root {
  --ink: #202423;
  --muted: #555e5b;
  --paper: #f3f4f3;
  --teal: #087c70;
  --line: #dfe4e1;
  --shadow: 0 3px 3px #2029240a, 0 13px 30px #2029240a;
  --ease: cubic-bezier(.22, 1, .36, 1);
  --mono: ui-monospace, "SF Mono", Menlo, monospace;

  --section: 112px;
  --gap: 24px;
}

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

/* Gescrollt wird das Dokument; body hat keine Overflow-Sperre. */
html {
  overflow-y: auto;
  background: #e9ebe9;
  scroll-behavior: smooth;
  /* Platz für das klebende Menü bei Sprungzielen */
  scroll-padding-top: 96px;
}

body {
  --frame-radius: 40px;
  margin: clamp(16px, 5vw, 72px) auto;
  width: min(1330px, calc(100% - clamp(20px, 9vw, 144px)));
  background: #e9ebe9;
  color: var(--ink);
  border: 6px solid #fff;
  border-radius: var(--frame-radius);
  box-shadow: 0 5px 6px #28393414, 0 28px 64px #28393412;
  font: 16px/1.6 system-ui, sans-serif;
}

a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }

a:focus-visible,
button:focus-visible,
summary:focus-visible {
  outline: 3px solid var(--teal);
  outline-offset: 4px;
}

h1, h2, h3, p { margin: 0; }
h1, h2, h3 { line-height: 1.08; }
h2 { font-size: clamp(34px, 5vw, 56px); letter-spacing: -.04em; }
h3 { font-size: 22px; letter-spacing: -.02em; }
p { color: var(--muted); }

code { font-family: var(--mono); font-size: .9em; }

/* Signatur: Tasten und Befehle als kleine Kappen. */
kbd {
  display: inline-block;
  min-width: 24px;
  padding: 0 6px;
  border: 1px solid var(--line);
  border-bottom-width: 2px;
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
  font: 500 13px/20px var(--mono);
  text-align: center;
}

/* Header und Footer runden den Rahmen selbst ab. */
header, main, footer { background: var(--paper); }
header { border-radius: var(--frame-radius) var(--frame-radius) 0 0; }
footer { border-radius: 0 0 var(--frame-radius) var(--frame-radius); }

.wrap {
  width: min(1050px, calc(100% - 48px));
  margin-inline: auto;
}

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

.hero {
  position: relative;
  /* 74 px: Platz für das Menü, das über dem Header liegt (24 Abstand + 50 Höhe) */
  padding: 74px 0 112px;
  text-align: center;
  background: radial-gradient(ellipse at 50% 40%, #fff7, transparent 58%), var(--paper);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0 8%;
  border-inline: 1px solid #dce1de;
  pointer-events: none;
}

.hero > * { position: relative; }

/* Das Menü steht direkt im body und klebt beim Scrollen oben. Der negative Außenabstand legt es
   über den Header, so sieht es aus wie vorher im Hero. */
.nav {
  position: sticky;
  top: 16px;
  z-index: 20;
  box-sizing: border-box;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  width: max-content;
  max-width: calc(100% - 32px);
  margin: 24px auto -74px;
  padding: 6px 6px 6px 12px;
  background: #fff;
  border: 1px solid #fff;
  border-radius: 14px;
  box-shadow: var(--shadow);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 18px;
  letter-spacing: -.02em;
}

.logo { width: 24px; height: 24px; flex: none; }
.logo rect { fill: #222927; }
.logo path { fill: none; stroke: #fff; stroke-width: 1.5; stroke-linejoin: round; }

.navlinks { display: flex; gap: 20px; font-size: 14px; }
.navlinks a, footer nav a, .mobile-nav a { transition: color 150ms var(--ease); }
.navlinks a:hover { color: var(--teal); }

.mobile-nav { display: none; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 20px;
  border: 1px solid #08786b;
  border-radius: 10px;
  /* Oberer Verlaufston abgedunkelt (Referenz #159588), damit weiße Schrift überall 4,5:1 erreicht. */
  background: linear-gradient(#0d8276, #08786c);
  color: #fff;
  font-weight: 600;
  font-size: 15px;
  box-shadow: inset 0 1px 0 #ffffff60, var(--shadow);
  transition: filter 150ms var(--ease), transform 150ms var(--ease);
}

.btn:hover { filter: brightness(1.09); }
.btn:active { transform: scale(.98); }
.btn.ghost { background: #fff; border-color: #e0e4e1; color: #27322e; }
.btn-small { min-height: 36px; padding: 0 16px; font-size: 14px; }

.intro { padding: 120px 0 96px; }

.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid #d8dfdc;
  background: #ffffff80;
  padding: 4px 12px 4px 4px;
  border-radius: 100px;
  font-size: 13px;
  color: #3f4a46;
}

.pill b {
  background: #29332f;
  color: #fff;
  border-radius: 100px;
  padding: 0 8px;
  font-weight: 600;
}

.intro h1 {
  font-size: clamp(36px, 6.2vw, 84px);
  line-height: 1.04;
  letter-spacing: -.07em;
  margin: 32px auto 32px;
}

.intro h1 span {
  display: inline-block;
  padding: 0 .15em .07em;
  border: 1px solid #c5e3dd;
  border-radius: .25em;
  color: #08796e;
  background: linear-gradient(#eaf8f5, #d8ece7);
  box-shadow: inset 0 1px 3px #348c7a18;
}

.intro p { max-width: 600px; margin: auto; font-size: 18px; line-height: 1.65; }

.actions {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-top: 40px;
  flex-wrap: wrap;
}

.hero-cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 32px;
  max-width: 960px;
  margin: 0 auto;
  text-align: left;
  align-items: center;
}

.hero-card {
  border: 4px solid #fff;
  border-radius: 32px;
  overflow: hidden;
  padding-bottom: 28px;
  background: linear-gradient(150deg, #e8ecea, #f8f9f8);
  box-shadow: var(--shadow);
}

.hero-card:first-child { transform: rotate(-4deg); }
.hero-card:last-child { transform: rotate(4deg); }
.hero-card h2, .hero-card p { margin-inline: 24px; }
.hero-card h2 { margin-top: 8px; font-size: 21px; letter-spacing: -.02em; }
.hero-card p { margin-top: 8px; font-size: 15px; }

.card-art {
  position: relative;
  height: 152px;
  display: grid;
  align-content: center;
  gap: 8px;
  padding: 16px 20px;
  background: radial-gradient(ellipse at center, #ffffffb0, transparent 75%);
}

/* Glanzmoment: die gesperrte Versandkarte trägt als einzige eine warme Tönung. */
.art-alert { background: radial-gradient(ellipse at center, #f6e4dc, transparent 75%); }

.art-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  background: #fff;
  padding: 8px 12px;
  border-radius: 10px;
  box-shadow: var(--shadow);
}

.art-row b { color: var(--teal); white-space: nowrap; }
.art-dns .art-row:nth-child(2) { margin-left: 16px; }
.art-dns .art-row:nth-child(3) { margin-left: 32px; }

.art-warn { background: #fff6f2; box-shadow: inset 0 0 0 1px #f1d3c6, var(--shadow); color: #7a2e17; font-weight: 600; }
.art-warn b { color: #a63c1d; font-weight: 600; }

/* ---------- Technikstreifen ---------- */

.stack { border-block: 1px solid var(--line); text-align: center; padding: 80px 0; }
.stack h2 { font-size: 28px; letter-spacing: -.03em; }
.stack p { margin: 12px auto 32px; max-width: 600px; }
.stack-list { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; }

.stack-list span {
  padding: 8px 16px;
  background: #fff;
  border-radius: 10px;
  box-shadow: var(--shadow);
  font-weight: 600;
}

/* ---------- Abschnitte ---------- */

.section { padding: var(--section) 0; }
.section + .section { padding-top: 0; }
.heading { max-width: 880px; margin-bottom: 48px; }
.heading p { max-width: 640px; margin-top: 16px; font-size: 17px; }
.heading.center p { margin-inline: auto; }
.center { text-align: center; margin-inline: auto; }

.panel {
  padding: clamp(24px, 5vw, 56px);
  border: 2px solid #fff;
  border-radius: 32px;
  background: linear-gradient(145deg, #e8efec, #f8faf9);
  box-shadow: var(--shadow);
}

.grid, .split { display: grid; gap: var(--gap); }
.grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.split { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 48px; align-items: center; }
.split-top { gap: var(--gap); align-items: stretch; }

.card {
  padding: 28px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: var(--shadow);
}

.card p { margin-top: 12px; }
.split p, .split ul { margin-top: 16px; }
.split ul { display: grid; gap: 8px; padding-left: 20px; color: var(--muted); }

.sample {
  margin-top: 20px;
  padding: 8px 12px;
  border-radius: 8px;
  background: #eff4f1;
  font-size: 14px;
}

/* ---------- Produktfenster ---------- */

.window {
  border: 2px solid #fff;
  border-radius: 20px;
  background: #fff;
  overflow: hidden;
  box-shadow: var(--shadow);
  text-align: left;
}

.titlebar {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--line);
  font-size: 13px;
  color: var(--muted);
}

.dots { letter-spacing: 3px; color: var(--teal); }

.app { display: grid; grid-template-columns: 168px minmax(0, 1fr); min-height: 288px; }
.sidebar { padding: 12px; background: #eef3f0; border-right: 1px solid var(--line); }
.tabs { display: grid; gap: 4px; }

.tabs button {
  padding: 8px 12px;
  text-align: left;
  background: none;
  border: 0;
  border-radius: 8px;
  font-size: 14px;
  color: var(--ink);
  transition: background-color 150ms var(--ease), color 150ms var(--ease);
}

.tabs button:hover { background: #e2ece8; }
.tabs button[aria-pressed="true"] { background: #d6ece5; color: #07675c; font-weight: 600; }

.appmain { padding: 24px; }
.appmain h3 { margin-bottom: 16px; }
.appmain > p { margin-bottom: 8px; }
.metrics { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-bottom: 8px; }

.metric, .mailrow {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 14px;
}

.metric strong { display: block; margin-top: 4px; font-size: clamp(16px, 3vw, 28px); font-variant-numeric: tabular-nums; }
.mailrow { display: flex; justify-content: space-between; gap: 8px; margin-top: 8px; padding-block: 8px; }
.ok { font-weight: 600; color: #147453; }

.caption, .note { display: block; color: var(--muted); margin-top: 16px; font-size: 13px; }

/* ---------- Code ---------- */

.code { background: #26312e; color: #edfaf4; padding: 20px 24px; border-radius: 16px; }
.code strong { font-size: 13px; font-weight: 600; color: #a9c4bb; }
/* Lange Kommandos scrollen im Block, nicht die Seite. */
.code pre { margin: 12px 0 0; overflow: auto; font: 14px/1.7 var(--mono); }

/* ---------- FAQ ---------- */

.faq { max-width: 720px; margin: auto; }
details { padding: 20px 0; border-bottom: 1px solid var(--line); }
details:first-child { border-top: 1px solid var(--line); }
summary { cursor: pointer; font-weight: 600; }
details p { margin-top: 12px; }

/* ---------- Beta ---------- */

.beta-panel { padding-block: clamp(40px, 7vw, 80px); background: radial-gradient(ellipse at top, #fff, transparent 75%), #eef3f0; }
.beta-heading { margin-bottom: 0; }
.beta-heading h2 { margin-top: 20px; }

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

footer { border-top: 1px solid var(--line); padding: 32px 0; }
footer .wrap { display: flex; justify-content: space-between; gap: 16px; align-items: center; }
footer nav { display: flex; gap: 20px; flex-wrap: wrap; font-size: 14px; color: var(--muted); }
footer nav a:hover, .mobile-nav a:hover { color: var(--teal); }

/* ---------- Klein ---------- */

@media (max-width: 740px) {
  :root { --section: 64px; --gap: 16px; }
  body { border-width: 4px; --frame-radius: 24px; }
  .wrap { width: calc(100% - 32px); }
  .hero::before, .navlinks { display: none; }
  .mobile-nav {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px 16px;
    margin: 16px 16px 0;
    font-size: 14px;
    color: var(--muted);
  }
  .hero { padding-bottom: 48px; }
  .intro { padding: 56px 0 48px; }
  .intro h1 { margin: 24px auto; }
  .intro p { font-size: 16px; }
  .actions { margin-top: 32px; }
  .heading { margin-bottom: 32px; }
  /* minmax(0, 1fr): lange Shell-Kommandos dürfen die Spalte nicht verbreitern (Referenz: 1fr). */
  .hero-cards, .grid, .split { grid-template-columns: minmax(0, 1fr); }
  .split { gap: 32px; }
  .split-top { gap: var(--gap); }
  .hero-cards { max-width: 410px; gap: 16px; }
  .hero-card:first-child, .hero-card:last-child { transform: none; }
  .stack { padding: 56px 0; }
  .card { padding: 24px; }
  .app { grid-template-columns: 1fr; }
  .sidebar { border-right: 0; border-bottom: 1px solid var(--line); }
  .tabs { display: flex; flex-wrap: wrap; }
  .metric { font-size: 12px; padding: 8px; }
  .appmain { padding: 16px; }
  footer .wrap { align-items: flex-start; flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn, .tabs button { transition: none; }
}

/* ---------- MCP ---------- */

.mcp-title { margin-top: 20px; }

.chat .bubble {
  justify-self: end;
  width: fit-content;
  max-width: 85%;
  margin: 0 0 24px auto;
  padding: 8px 12px;
  border-radius: 12px 12px 4px 12px;
  background: #eef3f0;
  color: var(--ink);
  font-size: 14px;
}

.chat h3 { font-size: 17px; letter-spacing: -.01em; }

/* Ein Diagramm, eine Hervorhebung: nur die größte Ursache trägt das Türkis. Breiten sind Beispieldaten. */
.bar-row {
  display: grid;
  grid-template-columns: minmax(0, 13em) minmax(0, 1fr) 3em;
  align-items: center;
  gap: 12px;
  margin-top: 12px;
  font-size: 14px;
}

.bar-row span { color: var(--muted); }
.bar-row b { text-align: right; font-weight: 600; font-variant-numeric: tabular-nums; }
.bar-row i { display: block; height: 8px; border-radius: 4px; background: #d7dfdb; }
.bar-row:nth-of-type(1) i { width: 100%; background: var(--teal); }
.bar-row:nth-of-type(2) i { width: 15%; }
.bar-row:nth-of-type(3) i { width: 9%; }
.bar-row:nth-of-type(4) i { width: 4%; }

@media (max-width: 740px) {
  .bar-row { grid-template-columns: minmax(0, 1fr) 3em; }
  .bar-row i { grid-column: 1 / -1; grid-row: 2; }
}

/* ---------- Preise ---------- */

.pricing {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--gap);
  align-items: stretch;
}

.price-card {
  display: flex;
  flex-direction: column;
  padding: 32px 28px 28px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: var(--shadow);
}

.price-card.featured { border: 2px solid var(--teal); padding: 31px 27px 27px; }
.price-card { position: relative; }
.price-note {
  position: absolute;
  top: -13px;
  left: 26px;
  padding: 2px 10px;
  border-radius: 100px;
  background: var(--teal);
  color: #fff;
  font-size: 13px;
  font-weight: 600;
}
.price-for { margin-top: 8px; font-size: 15px; min-height: 3.2em; }

.price { margin-top: 24px; color: var(--muted); font-size: 15px; }
.price strong { color: var(--ink); font-size: 44px; font-weight: 700; letter-spacing: -.03em; font-variant-numeric: tabular-nums; margin-right: 4px; }

.price-card ul {
  display: grid;
  gap: 10px;
  margin: 24px 0 32px;
  padding: 24px 0 0;
  border-top: 1px solid var(--line);
  list-style: none;
  font-size: 15px;
}

.price-card li { display: grid; grid-template-columns: 20px minmax(0, 1fr); gap: 8px; }
.price-card li span { color: var(--teal); font-weight: 600; }
.price-card .btn { margin-top: auto; }

.price-legal { margin-top: 24px; text-align: center; font-size: 13px; }

@media (max-width: 900px) {
  .pricing { grid-template-columns: minmax(0, 1fr); max-width: 480px; margin-inline: auto; }
  .price-for { min-height: 0; }
}

/* ---------- Warteliste ---------- */

.waitlist {
  display: flex;
  gap: 8px;
  max-width: 480px;
  margin: 32px auto 0;
}

.waitlist input[type="email"] {
  flex: 1;
  min-width: 0;
  min-height: 44px;
  padding: 0 16px;
  border: 1px solid #d3dbd7;
  border-radius: 10px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  transition: border-color 150ms var(--ease);
}

.waitlist input[type="email"]::placeholder { color: #7b8581; }
.waitlist input[type="email"]:focus-visible { outline: 3px solid var(--teal); outline-offset: 2px; border-color: var(--teal); }
.waitlist .btn:disabled { opacity: .6; cursor: progress; }

/* Honigtopf für Bots: listmonk weist Anmeldungen mit ausgefülltem nonce ab. */
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.waitlist-status:empty { display: none; }
.beta-heading .waitlist-status { margin: 16px auto 0; max-width: 480px; font-weight: 600; color: var(--ink); }
.waitlist-status.is-ok { color: #147453; }
.waitlist-status.is-error { color: #a63c1d; }
.beta-heading .waitlist-note { max-width: 480px; margin: 16px auto 0; font-size: 13px; }
.waitlist-note a { text-decoration: underline; text-underline-offset: 2px; }

@media (max-width: 480px) {
  .waitlist { flex-direction: column; }
}

/* ---------- Sprachumschalter ---------- */

.lang { display: flex; gap: 2px; font-size: 13px; }
.lang a { padding: 4px 8px; border-radius: 6px; color: var(--muted); transition: color 150ms var(--ease), background-color 150ms var(--ease); }
.lang a:hover { color: var(--teal); }
.lang a[aria-current="page"] { color: var(--ink); font-weight: 600; background: #eef3f0; }
.lang-mobile { display: none; }

@media (max-width: 740px) {
  .nav .lang { display: none; }
  .mobile-nav .lang-mobile { display: flex; padding-left: 8px; border-left: 1px solid var(--line); }
  .mobile-nav .lang-mobile a { padding: 0 4px; }
}

/* Bis 960 px passen Links, Sprachumschalter und Button nicht in eine Zeile:
   Links und Sprachen wandern in die zweite Reihe unter dem Menü. */
@media (max-width: 960px) {
  .navlinks, .nav .lang { display: none; }
  .mobile-nav {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px 16px;
    margin: 16px 16px 0;
    font-size: 14px;
    color: var(--muted);
  }
  .mobile-nav .lang-mobile { display: flex; padding-left: 8px; border-left: 1px solid var(--line); }
  .mobile-nav .lang-mobile a { padding: 0 4px; }
}
