/*
 * Shared stylesheet for the static Nestling site (landing page, legal pages,
 * 404). Colours are the app's own tokens from `src/global.css`, the font is the
 * app's Figtree. The site's Content-Security-Policy (`customHttp.yml`) has no
 * `'unsafe-inline'` for styles, so nothing on the site may carry a `style`
 * attribute: every look lives in this file.
 */

@font-face {
  font-family: "Figtree";
  src: url("figtree-400.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Figtree";
  src: url("figtree-600.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Figtree";
  src: url("figtree-700.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Figtree";
  src: url("figtree-800.woff2") format("woff2");
  font-weight: 800;
  font-style: normal;
  font-display: swap;
}

/* The app's display serif, used only for the greeting in the phone mockup. */
@font-face {
  font-family: "Fraunces";
  src: url("fraunces-600.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

/* Keep in sync with the @theme block in src/global.css. */
:root {
  --brand: #1f6f68;
  --brand-soft: #e3f0ee;
  --brand-ink: #1f5e58;
  --brand-deep: #164f4a;
  --on-brand-muted: #d7eeeb;

  --ink: #17302e;
  --muted: #4a5d5b;
  --canvas: #f3f5f4;
  --surface: #fff;
  --line: #dde3e1;
  --line-soft: #edf1f0;

  --accent: #b45309;
  --accent-soft: #fbebdd;

  --font: "Figtree", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;

  --content: 1120px;
  --pad: 16px;
}

@media (min-width: 600px) {
  :root {
    --pad: 24px;
  }
}

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

body {
  margin: 0;
  background: var(--surface);
  color: var(--ink);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  -webkit-text-size-adjust: 100%;
}

h1,
h2,
h3 {
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 0;
  line-height: 1.15;
  text-wrap: balance;
}

a {
  color: inherit;
}

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

/* The inlined icon sprite: out of the flow, or its 0x0 box still opens a line. */
.sprite {
  position: absolute;
}

.wrap {
  width: 100%;
  max-width: var(--content);
  margin-inline: auto;
  padding-inline: var(--pad);
}

.skip {
  position: absolute;
  left: -9999px;
}

.skip:focus {
  left: var(--pad);
  top: 12px;
  z-index: 10;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 8px 14px;
}

:focus-visible {
  outline: 3px solid var(--brand);
  outline-offset: 2px;
}

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

.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px 16px;
  padding-block: 20px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.02em;
  text-decoration: none;
}

.brand img {
  width: 40px;
  height: 40px;
}

.nav {
  display: none;
  gap: 32px;
}

.nav a {
  font-size: 15px;
  font-weight: 600;
  color: var(--brand);
  text-decoration: none;
}

.nav a:hover {
  text-decoration: underline;
}

@media (min-width: 900px) {
  .nav {
    display: flex;
  }
}

.btn {
  display: inline-block;
  background: var(--brand);
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  text-decoration: none;
  padding: 10px 20px;
  border-radius: 9999px;
  white-space: nowrap;
  transition: background-color 0.15s ease;
}

.btn:hover {
  background: var(--brand-ink);
}

@media (max-width: 599px) {
  .brand {
    font-size: 20px;
  }

  .brand img {
    width: 34px;
    height: 34px;
  }

  .header .btn {
    font-size: 14px;
    padding: 9px 16px;
  }
}

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

.hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 48px;
  padding-block: 32px 64px;
}

.eyebrow {
  display: inline-block;
  margin: 0 0 20px;
  padding: 6px 14px;
  border-radius: 9999px;
  background: var(--brand-soft);
  color: var(--brand-ink);
  font-size: 14px;
  font-weight: 700;
}

.hero h1 {
  font-size: clamp(34px, 6vw, 56px);
  line-height: 1.1;
}

.hero p.lead {
  max-width: 600px;
  margin: 24px auto 0;
  color: var(--muted);
  font-size: clamp(17px, 2.2vw, 19px);
  line-height: 1.6;
}

/* The privacy promise in one line, linking to #datenschutz. */
.hero-trust {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 24px;
  color: var(--brand-ink);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
}

.hero-trust:hover {
  text-decoration: underline;
}

.hero-trust svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
  flex: none;
}

.hero-visual {
  display: flex;
  justify-content: center;
  width: 100%;
}

@media (min-width: 600px) {
  .hero {
    padding-block: 64px 80px;
  }
}

@media (min-width: 900px) {
  .hero {
    flex-direction: row;
    text-align: left;
    gap: 64px;
  }

  .hero-content {
    flex: 1 1 0;
    min-width: 0;
  }

  .hero p.lead {
    margin-inline: 0;
  }

  .hero .stores {
    justify-content: flex-start;
  }

  .hero-visual {
    flex: none;
    width: auto;
  }
}

/* Phone mockup ------------------------------------------------------------
   The Heute screen drawn in HTML/CSS rather than a screenshot, so it stays
   sharp, weighs nothing and can't drift into showing personal data. Mirror
   `src/app/(tabs)/index.tsx` when that screen changes. */

.phone {
  width: 340px;
  max-width: 100%;
  border-radius: 44px;
  padding: 12px;
  background: var(--ink);
  box-shadow: 0 30px 60px -20px rgba(23, 48, 46, 0.45),
    0 0 0 1px rgba(23, 48, 46, 0.2);
}

.screen {
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-height: 600px;
  /* The app's warm palette (src/global.css), scoped to the mockup. */
  --m-canvas: #faf6f0;
  --m-muted: #57544c;
  --m-line: #e8e0d4;
  --m-line-soft: #f2ece3;
  border-radius: 34px;
  background: var(--m-canvas);
  padding: 44px 16px 0;
  text-align: left;
  overflow: hidden;
}

.m-head {
  display: flex;
  align-items: center;
  gap: 12px;
}

.m-avatar {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: none;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--brand);
  color: #fff;
  font-size: 19px;
  font-weight: 700;
}

.m-date {
  display: block;
  color: var(--m-muted);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.3;
}

.m-title {
  display: block;
  font-family: "Fraunces", Georgia, serif;
  font-size: 23px;
  font-weight: 600;
  line-height: 1.2;
}

.m-age {
  display: block;
  color: var(--m-muted);
  font-size: 12.5px;
  line-height: 1.3;
}

.m-next {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  border-radius: 24px;
  background: var(--brand);
  color: #fff;
  padding: 16px;
}

.m-next-body {
  flex: 1;
  min-width: 0;
}

/* The call button on the next appointment. */
.m-round {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: none;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--surface);
}

