:root {
  --bg-base: #f6f8fc;
  --bg-surface: #ffffff;
  --bg-elevated: #f9fbff;
  --text-main: #182230;
  --text-muted: #5d6b82;
  --line-soft: #d8e0ee;
  --brand: #1f6feb;
  --brand-strong: #1a56b8;
  --accent: #0e9f6e;
  --danger: #cc2f52;
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --shadow-sm: 0 8px 20px rgba(16, 24, 40, 0.08);
  --shadow-md: 0 18px 48px rgba(16, 24, 40, 0.12);
  --container: 1140px;
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes shimmer {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

@keyframes driftGlow {
  0% {
    transform: translateY(0);
    opacity: 0.85;
  }
  50% {
    transform: translateY(-8px);
    opacity: 1;
  }
  100% {
    transform: translateY(0);
    opacity: 0.85;
  }
}

@keyframes detailReveal {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
}

body {
  font-family: "Manrope", "Segoe UI", sans-serif;
  color: var(--text-main);
  min-height: 100vh;
  background:
    radial-gradient(circle at 8% 0%, rgba(31, 111, 235, 0.16), transparent 38%),
    radial-gradient(circle at 88% 12%, rgba(14, 159, 110, 0.16), transparent 40%),
    linear-gradient(180deg, #eff4ff 0%, #f8fbff 32%, #f5f8ff 100%);
  transition: transform 220ms ease, opacity 220ms ease, filter 220ms ease;
  opacity: 1;
  transform: translateY(0);
  filter: blur(0);
}

.home-page {
  font-family: "Inter", "Sora", "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at 2% -4%, rgba(32, 119, 231, 0.24), transparent 35%),
    radial-gradient(circle at 92% 4%, rgba(24, 178, 130, 0.18), transparent 30%),
    linear-gradient(180deg, #ebf3ff 0%, #f5f8ff 46%, #f4fbff 100%);
}

.home-page h1,
.home-page h2,
.home-page h3 {
  font-family: "DM Serif Display", "Merriweather", Georgia, serif;
  letter-spacing: 0.01em;
}

.home-page .site-header {
  position: relative;
  margin-bottom: 24px;
  padding: 22px 22px 20px;
  border-radius: 28px;
  border: 1px solid #cbdbf4;
  background: linear-gradient(150deg, rgba(255, 255, 255, 0.95), rgba(237, 246, 255, 0.92));
  box-shadow: 0 22px 46px rgba(22, 54, 99, 0.14);
  overflow: hidden;
}

.home-page .site-header::before {
  content: "";
  position: absolute;
  top: -80px;
  right: -70px;
  width: 240px;
  height: 240px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(28, 122, 230, 0.26) 0%, rgba(28, 122, 230, 0) 72%);
  animation: driftGlow 8s ease-in-out infinite;
}

.home-page .site-header::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, rgba(80, 118, 172, 0.05) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(80, 118, 172, 0.04) 1px, transparent 1px);
  background-size: 26px 26px;
  opacity: 0.36;
  pointer-events: none;
}

.home-page .site-header > * {
  position: relative;
  z-index: 1;
}

.home-page .brand {
  border: 1px solid rgba(41, 104, 195, 0.28);
  color: #1b4f97;
  background: linear-gradient(140deg, rgba(219, 237, 255, 0.96), rgba(227, 250, 243, 0.96));
}

.home-page .hero-title {
  margin-top: 16px;
  color: #12284a;
  text-wrap: balance;
}

.home-page .hero-subtitle {
  margin-top: 12px;
  max-width: 760px;
  color: #435d83;
  line-height: 1.6;
}

.home-page .nav-row {
  margin-top: 20px;
  gap: 11px;
}

.home-page .nav-row .btn {
  border-width: 1px;
  border-style: solid;
  box-shadow: 0 10px 22px rgba(25, 61, 112, 0.16);
}

.home-page .btn-primary {
  border-color: rgba(27, 91, 192, 0.36);
  background: linear-gradient(140deg, #1e6eea, #1a54b9);
}

.home-page .btn-secondary {
  border-color: rgba(24, 133, 100, 0.34);
  background: linear-gradient(140deg, #dcf7ef, #c8efe1);
}

.home-page .btn-neutral {
  border-color: rgba(138, 161, 198, 0.45);
  background: linear-gradient(140deg, #f6f9ff, #ebf2ff);
}

.home-page .btn-availability {
  color: #ffffff;
  border-color: rgba(198, 95, 23, 0.44);
  background: linear-gradient(140deg, #ff8a00, #e65000);
  box-shadow: 0 12px 24px rgba(201, 79, 12, 0.3);
}

.home-page .card {
  border-color: #cfe0f6;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(242, 248, 255, 0.9));
  box-shadow: 0 16px 36px rgba(18, 50, 97, 0.11);
  transition: transform 220ms ease, box-shadow 220ms ease, border-color 220ms ease;
}

.home-page .card:hover {
  transform: translateY(-4px);
  border-color: #b4cdee;
  box-shadow: 0 24px 46px rgba(16, 47, 92, 0.16);
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0;
  background:
    radial-gradient(circle at 0% 0%, rgba(31, 111, 235, 0.16), transparent 38%),
    linear-gradient(180deg, rgba(241, 246, 255, 0.6), rgba(248, 251, 255, 0.85));
  transition: opacity 220ms ease;
  z-index: 1600;
}

body.page-enter-start {
  opacity: 0;
  transform: translateY(10px) scale(0.995);
  filter: blur(2px);
}

body.page-leaving {
  opacity: 0;
  transform: translateY(-8px) scale(0.995);
  filter: blur(2px);
}

body.page-leaving::after {
  opacity: 1;
}

@media (prefers-reduced-motion: reduce) {
  body,
  body::after {
    transition: none !important;
  }
}

/* Old widget styles removed — see revamped widget section below */

.page-wrap {
  max-width: var(--container);
  margin: 0 auto;
  padding: 28px 18px 56px;
}

.site-header {
  margin-bottom: 28px;
  animation: fadeUp 500ms ease both;
}

.brand {
  display: inline-block;
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #1a4fa3;
  background: rgba(31, 111, 235, 0.11);
}

h1, h2, h3 {
  font-family: "Fraunces", Georgia, serif;
  line-height: 1.1;
  margin: 0;
}

.hero-title {
  margin-top: 14px;
  font-size: clamp(2rem, 5.2vw, 3.2rem);
  color: #14213a;
}

.hero-subtitle {
  margin: 10px 0 0;
  color: var(--text-muted);
  max-width: 740px;
  font-size: 1.05rem;
}

.nav-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 18px;
}

.card {
  background: linear-gradient(180deg, var(--bg-surface), var(--bg-elevated));
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  padding: 24px;
  animation: fadeUp 520ms ease both;
}

.card h2 {
  font-size: 1.7rem;
  color: #16284a;
}

.card-subtitle {
  margin-top: 8px;
  color: var(--text-muted);
  font-size: 0.94rem;
}

.span-7 { grid-column: span 7; }
.span-5 { grid-column: span 5; }
.span-12 { grid-column: span 12; }

.card-grid > .card:nth-child(2) {
  animation-delay: 80ms;
}

.card-grid > .card:nth-child(3) {
  animation-delay: 160ms;
}

.form-stack {
  margin-top: 18px;
  display: grid;
  gap: 14px;
}

.field-grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

label {
  display: block;
  margin-bottom: 6px;
  color: #304360;
  font-size: 0.84rem;
  font-weight: 700;
  letter-spacing: 0.01em;
}

input,
select,
textarea,
button,
a.btn {
  font: inherit;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid #c7d2e4;
  border-radius: var(--radius-sm);
  padding: 11px 12px;
  color: var(--text-main);
  background: #ffffff;
  transition: border-color 150ms ease, box-shadow 150ms ease, background 150ms ease;
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: #3f80e2;
  box-shadow: 0 0 0 4px rgba(31, 111, 235, 0.16);
}

.btn,
button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  padding: 11px 18px;
  text-decoration: none;
  font-weight: 700;
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.btn:focus-visible,
button:focus-visible {
  outline: none;
  box-shadow: 0 0 0 4px rgba(31, 111, 235, 0.25);
}

.btn:hover,
button:hover {
  transform: translateY(-1px);
}

.btn[disabled],
button[disabled] {
  opacity: 0.7;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.btn-primary {
  color: #ffffff;
  background: linear-gradient(140deg, var(--brand), var(--brand-strong));
  box-shadow: 0 10px 20px rgba(31, 111, 235, 0.28);
}

.btn-secondary {
  color: #194f40;
  background: linear-gradient(140deg, #d9f5eb, #c5ecdc);
  border: 1px solid #aee2cd;
}

.btn-neutral {
  color: #243854;
  background: #edf2fb;
  border: 1px solid #dae3f2;
}

.btn-danger {
  color: #ffffff;
  background: linear-gradient(140deg, #d64d69, #be3152);
}

@keyframes buttonFlashGreen {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(26, 180, 109, 0.34);
  }
  50% {
    box-shadow: 0 0 0 8px rgba(26, 180, 109, 0);
  }
}

@keyframes buttonFlashRed {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(212, 46, 75, 0.34);
  }
  50% {
    box-shadow: 0 0 0 8px rgba(212, 46, 75, 0);
  }
}

.btn-approve-all {
  color: #ffffff;
  border: 1px solid #31b47a;
  background: linear-gradient(140deg, #1fb469, #158e59);
  animation: buttonFlashGreen 1.7s ease-in-out infinite;
}

.btn-disapprove-all {
  color: #ffffff;
  border: 1px solid #d93f5f;
  background: linear-gradient(140deg, #dc3558, #b71e41);
  animation: buttonFlashRed 1.7s ease-in-out infinite;
}

.btn-wide,
button.btn-wide {
  width: 100%;
}

.panel {
  background: #f8fbff;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-md);
  padding: 14px;
}

.panel-title {
  margin-bottom: 10px;
  font-size: 1.12rem;
  color: #1d3153;
}

.message {
  margin-top: 12px;
  border-radius: 12px;
  border: 1px solid transparent;
  padding: 10px 12px;
  font-size: 0.92rem;
}

.message:empty {
  display: none;
}

.message.info {
  background: #e9f2ff;
  border-color: #b8d3fb;
  color: #17468d;
}

.message.success {
  background: #eafaf3;
  border-color: #b8e8d0;
  color: #1c6c4d;
}

.message.error {
  background: #ffedf2;
  border-color: #f4b8c7;
  color: #982142;
}

.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.kicker {
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #476085;
  margin-bottom: 4px;
}

.badge {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 4px 9px;
  font-size: 0.78rem;
  font-weight: 700;
  color: #19553f;
  background: #d9f5eb;
}

.simple-list {
  display: grid;
  gap: 10px;
}

.record {
  border: 1px solid var(--line-soft);
  border-left: 4px solid #76a1e9;
  background: #ffffff;
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  animation: fadeUp 380ms ease both;
}

.record.highlight {
  border-left-color: #0e9f6e;
  background: #f0fcf7;
}

.record-title {
  font-weight: 800;
  color: #1c3258;
}

.record-meta {
  color: var(--text-muted);
  font-size: 0.88rem;
  margin-top: 3px;
}

.table-shell {
  width: 100%;
  overflow-x: auto;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-md);
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 780px;
}

th,
td {
  padding: 12px;
  border-bottom: 1px solid #e4eaf5;
  text-align: left;
  font-size: 0.92rem;
}

th {
  color: #324766;
  background: #eff4fc;
  font-weight: 800;
}

td {
  color: #1f324f;
}

.mobile-cards {
  display: none;
  gap: 10px;
}

.mobile-card {
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-sm);
  background: #ffffff;
  padding: 10px;
}

.mobile-card .row {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  font-size: 0.88rem;
  padding: 3px 0;
}

.mobile-card .row span:first-child {
  color: var(--text-muted);
}

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

.pagination-row {
  margin-top: 12px;
  align-items: center;
  justify-content: flex-end;
}

.lookup-input-wrap {
  position: relative;
  width: min(360px, 100%);
}

.lookup-input-wrap input {
  max-width: 100% !important;
}

.lookup-suggestions {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  z-index: 1400;
  border: 1px solid #c6d8f2;
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 14px 24px rgba(18, 46, 89, 0.18);
  overflow: hidden;
}

.lookup-suggestion-item {
  width: 100%;
  border: none;
  border-bottom: 1px solid #e4ebf7;
  background: #ffffff;
  color: #1f3556;
  text-align: left;
  padding: 10px 11px;
  cursor: pointer;
  font-size: 0.88rem;
}

.lookup-suggestion-item:last-child {
  border-bottom: none;
}

.lookup-suggestion-item:hover,
.lookup-suggestion-item:focus-visible {
  background: #eef4ff;
  outline: none;
}

.lookup-result-card {
  border: 1px solid #c2d6f2;
  background: linear-gradient(165deg, #ffffff, #f3f8ff);
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.lookup-result-card:hover {
  transform: translateY(-2px);
  border-color: #88b2ea;
  box-shadow: 0 14px 24px rgba(27, 62, 113, 0.16);
}

.lookup-result-head {
  align-items: center;
}

.lookup-result-actions {
  margin-top: 10px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.lookup-collapsible {
  margin-top: 10px;
}

.lookup-collapsible[hidden] {
  display: none !important;
}

.skeleton {
  border-radius: 10px;
  background: linear-gradient(100deg, #edf2fb 20%, #e0e9f8 40%, #edf2fb 60%);
  background-size: 200% 100%;
  animation: shimmer 1.15s linear infinite;
}

.skeleton-line {
  height: 12px;
  margin-top: 8px;
}

.skeleton-line:first-child {
  margin-top: 0;
}

.skeleton-line.short {
  width: 42%;
}

.skeleton-line.mid {
  width: 68%;
}

.skeleton-record {
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-sm);
  background: #ffffff;
  padding: 10px 12px;
}

.empty-state {
  border: 1px dashed #bfd0ea;
  border-radius: var(--radius-md);
  background: #f4f8ff;
  padding: 14px;
}

.empty-title {
  font-weight: 800;
  color: #28426a;
}

.empty-copy {
  margin-top: 4px;
  color: #5f7291;
  font-size: 0.9rem;
}

.interactive-info-panel {
  position: relative;
  background: linear-gradient(145deg, #eaf3ff, #eafcf5);
  border: 1px solid #bfd5f0;
  overflow: hidden;
}

.interactive-info-panel::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 102% 6%, rgba(31, 111, 235, 0.2), transparent 36%),
    radial-gradient(circle at -2% 102%, rgba(19, 165, 117, 0.2), transparent 34%);
}

.interactive-info-panel > * {
  position: relative;
  z-index: 1;
}

.hint-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 10px;
}

.hint-card {
  --hint-accent: #2d71dd;
  position: relative;
  border: 1px solid #c8d8f2;
  background: linear-gradient(180deg, #ffffff, #f4f8ff);
  border-radius: 14px;
  padding: 12px;
  text-align: left;
  cursor: pointer;
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease, background 180ms ease;
}

.hint-card:nth-child(2) {
  --hint-accent: #1c9e78;
}

.hint-card:nth-child(3) {
  --hint-accent: #d08b2c;
}

.hint-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 12px;
  right: 12px;
  height: 3px;
  border-radius: 0 0 999px 999px;
  background: var(--hint-accent);
  opacity: 0.6;
  transition: opacity 180ms ease;
}

.hint-card:hover {
  transform: translateY(-3px);
  border-color: #7aa7e9;
  box-shadow: 0 14px 24px rgba(34, 72, 127, 0.15);
}

.hint-card:hover::before {
  opacity: 1;
}

.hint-card.active {
  border-color: var(--hint-accent);
  background: linear-gradient(180deg, #ffffff, #eef4ff);
  box-shadow: 0 0 0 2px rgba(31, 111, 235, 0.16) inset, 0 14px 22px rgba(31, 68, 123, 0.14);
}

.hint-title {
  margin-top: 2px;
  font-weight: 700;
  color: #17396e;
  font-size: 0.92rem;
}

.hint-summary {
  margin-top: 6px;
  color: #5a7194;
  font-size: 0.79rem;
  line-height: 1.45;
}

.hint-detail {
  margin-top: 12px;
  border-radius: 12px;
  background: linear-gradient(130deg, #ffffff, #f5f9ff);
  border: 1px solid #c8d8f2;
  border-left: 4px solid #2f73df;
  box-shadow: 0 10px 20px rgba(32, 67, 118, 0.12);
  padding: 12px 14px;
  color: #26456e;
  font-size: 0.9rem;
  line-height: 1.5;
}

.hint-detail.is-updating {
  animation: detailReveal 260ms ease;
}

.hero-title-splash {
  background: linear-gradient(135deg, #0e3f82 0%, #1e6eea 42%, #149972 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 7px 16px rgba(23, 77, 149, 0.2));
  transition: transform 180ms ease, filter 180ms ease;
}

.hero-interactive-row {
  margin-top: 12px;
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}

.hero-chip {
  border: 1px solid #b4cbeb;
  border-radius: 999px;
  padding: 7px 12px;
  background: linear-gradient(140deg, #f4f9ff, #e9f2ff);
  color: #1f4e8e;
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.hero-chip-soft {
  border-color: #bce2d4;
  color: #1f6e57;
  background: linear-gradient(140deg, #f0fff9, #e2f7ee);
}

body.home-page.theme-dark {
  color: #e6eef9;
  background:
    radial-gradient(circle at 8% 0%, rgba(65, 138, 239, 0.22), transparent 36%),
    radial-gradient(circle at 88% 12%, rgba(0, 180, 140, 0.19), transparent 34%),
    linear-gradient(180deg, #0c1526 0%, #101b31 48%, #0f1b2f 100%);
}

body.home-page.theme-dark .site-header {
  border-color: #2b4f7a;
  background: linear-gradient(155deg, rgba(22, 34, 58, 0.96), rgba(18, 40, 64, 0.92));
  box-shadow: 0 26px 52px rgba(3, 8, 19, 0.55);
}

body.home-page.theme-dark .site-header::after {
  opacity: 0.22;
}

body.home-page.theme-dark .brand {
  border-color: rgba(96, 140, 199, 0.52);
  color: #a7cbff;
  background: linear-gradient(140deg, rgba(25, 49, 85, 0.96), rgba(20, 65, 74, 0.94));
}

body.home-page.theme-dark .hero-title-splash {
  background: linear-gradient(135deg, #89c7ff 0%, #6a8dff 45%, #58e9cb 100%);
  -webkit-background-clip: text;
  background-clip: text;
}

body.home-page.theme-dark .hero-subtitle {
  color: #bbcee9;
}

body.home-page.theme-dark .hero-chip {
  border-color: #446996;
  background: linear-gradient(140deg, #1f3458, #223960);
  color: #c7daf6;
}

body.home-page.theme-dark .hero-chip-soft {
  border-color: #2f6f67;
  background: linear-gradient(140deg, #193f43, #20474f);
  color: #b9ede4;
}

body.home-page.theme-dark .card,
body.home-page.theme-dark .panel,
body.home-page.theme-dark .record,
body.home-page.theme-dark .mobile-card,
body.home-page.theme-dark .empty-state {
  border-color: #2d4f79;
  background: linear-gradient(175deg, rgba(24, 39, 64, 0.94), rgba(20, 34, 56, 0.9));
  color: #deebff;
}

body.home-page.theme-dark h1,
body.home-page.theme-dark h2,
body.home-page.theme-dark h3,
body.home-page.theme-dark .record-title {
  color: #e3efff;
}

body.home-page.theme-dark .kicker,
body.home-page.theme-dark .card-subtitle,
body.home-page.theme-dark .record-meta,
body.home-page.theme-dark .empty-copy,
body.home-page.theme-dark .empty-title,
body.home-page.theme-dark label {
  color: #b8cae4;
}

body.home-page.theme-dark input,
body.home-page.theme-dark select,
body.home-page.theme-dark textarea {
  border-color: #3b5e87;
  background: #15263f;
  color: #e3efff;
}

body.home-page.theme-dark .btn-neutral {
  border-color: #4c6c97;
  background: linear-gradient(140deg, #263f63, #2f4a73);
  color: #d3e3fa;
}

body.home-page.theme-dark .btn-secondary {
  border-color: #3f8d7c;
  background: linear-gradient(140deg, #254b4d, #2e6460);
  color: #d8fff3;
}

body.home-page.theme-dark .btn-primary {
  border-color: #4f6fde;
  background: linear-gradient(140deg, #3356cf, #2e48ad);
}

body.home-page.theme-dark .btn-availability {
  border-color: #f49b50;
  background: linear-gradient(140deg, #ff9f1a, #ff6d00);
}

body.home-page.theme-dark .availability-day.available {
  border-color: #2d7d5f;
  background: linear-gradient(165deg, #163f43, #1d524b);
}

body.home-page.theme-dark .availability-day.unavailable {
  border-color: #8a5f36;
  background: linear-gradient(165deg, #3e2f1d, #4a341f);
}

.label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.label-row label {
  margin-bottom: 0;
}

.mini-toggle {
  border-radius: 999px;
  border: 1px solid #bfd4f4;
  background: linear-gradient(140deg, #f3f8ff, #e9f1ff);
  color: #244f8b;
  padding: 4px 10px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.03em;
}

.mini-toggle.active {
  border-color: #2c73de;
  background: linear-gradient(140deg, #ddedff, #cfe3ff);
  color: #174687;
}

.input-hint {
  margin-top: 6px;
  color: #506584;
  font-size: 0.8rem;
}

.split-input-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.availability-list {
  display: grid;
  gap: 10px;
  margin-top: 10px;
}

.availability-day {
  border: 1px solid #c6d8f2;
  border-radius: 12px;
  background: linear-gradient(165deg, #ffffff, #f3f8ff);
  padding: 10px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.availability-day.available {
  border-color: #a9dfc7;
  background: linear-gradient(165deg, #f0fff8, #eafaf2);
}

.availability-day.unavailable {
  border-color: #e6d0aa;
  background: linear-gradient(165deg, #fff9ef, #fff4e4);
}

.availability-day-title {
  font-weight: 800;
  color: #1a365f;
}

.availability-day-meta {
  color: #5e7291;
  font-size: 0.84rem;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 4px 9px;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.status-pill.pending {
  background: #edf2fb;
  border: 1px solid #cfd8ea;
  color: #3a5377;
}

.status-pill.approved {
  background: #dff8ea;
  border: 1px solid #a5ddbc;
  color: #1d6c4c;
}

.status-pill.disapproved {
  background: #fdecef;
  border: 1px solid #efbcc6;
  color: #99314a;
}

.appointment-actions {
  margin-top: 10px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.appointment-actions .btn {
  padding: 8px 14px;
  font-size: 0.82rem;
}

.appointment-note-input {
  border: 1px solid #bfd4f1;
  background: #f7fbff;
  color: #204262;
}

.appointment-section {
  margin-top: 10px;
  border: 1px solid #cfe0f7;
  border-radius: 14px;
  background: linear-gradient(175deg, #f8fcff, #f3f9ff);
  padding: 10px;
}

.appointment-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}

.appointment-section-title {
  margin: 0;
  font-size: 1rem;
  color: #213f68;
}

.reviewed-list .record {
  border-left-color: #8f8fa4;
  background: #f8f9fd;
}

.reviewed-note {
  margin-top: 6px;
  color: #445978;
}

.doctor-availability-grid {
  display: grid;
  gap: 10px;
  margin-top: 8px;
}

.doctor-availability-row {
  border: 1px solid #c4d7f1;
  border-radius: 12px;
  padding: 10px 12px;
  background: linear-gradient(165deg, #ffffff, #f3f8ff);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.doctor-availability-row.available {
  border-color: #a6debf;
  background: linear-gradient(165deg, #effff7, #e8f9f0);
}

.doctor-availability-row.unavailable {
  border-color: #f1d2a8;
  background: linear-gradient(165deg, #fffbf2, #fff5e7);
}

.doctor-availability-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.86rem;
  color: #294465;
}

.doctor-page {
  background:
    radial-gradient(circle at 6% -8%, rgba(43, 123, 221, 0.2), transparent 32%),
    radial-gradient(circle at 95% 2%, rgba(16, 166, 121, 0.16), transparent 30%),
    linear-gradient(180deg, #eef4ff 0%, #f7fbff 100%);
}

.doctor-page-wrap {
  max-width: 1560px;
}

.doctor-page .site-header {
  position: relative;
  border: 1px solid #ccdcf4;
  border-radius: 26px;
  padding: 20px 22px;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.96), rgba(235, 246, 255, 0.9));
  box-shadow: 0 18px 40px rgba(22, 52, 95, 0.14);
  overflow: hidden;
}

.doctor-page .site-header::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, rgba(70, 102, 149, 0.05) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(70, 102, 149, 0.05) 1px, transparent 1px);
  background-size: 22px 22px;
  pointer-events: none;
}

.doctor-page .site-header > * {
  position: relative;
  z-index: 1;
}

.doctor-page .btn,
.doctor-page button {
  transition: transform 180ms ease, box-shadow 180ms ease, filter 180ms ease;
}

.doctor-page .btn:hover,
.doctor-page button:hover {
  transform: translateY(-2px) scale(1.01);
  box-shadow: 0 14px 24px rgba(21, 58, 108, 0.2);
  filter: saturate(1.06);
}

.doctor-greeting-panel {
  min-width: 250px;
  border: 1px solid #bfd4f2;
  border-radius: 14px;
  padding: 10px 12px;
  background: linear-gradient(135deg, rgba(225, 241, 255, 0.9), rgba(224, 251, 239, 0.9));
}

.doctor-time-greeting {
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
  color: #245598;
}

.doctor-personal-ask {
  margin-top: 4px;
  font-weight: 700;
  color: #17466f;
}

.doctor-tools-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.doctor-workspace-grid {
  margin: 12px -10px 0;
  width: calc(100% + 20px);
  display: grid;
  grid-template-columns: minmax(220px, 0.7fr) minmax(700px, 2.5fr) minmax(220px, 0.7fr);
  gap: 14px;
  align-items: start;
}

.doctor-column {
  min-height: 100%;
}

.doctor-appointments-column .simple-list {
  overflow-y: auto;
  overflow-x: hidden;
  padding-right: 3px;
  scrollbar-width: thin;
}

.doctor-middle-column .section-head,
.doctor-middle-column .empty-state,
.doctor-middle-column > .simple-list > .empty-state {
  text-align: center;
}

.doctor-middle-column .section-head {
  justify-content: center;
  flex-direction: column;
  align-items: center;
}

.doctor-middle-column .section-head > div {
  text-align: center;
  width: 100%;
}

.doctor-middle-column .kicker {
  text-align: center;
}

.doctor-middle-column .panel-title {
  text-align: center;
}

.doctor-middle-column .doctor-tools-grid {
  grid-template-columns: 1fr;
}

#appointments-summary {
  margin-top: 2px;
}

.prescription-tool-panel {
  min-height: 100%;
  background: linear-gradient(165deg, #fbfdff, #f2f8ff);
  border: 1px solid #c6d9f3;
}

.doctor-context-card {
  border-left-color: #1f6feb;
  background: linear-gradient(150deg, #f4f9ff, #f0fbf6);
}

.doctor-translate-actions {
  gap: 8px;
}

.doctor-translate-actions .btn {
  min-width: 130px;
}

.doctor-toast-stack {
  position: fixed;
  right: 16px;
  bottom: 18px;
  z-index: 1300;
  display: grid;
  gap: 8px;
}

.doctor-toast {
  transform: translateY(8px);
  opacity: 0;
  min-width: 260px;
  max-width: 360px;
  padding: 11px 12px;
  border-radius: 12px;
  border: 1px solid #b9d4f8;
  background: #edf5ff;
  color: #1b4f92;
  box-shadow: 0 14px 26px rgba(20, 50, 92, 0.24);
  transition: transform 180ms ease, opacity 180ms ease;
}

.doctor-toast.success {
  border-color: #9eddbc;
  background: #eafaf2;
  color: #1e6e4d;
}

.doctor-toast.error {
  border-color: #f2bac7;
  background: #ffeef3;
  color: #9a2442;
}

.doctor-toast.show {
  transform: translateY(0);
  opacity: 1;
}

.doctor-modal {
  position: fixed;
  inset: 0;
  z-index: 1400;
  display: grid;
  place-items: center;
  padding: 18px;
}

.doctor-modal[hidden] {
  display: none !important;
}

.doctor-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(8, 17, 31, 0.44);
  backdrop-filter: blur(2px);
}

.doctor-modal-card {
  position: relative;
  width: min(520px, 96vw);
  border: 1px solid #c8daf2;
  border-radius: 16px;
  background: linear-gradient(170deg, #ffffff, #f3f8ff);
  box-shadow: 0 24px 48px rgba(15, 35, 66, 0.26);
  padding: 18px;
}

.doctor-modal-card h3 {
  margin: 0;
  font-size: 1.2rem;
  color: #193b66;
}

.doctor-modal-card p {
  margin: 10px 0 14px;
  color: #405c83;
}

/* Global dark mode for all pages (home/admin/doctor) */
body.theme-dark {
  color: #e6eef9;
  background:
    radial-gradient(circle at 8% 0%, rgba(65, 138, 239, 0.22), transparent 36%),
    radial-gradient(circle at 88% 12%, rgba(0, 180, 140, 0.19), transparent 34%),
    linear-gradient(180deg, #0c1526 0%, #101b31 48%, #0f1b2f 100%);
}

body.theme-dark .site-header {
  border-color: #2b4f7a;
  background: linear-gradient(155deg, rgba(22, 34, 58, 0.96), rgba(18, 40, 64, 0.92));
  box-shadow: 0 26px 52px rgba(3, 8, 19, 0.55);
}

body.theme-dark .site-header::after {
  opacity: 0.22;
}

body.theme-dark .brand {
  border-color: rgba(96, 140, 199, 0.52);
  color: #c0d9ff;
  background: linear-gradient(140deg, rgba(25, 49, 85, 0.96), rgba(20, 65, 74, 0.94));
}

body.theme-dark .hero-title,
body.theme-dark h1,
body.theme-dark h2,
body.theme-dark h3,
body.theme-dark .record-title,
body.theme-dark th,
body.theme-dark td {
  color: #e6efff;
}

body.theme-dark .hero-title-splash {
  background: linear-gradient(135deg, #89c7ff 0%, #6a8dff 45%, #58e9cb 100%);
  -webkit-background-clip: text;
  background-clip: text;
}

body.theme-dark .kicker,
body.theme-dark .card-subtitle,
body.theme-dark .record-meta,
body.theme-dark .empty-copy,
body.theme-dark .empty-title,
body.theme-dark label,
body.theme-dark .doctor-time-greeting,
body.theme-dark .doctor-personal-ask,
body.theme-dark .availability-day-meta,
body.theme-dark .lookup-suggestion-item,
body.theme-dark .message {
  color: #bfd0ea;
}

body.theme-dark .card,
body.theme-dark .panel,
body.theme-dark .record,
body.theme-dark .mobile-card,
body.theme-dark .empty-state,
body.theme-dark .table-shell {
  border-color: #2f5079;
  background: linear-gradient(175deg, rgba(24, 39, 64, 0.94), rgba(20, 34, 56, 0.9));
  color: #deebff;
}

body.theme-dark .record.highlight {
  border-left-color: #2db782;
  background: linear-gradient(175deg, rgba(18, 50, 58, 0.9), rgba(15, 44, 52, 0.92));
}

body.theme-dark .reviewed-list .record {
  border-left-color: #6786b4;
}

body.theme-dark .table-shell {
  border-color: #31537d;
}

body.theme-dark th {
  background: #1d314f;
  border-bottom-color: #33557d;
}

body.theme-dark td {
  border-bottom-color: #2e4d74;
}

body.theme-dark input,
body.theme-dark select,
body.theme-dark textarea {
  border-color: #43638d;
  background: #15263f;
  color: #e3efff;
}

body.theme-dark input::placeholder,
body.theme-dark textarea::placeholder {
  color: #98afcc;
}

body.theme-dark .btn-neutral {
  border-color: #4f6f99;
  background: linear-gradient(140deg, #2a4368, #324f79);
  color: #dbe8ff;
}

body.theme-dark .btn-secondary {
  border-color: #429784;
  background: linear-gradient(140deg, #285350, #336c67);
  color: #dcfff5;
}

body.theme-dark .btn-primary {
  border-color: #5c7af0;
  background: linear-gradient(140deg, #3f61e2, #3550bb);
  color: #ffffff;
}

body.theme-dark .btn-danger {
  border-color: #d85672;
  background: linear-gradient(140deg, #c63758, #a8203f);
  color: #fff3f6;
}

body.theme-dark .btn-availability {
  border-color: #ffa757;
  background: linear-gradient(140deg, #ff9f1a, #ff6d00);
  color: #ffffff;
}

body.theme-dark .btn-approve-all {
  border-color: #40cd8d;
  background: linear-gradient(140deg, #2bbd75, #1b8f5b);
}

body.theme-dark .btn-disapprove-all {
  border-color: #f06a87;
  background: linear-gradient(140deg, #d83d61, #ad2143);
}

body.theme-dark .doctor-greeting-panel,
body.theme-dark .doctor-context-card,
body.theme-dark .appointment-section,
body.theme-dark .doctor-modal-card,
body.theme-dark .doctor-availability-row,
body.theme-dark .availability-day,
body.theme-dark .lookup-result-card {
  border-color: #3a5f8c;
  background: linear-gradient(170deg, rgba(30, 49, 78, 0.92), rgba(22, 38, 63, 0.9));
}

body.theme-dark .lookup-suggestions {
  border-color: #40638e;
  background: #132640;
  box-shadow: 0 14px 24px rgba(0, 7, 17, 0.48);
}

body.theme-dark .lookup-suggestion-item {
  background: #132640;
  border-bottom-color: #315174;
}

body.theme-dark .lookup-suggestion-item:hover,
body.theme-dark .lookup-suggestion-item:focus-visible {
  background: #1d3658;
}

body.theme-dark .badge {
  border: 1px solid #3d8d7a;
  background: linear-gradient(140deg, #1f4d4a, #2a5f5a);
  color: #d6fff2;
}

body.theme-dark .message.info {
  background: #1a3155;
  border-color: #3f6393;
  color: #cbe0ff;
}

body.theme-dark .message.success {
  background: #183d39;
  border-color: #3f8b77;
  color: #cdf7eb;
}

body.theme-dark .message.error {
  background: #4a1f2f;
  border-color: #a14e67;
  color: #ffdbe5;
}

body.theme-dark .status-pill.pending {
  background: #2a3d5f;
  border-color: #4c6f9f;
  color: #d7e7ff;
}

body.theme-dark .status-pill.approved {
  background: #1e5042;
  border-color: #4ab08b;
  color: #d9fff2;
}

body.theme-dark .status-pill.disapproved {
  background: #59253a;
  border-color: #be5f79;
  color: #ffdbe6;
}

body.theme-dark .skeleton {
  background: linear-gradient(100deg, #203553 20%, #2a4368 40%, #203553 60%);
}

body.theme-dark .doctor-toast {
  border-color: #4f6f99;
  background: #213956;
  color: #d7e8ff;
}

body.theme-dark .doctor-toast.success {
  border-color: #4aa889;
  background: #1f4a43;
  color: #d8fff1;
}

body.theme-dark .doctor-toast.error {
  border-color: #be5f79;
  background: #5a263b;
  color: #ffdce7;
}

body.theme-dark .doctor-modal-card h3 {
  color: #e7f0ff;
}

body.theme-dark .doctor-modal-card p {
  color: #c5d8f5;
}

body.theme-dark .lang-time-widget {
  border-color: #3b5f8b;
  background: rgba(16, 30, 50, 0.9);
  box-shadow: 0 14px 28px rgba(4, 10, 24, 0.52);
}

body.theme-dark .lang-time-row label,
body.theme-dark .lang-time-meta {
  color: #bdd3f3;
}

body.theme-dark .mini-toggle {
  border-color: #4e70a0;
  background: linear-gradient(140deg, #263f63, #2f4a73);
  color: #d4e6ff;
}

body.theme-dark .mini-toggle.active {
  border-color: #6b90d4;
  background: linear-gradient(140deg, #345a8b, #3f6ba5);
  color: #eef5ff;
}

body.theme-dark .input-hint {
  color: #9bb2d1;
}

body.theme-dark .availability-day.available,
body.theme-dark .doctor-availability-row.available {
  border-color: #3f8f78;
  background: linear-gradient(165deg, #1a4a45, #1f524b);
}

body.theme-dark .availability-day.unavailable,
body.theme-dark .doctor-availability-row.unavailable {
  border-color: #9d7848;
  background: linear-gradient(165deg, #4a3822, #5b4228);
}

body.theme-dark .availability-day-title,
body.theme-dark .doctor-availability-row .record-title {
  color: #edf5ff;
  font-weight: 800;
}

body.theme-dark .availability-day-meta,
body.theme-dark .doctor-availability-row .record-meta {
  color: #d8e6fb;
}

@media (max-width: 1040px) {
  .span-7,
  .span-5 {
    grid-column: span 12;
  }

  .doctor-tools-grid {
    grid-template-columns: 1fr;
  }

  .doctor-workspace-grid {
    margin: 12px 0 0;
    width: 100%;
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .lang-time-widget {
    position: static;
    margin: 10px auto 0;
    min-width: 0;
    max-width: 400px;
    border-radius: 14px;
  }

  .site-header {
    padding-right: 0;
  }

  .page-wrap {
    padding-top: 20px;
  }

  .card {
    padding: 18px;
    border-radius: 18px;
  }

  .field-grid-2 {
    grid-template-columns: 1fr;
  }

  .hint-card-grid {
    grid-template-columns: 1fr;
  }

  .section-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .table-shell {
    display: none;
  }

  .mobile-cards {
    display: grid;
  }
}

/* ========================================
   TASK 4: Global Theme Toggle – Top-Left
   ======================================== */
.global-theme-toggle {
  position: fixed;
  top: 16px;
  left: 16px;
  z-index: 1500;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 2px solid rgba(31, 111, 235, 0.3);
  background: linear-gradient(145deg, rgba(255,255,255,0.95), rgba(237,246,255,0.9));
  box-shadow: 0 8px 24px rgba(16, 24, 40, 0.18), 0 0 0 0 rgba(31, 111, 235, 0);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  transition: transform 280ms cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 280ms ease, border-color 280ms ease, background 280ms ease;
  backdrop-filter: blur(12px);
}

.global-theme-toggle:hover {
  transform: translateY(-2px) scale(1.1);
  box-shadow: 0 12px 32px rgba(16, 24, 40, 0.24), 0 0 0 4px rgba(31, 111, 235, 0.12);
  border-color: rgba(31, 111, 235, 0.5);
}

.global-theme-toggle:active {
  transform: scale(0.92);
}

.theme-toggle-icon {
  font-size: 22px;
  line-height: 1;
  transition: transform 400ms cubic-bezier(0.34, 1.56, 0.64, 1);
  display: block;
}

.global-theme-toggle:hover .theme-toggle-icon {
  transform: rotate(-20deg) scale(1.15);
}

body.theme-dark .global-theme-toggle {
  border-color: rgba(250, 204, 21, 0.4);
  background: linear-gradient(145deg, rgba(15, 23, 42, 0.95), rgba(30, 41, 59, 0.9));
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4), 0 0 20px rgba(250, 204, 21, 0.08);
}

body.theme-dark .global-theme-toggle:hover {
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.5), 0 0 30px rgba(250, 204, 21, 0.15);
  border-color: rgba(250, 204, 21, 0.6);
}

/* ========================================
   Floating Back Button – Below Theme Toggle
   ======================================== */
.global-back-btn {
  position: fixed;
  top: 76px;
  left: 16px;
  z-index: 1500;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 2px solid rgba(31, 111, 235, 0.3);
  background: linear-gradient(145deg, rgba(255,255,255,0.95), rgba(237,246,255,0.9));
  box-shadow: 0 8px 24px rgba(16, 24, 40, 0.18);
  backdrop-filter: blur(14px);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  transition: transform 320ms cubic-bezier(0.34, 1.56, 0.64, 1),
              box-shadow 320ms ease,
              border-color 320ms ease;
}

.global-back-btn:hover {
  transform: translateY(-2px) scale(1.1);
  box-shadow: 0 12px 32px rgba(16, 24, 40, 0.24), 0 0 0 4px rgba(31, 111, 235, 0.12);
  border-color: rgba(31, 111, 235, 0.5);
}

.global-back-btn:active {
  transform: scale(0.92);
}

.back-btn-icon {
  font-size: 22px;
  line-height: 1;
  color: var(--brand);
  transition: transform 400ms cubic-bezier(0.34, 1.56, 0.64, 1);
  display: block;
}

.global-back-btn:hover .back-btn-icon {
  transform: translateX(-3px);
}

body.theme-dark .global-back-btn {
  border-color: rgba(250, 204, 21, 0.4);
  background: linear-gradient(145deg, rgba(15, 23, 42, 0.95), rgba(30, 41, 59, 0.9));
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4), 0 0 20px rgba(250, 204, 21, 0.08);
}

body.theme-dark .global-back-btn:hover {
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.5), 0 0 30px rgba(250, 204, 21, 0.15);
  border-color: rgba(250, 204, 21, 0.6);
}

body.theme-dark .back-btn-icon {
  color: #facc15;
}

/* ========================================
   Login Page Visual Upgrades
   ======================================== */
.login-hero-card {
  position: relative;
  overflow: hidden;
  padding: 40px 32px 32px;
  border: 1px solid rgba(31, 111, 235, 0.15);
  background: linear-gradient(170deg,
    rgba(255,255,255,0.98) 0%,
    rgba(237,246,255,0.95) 40%,
    rgba(224,240,255,0.9) 100%);
  box-shadow:
    0 24px 56px rgba(16, 24, 40, 0.1),
    0 0 0 1px rgba(255,255,255,0.7) inset,
    0 0 80px rgba(31, 111, 235, 0.04);
}

.login-hero-card:hover {
  border-color: rgba(31, 111, 235, 0.25);
  box-shadow:
    0 32px 64px rgba(16, 24, 40, 0.14),
    0 0 0 1px rgba(255,255,255,0.7) inset,
    0 0 100px rgba(31, 111, 235, 0.06);
}

.login-decorative-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.login-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);
  opacity: 0.5;
  animation: loginOrbFloat 12s ease-in-out infinite;
}

.login-orb-1 {
  width: 200px;
  height: 200px;
  top: -60px;
  right: -40px;
  background: radial-gradient(circle, rgba(31, 111, 235, 0.3), transparent 70%);
}

.login-orb-2 {
  width: 160px;
  height: 160px;
  bottom: -40px;
  left: -30px;
  background: radial-gradient(circle, rgba(14, 159, 110, 0.25), transparent 70%);
  animation-delay: -6s;
}

@keyframes loginOrbFloat {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(10px, -15px) scale(1.05); }
  66% { transform: translate(-8px, 10px) scale(0.95); }
}

.login-icon-badge {
  position: absolute;
  top: 24px;
  right: 28px;
  width: 64px;
  height: 64px;
  border-radius: 20px;
  background: linear-gradient(135deg, rgba(31, 111, 235, 0.12), rgba(14, 159, 110, 0.08));
  border: 1px solid rgba(31, 111, 235, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 24px rgba(31, 111, 235, 0.1);
  animation: loginBadgeGlow 4s ease-in-out infinite;
}

.login-icon-emoji {
  font-size: 30px;
  line-height: 1;
}

.login-icon-svg {
  color: #4f6b96;
  opacity: 0.85;
}

[data-theme="dark"] .login-icon-svg {
  color: #93c5fd;
  opacity: 0.9;
}

@keyframes loginBadgeGlow {
  0%, 100% { box-shadow: 0 8px 24px rgba(31, 111, 235, 0.1); }
  50% { box-shadow: 0 8px 32px rgba(31, 111, 235, 0.2), 0 0 16px rgba(31, 111, 235, 0.08); }
}

.login-form-elevated {
  position: relative;
  z-index: 1;
}

.login-title {
  font-size: 1.9rem;
  background: linear-gradient(135deg, #0e3f82, #1e6eea);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  margin-bottom: 4px;
}

.login-subtitle {
  font-size: 0.92rem;
  color: var(--text-muted);
  margin: 0 0 8px;
  line-height: 1.5;
  position: relative;
  z-index: 1;
}

.btn-login-wide {
  width: 100%;
  padding: 14px 24px;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

/* Dark theme: Login cards */
body.theme-dark .login-hero-card {
  border-color: rgba(96, 165, 250, 0.2);
  background: linear-gradient(170deg,
    rgba(15, 23, 42, 0.98) 0%,
    rgba(20, 35, 58, 0.95) 40%,
    rgba(16, 30, 52, 0.92) 100%);
  box-shadow:
    0 24px 56px rgba(0, 0, 0, 0.35),
    0 0 0 1px rgba(255,255,255,0.04) inset,
    0 0 80px rgba(96, 165, 250, 0.03);
}

body.theme-dark .login-orb-1 {
  background: radial-gradient(circle, rgba(96, 165, 250, 0.2), transparent 70%);
}

body.theme-dark .login-orb-2 {
  background: radial-gradient(circle, rgba(52, 211, 153, 0.15), transparent 70%);
}

body.theme-dark .login-icon-badge {
  background: linear-gradient(135deg, rgba(96, 165, 250, 0.15), rgba(52, 211, 153, 0.08));
  border-color: rgba(96, 165, 250, 0.2);
}

body.theme-dark .login-title {
  background: linear-gradient(135deg, #89c7ff, #6a8dff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

body.theme-dark .login-subtitle {
  color: #8daed4;
}

/* ========================================
   TASK 3: Floating Transparent Quotes
   ======================================== */
.floating-quotes-container {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.floating-quote {
  position: absolute;
  font-family: "Merriweather", Georgia, serif;
  font-style: italic;
  font-weight: 900;
  color: rgba(31, 111, 235, 0.25);
  white-space: nowrap;
  user-select: none;
  animation: floatQuote linear infinite;
  text-shadow: 0 3px 16px rgba(31, 111, 235, 0.1);
}

body.theme-dark .floating-quote {
  color: rgba(147, 197, 253, 0.18);
  text-shadow: 0 3px 16px rgba(147, 197, 253, 0.06);
}

@keyframes floatQuote {
  0% {
    transform: translateY(0) rotate(var(--rotate, -3deg));
    opacity: 0;
  }
  8% {
    opacity: 1;
  }
  92% {
    opacity: 1;
  }
  100% {
    transform: translateY(calc(-100vh - 80px)) rotate(var(--rotate, -3deg));
    opacity: 0;
  }
}

/* ========================================
   TASK 5: Revamped Language / Time / Date Widget
   ======================================== */
.lang-time-widget {
  position: fixed;
  top: 14px;
  right: 14px;
  z-index: 1200;
  min-width: 240px;
  max-width: 290px;
  padding: 0;
  border-radius: 18px;
  border: 1px solid rgba(196, 210, 233, 0.6);
  background: linear-gradient(160deg, rgba(255,255,255,0.96), rgba(237,246,255,0.92));
  box-shadow: 0 16px 40px rgba(16, 24, 40, 0.14), 0 0 0 1px rgba(255,255,255,0.5) inset;
  backdrop-filter: blur(16px);
  overflow: hidden;
  transition: border-color 280ms ease, box-shadow 280ms ease, background 280ms ease;
}

.lang-time-widget:hover {
  border-color: rgba(31, 111, 235, 0.3);
  box-shadow: 0 20px 48px rgba(16, 24, 40, 0.18), 0 0 0 1px rgba(255,255,255,0.5) inset;
}

.lang-time-widget-header {
  padding: 10px 14px 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  border-bottom: 1px solid rgba(196, 210, 233, 0.5);
  background: linear-gradient(140deg, rgba(31, 111, 235, 0.06), rgba(14, 159, 110, 0.04));
}

.lang-time-widget-header label {
  margin: 0;
  font-size: 0.72rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: #476085;
  font-weight: 800;
}

.lang-time-widget-header select {
  width: auto;
  min-width: 110px;
  padding: 6px 10px;
  font-size: 0.84rem;
  border-radius: 10px;
  border: 1px solid rgba(31, 111, 235, 0.2);
  background: rgba(255, 255, 255, 0.9);
  font-weight: 600;
}

.lang-time-widget-body {
  padding: 10px 14px 12px;
  display: grid;
  gap: 6px;
}

.lang-time-stat {
  display: flex;
  align-items: center;
  gap: 10px;
}

.lang-time-stat-icon {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
}

.lang-time-stat-icon.time-icon {
  background: linear-gradient(140deg, rgba(31, 111, 235, 0.12), rgba(31, 111, 235, 0.06));
  color: #1f6feb;
}

.lang-time-stat-icon.date-icon {
  background: linear-gradient(140deg, rgba(14, 159, 110, 0.12), rgba(14, 159, 110, 0.06));
  color: #0e9f6e;
}

.lang-time-stat-content {
  flex: 1;
  min-width: 0;
}

.lang-time-stat-label {
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #6b7f9b;
  font-weight: 700;
  line-height: 1;
}

.lang-time-stat-value {
  font-size: 0.96rem;
  font-weight: 800;
  color: #1a365f;
  line-height: 1.3;
  letter-spacing: -0.01em;
}

body.theme-dark .lang-time-widget {
  border-color: rgba(59, 95, 139, 0.6);
  background: linear-gradient(160deg, rgba(15, 23, 42, 0.96), rgba(30, 41, 59, 0.92));
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(255,255,255,0.05) inset;
}

body.theme-dark .lang-time-widget-header {
  border-bottom-color: rgba(59, 95, 139, 0.4);
  background: linear-gradient(140deg, rgba(31, 111, 235, 0.08), rgba(14, 159, 110, 0.05));
}

body.theme-dark .lang-time-widget-header label {
  color: #8daed4;
}

body.theme-dark .lang-time-widget-header select {
  border-color: rgba(59, 95, 139, 0.5);
  background: rgba(15, 23, 42, 0.9);
  color: #e3efff;
}

body.theme-dark .lang-time-stat-label {
  color: #8daed4;
}

body.theme-dark .lang-time-stat-value {
  color: #e6efff;
}

body.theme-dark .lang-time-stat-icon.time-icon {
  background: linear-gradient(140deg, rgba(96, 165, 250, 0.15), rgba(96, 165, 250, 0.06));
  color: #60a5fa;
}

body.theme-dark .lang-time-stat-icon.date-icon {
  background: linear-gradient(140deg, rgba(52, 211, 153, 0.15), rgba(52, 211, 153, 0.06));
  color: #34d399;
}

/* Widget responsive: prevent overlap with site headers on desktop */
@media (min-width: 761px) {
  .site-header {
    padding-right: 310px;
  }

  /* Add left padding on non-home pages to avoid back button overlap */
  .doctor-page .site-header,
  body:not(.home-page):not(.doctor-page) .site-header {
    padding-left: 72px;
  }
}

/* Widget responsive: tablet intermediate breakpoint */
@media (max-width: 1000px) and (min-width: 761px) {
  .lang-time-widget {
    min-width: 200px;
    max-width: 240px;
    top: 10px;
    right: 10px;
    border-radius: 14px;
  }

  .lang-time-widget-header {
    padding: 8px 10px 6px;
  }

  .lang-time-widget-header select {
    min-width: 90px;
    font-size: 0.78rem;
  }

  .lang-time-widget-body {
    padding: 8px 10px 10px;
  }

  .lang-time-stat-icon {
    width: 28px;
    height: 28px;
    font-size: 14px;
    border-radius: 8px;
  }

  .lang-time-stat-value {
    font-size: 0.88rem;
  }

  .site-header {
    padding-right: 265px;
  }

  .doctor-page .site-header,
  body:not(.home-page):not(.doctor-page) .site-header {
    padding-left: 60px;
  }
}

/* ========================================
   TASK 6: Availability Time Boxes
   ======================================== */
.availability-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(155px, 1fr));
  gap: 12px;
  margin-top: 12px;
}

.availability-day {
  border: 1px solid #c6d8f2;
  border-radius: 16px;
  background: linear-gradient(165deg, #ffffff, #f3f8ff);
  padding: 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 6px;
  min-height: 110px;
  transition: transform 220ms ease, box-shadow 220ms ease, border-color 220ms ease;
}

.availability-day:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 28px rgba(16, 24, 40, 0.12);
}

.availability-day.available {
  border-color: #6dd4a8;
  background: linear-gradient(165deg, #ecfdf5, #d1fae5);
  box-shadow: 0 4px 16px rgba(14, 159, 110, 0.1);
}

.availability-day.unavailable {
  border-color: #fbbf6a;
  background: linear-gradient(165deg, #fffbeb, #fef3c7);
  box-shadow: 0 4px 16px rgba(217, 119, 6, 0.08);
}

.availability-day-title {
  font-weight: 800;
  color: #1a365f;
  font-size: 0.95rem;
  line-height: 1.2;
}

.availability-day-meta {
  color: #5e7291;
  font-size: 0.78rem;
  line-height: 1.3;
}

.availability-time-label {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 2px;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.availability-day.available .availability-time-label {
  background: rgba(14, 159, 110, 0.12);
  color: #047857;
}

.availability-day.unavailable .availability-time-label {
  background: rgba(217, 119, 6, 0.12);
  color: #92400e;
}

body.theme-dark .availability-day.available {
  border-color: #3f8f78;
  background: linear-gradient(165deg, #0d3d38, #134e48);
}

body.theme-dark .availability-day.unavailable {
  border-color: #9d7848;
  background: linear-gradient(165deg, #3c2a14, #4a341f);
}

body.theme-dark .availability-day-title {
  color: #e6efff;
}

body.theme-dark .availability-day-meta {
  color: #b8cae4;
}

body.theme-dark .availability-day.available .availability-time-label {
  background: rgba(52, 211, 153, 0.15);
  color: #6ee7b7;
}

body.theme-dark .availability-day.unavailable .availability-time-label {
  background: rgba(251, 191, 36, 0.12);
  color: #fbbf24;
}

/* Doctor availability grid - time editing boxes */
.doctor-availability-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 12px;
  margin-top: 10px;
}

.doctor-availability-row {
  border: 1px solid #c4d7f1;
  border-radius: 16px;
  padding: 14px;
  background: linear-gradient(165deg, #ffffff, #f3f8ff);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 8px;
  min-height: 120px;
  transition: transform 220ms ease, box-shadow 220ms ease, border-color 220ms ease;
}

.doctor-availability-row:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 28px rgba(16, 24, 40, 0.12);
}

.doctor-availability-row.available {
  border-color: #6dd4a8;
  background: linear-gradient(165deg, #ecfdf5, #d1fae5);
}

.doctor-availability-row.unavailable {
  border-color: #fbbf6a;
  background: linear-gradient(165deg, #fffbeb, #fef3c7);
}

body.theme-dark .doctor-availability-row {
  border-color: #3a5f8c;
  background: linear-gradient(170deg, rgba(30, 49, 78, 0.92), rgba(22, 38, 63, 0.9));
}

body.theme-dark .doctor-availability-row.available {
  border-color: #3f8f78;
  background: linear-gradient(165deg, #0d3d38, #134e48);
}

body.theme-dark .doctor-availability-row.unavailable {
  border-color: #9d7848;
  background: linear-gradient(165deg, #3c2a14, #4a341f);
}

.doctor-availability-toggle {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.82rem;
  font-weight: 700;
  color: #294465;
}

body.theme-dark .doctor-availability-toggle {
  color: #b8cae4;
}

.availability-time-input {
  width: 120px;
  padding: 5px 8px;
  font-size: 0.82rem;
  border-radius: 8px;
  border: 1px solid rgba(31, 111, 235, 0.25);
  background: rgba(255, 255, 255, 0.9);
  text-align: center;
  font-weight: 600;
}

body.theme-dark .availability-time-input {
  border-color: #43638d;
  background: #15263f;
  color: #e3efff;
}

/* ========================================
   TASK 2: Visual Upgrade - Enhanced Effects
   ======================================== */

/* Glass morphism cards */
.card {
  background: linear-gradient(180deg, rgba(255,255,255,0.98), rgba(242,248,255,0.92));
  border: 1px solid rgba(200, 218, 244, 0.7);
  border-radius: var(--radius-lg);
  box-shadow: 0 16px 40px rgba(16, 24, 40, 0.08), 0 0 0 1px rgba(255,255,255,0.6) inset;
  padding: 24px;
  animation: fadeUp 520ms ease both;
  backdrop-filter: blur(8px);
  transition: transform 280ms cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 280ms ease, border-color 280ms ease;
}

.card:hover {
  transform: translateY(-4px);
  border-color: rgba(31, 111, 235, 0.2);
  box-shadow: 0 24px 56px rgba(16, 24, 40, 0.12), 0 0 0 1px rgba(255,255,255,0.6) inset;
}

body.theme-dark .card {
  background: linear-gradient(180deg, rgba(24, 39, 64, 0.96), rgba(20, 34, 56, 0.92));
  border-color: rgba(47, 80, 121, 0.6);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.25), 0 0 0 1px rgba(255,255,255,0.03) inset;
}

/* Enhanced site headers with subtle particle effect */
.site-header {
  position: relative;
  overflow: hidden;
}

.site-header::before {
  content: "";
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background:
    radial-gradient(circle 80px at 20% 30%, rgba(31, 111, 235, 0.08), transparent),
    radial-gradient(circle 60px at 70% 60%, rgba(14, 159, 110, 0.06), transparent),
    radial-gradient(circle 40px at 90% 20%, rgba(168, 85, 247, 0.04), transparent);
  animation: headerParticles 20s linear infinite;
  pointer-events: none;
}

@keyframes headerParticles {
  0% { transform: translate(0, 0) rotate(0deg); }
  50% { transform: translate(-2%, -1%) rotate(1deg); }
  100% { transform: translate(0, 0) rotate(0deg); }
}

/* Glowing input focus states */
input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: #3f80e2;
  box-shadow: 0 0 0 4px rgba(31, 111, 235, 0.12), 0 4px 12px rgba(31, 111, 235, 0.08);
  background: rgba(255,255,255,1);
}

body.theme-dark input:focus,
body.theme-dark select:focus,
body.theme-dark textarea:focus {
  border-color: #5c8fd6;
  box-shadow: 0 0 0 4px rgba(96, 165, 250, 0.15), 0 4px 12px rgba(96, 165, 250, 0.06);
  background: #192d4a;
}

/* Soft gradient buttons with glow */
.btn-primary {
  position: relative;
  overflow: hidden;
}

.btn-primary::after {
  content: "";
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255,255,255,0.15), transparent 60%);
  opacity: 0;
  transition: opacity 300ms ease;
  pointer-events: none;
}

.btn-primary:hover::after {
  opacity: 1;
}

/* Enhanced record cards */
.record {
  transition: transform 200ms ease, box-shadow 200ms ease, border-color 200ms ease;
}

.record:hover {
  transform: translateX(4px);
  box-shadow: 0 6px 18px rgba(16, 24, 40, 0.08);
  border-color: rgba(31, 111, 235, 0.25);
}

/* Smooth status pills */
.status-pill {
  transition: transform 200ms ease, box-shadow 200ms ease;
}

.status-pill:hover {
  transform: scale(1.05);
}

/* Enhanced panels */
.panel {
  transition: border-color 280ms ease, box-shadow 280ms ease;
}

.panel:hover {
  border-color: rgba(31, 111, 235, 0.15);
  box-shadow: 0 8px 24px rgba(16, 24, 40, 0.06);
}

/* Subtle page gradient animation */
@keyframes bgShift {
  0% { background-position: 0% 0%; }
  50% { background-position: 100% 100%; }
  100% { background-position: 0% 0%; }
}

body {
  background-size: 200% 200%;
  animation: bgShift 30s ease infinite;
}

/* Badge glow */
.badge {
  transition: transform 200ms ease, box-shadow 200ms ease;
}

.badge:hover {
  transform: scale(1.08);
  box-shadow: 0 4px 12px rgba(14, 159, 110, 0.2);
}

/* Smooth table rows */
tr {
  transition: background 200ms ease;
}

tbody tr:hover {
  background: rgba(31, 111, 235, 0.04);
}

body.theme-dark tbody tr:hover {
  background: rgba(96, 165, 250, 0.06);
}

@media (max-width: 760px) {
  .global-theme-toggle {
    top: 10px;
    left: 10px;
    width: 42px;
    height: 42px;
  }

  .theme-toggle-icon {
    font-size: 18px;
  }

  .global-back-btn {
    top: 62px;
    left: 10px;
    width: 42px;
    height: 42px;
  }

  .back-btn-icon {
    font-size: 18px;
  }

  .login-hero-card {
    padding: 28px 18px 24px;
  }

  .login-icon-badge {
    width: 48px;
    height: 48px;
    top: 16px;
    right: 16px;
    border-radius: 14px;
  }

  .login-icon-emoji {
    font-size: 22px;
  }

  .login-title {
    font-size: 1.5rem;
  }

  .availability-list {
    grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  }

  .doctor-availability-grid {
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  }
}

/* ═══════════════════════════════════════════════
   Patient Account Page
   ═══════════════════════════════════════════════ */

/* Health Tips Floating System */
.health-tips-container {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 5;
  overflow: hidden;
}

.health-tip-float {
  position: absolute;
  bottom: -80px;
  padding: 10px 18px;
  border-radius: 20px;
  background: rgba(74, 144, 226, 0.08);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(74, 144, 226, 0.15);
  font-size: 0.78rem;
  font-weight: 500;
  color: #3a7bd5;
  max-width: 320px;
  opacity: 0.5;
  animation: healthTipFloat 22s linear forwards;
  pointer-events: none;
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 2px 12px rgba(74, 144, 226, 0.08);
}

.health-tip-icon {
  font-size: 1rem;
  flex-shrink: 0;
}

@keyframes healthTipFloat {
  0% { transform: translateY(0); opacity: 0; }
  5% { opacity: 0.5; }
  85% { opacity: 0.5; }
  100% { transform: translateY(-110vh); opacity: 0; }
}

/* Patient Profile Card */
.patient-profile-card {
  padding: 0;
}

.profile-info-grid {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.profile-avatar {
  display: flex;
  align-items: center;
  gap: 16px;
}

.profile-avatar-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: linear-gradient(135deg, #667eea, #764ba2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  box-shadow: 0 4px 14px rgba(102, 126, 234, 0.25);
}

.profile-name {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text);
  margin: 0;
}

.profile-detail-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.profile-detail-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 10px 14px;
  border-radius: 10px;
  background: rgba(74, 144, 226, 0.04);
  border: 1px solid rgba(74, 144, 226, 0.08);
}

.profile-detail-label {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #5e7291;
}

.profile-detail-value {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text);
}

/* Booking Timeline */
.booking-timeline {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.timeline-date-group {
  position: relative;
  padding-left: 24px;
  border-left: 3px solid rgba(74, 144, 226, 0.2);
}

.timeline-date-header {
  font-size: 0.88rem;
  font-weight: 700;
  color: #3a7bd5;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
  position: relative;
}

.timeline-date-header::before {
  content: '';
  position: absolute;
  left: -30px;
  top: 50%;
  transform: translateY(-50%);
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #3a7bd5;
  border: 3px solid #fff;
  box-shadow: 0 0 0 2px rgba(74, 144, 226, 0.3);
}

.timeline-date-icon {
  font-size: 1rem;
}

.timeline-booking-item {
  background: rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(6px);
  border: 1px solid rgba(74, 144, 226, 0.1);
  border-radius: 12px;
  padding: 14px 16px;
  margin-bottom: 10px;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.timeline-booking-item:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(74, 144, 226, 0.1);
}

.timeline-booking-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.timeline-booking-time {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text);
}

.booking-status-pill {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 100px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.pill-success { background: rgba(72, 187, 120, 0.12); color: #22863a; }
.pill-warning { background: rgba(237, 137, 54, 0.12); color: #c05621; }
.pill-danger  { background: rgba(229, 62, 62, 0.12); color: #c53030; }

.timeline-booking-body {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.timeline-detail {
  font-size: 0.82rem;
  color: #5e7291;
}

.timeline-note {
  font-style: italic;
  color: #805ad5;
}

.timeline-prescriptions {
  margin-top: 8px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.prescription-download-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 5px 12px;
  border-radius: 8px;
  background: linear-gradient(135deg, rgba(74, 144, 226, 0.08), rgba(102, 126, 234, 0.08));
  border: 1px solid rgba(74, 144, 226, 0.15);
  color: #3a7bd5;
  font-size: 0.75rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.15s ease;
}

.prescription-download-link:hover {
  background: linear-gradient(135deg, rgba(74, 144, 226, 0.15), rgba(102, 126, 234, 0.15));
  transform: translateY(-1px);
}

.rx-icon {
  font-size: 0.85rem;
}

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

/* Patient page header padding for back button */
.patient-page .site-header {
  padding-left: 72px;
}

/* Dark Mode - Patient Page */
[data-theme="dark"] .health-tip-float {
  background: rgba(99, 179, 237, 0.08);
  border-color: rgba(99, 179, 237, 0.15);
  color: #90cdf4;
}

[data-theme="dark"] .profile-avatar-icon {
  background: linear-gradient(135deg, #805ad5, #6b46c1);
}

[data-theme="dark"] .profile-detail-item {
  background: rgba(99, 179, 237, 0.06);
  border-color: rgba(99, 179, 237, 0.12);
}

[data-theme="dark"] .profile-detail-label {
  color: #a0aec0;
}

[data-theme="dark"] .timeline-date-group {
  border-left-color: rgba(99, 179, 237, 0.25);
}

[data-theme="dark"] .timeline-date-header {
  color: #90cdf4;
}

[data-theme="dark"] .timeline-date-header::before {
  background: #63b3ed;
  border-color: #1a202c;
  box-shadow: 0 0 0 2px rgba(99, 179, 237, 0.3);
}

[data-theme="dark"] .timeline-booking-item {
  background: rgba(26, 32, 44, 0.6);
  border-color: rgba(99, 179, 237, 0.12);
}

[data-theme="dark"] .pill-success { background: rgba(72, 187, 120, 0.15); color: #68d391; }
[data-theme="dark"] .pill-warning { background: rgba(237, 137, 54, 0.15); color: #f6ad55; }
[data-theme="dark"] .pill-danger  { background: rgba(229, 62, 62, 0.15); color: #fc8181; }

[data-theme="dark"] .timeline-detail {
  color: #a0aec0;
}

[data-theme="dark"] .timeline-note {
  color: #b794f4;
}

[data-theme="dark"] .prescription-download-link {
  background: rgba(99, 179, 237, 0.08);
  border-color: rgba(99, 179, 237, 0.15);
  color: #90cdf4;
}

/* Patient page responsive */
@media (max-width: 760px) {
  .profile-detail-grid {
    grid-template-columns: 1fr;
  }

  .health-tip-float {
    max-width: 240px;
    font-size: 0.72rem;
    padding: 8px 14px;
  }

  .patient-page .site-header {
    padding-left: 60px;
  }
}

/* ========================================
   HOME PAGE TOAST NOTIFICATION
   ======================================== */
.home-toast-stack {
  position: fixed;
  top: 80px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 9999;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  pointer-events: none;
}

.home-toast {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 22px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(31, 111, 235, 0.2);
  box-shadow: 0 8px 32px rgba(16, 24, 40, 0.14), 0 0 0 1px rgba(31, 111, 235, 0.08);
  max-width: 460px;
  pointer-events: auto;
  opacity: 0;
  transform: translateY(-16px) scale(0.95);
  transition: none;
}

.home-toast-visible {
  animation: homeToastIn 380ms cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.home-toast-exit {
  animation: homeToastOut 280ms ease forwards;
}

@keyframes homeToastIn {
  from { opacity: 0; transform: translateY(-16px) scale(0.95); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes homeToastOut {
  from { opacity: 1; transform: translateY(0) scale(1); }
  to { opacity: 0; transform: translateY(-10px) scale(0.96); }
}

.home-toast-icon {
  font-size: 1.3rem;
  flex-shrink: 0;
}

.home-toast-text {
  font-size: 0.88rem;
  font-weight: 600;
  color: #1a365f;
  line-height: 1.4;
}

.home-toast-info {
  border-color: rgba(31, 111, 235, 0.25);
}

.home-toast-warning {
  border-color: rgba(217, 119, 6, 0.3);
  background: rgba(255, 251, 235, 0.95);
}

[data-theme="dark"] .home-toast {
  background: rgba(30, 41, 59, 0.95);
  border-color: rgba(96, 165, 250, 0.25);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(96, 165, 250, 0.1);
}

[data-theme="dark"] .home-toast-text {
  color: #e2e8f0;
}

[data-theme="dark"] .home-toast-warning {
  background: rgba(60, 42, 20, 0.95);
  border-color: rgba(251, 191, 36, 0.3);
}

.home-toast-warning .home-toast-text {
  color: #92400e;
}

[data-theme="dark"] .home-toast-warning .home-toast-text {
  color: #fcd34d;
}

/* ========================================
   INPUT ERROR HIGHLIGHT
   ======================================== */
.input-error {
  border-color: #ef4444 !important;
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.15), 0 0 12px rgba(239, 68, 68, 0.08) !important;
  animation: inputShake 400ms ease;
}

@keyframes inputShake {
  0%, 100% { transform: translateX(0); }
  15% { transform: translateX(-6px); }
  30% { transform: translateX(5px); }
  45% { transform: translateX(-4px); }
  60% { transform: translateX(3px); }
  75% { transform: translateX(-2px); }
}

[data-theme="dark"] .input-error {
  border-color: #f87171 !important;
  box-shadow: 0 0 0 3px rgba(248, 113, 113, 0.2), 0 0 12px rgba(248, 113, 113, 0.1) !important;
}

/* ========================================
   HOME PAGE VISUAL UPGRADES — Card Accents
   ======================================== */

/* Booking form card — blue-teal left accent */
.home-page #book.card {
  border-left: 4px solid transparent;
  border-image: linear-gradient(to bottom, #2d71dd, #0ea5a0) 1;
  border-image-slice: 1;
}

/* Account card — amber-orange left accent */
.home-page #account.card {
  border-left: 4px solid transparent;
  border-image: linear-gradient(to bottom, #f59e0b, #e67e22) 1;
  border-image-slice: 1;
}

/* Availability section — green top accent */
.home-page #availability.card {
  border-top: 4px solid transparent;
  border-image: linear-gradient(to right, #10b981, #3b82f6) 1;
  border-image-slice: 1;
}

/* Hint cards — distinct pastel backgrounds */
.hint-card:nth-child(1) {
  background: linear-gradient(180deg, #eff6ff, #dbeafe);
}

.hint-card:nth-child(2) {
  background: linear-gradient(180deg, #ecfdf5, #d1fae5);
}

.hint-card:nth-child(3) {
  background: linear-gradient(180deg, #fefce8, #fef3c7);
}

.hint-card.active:nth-child(1) {
  background: linear-gradient(180deg, #dbeafe, #bfdbfe);
  box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.18) inset, 0 12px 20px rgba(59, 130, 246, 0.12);
}

.hint-card.active:nth-child(2) {
  background: linear-gradient(180deg, #d1fae5, #a7f3d0);
  box-shadow: 0 0 0 2px rgba(16, 185, 129, 0.18) inset, 0 12px 20px rgba(16, 185, 129, 0.12);
}

.hint-card.active:nth-child(3) {
  background: linear-gradient(180deg, #fef3c7, #fde68a);
  box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.18) inset, 0 12px 20px rgba(245, 158, 11, 0.12);
}

/* Hero chip — gradient background */
.hero-chip-soft {
  background: linear-gradient(135deg, #dbeafe, #c7d2fe, #e0e7ff) !important;
  border: 1px solid rgba(99, 102, 241, 0.2) !important;
  color: #3730a3 !important;
  font-weight: 700 !important;
  box-shadow: 0 2px 8px rgba(99, 102, 241, 0.12);
}

/* Nav button hover glow effects */
.home-page .nav-row .btn-primary:hover {
  box-shadow: 0 6px 20px rgba(31, 111, 235, 0.35);
}

.home-page .nav-row .btn-availability:hover {
  box-shadow: 0 6px 20px rgba(234, 115, 23, 0.35);
}

.home-page .nav-row .btn-secondary:hover {
  box-shadow: 0 6px 20px rgba(14, 159, 110, 0.3);
}

.home-page .nav-row .btn-neutral:hover {
  box-shadow: 0 6px 20px rgba(90, 113, 148, 0.25);
}

/* Dark mode card accents */
[data-theme="dark"] .home-page #book.card {
  border-image: linear-gradient(to bottom, #60a5fa, #2dd4bf) 1;
}

[data-theme="dark"] .home-page #account.card {
  border-image: linear-gradient(to bottom, #fbbf24, #f97316) 1;
}

[data-theme="dark"] .home-page #availability.card {
  border-image: linear-gradient(to right, #34d399, #60a5fa) 1;
}

/* Dark mode hint cards */
[data-theme="dark"] .hint-card:nth-child(1) {
  background: linear-gradient(180deg, #1e293b, #1e3a5f);
  border-color: #334155;
}

[data-theme="dark"] .hint-card:nth-child(2) {
  background: linear-gradient(180deg, #1e293b, #134e48);
  border-color: #334155;
}

[data-theme="dark"] .hint-card:nth-child(3) {
  background: linear-gradient(180deg, #1e293b, #4a341f);
  border-color: #334155;
}

[data-theme="dark"] .hint-card.active:nth-child(1) {
  background: linear-gradient(180deg, #1e3a5f, #1e40af);
  box-shadow: 0 0 0 2px rgba(96, 165, 250, 0.2) inset, 0 12px 20px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] .hint-card.active:nth-child(2) {
  background: linear-gradient(180deg, #134e48, #065f46);
  box-shadow: 0 0 0 2px rgba(52, 211, 153, 0.2) inset, 0 12px 20px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] .hint-card.active:nth-child(3) {
  background: linear-gradient(180deg, #4a341f, #78350f);
  box-shadow: 0 0 0 2px rgba(251, 191, 36, 0.2) inset, 0 12px 20px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] .hint-title {
  color: #e2e8f0;
}

[data-theme="dark"] .hero-chip-soft {
  background: linear-gradient(135deg, #1e3a5f, #312e81, #1e1b4b) !important;
  border-color: rgba(129, 140, 248, 0.3) !important;
  color: #a5b4fc !important;
  box-shadow: 0 2px 8px rgba(99, 102, 241, 0.2);
}

/* ========================================
   ABSTRACT TRANSPARENT CARD DECORATIONS
   ======================================== */

/* Base: ensure cards can hold decorative elements */
.home-page #book.card,
.home-page #account.card,
.home-page #availability.card {
  position: relative;
  overflow: hidden;
}

/* Booking card — floating circle + diagonal stripe */
.home-page #book.card::before {
  content: '';
  position: absolute;
  top: -40px;
  right: -40px;
  width: 180px;
  height: 180px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(45, 113, 221, 0.07) 0%, rgba(14, 165, 160, 0.04) 50%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

.home-page #book.card::after {
  content: '';
  position: absolute;
  bottom: -20px;
  left: -20px;
  width: 140px;
  height: 140px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(14, 165, 160, 0.06) 0%, transparent 65%);
  pointer-events: none;
  z-index: 0;
}

/* Account card — warm circles + cross-hatch pattern */
.home-page #account.card::before {
  content: '';
  position: absolute;
  top: -30px;
  left: -30px;
  width: 160px;
  height: 160px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(245, 158, 11, 0.06) 0%, rgba(234, 88, 12, 0.03) 50%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

.home-page #account.card::after {
  content: '';
  position: absolute;
  bottom: 10px;
  right: -10px;
  width: 200px;
  height: 200px;
  background:
    repeating-linear-gradient(
      45deg,
      transparent,
      transparent 20px,
      rgba(245, 158, 11, 0.02) 20px,
      rgba(245, 158, 11, 0.02) 21px
    ),
    repeating-linear-gradient(
      -45deg,
      transparent,
      transparent 20px,
      rgba(234, 88, 12, 0.02) 20px,
      rgba(234, 88, 12, 0.02) 21px
    );
  border-radius: 24px;
  pointer-events: none;
  z-index: 0;
}

/* Availability card — dotted pattern + circle */
.home-page #availability.card::before {
  content: '';
  position: absolute;
  top: 10px;
  right: 20px;
  width: 200px;
  height: 200px;
  background-image: radial-gradient(rgba(16, 185, 129, 0.08) 1.5px, transparent 1.5px);
  background-size: 16px 16px;
  border-radius: 50%;
  pointer-events: none;
  z-index: 0;
}

.home-page #availability.card::after {
  content: '';
  position: absolute;
  bottom: -50px;
  left: 40px;
  width: 180px;
  height: 180px;
  border-radius: 50%;
  border: 2px solid rgba(59, 130, 246, 0.05);
  background: radial-gradient(circle, rgba(16, 185, 129, 0.04) 0%, transparent 60%);
  pointer-events: none;
  z-index: 0;
}

/* Ensure card children are above decorations */
.home-page #book.card > *,
.home-page #account.card > *,
.home-page #availability.card > * {
  position: relative;
  z-index: 1;
}

/* ── Dark mode abstract decorations ── */
[data-theme="dark"] .home-page #book.card::before {
  background: radial-gradient(circle, rgba(96, 165, 250, 0.08) 0%, rgba(45, 212, 191, 0.04) 50%, transparent 70%);
}

[data-theme="dark"] .home-page #book.card::after {
  background: radial-gradient(circle, rgba(45, 212, 191, 0.06) 0%, transparent 65%);
}

[data-theme="dark"] .home-page #account.card::before {
  background: radial-gradient(circle, rgba(251, 191, 36, 0.07) 0%, rgba(249, 115, 22, 0.04) 50%, transparent 70%);
}

[data-theme="dark"] .home-page #account.card::after {
  background:
    repeating-linear-gradient(
      45deg,
      transparent,
      transparent 20px,
      rgba(251, 191, 36, 0.025) 20px,
      rgba(251, 191, 36, 0.025) 21px
    ),
    repeating-linear-gradient(
      -45deg,
      transparent,
      transparent 20px,
      rgba(249, 115, 22, 0.025) 20px,
      rgba(249, 115, 22, 0.025) 21px
    );
}

[data-theme="dark"] .home-page #availability.card::before {
  background-image: radial-gradient(rgba(52, 211, 153, 0.08) 1.5px, transparent 1.5px);
}

[data-theme="dark"] .home-page #availability.card::after {
  border-color: rgba(96, 165, 250, 0.08);
  background: radial-gradient(circle, rgba(52, 211, 153, 0.05) 0%, transparent 60%);
}

/* ========================================
   ADMIN PAGE VISUAL EFFECTS
   ======================================== */

/* Floating background orbs */
.admin-bg-effects {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.admin-bg-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.4;
}

.admin-bg-orb-1 {
  width: 350px;
  height: 350px;
  top: -80px;
  right: -60px;
  background: radial-gradient(circle, rgba(99, 102, 241, 0.18) 0%, transparent 70%);
  animation: adminOrb1 18s ease-in-out infinite;
}

.admin-bg-orb-2 {
  width: 280px;
  height: 280px;
  bottom: -60px;
  left: -40px;
  background: radial-gradient(circle, rgba(14, 165, 160, 0.15) 0%, transparent 70%);
  animation: adminOrb2 22s ease-in-out infinite;
}

.admin-bg-orb-3 {
  width: 200px;
  height: 200px;
  top: 40%;
  left: 50%;
  background: radial-gradient(circle, rgba(245, 158, 11, 0.1) 0%, transparent 70%);
  animation: adminOrb3 15s ease-in-out infinite;
}

/* Subtle dot-grid overlay */
.admin-bg-grid {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(31, 111, 235, 0.04) 1px, transparent 1px);
  background-size: 28px 28px;
}

@keyframes adminOrb1 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  25% { transform: translate(-30px, 40px) scale(1.1); }
  50% { transform: translate(20px, 60px) scale(0.95); }
  75% { transform: translate(-10px, 20px) scale(1.05); }
}

@keyframes adminOrb2 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  30% { transform: translate(40px, -30px) scale(1.08); }
  60% { transform: translate(-20px, -50px) scale(0.92); }
}

@keyframes adminOrb3 {
  0%, 100% { transform: translate(0, 0) scale(1); opacity: 0.4; }
  50% { transform: translate(30px, -40px) scale(1.15); opacity: 0.6; }
}

/* Admin login card — enhanced visual */
.admin-page .login-hero-card {
  background: linear-gradient(170deg,
    rgba(255, 255, 255, 0.98) 0%,
    rgba(238, 242, 255, 0.95) 40%,
    rgba(224, 231, 255, 0.9) 100%);
  border: 1px solid rgba(99, 102, 241, 0.15);
  box-shadow:
    0 24px 56px rgba(16, 24, 40, 0.1),
    0 0 0 1px rgba(255, 255, 255, 0.7) inset,
    0 0 80px rgba(99, 102, 241, 0.04);
}

.admin-page .login-hero-card:hover {
  border-color: rgba(99, 102, 241, 0.25);
  box-shadow:
    0 32px 64px rgba(16, 24, 40, 0.14),
    0 0 0 1px rgba(255, 255, 255, 0.7) inset,
    0 0 100px rgba(99, 102, 241, 0.06);
}

/* Admin login orbs — indigo tones */
.admin-page .login-orb-1 {
  background: radial-gradient(circle, rgba(99, 102, 241, 0.3), transparent 70%);
}

.admin-page .login-orb-2 {
  background: radial-gradient(circle, rgba(14, 165, 160, 0.25), transparent 70%);
}

/* Admin icon badge — indigo glow */
.admin-page .login-icon-badge {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.14), rgba(14, 165, 160, 0.08));
  border-color: rgba(99, 102, 241, 0.18);
  box-shadow: 0 8px 24px rgba(99, 102, 241, 0.12);
}

.admin-page .login-icon-badge {
  animation: adminBadgePulse 3s ease-in-out infinite;
}

@keyframes adminBadgePulse {
  0%, 100% {
    box-shadow: 0 8px 24px rgba(99, 102, 241, 0.12);
    transform: scale(1);
  }
  50% {
    box-shadow: 0 8px 32px rgba(99, 102, 241, 0.25), 0 0 20px rgba(99, 102, 241, 0.1);
    transform: scale(1.05);
  }
}

/* Admin dashboard cards — subtle gradient borders */
.admin-page #dashboard .card {
  position: relative;
  overflow: hidden;
}

.admin-page #dashboard .card::before {
  content: '';
  position: absolute;
  top: -30px;
  right: -30px;
  width: 150px;
  height: 150px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(99, 102, 241, 0.05) 0%, transparent 65%);
  pointer-events: none;
  z-index: 0;
}

.admin-page #dashboard .card > * {
  position: relative;
  z-index: 1;
}

/* ── Admin dark mode ── */
[data-theme="dark"] .admin-bg-orb-1 {
  background: radial-gradient(circle, rgba(129, 140, 248, 0.12) 0%, transparent 70%);
}

[data-theme="dark"] .admin-bg-orb-2 {
  background: radial-gradient(circle, rgba(45, 212, 191, 0.1) 0%, transparent 70%);
}

[data-theme="dark"] .admin-bg-orb-3 {
  background: radial-gradient(circle, rgba(251, 191, 36, 0.08) 0%, transparent 70%);
}

[data-theme="dark"] .admin-bg-grid {
  background-image: radial-gradient(rgba(148, 163, 184, 0.04) 1px, transparent 1px);
}

[data-theme="dark"] .admin-page .login-hero-card {
  background: linear-gradient(170deg,
    rgba(30, 41, 59, 0.98) 0%,
    rgba(30, 27, 75, 0.95) 40%,
    rgba(49, 46, 129, 0.2) 100%);
  border-color: rgba(129, 140, 248, 0.2);
  box-shadow:
    0 24px 56px rgba(0, 0, 0, 0.3),
    0 0 0 1px rgba(129, 140, 248, 0.1) inset,
    0 0 60px rgba(129, 140, 248, 0.05);
}

[data-theme="dark"] .admin-page .login-orb-1 {
  background: radial-gradient(circle, rgba(129, 140, 248, 0.25), transparent 70%);
}

[data-theme="dark"] .admin-page .login-orb-2 {
  background: radial-gradient(circle, rgba(45, 212, 191, 0.2), transparent 70%);
}

[data-theme="dark"] .admin-page .login-icon-badge {
  background: linear-gradient(135deg, rgba(129, 140, 248, 0.18), rgba(45, 212, 191, 0.1));
  border-color: rgba(129, 140, 248, 0.25);
}

[data-theme="dark"] .admin-page #dashboard .card::before {
  background: radial-gradient(circle, rgba(129, 140, 248, 0.06) 0%, transparent 65%);
}

/* Admin watermark quote */
.admin-watermark-quote {
  position: fixed;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  font-family: "Merriweather", Georgia, serif;
  font-style: italic;
  font-size: 0.92rem;
  color: rgba(99, 102, 241, 0.12);
  white-space: nowrap;
  pointer-events: none;
  user-select: none;
  letter-spacing: 0.02em;
  z-index: 0;
}

[data-theme="dark"] .admin-watermark-quote {
  color: rgba(165, 180, 252, 0.1);
}

/* Admin dashboard symmetry fixes */
.admin-page #dashboard .card {
  box-sizing: border-box;
}

.admin-page #dashboard .section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.admin-page #dashboard .table-shell {
  margin-top: 12px;
  border-radius: 10px;
  overflow: hidden;
}

.admin-page #dashboard .table-shell table {
  min-width: 600px;
}

.admin-page #dashboard .table-shell th,
.admin-page #dashboard .table-shell td {
  padding: 10px 14px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 200px;
}

.admin-page .pagination-row {
  margin-top: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
}

.admin-page .pagination-row .btn {
  min-width: 80px;
  text-align: center;
}

.admin-page .pagination-row .record-meta {
  min-width: 100px;
  text-align: center;
  font-weight: 600;
}

.admin-page #dashboard .panel {
  border-radius: 12px;
}

.admin-page .lookup-input-wrap {
  flex: 1;
  max-width: 400px;
}

/* ========================================
   ADMIN PAGE — TOTAL VISUAL OVERHAUL
   ======================================== */

/* ── Admin Header ── */
.admin-header {
  text-align: center;
  margin-bottom: 20px;
}

.admin-brand {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.18), rgba(14, 165, 160, 0.12));
  color: #6366f1;
  border: 1px solid rgba(99, 102, 241, 0.15);
  font-size: 11px;
  padding: 6px 16px;
}

[data-theme="dark"] .admin-brand {
  background: linear-gradient(135deg, rgba(129, 140, 248, 0.2), rgba(45, 212, 191, 0.12));
  color: #a5b4fc;
  border-color: rgba(129, 140, 248, 0.2);
}

.admin-hero-title {
  background: linear-gradient(135deg, #312e81 0%, #6366f1 50%, #0ea5a0 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

[data-theme="dark"] .admin-hero-title {
  background: linear-gradient(135deg, #a5b4fc 0%, #818cf8 50%, #5eead4 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ── Flashy Navigation Card ── */
.admin-nav-card {
  position: relative;
  margin-bottom: 24px;
  padding: 6px;
  border-radius: 20px;
  background: linear-gradient(135deg,
    rgba(99, 102, 241, 0.08) 0%,
    rgba(14, 165, 160, 0.06) 50%,
    rgba(99, 102, 241, 0.1) 100%);
  border: 1px solid rgba(99, 102, 241, 0.15);
  box-shadow:
    0 8px 32px rgba(99, 102, 241, 0.08),
    0 2px 8px rgba(16, 24, 40, 0.04);
  overflow: hidden;
  animation: fadeUp 500ms ease both;
  animation-delay: 100ms;
}

.admin-nav-card::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 20px;
  padding: 1.5px;
  background: linear-gradient(135deg,
    rgba(99, 102, 241, 0.4),
    rgba(14, 165, 160, 0.3),
    rgba(99, 102, 241, 0.4));
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
  opacity: 0.5;
}

.admin-nav-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 200%;
  height: 200%;
  transform: translate(-50%, -50%);
  background: radial-gradient(ellipse at center,
    rgba(99, 102, 241, 0.06) 0%,
    transparent 60%);
  animation: adminNavGlow 6s ease-in-out infinite;
}

@keyframes adminNavGlow {
  0%, 100% { opacity: 0.5; transform: translate(-50%, -50%) scale(1); }
  50% { opacity: 1; transform: translate(-50%, -50%) scale(1.1); }
}

.admin-nav-inner {
  position: relative;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 0;
  background: linear-gradient(180deg, #1e293b, #0f172a);
  border: 1px solid rgba(129, 140, 248, 0.1);
  border-radius: 16px;
  padding: 8px 12px;
  z-index: 1;
}

[data-theme="dark"] .admin-nav-inner {
  background: linear-gradient(180deg, #141c2e, #0c1222);
  border-color: rgba(129, 140, 248, 0.15);
}

.admin-nav-divider {
  width: 1px;
  height: 48px;
  background: linear-gradient(180deg,
    transparent 0%,
    rgba(99, 102, 241, 0.25) 50%,
    transparent 100%);
  margin: 0 4px;
}

.admin-nav-link {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 20px;
  border-radius: 12px;
  text-decoration: none;
  transition: all 0.25s ease;
  position: relative;
}

.admin-nav-link:hover {
  background: rgba(129, 140, 248, 0.08);
  transform: translateY(-1px);
}

.admin-nav-link--booking {
  justify-content: flex-start;
}

.admin-nav-link--doctor {
  justify-content: flex-end;
  text-align: right;
  flex-direction: row-reverse;
}

.admin-nav-link--doctor .admin-nav-link-text {
  align-items: flex-end;
}

.admin-nav-link-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  flex-shrink: 0;
  transition: all 0.25s ease;
}

.admin-nav-link--booking .admin-nav-link-icon {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.2), rgba(79, 70, 229, 0.15));
  color: #a5b4fc;
  border: 1px solid rgba(129, 140, 248, 0.2);
}

.admin-nav-link--doctor .admin-nav-link-icon {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.2), rgba(5, 150, 105, 0.15));
  color: #6ee7b7;
  border: 1px solid rgba(52, 211, 153, 0.2);
}

.admin-nav-link:hover .admin-nav-link-icon {
  transform: scale(1.08);
  box-shadow: 0 4px 16px rgba(99, 102, 241, 0.15);
}

.admin-nav-link--doctor:hover .admin-nav-link-icon {
  box-shadow: 0 4px 16px rgba(16, 185, 129, 0.15);
}

.admin-nav-link-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.admin-nav-link-label {
  font-size: 0.95rem;
  font-weight: 700;
  color: #e2e8f0;
  letter-spacing: -0.01em;
}

.admin-nav-link-hint {
  font-size: 0.78rem;
  color: #94a3b8;
  font-weight: 500;
}

.admin-nav-link-arrow {
  display: flex;
  align-items: center;
  color: #94a3b8;
  transition: transform 0.25s ease;
}

.admin-nav-link--doctor:hover .admin-nav-link-arrow {
  transform: translateX(3px);
  color: #6ee7b7;
}

[data-theme="dark"] .admin-nav-card {
  background: linear-gradient(135deg,
    rgba(129, 140, 248, 0.06) 0%,
    rgba(45, 212, 191, 0.04) 50%,
    rgba(129, 140, 248, 0.08) 100%);
  border-color: rgba(129, 140, 248, 0.15);
  box-shadow:
    0 8px 32px rgba(0, 0, 0, 0.2),
    0 2px 8px rgba(0, 0, 0, 0.1);
}

[data-theme="dark"] .admin-nav-card::before {
  background: linear-gradient(135deg,
    rgba(129, 140, 248, 0.35),
    rgba(45, 212, 191, 0.25),
    rgba(129, 140, 248, 0.35));
}

/* ── Admin Login Card overhaul ── */
.admin-login-card {
  max-width: 520px;
  margin: 0 auto;
}

/* ── Admin Dashboard Header Card ── */
.admin-dashboard-header-card {
  border: 1px solid rgba(99, 102, 241, 0.12);
}

.admin-dashboard-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}

.admin-top-actions {
  display: flex;
  gap: 10px;
  flex-shrink: 0;
}

.admin-btn-csv {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  font-size: 0.85rem;
  font-weight: 600;
  color: #059669;
  background: linear-gradient(135deg, #ecfdf5, #d1fae5);
  border: 1px solid rgba(16, 185, 129, 0.2);
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.admin-btn-csv:hover {
  background: linear-gradient(135deg, #d1fae5, #a7f3d0);
  box-shadow: 0 4px 16px rgba(16, 185, 129, 0.15);
  transform: translateY(-1px);
}

[data-theme="dark"] .admin-btn-csv {
  color: #6ee7b7;
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.15), rgba(5, 150, 105, 0.1));
  border-color: rgba(52, 211, 153, 0.2);
}

[data-theme="dark"] .admin-btn-csv:hover {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.25), rgba(5, 150, 105, 0.18));
  box-shadow: 0 4px 16px rgba(52, 211, 153, 0.12);
}

.admin-btn-logout {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  font-size: 0.85rem;
  font-weight: 600;
  color: #dc2626;
  background: linear-gradient(135deg, #fef2f2, #fee2e2);
  border: 1px solid rgba(220, 38, 38, 0.15);
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.admin-btn-logout:hover {
  background: linear-gradient(135deg, #fee2e2, #fecaca);
  box-shadow: 0 4px 16px rgba(220, 38, 38, 0.12);
  transform: translateY(-1px);
}

[data-theme="dark"] .admin-btn-logout {
  color: #fca5a5;
  background: linear-gradient(135deg, rgba(220, 38, 38, 0.12), rgba(185, 28, 28, 0.08));
  border-color: rgba(248, 113, 113, 0.2);
}

[data-theme="dark"] .admin-btn-logout:hover {
  background: linear-gradient(135deg, rgba(220, 38, 38, 0.2), rgba(185, 28, 28, 0.15));
  box-shadow: 0 4px 16px rgba(248, 113, 113, 0.1);
}

/* ── Admin Login Card — Bigger ── */
.admin-login-card {
  max-width: 620px;
  margin: 0 auto;
  padding: 48px 40px 40px;
}

.admin-login-card .login-title {
  font-size: 2.2rem;
}

.admin-login-card .login-subtitle {
  font-size: 1.05rem;
}

.admin-login-card .form-stack {
  gap: 18px;
}

.admin-login-card label {
  font-size: 0.92rem;
}

.admin-login-card input {
  padding: 14px 16px;
  font-size: 1rem;
}

.admin-login-card .btn-login-wide {
  padding: 16px;
  font-size: 1.05rem;
}

.admin-login-card .login-icon-badge {
  width: 64px;
  height: 64px;
}

.admin-login-card .login-icon-svg {
  width: 42px;
  height: 42px;
}

/* ── Admin Restricted Badge ── */
.admin-restricted-badge {
  position: relative;
  width: 200px;
  height: 200px;
  margin: 40px auto 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: fadeUp 600ms ease both;
  animation-delay: 200ms;
}

.admin-restricted-ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 2px solid rgba(99, 102, 241, 0.15);
  background: linear-gradient(160deg,
    rgba(99, 102, 241, 0.04) 0%,
    rgba(14, 165, 160, 0.03) 100%);
  animation: restrictedRingSpin 30s linear infinite;
}

.admin-restricted-ring::before {
  content: '';
  position: absolute;
  inset: -2px;
  border-radius: 50%;
  border: 2px dashed rgba(99, 102, 241, 0.1);
  animation: restrictedRingSpin 20s linear infinite reverse;
}

.admin-restricted-ring::after {
  content: '';
  position: absolute;
  inset: 8px;
  border-radius: 50%;
  border: 1px solid rgba(99, 102, 241, 0.08);
}

@keyframes restrictedRingSpin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.admin-restricted-inner {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 24px;
  z-index: 1;
}

.admin-restricted-icon {
  color: #6366f1;
  margin-bottom: 8px;
  opacity: 0.7;
}

[data-theme="dark"] .admin-restricted-icon {
  color: #a5b4fc;
  opacity: 0.8;
}

.admin-restricted-title {
  font-family: "Fraunces", Georgia, serif;
  font-size: 0.95rem;
  font-weight: 700;
  color: #4338ca;
  letter-spacing: 0.02em;
}

[data-theme="dark"] .admin-restricted-title {
  color: #a5b4fc;
}

.admin-restricted-text {
  font-size: 0.7rem;
  color: #64748b;
  line-height: 1.4;
  max-width: 160px;
  margin-top: 4px;
}

[data-theme="dark"] .admin-restricted-text {
  color: #94a3b8;
}

[data-theme="dark"] .admin-restricted-ring {
  border-color: rgba(129, 140, 248, 0.15);
  background: linear-gradient(160deg,
    rgba(129, 140, 248, 0.04) 0%,
    rgba(45, 212, 191, 0.03) 100%);
}

[data-theme="dark"] .admin-restricted-ring::before {
  border-color: rgba(129, 140, 248, 0.1);
}

[data-theme="dark"] .admin-restricted-ring::after {
  border-color: rgba(129, 140, 248, 0.08);
}

/* ── Admin Responsive Nav ── */
@media (max-width: 640px) {
  .admin-nav-inner {
    grid-template-columns: 1fr;
    gap: 0;
  }
  .admin-nav-divider {
    width: 80%;
    height: 1px;
    margin: 0 auto;
    background: linear-gradient(90deg,
      transparent 0%,
      rgba(99, 102, 241, 0.2) 50%,
      transparent 100%);
  }
  .admin-nav-link--doctor {
    flex-direction: row;
    text-align: left;
    justify-content: flex-start;
  }
  .admin-nav-link--doctor .admin-nav-link-text {
    align-items: flex-start;
  }
  .admin-top-actions {
    width: 100%;
    justify-content: stretch;
  }
  .admin-top-actions .btn {
    flex: 1;
    justify-content: center;
  }
}

/* ========================================
   LOCATION PICKER HEADER CARD
   ======================================== */
.location-picker-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(31, 111, 235, 0.12);
  background: linear-gradient(160deg,
    #ffffff 0%,
    #f8fbff 40%,
    #f0f6ff 100%);
  box-shadow:
    0 1px 3px rgba(16, 24, 40, 0.06),
    0 12px 36px rgba(31, 111, 235, 0.06);
  padding: 32px 36px 24px;
  transition: border-color 0.4s, box-shadow 0.4s;
}

.location-picker-card.location-selected {
  border-color: rgba(16, 185, 129, 0.25);
  box-shadow:
    0 1px 3px rgba(16, 24, 40, 0.06),
    0 12px 36px rgba(16, 185, 129, 0.08);
}

/* ── Internal decorative elements ── */
.location-picker-deco {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.lp-ring {
  position: absolute;
  border-radius: 50%;
  border: 1.5px solid rgba(31, 111, 235, 0.06);
}

.lp-ring-1 {
  width: 220px;
  height: 220px;
  top: -80px;
  right: -40px;
  border-width: 2px;
  border-color: rgba(31, 111, 235, 0.05);
}

.lp-ring-2 {
  width: 140px;
  height: 140px;
  bottom: -50px;
  left: 20%;
  border-color: rgba(14, 165, 160, 0.05);
}

.lp-dots {
  position: absolute;
  top: 12px;
  right: 60px;
  width: 100px;
  height: 80px;
  background-image: radial-gradient(rgba(31, 111, 235, 0.07) 1.2px, transparent 1.2px);
  background-size: 12px 12px;
  border-radius: 8px;
}

.location-picker-inner {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}

/* Badge icon — SVG based */
.location-picker-badge {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: linear-gradient(135deg, #eef4ff, #e0ecff);
  border: 1px solid rgba(31, 111, 235, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(31, 111, 235, 0.08);
}

.lp-badge-icon {
  width: 24px;
  height: 24px;
  color: #2563eb;
}

.location-selected .location-picker-badge {
  background: linear-gradient(135deg, #ecfdf5, #d1fae5);
  border-color: rgba(16, 185, 129, 0.18);
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.1);
}

.location-selected .lp-badge-icon {
  color: #059669;
}

.location-picker-content {
  flex: 1;
  min-width: 180px;
}

.location-picker-title {
  font-family: "DM Serif Display", "Merriweather", Georgia, serif;
  font-size: 1.35rem;
  font-weight: 400;
  color: #0f2b52;
  margin: 0 0 3px;
  letter-spacing: 0.01em;
}

.location-picker-subtitle {
  font-size: 0.84rem;
  color: var(--text-muted);
  margin: 0;
  line-height: 1.5;
}

.location-picker-fields {
  display: flex;
  align-items: flex-end;
  gap: 14px;
  flex-wrap: wrap;
}

.location-field {
  min-width: 170px;
  flex: 1;
}

.location-field label {
  display: block;
  font-family: "Inter", "Sora", sans-serif;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #64748b;
  margin-bottom: 5px;
}

.location-field select {
  width: 100%;
  padding: 10px 14px;
  font-family: "Inter", "Sora", sans-serif;
  font-size: 0.9rem;
  font-weight: 500;
  border-radius: 10px;
  border: 1.5px solid #d1d9e6;
  background: #ffffff;
  color: #1e293b;
  cursor: pointer;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.location-field select:focus {
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.12);
  outline: none;
}

.location-field-arrow {
  color: #94a3b8;
  padding-bottom: 8px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
}

.location-status {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 18px;
  padding: 10px 16px;
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.8);
  border: 1px solid #e2e8f0;
  font-family: "Inter", "Sora", sans-serif;
  font-size: 0.82rem;
  font-weight: 500;
  color: #64748b;
  transition: all 0.3s;
}

.location-status-ready {
  background: #f0fdf4;
  border-color: #bbf7d0;
  color: #166534;
}

.location-status-icon {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  color: #94a3b8;
}

.location-status-ready .location-status-icon {
  color: #16a34a;
}

/* ── Dark mode location picker ── */
[data-theme="dark"] .location-picker-card {
  background: linear-gradient(160deg,
    rgba(30, 41, 59, 0.98) 0%,
    rgba(30, 41, 59, 0.95) 40%,
    rgba(30, 50, 80, 0.9) 100%);
  border-color: rgba(71, 85, 105, 0.5);
  box-shadow:
    0 1px 3px rgba(0, 0, 0, 0.2),
    0 12px 36px rgba(0, 0, 0, 0.15);
}

[data-theme="dark"] .location-picker-card.location-selected {
  border-color: rgba(52, 211, 153, 0.3);
}

[data-theme="dark"] .location-picker-badge {
  background: linear-gradient(135deg, #1e3a5f, #1e40af40);
  border-color: rgba(96, 165, 250, 0.2);
}

[data-theme="dark"] .lp-badge-icon {
  color: #60a5fa;
}

[data-theme="dark"] .location-selected .location-picker-badge {
  background: linear-gradient(135deg, #064e3b, #065f4660);
  border-color: rgba(52, 211, 153, 0.25);
}

[data-theme="dark"] .location-selected .lp-badge-icon {
  color: #34d399;
}

[data-theme="dark"] .location-picker-title {
  color: #e2e8f0;
}

[data-theme="dark"] .location-field label {
  color: #94a3b8;
}

[data-theme="dark"] .location-field select {
  background: rgba(15, 23, 42, 0.8);
  border-color: #475569;
  color: #e2e8f0;
}

[data-theme="dark"] .location-field select:focus {
  border-color: #60a5fa;
  box-shadow: 0 0 0 3px rgba(96, 165, 250, 0.15);
}

[data-theme="dark"] .location-status {
  background: rgba(15, 23, 42, 0.6);
  border-color: #334155;
  color: #94a3b8;
}

[data-theme="dark"] .location-status-ready {
  background: rgba(6, 78, 59, 0.3);
  border-color: rgba(52, 211, 153, 0.2);
  color: #6ee7b7;
}

[data-theme="dark"] .location-status-ready .location-status-icon {
  color: #34d399;
}

[data-theme="dark"] .location-field-arrow {
  color: #475569;
}

[data-theme="dark"] .lp-ring-1 {
  border-color: rgba(96, 165, 250, 0.05);
}

[data-theme="dark"] .lp-ring-2 {
  border-color: rgba(45, 212, 191, 0.05);
}

[data-theme="dark"] .lp-dots {
  background-image: radial-gradient(rgba(96, 165, 250, 0.06) 1.2px, transparent 1.2px);
}

/* ========================================
   GEOMETRIC BOX DESIGNS INSIDE CARDS
   ======================================== */

/* Booking card — diamond + ring */
.home-page #book.card::before {
  content: '';
  position: absolute;
  top: 20px;
  right: 20px;
  width: 90px;
  height: 90px;
  border: 2.5px solid rgba(45, 113, 221, 0.07);
  transform: rotate(45deg);
  border-radius: 8px;
  pointer-events: none;
  z-index: 0;
}

.home-page #book.card::after {
  content: '';
  position: absolute;
  bottom: 30px;
  left: -15px;
  width: 100px;
  height: 100px;
  border: 2px solid rgba(14, 165, 160, 0.06);
  border-radius: 50%;
  pointer-events: none;
  z-index: 0;
}

/* Account card — hexagonal pattern + triangle */
.home-page #account.card::before {
  content: '';
  position: absolute;
  top: -10px;
  left: 50%;
  width: 80px;
  height: 80px;
  border: 2.5px solid rgba(245, 158, 11, 0.07);
  border-radius: 50%;
  pointer-events: none;
  z-index: 0;
}

.home-page #account.card::after {
  content: '';
  position: absolute;
  bottom: 20px;
  right: 15px;
  width: 0;
  height: 0;
  border-left: 40px solid transparent;
  border-right: 40px solid transparent;
  border-bottom: 70px solid rgba(234, 88, 12, 0.03);
  pointer-events: none;
  z-index: 0;
}

/* Availability card — dotted hex + parallelogram */
.home-page #availability.card::before {
  content: '';
  position: absolute;
  top: 15px;
  right: 30px;
  width: 110px;
  height: 110px;
  background-image:
    radial-gradient(rgba(16, 185, 129, 0.07) 2px, transparent 2px);
  background-size: 14px 14px;
  border-radius: 12px;
  transform: rotate(15deg);
  pointer-events: none;
  z-index: 0;
}

.home-page #availability.card::after {
  content: '';
  position: absolute;
  bottom: 10px;
  left: 40px;
  width: 100px;
  height: 60px;
  border: 2px solid rgba(59, 130, 246, 0.05);
  transform: skewX(-12deg);
  border-radius: 6px;
  pointer-events: none;
  z-index: 0;
}

/* ── Dark mode geometric decorations ── */
[data-theme="dark"] .home-page #book.card::before {
  border-color: rgba(96, 165, 250, 0.08);
}

[data-theme="dark"] .home-page #book.card::after {
  border-color: rgba(45, 212, 191, 0.07);
}

[data-theme="dark"] .home-page #account.card::before {
  border-color: rgba(251, 191, 36, 0.08);
}

[data-theme="dark"] .home-page #account.card::after {
  border-bottom-color: rgba(249, 115, 22, 0.04);
}

[data-theme="dark"] .home-page #availability.card::before {
  background-image: radial-gradient(rgba(52, 211, 153, 0.07) 2px, transparent 2px);
}

[data-theme="dark"] .home-page #availability.card::after {
  border-color: rgba(96, 165, 250, 0.06);
}

/* Mobile toast adjustments */
@media (max-width: 600px) {
  .home-toast-stack {
    top: 70px;
    left: 12px;
    right: 12px;
    transform: none;
  }

  .home-toast {
    max-width: 100%;
    padding: 12px 16px;
    font-size: 0.84rem;
  }

  .location-picker-inner {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }

  .location-picker-fields {
    flex-direction: column;
  }

  .location-field-arrow {
    display: none;
  }

  .location-picker-icon {
    display: none;
  }

  .location-picker-title {
    font-size: 1.2rem;
  }
}

/* ═══════════════════════════════════════════════════════
   Golden "Your Account" Button
   ═══════════════════════════════════════════════════════ */
.btn-golden {
  background: linear-gradient(135deg, #f6d365 0%, #d4a017 100%);
  color: #1a1a2e;
  border: 1px solid #c4960c;
  font-weight: 700;
  text-shadow: 0 1px 0 rgba(255,255,255,0.25);
  box-shadow: 0 2px 8px rgba(212, 160, 23, 0.3);
}
.btn-golden:hover {
  background: linear-gradient(135deg, #f7dc6f 0%, #daa520 100%);
  box-shadow: 0 4px 14px rgba(212, 160, 23, 0.45);
  transform: translateY(-1px);
}
.btn-golden:active {
  transform: translateY(0);
  box-shadow: 0 1px 4px rgba(212, 160, 23, 0.3);
}
.theme-dark .btn-golden {
  background: linear-gradient(135deg, #f6d365 0%, #c4960c 100%);
  color: #1a1a2e;
  border-color: #b8860b;
}

/* ═══════════════════════════════════════════════════════
   Patient Status Widget (fixed bottom-right)
   ═══════════════════════════════════════════════════════ */
.patient-status-widget {
  position: fixed;
  bottom: 16px;
  right: 16px;
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  background: rgba(0, 0, 0, 0.7);
  color: #fff;
  z-index: 1000;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  transition: all 0.3s ease;
  pointer-events: none;
  user-select: none;
}
.patient-status-widget.patient-status-logged-in {
  background: rgba(15, 130, 90, 0.85);
  box-shadow: 0 2px 12px rgba(14, 159, 110, 0.3);
}
.theme-dark .patient-status-widget {
  background: rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.8);
}
.theme-dark .patient-status-widget.patient-status-logged-in {
  background: rgba(15, 130, 90, 0.75);
  color: #fff;
}

/* ═══════════════════════════════════════════════════════
   Bottom Patient Login Bar (main page)
   ═══════════════════════════════════════════════════════ */
.patient-login-bar {
  border-top: 2px solid var(--line-soft);
}
.bottom-login-header {
  margin-bottom: 12px;
}
.bottom-login-row {
  display: flex;
  gap: 12px;
  align-items: flex-end;
  flex-wrap: wrap;
}
.bottom-login-row > div {
  flex: 1;
  min-width: 160px;
}
.bottom-login-actions {
  display: flex;
  align-items: flex-end;
  padding-bottom: 1px;
}
.bottom-login-actions .btn {
  white-space: nowrap;
}

/* Bottom account summary (logged in state) */
.bottom-account-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.bottom-account-info {
  display: flex;
  align-items: center;
  gap: 12px;
}
.bottom-account-avatar {
  font-size: 1.8rem;
  line-height: 1;
}
.bottom-acc-name {
  font-weight: 700;
  font-size: 1rem;
  color: var(--text-main);
}
.bottom-acc-phone {
  font-size: 0.85rem;
  color: var(--text-muted);
}
.bottom-account-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

/* ── Responsive: bottom login bar ── */
@media (max-width: 600px) {
  .bottom-login-row {
    flex-direction: column;
    align-items: stretch;
  }
  .bottom-login-row > div {
    min-width: 100%;
  }
  .bottom-account-row {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* ── btn-sm utility ── */
.btn-sm {
  padding: 6px 14px;
  font-size: 0.82rem;
}

/* ══════════════════════════════════════
   Admin Edit Booking Modal
   ══════════════════════════════════════ */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(10, 10, 30, 0.65);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  animation: modalFadeIn 0.2s ease;
}
@keyframes modalFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
.modal-content {
  width: 100%;
  animation: modalSlideUp 0.25s ease;
}
@keyframes modalSlideUp {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: translateY(0); }
}
.modal-close-btn {
  position: absolute;
  top: 12px;
  right: 16px;
  background: none;
  border: none;
  font-size: 1.6rem;
  cursor: pointer;
  color: var(--text-secondary, #888);
  line-height: 1;
  padding: 4px 8px;
  border-radius: 6px;
  transition: background 0.15s, color 0.15s;
}
.modal-close-btn:hover {
  background: var(--card-hover-bg, rgba(255,255,255,0.08));
  color: var(--text-primary, #fff);
}

/* Form grid rows for modal */
.form-row-2col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.form-row-3col {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 12px;
}
@media (max-width: 540px) {
  .form-row-2col,
  .form-row-3col {
    grid-template-columns: 1fr;
  }
}

/* Edit button in booking table rows */
.btn-edit-booking {
  padding: 4px 12px;
  font-size: 0.78rem;
  border-radius: 6px;
  cursor: pointer;
  background: var(--accent, #6c63ff);
  color: #fff;
  border: none;
  font-weight: 600;
  transition: background 0.15s, transform 0.1s;
}
.btn-edit-booking:hover {
  background: var(--accent-hover, #5a52e0);
  transform: translateY(-1px);
}
