/* The Curated Lobe storefront design system, re-implemented for the booking prototype.
   Values mirror the live theme (Icon v12.2.1 + settings) so this can drop into the theme later. */

:root {
  --background: #ffffff;
  --text-color: #000000;
  --header-color: #000000;
  --dotted-color: #333333;
  --button-color: #9f658d;
  --button-hover: #30202a;
  --button-text: #ffffff;
  --secondary-button-color: #333333;
  --secondary-button-hover: #9f658d;
  --secondary-button-text: #ffffff;
  --cs2-background: #f5eff3;
  --footer-background: #000000;
  --footer-text: #ffffff;
  --error-msg-dark: #e81000;
  --error-msg-light: #ffeae8;
  --success-msg-dark: #007f5f;
  --success-msg-light: #e5fff8;
  --disabled-text: #808080;
  --muted-text: #666666;
  --hairline: #e1d8de;

  --main-family: Montserrat, sans-serif;
  --font-size: 14px;
  --font-size-sm: 12px;
  --main-spacing: 0.025em;
  --heading-spacing: 0.05em;
  --h1-size: 22px;
  --h2-size: 19px;
  --h3-size: 18px;
  --section-padding: 45px;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--background);
  color: var(--text-color);
  font-family: var(--main-family);
  font-size: var(--font-size);
  font-weight: 400;
  line-height: 1.6em;
  letter-spacing: var(--main-spacing);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5 {
  color: var(--header-color);
  font-weight: 400;
  letter-spacing: var(--heading-spacing);
  line-height: normal;
  margin: 0 0 10px;
}
h1 { font-size: var(--h1-size); }
h2 { font-size: var(--h2-size); }
h3 { font-size: var(--h3-size); }
h4 { font-size: 16px; }
h5 { font-size: 15px; }
p { margin: 0 0 15px; }

a { color: var(--text-color); text-decoration: none; }
.rte a { text-decoration: underline; }
img { max-width: 100%; display: block; }
hr { border: 0; border-top: 1px solid var(--dotted-color); margin: 20px 0; }
ul { margin: 0; padding: 0; list-style: none; }

/* The live theme's focus ring is white-on-white; the prototype uses a visible one. */
:focus-visible { outline: 2px solid var(--button-color); outline-offset: 2px; }

.row { width: 92%; margin: 0 auto; }
@media (min-width: 500px) { .row { width: 96%; } }
@media (min-width: 1220px) { .row { width: 1200px; } }
@media (min-width: 1320px) { .row { width: 1300px; } }

