/* ===== DESIGN TOKENS ===== */
/* Palette: Danube #5992c6 · Torea Bay #0a2a92 · Cocoa Brown #31241f · Shilo #e9b8c9 */
:root {
  --bg:             #f0f4fb;
  --surface:        #ffffff;
  --surface-2:      #eaeff8;
  --border:         #cfdaee;
  --border-strong:  #b0c4e0;
  --text:           #31241f;   /* Cocoa Brown */
  --text-2:         #4a3830;
  --muted:          #7a6a65;
  --primary:        #5992c6;   /* Danube */
  --primary-h:      #0a2a92;   /* Torea Bay */
  --primary-light:  #c5dcf0;
  --primary-xlight: #eaf3fb;
  --accent:         #e9b8c9;   /* Shilo */
  --accent-dark:    #b5607e;
  --danger:         #c0392b;
  --danger-light:   #fdf0ef;
  --success:        #2d7a4f;
  --completed:      #9aabbf;
  --radius:         12px;
  --radius-sm:      8px;
  --radius-xs:      6px;
  --shadow-xs:      0 1px 2px rgba(10,42,146,0.05);
  --shadow-sm:      0 1px 3px rgba(10,42,146,0.07), 0 1px 2px rgba(10,42,146,0.04);
  --shadow:         0 4px 6px -1px rgba(10,42,146,0.07), 0 2px 4px -1px rgba(10,42,146,0.04);
  --shadow-lg:      0 10px 25px -3px rgba(10,42,146,0.09), 0 4px 6px -2px rgba(10,42,146,0.05);
  --shadow-xl:      0 20px 40px -5px rgba(10,42,146,0.13), 0 8px 16px -4px rgba(10,42,146,0.07);
}

/* ===== RESET & BASE ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* ===== TOP NAV ===== */
.topbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255,255,255,0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow-xs);
}

.topbar-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.topbar-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
}

.brand-name {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.01em;
}

.topbar-nav {
  display: flex;
  align-items: center;
  gap: 4px;
}

.nav-link {
  padding: 6px 14px;
  border-radius: var(--radius-xs);
  font-size: 14px;
  font-weight: 500;
  color: var(--muted);
  text-decoration: none;
  transition: all 0.15s;
}
.nav-link:hover { color: var(--text); background: var(--surface-2); }
.nav-link-active { color: var(--primary) !important; background: var(--primary-xlight) !important; font-weight: 600; }

.topbar-actions { display: flex; align-items: center; gap: 10px; }

.role-badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-top: 0;
}
.role-admin       { background: var(--primary-h); color: #fff; }
.role-coordinator { background: var(--primary-xlight); color: var(--primary-h); }
.role-viec        { background: #fdf0f5; color: var(--accent-dark); }
.role-other       { background: var(--primary-xlight); color: var(--primary-h); }

.user-menu {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 5px 14px 5px 10px;
}

.user-display-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  max-width: 140px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.user-menu-divider {
  width: 1px;
  height: 14px;
  background: var(--border-strong);
}

.user-signout-btn {
  background: none;
  border: none;
  font-family: 'Inter', sans-serif;
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  padding: 0;
  transition: color 0.15s;
}
.user-signout-btn:hover { color: var(--danger); }

.signed-in-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 500;
  color: var(--success);
  background: var(--primary-xlight);
  padding: 4px 12px;
  border-radius: 20px;
}
.dot-green {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--primary);
  box-shadow: 0 0 0 2px rgba(89,146,198,0.3);
}

/* ===== BOOKING CONFIRMATION MODAL ===== */
.confirm-modal {
  background: var(--surface);
  border-radius: 16px;
  box-shadow: var(--shadow-xl);
  width: 100%;
  max-width: 460px;
  overflow: hidden;
  animation: modal-in 0.22s cubic-bezier(0.34, 1.4, 0.64, 1);
}

.confirm-header {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 22px 24px 18px;
  background: linear-gradient(135deg, #ecfdf5 0%, #f0fdf4 100%);
  border-bottom: 1px solid #d1fae5;
}

.confirm-check { flex-shrink: 0; }

.confirm-title {
  font-size: 17px;
  font-weight: 700;
  color: #065f46;
  margin-bottom: 3px;
  letter-spacing: -0.02em;
}

.confirm-subtitle {
  font-size: 12px;
  color: #047857;
  font-weight: 500;
}

.confirm-body {
  padding: 20px 24px;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.confirm-row {
  display: flex;
  align-items: baseline;
  gap: 12px;
  padding: 9px 0;
  border-bottom: 1px solid var(--border);
}
.confirm-row:last-of-type { border-bottom: none; }

.confirm-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  min-width: 90px;
  flex-shrink: 0;
}

.confirm-value {
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
}

/* Meet link section */
.confirm-meet {
  margin-top: 16px;
  background: var(--primary-xlight);
  border: 1.5px solid var(--primary-light);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
}

.confirm-meet-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--primary-h);
  margin-bottom: 8px;
}

.confirm-meet-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

.conf-meet-url {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--primary-h);
  text-decoration: none;
  word-break: break-all;
  flex: 1;
}
.conf-meet-url:hover { text-decoration: underline; }

.copy-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 12px;
  border: 1.5px solid var(--primary);
  border-radius: var(--radius-xs);
  background: var(--surface);
  color: var(--primary);
  font-family: 'Inter', sans-serif;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.15s;
  flex-shrink: 0;
}
.copy-btn:hover { background: var(--primary); color: #fff; }

.confirm-meet-hint {
  font-size: 11px;
  color: var(--muted);
  margin: 0;
}

.confirm-footer {
  padding: 14px 24px;
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  border-top: 1px solid var(--border);
  background: var(--surface-2);
}

/* ===== ERROR BANNER ===== */
.error-banner {
  position: fixed;
  top: 60px; /* below topbar */
  left: 0; right: 0;
  z-index: 9999;
  padding: 0 16px;
  animation: slideDown 0.2s ease;
}

@keyframes slideDown {
  from { opacity: 0; transform: translateY(-8px); }
  to   { opacity: 1; transform: translateY(0); }
}

.error-banner-inner {
  max-width: 800px;
  margin: 8px auto 0;
  background: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: var(--radius-xs);
  padding: 10px 16px;
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--danger);
  font-size: 13px;
  font-weight: 500;
  box-shadow: var(--shadow-sm);
}

.error-banner-inner strong { font-weight: 700; }

.error-banner-close {
  background: none;
  border: none;
  color: var(--danger);
  cursor: pointer;
  font-size: 14px;
  margin-left: auto;
  padding: 0 4px;
  opacity: 0.7;
}
.error-banner-close:hover { opacity: 1; }

/* ===== SIGN-IN BANNER ===== */
.sign-in-banner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  background: #fff7ed;
  border-bottom: 1px solid #fed7aa;
  padding: 12px 24px;
  font-size: 13px;
  font-weight: 500;
  color: #92400e;
}

/* ===== SIGN-IN PAGE ===== */
.sign-in-page {
  min-height: calc(100vh - 60px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
}

.sign-in-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  padding: 48px 40px;
  text-align: center;
  max-width: 380px;
  width: 100%;
}

.sign-in-title {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 8px;
}

.sign-in-sub {
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 24px;
  line-height: 1.6;
}

/* ===== BOOKING PAGE ===== */
.booking-page {
  max-width: 1100px;
  margin: 0 auto;
  padding: 32px 24px 60px;
}

.booking-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 28px;
  gap: 16px;
  flex-wrap: wrap;
}

