/* Buchungsseite im Look der Calendly-Seite (Maße aus den Referenz-Screenshots). */
:root {
  --blue: #0069ff; --blue-dark: #0056d6; --blue-text: #004eba; --blue-soft: #f4f8ff; --blue-soft-hover: #e1ecff;
  --navy: #0a2540; --muted: #476788; --grey-num: #476788; --line: #d4e0ed; --input: #a6bbd1;
  --sel-grey: #84929f; --link: #004eba; --icon: #0b3558; --bg: #fafafa; --err-bg: #fdecea; --err: #b3261e;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--navy); font: 16px/1.5 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; -webkit-font-smoothing: antialiased; }
html.embedded, html.embedded body { background: transparent; }
[hidden] { display: none !important; }
button { font: inherit; color: inherit; }
a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
svg { display: block; }

/* ---------- Karte ---------- */
.card { position: relative; display: grid; grid-template-columns: 400px 400px; width: 800px; max-width: calc(100% - 32px); min-height: 700px; margin: 66px auto; background: #fff; border: 1px solid var(--line); border-radius: 8px; box-shadow: 0 1px 8px rgba(0, 0, 0, .08); }
html.embedded .card { margin: 4px auto 24px; }
.card.is-wide.has-day, .card.is-wide.view-form, .card.is-wide.view-reschedule, .card.is-wide.view-done { grid-template-columns: 370px 1fr; width: 1060px; }
.card.is-wide.view-date.has-day { height: 700px; }
.card.narrow.message { display: block; width: 560px; min-height: 0; padding: 32px; }

/* ---------- Infospalte links ---------- */
.info { position: relative; display: flex; flex-direction: column; padding: 25px 24px 25px 29px; border-right: 1px solid var(--line); min-width: 0; }
.logo { width: 68px; height: 68px; display: block; margin: 0 0 3px; }
.round-back { display: flex; align-items: center; justify-content: center; width: 43px; height: 43px; padding: 0; border: 1px solid #dee7f1; border-radius: 50%; background: #fff; color: var(--blue); cursor: pointer; flex: none; }
.round-back svg { width: 20px; height: 20px; }
.round-back:hover { background: var(--blue-soft); }
.info .round-back { margin: 1px 0 24px 2px; }
.host { font-size: 16px; font-weight: 600; color: var(--muted); line-height: 24px; }
h1 { font-size: 28px; line-height: 33px; font-weight: 700; margin: 0 0 22px; color: var(--navy); letter-spacing: -.4px; }
.meta { list-style: none; margin: 0; padding: 0; }
.meta li { display: flex; align-items: flex-start; gap: 8px; margin: 0 0 9px; font-size: 14.5px; font-weight: 600; color: var(--muted); line-height: 24px; }
.meta li .ico { width: 20px; height: 20px; flex: none; margin-top: 2px; color: var(--icon); }
.meta li#meta-when, .meta li#meta-tz { font-size: 14.5px; letter-spacing: -.1px; line-height: 21px; gap: 10px; margin: 12px 0 9px 2px; }
.meta li#meta-when .ico, .meta li#meta-tz .ico { width: 22px; height: 22px; margin-top: 0; }
.hint { margin: 16px 0 0; padding: 10px 12px; border-radius: 8px; background: var(--blue-soft); font-size: 14px; color: var(--navy); }
.info-foot { margin-top: auto; padding: 24px 0 0 2px; font-size: 14px; font-weight: 500; }
.mobile-foot { display: none; }

/* ---------- Inhalt rechts ---------- */
.content { position: relative; display: flex; flex-direction: column; min-width: 0; min-height: 0; }
h2 { font-size: 20px; line-height: 28px; font-weight: 700; margin: 0; color: var(--navy); }
.loading { display: flex; justify-content: center; padding: 120px 0; }
.spinner { width: 36px; height: 36px; border: 3px solid var(--blue-soft-hover); border-top-color: var(--blue); border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.error { margin: 20px 32px 0; padding: 10px 14px; border-radius: 8px; background: var(--err-bg); color: var(--err); font-size: 14px; }

/* Schritt 1: Kalender (+ Uhrzeiten rechts daneben auf breiten Bildschirmen) */
.step-date { flex: 1; display: grid; grid-template-columns: 100%; min-height: 0; }
.card.is-wide.has-day .step-date { grid-template-columns: 362px 1fr; }
.date-pane { padding: 28px 20px 24px; min-width: 0; }
.card.is-wide.has-day .date-pane { padding: 28px 0 24px 19px; }
.date-pane h2 { margin: 0 12px 32px; }
.cal-head { display: flex; align-items: center; justify-content: center; gap: 22px; height: 36px; }
#month-label { min-width: 118px; text-align: center; font-size: 14.5px; font-weight: 600; color: var(--navy); }
.chev { display: flex; align-items: center; justify-content: center; width: 36px; height: 36px; padding: 0; border: 0; border-radius: 50%; background: transparent; color: var(--blue-text); cursor: pointer; }
.chev svg { width: 18px; height: 18px; }
.chev:hover:not(:disabled) { background: var(--blue-soft); }
.chev:disabled { color: var(--muted); opacity: .9; cursor: default; }
.weekdays, .days { display: grid; grid-template-columns: repeat(7, 1fr); text-align: center; }
.weekdays { margin-top: 18px; height: 22px; }
.weekdays span { font-size: 11.5px; font-weight: 600; line-height: 22px; color: var(--muted); }
.days { grid-auto-rows: 52px; }
.days > span { display: block; }
.days button { position: relative; justify-self: center; align-self: center; width: 44px; height: 44px; max-width: 100%; padding: 0; border: 0; border-radius: 50%; background: transparent; font-size: 16px; line-height: 44px; color: var(--grey-num); cursor: default; }
.days button.free { background: var(--blue-soft); color: var(--blue-text); font-weight: 500; cursor: pointer; }
.days button.free:hover { background: var(--blue-soft-hover); font-weight: 600; }
.days button.selected, .days button.selected:hover { background: var(--blue); color: #fff; font-weight: 600; }
.days button.today::after { content: ""; position: absolute; left: 50%; bottom: 5px; width: 4px; height: 4px; margin-left: -2px; border-radius: 50%; background: currentColor; }
.days button:focus-visible, .chev:focus-visible, .time:focus-visible, .round-back:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }

.tz-block { margin: 28px 12px 0; }
.tz-label { font-size: 14px; font-weight: 700; line-height: 20px; color: var(--navy); }
.tz-pick { position: relative; display: inline-flex; align-items: center; gap: 2px; height: 28px; margin: 3px 0 0; padding: 0 6px 0 10px; border-radius: 4px; font-size: 14px; color: var(--navy); cursor: pointer; max-width: 100%; }
.tz-pick:hover { background: #f0f3f8; }
.tz-pick .g { width: 14px; height: 14px; flex: none; }
.tz-pick .tz-text { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tz-pick .c { width: 10px; height: 6px; flex: none; margin-left: 9px; }
.tz-pick select { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; font-size: 16px; }
.tz-pick:focus-within { outline: 2px solid var(--blue); outline-offset: 1px; }

.times-pane { display: flex; flex-direction: column; min-height: 0; padding: 0 19px 0 33px; }
.times-head { display: none; }
#day-label { margin: 87px 0 37px -10px; font-size: 16px; line-height: 24px; font-weight: 400; color: var(--navy); }
.time-list { flex: 1; min-height: 0; overflow-y: auto; padding: 0 2px 24px 0; margin-right: -2px; }
.time-row { display: grid; grid-template-columns: 1fr; gap: 8px; margin: 0 0 10px; }
.time-row.sel { grid-template-columns: 1fr 1fr; }
.time { display: block; width: 100%; height: 52px; padding: 0; border: 1px solid #006bff; border-radius: 4px; background: #fff; color: var(--blue-text); font-size: 16px; font-weight: 700; cursor: pointer; }
.time:hover { box-shadow: inset 0 0 0 1px #006bff; }
.time-sel { display: flex; align-items: center; justify-content: center; height: 52px; border-radius: 4px; background: var(--sel-grey); color: #fff; font-size: 16px; font-weight: 700; }
.time-next { height: 52px; border: 0; border-radius: 4px; background: var(--blue); color: #fff; font-size: 16px; font-weight: 700; cursor: pointer; }
.time-next:hover { background: var(--blue-dark); }

/* Schritt 2: Formular */
.step-form { padding: 24px 30px 36px; max-width: 460px; }
.step-form h2 { margin: 0 0 3px; }
.field { display: block; margin: 0 0 23px; }
.lbl { display: block; margin: 0 0 5px; font-size: 14px; line-height: 20px; font-weight: 700; color: var(--navy); }
input, textarea { display: block; width: 100%; height: 40px; padding: 0 14px; border: 1px solid var(--input); border-radius: 8px; background: #fff; color: var(--navy); font: inherit; font-size: 15px; }
textarea { height: 57px; padding: 10px 14px; line-height: 1.4; resize: vertical; }
input:focus, textarea:focus, .phone:focus-within { outline: none; border-color: var(--blue); box-shadow: 0 0 0 1px var(--blue); }
.field small { display: block; margin-top: 6px; font-size: 13px; color: var(--muted); }
.pill { display: block; width: fit-content; height: 32px; margin: -9px 0 19px; padding: 0 12px; border: 1px solid var(--blue); border-radius: 40px; background: #fff; color: var(--blue-text); font-size: 14px; font-weight: 600; cursor: pointer; }
.pill:hover { background: var(--blue-soft); }
.phone { display: flex; align-items: center; height: 40px; border: 1px solid var(--input); border-radius: 8px; background: #fff; }
.phone .flag { width: 21px; height: 14px; margin: 0 0 0 12px; flex: none; background: linear-gradient(#000 0 33.3%, #dd0000 33.3% 66.6%, #ffce00 66.6%); }
.phone .cc { margin: 0 0 0 27px; font-size: 15px; color: var(--navy); }
.phone input { flex: 1; min-width: 0; height: 38px; padding: 0 12px 0 6px; border: 0; background: transparent; }
.phone input:focus { box-shadow: none; }
.hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.privacy { margin: -10px 0 22px; font-size: 14px; line-height: 21px; color: var(--navy); }
.privacy a { color: var(--blue); font-weight: 600; }
.btn { display: inline-block; height: 40px; padding: 0 17px; border: 0; border-radius: 40px; background: var(--blue); color: #fff; font-size: 14px; font-weight: 600; cursor: pointer; text-decoration: none; line-height: 40px; }
.btn:hover { background: var(--blue-dark); text-decoration: none; }
.btn:disabled { opacity: .6; cursor: wait; }
.btn.secondary { background: #fff; color: var(--blue); border: 1px solid var(--blue); line-height: 38px; }
.btn.danger { background: var(--err); }
.ext-note { margin: 11px 0 0; font-size: 11px; line-height: 14px; color: var(--navy); }
.chosen { margin: 16px 0 24px; padding: 12px 14px; border-radius: 8px; background: var(--blue-soft); font-size: 15px; }
.step-done { padding: 28px 30px; }
.step-done p { font-size: 15px; }

/* Server-Seiten (Absage, Meldungen) */
.message h1 { font-size: 24px; line-height: 30px; margin: 0 0 16px; }
.message .logo { margin: -8px 0 8px -6px; }
.message .host { margin: 0 0 2px; }
.message p { font-size: 15px; }
.message .when { display: flex; gap: 10px; align-items: flex-start; font-size: 15px; font-weight: 600; color: var(--muted); }
.message .when .ico { width: 20px; height: 20px; flex: none; margin-top: 2px; color: var(--icon); }
.message form .field { margin: 20px 0; }
.message .actions { display: flex; flex-wrap: wrap; gap: 10px; }

/* ---------- mittlere Breite: Uhrzeiten als eigene Ansicht ---------- */
.card:not(.is-wide).view-times .date-pane { display: none; }
.card:not(.is-wide) .times-pane { padding: 0; }
.card:not(.is-wide) .times-head { display: block; position: relative; padding: 17px 17px 0; text-align: center; }
.times-head .round-back { position: absolute; left: 17px; top: 17px; }
.times-day { display: flex; flex-direction: column; align-items: center; padding: 0 44px; }
.times-day strong { font-size: 20px; line-height: 28px; font-weight: 700; margin-top: 7px; }
.times-day span { font-size: 14px; line-height: 20px; margin-top: 7px; }
.times-head .tz-block { display: inline-block; margin: 12px 0 0; text-align: left; }
.times-head .tz-label { font-size: 13px; }
.times-head .tz-pick { margin-top: 2px; }
.times-head hr { margin: 26px -17px 0; border: 0; border-top: 1px solid var(--line); }
.times-title { margin: 17px 0 0; }
.times-dur { margin: 13px 0 0; font-size: 13px; line-height: 20px; }
.card:not(.is-wide) #day-label { display: none; }
.card:not(.is-wide) .time-list { overflow: visible; padding: 24px 17px 24px; margin: 0; }

/* ---------- Handy ---------- */
@media (max-width: 699px) {
  html, body { background: #fff; }
  .card, .card.is-wide.has-day { display: block; width: 100%; max-width: none; min-height: 0; margin: 0; border: 0; border-radius: 0; box-shadow: none; }
  .card.narrow.message { width: 100%; padding: 24px 16px; }
  .info { padding: 24px 16px 20px; border-right: 0; border-bottom: 1px solid var(--line); align-items: center; text-align: center; }
  .info .meta li { justify-content: center; }
  .info-foot { display: none; }
  .mobile-foot { display: block; padding: 24px 16px 32px; font-size: 14px; font-weight: 500; }
  .view-times .info { display: none; }
  .view-form .info, .view-reschedule .info, .view-done .info { position: relative; align-items: stretch; text-align: left; padding: 17px 16px 40px; }
  .view-form .info .logo, .view-form .info .host, .view-reschedule .info .logo, .view-reschedule .info .host, .view-done .info .logo, .view-done .info .host { display: none; }
  .view-form .info .round-back, .view-reschedule .info .round-back { position: absolute; left: 17px; top: 17px; margin: 0; }
  .view-form h1, .view-reschedule h1, .view-done h1 { margin: 5px 44px 24px; text-align: center; font-size: 24px; line-height: 32px; }
  .view-form .info .meta li, .view-reschedule .info .meta li { justify-content: flex-start; margin: 0 0 12px; }
  .view-form .meta li#meta-when, .view-form .meta li#meta-tz { margin: 14px 0 14px 0; }
  .date-pane { padding: 24px 12px; }
  .date-pane h2 { margin: 0 4px 20px; }
  .tz-block { margin: 20px 4px 0; }
  .step-form { max-width: none; padding: 24px 16px 8px; }
  .pill, .btn { display: block; width: 100%; text-align: center; }
  .step-done { padding: 24px 16px; }
  .error { margin: 16px 16px 0; }
}
