/* ==========================================================================
   Veřejná rezervační stránka (průvodce ve třech krocích) a zrušení rezervace.
   Barva firmy přichází v --accent / --accent-ink (nastavuje booking.php).
   ========================================================================== */

body.booking { background: var(--bg); }
body.booking.is-embed { background: transparent; min-height: 0; overflow: hidden; }
body.booking .eyebrow { color: var(--accent); }
body.booking .eyebrow::before { background: var(--accent); }

.bk { max-width: 700px; margin: 0 auto; padding: clamp(1.4rem, 4vw, 3rem) clamp(1rem, 3vw, 1.5rem) 3rem; }
.is-embed .bk { padding-top: .5rem; padding-bottom: 1.5rem; }
.bk--narrow { max-width: 520px; }

/* --- Hlavička --- */
.bk-head { margin-bottom: 1.6rem; }
.bk-logo { height: 48px; width: auto; margin-bottom: 1rem; }
.bk-title { font-size: clamp(1.7rem, 4.5vw, 2.4rem); letter-spacing: -.03em; }
.bk-sub { color: var(--muted); margin-top: .6rem; max-width: 56ch; }
.bk-demo-note { margin-top: .9rem; font-family: var(--font-mono); font-size: .76rem; color: var(--amber); display: inline-flex; gap: .45rem; align-items: center; border: 1px solid rgba(227, 168, 58, .4); border-radius: var(--r-sm); padding: .4rem .7rem; }

/* --- Kroky --- */
.bk-steps { list-style: none; display: grid; grid-template-columns: repeat(3, 1fr); gap: .5rem; margin-bottom: 1.2rem; }
.bk-steps li { border-top: 2px solid var(--line-2); padding-top: .55rem; color: var(--muted); transition: border-color .25s, color .25s; }
.bk-steps li .n { display: block; font-family: var(--font-mono); font-size: .7rem; letter-spacing: .14em; }
.bk-steps li .t { display: block; font-family: var(--font-display); font-weight: 600; font-size: .95rem; margin-top: .1rem; }
.bk-steps li.is-active { border-color: var(--accent); color: var(--text); }
.bk-steps li.is-active .n { color: var(--accent); }
.bk-steps li.is-done { border-color: var(--accent); color: var(--muted); cursor: pointer; }
.bk-steps li.is-done .n { color: var(--accent); }

/* --- Panel --- */
.bk-panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); padding: clamp(1.2rem, 3vw, 1.8rem); margin-bottom: 1rem; }
.bk-h { font-size: 1.25rem; margin-bottom: 1rem; }
.bk-h3 { font-family: var(--font-mono); font-size: .74rem; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); font-weight: 700; margin: 1.4rem 0 .8rem; }
.bk-h-row { display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; }
.bk-h-row .bk-h { margin-bottom: 0; }
.bk-h-row + .bk-cal, .bk-h-row + .bk-summary { margin-top: 1rem; }
.bk-chosen { font-size: .9rem; color: var(--muted); margin: .6rem 0 1rem; }
.bk-chosen strong { color: var(--text); }
.bk-center { text-align: center; padding: 2.5rem 1.5rem; }
.bk-center .btn { margin-top: 1.2rem; }
.bk-lead { font-size: 1.05rem; margin-bottom: 1rem; }
.bk-fine { font-size: .82rem; color: var(--muted); margin-top: 1rem; line-height: 1.55; }
.bk-fine .link { color: var(--accent); }
body.booking .link-btn { color: var(--accent); }

/* --- Služby --- */
.svc-list { display: grid; gap: .6rem; }
.svc { width: 100%; text-align: left; display: flex; justify-content: space-between; align-items: center; gap: 1rem; min-width: 0; background: var(--bg-alt); border: 1px solid var(--line); border-radius: var(--r-sm); padding: .95rem 1.1rem; transition: border-color .2s, transform .2s, background-color .2s; }
body.theme-light .svc { background: var(--surface-2); }
.svc:hover { border-color: var(--accent); transform: translateY(-2px); }
.svc:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.svc.is-selected { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent) inset; }
.svc-name { display: block; font-family: var(--font-display); font-weight: 600; font-size: 1.05rem; }
.svc-desc { display: block; color: var(--muted); font-size: .86rem; margin-top: .2rem; line-height: 1.45; }
.svc-meta { text-align: right; flex: none; align-self: flex-start; font-family: var(--font-mono); font-size: .8rem; color: var(--muted); display: grid; gap: .2rem; }
.svc-meta .price { color: var(--text); font-weight: 700; font-size: .95rem; }

