/* ============================================================
   DENTAL SPOT MANILA — Booking Page Styles
   ============================================================ */

body.book-page {
  background: var(--off-white);
  min-height: 100vh;
}

/* ---------- Booking Hero ---------- */
.book-hero {
  background: var(--navy-deeper);
  padding: 120px 0 52px;
  position: relative;
  overflow: hidden;
}
.book-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 60% 80% at 80% 50%, rgba(84,144,172,0.1) 0%, transparent 70%);
  pointer-events: none;
}
.book-hero .container { position: relative; z-index: 1; }

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.45);
  margin-bottom: 20px;
  transition: color 0.2s ease;
}
.back-link:hover { color: var(--white); }

.book-hero-title {
  font-size: clamp(1.8rem, 3.5vw, 2.8rem);
  font-weight: 800;
  color: var(--white);
  letter-spacing: -0.025em;
  margin-bottom: 10px;
}
.book-hero-sub {
  font-size: 1rem;
  color: rgba(255,255,255,0.5);
  font-weight: 400;
}

/* ---------- Main Layout ---------- */
.book-main {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 0;
  max-width: 1160px;
  margin: 0 auto;
  padding: 40px 4%;
  align-items: start;
}

.book-container { min-width: 0; }

/* ---------- Progress Bar ---------- */
.progress-bar {
  display: flex;
  align-items: center;
  margin-bottom: 36px;
  padding: 24px 28px;
  background: var(--white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

.progress-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.step-dot {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--gray-100);
  color: var(--gray-400);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  font-weight: 700;
  border: 2px solid var(--gray-200);
  transition: all 0.3s ease;
}

.progress-step span {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--gray-400);
  transition: color 0.3s ease;
  white-space: nowrap;
}

.progress-step.active .step-dot {
  background: var(--navy);
  color: var(--white);
  border-color: var(--navy);
  box-shadow: 0 4px 16px rgba(27,46,82,0.3);
}
.progress-step.active span { color: var(--navy); }

.progress-step.done .step-dot {
  background: var(--teal);
  color: var(--white);
  border-color: var(--teal);
}
.progress-step.done span { color: var(--teal); }

.progress-line {
  flex: 1;
  height: 2px;
  background: var(--gray-200);
  margin: 0 8px;
  margin-bottom: 24px;
  border-radius: 2px;
  transition: background 0.3s ease;
}
.progress-line.done { background: var(--teal); }

/* ---------- Step Panels ---------- */
.steps-wrapper { position: relative; }

.step-panel {
  display: none;
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 40px 36px;
  box-shadow: var(--shadow-sm);
}
.step-panel.active { display: block; }

.step-header {
  margin-bottom: 32px;
}
.step-header h2 {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--navy-dark);
  letter-spacing: -0.02em;
  margin-bottom: 6px;
}
.step-header p {
  font-size: 0.9rem;
  color: var(--gray-600);
  font-weight: 400;
}

/* ---------- Form Fields ---------- */
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 32px;
}
.full-width { grid-column: 1 / -1; }

.field-group {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.field-group label {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--gray-800);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.req { color: var(--teal); }
.optional { color: var(--gray-400); font-weight: 400; text-transform: none; letter-spacing: 0; }

.field-group input,
.field-group textarea,
.field-group select {
  font-family: var(--font);
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--gray-800);
  background: var(--off-white);
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius);
  padding: 13px 16px;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  resize: vertical;
  width: 100%;
}
.field-group input:focus,
.field-group textarea:focus,
.field-group select:focus {
  border-color: var(--navy);
  background: var(--white);
  box-shadow: 0 0 0 3px rgba(39,64,111,0.08);
}
.field-group input.error,
.field-group textarea.error {
  border-color: #E53E3E;
  background: #FFF5F5;
}
.field-group input::placeholder,
.field-group textarea::placeholder { color: var(--gray-400); font-weight: 400; }

.field-error {
  font-size: 0.78rem;
  color: #C53030;
  font-weight: 600;
  min-height: 16px;
  display: block;
}

/* ---------- Service Category Select ---------- */
.service-select-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 12px;
  margin-bottom: 28px;
}

