/*
 * Couvra Component Styles
 * All reusable UI component classes.
 */

@layer components {

/* ==========================================================================
   Buttons
   ========================================================================== */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  min-height: var(--touch-target-min);
  min-width: var(--touch-target-min);
  border-radius: var(--radius-sm);
  font-family: var(--font-family);
  font-size: var(--font-size-base);
  font-weight: var(--font-weight-medium);
  line-height: var(--line-height-normal);
  cursor: pointer;
  transition: background var(--transition-fast), transform var(--transition-fast);
  border: 1px solid transparent;
  text-decoration: none;
  white-space: nowrap;
}

.btn:active {
  transform: scale(0.98);
}

/* Buttons should not stretch to fill flex containers */
.stack .btn:not(.btn--full),
.card-body .btn:not(.btn--full) {
  align-self: flex-start;
}

.btn:disabled,
.btn[disabled] {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn--brand {
  background: var(--color-brand);
  color: var(--color-text-inverse);
}

.btn--brand:hover {
  background: var(--color-brand-hover);
}

.btn--success {
  background: var(--color-success);
  color: var(--color-text-inverse);
}

.btn--success:hover {
  background: color-mix(in hsl, var(--color-success), black 12%);
}

.btn--danger {
  background: var(--color-danger);
  color: var(--color-text-inverse);
}

.btn--danger:hover {
  background: color-mix(in hsl, var(--color-danger), black 10%);
}

.btn--warning {
  background: var(--color-warning);
  color: var(--color-warning-text);
}

.btn--warning:hover {
  background: color-mix(in hsl, var(--color-warning), black 10%);
}

.btn--neutral {
  background: var(--color-bg-subtle);
  color: var(--color-text);
}

.btn--neutral:hover {
  background: var(--color-border-light);
}

.btn--text {
  background: none;
  border: none;
  color: var(--color-brand);
  padding: 0.25rem 0.5rem;
}

.btn--text:hover {
  background: var(--color-bg);
}

.btn--outline {
  background: transparent;
  border: 1px solid currentColor;
}

.btn--outline:hover {
  background: var(--color-bg);
}

/* Outline variants — override fill colors with visible text/border */
.btn--brand.btn--outline {
  color: var(--color-brand);
  background: transparent;
}

.btn--brand.btn--outline:hover {
  background: var(--color-brand-light);
}

.btn--danger.btn--outline {
  color: var(--color-danger);
  background: transparent;
}

.btn--danger.btn--outline:hover {
  background: var(--color-danger-bg);
}

.btn--success.btn--outline {
  color: var(--color-success);
  background: transparent;
}

.btn--success.btn--outline:hover {
  background: var(--color-success-bg);
}

.btn--warning.btn--outline {
  color: var(--color-warning-text);
  background: transparent;
}

.btn--warning.btn--outline:hover {
  background: var(--color-warning-bg);
}

.btn--sm {
  padding: 0.25rem 0.625rem;
  font-size: var(--font-size-sm);
}

.btn--full {
  width: 100%;
  justify-content: center;
}

/* Icon-only button */
.btn-icon {
  all: unset;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: var(--touch-target-min);
  height: var(--touch-target-min);
  border-radius: var(--radius-sm);
  color: var(--color-text);
  transition: background var(--transition-fast);
}

.btn-icon:hover {
  background: var(--color-bg);
}

/* Dense desktop-only exception (32px) — reserved for mouse-primary,
   non-primary-action contexts (e.g. a secondary "view details" icon
   button inside a data table row on a desktop-only management screen).
   Never use for confirm/seat/cancel/walk-in actions and never on
   tablet/mobile viewports. */
.btn-icon--sm {
  width: 2rem;
  height: 2rem;
}

/* ==========================================================================
   Inputs
   ========================================================================== */

.input {
  width: 100%;
  padding: 0.5rem 0.75rem;
  min-height: var(--touch-target-min);
  border: var(--border-width) solid var(--color-border);
  border-radius: var(--radius-md);
  font-family: var(--font-family);
  font-size: var(--font-size-base);
  background: var(--color-surface-raised);
  color: var(--color-text);
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.input:focus {
  border-color: var(--color-brand);
  box-shadow: 0 0 0 3px hsla(18, 65%, 50%, 0.15);
  outline: none;
}

.input-group {
  display: flex;
  align-items: stretch;
  position: relative;
}

.input-group .input {
  flex: 1;
}

.input-prefix {
  display: flex;
  align-items: center;
  padding: 0 0.75rem;
  background: var(--color-bg-subtle);
  border: var(--border-width) solid var(--color-border);
  border-right: none;
  border-radius: var(--radius-md) 0 0 var(--radius-md);
  color: var(--color-text-muted);
  font-size: var(--font-size-sm);
}

.input--has-prefix {
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
}

.input-suffix {
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: 2.5rem;
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
}

/* ==========================================================================
   Selects
   ========================================================================== */

.select {
  width: 100%;
  padding: 0.5rem 2.5rem 0.5rem 0.75rem;
  min-height: var(--touch-target-min);
  border: var(--border-width) solid var(--color-border);
  border-radius: var(--radius-md);
  font-family: var(--font-family);
  font-size: var(--font-size-base);
  background: var(--color-surface-raised);
  color: var(--color-text);
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23666' d='M6 8.825a.5.5 0 0 1-.354-.146l-4-4a.5.5 0 0 1 .708-.708L6 7.617l3.646-3.646a.5.5 0 0 1 .708.708l-4 4A.5.5 0 0 1 6 8.825z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.75rem center;
  cursor: pointer;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.select:focus {
  border-color: var(--color-brand);
  box-shadow: 0 0 0 3px hsla(18, 65%, 50%, 0.15);
  outline: none;
}

.select--sm {
  padding: 0.25rem 2rem 0.25rem 0.5rem;
  font-size: var(--font-size-sm);
}

/* ==========================================================================
   Cards
   ========================================================================== */

.card {
  background: var(--color-surface-raised);
  border: var(--border-width) solid var(--color-border-light);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
}

.card-header {
  padding: 0.75rem 1.25rem;
  border-bottom: var(--border-width) solid var(--color-border-light);
  font-weight: var(--font-weight-semibold);
}

.card-body {
  padding: 1.25rem;
}

.card:has(.card-header),
.card:has(.card__header) {
  padding: 0;
}

.card-header + .card-body,
.card-header + .stack,
.card-header + div:not(.card-body):not(.card-header),
.card__header + .card-body,
.card__header + .stack,
.card__header + dl,
.card__header + div:not(.card-body):not(.card__header) {
  padding: 1.25rem;
}

/* BEM alias for card header */
.card__header {
  padding: 0.75rem 1.25rem;
  border-bottom: var(--border-width) solid var(--color-border-light);
  font-weight: var(--font-weight-semibold);
}

/* Card footer — always at bottom, buttons aligned left */
.card__footer {
  padding: 0.75rem 1.25rem;
  border-top: var(--border-width) solid var(--color-border-light);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: auto;
}

/* ==========================================================================
   Alerts
   ========================================================================== */

.alert {
  display: flex;
  align-items: flex-start;
  gap: 0.625rem;
  padding: 0.75rem 1rem;
  border-radius: var(--radius-md);
  font-size: var(--font-size-base);
  margin-bottom: 1rem;
}

.alert--danger {
  background: var(--color-danger-bg);
  border: 1px solid var(--color-danger-border);
  color: var(--color-danger-text);
}

.alert--warning {
  background: var(--color-warning-bg);
  border: 1px solid var(--color-warning-border);
  color: var(--color-warning-text);
}

.alert--success {
  background: var(--color-success-bg);
  border: 1px solid var(--color-success-border);
  color: var(--color-success-text);
}

.alert--info {
  background: var(--color-bg-subtle);
  border: 1px solid var(--color-border);
  color: var(--color-text);
}

.alert-icon {
  flex-shrink: 0;
  font-size: 1rem;
  margin-top: 0.125rem;
}

.alert-content {
  flex: 1;
}

.alert-close {
  all: unset;
  cursor: pointer;
  font-size: 1.25rem;
  line-height: 1;
  opacity: 0.6;
  padding: 0 0.25rem;
}

.alert-close:hover {
  opacity: 1;
}

/* ==========================================================================
   Badges
   ========================================================================== */

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.125rem 0.5rem;
  font-size: var(--font-size-xs);
  font-weight: var(--font-weight-semibold);
  border-radius: 9999px;
  line-height: 1.5;
  white-space: nowrap;
}

.badge--success {
  background: var(--color-success-bg);
  color: var(--color-success-text);
}

.badge--danger {
  background: var(--color-danger-bg);
  color: var(--color-danger-text);
}

.badge--warning {
  background: var(--color-warning-bg);
  color: var(--color-warning-text);
}

.badge--neutral {
  background: var(--color-neutral-badge-bg);
  color: var(--color-neutral-badge-text);
}

.badge--brand {
  background: var(--color-brand-light);
  color: var(--color-brand-dark);
}

/* ==========================================================================
   Dialogs
   ========================================================================== */

.dialog {
  border: none;
  border-radius: var(--radius-lg);
  padding: 0;
  box-shadow: var(--shadow-lg);
  max-width: 480px;
  width: calc(100% - 2rem);
  background: var(--color-surface-raised);
}

.dialog::backdrop {
  background: hsla(0, 0%, 0%, 0.4);
}

.dialog-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.25rem;
  border-bottom: var(--border-width) solid var(--color-border-light);
}

.dialog-title {
  margin: 0;
  font-size: var(--font-size-lg);
  font-weight: var(--font-weight-semibold);
}

.dialog-close {
  color: var(--color-text-muted);
}

.dialog-body {
  padding: 1.25rem;
}

/* ==========================================================================
   Tabs
   ========================================================================== */

.tabs__nav {
  display: flex;
  gap: 0;
  border-bottom: 2px solid var(--color-border);
}

.tabs__tab {
  padding: 0.75rem 1.25rem;
  min-height: var(--touch-target-min);
  border: none;
  background: none;
  cursor: pointer;
  font-family: var(--font-family);
  font-size: var(--font-size-base);
  color: var(--color-text-muted);
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  transition: color var(--transition-fast), border-color var(--transition-fast);
}

.tabs__tab:hover {
  color: var(--color-text);
}

.tabs__tab--active {
  color: var(--color-brand);
  border-bottom-color: var(--color-brand);
  font-weight: var(--font-weight-medium);
}

.tabs__panel {
  padding: 1.5rem 0;
}

.tabs__panel[hidden] {
  display: none;
}

/* ==========================================================================
   Accessibility: Focus Rings (keyboard-only)
   ========================================================================== */

/* Visible only on keyboard/programmatic focus, never on mouse click */
.btn:focus-visible,
.btn-icon:focus-visible,
.input:focus-visible,
.select:focus-visible,
.textarea:focus-visible,
.tabs__tab:focus-visible,
a:focus-visible {
  outline: 2px solid var(--color-focus-ring-solid);
  outline-offset: 2px;
}

/* Double-ring pattern for terracotta-filled buttons — a same-hue outline
   would blend into the fill, so pair a white inner ring with a terracotta
   outer glow for guaranteed contrast against both the button and the page. */
.btn--brand:focus-visible {
  outline: 2px solid white;
  outline-offset: 2px;
  box-shadow: 0 0 0 4px var(--color-focus-ring-solid);
}

/* ==========================================================================
   Checkboxes
   ========================================================================== */

.checkbox {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  font-size: var(--font-size-base);
}

.checkbox input[type="checkbox"] {
  appearance: none;
  width: 1.125rem;
  height: 1.125rem;
  border: var(--border-width) solid var(--color-border);
  border-radius: var(--radius-sm);
  background: var(--color-surface-raised);
  transition: background var(--transition-fast), border-color var(--transition-fast);
  cursor: pointer;
  flex-shrink: 0;
  position: relative;
}

.checkbox input[type="checkbox"]:checked {
  background: var(--color-brand);
  border-color: var(--color-brand);
}

.checkbox input[type="checkbox"]:checked::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 5px;
  width: 5px;
  height: 9px;
  border: solid white;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.checkbox input[type="checkbox"]:focus-visible {
  box-shadow: 0 0 0 3px hsla(18, 65%, 50%, 0.15);
}

.checkbox-label {
  user-select: none;
}

/* ==========================================================================
   Switches
   ========================================================================== */

.switch {
  appearance: none;
  width: 2.5rem;
  height: 1.375rem;
  border-radius: 9999px;
  background: var(--color-border);
  position: relative;
  transition: background var(--transition-fast);
  cursor: pointer;
  border: none;
  flex-shrink: 0;
}

.switch::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 2px;
  width: 1rem;
  height: 1rem;
  border-radius: 50%;
  background: white;
  transition: transform var(--transition-fast);
}

