/* Booking callback widget — cal.com-like flow, Reev dark + red */

.reev-booking-honeypot {
  position: absolute;
  left: -9999px;
  opacity: 0;
  height: 0;
  width: 0;
}

.reev-contact-modal-dialog.reev-booking-dialog {
  max-width: 980px;
  padding: 0;
  overflow-x: hidden;
  overflow-y: auto;
  background: #1f1f1f;
  transform: translateY(18px) scale(0.975);
  transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.45s ease;
}

.reev-contact-modal.is-open .reev-contact-modal-dialog.reev-booking-dialog {
  transform: none;
}

.reev-booking-dialog .reev-contact-modal-close {
  z-index: 3;
  top: 14px;
  right: 14px;
}

.reev-booking {
  min-height: 560px;
}

.reev-booking-step {
  display: none;
}

.reev-booking-step.is-active {
  display: grid;
  animation: reevBookingEnter 0.48s cubic-bezier(0.22, 1, 0.36, 1);
}

.reev-booking-step.is-active.is-back {
  animation-name: reevBookingBack;
}

.reev-booking-step[data-booking-step="schedule"].is-active {
  grid-template-columns: 280px 1fr;
  min-height: 560px;
}

.reev-booking-step[data-booking-step="details"].is-active,
.reev-booking-step[data-booking-step="done"].is-active {
  display: block;
}