.m-round svg {
  width: 18px;
  height: 18px;
  fill: var(--brand);
}

.m-questions {
  display: block;
  margin-top: 4px;
  color: var(--on-brand-muted);
  font-size: 12px;
  font-weight: 600;
}

/* The check-up hint (CheckupHint in the app). */
.m-hint {
  border-radius: 24px;
  background: var(--surface);
  padding: 14px;
  box-shadow: 0 1px 2px rgba(87, 60, 30, 0.06), 0 4px 14px rgba(87, 60, 30, 0.06);
}

.m-hint-top {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.m-hint-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: none;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--brand-soft);
}

.m-hint-icon svg {
  width: 18px;
  height: 18px;
  fill: var(--brand);
}

.m-hint-text {
  flex: 1;
  min-width: 0;
}

.m-hint-label {
  display: block;
  color: var(--brand);
  font-size: 11.5px;
  font-weight: 600;
}

.m-hint-title {
  display: block;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.3;
}

.m-hint-period {
  display: block;
  color: var(--m-muted);
  font-size: 12px;
  line-height: 1.35;
}

.m-hint-close {
  flex: none;
  width: 14px;
  height: 14px;
  fill: var(--m-muted);
}

.m-hint-button {
  display: block;
  margin-top: 10px;
  border: 1px solid var(--brand);
  border-radius: 14px;
  padding: 8px;
  color: var(--brand);
  font-size: 13px;
  font-weight: 700;
  text-align: center;
}

.m-label {
  display: block;
  color: var(--on-brand-muted);
  font-size: 12px;
  font-weight: 600;
}

.m-when {
  display: block;
  margin-top: 2px;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.3;
}

.m-who {
  display: block;
  color: var(--on-brand-muted);
  font-size: 14px;
}

.m-note {
  display: block;
  margin-top: 8px;
  font-size: 14px;
  line-height: 1.4;
}

.m-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}

.m-h {
  font-size: 16px;
  font-weight: 700;
}