.switch:checked {
  background: var(--color-brand);
}

.switch:checked::after {
  transform: translateX(1.125rem);
}

.switch-label {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  cursor: pointer;
}

.switch-text {
  user-select: none;
}

/* ==========================================================================
   Textareas
   ========================================================================== */

.textarea {
  width: 100%;
  padding: 0.5rem 0.75rem;
  border: var(--border-width) solid var(--color-border);
  border-radius: var(--radius-md);
  font-family: var(--font-family);
  font-size: var(--font-size-base);
  background: var(--color-surface-raised);
  color: var(--color-text);
  resize: vertical;
  min-height: 5rem;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.textarea:focus {
  border-color: var(--color-brand);
  box-shadow: 0 0 0 3px hsla(18, 65%, 50%, 0.15);
  outline: none;
}

/* ==========================================================================
   Radio buttons
   ========================================================================== */

.radio-group {
  border: none;
  padding: 0;
  margin: 0;
}

.radio {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  margin-right: 1rem;
}

.radio input[type="radio"] {
  appearance: none;
  width: 1.125rem;
  height: 1.125rem;
  border: var(--border-width) solid var(--color-border);
  border-radius: 50%;
  background: var(--color-surface-raised);
  cursor: pointer;
  transition: border-color var(--transition-fast);
  flex-shrink: 0;
}

.radio input[type="radio"]:checked {
  border-color: var(--color-brand);
  border-width: 5px;
}

.radio input[type="radio"]:focus-visible {
  box-shadow: 0 0 0 3px hsla(18, 65%, 50%, 0.15);
}

.radio-label {
  user-select: none;
}

/* ==========================================================================
   Tags
   ========================================================================== */

.tag {
  display: inline-flex;
  align-items: center;
  padding: 0.125rem 0.5rem;
  font-size: var(--font-size-xs);
  font-weight: var(--font-weight-medium);
  border-radius: var(--radius-sm);
  background: var(--color-bg-subtle);
  color: var(--color-text);
}

.tag--danger {
  background: var(--color-danger-bg);
  color: var(--color-danger-text);
}

/* ==========================================================================
   Coming-soon block (disabled feature preview)
   ========================================================================== */

.coming-soon-block {
  border: var(--border-width) dashed var(--color-border);
  border-radius: var(--radius-md);
  padding: 1rem;
  margin-top: 1.5rem;
  opacity: 0.65;
}

.coming-soon-block__header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.25rem;
}