.booking-title {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.tz-label {
  font-size: 12px;
  color: var(--muted);
  font-weight: 500;
}

/* ===== SLOT PICKER SHELL ===== */
.picker-shell {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  display: flex;
  align-items: flex-start;
  min-height: 480px;
  overflow: hidden;
}

/* ===== MINI CALENDAR ===== */
.left-panel {
  width: 220px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  border-right: 1px solid var(--border);
  overflow: hidden;
}

.mini-cal {
  padding: 20px 16px 12px;
  flex-shrink: 0;
}

.mini-cal-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.mini-cal-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
}

.mini-nav-btn {
  background: none;
  border: none;
  font-size: 20px;
  color: var(--muted);
  cursor: pointer;
  padding: 2px 6px;
  border-radius: var(--radius-xs);
  line-height: 1;
  transition: all 0.15s;
}
.mini-nav-btn:hover { background: var(--surface-2); color: var(--text); }

.mini-cal-dow {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  margin-bottom: 6px;
}
.mini-cal-dow span {
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
  text-align: center;
  padding: 4px 0;
}

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

.mini-day {
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 500;
  border-radius: 50%;
  cursor: default;
}

.mini-day-today  { background: var(--primary); color: #fff; font-weight: 700; }

/* ===== UPCOMING PANEL ===== */
.upcoming-panel {
  border-top: 1px solid var(--border);
  padding: 12px 14px;
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.upcoming-panel-title {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--muted);
  margin-bottom: 8px;
}

.upcoming-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
  overflow-y: auto;
  flex: 1;
}

.upcoming-item {
  padding: 6px 8px;
  border-radius: var(--radius-xs);
  background: var(--surface-2);
  border-left: 3px solid var(--primary);
  transition: background 0.12s;
}
.upcoming-item:hover { background: var(--primary-xlight); }

.upcoming-today {
  border-left-color: var(--accent-dark);
  background: #fdf0f5;
}
.upcoming-today:hover { background: #fce4ee; }

.upcoming-past {
  opacity: 0.55;
  border-left-color: var(--completed);
}

.upcoming-date {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 10.5px;
  font-weight: 600;
  color: var(--primary-h);
  margin-bottom: 2px;
}

.upcoming-today .upcoming-date { color: var(--accent-dark); }

.upcoming-today-badge {
  font-size: 9px;
  font-weight: 700;
  background: var(--accent-dark);
  color: #fff;
  padding: 1px 5px;
  border-radius: 10px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.upcoming-name-row {
  display: flex;
  align-items: center;
  gap: 4px;
  min-width: 0;
}
.upcoming-name {
  font-size: 11.5px;
  font-weight: 500;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex: 1;
  min-width: 0;
}
.upcoming-type-icon {
  font-size: 11px;
  flex-shrink: 0;
  line-height: 1;
  opacity: 0.85;
}

.upcoming-item-clickable {
  cursor: pointer;
}
.upcoming-item-clickable:hover {
  background: var(--primary-xlight);
  border-left-color: var(--primary-h);
}

/* ===== SESSION DETAIL POPUP ===== */
.session-popup {
  background: var(--surface);
  border-radius: 14px;
  box-shadow: var(--shadow-xl);
  width: 100%;
  max-width: 400px;
  overflow: hidden;
  animation: modal-in 0.2s cubic-bezier(0.34,1.4,0.64,1);
}

.session-popup-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 20px 20px 16px;
  border-bottom: 1px solid var(--border);
  gap: 12px;
  background: var(--primary-xlight);
}

.session-popup-name {
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 4px;
  letter-spacing: -0.01em;
}

.session-popup-time {
  font-size: 12px;
  font-weight: 600;
  color: var(--primary-h);
}

.session-popup-body {
  padding: 16px 20px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.sp-row {
  display: flex;
  align-items: baseline;
  gap: 12px;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
}
.sp-row:last-of-type { border-bottom: none; }

.sp-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  min-width: 80px;
  flex-shrink: 0;
}

.sp-value {
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
  word-break: break-all;
}

.sp-meet {
  margin-top: 14px;
  background: var(--primary-xlight);
  border: 1.5px solid var(--primary-light);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
}

.sp-meet-label {
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--primary-h);
  margin-bottom: 8px;
}

.sp-meet-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.sp-meet-url {
  font-size: 12px;
  font-weight: 600;
  color: var(--primary-h);
  text-decoration: none;
  word-break: break-all;
  flex: 1;
}
.sp-meet-url:hover { text-decoration: underline; }

.sp-no-meet { margin-top: 14px; text-align: center; padding: 10px 0; }

.session-popup-footer {
  padding: 12px 20px;
  display: flex;
  justify-content: flex-end;
  border-top: 1px solid var(--border);
  background: var(--surface-2);
}

.upcoming-empty {
  font-size: 12px;
  color: var(--muted);
  text-align: center;
  padding: 12px 0;
}
.mini-day-past   { color: #cbd5e1; }
.mini-day-future { color: var(--text); cursor: pointer; transition: all 0.12s; }
.mini-day-future:hover { background: var(--primary-xlight); color: var(--primary); }

/* ===== PICKER DIVIDER ===== */
.picker-divider {
  width: 1px;
  background: var(--border);
  align-self: stretch;
  flex-shrink: 0;
}

/* ===== WEEK VIEW ===== */
.week-view {
  flex: 1;
  padding: 24px 12px 24px 0;
  min-width: 0;
}

.week-nav-row {
  display: flex;
  align-items: flex-start;
  gap: 4px;
}

.week-nav-btn {
  background: none;
  border: 1px solid var(--border);
  border-radius: var(--radius-xs);
  font-size: 22px;
  color: var(--muted);
  cursor: pointer;
  padding: 4px 10px;
  margin-top: 36px;
  line-height: 1;
  transition: all 0.15s;
  flex-shrink: 0;
}
.week-nav-btn:hover:not(:disabled) { background: var(--surface-2); color: var(--text); }
.week-nav-btn:disabled { opacity: 0.3; cursor: not-allowed; }

.day-cols {
  flex: 1;
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 6px;
  min-width: 0;
}

.day-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.day-col-hdr {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  margin-bottom: 4px;
}

.day-col-name {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--muted);
  text-transform: uppercase;
}

.day-col-num {
  font-size: 20px;
  font-weight: 600;
  color: var(--text);
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
}

.day-num-today { background: var(--primary); color: #fff; }

/* ===== TIME SLOT PILLS ===== */
.slot-list {
  display: flex;
  flex-direction: column;
  gap: 7px;
  width: 100%;
  align-items: center;
}

.slot-pill-btn {
  width: 90%;
  padding: 8px 6px;
  border: 1.5px solid var(--primary);
  border-radius: 999px;
  background: transparent;
  color: var(--primary);
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
  white-space: nowrap;
}
.slot-pill-btn:hover {
  background: var(--primary);
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 3px 8px rgba(5,150,105,0.25);
}

.slot-pill-view {
  opacity: 0.45;
  cursor: default !important;
  border-style: dashed;
}

.view-only-notice {
  display: inline-block;
  margin-top: 8px;
  font-size: 12px;
  font-weight: 500;
  color: #92400e;
  background: #fff7ed;
  border: 1px solid #fed7aa;
  border-radius: var(--radius-xs);
  padding: 5px 12px;
}

.slot-dash {
  font-size: 18px;
  color: #cbd5e1;
  display: block;
  text-align: center;
  margin-top: 8px;
}

.slot-holiday {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  color: var(--accent-dark);
  background: #fdf0f5;
  border: 1px solid var(--accent);
  border-radius: 20px;
  padding: 4px 10px;
  margin-top: 8px;
  text-align: center;
}

/* ===== LOADING SPINNER ===== */
.slots-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 48px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 500;
}