.m-add {
  color: var(--brand);
  font-size: 14px;
  font-weight: 700;
}

.m-values {
  display: flex;
  margin-top: 8px;
  border-radius: 20px;
  background: var(--surface);
  box-shadow: 0 1px 2px rgba(87, 60, 30, 0.06), 0 4px 14px rgba(87, 60, 30, 0.06);
}

.m-value {
  flex: 1;
  padding: 10px 10px;
}

.m-value + .m-value {
  border-left: 1px solid var(--m-line-soft);
}

.m-vlabel {
  display: block;
  color: var(--m-muted);
  font-size: 11px;
  font-weight: 600;
}

.m-num {
  display: block;
  font-size: 16px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.m-unit {
  color: var(--m-muted);
  font-size: 11px;
  font-weight: 600;
}

.m-vdate {
  display: block;
  color: var(--m-muted);
  font-size: 10.5px;
}

.m-tabs {
  display: flex;
  justify-content: space-around;
  margin: auto -16px 0;
  padding: 10px 8px 18px;
  border-top: 1px solid var(--m-line);
  background: var(--m-line-soft);
}

.m-tab {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  color: var(--m-muted);
  font-size: 10.5px;
  font-weight: 600;
}

.m-tab svg {
  width: 22px;
  height: 22px;
  fill: currentColor;
}

.m-tab-active {
  color: var(--brand);
}

/* Store buttons ----------------------------------------------------------- */

.stores {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
  margin-top: 36px;
}

.store {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgb(10, 10, 10);
  color: #fff;
  border-radius: 12px;
  padding: 10px 18px;
  text-decoration: none;
  transition: opacity 0.15s ease;
}

.store:hover {
  opacity: 0.8;
}

.store svg {
  width: 22px;
  height: 22px;
  fill: currentColor;
  flex: none;
}

.store-top {
  display: block;
  font-size: 11px;
  line-height: 1.2;
  opacity: 0.8;
}

.store-name {
  display: block;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.3;
}

/* A store without a listing yet: an inert placeholder rather than a dead link. */
.store-soon {
  background: var(--canvas);
  color: var(--muted);
  border: 1px solid var(--line);
  cursor: default;
}

.store-soon:hover {
  opacity: 1;
}

.cta .store-soon {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.25);
  color: #fff;
}

.stores-note {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 14px;
}

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

.section {
  padding-block: 80px 96px;
}

.section-tint {
  background: var(--canvas);
}

.section-head {
  max-width: 640px;
  margin: 0 auto 48px;
  text-align: center;
}

.section-head h2 {
  font-size: clamp(28px, 4vw, 38px);
}

.section-head p {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: clamp(16px, 2vw, 18px);
}

.grid {
  display: grid;
  gap: 20px;
  grid-template-columns: 1fr;
}

@media (min-width: 640px) {
  .grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 960px) {
  .grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 24px;
}

.card-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  margin-bottom: 16px;
  border-radius: 14px;
  background: var(--brand-soft);
}

.card-icon svg {
  width: 26px;
  height: 26px;
  fill: var(--brand);
}

.card h3 {
  font-size: 19px;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin-bottom: 8px;
}

.card p {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.55;
}

/* Words with a hyphen that shouldn't break at it, e.g. "U-Untersuchungen". */
.nobreak {
  white-space: nowrap;
}

/* Nestling Plus ----------------------------------------------------------- */

/* The warm accent sets the paid extras apart from the free features above.
   Scoped to .section-head, whose paragraph style would otherwise win. */
.section-head .eyebrow-plus {
  margin: 0 0 16px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 14px;
}

.plus .card-icon {
  background: var(--accent-soft);
}

.plus .card-icon svg {
  fill: var(--accent);
}

/* The two packages, side by side from tablet width; the yearly one carries
   the accent border and the savings badge. */
.plans {
  display: grid;
  gap: 20px;
  grid-template-columns: 1fr;
  max-width: 640px;
  margin: 48px auto 0;
}

@media (min-width: 640px) {
  .plans {
    grid-template-columns: repeat(2, 1fr);
  }
}

.plan {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 28px 24px 24px;
  text-align: center;
}

.plan h3 {
  font-size: 17px;
  font-weight: 700;
  color: var(--muted);
}

.plan-price {
  margin: 8px 0 4px;
  font-size: 40px;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.1;
}

