:root {
  --bg: #F6F0E8;
  --bg-2: #EFE6DA;
  --paper: #FFFCF7;
  --line: #E4D8C8;
  --line-strong: #D3C2AC;
  --ink: #2A221C;
  --ink-2: #5E5246;
  --muted: #8C7D6E;
  --gold: #B08D4A;
  --gold-deep: #8A6A2F;
  --gold-soft: #E9D9B4;
  --cream: #F3E6CC;
  --danger: #A2463A;
  --metal: linear-gradient(135deg, #8A6A2F, #C9A45C 30%, #EBD59C 50%, #C29B52 70%, #8A6A2F);
  --serif: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --sans: "Jost", "Helvetica Neue", Arial, sans-serif;
  --radius: 22px;
  --ease: cubic-bezier(.22, .61, .36, 1);
  --shadow: 0 1px 0 rgba(255, 255, 255, .7) inset, 0 30px 60px -30px rgba(74, 52, 24, .28), 0 12px 24px -18px rgba(74, 52, 24, .18);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background:
    radial-gradient(1200px 600px at 85% -10%, rgba(233, 217, 180, .45), transparent 60%),
    radial-gradient(900px 500px at -10% 110%, rgba(233, 217, 180, .35), transparent 60%),
    var(--bg);
  color: var(--ink);
  font: 300 16px/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}
img { max-width: 100%; display: block; }
button, input, textarea { font: inherit; color: inherit; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; border-radius: 10px; }

/* ───── Layout ───── */
.page {
  max-width: 1240px;
  margin: 0 auto;
  padding: clamp(16px, 4vw, 56px);
  display: grid;
  gap: clamp(28px, 5vw, 72px);
  grid-template-columns: minmax(0, 1fr);
}
@media (min-width: 980px) {
  .page { grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); align-items: start; }
  .hero { position: sticky; top: 56px; }
}

/* ───── Hero ───── */
.sign {
  margin: 0;
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 3 / 2;
  box-shadow: var(--shadow);
  position: relative;
}
.sign img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.02); }
.sign::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .35);
  pointer-events: none;
}
.hero-copy { padding: clamp(24px, 3vw, 40px) 4px 0; }
.eyebrow {
  margin: 0 0 14px;
  font-size: 11px;
  letter-spacing: .32em;
  text-transform: uppercase;
  color: var(--gold-deep);
  font-weight: 400;
  display: flex;
  align-items: center;
  gap: 14px;
}
.eyebrow::before { content: ""; width: 28px; height: 1px; background: var(--gold); }
h1 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(40px, 5.4vw, 66px);
  line-height: 1.02;
  letter-spacing: -.01em;
  margin: 0 0 18px;
}
h1 em {
  font-style: italic;
  background: var(--metal);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  padding-right: .06em;
}
.lede { margin: 0; color: var(--ink-2); max-width: 46ch; font-size: 17px; }
.studio-info {
  list-style: none;
  padding: 0;
  margin: 28px 0 0;
  display: grid;
  gap: 12px;
  border-top: 1px solid var(--line);
  padding-top: 22px;
}
.studio-info li { display: flex; gap: 12px; align-items: center; color: var(--ink-2); font-size: 15px; }
.studio-info svg { width: 18px; height: 18px; flex: none; stroke: var(--gold); fill: none; stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }
.studio-info a { color: inherit; text-decoration: none; border-bottom: 1px solid var(--line-strong); }
.studio-info a:hover { color: var(--gold-deep); border-color: var(--gold); }

/* ───── Card ───── */
.card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: calc(var(--radius) + 6px);
  box-shadow: var(--shadow);
  padding: clamp(22px, 3.6vw, 44px);
  position: relative;
  min-height: 520px;
  display: flex;
  flex-direction: column;
}
.foot { text-align: center; font-size: 11px; letter-spacing: .28em; text-transform: uppercase; color: var(--muted); margin: 22px 0 0; }

.stepper {
  list-style: none;
  margin: 0 0 30px;
  padding: 0 0 22px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  border-bottom: 1px solid var(--line);
}
.stepper li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--muted);
  transition: color .3s var(--ease);
}
.stepper span {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  display: grid;
  place-items: center;
  font-family: var(--serif);
  font-size: 15px;
  letter-spacing: 0;
  flex: none;
  transition: all .3s var(--ease);
}
.stepper li.is-active { color: var(--ink); }
.stepper li.is-active span { background: var(--ink); border-color: var(--ink); color: var(--cream); }
.stepper li.is-done span { background: var(--gold-soft); border-color: var(--gold-soft); color: var(--gold-deep); }
@media (max-width: 520px) {
  .stepper li { font-size: 10px; letter-spacing: .08em; gap: 8px; }
  .stepper span { width: 24px; height: 24px; font-size: 13px; }
}

.step { animation: rise .45s var(--ease) both; flex: 1; }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.step-title {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(26px, 3vw, 32px);
  line-height: 1.15;
  margin: 0 0 22px;
}

