/* ═══════════════════════════════════════════════════════════════
   PNEUSERVIS TROJAN — ZÁKAZNICKÝ WEB
   ───────────────────────────────────────────────────────────────
   • Manrope, černo-bílá paleta s odstíny šedé
   • Moderní layout, animace, hover efekty
   • Plně responzivní (mobil → desktop)
═══════════════════════════════════════════════════════════════ */

* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  /* Paleta — sjednoceno s pneutrojan.cz */
  --c-text:       #0f172a;
  --c-white:      #F9F9F9;
  --c-bg-soft:    #eef2f6;
  --c-primary:    #0b5aa6;
  --c-primary-2:  #0a3f75;
  --c-accent:     #d51f2f;
  --c-accent-soft: rgba(213, 31, 47, 0.06);

  /* Aliasy zachované pro stávající selektory v souboru */
  --ink:          #0f172a;
  --ink-soft:     #1E293B;
  --ink-softer:   #334155;
  --muted:        #555555;
  --muted-soft:   #888888;
  --line:         rgba(15, 23, 42, 0.18);
  --line-soft:    rgba(15, 23, 42, 0.10);
  --line-softer:  rgba(15, 23, 42, 0.06);
  --bg:           #ffffff;
  --bg-soft:      #eef2f6;
  --bg-softer:    #F9F9F9;

  /* Borders v pneutrojan.cz stylu */
  --b-soft:       1px solid rgba(15, 23, 42, 0.10);
  --b-soft-2:     1px solid rgba(15, 23, 42, 0.08);
  --b-accent:     1px solid rgba(213, 31, 47, 0.22);

  /* Stavová UI — warning/success/error */
  --warning-bg:   #fef3c7;
  --warning-fg:   #92400e;
  --warning-line: #f59e0b;
  --success-bg:   #d1fae5;
  --success-fg:   #065f46;
  --success-line: #10b981;
  --error-bg:     #fee2e2;
  --error-fg:     #991b1b;
  --error-line:   #ef4444;

  /* Výstražná ikona (trojúhelník) — pro masku v .form-error */
  --icon-warning: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M10.29 3.86L1.82 18a2 2 0 0 0 1.71 3h16.94a2 2 0 0 0 1.71-3L13.71 3.86a2 2 0 0 0-3.42 0z'/%3E%3Cline x1='12' y1='9' x2='12' y2='13'/%3E%3Cline x1='12' y1='17' x2='12.01' y2='17'/%3E%3C/svg%3E");

  /* Stíny — jemné, navy tón */
  --shadow-xs:    0 1px 2px rgba(15, 23, 42, 0.04);
  --shadow-sm:    0 10px 22px rgba(15, 23, 42, 0.06);
  --shadow:       0 10px 25px rgba(15, 23, 42, 0.06);
  --shadow-lg:    0 18px 35px rgba(15, 23, 42, 0.10);
  --shadow-card:  0 18px 40px rgba(15, 23, 42, 0.07);
  --shadow-xl:    0 30px 80px rgba(15, 23, 42, 0.18);

  /* Tvary — pneutrojan.cz hodnoty */
  --radius:       22px;
  --radius-sm:    16px;
  --radius-xs:    12px;
  --r-pill:       999px;

  /* Tranzice */
  --t-fast:       0.2s;
  --t-med:        0.3s;

  /* Layout */
  --max-w:        800px;
  --max-w-wide:   800px;
  --header-h:     64px;

  /* Spacing — striktní 8pt grid (4 hodnoty pokrývají všechno) */
  --sp-1:         8px;
  --sp-2:         16px;
  --sp-3:         24px;
  --sp-4:         32px;

  /* Sémantické tokeny — řídí celý layout, jeden zdroj pravdy */
  --gutter-x:     var(--sp-3);   /* horizontální okraj appky */
  --stack:        var(--sp-3);   /* vertikální okraj appky + mezera mezi sekcemi */
  --card-pad:     var(--sp-3);   /* vnitřní padding karet */
  --field-gap:    var(--sp-1);   /* label ↔ input */
}

/* Mobilní úprava semantic tokenů — menší appka, menší karty */
@media (max-width: 540px) {
  :root {
    --header-h:   52px;
    --gutter-x:   var(--sp-2);
    --stack:      var(--sp-2);
    --card-pad:   var(--sp-2);
  }
}