/* --- Kalendář --- */
.cal-nav { display: flex; align-items: center; justify-content: space-between; gap: .6rem; margin-bottom: .8rem; }
.cal-nav .cal-month { font-family: var(--font-display); font-weight: 600; font-size: 1.05rem; text-transform: capitalize; }
.cal-nav button { width: 38px; height: 38px; border: 1px solid var(--line-2); border-radius: var(--r-sm); color: var(--text); display: grid; place-items: center; transition: border-color .2s, color .2s; }
.cal-nav button:hover { border-color: var(--accent); color: var(--accent); }
.cal-nav button:disabled { opacity: .3; cursor: not-allowed; border-color: var(--line); color: var(--muted); }
.cal-nav button .ico { width: 18px; height: 18px; }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.cal-dow { font-family: var(--font-mono); font-size: .68rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); text-align: center; padding: .3rem 0 .5rem; }
.cal-day { position: relative; aspect-ratio: 1 / .92; min-height: 42px; border-radius: var(--r-sm); border: 1px solid transparent; font-family: var(--font-mono); font-size: .9rem; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .15rem; color: var(--muted-2); background: transparent; cursor: default; transition: border-color .15s, background-color .15s, color .15s, transform .15s; }
.cal-day.is-open { color: var(--text); background: var(--bg-alt); border-color: var(--line); cursor: pointer; }
body.theme-light .cal-day.is-open { background: var(--surface-2); }
.cal-day.is-open:hover { border-color: var(--accent); transform: translateY(-1px); }
.cal-day.is-open:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.cal-day.is-open .free { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.cal-day.is-full { color: var(--muted); text-decoration: line-through; }
.cal-day.is-today { font-weight: 700; }
.cal-day.is-today::after { content: ""; position: absolute; top: 4px; right: 5px; width: 5px; height: 5px; border-radius: 50%; background: var(--muted); }
.cal-day.is-selected { background: var(--accent) !important; color: var(--accent-ink) !important; border-color: var(--accent) !important; }
.cal-day.is-selected .free { background: var(--accent-ink); }
.cal-day.is-empty { visibility: hidden; }
.cal-legend { display: flex; flex-wrap: wrap; gap: .4rem 1.1rem; margin-top: .8rem; font-family: var(--font-mono); font-size: .7rem; color: var(--muted); }
.cal-legend span { display: inline-flex; align-items: center; gap: .4rem; }
.cal-legend i { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.cal-legend .l-open { background: var(--accent); }
.cal-legend .l-full { background: var(--muted); }
.cal-legend .l-closed { border: 1px solid var(--line-2); }
.cal-loading { opacity: .5; pointer-events: none; }

/* --- Časy --- */
.slot-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(88px, 1fr)); gap: .5rem; }
.slot { font-family: var(--font-mono); font-size: .92rem; font-weight: 700; padding: .7rem .4rem; border-radius: var(--r-sm); border: 1px solid var(--line-2); background: var(--bg-alt); color: var(--text); transition: border-color .15s, background-color .15s, color .15s, transform .15s; }
body.theme-light .slot { background: var(--surface-2); }
.slot:hover { border-color: var(--accent); transform: translateY(-2px); }
.slot:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.slot.is-selected { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.slot-empty { color: var(--muted); font-size: .92rem; padding: .6rem 0; }

/* --- Souhrn a formulář --- */
.bk-summary { display: grid; gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--r-sm); overflow: hidden; margin-bottom: 1.3rem; }
.bk-summary .row { display: flex; justify-content: space-between; gap: 1rem; background: var(--bg-alt); padding: .6rem .9rem; font-size: .92rem; }
body.theme-light .bk-summary .row { background: var(--surface-2); }
.bk-summary .label { font-family: var(--font-mono); font-size: .7rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); padding-top: .15rem; }
.bk-summary .value { font-weight: 600; text-align: right; }
.bk-summary .value.accent { color: var(--accent); }
.bk-summary .row.total .value { font-family: var(--font-display); font-size: 1.05rem; }
body.booking .field input:focus, body.booking .field textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 18%, transparent); }
body.booking .check input:checked { background: var(--accent); border-color: var(--accent); }
body.booking .check input:checked::after { border-color: var(--accent-ink); }
#bkForm .btn-block { margin-top: .4rem; }

/* --- Hotovo / stavy --- */
.bk-status { width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; margin-bottom: 1rem; }
.bk-status .ico { width: 28px; height: 28px; }
.bk-status.ok { background: var(--accent-soft); color: var(--accent); }
.bk-status.info { background: var(--blue-soft); color: var(--blue); }
.bk-status.err { background: var(--red-soft); color: var(--red); }
.bk-done h2 { font-size: 1.5rem; margin-bottom: .5rem; }
.bk-done .bk-lead { color: var(--muted); font-size: 1rem; }
.bk-done-actions { display: flex; flex-wrap: wrap; gap: .6rem; margin-top: 1.2rem; }
.bk-done-actions .btn { min-height: 44px; }
.bk-success-text { border-left: 2px solid var(--accent); padding-left: 1rem; color: var(--text); margin: 1rem 0; }

/* --- Patička --- */
.bk-foot { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .8rem 1.5rem; margin-top: 1.4rem; padding-top: 1.2rem; border-top: 1px solid var(--line); }
.bk-contact { display: flex; flex-wrap: wrap; gap: .5rem 1.3rem; font-size: .86rem; color: var(--muted); }
.bk-contact a, .bk-contact span { display: inline-flex; align-items: center; gap: .4rem; }
.bk-contact a:hover { color: var(--accent); }
.bk-contact .ico { width: 15px; height: 15px; }
.bk-powered { font-family: var(--font-mono); font-size: .7rem; letter-spacing: .06em; color: var(--muted-2); transition: color .2s; }
.bk-powered strong { color: var(--muted); font-weight: 700; }
.bk-powered:hover, .bk-powered:hover strong { color: var(--accent); }

@media (max-width: 560px) {
  .svc { flex-direction: column; align-items: stretch; gap: .5rem; }
  .svc-meta { text-align: left; grid-auto-flow: column; justify-content: start; gap: 1rem; }
  .bk-steps li .t { font-size: .85rem; }
  .cal-day { min-height: 40px; font-size: .84rem; }
  .slot-grid { grid-template-columns: repeat(3, 1fr); }
}
