/* ============================================================
   SHANIEL BESPOKE TAILOR — APPOINTMENT / BOOKING PAGE CSS
   ============================================================ */

/* Reset p margin so it doesn't break grid layout */
.appt-page p,
.sh-cal-wrap p,
.sh-sel-panel p,
.appt-form-box p,
.meet-card p { margin-bottom: 0; }

/* ── PAGE LAYOUT ─────────────────────────────────────────── */
.appt-page { background: var(--bg-light); padding: 40px 0 80px; }
.appt-grid {
  display: grid;
  grid-template-columns: 1fr 420px;
  gap: 28px;
  align-items: start;
}

/* ── CALENDAR WRAPPER ────────────────────────────────────── */
.sh-cal-wrap {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

/* ── TOOLBAR ─────────────────────────────────────────────── */
.sh-cal-toolbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border-light);
  background: var(--bg-white);
  gap: 10px; flex-wrap: wrap;
}
.sh-cal-toolbar-left { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.sh-cal-title {
  font-family: var(--font-serif);
  font-size: 1.25rem; font-weight: 600; color: var(--text-dark);
  letter-spacing: 0.03em;
}
.sh-cal-btn {
  height: 32px; min-width: 32px; padding: 0 12px;
  border: 1.5px solid var(--border); background: var(--bg-white);
  border-radius: var(--radius); cursor: pointer;
  font-size: 0.78rem; font-weight: 600; color: var(--primary);
  font-family: var(--font-sans);
  transition: var(--transition); display: flex; align-items: center; justify-content: center;
}
.sh-cal-btn:hover { background: var(--primary); color: #fff; border-color: var(--primary); }
.sh-cal-btn.today-btn {
  background: var(--primary); color: #fff; border-color: var(--primary);
  font-weight: 700; letter-spacing: 0.06em; font-size: 0.72rem;
}
.sh-cal-btn.today-btn:hover { background: var(--primary-dark); border-color: var(--primary-dark); }
.sh-cal-nav { display: flex; gap: 3px; }

/* ── YEAR BUTTONS ────────────────────────────────────────── */
.sh-cal-years { display: flex; gap: 4px; flex-wrap: wrap; }
.sh-yr-btn {
  padding: 4px 11px; border: 1.5px solid var(--border);
  background: var(--bg-white); border-radius: 20px; cursor: pointer;
  font-size: 0.7rem; font-weight: 600; color: var(--text-muted);
  font-family: var(--font-sans); transition: var(--transition);
}
.sh-yr-btn:hover { border-color: var(--primary); color: var(--primary); background: var(--primary-pale); }
.sh-yr-btn.active { background: var(--text-dark); color: #fff; border-color: var(--text-dark); }

/* ── MONTH TABS ──────────────────────────────────────────── */
.sh-cal-months {
  display: grid; grid-template-columns: repeat(12, 1fr);
  border-bottom: 1px solid var(--border-light);
  background: var(--bg-cream);
}
.sh-mon-tab {
  padding: 8px 2px; text-align: center;
  font-family: var(--font-sans);
  font-size: 0.6rem; font-weight: 700;
  letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--text-muted); cursor: pointer;
  transition: var(--transition); border-bottom: 2px solid transparent;
}
.sh-mon-tab:hover { color: var(--primary); background: var(--primary-pale); }
.sh-mon-tab.active {
  color: var(--primary); border-bottom-color: var(--primary);
  background: var(--bg-white); font-weight: 700;
}

/* ── DAY HEADER ──────────────────────────────────────────── */
.sh-cal-day-header {
  display: grid; grid-template-columns: repeat(7, 1fr);
  background: var(--text-dark);
}
.sh-dh-cell {
  padding: 9px 0; text-align: center;
  font-family: var(--font-sans);
  font-size: 0.65rem; font-weight: 700;
  letter-spacing: 0.1em; text-transform: uppercase;
  color: rgba(255,255,255,0.8);
  border-right: 1px solid rgba(255,255,255,0.05);
}
.sh-dh-cell:last-child { border-right: none; }
.sh-dh-cell.weekend { color: var(--primary-light); }

/* ── CALENDAR GRID ───────────────────────────────────────── */
.sh-cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
}
.sh-cal-cell {
  min-height: 88px;
  border-right: 1px solid var(--border-light);
  border-bottom: 1px solid var(--border-light);
  padding: 6px 7px 5px;
  position: relative;
  cursor: default;
  background: var(--bg-white);
  transition: var(--transition);
}
.sh-cal-cell:nth-child(7n) { border-right: none; }
.sh-cal-cell.other-month { background: var(--bg-light); }
.sh-cal-cell.other-month .sh-date-num { color: #ccc; }
.sh-cal-cell.past-day { background: var(--bg-light); }
.sh-cal-cell.past-day .sh-date-num { color: #bfd0de; }
.sh-cal-cell.avail { cursor: pointer; }
.sh-cal-cell.avail:hover { background: var(--primary-pale); }
.sh-cal-cell.avail:hover .sh-date-num { color: var(--primary); }
.sh-cal-cell.blocked-day { background: #fff9f9; }
.sh-cal-cell.blocked-day .sh-date-num { color: #d0a8a8; }
.sh-cal-cell.today-cell { background: var(--primary-pale); }
.sh-cal-cell.today-cell .sh-date-num {
  background: var(--primary); color: #fff;
  width: 26px; height: 26px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 0.78rem;
}
.sh-cal-cell.selected-cell { background: #dbeeff !important; outline: 2px solid var(--primary); outline-offset: -2px; }
.sh-cal-cell.selected-cell .sh-date-num {
  background: var(--primary) !important; color: #fff !important;
  width: 26px; height: 26px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 0.78rem;
}

/* ── DATE NUMBER ─────────────────────────────────────────── */
.sh-date-num {
  font-family: var(--font-sans);
  font-size: 0.78rem; font-weight: 600;
  color: var(--text-body); margin-bottom: 4px; line-height: 1;
}

/* ── EVENT LABELS ────────────────────────────────────────── */
.sh-event {
  display: flex; align-items: center; gap: 4px;
  background: var(--primary-dark); color: #fff;
  border-radius: var(--radius); padding: 3px 6px;
  font-size: 0.62rem; font-weight: 600;
  font-family: var(--font-sans);
  margin-bottom: 2px; cursor: pointer;
  transition: var(--transition);
  white-space: nowrap; overflow: hidden;
  text-overflow: ellipsis; max-width: 100%;
}
.sh-event:hover { background: var(--primary); }
.sh-event-dot { width: 5px; height: 5px; border-radius: 50%; flex-shrink: 0; background: var(--primary-light); }
.sh-event.blocked-ev { background: #7f1d1d; }
.sh-event.blocked-ev .sh-event-dot { background: #f87171; }

/* ── TODAY BADGE ─────────────────────────────────────────── */
.sh-today-badge {
  position: absolute; top: 5px; right: 6px;
  font-size: 0.5rem; font-weight: 700; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--primary);
  font-family: var(--font-sans);
  background: #dbeeff; padding: 1px 5px; border-radius: 8px;
}

/* ── CALENDAR FOOTER LEGEND ──────────────────────────────── */
.sh-cal-footer {
  padding: 10px 18px;
  border-top: 1px solid var(--border-light);
  background: var(--bg-cream);
  display: flex; align-items: center; gap: 16px; flex-wrap: wrap;
}
.sh-leg-item {
  display: flex; align-items: center; gap: 5px;
  font-family: var(--font-sans); font-size: 0.68rem; color: var(--text-muted);
}
.sh-leg-dot { width: 9px; height: 9px; border-radius: var(--radius); flex-shrink: 0; }

/* ── TIME SLOT PANEL ─────────────────────────────────────── */
.sh-sel-panel {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 18px 20px;
  margin-top: 14px;
  display: none;
  box-shadow: var(--shadow-sm);
}
.sh-sel-panel.show { display: block; }
.sh-sel-date {
  font-family: var(--font-serif);
  font-size: 1.15rem; color: var(--text-dark);
  margin-bottom: 4px; font-weight: 600;
}
.sh-slot-grid {
  display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px;
}
.sh-slot {
  padding: 8px 4px;
  background: var(--primary-pale);
  border: 1.5px solid var(--border);
  border-radius: var(--radius); text-align: center;
  font-family: var(--font-sans); font-size: 0.72rem; font-weight: 600;
  color: var(--primary); cursor: pointer; transition: var(--transition);
}
.sh-slot:hover { background: var(--primary); color: #fff; border-color: var(--primary); }
.sh-slot.sel {
  background: var(--primary); color: #fff;
  border-color: var(--primary-dark); font-weight: 700;
  box-shadow: var(--shadow-md);
}
.sh-slot.full {
  background: #f8f8f8; color: #ccc;
  border-color: #eee; cursor: not-allowed;
  text-decoration: line-through;
}

/* ── HOW TO MEET US ──────────────────────────────────────── */
.meet-us-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 10px;
  margin-top: 14px;
}
.meet-card {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 14px;
  background: var(--bg-cream);
  transition: var(--transition);
}
.meet-card:hover { border-color: var(--primary); box-shadow: var(--shadow-sm); }
.meet-card-icon { font-size: 1.5rem; margin-bottom: 6px; }
.meet-card strong { font-size: 0.82rem; color: var(--text-dark); display: block; margin-bottom: 3px; }
.meet-card p { font-size: 0.72rem; color: var(--text-muted); margin: 0; line-height: 1.5; }

/* ── CONTACT STRIP ───────────────────────────────────────── */
.appt-contact-strip {
  background: linear-gradient(135deg, var(--text-dark), var(--primary));
  border-radius: var(--radius-lg); padding: 16px 20px;
  color: #fff; margin-top: 14px;
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px;
}
.appt-contact-strip a { color: var(--primary-light); font-weight: 600; font-size: 0.88rem; }
.appt-contact-strip a:hover { color: #fff; }

/* ── BOOKING FORM BOX ────────────────────────────────────── */
.appt-form-box {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-md);
  overflow: hidden;
}
.appt-form-head {
  background: linear-gradient(135deg, var(--text-dark), var(--primary-dark));
  padding: 22px 24px; text-align: center;
}
.appt-form-head h2 {
  font-family: var(--font-serif);
  color: #fff; font-size: 1.5rem; font-weight: 400;
  letter-spacing: 0.12em; margin-bottom: 4px;
}
.appt-form-head p { color: rgba(255,255,255,0.55); font-size: 0.75rem; margin: 0; }
.appt-form-body { padding: 22px 22px 18px; }

/* ── SELECTED DATE INFO BOX ──────────────────────────────── */
.selected-info {
  background: var(--primary-pale);
  border: 1.5px solid var(--primary);
  border-radius: var(--radius-lg); padding: 11px 14px;
  margin-bottom: 16px; font-size: 0.83rem;
  font-family: var(--font-sans);
}

/* ── FORM FIELDS ─────────────────────────────────────────── */
.appt-form-body .form-group { margin-bottom: 14px; }
.appt-form-body .form-group label {
  font-size: 0.65rem; font-weight: 700;
  letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--primary-dark); display: block; margin-bottom: 5px;
}
.appt-form-body .form-group p { margin: 0; }
.appt-form-body .form-group input,
.appt-form-body .form-group select,
.appt-form-body .form-group textarea {
  width: 100%; padding: 10px 12px;
  border: 1.5px solid var(--border); border-radius: var(--radius-lg);
  font-family: var(--font-sans); font-size: 0.85rem;
  color: var(--text-dark); background: var(--bg-white); outline: none;
  transition: var(--transition);
  box-sizing: border-box;
}
.appt-form-body .form-group input:focus,
.appt-form-body .form-group select:focus,
.appt-form-body .form-group textarea:focus {
  border-color: var(--primary); box-shadow: 0 0 0 3px rgba(37,99,168,0.1);
}
.appt-form-body .form-group textarea { min-height: 65px; resize: vertical; }

/* ── SUBMIT BUTTON ───────────────────────────────────────── */
.appt-submit-btn {
  width: 100%; padding: 14px;
  background: linear-gradient(135deg, var(--primary-dark), var(--primary));
  color: #fff; border: none;
  font-family: var(--font-sans);
  font-size: 0.78rem; font-weight: 700;
  letter-spacing: 0.12em; text-transform: uppercase;
  border-radius: var(--radius-lg); cursor: pointer;
  transition: var(--transition);
  box-shadow: var(--shadow-md);
}
.appt-submit-btn:hover {
  background: linear-gradient(135deg, var(--text-dark), var(--primary-dark));
  box-shadow: var(--shadow-lg);
  transform: translateY(-1px);
}
.appt-submit-btn:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }
.appt-secure-note {
  text-align: center; margin-top: 8px;
  font-size: 0.7rem; color: var(--text-muted);
  font-family: var(--font-sans);
}

/* ── RESPONSIVE ──────────────────────────────────────────── */
@media (max-width: 1100px) {
  .sh-cal-months { grid-template-columns: repeat(6, 1fr); }
}
@media (max-width: 960px) {
  .appt-grid { grid-template-columns: 1fr !important; }
  .appt-form-box { position: static !important; }
  .sh-slot-grid { grid-template-columns: repeat(4, 1fr); }
}
@media (max-width: 700px) {
  .sh-cal-cell { min-height: 66px; padding: 5px; }
  .sh-event { font-size: 0.58rem; padding: 2px 4px; }
  .sh-slot-grid { grid-template-columns: repeat(3, 1fr); }
  .sh-cal-months { grid-template-columns: repeat(4, 1fr); }
  .sh-cal-title { font-size: 1rem; }
  .meet-us-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 480px) {
  .sh-cal-cell { min-height: 50px; }
  .sh-event span { display: none; }
  .sh-slot-grid { grid-template-columns: repeat(3, 1fr); }
  .sh-cal-months { grid-template-columns: repeat(3, 1fr); }
  .appt-contact-strip { flex-direction: column; text-align: center; }
}