.spinner {
  width: 18px; height: 18px;
  border: 2px solid var(--border);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* ===== CALENDAR PAGE LAYOUT ===== */
.cal-page {
  max-width: 1200px;
  margin: 0 auto;
  padding: 28px 24px 60px;
}

.cal-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 20px;
  gap: 16px;
}

.cal-title {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--text);
  margin-bottom: 4px;
}

.cal-subtitle {
  font-size: 13px;
  color: var(--muted);
}

.cal-legend {
  display: flex;
  gap: 16px;
  flex-shrink: 0;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
}

.legend-dot {
  width: 10px; height: 10px;
  border-radius: 3px;
}
.legend-upcoming  { background: var(--primary); }
.legend-completed { background: var(--completed); }

.cal-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 24px;
  overflow: hidden;
}

/* ===== FULLCALENDAR OVERRIDES ===== */

/* Toolbar / buttons */
.fc .fc-toolbar { margin-bottom: 20px; }
.fc .fc-toolbar-title {
  font-family: 'Inter', sans-serif;
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
}

.fc .fc-button {
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  font-weight: 600;
  padding: 7px 14px;
  border-radius: var(--radius-xs);
  transition: all 0.15s;
  outline: none !important;
  box-shadow: none !important;
}

.fc .fc-button-primary {
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text-2);
}
.fc .fc-button-primary:hover {
  background: var(--surface-2);
  border-color: var(--border-strong);
  color: var(--text);
}
.fc .fc-button-primary:not(:disabled).fc-button-active,
.fc .fc-button-primary:not(:disabled):active {
  background: var(--primary-xlight);
  border-color: var(--primary-light);
  color: var(--primary);
}
.fc .fc-button-primary:focus { box-shadow: none !important; }

.fc .fc-today-button {
  background: var(--primary) !important;
  border-color: var(--primary) !important;
  color: white !important;
}
.fc .fc-today-button:hover {
  background: var(--primary-h) !important;
  border-color: var(--primary-h) !important;
}

/* Column headers */
.fc .fc-col-header-cell {
  font-family: 'Inter', sans-serif;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  background: var(--surface);
  padding: 10px 0;
  border-color: var(--border) !important;
}
.fc .fc-col-header-cell a { color: inherit; text-decoration: none; }
.fc .fc-col-header-cell.fc-day-today { color: var(--primary); }

/* Time slots */
.fc .fc-timegrid-slot {
  font-family: 'Inter', sans-serif;
  font-size: 11px;
  color: var(--muted);
  height: 44px;
  border-color: var(--border) !important;
}
.fc .fc-timegrid-slot-minor { border-color: transparent !important; }

/* Today column highlight */
.fc .fc-day-today { background: var(--primary-xlight) !important; }

/* Selection highlight */
.fc .fc-highlight {
  background: rgba(5,150,105,0.1) !important;
  border-radius: 6px;
}

/* Now indicator */
.fc .fc-timegrid-now-indicator-line { border-color: var(--danger); }
.fc .fc-timegrid-now-indicator-arrow {
  border-top-color: var(--danger);
  border-bottom-color: var(--danger);
}

/* Grid borders */
.fc .fc-scrollgrid { border-color: var(--border) !important; border-radius: var(--radius-sm); }
.fc td, .fc th { border-color: var(--border) !important; }

/* Events */
.fc-event {
  border: none !important;
  border-radius: 6px !important;
  cursor: pointer;
  box-shadow: 0 1px 3px rgba(0,0,0,0.12);
  background: var(--primary) !important;
  transition: filter 0.15s, transform 0.1s;
}
.fc-event:hover { filter: brightness(1.08); transform: translateY(-1px); }

.fc-event-inner {
  padding: 4px 8px;
  height: 100%;
}

.fc-event-name {
  font-family: 'Inter', sans-serif;
  font-size: 12px;
  font-weight: 600;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.4;
}

.fc-event-meta {
  font-family: 'Inter', sans-serif;
  font-size: 11px;
  color: rgba(255,255,255,0.8);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.3;
}

.fc-event-done {
  opacity: 0.6;
}

/* Month view events */
.fc-daygrid-event {
  border-radius: 4px !important;
  font-family: 'Inter', sans-serif;
  font-size: 12px;
  font-weight: 600;
}

/* ===== MODAL ===== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 42, 146, 0.38);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 16px;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

.modal {
  background: var(--surface);
  border-radius: 16px;
  box-shadow: 0 24px 60px rgba(10,42,146,0.18), 0 4px 16px rgba(0,0,0,0.08);
  width: 100%;
  max-width: 700px;
  height: 88vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: modal-in 0.22s cubic-bezier(0.34, 1.4, 0.64, 1);
}

.modal form {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
}

.modal-scroll {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
}

@keyframes modal-in {
  from { opacity: 0; transform: scale(0.96) translateY(14px); }
  to   { opacity: 1; transform: scale(1)    translateY(0);    }
}

.modal-accent {
  height: 5px;
  flex-shrink: 0;
  background: linear-gradient(90deg, var(--primary-h) 0%, var(--primary) 55%, var(--accent) 100%);
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 22px 15px;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
  flex-shrink: 0;
  gap: 12px;
}

.modal-title   { font-size: 16px; font-weight: 700; letter-spacing: -0.02em; color: var(--text); margin-bottom: 2px; }
.modal-subtitle { font-size: 12px; font-weight: 600; color: var(--primary); }

.modal-header-right {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.modal-close {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-xs);
  width: 30px; height: 30px;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  color: var(--muted);
  transition: all 0.15s;
}
.modal-close:hover { background: #fee; border-color: #fca5a5; color: var(--danger); }

.modal-body { padding: 18px 22px 14px; display: flex; flex-direction: column; gap: 12px; }

.slot-info {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding-top: 2px;
}

.slot-badge {
  display: inline-flex;
  align-items: center;
  padding: 5px 10px;
  border-radius: var(--radius-xs);
  font-size: 12px;
  font-weight: 600;
  width: fit-content;
}

.slot-session {
  background: var(--primary-xlight);
  color: var(--primary);
  border: 1px solid var(--primary-light);
}

.slot-gap {
  background: #fff7ed;
  color: #92400e;
  border: 1px solid #fed7aa;
}

/* ===== QUALIFICATION CHECKLIST ===== */
.checklist-required {
  font-size: 11px;
  font-weight: 500;
  color: var(--muted);
  margin-left: 8px;
}

.checklist-error {
  font-size: 12px;
  color: var(--danger);
  margin-top: 4px;
  font-weight: 500;
}

/* ===== QUALIFICATION TABLE ===== */
.qual-table-wrap {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.qual-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12.5px;
}

.qual-table thead th {
  background: var(--primary-h);
  color: #fff;
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 8px 12px;
  text-align: left;
  border-right: 1px solid rgba(255,255,255,0.12);
}
.qual-table thead th:last-child { border-right: none; }