html, body {
  width: 100%;
  background: var(--c-white);
  color: var(--c-text);
  font-family: 'Manrope', system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.55;
  letter-spacing: -0.005em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

body {
  position: relative;
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh;   /* dynamic viewport — počítá s mobilní URL bar */
}

button, input, select, textarea {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
}
button { cursor: pointer; border: none; background: none; }
a { color: inherit; text-decoration: none; }

::selection { background: var(--ink); color: var(--bg); }

/* ═══════════════════════════════════════════════════════════════
   POZADÍ — animované gradienty + jemná mřížka
═══════════════════════════════════════════════════════════════ */
.bg-blob {
  position: fixed;
  z-index: -2;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.5;
  pointer-events: none;
  will-change: transform;
}
.bg-blob--1,
.bg-blob--2 {
  display: none;  /* BMW-M: empty space stays as empty canvas, no atmospheric backdrops */
}
@keyframes floatBlob {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33%      { transform: translate(60px, -40px) scale(1.08); }
  66%      { transform: translate(-40px, 50px) scale(0.95); }
}

.bg-grid {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    linear-gradient(to right, rgba(15, 23, 42, 0.04) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(15, 23, 42, 0.04) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse at center, black 30%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse at center, black 30%, transparent 75%);
}

/* ═══════════════════════════════════════════════════════════════
   HLAVIČKA + PATIČKA
═══════════════════════════════════════════════════════════════ */
.site-header {
  height: var(--header-h);
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: var(--sp-2);
  padding: 0 var(--gutter-x);
  background: var(--c-white);
  border-bottom: var(--b-soft);
  position: sticky;
  top: 0;
  z-index: 50;
  flex-shrink: 0;
}
.site-header > .brand { justify-self: start; }

/* Pill se zvoleným termínem — výrazný, uprostřed headeru */
.header-selection {
  justify-self: center;
  display: inline-flex;
  align-items: center;
  gap: 14px;
  padding: 13px 24px;
  background: var(--c-primary);
  border-radius: 999px;
  box-shadow: 0 10px 26px rgba(11, 90, 166, 0.42);
  color: #ffffff;
  max-width: 100%;
  min-width: 0;
  animation: headerSelIn 320ms cubic-bezier(0.16, 1, 0.3, 1);
}
.header-selection[hidden] { display: none; }
.header-selection-icon {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  color: #ffffff;
  opacity: 0.95;
}
/* Jednotný font, barva, velikost — vše zarovnáno na střed (baseline) */
.header-selection-text {
  display: inline-flex;
  align-items: baseline;
  justify-content: center;
  gap: 6px;
  min-width: 0;
  line-height: 1;
}
.header-selection-label,
.header-selection-date,
.header-selection-time {
  font-family: inherit;
  font-size: 18px;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: -0.005em;
  text-transform: none;
  line-height: 1;
  white-space: nowrap;
}
.header-selection-date {
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 36ch;
}
.header-selection-time {
  font-variant-numeric: tabular-nums;
}
.header-selection-time:empty { display: none; }

@keyframes headerSelIn {
  from { opacity: 0; transform: translateY(-4px); }
  to   { opacity: 1; transform: translateY(0); }
}
.brand {
  display: flex;
  align-items: center;
  transition: transform 220ms cubic-bezier(0.4, 0, 0.2, 1);
}
.brand:hover { transform: scale(1.04); }
.brand-logo {
  height: 44px;
  width: auto;
  display: block;
}
.header-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  line-height: 1.2;
}
.header-meta-label {
  font-weight: 700;
  font-size: 14px;
  color: var(--ink);
}
.header-meta-sub {
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.02em;
}

.site-footer {
  flex-shrink: 0;
  background: var(--c-bg-soft);
  text-align: center;
  padding: var(--sp-2) var(--gutter-x);
  font-size: 13px;
  color: var(--c-text);
  border-top: var(--b-soft);
}
.site-footer p { margin: 0; }

