/* tiny pot – by die kleine töpferei
   Farben aus dem Logo: Olivgrün und Creme. Terrakotta (wie die Website der kleinen töpferei) als Akzent. */

:root {
  --olive: #707056;
  --olive-dark: #55553F;
  --olive-soft: #E3E2D3;
  --cream: #F3ECDF;
  --ink: #2E2D22;
  --ink-2: #47463A;
  --muted: #6C6A5C;
  --line: #E2DBCC;
  --soft: #ECE6D8;
  --bg: #F7F3EA;
  --card: #FFFDF8;
  --sand: #EDE3D2;
  --clay: #B5653E;
  --clay-dark: #94502F;
  --celadon: #707056;
  --celadon-soft: #E3E2D3;
  --danger: #A8322A;
  --radius: 18px;
  --font-display: 'Fredoka', 'Figtree', system-ui, sans-serif;
  --font-body: 'Figtree', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --safe-bottom: env(safe-area-inset-bottom, 0px);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}

body { min-height: 100vh; }

button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: var(--clay-dark); }
img { display: block; max-width: 100%; }
fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
legend { padding: 0; }

.app {
  max-width: 480px;
  margin: 0 auto;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
}

@media (min-width: 520px) {
  body { background: #E6E1D2; }
  .app { box-shadow: 0 0 0 1px var(--line); }
}

/* ---------- Typografie ---------- */

.display {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.12;
  margin: 0;
}
.h1 { font-size: 30px; }
.h2 { font-size: 23px; }
.h3 { font-size: 18px; }
.lead { font-size: 18px; color: var(--ink-2); }
.muted { color: var(--muted); }
.small { font-size: 14px; }
.tiny { font-size: 13px; }
.center { text-align: center; }
.right { text-align: right; }
.nowrap { white-space: nowrap; }
.grow { flex: 1; min-width: 0; }
.pre { white-space: pre-wrap; }
p { margin: 0; }

.eyebrow {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.eyebrow--clay { color: var(--clay); }

/* ---------- Logo ---------- */

.wordmark { display: inline-flex; color: var(--olive); line-height: 0; }
.wordmark svg { height: 26px; width: auto; }
.wordmark--lg svg { height: 40px; }
.wordmark--on-dark { color: var(--cream); }

/* Logo zweizeilig mit Claim, wie das tiny pot Logo */
.logo-stack { display: flex; flex-direction: column; align-items: center; gap: 18px; color: var(--cream); }
.logo-stack svg { width: 190px; height: auto; }
.logo-stack__claim { font-size: 13px; letter-spacing: 0.32em; text-transform: uppercase; padding-left: 0.32em; white-space: nowrap; }
.logo-stack__claim span { margin: 0 0.15em; }

.byline { font-size: 13px; letter-spacing: 0.04em; color: var(--muted); }
.byline a { color: inherit; }

.splash {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  background: var(--olive);
}

/* ---------- Layout ---------- */

.screen {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 20px 16px calc(28px + var(--safe-bottom));
}
.screen--with-nav { padding-bottom: calc(100px + var(--safe-bottom)); }
.screen--center { justify-content: center; }
/* Login: olivgrün wie das Logo */
.screen--login { background: var(--olive); color: var(--cream); min-height: 100vh; justify-content: center; gap: 22px; }
.login-hero { display: flex; justify-content: center; padding: 28px 0 12px; }
.login-text { color: #E2DCCB; }
.screen--login .field__label { color: var(--cream); }
.screen--login .field__hint { color: #D8D2C0; }
.screen--login .input { border-color: transparent; color: var(--ink); }
.screen--login .input::placeholder { color: #9A978A; }
.screen--login .btn--primary { background: var(--cream); color: var(--olive-dark); }
.screen--login .btn--primary:hover { background: #FFFFFF; }
.screen--login .muted, .screen--login .byline { color: #D8D2C0; }
.screen--login .error { color: #FFD9C7; }
.screen--login .banner { background: rgba(243, 236, 223, 0.16); color: var(--cream); }

.stack { display: flex; flex-direction: column; gap: 12px; }
.stack-lg { display: flex; flex-direction: column; gap: 22px; }
.stack-sm { display: flex; flex-direction: column; gap: 8px; }
.stack-xs { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.row { display: flex; align-items: center; gap: 12px; }
.row-between { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.wrap { display: flex; flex-wrap: wrap; gap: 8px; }

.topbar {
  display: grid;
  grid-template-columns: 44px 1fr 44px;
  align-items: center;
  min-height: 44px;
}
.topbar__title { text-align: center; font-weight: 700; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--card);
  border: 1px solid var(--line);
  color: var(--ink);
  text-decoration: none;
}

/* ---------- Karten ---------- */

.card {
  display: block;
  background: var(--card);
  border-radius: var(--radius);
  padding: 16px 18px;
  color: inherit;
  text-decoration: none;
}
a.card { transition: transform 0.12s ease; }
a.card:active { transform: scale(0.99); }
.card--dark { background: var(--olive); color: var(--cream); }
.card--dark .muted, .card--dark .eyebrow { color: #DCD6C4; }
.card--outline { background: transparent; border: 1.5px dashed var(--line); }
.card--clay { background: var(--clay); color: #FFF8F1; }
.card--sand { background: var(--sand); }
a.card.row-between, .upsell { display: flex; align-items: center; justify-content: space-between; gap: 12px; }

.empty { display: flex; flex-direction: column; gap: 4px; }

.hero { position: relative; display: flex; flex-direction: column; gap: 6px; padding: 20px 20px 22px; overflow: hidden; }
.hero::after {
  content: '';
  position: absolute;
  right: -40px;
  bottom: -60px;
  width: 170px;
  height: 170px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #C47A52, var(--clay) 55%, #7E4026);
  opacity: 0.85;
}
.hero > * { position: relative; z-index: 1; max-width: 78%; }
.hero__play {
  position: absolute !important;
  right: 22px;
  bottom: 22px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--cream);
  color: var(--olive-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  padding-left: 3px;
}

.stat { display: flex; flex-direction: column; gap: 2px; padding: 14px; }
.stat__value { font-family: var(--font-display); font-weight: 650; font-size: 24px; }
.stat__of { font-size: 15px; color: var(--muted); }
.stat__label { font-size: 13px; color: var(--muted); }

.list { background: var(--card); border-radius: var(--radius); padding: 2px 18px; }
.list__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 0;
  border-bottom: 1px solid var(--soft);
  color: inherit;
  text-decoration: none;
}
.list__row:last-child { border-bottom: 0; }
.list__title { font-weight: 700; }
.link { font-weight: 700; text-decoration: none; }

.tile {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-height: 130px;
  padding: 16px;
  border-radius: var(--radius);
  text-decoration: none;
  color: var(--ink);
}
.tile__title { font-family: var(--font-display); font-weight: 650; font-size: 19px; }
.tile--glaze { background: var(--olive-soft); }
.tile--kiln { background: var(--sand); }

.upsell__title { font-weight: 700; font-size: 17px; }

.avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--olive);
  color: var(--cream);
  font-weight: 700;
  text-decoration: none;
  flex: none;
}
.avatar--lg { width: 60px; height: 60px; font-size: 26px; font-family: var(--font-display); font-weight: 600; }

.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
  flex: none;
}
.badge--lock { background: var(--soft); color: var(--muted); }
.badge--plus { background: var(--olive); color: var(--cream); }

.pill {
  font-size: 13px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--olive-soft);
  color: var(--olive-dark);
  white-space: nowrap;
}

/* ---------- Abo ---------- */

.plan { display: flex; flex-direction: column; gap: 10px; background: var(--card); border-radius: var(--radius); padding: 20px; }
.plan--plus { background: var(--olive); color: var(--cream); }
.plan__name { font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; font-size: 13px; }
.plan__price { display: flex; align-items: baseline; gap: 6px; }
.checks { list-style: none; margin: 4px 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.checks li { display: flex; gap: 10px; align-items: flex-start; font-size: 15px; }
.checks svg { flex: none; margin-top: 3px; color: var(--celadon); }
.plan--plus .checks svg { color: var(--cream); }

/* ---------- Knöpfe ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 50px;
  padding: 12px 20px;
  border-radius: 999px;
  border: 0;
  font-weight: 700;
  text-decoration: none;
  text-align: center;
  transition: transform 0.1s ease, background 0.15s ease;
}
.btn:active { transform: scale(0.98); }
.btn:disabled { opacity: 0.55; cursor: default; }
.btn--block { width: 100%; }
.btn--primary { background: var(--olive); color: var(--cream); }
.btn--primary:hover { background: var(--olive-dark); }
.btn--secondary { background: var(--ink); color: var(--bg); }
.btn--small { min-height: 40px; padding: 8px 16px; font-size: 14px; }
.btn--ghost { background: transparent; color: var(--ink); border: 1.5px solid var(--line); }
.btn--light { background: var(--bg); color: var(--ink); }
.btn--danger { color: var(--danger); }

/* ---------- Formulare ---------- */

.field { display: flex; flex-direction: column; gap: 8px; }
.field__label { font-weight: 700; font-size: 15px; }
.field__hint { font-size: 13px; color: var(--muted); }

.input {
  width: 100%;
  min-height: 50px;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1.5px solid var(--line);
  background: var(--card);
  font-size: 16px;
}
.input:focus { outline: none; border-color: var(--olive); box-shadow: 0 0 0 3px rgba(112, 112, 86, 0.2); }
.textarea { min-height: 110px; resize: vertical; line-height: 1.45; }
.code-input { font-size: 24px; letter-spacing: 0.3em; text-align: center; }

.input-unit { position: relative; display: block; }
.input-unit .input { padding-right: 76px; }
.input-unit__unit { position: absolute; right: 14px; top: 50%; transform: translateY(-50%); color: var(--muted); font-size: 14px; pointer-events: none; }

.option {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  width: 100%;
  padding: 14px 16px;
  border-radius: 16px;
  border: 1.5px solid var(--line);
  background: var(--card);
  text-align: left;
}
.option[aria-pressed='true'] { border-color: var(--olive); background: var(--olive-soft); }
.option__title { font-weight: 700; }

.chip {
  min-height: 40px;
  padding: 8px 16px;
  border-radius: 999px;
  border: 1.5px solid var(--line);
  background: var(--card);
  font-weight: 500;
  font-size: 15px;
}
.chip[aria-pressed='true'] { background: var(--olive); border-color: var(--olive); color: var(--cream); }

.error { color: var(--danger); font-weight: 500; font-size: 15px; }
.banner { margin: 0; padding: 10px 14px; border-radius: 12px; background: var(--olive-soft); color: var(--olive-dark); font-size: 13px; }

/* ---------- Navigation ---------- */

.nav {
  position: fixed;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: 100%;
  max-width: 480px;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  padding: 8px 6px calc(8px + var(--safe-bottom));
  background: rgba(255, 253, 249, 0.94);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-top: 1px solid var(--line);
  z-index: 10;
}
.nav__item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 6px 2px;
  border-radius: 12px;
  color: var(--muted);
  text-decoration: none;
  font-size: 11.5px;
  font-weight: 500;
  white-space: nowrap;
}
.nav__item[aria-current='page'] { color: var(--olive-dark); font-weight: 700; }

.toast {
  position: fixed;
  left: 50%;
  bottom: calc(96px + var(--safe-bottom));
  transform: translateX(-50%);
  width: calc(100% - 32px);
  max-width: 440px;
  padding: 14px 18px;
  border-radius: 16px;
  background: var(--ink);
  color: var(--cream);
  font-weight: 500;
  z-index: 20;
  animation: toast-in 0.2s ease;
}
@keyframes toast-in { from { opacity: 0; transform: translate(-50%, 8px); } }

.loading { display: flex; align-items: center; gap: 10px; color: var(--muted); padding: 12px 0; }
.loading__dot { width: 10px; height: 10px; border-radius: 50%; background: var(--clay); animation: pulse 1s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: 0.3; transform: scale(0.7); } }

/* ---------- Lernen ---------- */

.path { display: flex; flex-direction: column; gap: 6px; }
.bar { flex: 1; height: 6px; border-radius: 999px; background: var(--soft); overflow: hidden; }
.bar span { display: block; height: 100%; background: var(--celadon); border-radius: 999px; }

.lessons { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.lesson-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border-radius: var(--radius);
  background: var(--card);
  color: inherit;
  text-decoration: none;
}
.lesson-row__num {
  flex: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--soft);
  font-weight: 700;
  font-size: 14px;
}
.lesson-row.is-done .lesson-row__num { background: var(--celadon); color: #FFFFFF; }

.video {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius);
  background: var(--ink);
  color: var(--bg);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}
.video__frame { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; background: #000; }
.video--locked, .video--soon { flex-direction: column; gap: 10px; padding: 20px; text-align: center; }
.video--locked { background: linear-gradient(140deg, var(--olive-dark), #3E3E2E); }
.video--soon { background: linear-gradient(140deg, var(--olive), var(--olive-dark)); }
.video--soon .small { max-width: 300px; color: #E6E0CF; }
.video__icon { width: 52px; height: 52px; border-radius: 50%; background: rgba(246, 241, 234, 0.14); display: flex; align-items: center; justify-content: center; }

.steps { margin: 0; padding: 0; list-style: none; counter-reset: step; display: flex; flex-direction: column; gap: 12px; }
.steps li { counter-increment: step; display: grid; grid-template-columns: 30px 1fr; gap: 10px; }
.steps li::before {
  content: counter(step);
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--sand);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
}
.tips, .bullets { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 8px; }

/* ---------- Glasur ---------- */

.tabs { display: grid; grid-template-columns: 1fr 1fr; padding: 4px; border-radius: 999px; background: var(--soft); }
.tabs__item { text-align: center; padding: 10px; border-radius: 999px; color: var(--muted); text-decoration: none; font-weight: 700; font-size: 15px; }
.tabs__item[aria-selected='true'] { background: var(--card); color: var(--ink); box-shadow: 0 1px 3px rgba(43, 33, 28, 0.08); }

.cards { display: flex; flex-direction: column; gap: 10px; }
.test-card, .project-card {
  display: flex;
  gap: 14px;
  align-items: center;
  padding: 10px;
  border-radius: var(--radius);
  background: var(--card);
  color: inherit;
  text-decoration: none;
}
.test-card__img, .project-card__img { flex: none; width: 76px; height: 76px; border-radius: 12px; overflow: hidden; background: var(--soft); }
.test-card__img img, .project-card__img img { width: 100%; height: 100%; object-fit: cover; }
.test-card__body, .project-card__body { flex: 1; }
.swatch { display: block; width: 100%; height: 100%; background: radial-gradient(circle at 30% 30%, #A9C4B4, #6E8F7E 60%, #4E6C5D); }
.swatch--clay { background: radial-gradient(circle at 30% 30%, #D69C78, var(--clay) 60%, #7E4026); }

.stars { display: inline-flex; gap: 2px; color: #D9C9B8; }
.star { display: inline-flex; padding: 0; border: 0; background: none; color: inherit; }
.star.is-on { color: #C98A2E; }
button.star { padding: 4px; }
.test-card .star svg { width: 15px; height: 15px; }

/* ---------- Brand & Ton ---------- */

.table-wrap { background: var(--card); border-radius: var(--radius); padding: 6px 14px; overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-size: 15px; }
.table th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); padding: 10px 6px; }
.table td { padding: 10px 6px 2px; font-weight: 700; }
.table__note td { padding: 0 6px 10px; font-weight: 400; font-size: 13px; color: var(--muted); border-bottom: 1px solid var(--soft); }
.table tbody tr:last-child td { border-bottom: 0; }

.curve { list-style: none; margin: 0; padding: 0 0 0 14px; border-left: 2px solid var(--clay); display: flex; flex-direction: column; gap: 12px; }
.curve li { display: flex; flex-direction: column; gap: 1px; }
.curve__range { font-weight: 700; }
.curve__rate { color: var(--clay-dark); font-size: 14px; font-weight: 500; }

.checklist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.checklist label { display: flex; gap: 12px; align-items: flex-start; }
.checklist input { width: 22px; height: 22px; margin: 0; flex: none; accent-color: var(--celadon); }
.checklist input:checked + span { color: var(--muted); text-decoration: line-through; }

.result { display: flex; flex-direction: column; gap: 2px; padding: 14px 16px; border-radius: 14px; background: var(--celadon-soft); }

/* ---------- Studio ---------- */

.dots { display: flex; gap: 4px; margin-top: 4px; }
.dots span { width: 18px; height: 5px; border-radius: 999px; background: var(--soft); }
.dots span.is-on { background: var(--clay); }

.timeline { list-style: none; margin: 0; padding: 4px 0; display: flex; flex-direction: column; }
.timeline li { position: relative; display: flex; align-items: center; gap: 12px; padding: 7px 0; color: var(--muted); }
.timeline li:not(:last-child)::after { content: ''; position: absolute; left: 11px; top: 30px; bottom: -8px; width: 2px; background: var(--line); }
.timeline__dot { flex: none; width: 24px; height: 24px; border-radius: 50%; border: 2px solid var(--line); background: var(--bg); display: flex; align-items: center; justify-content: center; position: relative; z-index: 1; }
.timeline li.is-done { color: var(--ink); }
.timeline li.is-done .timeline__dot { background: var(--celadon); border-color: var(--celadon); color: #FFFFFF; }
.timeline li.is-done::after { background: var(--celadon); }
.timeline li.is-current { color: var(--ink); font-weight: 700; }
.timeline li.is-current .timeline__dot { border-color: var(--clay); box-shadow: inset 0 0 0 4px var(--bg); background: var(--clay); }
.timeline__dot svg { width: 13px; height: 13px; }

/* ---------- Fotos ---------- */

.photos { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.photo { position: relative; margin: 0; aspect-ratio: 1; border-radius: 14px; overflow: hidden; background: var(--soft); }
.photo img { width: 100%; height: 100%; object-fit: cover; }
.photo__ph { display: block; width: 100%; height: 100%; }
.photo__remove {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 0;
  background: rgba(43, 33, 28, 0.75);
  color: #FFFFFF;
  font-size: 18px;
  line-height: 1;
}
.photo--add {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  border: 1.5px dashed var(--line);
  background: var(--card);
  color: var(--muted);
  cursor: pointer;
}

/* ---------- Login: Reiter und Knöpfe auf Olivgrün ---------- */

.tabs--on-dark { background: rgba(243, 236, 223, 0.16); }
.tabs--on-dark .tabs__item { border: 0; background: transparent; color: #E2DCCB; font: inherit; font-weight: 700; cursor: pointer; }
.tabs--on-dark .tabs__item[aria-selected='true'] { background: var(--cream); color: var(--olive-dark); }
.btn--on-dark { color: var(--cream); border-color: rgba(243, 236, 223, 0.5); }
.link-btn { align-self: center; border: 0; background: none; color: var(--cream); text-decoration: underline; font-size: 14px; padding: 6px; }

/* ---------- Absender ---------- */

.studio-card { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; padding: 18px; border-radius: var(--radius); background: var(--sand); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