.coming-soon-block__note {
  font-size: var(--font-size-sm);
  color: var(--color-text-muted);
  margin: 0 0 0.75rem;
}

.coming-soon-block .switch:disabled,
.coming-soon-block .switch-label {
  cursor: not-allowed;
}

/* ==========================================================================
   Legal pages (privacy, terms)
   ========================================================================== */

.legal-page {
  max-width: 720px;
  margin: 2rem auto;
  line-height: 1.6;
}

.legal-page h1 {
  margin-bottom: 0.25rem;
}

.legal-page h2 {
  margin-top: 1.75rem;
  margin-bottom: 0.5rem;
  font-size: var(--font-size-lg);
}

.legal-page ul {
  padding-left: 1.25rem;
}

.legal-page li {
  margin-bottom: 0.35rem;
}

.legal-meta {
  color: var(--color-text-muted);
  font-size: var(--font-size-sm);
  margin-bottom: 1.5rem;
}

.legal-footer-links {
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: var(--border-width) solid var(--color-border);
}

/* ==========================================================================
   Slot buttons (booking time slots)
   ========================================================================== */

.slot-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.25rem 0.625rem;
  border-radius: var(--radius-sm);
  font-family: var(--font-family);
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-medium);
  cursor: pointer;
  transition: background var(--transition-fast), border-color var(--transition-fast);
  background: transparent;
  border: 1px solid var(--color-border);
  color: var(--color-text);
}