.narrow { max-width: 860px; margin-left: auto; margin-right: auto; }
.a-center { text-align: center; }
.muted { color: var(--muted-text); }
.small { font-size: var(--font-size-sm); }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.eyebrow { font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase; color: #757575; margin: 0 0 4px; }

/* Buttons */
.button, button.button, a.button {
  display: inline-block;
  width: 100%;
  height: 48px;
  line-height: 48px;
  padding: 0 15px;
  border: none;
  background: var(--button-color);
  color: var(--button-text);
  font-family: var(--main-family);
  font-size: var(--font-size);
  font-weight: 400;
  letter-spacing: var(--main-spacing);
  text-transform: uppercase;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.3s ease, color 0.3s ease;
  -webkit-appearance: none;
  border-radius: 0;
}
.button:hover { background: var(--button-hover); color: var(--button-text); }
.button.secondary-button { background: var(--secondary-button-color); color: var(--secondary-button-text); }
.button.secondary-button:hover { background: var(--secondary-button-hover); }
.button.btn-outline { background: var(--background); color: var(--text-color); border: 1px solid var(--dotted-color); line-height: 46px; }
.button.btn-outline:hover { background: var(--background); color: var(--text-color); border-color: var(--text-color); }
.button.btn-tint { background: var(--cs2-background); color: #333333; }
.button.btn-tint:hover { background: var(--button-color); color: #ffffff; }
.button.auto { width: auto; padding: 0 24px; }
.button.sm { height: 40px; line-height: 40px; font-size: 13px; }
.button.btn-outline.sm { line-height: 38px; }
/* The theme defines no disabled state; this one is the prototype's own. */
.button[disabled], .button.is-disabled { background: #d9d2d6; color: #ffffff; cursor: not-allowed; }
.button-as-link {
  border: none; background: none; padding: 0; color: var(--text-color); text-decoration: underline;
  font: inherit; letter-spacing: var(--main-spacing); cursor: pointer; width: auto; height: auto; text-transform: none;
}

/* Forms */
label, legend { display: block; font-size: var(--font-size); margin-bottom: 5px; }
input[type="text"], input[type="email"], input[type="password"], input[type="tel"], input[type="date"], input[type="number"], input[type="time"], select, textarea {
  width: 100%;
  height: 48px;
  border: 1px solid var(--dotted-color);
  border-radius: 0;
  background: var(--background);
  color: var(--text-color);
  font-family: var(--main-family);
  font-size: var(--font-size);
  letter-spacing: var(--main-spacing);
  padding: 0 15px;
  margin: 0 0 20px;
  outline: none;
  -webkit-appearance: none;
  appearance: none;
}
textarea { height: auto; min-height: 100px; padding: 12px 15px; line-height: 1.5; }
select {
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 13.3' width='10' height='7'><polygon fill='%23000' points='17.7,0 10,8.3 2.3,0 0,2.5 10,13.3 20,2.5'/></svg>");
  background-repeat: no-repeat;
  background-position: right 15px center;
  padding-right: 36px;
}
input:focus, select:focus, textarea:focus { box-shadow: 0 0 3px rgba(0, 0, 0, 0.2); }
::placeholder { color: var(--muted-text); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0 20px; }
.check { display: flex; gap: 10px; align-items: flex-start; margin-bottom: 12px; cursor: pointer; }
.check input { width: 18px; height: 18px; margin: 2px 0 0; accent-color: var(--button-color); flex: 0 0 auto; }

/* Choice chips: the theme's swatch pattern */
.chips { display: flex; flex-wrap: wrap; gap: 5px; }
.chip {
  display: inline-block; min-width: 44px; height: 44px; line-height: 42px; padding: 0 12px;
  border: 1px solid var(--dotted-color); background: var(--background); color: var(--text-color);
  font-family: var(--main-family); font-size: 13px; letter-spacing: var(--main-spacing);
  text-align: center; white-space: nowrap; cursor: pointer; border-radius: 0;
}
.chip:hover { border-color: var(--text-color); }
.chip.is-selected, .chip[aria-pressed="true"] { background: var(--text-color); color: var(--background); border-color: var(--text-color); }
.chip[disabled] { color: #b5b5b5; border-color: #d5d5d5; cursor: not-allowed; text-decoration: line-through; }

/* Notes */
.note { padding: 15px 20px; border: 1px solid var(--dotted-color); margin: 0 0 20px; }
.note-tint { background: var(--cs2-background); border: 0; }
.note-error { border: 1px solid var(--error-msg-dark); color: var(--error-msg-dark); background: var(--error-msg-light); padding: 10px; margin-bottom: 15px; line-height: 19px; }
.note-success { border: 1px solid var(--success-msg-dark); color: var(--success-msg-dark); background: var(--success-msg-light); padding: 10px; margin-bottom: 15px; line-height: 19px; }

/* Status pills (the theme's rectangular badge) */
.pill { display: inline-flex; align-items: center; padding: 4px 8px; font-size: 11px; line-height: 1.2; letter-spacing: 0.04em; text-transform: uppercase; background: var(--cs2-background); color: #535353; white-space: nowrap; }
.pill--requested { background: #fff4d6; color: #6b4e00; }
.pill--confirmed { background: var(--button-color); color: #ffffff; }
.pill--checked_in { background: #30202a; color: #ffffff; }
.pill--completed { background: #e5fff8; color: var(--success-msg-dark); }
.pill--cancelled, .pill--declined, .pill--no_show { background: #f1f1f1; color: #757575; }
.pill--warn { background: var(--error-msg-light); color: var(--error-msg-dark); }
.pill--ok { background: #e5fff8; color: var(--success-msg-dark); }

/* Section title with the short centred rule */
.section-title { text-align: center; padding: 10px 0 30px; position: relative; }
.section-title h1, .section-title h2, .section-title h3 { margin-bottom: 0; }
.section-title::after { content: ""; position: absolute; left: 50%; bottom: 10px; width: 100px; height: 1px; margin-left: -50px; background: var(--header-color); }

/* Accordion: native details, as in the theme */
.details { border-bottom: 1px solid var(--dotted-color); }
.details__summary { min-height: 44px; display: flex; justify-content: space-between; align-items: center; cursor: pointer; list-style: none; gap: 15px; }
.details__summary::-webkit-details-marker { display: none; }
.details__title { margin: 0; font-size: var(--font-size); }
.details__svg { width: 1rem; transition: rotate 0.5s; flex: 0 0 auto; }
.details[open] > .details__summary .details__svg { rotate: 180deg; }
.details__content { padding: 1rem 0; }

/* Hero: image with text overlay */
.hero { position: relative; height: 300px; overflow: hidden; background: #30202a; }
.hero--tall { height: 400px; }
.hero img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero::before { content: ""; position: absolute; inset: 0; background: rgba(0, 0, 0, 0.25); z-index: 1; }
.hero__caption { position: absolute; z-index: 2; top: 50%; left: 50%; transform: translate(-50%, -50%); text-align: center; color: #ffffff; max-width: 90%; }
.hero__caption h1, .hero__caption h2 { color: #ffffff; font-size: 46px; margin: 0; }
.hero__caption p { margin: 10px 0 0; font-size: 15px; }
@media (max-width: 740px) { .hero, .hero--tall { height: 200px; } .hero__caption h1, .hero__caption h2 { font-size: 28px; } }

/* Location tiles */
.tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.tile { position: relative; height: 500px; overflow: hidden; background: #30202a; }
.tile img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.tile::before { content: ""; position: absolute; inset: 0; background: rgba(0, 0, 0, 0.25); z-index: 1; }
.tile__caption { position: absolute; z-index: 2; top: 50%; left: 50%; transform: translate(-50%, -50%); display: flex; flex-direction: column; align-items: center; gap: 15px; color: #ffffff; text-align: center; width: 90%; }
.tile__caption h3 { color: #ffffff; font-size: 24px; margin: 0; }
.tile__caption p { margin: 0; font-size: 15px; }
@media (max-width: 740px) { .tiles { grid-template-columns: 1fr; } .tile { height: 340px; } }

.main__section { margin: 30px 0 50px; }
.section { padding: 22.5px 0; }
.section--tint { background: var(--cs2-background); }

/* Drawer and modal, shaped like the theme's popover slideout */
.overlay { position: fixed; inset: 0; background: rgba(0, 0, 0, 0.5); z-index: 1400; display: none; }
.overlay.is-open { display: block; }
.drawer { position: fixed; top: 10px; bottom: 10px; right: 10px; width: min(450px, calc(100% - 20px)); background: var(--background); border: 1px solid var(--dotted-color); z-index: 1401; overflow-y: auto; padding: 20px; transform: translateX(calc(100% + 20px)); transition: transform 0.2s; }
.drawer.is-open { transform: translateX(0); }
.modal { position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%); width: min(640px, calc(100% - 20px)); max-height: calc(100vh - 40px); overflow-y: auto; background: var(--background); padding: 40px; z-index: 1401; display: none; }
.modal.is-open { display: block; }
.icn-close { position: absolute; top: 12px; right: 12px; width: 32px; height: 32px; background: none; border: 0; cursor: pointer; font-size: 26px; line-height: 1; color: var(--text-color); }
@media (max-width: 740px) { .modal { padding: 40px 18px 20px; } }

.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); background: #30202a; color: #ffffff; padding: 12px 20px; z-index: 1500; font-size: 13px; max-width: calc(100% - 40px); }

/* Prototype switcher: makes it obvious this is a demo, and jumps between its views */
.proto-bar { position: fixed; left: 12px; bottom: 12px; z-index: 1200; background: #ffffff; border: 1px solid #333333; font-size: 12px; line-height: 1.4; padding: 8px 10px; display: flex; gap: 10px; align-items: center; flex-wrap: wrap; max-width: calc(100% - 24px); }
.proto-bar strong { font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; font-size: 10px; }
.proto-bar a, .proto-bar button { text-decoration: underline; background: none; border: 0; padding: 0; font: inherit; cursor: pointer; color: #000000; }
.proto-bar a.is-current { font-weight: 700; text-decoration: none; }

@media (max-width: 740px) {
  :root { --font-size: 13px; --h1-size: 19px; --h2-size: 17px; --h3-size: 16px; }
  .field-row { grid-template-columns: 1fr; }
  /* 16px stops iOS zooming into focused fields */
  input[type="text"], input[type="email"], input[type="password"], input[type="tel"], input[type="date"], input[type="number"], input[type="time"], select, textarea { font-size: 16px; }
}

/* Waiver form (shared by booking, account and staff) */
.waiver h2 { margin-bottom: 6px; }
.waiver__items { border-top: 1px solid var(--hairline); margin: 15px 0 10px; }
.waiver__item { padding: 12px 0; margin: 0; border-bottom: 1px solid var(--hairline); }
.waiver__all { margin-bottom: 20px; }
.waiver__photo { border: 0; padding: 0; margin: 0 0 20px; }
.chip-radio input { position: absolute; opacity: 0; }
.chip-radio input:checked + .chip { background: var(--text-color); color: var(--background); }
.chip-radio input:focus-visible + .chip { outline: 2px solid var(--button-color); outline-offset: 2px; }
.waiver__sig-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 5px; }
.waiver__canvas { display: block; width: 100%; height: 150px; border: 1px solid var(--dotted-color); background: #ffffff; touch-action: none; cursor: crosshair; margin-bottom: 15px; }
.waiver__list { padding-left: 20px; margin: 0 0 15px; }
.waiver__list li { margin-bottom: 8px; }
.waiver__sig-img { max-width: 320px; border-bottom: 1px solid var(--dotted-color); }

/* On phones the switcher sits in the page flow so it never covers sticky step buttons. */
@media (max-width: 740px) { .proto-bar { position: static; border-width: 1px 0 0; justify-content: center; max-width: none; } }

/* Room for the fixed switcher so it never sits on top of the last line of content. */
#app { padding-bottom: 70px; }