.plan-period {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
}

.plan-featured {
  border: 2px solid var(--accent);
}

.plan-featured h3 {
  color: var(--accent);
}

.plan-badge {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translate(-50%, -50%);
  margin: 0;
  padding: 4px 14px;
  border-radius: 9999px;
  background: var(--accent);
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
}

.plus-note {
  max-width: 640px;
  margin: 32px auto 0;
  color: var(--muted);
  font-size: 15px;
  text-align: center;
}

/* Privacy ----------------------------------------------------------------- */

.privacy {
  background: var(--brand-deep);
  color: #fff;
}

.privacy .section-head p {
  color: var(--on-brand-muted);
}

.privacy .card {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.14);
}

.privacy .card p {
  color: var(--on-brand-muted);
}

.privacy .card-icon {
  background: rgba(255, 255, 255, 0.12);
}

.privacy .card-icon svg {
  fill: #fff;
}

/* The one plaintext exception, said out loud rather than in small print. */
.privacy .card-exception {
  border-color: rgba(251, 235, 221, 0.45);
}

.privacy .card-exception .card-icon {
  background: var(--accent-soft);
}

.privacy .card-exception .card-icon svg {
  fill: var(--accent);
}

/* Story ------------------------------------------------------------------- */

.story {
  max-width: 720px;
  padding-block: 96px;
}

.story h2 {
  text-align: center;
  font-size: clamp(28px, 4vw, 38px);
  margin-bottom: 40px;
}

.story p {
  color: var(--muted);
  font-size: clamp(16px, 2vw, 18px);
  line-height: 1.7;
  margin: 0 0 24px;
}

.story .story-lead {
  color: var(--ink);
  font-weight: 600;
  font-size: clamp(18px, 2.4vw, 21px);
}

.story .story-highlight {
  margin-block: 36px;
  text-align: center;
  color: var(--brand-ink);
  font-weight: 700;
  font-size: clamp(19px, 2.6vw, 23px);
  line-height: 1.5;
}

.story .story-signature {
  margin: 0;
  text-align: center;
  color: var(--ink);
  font-size: clamp(17px, 2.2vw, 19px);
  font-weight: 600;
}

.story .story-signature::before {
  content: "– ";
}

/* Closing call-to-action -------------------------------------------------- */

.cta {
  background: linear-gradient(to bottom, var(--brand), var(--brand-deep));
  color: #fff;
  text-align: center;
  padding-block: 96px;
}

.cta h2 {
  font-size: clamp(28px, 4vw, 38px);
}

.cta p {
  max-width: 500px;
  margin: 16px auto 0;
  color: var(--on-brand-muted);
  font-size: clamp(16px, 2vw, 18px);
}

/* Legal pages ------------------------------------------------------------- */

.legal {
  max-width: 760px;
  padding-block: 32px 96px;
}

.legal h1 {
  font-size: clamp(30px, 5vw, 42px);
}

.legal .meta {
  margin: 8px 0 32px;
  color: var(--muted);
}

.legal section {
  margin-top: 32px;
}

.legal h2 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 8px;
}

.legal p,
.legal li {
  color: var(--muted);
}

.legal p {
  margin: 0 0 12px;
}

.legal ul {
  margin: 0 0 12px;
  padding-left: 22px;
}

.legal a {
  color: var(--brand);
}

/* `white-space: pre-line` keeps the address block's line breaks without <br>. */
.legal .address {
  white-space: pre-line;
}

/* 404 --------------------------------------------------------------------- */

.notfound {
  max-width: 640px;
  padding-block: 96px;
  text-align: center;
}

.notfound h1 {
  font-size: clamp(30px, 5vw, 42px);
}

.notfound p {
  margin: 16px 0 32px;
  color: var(--muted);
  font-size: 18px;
}

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

.footer {
  border-top: 1px solid var(--line);
  padding-block: 48px;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px 24px;
}

.footer .brand {
  font-size: 17px;
  gap: 8px;
}

.footer .brand img {
  width: 28px;
  height: 28px;
}

.footer-copy {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

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

.footer-links a {
  color: var(--muted);
  font-size: 14px;
  text-decoration: none;
}

.footer-links a:hover {
  color: var(--ink);
  text-decoration: underline;
}