.qual-table tbody tr {
  border-bottom: 1px solid var(--border);
  transition: background 0.1s;
}
.qual-table tbody tr:last-child { border-bottom: none; }
.qual-table tbody tr:hover { background: var(--primary-xlight); }
.qual-table tbody tr.qual-row-review { background: #fff5f5; }
.qual-table tbody tr.qual-row-review:hover { background: #ffe8e8; }

.qual-table td {
  padding: 7px 12px;
  vertical-align: middle;
  border-right: 1px solid var(--border);
}
.qual-table td:last-child { border-right: none; }

/* Area cell — merged rows */
.qual-area-cell {
  font-weight: 700;
  font-size: 11.5px;
  color: var(--text-2);
  background: var(--surface-2) !important;
  vertical-align: middle !important;
  text-align: center;
  width: 110px;
  border-right: 2px solid var(--border-strong) !important;
  line-height: 1.4;
  padding: 8px !important;
}

/* Radio label */
.qual-radio-label {
  display: flex;
  align-items: center;
  gap: 9px;
  cursor: pointer;
}

.qual-radio-label input[type="radio"] { display: none; }

.qual-radio {
  width: 15px; height: 15px;
  border: 2px solid var(--border-strong);
  border-radius: 50%;
  flex-shrink: 0;
  transition: all 0.15s;
  background: #fff;
}

.qual-radio-label:hover .qual-radio { border-color: var(--primary); }

.qual-radio-label input:checked ~ .qual-radio {
  border-color: var(--primary);
  background: var(--primary);
  box-shadow: inset 0 0 0 3px #fff;
}

.qual-row-review .qual-radio-label input:checked ~ .qual-radio {
  border-color: var(--danger);
  background: var(--danger);
}

.qual-answer-text {
  font-size: 12.5px;
  font-weight: 500;
  color: var(--text);
}

.qual-radio-label input:checked ~ .qual-answer-text { color: var(--primary-h); font-weight: 700; }
.qual-row-review .qual-radio-label input:checked ~ .qual-answer-text { color: var(--danger); }

/* Guidance */
.qual-guidance-cell {
  color: var(--muted);
  font-size: 11.5px;
  line-height: 1.4;
}

.conflict-warning {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  background: #fff7ed;
  border: 1px solid #fed7aa;
  border-radius: var(--radius-xs);
  padding: 10px 12px;
  font-size: 12px;
  font-weight: 500;
  color: #92400e;
  margin-bottom: 14px;
  line-height: 1.5;
}
.conflict-warning svg { flex-shrink: 0; margin-top: 1px; }
.modal-footer {
  padding: 12px 22px;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 10px;
  border-top: 1px solid var(--border);
  background: var(--surface-2);
  flex-shrink: 0;
}

/* ===== FORM FIELDS (modal) ===== */
.field-group { margin-bottom: 0; }
.field-row   { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

.field-label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-2);
  margin-bottom: 6px;
  letter-spacing: 0.01em;
}

.field-optional {
  font-weight: 400;
  color: var(--muted);
  margin-left: 4px;
}

.field-input {
  width: 100%;
  padding: 9px 12px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-xs);
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  background: var(--surface);
  color: var(--text);
  transition: border-color 0.15s, box-shadow 0.15s;
  outline: none;
}

.field-input::placeholder { color: var(--muted); }
.field-input:hover  { border-color: var(--border-strong); }
.field-input:focus  { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(5,150,105,0.12); }

.field-textarea { resize: vertical; min-height: 70px; }

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 18px;
  border-radius: var(--radius-xs);
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  border: 1.5px solid transparent;
  transition: all 0.15s;
  white-space: nowrap;
}

.btn-primary {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
  box-shadow: 0 1px 3px rgba(5,150,105,0.3);
}
.btn-primary:hover  { background: var(--primary-h); border-color: var(--primary-h); transform: translateY(-1px); box-shadow: 0 4px 8px rgba(5,150,105,0.25); }
.btn-primary:active { transform: translateY(0); }

.btn-ghost {
  background: transparent;
  color: var(--muted);
  border-color: var(--border);
}
.btn-ghost:hover { background: var(--surface-2); color: var(--text); border-color: var(--border-strong); }

.btn-outline {
  background: transparent;
  color: var(--primary);
  border-color: var(--primary-light);
}
.btn-outline:hover { background: var(--primary-xlight); }

.btn-sm { padding: 6px 14px; font-size: 12px; }

.btn:disabled { opacity: 0.55; cursor: not-allowed; transform: none !important; }

/* ================================================================
   DASHBOARD PAGE
   ================================================================ */
.dash-page {
  max-width: 1200px;
  margin: 0 auto;
  padding: 28px 24px 60px;
}

.dash-period-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  gap: 16px;
  flex-wrap: wrap;
}

.dash-page-title { font-size: 20px; font-weight: 700; letter-spacing: -0.02em; color: var(--text); }

