:root {
  --ink: #17181a;
  --bone: #e9e6df;
  --graphite: #4a4d50;
  --ash: #77797b;
  --brass: #8a6633;
  --line: #cac5b8;
  --btn-primary-bg: #17181a;
  --btn-primary-fg: #e9e6df;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ink: #efece5;
    --bone: #17181a;
    --graphite: #b4b6b8;
    --ash: #93968f;
    --brass: #c99a52;
    --line: #34363a;
    --btn-primary-bg: #c99a52;
    --btn-primary-fg: #17181a;
  }
}

:root[data-theme="dark"] {
  --ink: #efece5;
  --bone: #17181a;
  --graphite: #b4b6b8;
  --ash: #93968f;
  --brass: #c99a52;
  --line: #34363a;
  --btn-primary-bg: #c99a52;
  --btn-primary-fg: #17181a;
}

:root[data-theme="light"] {
  --ink: #17181a;
  --bone: #e9e6df;
  --graphite: #4a4d50;
  --ash: #77797b;
  --brass: #8a6633;
  --line: #cac5b8;
  --btn-primary-bg: #17181a;
  --btn-primary-fg: #e9e6df;
}

* { box-sizing: border-box; }

html, body { margin: 0; }

body {
  background: var(--bone);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }

.display {
  font-weight: 800;
  letter-spacing: -0.02em;
  text-wrap: balance;
}

.label {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ash);
}

.mono {
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-variant-numeric: tabular-nums;
}

.wrap {
  max-width: 640px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--line) 15%, var(--line) 85%, transparent);
}

/* Nav */
header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--bone);
  border-bottom: 1px solid var(--line);
}

nav.wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 0.9rem;
  padding-bottom: 0.9rem;
}

.wordmark {
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-decoration: none;
}

.navlinks {
  display: flex;
  gap: 1.5rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.navlinks a {
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--graphite);
  border-bottom: 1px solid transparent;
  padding-bottom: 2px;
  transition: border-color 0.15s ease, color 0.15s ease;
}

.navlinks a:hover,
.navlinks a:focus-visible {
  color: var(--brass);
  border-color: var(--brass);
}

.navlinks a.current {
  color: var(--brass);
  border-color: var(--brass);
}

/* Hero */
.hero { padding: 3.4rem 0 2.6rem; }

.hero .label { margin-bottom: 0.9rem; }

h1.display {
  font-size: clamp(2.4rem, 7vw, 3.4rem);
  margin: 0 0 0.2rem;
  line-height: 1.02;
}

.hero .sub {
  font-size: 1rem;
  font-weight: 700;
  color: var(--brass);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin: 0 0 1.1rem;
}

.hero p.tagline {
  max-width: 46ch;
  color: var(--graphite);
  margin: 0 0 1.6rem;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.65rem 1.1rem;
  border-radius: 3px;
  font-size: 0.85rem;
  font-weight: 700;
  text-decoration: none;
  border: 1px solid transparent;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.btn-primary {
  background: var(--btn-primary-bg);
  color: var(--btn-primary-fg);
}

.btn-primary:hover {
  background: var(--brass);
  color: var(--btn-primary-fg);
}

.btn-ghost {
  border-color: var(--line);
  color: var(--ink);
}
.btn-ghost:hover { border-color: var(--brass); color: var(--brass); }

/* Sections */
section { padding: 2.6rem 0; }

h2.label { margin: 0 0 1.4rem; }

/* Services ticket */
.ticket { list-style: none; margin: 0; padding: 0; }

.ticket li {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  padding: 0.6rem 0;
  border-bottom: 1px dashed var(--line);
}

.ticket li:last-child { border-bottom: none; }

.ticket .name { font-weight: 600; }

.ticket .fill {
  flex: 1;
  border-bottom: 1px dotted var(--ash);
  transform: translateY(-4px);
  opacity: 0.6;
}

.ticket .price { font-weight: 700; color: var(--brass); }

.note {
  margin-top: 1.1rem;
  font-size: 0.8rem;
  color: var(--ash);
}

/* Hours + location */
.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}

@media (max-width: 560px) {
  .grid-2 { grid-template-columns: 1fr; }
}

.hours-table { width: 100%; border-collapse: collapse; }

.hours-table td { padding: 0.4rem 0; font-size: 0.92rem; }

.hours-table td:first-child { color: var(--graphite); }

.hours-table td:last-child { text-align: right; font-weight: 600; }

.hours-table tr.today td { color: var(--brass); font-weight: 700; }

address { font-style: normal; color: var(--graphite); }

address p { margin: 0 0 0.3rem; }

address .fine { margin-top: 0.6rem; font-size: 0.85rem; }

/* Contact */
.contact-list {
  list-style: none;
  margin: 1.2rem 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}

.contact-list a {
  text-decoration: none;
  font-weight: 600;
  border-bottom: 1px solid var(--line);
  padding-bottom: 2px;
  transition: border-color 0.15s ease, color 0.15s ease;
}

.contact-list a:hover,
.contact-list a:focus-visible {
  color: var(--brass);
  border-color: var(--brass);
}

