/* Bílé pozadí a černé písmo, velké a kontrastní, aby to bylo čitelné na kameře. */
:root {
  --fg: #000;
  --muted: #555;
  --line: #e5e5e5;
  --green: #12a150;
  --orange: #f57c00;
  --red: #e11d2e;
  --brand: #0E4F53; /* Nomce Teal z logo manuálu */
  --bar-h: 64px;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html, body {
  margin: 0;
  height: 100%;
  background: #fff;
  color: var(--fg);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  -webkit-user-select: none;
  user-select: none;
  overscroll-behavior: none;
}

.hidden { display: none !important; }

/* Značka */
.brand { display: flex; align-items: baseline; gap: 6px; color: var(--brand); }
.brand img { height: 26px; align-self: center; }
.brand-ai { font-weight: 800; font-size: 22px; margin-left: -4px; }
.brand-gastro { font-weight: 300; font-size: 24px; margin-left: 6px; }

.brand-big { flex-direction: column; align-items: center; gap: 10px; }
.brand-big img { height: 56px; }
.brand-big .brand-row { display: flex; align-items: baseline; }
.brand-big .brand-ai { font-size: 44px; margin-left: -2px; }
.brand-big .brand-gastro { font-size: 40px; margin: 0; letter-spacing: .02em; }

/* Úvodní obrazovka */
.splash {
  position: fixed; inset: 0; z-index: 10;
  display: flex; align-items: center; justify-content: center;
  background: #fff;
  transition: opacity .6s ease;
}
.splash .brand { animation: rise .9s ease both; }
.splash.fade { opacity: 0; pointer-events: none; }

/* Pruh nahoře */
.topbar {
  position: sticky; top: 0; z-index: 5;
  height: calc(var(--bar-h) + env(safe-area-inset-top));
  padding: env(safe-area-inset-top) 20px 0;
  display: flex; align-items: center;
  background: #fff;
  border-bottom: 2px solid var(--fg);
}

main { padding: 0 20px calc(24px + env(safe-area-inset-bottom)); max-width: 560px; margin: 0 auto; }

.screen { animation: fadein .35s ease both; }
h1 { font-size: 30px; line-height: 1.2; margin: 28px 0 8px; }
h2 { font-size: 22px; margin: 0; }
.sub { font-size: 18px; color: var(--muted); margin: 0 0 14px; }

/* Mikrofon */
#screen-listen { display: flex; flex-direction: column; align-items: center; text-align: center; }
.mic {
  width: 132px; height: 132px; margin: 26px 0 12px;
  border-radius: 50%;
  border: 4px solid var(--fg);
  background: #fff;
  display: grid; place-items: center;
  cursor: pointer;
  transition: background .2s, border-color .2s, transform .1s;
}
.mic:active { transform: scale(.96); }
.mic svg { width: 60px; height: 60px; fill: var(--fg); transition: fill .2s; }
.mic.listening { background: var(--red); border-color: var(--red); animation: pulse 1.4s ease-out infinite; }
.mic.listening svg { fill: #fff; }
.mic.busy { opacity: .35; pointer-events: none; }

.status { font-size: 22px; font-weight: 600; margin: 4px 0 8px; min-height: 1.3em; }
.transcript { font-size: 22px; line-height: 1.4; margin: 0 0 16px; min-height: 1.4em; max-width: 34em; }
.transcript .interim { color: #888; }

/* Objednávka / seznamy */
.card {
  width: 100%; text-align: left;
  border: 2px solid var(--fg); border-radius: 16px;
  padding: 16px 18px; margin-top: 4px;
}
.card h2 { margin-bottom: 6px; }

.list { list-style: none; padding: 0; margin: 0; }
.list li {
  display: flex; justify-content: space-between; gap: 12px;
  font-size: 22px; padding: 10px 0;
  border-bottom: 1px solid var(--line);
  animation: slidein .35s ease both;
}
.list li:last-child { border-bottom: 0; }
.list .qty { font-weight: 700; white-space: nowrap; }
.list-compact li { font-size: 17px; padding: 6px 0; }
.list-compact .note { display: block; font-size: 14px; color: var(--orange); font-weight: 600; }

.status-left, .transcript-left { text-align: left; }

/* Kdo vaří */
.chefs { display: grid; gap: 12px; margin-top: 12px; }
.chef {
  border: 3px solid var(--fg); border-radius: 16px; background: #fff;
  font-size: 34px; font-weight: 800; padding: 22px; cursor: pointer;
  transition: background .2s, color .2s, transform .1s;
}
.chef:active { transform: scale(.98); }
.chef.picked { background: var(--fg); color: #fff; animation: pop .4s ease both; }

/* Recepty */
.dish { border: 2px solid var(--fg); border-radius: 16px; padding: 12px 16px; margin-bottom: 12px; animation: fadein .4s ease both; }
.dish-head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; margin-bottom: 4px; }
.dish-head h2 { font-size: 21px; }
.dish-head span { font-weight: 700; white-space: nowrap; }
.notes { list-style: none; padding: 0; margin: 4px 0 0; }
.notes li { font-size: 18px; font-weight: 700; color: var(--orange); padding: 4px 0; animation: slidein .35s ease both; }

/* Kontroly */
.checks { list-style: none; padding: 0; margin: 18px 0 0; }
.checks li { display: flex; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--line); animation: slidein .35s ease both; }
.checks .icon {
  flex: none; width: 34px; height: 34px; border-radius: 50%;
  border: 4px solid var(--line); border-top-color: var(--fg);
  animation: spin .8s linear infinite;
}
.checks li.ok .icon {
  border: 0; background: var(--green); animation: pop .35s ease both;
  display: grid; place-items: center;
}
.checks li.ok .icon::after { content: "✓"; color: #fff; font-weight: 900; font-size: 20px; }
.checks .text { font-size: 22px; font-weight: 700; line-height: 1.25; }
.checks .detail { display: block; font-size: 16px; font-weight: 400; color: var(--muted); margin-top: 4px; }

/* Návrh: dva sloupce */
#screen-proposal { padding-bottom: 110px; }
.columns { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.supplier { border: 2px solid var(--fg); border-radius: 14px; overflow: hidden; display: flex; flex-direction: column; animation: rise .5s ease both; }
.supplier:nth-child(2) { animation-delay: .25s; }
.supplier-head {
  background: var(--bg); color: var(--fg-shop);
  font-weight: 900; font-size: 22px; text-align: center; padding: 12px 6px;
}
.supplier-head img { max-height: 34px; max-width: 90%; }
.supplier ul { list-style: none; padding: 4px 10px; margin: 0; flex: 1; }
.supplier li { padding: 7px 0; border-bottom: 1px solid var(--line); font-size: 15px; line-height: 1.25; }
.supplier li:last-child { border-bottom: 0; }
.supplier li .meta { display: flex; justify-content: space-between; gap: 6px; font-weight: 700; margin-top: 2px; }
.supplier li .note { display: block; font-size: 12px; color: var(--orange); font-weight: 700; }
.supplier-foot { border-top: 2px solid var(--fg); padding: 8px 10px; }
.supplier-foot .sum { font-size: 20px; font-weight: 900; }
.supplier-foot .vat { font-size: 13px; font-weight: 700; color: var(--muted); }
.vat-note { font-size: 15px; font-weight: 700; color: var(--muted); margin: -8px 0 12px; }
.supplier-foot .when { font-size: 14px; color: var(--muted); }
.editing .supplier li { cursor: pointer; background: #fff7ed; }
.edit-hint { font-size: 16px; font-weight: 700; color: var(--orange); margin: 0 0 10px; }
.sub strong { color: var(--fg); }

.actions {
  position: fixed; left: 0; right: 0; bottom: 0;
  display: flex; gap: 12px;
  padding: 14px 20px calc(14px + env(safe-area-inset-bottom));
  background: #fff; border-top: 1px solid var(--line);
  max-width: 560px; margin: 0 auto;
}
.btn {
  border: 0; border-radius: 14px; cursor: pointer;
  font-size: 24px; font-weight: 800; color: #fff;
  padding: 20px 10px;
  transition: transform .1s, filter .1s;
}
.btn:active { transform: scale(.97); filter: brightness(.92); }
.btn-green { background: var(--green); flex: 2; }
.btn-orange { background: var(--orange); flex: 1; }
.btn-ghost { background: none; color: var(--muted); font-size: 18px; font-weight: 600; display: block; margin: 30px auto 0; }

/* Objednáno */
.done { text-align: center; padding-top: 50px; }
.done-check {
  width: 130px; height: 130px; margin: 0 auto;
  border-radius: 50%; background: var(--green); color: #fff;
  font-size: 80px; line-height: 130px; font-weight: 900;
  animation: pop .5s ease both;
}
.done h1 { font-size: 40px; }
.done-line { font-size: 22px; margin: 0 0 10px; line-height: 1.35; }
.done-line span { color: var(--muted); }

@keyframes fadein { from { opacity: 0; } to { opacity: 1; } }
@keyframes rise { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@keyframes slidein { from { opacity: 0; transform: translateX(-12px); } to { opacity: 1; transform: none; } }
@keyframes pop { 0% { transform: scale(.6); opacity: 0; } 70% { transform: scale(1.06); opacity: 1; } 100% { transform: scale(1); } }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(225,29,46,.45); } 100% { box-shadow: 0 0 0 28px rgba(225,29,46,0); } }
@keyframes spin { to { transform: rotate(360deg); } }