/* ═══════════════════════════════════════════════════════════════
   APP — vrstvy kroků
═══════════════════════════════════════════════════════════════ */
.app {
  flex: 1 1 auto;
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: var(--stack) var(--gutter-x);
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.step {
  display: none;
  flex: 1 1 auto;
  flex-direction: column;
  gap: var(--sp-3);                /* jednotný rytmus mezi prvky kroku */
  animation: stepIn 480ms cubic-bezier(0.16, 1, 0.3, 1);
}
.step.is-active { display: flex; }

/* Success krok se centruje vertikálně — je to potvrzovací obrazovka
   a vypadá líp uprostřed než přilepená nahoře. Ostatní kroky začínají
   těsně pod headerem, aby nebyla optická mezera nahoře. */
.step--success.is-active {
  justify-content: center;
}

@keyframes stepIn {
  from { opacity: 0; transform: translateY(18px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Hlavička každého kroku (mimo hero) */
.step-head {
  display: flex;
  align-items: center;
  gap: var(--sp-1);                 /* 8 px mezi tlačítkem zpět a textem */
  /* margin-bottom odstraněn — rytmus řídí gap na rodiči .step */
}
.step-back {
  flex: 0 0 auto;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-xs);
  background: var(--bg);
  border: 1.5px solid var(--line);
  color: var(--ink);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 180ms ease;
  box-shadow: var(--shadow-xs);
}
.step-back:hover {
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
  transform: translateX(-2px);
}
.step-back svg { width: 18px; height: 18px; }

.step-head-text {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-top: 2px;
}
.step-head-num {
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.step-head-title {
  font-size: 19px;
  font-weight: 800;
  color: var(--ink);
  letter-spacing: 0.01em;
  line-height: 1.15;
  text-transform: uppercase;
}
.step-head-context {
  font-size: 14px;
  color: var(--muted);
  margin-top: 2px;
}

/* ═══════════════════════════════════════════════════════════════
   HERO
═══════════════════════════════════════════════════════════════ */

/* HERO — text vlevo, žádný blok kolem.
   Rytmus mezi h1/h2/body řídí gap na .step (24 px). Vnitřní mezera
   uvnitř hero-text mezi h1 a h2 je menší (8 px) — patří k sobě. */
.hero-text {
  margin: 0;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: var(--sp-1);
  animation: heroFadeIn 700ms cubic-bezier(0.16, 1, 0.3, 1) both;
}
.hero-text h1 {
  font-size: clamp(26px, 4vw, 40px);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--c-text);
  margin: 0;
}
.hero-text h2 {
  font-size: clamp(14px, 1.4vw, 18px);
  font-weight: 500;
  color: var(--muted);
  margin: 0;
  line-height: 1.4;
  letter-spacing: -0.005em;
}

/* Tělo hero — alert + CTA. Rytmus mezi alert a actions je sp-3, parent gap (.step)
   řeší mezeru mezi .hero-text a .hero-body. */
.hero-body {
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
}
/* HERO — display titulek, decorative rule, alert s left-border, velký CTA */

.hero-title {
  display: flex;
  flex-direction: column;
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin: 0 0 8px;
  animation: heroFadeIn 700ms cubic-bezier(0.16, 1, 0.3, 1) 200ms both;
}
.hero-title-l1,
.hero-title-l2 {
  font-size: clamp(36px, 5vw, 56px);
  font-weight: 700;
  line-height: 1.05;
}
@keyframes heroFadeIn {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Upozornění — pneutrojan.cz infobox styl: bílý card, soft shadow, červený levý okraj */
.alert-box {
  position: relative;
  padding: var(--card-pad);
  margin: 0;
  background: #ffffff;
  border: var(--b-soft);
  border-left: 4px solid var(--c-accent);
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
  animation: heroFadeIn 700ms cubic-bezier(0.16, 1, 0.3, 1) 380ms both;
}

.alert-head {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-1);
  margin-bottom: var(--sp-1);
  padding-bottom: var(--sp-1);
  border-bottom: var(--b-soft-2);
  width: 100%;
}
.alert-icon {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  color: var(--c-accent);
}
.alert-title {
  font-size: 0.98rem;
  font-weight: 800;
  color: var(--c-text);
  line-height: 1;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.alert-text {
  font-size: 1rem;
  font-weight: 400;
  color: var(--c-text);
  line-height: 1.55;
}
.alert-text strong {
  font-weight: 700;
  color: var(--c-text);
}
/* Tlačítka v hero — 50/50 split na desktopu, stack na mobilu.
   margin-top odstraněn — řídí parent gap (.hero-body 24 px). */
.hero-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--sp-2);
}
.hero-actions .btn-cta {
  width: 100%;
  justify-content: center;
}

/* Sekundární tlačítko — telefon. Bílé pozadí, modrý text + border, hover invertuje */
.btn-cta--phone {
  background: #ffffff !important;
  color: var(--c-primary) !important;
  border: 2px solid var(--c-primary);
  box-shadow: 0 6px 14px rgba(11, 90, 166, 0.10) !important;
  text-decoration: none;
}
.btn-cta--phone:hover {
  background: var(--c-bg-soft) !important;
  color: var(--c-primary-2) !important;
  border-color: var(--c-primary-2);
  box-shadow: 0 10px 22px rgba(11, 90, 166, 0.18) !important;
}
.btn-cta--phone svg {
  width: 18px;
  height: 18px;
}
.alert-text em {
  font-style: normal;
  font-weight: 700;
  color: var(--c-text);
}

/* CTA na hero — moderní solid button, plný černý fill, lift na hover */
.step--hero .btn-cta {
  width: 100%;
  justify-content: center;
  gap: var(--sp-1);
  padding: var(--sp-2) var(--sp-3);
  font-size: 16px;
  font-weight: 700;
  animation: heroFadeIn 700ms cubic-bezier(0.16, 1, 0.3, 1) 480ms both;
}

/* CTA — solid navy + bílý text */
.btn-cta {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 14px 26px;
  background: var(--c-primary);
  color: #ffffff;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.005em;
  border-radius: var(--radius-xs);
  transition: all var(--t-fast) cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 8px 22px rgba(11, 90, 166, 0.25);
  position: relative;
}
.btn-cta:hover {
  background: var(--c-primary-2);
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(11, 90, 166, 0.35);
}
.btn-cta:hover::before { transform: translateX(100%); }
.btn-cta:active { transform: translateY(0); }
.btn-cta svg { width: 18px; height: 18px; }
.btn-cta--full { width: 100%; justify-content: center; }
.btn-cta--ghost {
  background: var(--bg);
  color: var(--ink);
  border: 1.5px solid var(--line);
  box-shadow: var(--shadow-xs);
}
.btn-cta--ghost:hover {
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
}
.btn-cta:disabled,
.btn-cta.is-loading {
  pointer-events: none;
  opacity: 0.85;
}
.btn-cta.is-loading .btn-cta-label,
.btn-cta.is-loading .btn-cta-icon { opacity: 0; }
.btn-cta-spinner {
  position: absolute;
  width: 22px;
  height: 22px;
  border: 2.5px solid rgba(255, 255, 255, 0.3);
  border-top-color: #fff;
  border-radius: 50%;
  opacity: 0;
  animation: spin 750ms linear infinite;
}
.btn-cta.is-loading .btn-cta-spinner { opacity: 1; }
@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Hero feature steps */
.hero-features {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 36px;
  padding-top: 24px;
  border-top: 1px solid var(--line-soft);
  flex-wrap: wrap;
}
.hero-feature {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  color: var(--ink-softer);
  font-weight: 500;
}
.hero-feature-num {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--ink);
  color: var(--bg);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 13px;
}
.hero-feature-line {
  flex: 1;
  min-width: 24px;
  height: 1.5px;
  background: var(--line-soft);
  border-radius: 999px;
}

/* ═══════════════════════════════════════════════════════════════
   KALENDÁŘ
═══════════════════════════════════════════════════════════════ */
.calendar-card {
  background: var(--bg);
  border: var(--b-soft);
  border-radius: var(--radius);
  padding: 24px 24px 18px;
  box-shadow: var(--shadow-card);
}

/* Kombinovaná karta — kalendář nahoře, časy pod ním (collapsable). */
.datetime-card {
  background: var(--bg);
  border: var(--b-soft);
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.datetime-section {
  padding: var(--card-pad);
  min-width: 0;
}
.datetime-divider {
  height: 1px;
  background: var(--line-soft);
  margin: 0;
}
.datetime-time {
  padding: var(--card-pad);
}

/* Wrap kolem časové sekce — rozbalovací animace */
/* Wrap je vždy viditelný — uvnitř se přepíná obsah (prompt ↔ časy) */
.datetime-time-wrap {
  display: block;
}
.datetime-time-wrap[data-open="true"] .datetime-time {
  animation: timeContentIn 320ms cubic-bezier(0.16, 1, 0.3, 1) 80ms both;
}
@keyframes timeContentIn {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: translateY(0); }
}

.cal-month-label {
  text-align: center;
  font-size: 16px;
  font-weight: 700;
  color: var(--c-text);
  text-transform: capitalize;
  letter-spacing: 0.02em;
  flex: 1;
}

/* Spacer — prázdná, neklikatelná cela pro nedostupné dny.
   Zachovává sloupcové zarovnání + tabulkové ohraničení. */
.cal-day.is-spacer {
  background: var(--c-bg-soft);    /* jemně šedé pozadí — vizuálně signalizuje "nedostupné" */
  cursor: default;
  pointer-events: none;
}

/* Wrap kolem časové sekce — rozbalovací animace přes grid-template-rows.
   Trik s 0fr → 1fr funguje plynule i bez fixní výšky. */
/* Wrap je vždy viditelný — uvnitř se přepíná obsah (prompt ↔ časy) */
.datetime-time-wrap {
  display: block;
}
/* Obsah uvnitř časové sekce má fade-in animaci po rozbalení */
.datetime-time-wrap[data-open="true"] .datetime-time {
  animation: timeContentIn 320ms cubic-bezier(0.16, 1, 0.3, 1) 80ms both;
}
@keyframes timeContentIn {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Záhlaví výběru času — ukazuje vybraný den */
.time-day-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  margin-bottom: 8px;
  padding-bottom: 6px;
  border-bottom: var(--b-soft-2);
}
.time-day-label strong {
  color: var(--c-text);
  font-weight: 700;
}

/* Placeholder, když ještě není vybraný den */
.time-placeholder {
  text-align: center;
  padding: 18px 18px 6px;
  color: var(--muted);
  font-size: 14.5px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}
.time-placeholder .time-empty-icon {
  width: 36px;
  height: 36px;
  color: var(--muted-soft);
  opacity: 0.7;
}

.cal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}
.cal-nav {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-xs);
  background: var(--bg-soft);
  color: var(--ink);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 180ms ease;
}
.cal-nav:hover:not(:disabled) {
  background: var(--ink);
  color: var(--bg);
  transform: scale(1.05);
}
.cal-nav:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}
.cal-nav svg { width: 18px; height: 18px; }