.slot-btn:hover {
  background: var(--color-bg);
  border-color: var(--color-brand);
}

.slot-btn--selected {
  background: var(--color-brand);
  border-color: var(--color-brand);
  color: var(--color-text-inverse);
}

/* ==========================================================================
   Input size variants
   ========================================================================== */

.input--sm {
  padding: 0.25rem 0.5rem;
  font-size: var(--font-size-sm);
}

/* ==========================================================================
   Combobox
   ========================================================================== */

.combobox-wrapper {
  position: relative;
}

.combobox-listbox {
  position: absolute;
  z-index: 100;
  width: 100%;
  max-height: 200px;
  overflow-y: auto;
  background: var(--color-surface-raised);
  border: var(--border-width) solid var(--color-border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  list-style: none;
  padding: 0.25rem 0;
  margin: 0;
  bottom: 100%;
  margin-bottom: 0.25rem;
}

.combobox-option {
  padding: 0.5rem 0.75rem;
  cursor: pointer;
  font-size: var(--font-size-sm);
}

.combobox-option:hover,
.combobox-option[aria-selected="true"] {
  background: var(--color-bg);
}

.combobox-empty {
  padding: 0.5rem 0.75rem;
  color: var(--color-text-muted);
  font-size: var(--font-size-sm);
}

/* ==========================================================================
   Flash Messages
   ========================================================================== */

.flash-bar {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  padding: 0.75rem 1rem;
  border-radius: 0.375rem;
  font-size: 0.875rem;
  font-weight: 500;
  margin-bottom: 1rem;
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.flash-bar.flash-hide {
  opacity: 0;
  transform: translateY(-0.5rem);
}

.flash-success {
  background: var(--color-success-bg);
  border: 1px solid var(--color-success-border);
  color: var(--color-success-text);
}

.flash-danger {
  background: var(--color-danger-bg);
  border: 1px solid var(--color-danger-border);
  color: var(--color-danger-text);
}

.flash-icon {
  font-size: 1rem;
  flex-shrink: 0;
}

.flash-message {
  flex: 1;
}

.flash-close {
  all: unset;
  cursor: pointer;
  font-size: 1.25rem;
  line-height: 1;
  opacity: 0.6;
  padding: 0 0.25rem;
}

.flash-close:hover {
  opacity: 1;
}

/* ==========================================================================
   Toast (inline, action-carrying notification — Popover API, manual mode)
   ========================================================================== */

.toast {
  display: none;
  align-items: center;
  gap: 0.625rem;
  padding: 0.75rem 1rem;
  border: var(--border-width) solid var(--color-border-light);
  border-radius: var(--radius-md);
  background: var(--color-surface-raised);
  box-shadow: var(--shadow-lg);
  font-size: var(--font-size-base);
  color: var(--color-text);
  margin: 0;
  max-width: calc(100% - 2rem);
  position: fixed;
  left: 50%;
  bottom: var(--space-xl);
  transform: translateX(-50%);
}

.toast:popover-open {
  display: flex;
}

.toast-icon {
  flex-shrink: 0;
  font-size: 1rem;
}

.toast-message {
  flex: 1;
}

.toast-action {
  color: var(--color-link);
  font-weight: var(--font-weight-semibold);
  text-decoration: none;
  white-space: nowrap;
}

.toast-action:hover {
  color: var(--color-link-hover);
  text-decoration: underline;
}

.toast-close {
  all: unset;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  flex-shrink: 0;
  border-radius: var(--radius-sm);
  color: var(--color-text-muted);
  transition: background var(--transition-fast);
}

.toast-close:hover {
  background: var(--color-bg);
}

.toast-close:focus-visible {
  outline: 2px solid var(--color-focus-ring-solid);
  outline-offset: 2px;
}

/* ==========================================================================
   Menu (anchored action menu — Popover API, auto mode)
   ========================================================================== */

.menu {
  display: none;
  flex-direction: column;
  min-width: 12rem;
  margin: 0;
  padding: 0.375rem;
  border: none;
  border-radius: var(--radius-lg);
  background: var(--color-surface-raised);
  box-shadow: var(--shadow-lg);
}

/* Browsers without CSS anchor positioning ignore `position-anchor` and fall
   through to the UA popover default (position: fixed, centered-ish) instead
   of sitting near the trigger. Give `.menu` an explicit static fallback so it
   degrades to a predictable position rather than breaking, per DS-05. */
@supports not (position-anchor: --x) {
  .menu {
    position: absolute;
    top: calc(100% + 4px);
    right: 0;
  }
}

/* Browsers WITH anchor positioning need the anchor actually consumed:
   `position-anchor` alone positions nothing, and the UA popover default
   (inset: 0) combined with .menu's margin: 0 (which cancels the UA's
   centering margin: auto) pins the open menu to the viewport's top-left.
   Tether below the trigger, end-aligned, flipping when near an edge. */
@supports (position-area: block-end) {
  .menu {
    inset: auto;
    position-area: block-end span-inline-start;
    position-try-fallbacks: flip-inline, flip-block;
    margin-top: 4px;
  }
}

.menu:popover-open {
  display: flex;
}

.menu-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.625rem 0.75rem;
  border: none;
  border-radius: var(--radius-sm);
  background: none;
  font-family: var(--font-family);
  font-size: var(--font-size-base);
  color: var(--color-text);
  text-align: left;
  cursor: pointer;
  transition: background var(--transition-fast), color var(--transition-fast);
}

.menu-item:hover {
  background: var(--color-bg);
}

.menu-item:focus-visible {
  outline: 2px solid var(--color-focus-ring-solid);
  outline-offset: 2px;
  background: var(--color-bg);
}

/* ==========================================================================
   Booking card additions (Phase 3 — HUB-01/02/06/11)
   ========================================================================== */

/* Note/allergy flags — neutral gray, never a status color (HUB-06); the
   card's status pill is the only thing on the card allowed to own color
   meaning. */
.flags-row {
  display: flex;
  align-items: center;
  gap: var(--space-2xs);
  margin-top: var(--space-xs);
  color: var(--color-text-muted);
  font-size: var(--font-size-sm);
}

/* The card's meta row (time/party/section/table) wraps to two lines rather
   than truncating or scrolling horizontally once the card's own container
   narrows (HUB-11) -- the card carries `.cq` (container-type: inline-size,
   see utilities.css) so this scopes to the card itself, not the viewport. */
@container (max-width: 30rem) {
  .card .admin-booking-meta {
    flex-wrap: wrap;
  }
}

/* Brief pulse on a successful status transition (HUB-02). Uses the pill's
   own currentColor -- already one of the --color-*-text tokens via
   shared/_status_pill's badge--* variants -- so one rule covers every
   status color without duplicating tokens per variant. */
@keyframes status-pill-flash {
  0%, 100% {
    box-shadow: 0 0 0 0 transparent;
  }
  35% {
    box-shadow: 0 0 0 0.3rem color-mix(in srgb, currentColor 35%, transparent);
  }
}

.status-pill--flash {
  animation: status-pill-flash 900ms ease-out;
}

@media (prefers-reduced-motion: reduce) {
  .status-pill--flash {
    animation: none;
  }
}
