/*
 * A salon's booking page, in Artover's paper and ink. The widget keeps its
 * own layout inside its shadow root; this page only sets the frame around it
 * and hands it Artover's colours through its custom properties.
 */

@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  src: url('/s/inter.woff2') format('woff2');
}
@font-face {
  font-family: 'Instrument Serif';
  font-style: italic;
  font-display: swap;
  font-weight: 400;
  src: url('/s/instrument-serif-italic.woff2') format('woff2');
}

:root {
  --paper: #f4efe6;
  --ink: #1c1b18;
  --muted: #5a534a;
  --faint: #766e63;
  --accent: #a8401a;
  --mark: #e9a81c;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  color-scheme: only light;
}

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; }
body {
  min-height: 100vh;
  background: var(--paper);
  color: var(--ink);
  font: 400 16px/1.5 'Inter', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;
  -webkit-font-smoothing: antialiased;
}
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(60vw 50vh at 92% -10%, rgba(233, 168, 28, 0.12), transparent 70%),
    radial-gradient(55vw 45vh at -5% 105%, rgba(201, 180, 154, 0.22), transparent 70%);
}
::selection { background: var(--mark); color: var(--ink); }

.salon {
  display: flex;
  align-items: center;
  gap: 16px;
  max-width: 1232px;
  margin: 0 auto;
  padding: 40px 16px 8px;
  animation: reveal-up 0.7s var(--ease) both;
}
.salon__logo { width: 56px; height: 56px; border-radius: 14px; object-fit: cover; box-shadow: 0 10px 24px -14px rgba(60, 40, 20, 0.45); }
.salon__eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 4px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--faint);
}
.salon__eyebrow::before { content: ''; width: 22px; height: 1px; background: var(--accent); }
.salon__name {
  margin: 0;
  font-size: clamp(1.9rem, 1.4rem + 2vw, 3rem);
  line-height: 1.08;
  letter-spacing: -0.03em;
  font-weight: 800;
}
@media (max-width: 600px) {
  .salon { padding-top: 28px; gap: 12px; }
  .salon__logo { width: 48px; height: 48px; border-radius: 12px; }
}
.salon__skeleton { width: 260px; height: 48px; border-radius: 10px; background: #ece5d8; }

/* Artover's palette for the widget, through its documented custom properties. */
.booking {
  --sb-accent: #a8401a;
  --sb-accent-contrast: #fffdf8;
  --sb-accent-soft: #f3e2d8;
  --sb-text: #1c1b18;
  --sb-muted: #5a534a;
  --sb-line: #e2d9c9;
  --sb-surface: #fbf8f2;
  --sb-surface-sunken: #ece5d8;
  --sb-price: #1c1b18;
  --sb-font: 'Inter', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;
  /* The page's side margin, which the widget's chip row and bar run past. */
  --sb-gutter: 16px;
  --sb-page-bg: #f4efe6;
  display: block;
  max-width: 1232px;
  margin: 0 auto;
  padding: 8px var(--sb-gutter) 32px;
  animation: reveal-up 0.7s var(--ease) 0.12s both;
}

@keyframes reveal-up {
  0% { opacity: 0; transform: translateY(14px) scale(0.99); filter: blur(3px); }
  60% { filter: blur(0); }
  100% { opacity: 1; transform: none; filter: none; }
}

.byline {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  padding: 8px 16px 40px;
  font-size: 13px;
  color: var(--faint);
}
.byline em { font-family: 'Instrument Serif', Georgia, serif; font-size: 15px; color: var(--accent); }
.mark {
  display: inline-grid;
  place-items: center;
  width: 20px;
  height: 20px;
  border-radius: 6px;
  background: var(--mark);
  color: var(--ink);
  font-size: 12px;
  font-weight: 800;
  transition: transform 0.45s var(--ease);
}
@media (hover: hover) { .byline:hover .mark { transform: rotate(-8deg) scale(1.06); } }
.noscript { text-align: center; color: var(--muted); padding: 0 16px 32px; }

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

/* EN / FR switch under the page (i18n.ts). */
.lang-switch { display: flex; justify-content: center; gap: 6px; margin: 4px auto 28px; }
.lang-switch button {
  appearance: none; border: 0; background: transparent; padding: 6px 10px; border-radius: 999px;
  font: inherit; font-size: 0.85rem; color: #766e63; cursor: pointer;
}
.lang-switch button[aria-current='true'] { color: #1c1b18; font-weight: 650; background: rgba(28, 27, 24, 0.06); }

/* Gift cards bought on the page (src/giftCards.ts, Phase 5.3). 16px inputs keep iOS from zooming. */
.gifts { max-width: 720px; margin: 0 auto 20px; padding: 0 16px; }
.gift__open, .gift__pay {
  appearance: none; border: 1px solid var(--ink); border-radius: 999px; padding: 10px 18px;
  font: inherit; font-weight: 600; background: transparent; color: var(--ink); cursor: pointer;
}
.gift__pay { background: var(--ink); color: var(--paper); margin-top: 8px; }
.gift__pay:disabled { opacity: 0.6; cursor: default; }
.gift { display: grid; gap: 12px; padding: 18px; border: 1px solid rgba(28, 27, 24, 0.12); border-radius: 16px; background: #fffdf8; }
.gift--done { margin-bottom: 12px; }
.gift__title { margin: 0; font-size: 1.15rem; }
.gift__amounts { display: flex; flex-wrap: wrap; gap: 8px; }
.gift__chip { appearance: none; border: 1px solid rgba(28, 27, 24, 0.2); border-radius: 999px; padding: 8px 14px; font: inherit; background: transparent; cursor: pointer; }
.gift__chip[aria-checked='true'] { border-color: var(--ink); background: var(--ink); color: var(--paper); }
.gift__field { display: grid; gap: 6px; font-size: 14px; color: var(--muted); }
.gift__field input, .gift__field textarea { font: inherit; font-size: 16px; padding: 10px 12px; border: 1px solid rgba(28, 27, 24, 0.2); border-radius: 10px; background: #fff; color: var(--ink); }
.gift__check { display: flex; gap: 10px; align-items: center; cursor: pointer; }
.gift__check input { width: 20px; height: 20px; accent-color: var(--ink); }
.gift__someone { display: grid; gap: 12px; }
.gift__error { margin: 0; color: #a8261a; min-height: 0; }
.gift__error:empty { display: none; }
.gift__note { margin: 0; font-size: 13px; color: var(--faint); }
.gift__open:focus-visible, .gift__pay:focus-visible, .gift__chip:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