.cal-month-label {
  font-size: 18px;
  font-weight: 800;
  color: var(--ink);
  text-transform: capitalize;
  letter-spacing: -0.015em;
  flex: 1;
  text-align: center;
}

/* Kalendář: pevná 5-sloupcová mřížka (Po–Pá), kachle dostupných dnů
   pod hlavičkou Po/Út/St/Čt/Pá, nedostupné dny jako neviditelné spacer cely */
/* Floating-card kalendář — karty s jemným stínem, hover lift, modrá selekce */
.cal-table {
  background: transparent;
}

/* Tabulkový obal kalendáře — outer rámeček + zaoblené rohy */
.cal-table {
  border: 1px solid var(--line-soft);
  border-radius: 14px;
  overflow: hidden;
  background: var(--bg);
}

.cal-weekdays {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  background: var(--c-bg-soft);
  border-bottom: 1px solid var(--line-soft);
}
.cal-weekdays span {
  text-align: center;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--c-text);
  padding: 10px 0;
  line-height: 1;
  border-right: 1px solid var(--line-soft);
}
.cal-weekdays span:last-child { border-right: 0; }

.cal-days {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  position: relative;
}
/* Loading spinner potřebuje výšku, jinak by byl 0 */
.cal-days:has(.cal-loading) { min-height: 120px; }
/* (sjednoceno do jednoho pravidla výše — viz .cal-day.is-spacer) */
.cal-loading {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.spinner {
  width: 32px;
  height: 32px;
  border: 3px solid var(--line-soft);
  border-top-color: var(--c-primary);
  border-radius: 50%;
  animation: spin 800ms linear infinite;
}

/* Empty stav — žádné dostupné dny */
.cal-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 32px 16px;
  color: var(--muted);
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.cal-empty strong {
  font-size: 16px;
  font-weight: 700;
  color: var(--c-text);
  letter-spacing: -0.005em;
}
.cal-empty span {
  font-size: 14px;
  color: var(--muted);
}

/* Jednotlivá kachle dne — tabulková buňka */
.cal-day {
  cursor: pointer;
  background: var(--bg);
  border-right: 1px solid var(--line-soft);
  border-bottom: 1px solid var(--line-soft);
  padding: 10px 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--c-text);
  transition: background-color 160ms ease, color 160ms ease;
  position: relative;
  font-family: inherit;
}
.cal-day:nth-child(5n) { border-right: 0; }
.cal-day-num {
  font-size: 18px;
  font-weight: 700;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.cal-day:hover {
  background: rgba(11, 90, 166, 0.08);
  color: var(--c-primary-2);
}

/* DNES — červený trojúhelníkový roh (folded-flag look) */
.cal-day.is-today { font-weight: 800; }

/* VYBRÁNO — solid navy fill, bílé číslo */
.cal-day.is-selected {
  background: var(--c-primary);
  color: #ffffff;
}
.cal-day.is-selected:hover {
  background: var(--c-primary-2);
  color: #ffffff;
}

/* (sjednoceno do jednoho pravidla výše — viz .cal-day.is-spacer) */

/* ═══════════════════════════════════════════════════════════════
   ČAS
═══════════════════════════════════════════════════════════════ */
.time-card {
  background: var(--bg);
  border: var(--b-soft);
  border-radius: var(--radius);
  padding: 28px 24px;
  box-shadow: var(--shadow-card);
  min-height: 280px;
  position: relative;
}

.time-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 60px 0;
  color: var(--muted);
  font-size: 14px;
}