.contact-lead { color: var(--graphite); max-width: 46ch; margin: 0 0 1.6rem; }

/* Request form (booking page) */
.request-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.1rem 1.2rem;
}

@media (max-width: 560px) {
  .request-form { grid-template-columns: 1fr; }
}

.field { display: flex; flex-direction: column; gap: 0.4rem; }

.field.full { grid-column: 1 / -1; }

.field label {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ash);
}

.field input,
.field select,
.field textarea {
  font: inherit;
  color: var(--ink);
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--line);
  padding: 0.5rem 0.1rem;
  border-radius: 0;
}

.field textarea { resize: vertical; min-height: 3.2rem; }

.field input:focus-visible,
.field select:focus-visible,
.field textarea:focus-visible {
  outline: none;
  border-bottom: 2px solid var(--brass);
}

.request-form .field.full:last-of-type { margin-top: 0.2rem; }

.form-submit {
  grid-column: 1 / -1;
  justify-self: start;
  margin-top: 0.4rem;
  cursor: pointer;
}

.request-result {
  margin-top: 1.6rem;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 1rem 1.1rem;
}

.request-result[hidden] { display: none; }

.btn-small {
  padding: 0.5rem 0.9rem;
  font-size: 0.78rem;
}

.copy-feedback {
  font-size: 0.78rem;
  color: var(--brass);
  font-weight: 600;
}

.result-fine {
  margin: 0.9rem 0 0;
  font-size: 0.78rem;
  color: var(--ash);
}

/* Time slot picker */
.slot-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.3rem;
}

.slot-message {
  font-size: 0.85rem;
  color: var(--ash);
  margin: 0.2rem 0 0;
}

.slot-btn {
  font-size: 0.82rem;
  font-weight: 600;
  padding: 0.45rem 0.75rem;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  transition: border-color 0.15s ease, color 0.15s ease, background 0.15s ease;
}

.slot-btn:hover { border-color: var(--brass); color: var(--brass); }

.slot-btn[aria-pressed="true"] {
  background: var(--btn-primary-bg);
  color: var(--btn-primary-fg);
  border-color: var(--btn-primary-bg);
}

.form-error {
  color: #b0413e;
  font-size: 0.85rem;
  font-weight: 600;
  margin: 0.9rem 0 0;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .form-error { color: #e08a86; }
}

:root[data-theme="dark"] .form-error { color: #e08a86; }

/* Back link (booking page) */
.back-link {
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  color: var(--graphite);
  border-bottom: 1px solid transparent;
  padding-bottom: 2px;
  transition: border-color 0.15s ease, color 0.15s ease;
}

.back-link:hover,
.back-link:focus-visible {
  color: var(--brass);
  border-color: var(--brass);
}

/* Admin page */
.login-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  max-width: 22rem;
}

.admin-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.6rem;
}

.logout-btn {
  background: none;
  border: none;
  font: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--graphite);
  cursor: pointer;
  border-bottom: 1px solid var(--line);
  padding: 0 0 2px;
}

.logout-btn:hover { color: var(--brass); border-color: var(--brass); }

.bookings-day {
  margin-bottom: 1.8rem;
}

.bookings-day h3 {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--brass);
  margin: 0 0 0.7rem;
}

.booking-row {
  display: flex;
  gap: 1rem;
  align-items: baseline;
  padding: 0.65rem 0;
  border-bottom: 1px dashed var(--line);
}

.booking-row:last-child { border-bottom: none; }

.booking-row .time {
  font-weight: 700;
  color: var(--ink);
  width: 5.4rem;
  flex-shrink: 0;
}

.booking-row .who {
  flex: 1;
}

.cancel-btn {
  align-self: center;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.9rem;
  height: 1.9rem;
  padding: 0;
  border: none;
  background: none;
  color: var(--ash);
  cursor: pointer;
  border-radius: 3px;
  transition: color 0.15s ease, background 0.15s ease;
}

.cancel-btn:hover,
.cancel-btn:focus-visible {
  color: #b0413e;
  background: rgba(176, 65, 62, 0.1);
  outline: none;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .cancel-btn:hover,
  :root:not([data-theme="light"]) .cancel-btn:focus-visible {
    color: #e08a86;
    background: rgba(224, 138, 134, 0.12);
  }
}

:root[data-theme="dark"] .cancel-btn:hover,
:root[data-theme="dark"] .cancel-btn:focus-visible {
  color: #e08a86;
  background: rgba(224, 138, 134, 0.12);
}

/* Cancel-booking modal */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  z-index: 100;
}

.modal-overlay[hidden] { display: none; }

.modal-card {
  background: var(--bone);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 1.6rem;
  max-width: 26rem;
  width: 100%;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.25);
}

.booking-row .who .name { font-weight: 600; }

.booking-row .who .meta {
  display: block;
  font-size: 0.82rem;
  color: var(--ash);
  margin-top: 0.1rem;
}

footer { padding: 2rem 0 3rem; }

footer .fine {
  font-size: 0.78rem;
  color: var(--ash);
  max-width: 46ch;
  margin: 1.5rem 0 0;
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
}