@keyframes reevBookingEnter {
  from {
    opacity: 0;
    transform: translateX(32px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes reevBookingBack {
  from {
    opacity: 0;
    transform: translateX(-32px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.reev-booking-meta {
  padding: 36px 28px 32px;
  padding-right: 48px;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  background: linear-gradient(180deg, rgba(248, 68, 56, 0.08) 0%, rgba(31, 31, 31, 0) 42%);
}

.reev-booking-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 28px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.reev-booking-brand img {
  width: 36px;
  height: 36px;
  object-fit: contain;
  border-radius: 8px;
}

.reev-booking-meta h3,
.reev-booking-form h3,
.reev-booking-done h3 {
  font-size: 28px;
  line-height: 1.2;
  margin-bottom: 12px;
  letter-spacing: -0.03em;
}

.reev-booking-lead {
  margin: 0 0 24px;
  color: rgba(255, 255, 255, 0.58);
  font-size: 15px;
  line-height: 1.55;
}

.reev-booking-facts {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 12px;
}

.reev-booking-facts li {
  display: flex;
  align-items: center;
  gap: 10px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 14px;
}

.reev-booking-facts i {
  width: 18px;
  color: var(--main-color);
  text-align: center;
}

.reev-booking-picker {
  display: grid;
  grid-template-columns: 1fr 0fr;
  min-height: 560px;
  transition: grid-template-columns 0.45s cubic-bezier(0.22, 1, 0.36, 1);
}

.reev-booking-picker.has-times {
  grid-template-columns: 1fr 220px;
}

.reev-booking-picker.has-times .reev-booking-calendar {
  padding-right: 20px;
}

.reev-booking-calendar {
  padding: 52px 48px 28px 28px;
  min-width: 0;
}

.reev-booking-cal-kicker {
  margin: 0 0 8px;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.42);
}

.reev-booking-cal-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}

.reev-booking-cal-nav h4 {
  margin: 0;
  font-size: 18px;
  font-weight: 500;
  text-align: center;
  flex: 1;
}

.reev-booking-nav {
  width: 36px;
  height: 36px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 50%;
  background: transparent;
  color: #fff;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.reev-booking-nav:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.28);
}

.reev-booking-nav:disabled {
  opacity: 0.28;
  cursor: default;
}

.reev-booking-weekdays,
.reev-booking-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}

.reev-booking-weekdays {
  margin-bottom: 6px;
}

.reev-booking-weekdays span {
  text-align: center;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.38);
  padding: 6px 0;
}

.reev-booking-day {
  aspect-ratio: 1;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: #fff;
  font-size: 14px;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.reev-booking-day:focus-visible {
  outline: 2px solid rgba(248, 68, 56, 0.85);
  outline-offset: 2px;
}

.reev-booking-day:hover:not(:disabled):not(.is-selected) {
  background: rgba(255, 255, 255, 0.08);
  transform: scale(1.06);
}

.reev-booking-day.is-today:not(.is-selected) {
  box-shadow: inset 0 0 0 1px rgba(248, 68, 56, 0.85);
  color: #ffb4ae;
}

.reev-booking-day.is-selected {
  background: var(--main-color);
  color: #fff;
  box-shadow: 0 8px 20px rgba(248, 68, 56, 0.28);
}

.reev-booking-day:disabled {
  color: rgba(255, 255, 255, 0.18);
  cursor: default;
}

.reev-booking-day.is-outside {
  visibility: hidden;
}

.reev-booking-times {
  border-left: 1px solid rgba(255, 255, 255, 0.08);
  padding: 52px 44px 20px 14px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.reev-booking-times[hidden] {
  display: none;
}

.reev-booking-picker.has-times .reev-booking-times {
  animation: reevTimesRail 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes reevTimesRail {
  from {
    opacity: 0;
    transform: translateX(24px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.reev-booking-times-head {
  margin-bottom: 12px;
  padding-right: 8px;
}

.reev-booking-slots {
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-right: 6px;
  max-height: 430px;
}

.reev-booking-slot {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.02);
  color: #fff;
  border-radius: 10px;
  padding: 11px 10px;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
  cursor: pointer;
  animation: reevSlotIn 0.42s cubic-bezier(0.22, 1, 0.36, 1) both;
  animation-delay: calc(var(--i, 0) * 35ms);
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease, color 0.2s ease;
}

.reev-booking-slot:hover,
.reev-booking-slot:focus-visible {
  background: var(--main-color);
  border-color: var(--main-color);
  transform: translateX(-2px);
}

@keyframes reevSlotIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.reev-booking-empty {
  color: rgba(255, 255, 255, 0.45);
  font-size: 13px;
  line-height: 1.5;
  padding: 8px 4px;
}

.reev-booking-form,
.reev-booking-done {
  padding: 36px 48px 40px;
  max-width: 640px;
  margin: 0 auto;
}

.reev-booking-back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 22px;
  padding: 0;
  border: 0;
  background: none;
  color: rgba(255, 255, 255, 0.62);
  font-size: 14px;
  cursor: pointer;
  transition: color 0.2s ease;
}

.reev-booking-form .reev-booking-back,
.reev-contact-modal-form .reev-booking-back {
  background: none;
  color: rgba(255, 255, 255, 0.62);
}

.reev-booking-back:hover,
.reev-booking-form .reev-booking-back:hover,
.reev-contact-modal-form .reev-booking-back:hover {
  background: none;
  color: #fff;
}

.reev-booking-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 0 28px;
}

.reev-booking-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(248, 68, 56, 0.12);
  border: 1px solid rgba(248, 68, 56, 0.28);
  color: #ffd2ce;
  font-size: 13px;
}

.reev-booking-form textarea {
  min-height: 84px;
}

.reev-booking-form .butn:disabled {
  opacity: 0.55;
  pointer-events: none;
}

.reev-booking-form .butn:hover,
.reev-booking-done .butn:hover {
  background: #fff;
  color: #151515;
}

.reev-booking-done {
  text-align: center;
  padding-top: 64px;
  padding-bottom: 64px;
}

.reev-booking-done .reev-booking-summary {
  justify-content: center;
}

.reev-booking-done-mark {
  width: 72px;
  height: 72px;
  margin: 0 auto 22px;
}

.reev-booking-done-mark svg {
  width: 72px;
  height: 72px;
}

.reev-booking-done-mark circle {
  stroke: rgba(248, 68, 56, 0.35);
  stroke-width: 2;
  fill: rgba(248, 68, 56, 0.12);
  transform-origin: 36px 36px;
}

.reev-booking-done.is-active .reev-booking-done-mark circle {
  animation: reevDoneRing 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}

.reev-booking-done-mark path {
  stroke: var(--main-color);
  stroke-width: 3.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
  stroke-dasharray: 48;
  stroke-dashoffset: 48;
}

.reev-booking-done.is-active .reev-booking-done-mark path {
  animation: reevDoneCheck 0.45s 0.2s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

@keyframes reevDoneRing {
  from {
    transform: scale(0.6);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

@keyframes reevDoneCheck {
  to {
    stroke-dashoffset: 0;
  }
}

@media screen and (max-width: 900px) {
  .reev-booking {
    min-height: 0;
  }

  .reev-booking-step[data-booking-step="schedule"].is-active {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .reev-booking-meta {
    border-right: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    padding: 52px 48px 20px 24px;
  }

  .reev-booking-facts {
    grid-template-columns: 1fr 1fr;
  }

  .reev-booking-picker,
  .reev-booking-picker.has-times {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .reev-booking-calendar {
    padding: 22px 48px 12px 20px;
  }

  .reev-booking-times {
    border-left: 0;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding: 16px 20px 24px;
  }

  .reev-booking-slots {
    max-height: 240px;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .reev-booking-form,
  .reev-booking-done {
    padding: 28px 24px 32px;
  }
}

@media screen and (max-width: 768px) {
  .reev-contact-modal-dialog.reev-booking-dialog {
    max-height: calc(100vh - 32px);
    overflow-y: auto;
    padding: 0;
  }

  .reev-booking-facts {
    grid-template-columns: 1fr;
  }

  .reev-booking-meta h3,
  .reev-booking-form h3,
  .reev-booking-done h3 {
    font-size: 24px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .reev-contact-modal,
  .reev-contact-modal-dialog.reev-booking-dialog,
  .reev-booking-step.is-active,
  .reev-booking-picker,
  .reev-booking-picker.has-times .reev-booking-times,
  .reev-booking-slot,
  .reev-booking-day,
  .reev-booking-done-mark circle,
  .reev-booking-done-mark path {
    animation: none !important;
    transition: none !important;
  }

  .reev-booking-done-mark path {
    stroke-dashoffset: 0;
  }
}