.time-section-label {
  font-size: 11px;
  font-weight: 800;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.time-section-label::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line-soft);
}
.time-section + .time-section { margin-top: 22px; }

/* Prompt — výzva uživateli, dokud nezvolí den */
.time-prompt {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 18px;
  background: var(--c-bg-soft);
  border: 1px dashed var(--line);
  border-radius: 12px;
  color: var(--ink-softer);
  font-size: 14.5px;
  font-weight: 500;
  line-height: 1.4;
}
.time-prompt-icon {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  color: var(--c-primary);
}

/* Nadpis nad časovým gridem */
.time-heading {
  font-size: 14px;
  font-weight: 700;
  color: var(--c-text);
  margin-bottom: 10px;
  letter-spacing: 0.01em;
}

/* Časový grid — tabulkový styl s rounded outer borderem */
.time-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  border: 1px solid var(--line-soft);
  border-radius: 14px;
  overflow: hidden;
  background: var(--bg);
}

/* Continue button — pod kalendářní kartou, vždy viditelný.
   margin-top odstraněn — řídí parent gap (.step 24 px). */
.datetime-continue {
  display: flex;
  justify-content: center;
}
.datetime-continue .btn-cta {
  width: 100%;
  max-width: 360px;
  justify-content: center;
  padding: var(--sp-2) var(--sp-3);
  font-size: 16px;
}
/* Disabled stav — solid šedá s okrajem, žádný gradient ani stín */
.btn-cta:disabled {
  background: var(--c-bg-soft) !important;
  background-image: none !important;
  color: var(--muted-soft) !important;
  border: 1.5px solid var(--line) !important;
  cursor: not-allowed;
  box-shadow: none !important;
  pointer-events: none;
  opacity: 1;
  -webkit-appearance: none;
          appearance: none;
}
.btn-cta:disabled::before { display: none; }
.btn-cta:disabled::after { display: none; }
.btn-cta:disabled:hover {
  background: var(--c-bg-soft) !important;
  color: var(--muted-soft) !important;
  border-color: var(--line) !important;
  transform: none !important;
  box-shadow: none !important;
}