.svc-cat-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 22px 16px;
  background: var(--off-white);
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius);
  cursor: pointer;
  font-family: var(--font);
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--gray-600);
  text-align: center;
  transition: all 0.2s ease;
}
.svc-cat-btn i { font-size: 1.4rem; color: var(--teal); transition: color 0.2s ease; }
.svc-cat-btn:hover { border-color: var(--navy); color: var(--navy); background: var(--white); }
.svc-cat-btn:hover i { color: var(--navy); }
.svc-cat-btn.selected {
  background: var(--navy);
  border-color: var(--navy);
  color: var(--white);
  box-shadow: var(--shadow-navy);
}
.svc-cat-btn.selected i { color: var(--white); }

.subservice-panel {
  margin-bottom: 28px;
  padding: 24px;
  background: var(--off-white);
  border-radius: var(--radius);
  border: 1px solid var(--gray-200);
}
.subservice-label {
  display: block;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--gray-600);
  margin-bottom: 14px;
}
.subservice-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.sub-btn {
  display: block;
  width: 100%;
  padding: 12px 16px;
  background: var(--white);
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius);
  font-family: var(--font);
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--gray-800);
  text-align: left;
  cursor: pointer;
  transition: all 0.2s ease;
}
.sub-btn:hover { border-color: var(--navy); color: var(--navy); background: #f0f4f9; }
.sub-btn.selected {
  background: var(--navy);
  border-color: var(--navy);
  color: var(--white);
}

/* ---------- Calendar ---------- */
.datetime-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  margin-bottom: 32px;
}

.calendar-wrap {
  background: var(--off-white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  padding: 24px;
}

.cal-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}
.cal-nav-btn {
  width: 36px;
  height: 36px;
  border: none;
  background: var(--white);
  border-radius: 50%;
  cursor: pointer;
  color: var(--navy);
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-sm);
  transition: all 0.2s ease;
}
.cal-nav-btn:hover { background: var(--navy); color: var(--white); }
.cal-nav-btn:disabled { opacity: 0.3; cursor: not-allowed; }
.cal-nav-btn:disabled:hover { background: var(--white); color: var(--navy); }

.cal-month-label {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--navy-dark);
  letter-spacing: -0.01em;
}

.cal-days-header {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
  margin-bottom: 8px;
}
.cal-days-header span {
  text-align: center;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--gray-400);
  padding: 4px 0;
}

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

.cal-day {
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  border: none;
  background: transparent;
  color: var(--gray-800);
  font-family: var(--font);
  transition: all 0.15s ease;
}
.cal-day:hover:not(:disabled):not(.cal-empty) {
  background: var(--teal-pale);
  color: var(--navy);
}
.cal-day.selected {
  background: var(--navy);
  color: var(--white);
  box-shadow: 0 4px 12px rgba(27,46,82,0.3);
}
.cal-day.today {
  border: 2px solid var(--teal);
  color: var(--teal);
  font-weight: 800;
}
.cal-day.today.selected {
  border-color: var(--navy);
  color: var(--white);
}
.cal-day:disabled,
.cal-day.unavailable {
  opacity: 0.28;
  cursor: not-allowed;
  text-decoration: line-through;
}
.cal-day.by-appt {
  opacity: 0.5;
  cursor: not-allowed;
  color: var(--gray-400);
}
.cal-day.cal-empty {
  cursor: default;
  pointer-events: none;
}

/* ---------- Time Slots ---------- */
.time-wrap {
  background: var(--off-white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  padding: 24px;
  display: flex;
  flex-direction: column;
}

.time-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  flex: 1;
  gap: 14px;
  text-align: center;
  padding: 32px 0;
  color: var(--gray-400);
}
.time-placeholder i { font-size: 2rem; }
.time-placeholder p { font-size: 0.88rem; font-weight: 500; max-width: 200px; }

.time-slots-label {
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--gray-600);
  margin-bottom: 16px;
}
.time-slots-label span { color: var(--navy); }