/* ───── States ───── */
.state { flex: 1; display: grid; place-content: center; text-align: center; gap: 10px; padding: 40px 0; }
.state p { margin: 0; }
.state-title { font-family: var(--serif); font-size: 28px; line-height: 1.2; }
.muted { color: var(--muted); }
.spinner {
  width: 34px;
  height: 34px;
  margin: 0 auto 6px;
  border-radius: 50%;
  border: 1.5px solid var(--line);
  border-top-color: var(--gold);
  animation: spin 1s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ───── Services ───── */
.services { display: grid; gap: 12px; }
.service {
  text-align: left;
  width: 100%;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 18px 20px;
  cursor: pointer;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 4px 16px;
  align-items: center;
  transition: border-color .25s var(--ease), background .25s var(--ease), transform .25s var(--ease);
}
.service:hover { border-color: var(--line-strong); background: #FFFDF9; }
.service:active { transform: scale(.995); }
.service[aria-checked="true"] { border-color: var(--gold); background: linear-gradient(180deg, #FFFBF2, #FBF4E6); box-shadow: 0 0 0 1px var(--gold) inset; }
.service-name { font-family: var(--serif); font-size: 22px; font-weight: 500; line-height: 1.2; }
.service-desc { grid-column: 1; color: var(--muted); font-size: 14px; }
.service-meta { grid-row: 1 / span 2; grid-column: 2; text-align: right; display: grid; gap: 2px; justify-items: end; }
.service-dur { font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-2); display: inline-flex; gap: 6px; align-items: center; }
.service-dur svg { width: 14px; height: 14px; stroke: var(--gold); fill: none; stroke-width: 1.5; }
.service-price { font-family: var(--serif); font-size: 18px; color: var(--gold-deep); }

/* ───── Calendar ───── */
.calendar { border: 1px solid var(--line); border-radius: 20px; padding: 16px 16px 12px; }
.cal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.cal-month { margin: 0; font-family: var(--serif); font-size: 22px; font-weight: 500; text-transform: capitalize; }
.icon-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: transparent;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: all .2s var(--ease);
}
.icon-btn svg { width: 18px; height: 18px; stroke: var(--ink); fill: none; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.icon-btn:hover:not(:disabled) { border-color: var(--gold); }
.icon-btn:disabled { opacity: .3; cursor: default; }
.cal-dow, .cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.cal-dow span { text-align: center; font-size: 11px; letter-spacing: .18em; color: var(--muted); padding: 6px 0; }
.day {
  aspect-ratio: 1;
  border: 0;
  background: transparent;
  border-radius: 50%;
  cursor: pointer;
  font-size: 15px;
  font-weight: 400;
  position: relative;
  transition: background .2s var(--ease), color .2s var(--ease);
  max-height: 48px;
  justify-self: center;
  width: 100%;
  max-width: 48px;
}
.day:hover:not(:disabled):not(.is-selected) { background: var(--bg-2); }
.day:disabled { color: #C9BDAE; cursor: default; text-decoration: line-through; text-decoration-color: rgba(201, 189, 174, .6); }
.day.is-empty { visibility: hidden; }
.day.is-today::after { content: ""; position: absolute; left: 50%; bottom: 6px; width: 4px; height: 4px; margin-left: -2px; border-radius: 50%; background: var(--gold); }
.day.is-selected { background: var(--ink); color: var(--cream); }
.day.is-selected::after { background: var(--cream); }

.slots-wrap { margin-top: 26px; }
.slots-date { margin: 0 0 14px; font-family: var(--serif); font-size: 20px; }
.slot-group + .slot-group { margin-top: 18px; }
.slot-label { font-size: 11px; letter-spacing: .26em; text-transform: uppercase; color: var(--muted); margin: 0 0 10px; }
.slot-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); gap: 8px; }
.slot {
  border: 1px solid var(--line);
  background: transparent;
  border-radius: 999px;
  padding: 11px 8px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 400;
  transition: all .2s var(--ease);
  white-space: nowrap;
}
.slot:hover { border-color: var(--gold); }
.slot[aria-pressed="true"] { background: var(--ink); color: var(--cream); border-color: var(--ink); }
.slots-empty { color: var(--muted); padding: 18px; text-align: center; border: 1px dashed var(--line-strong); border-radius: 16px; margin: 0; }
.slots-loading { display: flex; gap: 8px; flex-wrap: wrap; }
.slots-loading i { display: block; width: 104px; height: 42px; border-radius: 999px; background: linear-gradient(90deg, var(--bg-2), #F7F1E8, var(--bg-2)); background-size: 200% 100%; animation: shimmer 1.2s linear infinite; }
@keyframes shimmer { to { background-position: -200% 0; } }

/* ───── Form ───── */
.field { display: grid; gap: 8px; margin-bottom: 18px; }
.field-row { display: grid; gap: 0 16px; grid-template-columns: 1fr; }
@media (min-width: 620px) { .field-row { grid-template-columns: 1fr 1fr; } }
label { font-size: 11px; letter-spacing: .22em; text-transform: uppercase; color: var(--ink-2); font-weight: 400; }
.optional { text-transform: none; letter-spacing: 0; color: var(--muted); }
input, textarea {
  width: 100%;
  border: 1px solid var(--line);
  background: #FFFEFB;
  border-radius: 14px;
  padding: 14px 16px;
  font-size: 16px;
  font-weight: 400;
  transition: border-color .2s var(--ease), box-shadow .2s var(--ease);
  -webkit-appearance: none;
}
textarea { resize: vertical; min-height: 92px; }
input::placeholder, textarea::placeholder { color: #B7A998; }
input:focus, textarea:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 4px rgba(176, 141, 74, .14); }
input[aria-invalid="true"] { border-color: var(--danger); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-error { color: var(--danger); font-size: 14px; margin: 0; padding: 12px 16px; background: #FBF0EC; border-radius: 12px; }

/* ───── Buttons ───── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border-radius: 999px;
  border: 1px solid transparent;
  padding: 15px 26px;
  font-size: 12px;
  letter-spacing: .2em;
  text-transform: uppercase;
  font-weight: 400;
  cursor: pointer;
  text-decoration: none;
  transition: transform .2s var(--ease), background .25s var(--ease), opacity .2s, box-shadow .25s var(--ease);
  white-space: nowrap;
}
.btn:active:not(:disabled) { transform: scale(.98); }
.btn-primary { background: var(--ink); color: var(--cream); box-shadow: 0 10px 24px -14px rgba(42, 34, 28, .7); }
.btn-primary:hover:not(:disabled) { background: #3A2F26; }
.btn-primary:disabled { opacity: .32; cursor: default; box-shadow: none; }
.btn-ghost { border-color: var(--line-strong); color: var(--ink); background: transparent; }
.btn-ghost:hover { border-color: var(--gold); }
.btn-link { background: none; color: var(--ink-2); padding: 10px; border-bottom: 0; }
.btn-link:hover { color: var(--gold-deep); }
.btn-back { width: 48px; height: 48px; padding: 0; border-color: var(--line); background: transparent; flex: none; }
.btn-back svg { width: 18px; height: 18px; stroke: var(--ink); fill: none; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.btn.is-loading { pointer-events: none; }
.btn.is-loading::before { content: ""; width: 14px; height: 14px; border-radius: 50%; border: 1.5px solid rgba(243, 230, 204, .35); border-top-color: var(--cream); animation: spin .8s linear infinite; }

/* ───── Action bar ───── */
.actionbar {
  margin-top: 28px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  display: flex;
  align-items: center;
  gap: 14px;
  position: sticky;
  bottom: 0;
  background: linear-gradient(180deg, rgba(255, 252, 247, .85), var(--paper) 30%);
  backdrop-filter: blur(6px);
  padding-bottom: max(4px, env(safe-area-inset-bottom));
  margin-left: calc(clamp(22px, 3.6vw, 44px) * -1);
  margin-right: calc(clamp(22px, 3.6vw, 44px) * -1);
  padding-left: clamp(22px, 3.6vw, 44px);
  padding-right: clamp(22px, 3.6vw, 44px);
  border-radius: 0 0 calc(var(--radius) + 6px) calc(var(--radius) + 6px);
}
.summary { flex: 1; min-width: 0; font-size: 13px; color: var(--ink-2); line-height: 1.35; }
.summary strong { display: block; font-family: var(--serif); font-size: 18px; font-weight: 500; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.summary span { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
@media (max-width: 520px) {
  .btn-primary#next { padding: 15px 20px; }
  .summary strong { font-size: 16px; }
}

/* ───── Success ───── */
.success { text-align: center; padding-top: 8px; }
.success h2 { font-family: var(--serif); font-weight: 400; font-size: clamp(32px, 4vw, 42px); margin: 18px 0 8px; line-height: 1.1; }
.success > .muted { margin: 0 auto; max-width: 40ch; }
.seal {
  width: 76px;
  height: 76px;
  margin: 0 auto;
  border-radius: 50%;
  background: var(--metal);
  display: grid;
  place-items: center;
  box-shadow: 0 14px 30px -14px rgba(138, 106, 47, .7), inset 0 1px 0 rgba(255, 255, 255, .5);
  animation: pop .6s var(--ease) both .1s;
}
.seal svg { width: 34px; height: 34px; stroke: #FFFCF4; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 24; stroke-dashoffset: 24; animation: draw .5s var(--ease) forwards .45s; }
@keyframes pop { from { transform: scale(.6); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes draw { to { stroke-dashoffset: 0; } }
.receipt {
  margin: 28px auto 0;
  max-width: 440px;
  text-align: left;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 6px 20px;
  background: #FFFDF9;
}
.receipt div { display: grid; grid-template-columns: 110px 1fr; gap: 12px; padding: 13px 0; border-bottom: 1px solid #F0E7DB; }
.receipt div:last-child { border-bottom: 0; }
.receipt dt { font-size: 11px; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); padding-top: 3px; }
.receipt dd { margin: 0; font-family: var(--serif); font-size: 18px; line-height: 1.3; }
.success-actions { margin-top: 28px; display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .seal svg { stroke-dashoffset: 0; }
}