/* Time slot — tabulková buňka, sdílené borders, žádný shadow */
.time-slot {
  cursor: pointer;
  padding: 10px 6px;
  font-family: inherit;
  font-size: 16px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0;
  color: var(--c-text);
  background: var(--bg);
  border: none;
  border-right: 1px solid var(--line-soft);
  border-bottom: 1px solid var(--line-soft);
  transition: background-color 160ms ease, color 160ms ease;
  position: relative;
}
.time-slot:nth-child(5n) { border-right: 0; }
.time-slot:hover {
  background: rgba(11, 90, 166, 0.08);
  color: var(--c-primary-2);
}
.time-slot.is-selected,
.time-slot:active {
  background: var(--c-primary);
  color: #ffffff;
}
.time-slot.is-selected:hover {
  background: var(--c-primary-2);
  color: #ffffff;
}

.time-empty {
  text-align: center;
  padding: 50px 20px;
  color: var(--muted);
}
.time-empty-icon {
  width: 48px;
  height: 48px;
  margin: 0 auto 14px;
  color: var(--muted-soft);
  display: block;
}
.time-empty-title {
  font-size: 17px;
  font-weight: 800;
  color: var(--ink);
  margin-bottom: 6px;
  letter-spacing: -0.01em;
}
.time-empty-text {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.5;
  max-width: 380px;
  margin: 0 auto;
}

/* ═══════════════════════════════════════════════════════════════
   FORMULÁŘ
═══════════════════════════════════════════════════════════════ */
.form-card {
  background: var(--bg);
  border: var(--b-soft);
  border-radius: var(--radius);
  padding: var(--card-pad);
  box-shadow: var(--shadow-card);
  display: grid;
  grid-template-columns: 1fr 1fr;   /* 2 sloupce na desktopu */
  gap: var(--sp-2);
}
/* Submit button se roztáhne přes oba sloupce */
.form-card > .btn-cta {
  grid-column: 1 / -1;
}

.field {
  display: flex;
  flex-direction: column;
  gap: var(--field-gap);
}
.field label {
  font-size: 13px;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -0.005em;
}
.required {
  color: var(--error-line);
  font-weight: 800;
  margin-left: 2px;
}
.field input,
.field textarea {
  padding: 10px 12px;
  background: var(--bg);
  border: 1.5px solid var(--line);
  border-radius: var(--radius-xs);
  /* 16px = minimum, který Safari na iOS netriggeruje auto-zoom při fokusu.
     Nesnižovat ani v media query — některé telefony jsou v landscape širší než 540px. */
  font-size: 16px;
  font-weight: 500;
  color: var(--ink);
  transition: all 180ms ease;
  outline: none;
}
/* Textarea (poznámka) — sdílí styl i metriky s inputy (výchozí výška = jeden
   řádek jako ostatní pole). Výšku dopočítává JS podle obsahu, proto resize
   vypnutý a overflow skrytý (žádný posuvník při růstu). */
.field textarea {
  resize: none;
  overflow: hidden;
}
.field input::placeholder,
.field textarea::placeholder {
  color: var(--muted-soft);
  font-weight: 400;
}
.field input:hover,
.field textarea:hover { border-color: var(--c-primary); }
.field input:focus,
.field textarea:focus {
  border-color: var(--c-primary);
  box-shadow: 0 0 0 4px rgba(11, 90, 166, 0.12);
}
.field input.is-invalid,
.field textarea.is-invalid {
  border-color: var(--error-line);
  background: var(--error-bg);
}
.field input.is-invalid:focus,
.field textarea.is-invalid:focus {
  box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.12);
}
/* Field-hint pod inputem — menší šedý text */
.field-hint {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.4;
}

