/* Smile4U v8 · shared components: the live cards (L2: hours + Google; V8-SYSTEM §5 "L2 cards") and the booking panel
   (V8-BLOCKS §13). Markup: _tools/kit.py (card_hours, card_google, panel). Behaviour: js/core/cards.js, booking.js.
   Blocks place and size the cards; they never restyle their insides. */

/* ---- cards: paper, radius 12, padding 24 / 36, figure 48; no shadow, no hairline (makro's cards are flat on the photo) ---- */
.card {
  position: relative; min-width: 0; padding: 24px 36px; border-radius: var(--r-sm); background: var(--paper); color: var(--ink);
}
.card-status { font-size: var(--fs-h5); line-height: 1.35; letter-spacing: var(--ls-h5); }
.card-line { display: block; white-space: nowrap; }          /* status on one line, the next opening on the next (S9) */
.card-figure { display: block; font-size: var(--fs-figure); line-height: 1.1; letter-spacing: var(--ls-figure); font-variant-numeric: tabular-nums; }
.card-count { display: block; margin-top: 4px; font-size: var(--fs-body); line-height: 1.5; }
.card-source { margin-top: 12px; font-size: var(--fs-ui); line-height: var(--lh-ui); color: var(--ink-64); }
.card-label { font-size: var(--fs-ui); line-height: var(--lh-ui); color: var(--ink-64); }   /* no-JS only: names the week */

/* the week toggle (with JS): a full-width row at the card's foot, + turns to − */
.card-toggle {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; min-height: 44px; margin: 8px 0 -12px;
  font-size: var(--fs-ui); line-height: var(--lh-ui); color: var(--ink-75); text-align: left;
}
.card-toggle::after { content: "+"; font-size: 18px; line-height: 1; color: var(--ink); }
.card-toggle[aria-expanded="true"]::after { content: "\2212"; }
.card-toggle:hover { color: var(--ink); }
html.no-js .card-toggle { display: none; }
html.js .card-week:not(.is-open) { display: none; }
.card-week { margin-top: 12px; }
.card-week table { width: 100%; border-collapse: collapse; font-size: var(--fs-ui); line-height: var(--lh-ui); }
.card-week th, .card-week td { padding: 4px 0; text-align: left; font-weight: var(--fw-display); vertical-align: top; }
.card-week td { padding-left: 16px; white-space: nowrap; text-align: right; }
.card-week tr + tr th, .card-week tr + tr td { border-top: 4px solid transparent; }
.card-week tr[aria-current] th, .card-week tr[aria-current] td { font-weight: var(--fw-statement); }
html.js .card-nojs { display: none; }                         /* the no-JS label gives way to the live status */
html.no-js .card-status { display: none; }

/* ---- booking panel: a sheet from the right on D/T, from the bottom on P ---- */
.panel {
  margin: 8px 8px 8px auto; padding: 24px 36px 36px; width: min(calc(100vw - 16px), 480px); max-width: calc(100vw - 16px);
  height: auto; max-height: calc(100dvh - 16px); border: 0; border-radius: var(--r-lg); background: var(--paper); color: var(--ink); overflow-y: auto;
}
.panel::backdrop { background: color-mix(in srgb, var(--night) 48%, transparent); }
.panel[open] { animation: panel-in .6s var(--spring-enter); }
@keyframes panel-in { from { transform: translateX(40px); opacity: 0; } to { transform: none; opacity: 1; } }
.panel-top { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.panel-h { font-size: var(--fs-h2); line-height: var(--lh-h2); letter-spacing: var(--ls-h2); }
.panel-close { min-height: 44px; padding: 0 16px; border-radius: var(--r-md); background: var(--mist); font-size: var(--fs-ui); }
.panel-list { display: grid; gap: 4px; margin-top: 36px; }
.panel-item { display: grid; gap: 2px; padding: 24px; border-radius: var(--r-sm); background: var(--mist); text-decoration: none; }
.panel-item-t { font-size: var(--fs-h5); line-height: var(--lh-h5); letter-spacing: var(--ls-h5); }
.panel-item-v { font-size: var(--fs-ui); line-height: var(--lh-ui); color: var(--ink-64); }
a.panel-item:hover .panel-item-t { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: .2em; }
.panel-item[aria-disabled="true"] { color: var(--ink-64); cursor: not-allowed; }
.panel-akut { margin-top: 24px; font-size: var(--fs-body); line-height: var(--lh-body); }
@media (max-width: 809.98px) {
  .panel { margin: auto 0 0; width: 100vw; max-width: 100vw; border-radius: var(--r-lg) var(--r-lg) 0 0; padding: 24px var(--side) calc(24px + env(safe-area-inset-bottom)); }
  @keyframes panel-in { from { transform: translateY(40px); opacity: 0; } to { transform: none; opacity: 1; } }
}

/* ---- Blender frame player (js/core/frames.js; docs/3D-RETHINK.md): a 4:5 figure, the <img> is the end frame (no JS,
   reduced motion, the poster until frames decode); the canvas covers it once a frame is drawn ---- */
.fr-host { position: relative; margin: 0; aspect-ratio: 992 / 1240; }
.fr-host img, .fr-host .fr-canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; max-width: none; }
.fr-host .fr-canvas { cursor: grab; }
.fr-host.is-turning .fr-canvas { cursor: grabbing; }
.fr-host .fr-canvas { opacity: 0; transition: opacity .35s var(--ease-ui); }   /* purpose: the full set replaces the still without a cut */
.fr-host.is-live .fr-canvas { opacity: 1; }
.fr-host img { transition: opacity .35s var(--ease-ui); }
.fr-host.is-live img { opacity: 0; }   /* purpose: the frames have alpha, so the end-pose still must leave as the set arrives (else its crown shows in the gap) */