.period-tabs { display: flex; background: var(--surface); border: 1px solid var(--border); border-radius: 8px; padding: 3px; gap: 2px; }
.period-tab { padding: 6px 16px; border: none; border-radius: 6px; background: transparent; font-family: 'Inter', sans-serif; font-size: 13px; font-weight: 600; color: var(--muted); cursor: pointer; transition: all 0.15s; }
.period-tab.active { background: var(--primary-h); color: #fff; }
.period-tab:hover:not(.active) { background: var(--surface-2); color: var(--text); }

.dash-kpi-row { display: grid; grid-template-columns: repeat(5, 1fr); gap: 14px; margin-bottom: 24px; }

.kpi-tile { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px 20px; box-shadow: var(--shadow-sm); border-top: 3px solid transparent; transition: box-shadow 0.15s; }
.kpi-tile:hover { box-shadow: var(--shadow); }
.kpi-tile-blue    { border-top-color: var(--primary); }
.kpi-tile-green   { border-top-color: #10b981; }
.kpi-tile-emerald { border-top-color: #059669; }
.kpi-tile-amber   { border-top-color: #f59e0b; }
.kpi-tile-red     { border-top-color: var(--danger); }
.kpi-tile-num { font-size: 32px; font-weight: 700; letter-spacing: -0.03em; color: var(--text); line-height: 1; margin-bottom: 6px; }
.kpi-tile-lbl  { font-size: 11px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: 0.05em; }
.kpi-tile-hint { font-size: 10px; color: var(--muted); margin-top: 3px; opacity: 0.8; }

.dash-grid { display: grid; grid-template-columns: 1fr 340px; gap: 18px; }
.dash-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-sm); overflow: hidden; }
.dash-card-wide { grid-column: 1 / -1; }
.dash-card-header { display: flex; justify-content: space-between; align-items: center; padding: 16px 20px; border-bottom: 1px solid var(--border); }
.dash-card-title { font-size: 14px; font-weight: 700; color: var(--text); }
.dash-card-sub { font-size: 12px; color: var(--muted); font-weight: 500; }

.leaderboard-wrap { overflow-x: auto; }
.leaderboard-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.leaderboard-table thead th { padding: 10px 14px; text-align: left; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--muted); background: var(--surface-2); border-bottom: 1px solid var(--border); white-space: nowrap; }
.leaderboard-table tbody tr { border-bottom: 1px solid var(--border); transition: background 0.1s; }
.leaderboard-table tbody tr:last-child { border-bottom: none; }
.leaderboard-table tbody tr:hover { background: var(--primary-xlight); }
.leaderboard-table tbody tr.lb-top3 { background: #fafbff; }
.leaderboard-table td { padding: 11px 14px; vertical-align: middle; }
.lb-rank  { font-size: 18px; text-align: center; width: 48px; }
.lb-name  { font-weight: 700; color: var(--text); }
.lb-num   { text-align: right; color: var(--text-2); font-variant-numeric: tabular-nums; }
.lb-bold  { font-weight: 700; color: var(--text); font-size: 15px; }
.lb-green  { color: #059669; font-weight: 600; }
.lb-amber  { color: #d97706; font-weight: 600; }
.lb-red    { color: var(--danger); font-weight: 600; }
.lb-purple { color: #7c3aed; font-weight: 600; }
.lb-quality { font-weight: 700; }
.lb-flag  { background: #fef2f2; color: var(--danger); font-size: 11px; font-weight: 700; padding: 2px 6px; border-radius: 10px; }
.lb-empty { text-align: center; color: var(--muted); padding: 32px; font-size: 13px; }

.outcome-bars { padding: 16px 20px; display: flex; flex-direction: column; gap: 14px; }
.ob-row { display: grid; grid-template-columns: 180px 1fr 60px; align-items: center; gap: 10px; }
.ob-label { font-size: 12.5px; font-weight: 500; color: var(--text); }
.ob-track { background: var(--surface-2); border-radius: 20px; height: 8px; overflow: hidden; }
.ob-bar   { height: 100%; border-radius: 20px; transition: width 0.4s ease; min-width: 2px; }
.ob-stat  { font-size: 12px; font-weight: 700; color: var(--text); text-align: right; }
.ob-pct   { color: var(--muted); font-weight: 500; }

.week-schedule { padding: 8px 0; }
.ws-item { display: flex; align-items: center; gap: 14px; padding: 10px 20px; border-bottom: 1px solid var(--border); transition: background 0.1s; }
.ws-item:last-child { border-bottom: none; }
.ws-item:hover { background: var(--surface-2); }
.ws-today { background: var(--primary-xlight) !important; }
.ws-past  { opacity: 0.55; }
.ws-time  { text-align: center; flex-shrink: 0; width: 44px; }
.ws-day   { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); }
.ws-num   { font-size: 20px; font-weight: 700; color: var(--text); line-height: 1.1; }
.ws-clock { font-size: 10px; color: var(--muted); font-weight: 500; }
.ws-body  { flex: 1; min-width: 0; }
.ws-name  { font-size: 13px; font-weight: 600; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ws-coord { font-size: 11px; color: var(--muted); margin-top: 2px; }
.ws-empty { padding: 24px 20px; text-align: center; color: var(--muted); font-size: 13px; }

@media (max-width: 900px) {
  .dash-kpi-row { grid-template-columns: repeat(3, 1fr); }
  .dash-grid    { grid-template-columns: 1fr; }
  .dash-card-wide { grid-column: 1; }
  .ob-row { grid-template-columns: 140px 1fr 48px; }
}

/* ===== DASHBOARD PAGE LAYOUT ===== */
.page-wrap {
  max-width: 800px;
  margin: 0 auto;
  padding: 32px 24px 80px;
}

/* ===== DASHBOARD: HEADER ===== */
.page-header {
  margin-bottom: 28px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border);
}

.page-header h1 {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 4px;
}
.page-header .subtitle { font-size: 13px; color: var(--muted); margin-bottom: 16px; }
.header-actions { display: flex; gap: 10px; flex-wrap: wrap; }

/* ===== DASHBOARD: FILTER BAR ===== */
/* Summary table — breaks out of the 800px page-wrap to fill the viewport */
.summary-table-wrap {
  position: relative;
  left: 50%;
  right: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
  width: 100vw;
  padding: 0 28px;
  box-sizing: border-box;
  margin-top: 4px;
}
.summary-table-scroll { overflow-x: auto; border-radius: var(--radius-sm); border: 1.5px solid var(--border); }
.summary-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  background: var(--surface);
}
.summary-table thead th {
  background: var(--surface-2);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  padding: 10px 14px;
  text-align: left;
  white-space: nowrap;
  border-bottom: 1.5px solid var(--border);
}
.summary-table tbody tr { border-bottom: 1px solid var(--border); }
.summary-table tbody tr:last-child { border-bottom: none; }
.summary-table tbody tr:hover { background: var(--surface-2); }
.summary-table tbody td { padding: 10px 14px; vertical-align: middle; color: var(--text); }
.summary-table .session-notes-cell { max-width: 220px; white-space: pre-wrap; font-size: 12px; color: var(--muted); }
.summary-table .summary-empty { text-align: center; padding: 32px; color: var(--muted); }
.filter-btn-summary { margin-left: auto; }
.fw-500 { font-weight: 500; }
.fs-11  { font-size: 11px; }
.text-muted { color: var(--muted); }
.nowrap { white-space: nowrap; }

.filter-bar { display: flex; gap: 6px; margin-bottom: 20px; }

.filter-btn {
  padding: 6px 16px;
  border-radius: 20px;
  border: 1.5px solid var(--border);
  background: var(--surface);
  font-family: 'Inter', sans-serif;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  color: var(--muted);
  transition: all 0.15s;
}
.filter-btn.active,
.filter-btn:hover { background: var(--primary); color: #fff; border-color: var(--primary); }

/* ===== APPOINTMENTS PAGE ===== */

/* KPI strip */
.kpi-strip {
  display: flex;
  gap: 12px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}
.kpi-card {
  flex: 1;
  min-width: 110px;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  cursor: pointer;
  transition: border-color 0.15s, box-shadow 0.15s;
  text-align: center;
  user-select: none;
}
.kpi-card:hover { border-color: var(--primary-light); box-shadow: var(--shadow-sm); }
.kpi-num { display: block; font-size: 28px; font-weight: 700; letter-spacing: -0.03em; color: var(--text); line-height: 1.1; }
.kpi-lbl { display: block; font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); margin-top: 4px; }
.kpi-today    .kpi-num { color: var(--primary-h); }
.kpi-upcoming .kpi-num { color: #065f46; }
.kpi-past     .kpi-num { color: #92400e; }
.kpi-completed .kpi-num { color: var(--completed); }

/* Toolbar */
.appt-toolbar {
  display: flex;
  gap: 12px;
  margin-bottom: 16px;
  align-items: center;
  flex-wrap: wrap;
}
.search-wrap {
  position: relative;
  flex: 1;
  min-width: 200px;
}
.search-icon {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--muted);
  pointer-events: none;
}
.search-input {
  width: 100%;
  padding: 8px 12px 8px 34px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  background: var(--surface);
  color: var(--text);
  outline: none;
  transition: border-color 0.15s;
}
.search-input:focus { border-color: var(--primary); }

/* Coordinator filter pills */
.coord-filter { display: flex; gap: 6px; flex-wrap: wrap; }
.coord-btn {
  padding: 6px 14px;
  border-radius: 20px;
  border: 1.5px solid var(--border);
  background: var(--surface);
  color: var(--muted);
  font-family: 'Inter', sans-serif;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s;
  white-space: nowrap;
}
.coord-btn:hover { border-color: var(--primary-light); color: var(--primary); }
.coord-btn.active { background: var(--primary); color: #fff; border-color: var(--primary); }

/* ── Appointment cards ─────────────────────────────────────────── */
.appointments-grid { display: flex; flex-direction: column; gap: 12px; }

.appt-card-new {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-left: 4px solid var(--border-strong);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: box-shadow 0.15s, transform 0.15s;
}
.appt-card-new:hover { box-shadow: var(--shadow); transform: translateY(-1px); }
.appt-card-new.appt-completed { opacity: 0.72; }

/* Left accent per status / outcome */
.acn-accent-upcoming    { border-left-color: var(--primary); }
.acn-accent-past        { border-left-color: #f59e0b; }
.acn-accent-completed   { border-left-color: var(--completed); }
.acn-accent-prospective { border-left-color: #10b981; }
.acn-accent-followup    { border-left-color: #3b82f6; }
.acn-accent-notsuitable { border-left-color: #ef4444; }
.acn-accent-filterissue { border-left-color: #f59e0b; }

/* Header */
.acn-header { padding: 16px 20px 14px; }

.acn-title-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 4px;
}
.acn-name {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.3;
}
.acn-datetime { font-size: 12px; color: var(--muted); margin-bottom: 10px; }
.acn-chips { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }

.badge-lg { font-size: 12px !important; padding: 5px 13px !important; flex-shrink: 0; font-weight: 700 !important; letter-spacing: 0.01em; }

/* Solid vibrant colours for large outcome badges on cards */
.badge-lg.status-prospective { background: #10b981; color: #fff; }
.badge-lg.status-followup    { background: #3b82f6; color: #fff; }
.badge-lg.status-notsuitable { background: #ef4444; color: #fff; }
.badge-lg.status-filterissue { background: #f59e0b; color: #fff; }
.badge-lg.status-past        { background: #f59e0b; color: #fff; }
.badge-lg.status-upcoming    { background: var(--primary); color: #fff; }
.badge-lg.status-completed   { background: var(--completed); color: #fff; }

/* Chips */
.chip {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 500;
  text-decoration: none;
  white-space: nowrap;
}
.chip-coord { background: var(--primary-xlight); color: var(--primary-h); font-weight: 600; }
.chip-info  { background: var(--surface-2); color: var(--muted); border: 1px solid var(--border); }
.chip-meet  { background: #eff6ff; color: #1d4ed8; border: 1px solid #bfdbfe; font-weight: 600; }
.chip-meet:hover { background: #dbeafe; }

/* Student details — always shown */
.acn-details {
  background: var(--surface-2);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 14px 20px;
}
.acn-section-lbl {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  margin-bottom: 12px;
}
.acn-details-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 12px 24px;
}
.acn-di { display: flex; flex-direction: column; gap: 3px; }
.acn-dl { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); }
.acn-dv { font-size: 13px; font-weight: 500; color: var(--text); }
.acn-booking-note {
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid var(--border);
  font-size: 12px;
  color: var(--muted);
  font-style: italic;
}

/* Session notes */
.acn-notes {
  padding: 16px 20px;
  background: var(--surface);
}
.acn-notes-header {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 10px;
}
.acn-notes-icon {
  width: 28px;
  height: 28px;
  border-radius: var(--radius-xs);
  background: var(--primary-xlight);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.acn-notes-header .acn-section-lbl { margin: 0; }
.acn-notes .notes-input {
  width: 100%;
  box-sizing: border-box;
  min-height: 80px;
  padding: 12px 14px;
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  color: var(--text);
  line-height: 1.7;
  border-color: var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  resize: vertical;
}
.acn-notes .notes-input:focus {
  border-color: var(--primary);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(89,146,198,0.15);
}

/* Footer */
.acn-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border-top: 1px solid var(--border);
  background: var(--surface-2);
  flex-wrap: wrap;
}

/* ===== DASHBOARD PAGE ===== */
.dash-wrap { max-width: 1100px; }

.dash-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}
.dash-kpi-card {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 22px;
  display: flex;
  align-items: center;
  gap: 16px;
  box-shadow: var(--shadow-sm);
}
.dash-kpi-icon {
  width: 44px; height: 44px;
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.dash-kpi-green .dash-kpi-icon { background: #d1fae5; }
.dash-kpi-blue  .dash-kpi-icon { background: #dbeafe; }
.dash-kpi-amber .dash-kpi-icon { background: #fef3c7; }
.dash-kpi-num { font-size: 30px; font-weight: 700; letter-spacing: -0.03em; line-height: 1; color: var(--text); }
.dash-kpi-lbl { font-size: 12px; color: var(--muted); font-weight: 500; margin-top: 4px; }

.dash-main-grid {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 20px;
  margin-bottom: 20px;
  align-items: start;
}
.dash-section {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 24px;
  box-shadow: var(--shadow-sm);
}
.dash-section-title {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.01em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 16px;
}
.dash-table-wrap { overflow-x: auto; }
.dash-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.dash-table th {
  text-align: left;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  padding: 0 12px 10px 0;
  border-bottom: 1.5px solid var(--border);
  white-space: nowrap;
}
.dash-table td {
  padding: 11px 12px 11px 0;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}
.dash-table tbody tr:last-child td { border-bottom: none; }
.dash-table tbody tr:hover { background: var(--surface-2); }

/* Outcome breakdown bars */
.outcome-breakdown { display: flex; flex-direction: column; gap: 14px; }
.outcome-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  align-items: center;
}
.outcome-label { font-size: 13px; font-weight: 500; margin-bottom: 4px; }
.outcome-bar-wrap { background: var(--surface-2); border-radius: 4px; height: 7px; overflow: hidden; margin-bottom: 0; }
.outcome-bar { height: 100%; border-radius: 4px; transition: width 0.6s ease; min-width: 4px; }
.outcome-bar-prospective { background: #10b981; }
.outcome-bar-followup    { background: #3b82f6; }
.outcome-bar-notsuitable { background: #ef4444; }
.outcome-bar-filterissue { background: #f59e0b; }
.outcome-bar-upcoming    { background: var(--border-strong); }
.outcome-stat { font-size: 13px; font-weight: 700; text-align: right; white-space: nowrap; }
.outcome-pct  { font-size: 11px; color: var(--muted); font-weight: 400; }
.outcome-row { grid-template-columns: 1fr; }
.outcome-bar-row { display: flex; align-items: center; gap: 10px; }
.outcome-bar-wrap { flex: 1; }

/* This week list */
.week-list { display: flex; flex-direction: column; gap: 8px; }
.week-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  border: 1px solid var(--border);
}
.week-item.week-today { background: var(--primary-xlight); border-color: var(--primary-light); }
.week-item.week-past  { opacity: 0.6; }
.week-date { text-align: center; min-width: 34px; }
.week-day  { font-size: 10px; font-weight: 700; text-transform: uppercase; color: var(--muted); }
.week-num  { font-size: 20px; font-weight: 700; line-height: 1.2; letter-spacing: -0.02em; }
.week-detail { flex: 1; display: flex; flex-direction: column; gap: 1px; min-width: 0; }

/* ===== DASHBOARD: APPOINTMENT CARDS (legacy — kept for fallback) ===== */
.appt-card {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 24px;
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.15s, transform 0.15s;
}
.appt-card:hover { box-shadow: var(--shadow); transform: translateY(-1px); }
.appt-card.appt-completed { opacity: 0.7; border-left: 3px solid var(--completed); }

.appt-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 12px;
  gap: 12px;
}

.appt-title { font-size: 15px; font-weight: 700; letter-spacing: -0.01em; margin-bottom: 3px; }
.appt-meta  { font-size: 12px; color: var(--muted); }

.status-badge {
  font-size: 11px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
  white-space: nowrap;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}
.status-upcoming  { background: var(--primary-xlight); color: var(--primary); }
.status-completed { background: #f1f5f9; color: var(--completed); }
.status-past      { background: #fff3cd; color: #92620a; }
.status-outcome        { background: #edf7ee; color: #1a6b2f; }
.status-prospective    { background: #d1fae5; color: #065f46; }
.status-followup       { background: #dbeafe; color: #1e40af; }
.status-notsuitable    { background: #fee2e2; color: #991b1b; }
.status-filterissue    { background: #fef3c7; color: #92400e; }

.appt-people { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; }

.pill {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 500;
  text-decoration: none;
}
.pill-student   { background: var(--primary-xlight); color: var(--primary-h); }
.pill-counselor { background: #fdf0f5; color: var(--accent-dark); }
.pill-meet      { background: var(--primary-xlight); color: var(--primary); border: 1px solid var(--primary-light); }
.pill-meet:hover { background: var(--primary-light); }

.intake-section {
  background: var(--surface-2);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  margin-bottom: 14px;
}
.intake-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}
.intake-review-flag {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  background: #fff3cd;
  color: #92620a;
  border: 1px solid #f0d080;
  border-radius: 20px;
  padding: 2px 9px;
}
.intake-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 8px;
}
.intake-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.intake-label {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}
.intake-val {
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
}
.intake-booking-notes {
  margin-top: 10px;
  font-size: 12px;
  color: var(--muted);
  font-style: italic;
  border-top: 1px solid var(--border);
  padding-top: 8px;
}

.appt-notes-section { margin-bottom: 14px; }
.notes-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  margin-bottom: 6px;
  display: block;
}
.notes-input {
  width: 100%;
  min-height: 66px;
  padding: 9px 12px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-xs);
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  background: var(--surface-2);
  color: var(--text);
  resize: vertical;
  transition: border-color 0.15s, box-shadow 0.15s;
  outline: none;
}
.notes-input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(5,150,105,0.12); background: #fff; }

.appt-actions { display: flex; gap: 8px; flex-wrap: wrap; }

/* ================================================================
   APPOINTMENT CARD v2  (appointments.html)
   ================================================================ */
.appt-card-v2 {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  margin-bottom: 14px;
  transition: box-shadow 0.15s;
}
.appt-card-v2:hover { box-shadow: var(--shadow); }
.appt-card-v2.card-completed { opacity: 0.82; }

/* Colour stripe at top */
.card-stripe { height: 4px; }
.stripe-upcoming      { background: var(--primary); }
.stripe-past          { background: var(--completed); }
.stripe-completed     { background: var(--completed); }
.stripe-prospective   { background: #10b981; }
.stripe-followup      { background: #f59e0b; }
.stripe-notsuitable   { background: var(--danger); }
.stripe-filterissue   { background: #7c3aed; }

/* Header */
.card-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 16px 20px 10px;
  gap: 12px;
}
.card-student {
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.01em;
  margin-bottom: 4px;
}
.card-datetime {
  font-size: 12.5px;
  color: var(--muted);
  font-weight: 500;
}

/* Status badge */
.card-badge {
  font-size: 11px;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 20px;
  white-space: nowrap;
  flex-shrink: 0;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.badge-upcoming     { background: var(--primary-xlight); color: var(--primary-h); }
.badge-past         { background: #f1f5f9; color: var(--completed); }
.badge-completed    { background: #f1f5f9; color: var(--completed); }
.badge-prospective  { background: #d1fae5; color: #065f46; }
.badge-followup     { background: #fffbeb; color: #92400e; }
.badge-notsuitable  { background: var(--danger-light); color: var(--danger); }
.badge-filterissue  { background: #f5f3ff; color: #6d28d9; }

/* Info chips row */
.card-info-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 0 20px 14px;
  flex-wrap: wrap;
}
.card-info-left  { display: flex; flex-wrap: wrap; gap: 6px; flex: 1; }
.card-info-right { display: flex; gap: 6px; flex-shrink: 0; }
.ci {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 12px;
  font-weight: 500;
  padding: 4px 10px;
  border-radius: 20px;
  text-decoration: none;
}
.ci-coord  { background: var(--primary-xlight); color: var(--primary-h); }
.ci-info   { background: var(--surface-2); color: var(--text-2); border: 1px solid var(--border); }
.ci-meet       { background: #d1fae5; color: #065f46; border: 1px solid #a7f3d0; }
.ci-meet:hover { background: #a7f3d0; }
.ci-calendar   { background: var(--surface-2); color: var(--text-2); border: 1px solid var(--border); }
.ci-calendar:hover { background: var(--border); }
.ci-review     { background: #fef3c7; color: #92400e; border: 1px solid #fde68a; font-weight: 700; font-size: 11px; }

/* Reschedule popup */
.reschedule-popup {
  background: var(--surface);
  border-radius: 14px;
  box-shadow: var(--shadow-xl);
  width: 100%;
  max-width: 420px;
  overflow: hidden;
  animation: modal-in 0.2s cubic-bezier(0.34,1.4,0.64,1);
}
.reschedule-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 20px 20px 0;
  gap: 12px;
}
.reschedule-title    { font-size: 16px; font-weight: 700; color: var(--text); margin-bottom: 3px; }
.reschedule-subtitle { font-size: 12px; color: var(--primary); font-weight: 600; }
.reschedule-body     { padding: 16px 20px; }
.reschedule-current  { font-size: 12px; color: var(--muted); background: var(--surface-2); border-radius: var(--radius-xs); padding: 8px 12px; margin-bottom: 14px; }
.reschedule-fields   { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 12px; }
.reschedule-note     { font-size: 12px; color: var(--muted); line-height: 1.5; }
.reschedule-error    { font-size: 12px; color: var(--danger); font-weight: 600; margin-top: 8px; }
.reschedule-footer   { padding: 12px 20px 18px; display: flex; justify-content: flex-end; gap: 10px; border-top: 1px solid var(--border); background: var(--surface-2); }

/* Reschedule — result panel */
.rs-success-icon {
  display: flex;
  justify-content: center;
  margin-bottom: 10px;
}
.rs-success-msg {
  text-align: center;
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  margin: 0 0 4px;
}
.rs-success-time {
  text-align: center;
  font-size: 12px;
  color: var(--muted);
  margin: 0 0 16px;
}
.rs-meet-result {
  background: var(--primary-xlight);
  border: 1.5px solid var(--primary-light);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  margin-top: 4px;
}
.rs-meet-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--primary-h);
  margin-bottom: 8px;
}
.rs-meet-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}
.rs-meet-url {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--primary-h);
  text-decoration: none;
  word-break: break-all;
  flex: 1;
}
.rs-meet-url:hover { text-decoration: underline; }

/* Cancel popup */
.cancel-popup {
  background: var(--surface);
  border-radius: 16px;
  box-shadow: var(--shadow-xl);
  width: 100%;
  max-width: 420px;
  padding: 32px 28px 24px;
  text-align: center;
  animation: modal-in 0.2s cubic-bezier(0.34,1.4,0.64,1);
}
.cancel-popup-icon   { margin-bottom: 16px; }
.cancel-popup-title  { font-size: 18px; font-weight: 700; color: var(--text); margin-bottom: 10px; }
.cancel-popup-body   { font-size: 13px; color: var(--muted); line-height: 1.6; margin-bottom: 10px; }
.cancel-popup-name   { font-size: 14px; font-weight: 700; color: var(--text); margin-bottom: 24px; }
.cancel-popup-actions { display: flex; gap: 10px; justify-content: center; }

.btn-danger {
  background: var(--danger);
  color: #fff;
  border-color: var(--danger);
}
.btn-danger:hover { background: #a93226; border-color: #a93226; }

/* Qualification check */
.card-qual {
  padding: 14px 20px;
  border-top: 1px solid var(--border);
  background: var(--surface-2);
}
.card-section-lbl {
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--muted);
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.qual-viec-flag {
  font-size: 10px;
  font-weight: 700;
  background: #fef3c7;
  color: #92400e;
  border: 1px solid #fde68a;
  padding: 2px 8px;
  border-radius: 20px;
  text-transform: none;
  letter-spacing: 0;
}

.card-qual-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 8px;
}
.cq-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-xs);
  padding: 8px 12px;
}
/* Email address can be long — let it span two columns when space allows */
.cq-item-wide {
  grid-column: span 2;
}
.cq-label {
  display: block;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  margin-bottom: 3px;
}
.cq-value {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text);
}

/* Session notes */
.card-notes {
  padding: 14px 20px;
  border-top: 1px solid var(--border);
}
.card-readonly     { font-weight: 400; color: var(--muted); text-transform: none; letter-spacing: 0; font-size: 11px; }
.card-required-note { font-weight: 500; color: var(--primary); text-transform: none; letter-spacing: 0; font-size: 11px; }

.card-textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-xs);
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  color: var(--text);
  background: var(--surface);
  resize: vertical;
  min-height: 80px;
  transition: border-color 0.15s, box-shadow 0.15s;
  outline: none;
}
.card-textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(89,146,198,0.12);
}
.card-textarea[readonly] { background: var(--surface-2); opacity: 0.7; cursor: default; }

/* Outcome section */
.card-outcome {
  padding: 14px 20px;
  border-top: 1px solid var(--border);
  background: var(--surface-2);
}
.card-outcome-row {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-top: 8px;
}
.card-outcome-select {
  flex: 1;
  padding: 9px 12px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-xs);
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  font-weight: 500;
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
  transition: border-color 0.15s;
  outline: none;
}
.card-outcome-select:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(89,146,198,0.12); }
.card-outcome-select:invalid,
.card-outcome-select option[value=""] { color: var(--muted); }

.card-outcome-error {
  font-size: 12px;
  color: var(--danger);
  font-weight: 600;
  margin-top: 6px;
}

.card-outcome-done {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

/* Footer actions (non-completed) */
.card-footer-actions {
  padding: 10px 20px 14px;
  display: flex;
  gap: 8px;
}

/* ===== OUTCOME SECTION (appointments.html card) ===== */
.acn-outcome {
  padding: 12px 20px;
  border-top: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

/* ===== OUTCOME SECTION (dashboard) ===== */
.outcome-section { margin-bottom: 12px; display: flex; flex-direction: column; gap: 6px; }

.outcome-required {
  font-size: 10px;
  font-weight: 600;
  color: var(--danger);
  margin-left: 6px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.outcome-select {
  width: 100%;
  padding: 8px 12px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-xs);
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  font-weight: 500;
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
  transition: border-color 0.15s;
}
.outcome-select:focus { outline: none; border-color: var(--primary); }

.outcome-error { font-size: 12px; color: var(--danger); font-weight: 500; }

.outcome-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 700;
  width: fit-content;
}
.outcome-prospective         { background: #d1fae5; color: #065f46; }
.outcome-follow-up-required  { background: #fffbeb; color: #92400e; }
.outcome-not-suitable        { background: var(--danger-light); color: var(--danger); }
.outcome-filteration-issue   { background: #fdf4ff; color: #7e22ce; }

.btn-success {
  background: var(--success);
  color: #fff;
  border-color: var(--success);
}
.btn-success:hover { background: var(--primary-h); }

/* ===== SUCCESS / ERROR CARDS ===== */
.success-card {
  background: var(--primary-xlight);
  border: 1.5px solid var(--primary-light);
  border-radius: var(--radius);
  padding: 32px;
  text-align: center;
}
.success-card h2 { font-size: 18px; font-weight: 700; margin-bottom: 10px; }
.success-card p  { color: var(--muted); font-size: 13px; margin-bottom: 20px; }
.success-card .btn { margin: 0 5px; }

.error-card {
  background: var(--danger-light);
  border: 1.5px solid #fecaca;
  border-radius: var(--radius-xs);
  padding: 14px 18px;
  color: var(--danger);
  font-size: 13px;
  margin-top: 14px;
}

/* ===== LOADING / EMPTY ===== */
.loading-msg { text-align: center; color: var(--muted); padding: 48px; font-size: 14px; }
.empty-state { text-align: center; padding: 64px 20px; color: var(--muted); }
.empty-state p { margin-bottom: 20px; font-size: 15px; }

/* ===== STUDENT RSVP CHIPS & DECLINED WARNING ===== */
.ci-rsvp-accepted  { background: #d1fae5; color: #065f46; border: 1px solid #a7f3d0; font-weight: 600; }
.ci-rsvp-declined  { background: #fee2e2; color: #991b1b; border: 1px solid #fecaca; font-weight: 700; }
.ci-rsvp-tentative { background: #fef3c7; color: #92400e; border: 1px solid #fde68a; font-weight: 600; }
.ci-rsvp-pending   { background: var(--surface-2); color: var(--muted); border: 1px solid var(--border); }

/* Full-width warning bar shown inside declined cards */
.card-declined-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 20px;
  background: #fef2f2;
  border-top: 1px solid #fecaca;
  border-bottom: 1px solid #fecaca;
  font-size: 12px;
  font-weight: 600;
  color: #991b1b;
}
.card-declined-bar svg { flex-shrink: 0; }

/* Slightly dim the top stripe for declined so the warning bar stands out */
.appt-card-v2.card-declined .card-stripe { background: #fca5a5; }

/* ===== APPOINTMENT TYPE TOGGLE (booking modal) ===== */
.appt-type-toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.appt-type-btn {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.15s;
  background: var(--surface);
  user-select: none;
  position: relative;
}

.appt-type-btn input[type="radio"] { position: absolute; opacity: 0; width: 0; height: 0; }

.appt-type-btn:hover {
  border-color: var(--primary-light);
  background: var(--primary-xlight);
}

.appt-type-btn.appt-type-selected {
  border-color: var(--primary);
  background: var(--primary-xlight);
  box-shadow: 0 0 0 3px rgba(89,146,198,0.15);
}

.appt-type-icon { font-size: 22px; flex-shrink: 0; line-height: 1; }

.appt-type-text { display: flex; flex-direction: column; gap: 2px; }

.appt-type-name {
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.3;
}

.appt-type-hint {
  font-size: 11px;
  color: var(--muted);
  font-weight: 400;
}

.appt-type-btn.appt-type-selected .appt-type-name { color: var(--primary-h); }
.appt-type-btn.appt-type-selected .appt-type-hint { color: var(--primary); }

/* Confirmation modal — physical notice */
.confirm-physical {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #fffbeb;
  border: 1.5px solid #fde68a;
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  margin-top: 14px;
}
.confirm-physical-icon { font-size: 20px; flex-shrink: 0; }
.confirm-physical-text { font-size: 12px; color: #92400e; font-weight: 500; line-height: 1.5; margin: 0; }

/* Appointment type chips on cards (appointments.html) */
.ci-online   { background: #eff6ff; color: #1d4ed8; border: 1px solid #bfdbfe; font-weight: 600; }
.ci-physical { background: #fffbeb; color: #92400e; border: 1px solid #fde68a; font-weight: 600; }

/* ===== TOAST ===== */
.toast {
  position: fixed;
  bottom: 28px;
  right: 28px;
  background: var(--text);
  color: #fff;
  padding: 11px 18px;
  border-radius: var(--radius-sm);
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  font-weight: 600;
  opacity: 0;
  transform: translateY(10px);
  transition: all 0.25s cubic-bezier(0.34,1.56,0.64,1);
  z-index: 9999;
  box-shadow: var(--shadow-lg);
  pointer-events: none;
}
.toast.toast-show { opacity: 1; transform: translateY(0); }

/* ===== RESPONSIVE ===== */
@media (max-width: 640px) {
  .topbar-nav { display: none; }
  .cal-page   { padding: 16px 16px 48px; }
  .cal-card   { padding: 12px; }
  .cal-toolbar { flex-direction: column; align-items: flex-start; gap: 10px; }
  .fc .fc-toolbar { flex-direction: column; gap: 10px; }
  .modal { max-width: 100%; }
  .field-row  { grid-template-columns: 1fr; }
  .page-wrap  { padding: 20px 16px 60px; }
  .appt-card  { padding: 16px; }
  .appt-header { flex-direction: column; }
}