/* Drobná značka "(nepovinné)" vedle labelu */
.field-optional {
  font-size: 12px;
  font-weight: 500;
  color: var(--muted);
  letter-spacing: 0;
  margin-left: 4px;
}

/* Form-error v hlavičce kroku — absolutně přes celý step-head,
   centrováno horizontálně + vertikálně přes flex. */
.form-error {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: var(--sp-2);
  padding: 0 4px;
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1.5;
  color: var(--error-fg);
  text-align: left;
  animation: shake 380ms cubic-bezier(0.36, 0.07, 0.19, 0.97);
}
.form-error::before {
  content: "";
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  background-color: currentColor;
  -webkit-mask: var(--icon-warning) center / contain no-repeat;
  mask: var(--icon-warning) center / contain no-repeat;
}
.form-error[hidden] { display: none; }

/* Summary-error zůstává jako červený box (uvnitř karty shrnutí) */
.summary-error {
  padding: 12px 14px;
  background: var(--error-bg);
  color: var(--error-fg);
  border: 1.5px solid var(--error-line);
  border-radius: var(--radius-xs);
  font-size: 14px;
  font-weight: 600;
  animation: shake 380ms cubic-bezier(0.36, 0.07, 0.19, 0.97);
}
@keyframes shake {
  10%, 90% { transform: translateX(-1px); }
  20%, 80% { transform: translateX(2px); }
  30%, 50%, 70% { transform: translateX(-4px); }
  40%, 60% { transform: translateX(4px); }
}

/* ═══════════════════════════════════════════════════════════════
   SHRNUTÍ
═══════════════════════════════════════════════════════════════ */
.summary-card {
  background: var(--bg);
  border: var(--b-soft);
  border-radius: var(--radius);
  padding: var(--card-pad);
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
}

/* Summary banner — stejný styl jako alert-box v hero, ale s modrou barvou */
.summary-banner {
  position: relative;
  padding: var(--card-pad);
  margin: 0;
  background: #ffffff;
  border: var(--b-soft);
  border-left: 4px solid var(--c-primary);
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
}
.summary-banner-head {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-1);
  margin-bottom: var(--sp-1);
  color: var(--c-primary);
}
.summary-banner-icon {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  color: var(--c-primary);
}
.summary-banner-title {
  font-size: 17px;
  font-weight: 800;
  letter-spacing: -0.01em;
  text-transform: none;
  color: var(--c-primary-2);
  line-height: 1.2;
}
.summary-banner-text {
  font-size: 16px;
  font-weight: 600;
  color: var(--c-text);
  line-height: 1.5;
  margin: 0;
}

.summary-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid var(--line-soft);
}
.summary-row {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: var(--sp-2);
  padding: var(--sp-2);
  border-bottom: 1px solid var(--line-soft);
  align-items: baseline;
}
.summary-row:last-child { border-bottom: none; }
.summary-row:nth-child(odd) { background: var(--bg-softer); }
.summary-row dt {
  font-size: 14px;
  font-weight: 700;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.summary-row dd {
  font-size: 17px;
  font-weight: 600;
  color: var(--ink);
  word-break: break-word;
}
.summary-row dd.is-highlight {
  font-weight: 800;
  font-size: 19px;
  letter-spacing: -0.01em;
}

/* ═══════════════════════════════════════════════════════════════
   ÚSPĚCH
═══════════════════════════════════════════════════════════════ */
.success-card {
  background: var(--bg);
  border: var(--b-soft);
  border-radius: var(--radius);
  padding: var(--sp-4) var(--card-pad);
  box-shadow: var(--shadow-card);
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--sp-2);
}
.success-icon {
  width: 80px;
  height: 80px;
  color: var(--success-line);
}
.success-icon svg {
  width: 100%;
  height: 100%;
}
.success-circle {
  stroke-dasharray: 152;
  stroke-dashoffset: 0;
  animation: drawCircle 600ms cubic-bezier(0.16, 1, 0.3, 1) 100ms both;
}
.success-check {
  stroke-dasharray: 50;
  stroke-dashoffset: 0;
  animation: drawCheck 380ms cubic-bezier(0.16, 1, 0.3, 1) 600ms both;
}
@keyframes drawCircle {
  from { stroke-dashoffset: 152; }
  to   { stroke-dashoffset: 0; }
}
@keyframes drawCheck {
  from { stroke-dashoffset: 50; }
  to   { stroke-dashoffset: 0; }
}

.success-card h2 {
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--ink);
}
.success-card > p {
  font-size: 15.5px;
  color: var(--muted);
  line-height: 1.6;
  max-width: 460px;
}
.success-card strong { color: var(--ink); font-weight: 700; }

/* Sekundární poznámka o spam složce — jemnější styl */
.success-spam-hint {
  font-size: 13.5px;
  color: var(--muted);
  margin-top: 4px;
}
.success-spam-hint strong {
  color: var(--c-text);
  font-weight: 700;
}

