/* Plus Jakarta Sans (wie die Website), nur für das Design "Modern" (Pro) */
@font-face {
  font-family: "Kammzeit Sans";
  src: url("/static/fonts/display.woff2") format("woff2");
  font-weight: 400 800;
  font-display: swap;
}
:root {
  --accent: #3b82f6;  /* Salon überschreibt per style="--accent: ...; --on-accent: ..." */
  --on-accent: #000;  /* Text auf --accent, der Handler wählt Schwarz oder Weiß (onAccent) */
  --fg: #111;
  --bg: #fff;
  --muted: #555;      /* 7:1 auf Weiß */
  --line: #d4d4d4;
  --soft: #f3f3f3;
  --danger: #b00020;
  --focus: #111;      /* Fokusrahmen und heller Ring darum */
  --focus-ring: #fff;
  --r: 0;             /* Ecken: eckig, Design "Rund" (Pro) setzt 12px */
  --font: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
/* Design der Buchungsseite (Pro, Klassen am body aus custom.go themeClass) */
body.font-modern { --font: "Kammzeit Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }
body.font-klassisch { --font: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, "Times New Roman", serif; }
body.round { --r: 12px; }
/* Dunkel: Kontraste wie hell (Text 16:1, gedämpft 8:1, Fehler 6:1 auf #121212) */
body.dark { --fg: #ededed; --bg: #121212; --muted: #b0b0b0; --line: #3d3d3d; --soft: #1f1f1f; --danger: #ff8a95; --focus: #fff; --focus-ring: #121212; color-scheme: dark; }

* { box-sizing: border-box; }
body { margin: 0; font: 16px/1.5 var(--font); color: var(--fg); background: var(--bg); }
body.salon { border-top: 6px solid var(--accent); }
main, footer { max-width: 640px; margin: 0 auto; padding: 32px 20px; }
footer { padding-top: 0; color: var(--muted); font-size: .875rem; }
a { color: inherit; text-underline-offset: 2px; }
/* Fokus: dunkler Rahmen mit hellem Ring, sichtbar auf jeder Akzentfarbe */
:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; box-shadow: 0 0 0 4px var(--focus-ring); }
h1 { font-size: 2.25rem; line-height: 1.1; margin: 0 0 8px; letter-spacing: -.02em; overflow-wrap: anywhere; }
h2 { font-size: 1.125rem; margin: 28px 0 6px; }
.lead { margin: 0 0 8px; color: var(--muted); }
.muted { color: var(--muted); }
.small { font-size: .875rem; }
.crumb { margin: 0 0 28px; font-weight: 700; }
.crumb a { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; }
.crumb a:hover { text-decoration: underline; }
.crumb img { width: auto; height: 28px; max-width: 84px; object-fit: contain; border-radius: calc(var(--r) / 2); }

/* Kopf der Buchungsseite */
.cover { display: block; width: 100%; aspect-ratio: 16 / 7; object-fit: cover; margin: 0 0 24px; border-radius: var(--r); background: var(--soft); }
.salon-title { display: flex; align-items: center; gap: 16px; }
.salon-title h1 { margin: 0; }
.salon-logo { flex: none; width: auto; height: 64px; max-width: 160px; object-fit: contain; border-radius: calc(var(--r) / 2); }
/* Dunkel: Logos sind meist dunkel auf transparent, daher auf heller Fläche */
body.dark .salon-logo, body.dark .crumb img { padding: 6px; background: #fff; }
.welcome { margin: 16px 0 0; padding: 10px 0 10px 14px; border-left: 4px solid var(--accent); font-size: 1.0625rem; font-weight: 600; white-space: pre-line; }
.about { margin: 12px 0 0; font-size: 1.0625rem; white-space: pre-line; }
.salon-info { display: grid; gap: 16px; margin-top: 20px; padding-top: 12px; border-top: 1px solid var(--line); }
.contact { display: flex; flex-direction: column; gap: 4px; font-style: normal; }
.addr { white-space: pre-line; }
.contact-links { display: flex; flex-wrap: wrap; gap: 4px 20px; }
.contact-links:empty, .contact:not(:has(.addr, a)), .salon-info:not(:has(.addr, a, .hours)) { display: none; }
.hours h2 { margin: 0 0 4px; font-size: 1rem; }
.hours dl { display: block; margin: 0; }
.hours dl > div { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding: 3px 0; border-bottom: 1px solid var(--line); }
.hours dl > div:last-child { border-bottom: 0; }
.hours dt { color: var(--fg); }
.hours dd { font-weight: 600; font-variant-numeric: tabular-nums; text-align: right; }
.hours dd span { display: block; white-space: nowrap; }
.hours dd.closed { font-weight: 400; color: var(--muted); }
.hours .today dt, .hours .today dd { font-weight: 800; }
.today-mark { margin-left: 6px; padding: 0 6px; font-size: .75rem; font-weight: 700; color: var(--on-accent); background: var(--accent); border-radius: calc(var(--r) / 2); vertical-align: 1px; }
.social { display: flex; flex-wrap: wrap; gap: 8px; margin: 20px 0 0; padding: 0; list-style: none; }
.social a { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 8px 14px; border: 1px solid var(--fg); border-radius: var(--r); font-weight: 600; text-decoration: none; }
.social a:hover { background: var(--soft); }
.social svg { flex: none; }

/* Formular */
fieldset { border: 0; border-top: 2px solid var(--fg); margin: 36px 0 0; padding: 12px 0 0; min-width: 0; }
legend { font-weight: 800; font-size: 1.125rem; padding-right: 8px; }

.opt { display: flex; gap: 12px; align-items: flex-start; padding: 12px 0 12px 10px; border-bottom: 1px solid var(--line); border-left: 4px solid transparent; cursor: pointer; }
.opt:hover { background: var(--soft); }
.opt:has(input:checked) { border-left-color: var(--accent); }
.opt input { flex: none; width: 18px; height: 18px; margin: 3px 0 0; accent-color: var(--fg); }
.opt-text { flex: 1; min-width: 0; }
.opt-name { display: block; font-weight: 600; }
.opt-desc { display: block; margin-top: 2px; color: var(--muted); font-size: .875rem; }
.opt-meta { flex: none; text-align: right; color: var(--muted); font-size: .875rem; font-variant-numeric: tabular-nums; }
.opt-meta strong { display: block; color: var(--fg); font-size: 1rem; }

#slots { margin-top: 4px; min-height: 48px; }
#slots.htmx-request { opacity: .5; }
.slots { display: grid; grid-template-columns: repeat(auto-fill, minmax(76px, 1fr)); gap: 8px; }
.slot { position: relative; cursor: pointer; }
.slot input { position: absolute; inset: 0; margin: 0; opacity: 0; }
.slot span { display: block; padding: 11px 0; text-align: center; font-weight: 600; font-variant-numeric: tabular-nums; border: 1px solid var(--fg); border-radius: var(--r); }
.slot:hover span { background: var(--soft); }
.slot input:checked + span { background: var(--accent); color: var(--on-accent); box-shadow: inset 0 0 0 2px var(--fg); font-weight: 800; }
.slot input:focus-visible + span { outline: 2px solid var(--focus); outline-offset: 2px; box-shadow: 0 0 0 4px var(--focus-ring); }
.slot input:checked:focus-visible + span { box-shadow: inset 0 0 0 2px var(--fg), 0 0 0 4px var(--focus-ring); }

.field { display: block; margin: 12px 0; font-size: .875rem; font-weight: 600; }
.optional { font-weight: 400; color: var(--muted); }
input[type=text], input[type=email], input[type=tel], input[type=date] {
  display: block; width: 100%; min-height: 48px; margin-top: 4px; padding: 10px; font: inherit; font-size: 1rem; font-weight: 400;
  border: 1px solid var(--fg); border-radius: var(--r); background: var(--bg); color: var(--fg);
}
input, select, textarea { font-size: 16px; } /* darunter zoomt iOS beim Antippen */
input[aria-invalid=true], select[aria-invalid=true], textarea[aria-invalid=true] { border: 2px solid var(--danger); }
input[type=checkbox][aria-invalid=true] { outline: 2px solid var(--danger); outline-offset: 2px; }
.field .hint { display: block; margin-top: 4px; font-weight: 400; color: var(--muted); }
.field-error { display: block; margin-top: 4px; font-weight: 600; color: var(--danger); }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

button, .btn { display: block; width: 100%; margin-top: 24px; padding: 14px 20px; font: inherit; font-weight: 700; text-align: center; text-decoration: none;
  color: var(--bg); background: var(--fg); border: 2px solid var(--fg); border-radius: var(--r); cursor: pointer; }
button:hover, .btn:hover { background: var(--accent); color: var(--on-accent); }

.notice { padding: 12px 14px; border-left: 4px solid var(--fg); background: var(--soft); }

dl { display: grid; grid-template-columns: max-content 1fr; gap: 6px 16px; margin: 20px 0; }
dt { color: var(--muted); }
dd { margin: 0; font-weight: 600; }

/* Fotogalerie (Pro) */
.gallery { margin-top: 48px; }
.gallery h2 { margin: 0 0 12px; padding-top: 12px; border-top: 2px solid var(--fg); font-size: 1.125rem; }
.gallery ul { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin: 0; padding: 0; list-style: none; }
.gallery img { display: block; width: 100%; height: auto; aspect-ratio: 1; object-fit: cover; border-radius: var(--r); background: var(--soft); }

/* Tippflächen am Touchscreen mindestens 44px hoch */
@media (pointer: coarse) {
  footer a, .crumb a, .contact-links a { display: inline-flex; align-items: center; min-height: 44px; }
}

/* Schmal: Titelbild randlos unter der Akzentleiste */
@media (max-width: 559px) {
  .cover { width: calc(100% + 40px); max-width: none; margin: -32px -20px 20px; aspect-ratio: 16 / 9; border-radius: 0; }
  .salon-logo { height: 52px; max-width: 120px; }
}

@media (min-width: 560px) {
  h1 { font-size: 2.75rem; }
  .btn { display: inline-block; width: auto; }
  .salon-info:has(.hours) { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px; }
  .gallery ul { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
