/* ==========================================================================
   Seminar booking modal – light surface, desktop popup / mobile bottom sheet
   ========================================================================== */

.rn-book-modal {
  position: fixed;
  inset: 0;
  z-index: 10050;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  visibility: hidden;
  pointer-events: none;
}

.rn-book-modal.is-open {
  visibility: visible;
  pointer-events: auto;
}

.rn-book-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  opacity: 0;
  transition: opacity 0.28s ease;
}

.rn-book-modal.is-open .rn-book-modal__backdrop {
  opacity: 1;
}

.rn-book-modal__sheet {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 520px;
  max-height: 90vh;
  overflow: auto;
  background: #fff;
  color: #111;
  border-radius: var(--rn-radius-card);
  padding: 32px 28px 28px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.28);
  transform: translateY(12px) scale(0.97);
  opacity: 0;
  transition: transform 0.3s ease, opacity 0.28s ease;
  -webkit-overflow-scrolling: touch;
}

.rn-book-modal.is-open .rn-book-modal__sheet {
  transform: translateY(0) scale(1);
  opacity: 1;
}

body.rn-book-modal-open {
  overflow: hidden;
}

/* Close */
.rn-book-modal__close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 50%;
  background: #f3f3f3;
  color: #111;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}

.rn-book-modal__close:hover {
  background: #111;
  color: #fff;
}

.rn-book-modal__close .material-symbols-rounded {
  font-size: 22px;
}

/* Head */
.rn-book-modal__head {
  margin: 0 36px 28px 0;
}

.rn-book-modal__eyebrow {
  margin: 0 0 8px;
  font-size: var(--rn-eyebrow-size);
  font-weight: 700;
  letter-spacing: var(--rn-eyebrow-track);
  text-transform: uppercase;
  color: var(--rn-accent-dark);
}

.rn-book-modal__title {
  margin: 0;
  font-size: clamp(22px, 3vw, 28px);
  line-height: 1.15;
  font-weight: 800;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: #111;
}

.rn-book-modal__meta {
  margin: 10px 0 0;
  font-size: 0.9375rem;
  line-height: 1.5;
  color: #666;
}

/* Steps */
.rn-book-modal__step[hidden] {
  display: none !important;
}

.rn-book-modal__label {
  display: block;
  margin-bottom: 14px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #555;
}

.rn-book-modal__stepper {
  display: flex;
  align-items: center;
  width: max-content;
  border: 1px solid #ddd;
  border-radius: var(--rn-radius-card);
  background: #fff;
  margin-bottom: 16px;
}

.rn-book-modal .rn-stepper__btn {
  width: 48px;
  height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: none;
  border: 0;
  color: #111;
  cursor: pointer;
}

.rn-book-modal .rn-stepper__btn:hover {
  color: #9C7A48;
}

.rn-book-modal .rn-stepper__input {
  width: 52px;
  height: 48px;
  text-align: center;
  border: 0;
  background: transparent;
  color: #111;
  font-size: 18px;
  font-weight: 800;
  font-family: inherit;
  -moz-appearance: textfield;
}

.rn-book-modal .rn-stepper__input::-webkit-outer-spin-button,
.rn-book-modal .rn-stepper__input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.rn-book-modal__cost {
  margin: 0 0 24px;
  font-size: 15px;
  color: #555;
  min-height: 1.4em;
}

.rn-book-modal__back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 0 0 18px;
  padding: 0;
  border: 0;
  background: none;
  color: #666;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  font-family: inherit;
}

.rn-book-modal__back:hover {
  color: #111;
}

.rn-book-modal__back .material-symbols-rounded {
  font-size: 18px;
}

/* Form (light) */
.rn-book-modal .rn-form-row {
  margin-bottom: 14px;
}