/* Tlačítka v success kartě — vedle sebe na desktopu, pod sebou na mobilu.
   margin-top odstraněn — řídí parent gap (.success-card 16 px). */
.success-actions {
  display: flex;
  gap: var(--sp-2);
  flex-wrap: wrap;
  justify-content: center;
  width: 100%;
}
.success-actions .btn-cta {
  flex: 1 1 220px;
  max-width: 280px;
  justify-content: center;
  text-align: center;
}

/* ═══════════════════════════════════════════════════════════════
   TOAST
═══════════════════════════════════════════════════════════════ */
/* ═══════════════════════════════════════════════════════════════
   RESPONZIVNÍ ÚPRAVY
═══════════════════════════════════════════════════════════════ */
@media (max-width: 540px) {
  /* Header — kompaktnější logo a pill, hlavní rozměry řídí tokeny */
  .brand-logo { height: 32px; }
  .header-selection { padding: var(--sp-1) var(--sp-2); gap: var(--sp-1); }
  .header-selection-icon { width: 18px; height: 18px; }
  .header-selection-label,
  .header-selection-date,
  .header-selection-time { font-size: 13.5px; }
  .header-selection-date { max-width: none; overflow: visible; text-overflow: clip; }

  /* Když je viditelný pill, schovej logo a vycentruj pill */
  .site-header:has(.header-selection:not([hidden])) {
    grid-template-columns: 1fr;
    justify-items: center;
  }
  .site-header:has(.header-selection:not([hidden])) .brand { display: none; }
  .header-selection { justify-self: center; }

  /* Hero — menší typografie, tlačítka pod sebe */
  .hero-text h2 { font-size: 14px; }
  .alert-title { font-size: 0.9rem; }
  .alert-text { font-size: 0.95rem; }
  .step--hero .btn-cta { padding: var(--sp-2); font-size: 15px; }
  .hero-actions { grid-template-columns: 1fr; gap: var(--sp-1); }

  /* Step-head titulky */
  .step-head-title { font-size: 18px; }

  /* Kalendář — kompaktnější tabulka */
  .cal-table { border-radius: 12px; }
  .cal-weekdays span { font-size: 12px; padding: var(--sp-1) 0; }
  .cal-day { padding: var(--sp-1) var(--sp-0, 4px); }
  .cal-day-num { font-size: 17px; }
  .cal-month-label { font-size: 16px; }

  /* Časové sloty */
  .time-grid { border-radius: 12px; }
  .time-slot { padding: var(--sp-1) var(--sp-0, 4px); font-size: 15px; }

  /* Formulář — jeden sloupec (font-size 16px je nastavený globálně) */
  .form-card { grid-template-columns: 1fr; }

  /* Summary — jeden sloupec na řádek (label nad value) */
  .summary-row { grid-template-columns: 1fr; gap: 2px; padding: var(--sp-1) var(--sp-2); }
  .summary-row dt { font-size: 11px; }
  .summary-row dd { font-size: 16px; }
  .summary-row dd.is-highlight { font-size: 18px; }

  /* Success */
  .success-card h2 { font-size: 22px; }
  .success-icon { width: 64px; height: 64px; }
}

/* ═══════════════════════════════════════════════════════════════
   ULTRA-KOMPAKTNÍ — velmi nízké viewporty (landscape, malé androidy)
   Cíl: eliminovat scroll i zde. Zmenší vertikální rytmus,
   skryje footer (jen v tomto extrémním případě), zmenší padding karet.
═══════════════════════════════════════════════════════════════ */
@media (max-height: 720px) {
  :root {
    --stack:     var(--sp-2);
    --card-pad:  var(--sp-2);
  }
  .step { gap: var(--sp-2); }
}

@media (max-height: 560px) {
  :root {
    --header-h:  44px;
    --stack:     var(--sp-1);
  }
  .step { gap: var(--sp-1); }
  .hero-text h1 { font-size: 22px; }
  .hero-text h2 { font-size: 13px; }
  .alert-box { padding: var(--sp-2); }
  .alert-text { font-size: 14px; }
  .step--hero .btn-cta { padding: var(--sp-1) var(--sp-2); }
  .site-footer { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* Honeypot — neviditelný pro člověka, ale stále v DOM pro boty.
   Nepoužívá display:none ani visibility:hidden (boti to detekují).
   Kombinace clip-path + clip + 1×1 px + overflow: hidden je nejrobustnější
   "visually-hidden" technika (stejnou používají a11y knihovny).
   pointer-events: none + tabindex=-1 zabrání kliknutí i tabu. */
.hp-field {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  border: 0 !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  clip-path: inset(50%) !important;
  white-space: nowrap !important;
  opacity: 0 !important;
  pointer-events: none !important;
}