.slots-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.slot-btn {
  padding: 11px 10px;
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius);
  background: var(--white);
  font-family: var(--font);
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--gray-800);
  cursor: pointer;
  transition: all 0.15s ease;
  text-align: center;
}
.slot-btn:hover:not(:disabled) { border-color: var(--navy); color: var(--navy); background: #f0f4f9; }
.slot-btn.selected { background: var(--navy); border-color: var(--navy); color: var(--white); }
.slot-btn:disabled { opacity: 0.35; cursor: not-allowed; }

/* ---------- Confirmation Card ---------- */
.confirm-card {
  background: var(--off-white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-bottom: 24px;
}
.confirm-row {
  display: flex;
  align-items: baseline;
  gap: 16px;
  padding: 16px 24px;
  border-bottom: 1px solid var(--gray-200);
}
.confirm-row:last-child { border-bottom: none; }
.confirm-label {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--gray-400);
  flex-shrink: 0;
  width: 70px;
}
.confirm-val {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--navy-dark);
}

.clinic-notice {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 18px 20px;
  background: rgba(84,144,172,0.1);
  border: 1px solid rgba(84,144,172,0.25);
  border-radius: var(--radius);
  margin-bottom: 32px;
}
.clinic-notice i { color: var(--teal); font-size: 1rem; margin-top: 3px; flex-shrink: 0; }
.clinic-notice p { font-size: 0.88rem; color: var(--gray-600); line-height: 1.6; font-weight: 400; }
.clinic-notice a { color: var(--navy); font-weight: 700; }

/* ---------- Success Screen ---------- */
.success-screen {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 20px 0;
  gap: 18px;
}
.success-icon {
  width: 80px;
  height: 80px;
  background: rgba(84,144,172,0.12);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.2rem;
  color: var(--teal);
  margin-bottom: 8px;
}
.success-screen h2 {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--navy-dark);
  letter-spacing: -0.02em;
}
.success-screen > p {
  font-size: 1rem;
  color: var(--gray-600);
  max-width: 460px;
  line-height: 1.7;
}
.success-details {
  background: var(--off-white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  padding: 16px 24px;
  width: 100%;
  max-width: 420px;
  font-size: 0.9rem;
  color: var(--gray-600);
  font-weight: 500;
  line-height: 1.8;
}
.success-note {
  font-size: 0.82rem;
  color: var(--gray-400);
}
.success-note a { color: var(--navy); font-weight: 700; }

/* ---------- Step Navigation ---------- */
.step-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 28px;
  border-top: 1px solid var(--gray-200);
  margin-top: 8px;
}

/* ---------- Sidebar ---------- */
.book-sidebar {
  padding-left: 28px;
  position: sticky;
  top: 96px;
}

.sidebar-card {
  background: var(--navy-deeper);
  border-radius: var(--radius-lg);
  padding: 28px 24px;
  text-align: center;
  margin-bottom: 16px;
}
.sidebar-logo {
  width: 56px;
  height: 56px;
  border-radius: 12px;
  object-fit: cover;
  margin: 0 auto 14px;
}
.sidebar-card h3 {
  font-size: 1rem;
  font-weight: 800;
  color: var(--white);
  letter-spacing: -0.01em;
  margin-bottom: 4px;
}
.sidebar-tagline {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.4);
  font-style: italic;
}

.sidebar-info {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  padding: 22px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.si-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 0.83rem;
  color: var(--gray-600);
  font-weight: 500;
}
.si-row i { color: var(--teal); margin-top: 2px; flex-shrink: 0; width: 14px; }
.si-row a { color: var(--navy); font-weight: 700; }
.si-hours { display: flex; flex-direction: column; gap: 3px; }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .book-main { grid-template-columns: 1fr; }
  .book-sidebar {
    padding-left: 0;
    position: static;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
  }
  .sidebar-card { margin-bottom: 0; }
}

@media (max-width: 720px) {
  .book-main { padding: 24px 4%; }
  .step-panel { padding: 28px 20px; }
  .form-grid { grid-template-columns: 1fr; }
  .datetime-grid { grid-template-columns: 1fr; }
  .service-select-grid { grid-template-columns: repeat(2, 1fr); }
  .progress-bar { padding: 18px 16px; gap: 0; }
  .progress-step span { display: none; }
  .book-sidebar { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
  .progress-step .step-dot { width: 32px; height: 32px; font-size: 0.75rem; }
  .service-select-grid { grid-template-columns: 1fr; }
  .slots-grid { grid-template-columns: repeat(3, 1fr); }
  .step-nav { flex-direction: column-reverse; gap: 12px; }
  .step-nav .btn { width: 100%; }
}