.rn-book-modal .rn-form-row--half {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.rn-book-modal .rn-label {
  display: block;
  margin-bottom: 6px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #555;
}

.rn-book-modal .rn-input {
  width: 100%;
  box-sizing: border-box;
  padding: 12px 14px;
  border: 1px solid #ddd;
  border-radius: var(--rn-radius-control);
  background: #fff;
  color: #111;
  font-size: 15px;
  font-family: inherit;
  outline: none;
  color-scheme: light;
  transition: border-color 0.2s ease;
}

.rn-book-modal .rn-input:focus {
  border-color: #9C7A48;
}

.rn-book-modal .rn-form-row--checkbox label {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 0.9375rem;
  line-height: 1.5;
  color: #555;
  cursor: pointer;
}

.rn-book-modal .rn-form-row--checkbox input {
  margin-top: 3px;
  accent-color: #9C7A48;
}

.rn-book-modal .rn-form-row--checkbox a {
  color: #9C7A48;
}

.rn-book-modal__summary {
  margin: 8px 0 18px;
  padding: 16px 18px;
  background: #f8f5ef;
  border-radius: var(--rn-radius-card);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.rn-book-modal__summary .rn-price-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  font-size: 0.9375rem;
  color: #555;
}

.rn-book-modal__summary .rn-price-row span:last-child {
  color: #111;
  font-weight: 600;
  text-align: right;
}

.rn-book-modal__summary .rn-price-row--total {
  font-size: 16px;
  font-weight: 800;
  color: #111;
  padding-top: 8px;
  border-top: 1px solid #e8e0d4;
}

.rn-book-modal__summary .rn-price-row--total span:last-child {
  color: #9C7A48;
}

.rn-book-modal__summary .rn-price-row[hidden] {
  display: none !important;
}

.rn-book-modal .rn-btn--primary {
  width: 100%;
  margin-top: 4px;
  min-height: var(--rn-btn-height);
  font-size: var(--rn-btn-size);
  letter-spacing: var(--rn-btn-track);
  border-radius: var(--rn-radius-control);
}

.rn-book-modal .rn-book-msg {
  margin-top: 14px;
  font-size: 0.9375rem;
}

.rn-book-modal .rn-book-msg[hidden] {
  display: none !important;
}

.rn-book-modal .rn-msg--success {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #1f7a45;
}

.rn-book-modal .rn-msg--error {
  color: #c0392b;
}

/* Success step */
.rn-book-modal__step--done {
  text-align: center;
  padding: 12px 0 4px;
}

.rn-book-modal__done-icon {
  font-size: 56px;
  color: #1f7a45;
  display: block;
  margin-bottom: 12px;
}

.rn-book-modal__done-title {
  margin: 0 0 10px;
  font-size: 22px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  color: #111;
}

.rn-book-modal__done-text {
  margin: 0 0 28px;
  font-size: 15px;
  line-height: 1.6;
  color: #555;
}

/* Mobile bottom sheet */
@media (max-width: 768px) {
  .rn-book-modal {
    align-items: flex-end;
    padding: 0;
  }

  .rn-book-modal__sheet {
    max-width: none;
    width: 100%;
    max-height: 90dvh;
    border-radius: var(--rn-radius-card) var(--rn-radius-card) 0 0;
    padding: 28px 20px calc(24px + env(safe-area-inset-bottom, 0px));
    transform: translateY(100%);
    opacity: 1;
  }

  .rn-book-modal.is-open .rn-book-modal__sheet {
    transform: translateY(0);
  }

  .rn-book-modal .rn-form-row--half {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  .rn-book-modal__backdrop,
  .rn-book-modal__sheet {
    transition: none;
  }
}

/* ── Ticketarten, Hinweis & Kassen-Hinweis ───────────────────── */
.rn-book-modal__loading {
  margin: 0 0 16px;
  font-size: 0.9375rem;
  color: var(--rn-text-mute);
}

.rn-book-modal__tickets {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 0 0 20px;
}

.rn-book-ticket {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 14px;
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: var(--rn-radius, 4px);
}

.rn-book-ticket__info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.rn-book-ticket__name {
  font-weight: 600;
  font-size: 15px;
  color: var(--rn-black, #000);
}

.rn-book-ticket__price {
  font-size: 0.9375rem;
  color: #666;
}

.rn-book-ticket .rn-book-modal__stepper {
  flex-shrink: 0;
  margin: 0;
}

.rn-book-modal__notice {
  margin: 0 0 16px;
  padding: 14px 16px;
  max-height: 220px;
  overflow-y: auto;
  font-size: 0.9375rem;
  line-height: 1.6;
  color: #444;
  background: var(--rn-off-white, #f8f7f5);
  border-radius: var(--rn-radius, 4px);
}

.rn-book-modal__notice p,
.rn-book-modal__notice ul {
  margin: 0 0 8px;
}

.rn-book-modal__notice ul {
  padding-left: 18px;
}

.rn-book-modal__paynote {
  margin: 0 0 14px;
  font-size: 0.9375rem;
  color: #666;
}

#rn-book-modal-next:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

@media (max-width: 480px) {
  .rn-book-ticket {
    padding: 10px 12px;
  }
}

/* Exklusiv-Anfrage: Terminblock (nur Location/Tagung), Honeypot, Fehlermeldung */
.rn-book-modal [hidden] { display: none !important; }
.rn-book-modal .rn-ex-termin { margin: 4px 0 8px; padding: 14px 16px 2px; border: 1px solid var(--rn-line, #e6e6e6); border-radius: var(--rn-radius-control, 10px); }
.rn-book-modal .rn-ex-termin legend { padding: 0 6px; font-weight: 700; }
.rn-book-modal .rn-ex-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.rn-book-modal .rn-book-msg.is-error { color: #b42318; }
