/*
 * find-doctors.css — Unity Aid Hospital
 * ─────────────────────────────────────────────────────────────────
 * Design direction: "Clinical Luxury"
 * Precise, trustworthy, teal + deep-navy palette. Premium card
 * hierarchy with subtle motion and structured information layout.
 * ─────────────────────────────────────────────────────────────────
 */

:root {
  --dc-teal:        #0d9488;
  --dc-teal-dark:   #0f766e;
  --dc-teal-light:  #ccfbf1;
  --dc-teal-pale:   #f0fdfa;
  --dc-navy:        #0c1e3c;
  --dc-text-head:   #0f172a;
  --dc-text-body:   #475569;
  --dc-text-muted:  #94a3b8;
  --dc-border:      #e2e8f0;
  --dc-white:       #ffffff;
  --dc-radius:      16px;
  --dc-radius-sm:   10px;
  --dc-shadow:      0 1px 3px rgba(0,0,0,0.06), 0 6px 20px rgba(0,0,0,0.04);
  --dc-shadow-hover:0 4px 8px rgba(0,0,0,0.06), 0 20px 40px rgba(13,148,136,0.15);
  --dc-ease:        cubic-bezier(0.4, 0, 0.2, 1);
}


/* ═══════════════════════════════════════════════════════════
   PAGE HERO — replaces the plain centered title
   Deep navy + teal gradient with a dot-grid texture
   ═══════════════════════════════════════════════════════════ */

.fd-hero {
  background: linear-gradient(135deg, #0c1e3c 0%, #0e2d45 45%, #0f4f4a 100%);
  padding: 52px 0 44px;
  position: relative;
  overflow: hidden;
}

/* Radial glow accents */
.fd-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(circle at 18% 55%, rgba(13,148,136,0.18) 0%, transparent 55%),
    radial-gradient(circle at 82% 22%, rgba(3,105,161,0.14) 0%, transparent 50%);
  pointer-events: none;
}

/* Dot-grid overlay */
.fd-hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255,255,255,0.055) 1px, transparent 1px);
  background-size: 26px 26px;
  pointer-events: none;
}

.fd-hero__inner {
  position: relative;
  z-index: 1;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
  text-align: center;
}

/* "Our Specialists" label pill */
.fd-hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: rgba(13,148,136,0.18);
  border: 1px solid rgba(13,148,136,0.38);
  color: #5eead4;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  padding: 5px 14px;
  border-radius: 999px;
  margin-bottom: 16px;
}

.fd-hero__eyebrow-dot {
  width: 6px;
  height: 6px;
  background: #2dd4bf;
  border-radius: 50%;
  animation: fd-pulse 2.2s ease-in-out infinite;
}

@keyframes fd-pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%       { opacity: 0.45; transform: scale(0.75); }
}

.fd-hero__title {
  font-size: clamp(24px, 4vw, 40px);
  font-weight: 800;
  color: #fff;
  letter-spacing: -0.025em;
  margin: 0 0 10px;
  line-height: 1.15;
}

.fd-hero__title-accent {
  color: #2dd4bf;
}

.fd-hero__sub {
  color: rgba(255,255,255,0.55);
  font-size: 15px;
  max-width: 480px;
  margin: 0 auto 30px;
  line-height: 1.65;
}


/* ═══════════════════════════════════════════════════════════
   SEARCH BAR — embedded inside the hero
   ═══════════════════════════════════════════════════════════ */

.fd-search {
  max-width: 700px;
  margin: 0 auto;
}

.fd-search__row {
  display: flex;
  gap: 8px;
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.11);
  border-radius: 14px;
  padding: 6px;
  backdrop-filter: blur(10px);
}

.fd-search__input-wrap {
  flex: 1;
  position: relative;
  min-width: 0;
}

.fd-search__icon {
  position: absolute;
  left: 13px;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  color: rgba(255,255,255,0.4);
  pointer-events: none;
}

.fd-search__input {
  width: 100%;
  background: rgba(255,255,255,0.09);
  border: 1px solid rgba(255,255,255,0.11);
  border-radius: 9px;
  padding: 10px 14px 10px 38px;
  font-size: 14px;
  color: #fff;
  outline: none;
  transition: background 0.2s var(--dc-ease), border-color 0.2s var(--dc-ease);
  font-family: inherit;
}

.fd-search__input::placeholder { color: rgba(255,255,255,0.35); }

.fd-search__input:focus {
  background: rgba(255,255,255,0.14);
  border-color: rgba(45,212,191,0.55);
}

.fd-search__btn {
  flex-shrink: 0;
  padding: 10px 22px;
  border-radius: 9px;
  font-size: 13px;
  font-weight: 700;
  border: none;
  cursor: pointer;
  transition: background 0.2s var(--dc-ease), transform 0.15s var(--dc-ease);
  white-space: nowrap;
  font-family: inherit;
}

.fd-search__btn--primary {
  background: var(--dc-teal);
  color: #fff;
}

.fd-search__btn--primary:hover {
  background: #0f766e;
  transform: translateY(-1px);
}

.fd-search__btn--secondary {
  background: rgba(255,255,255,0.08);
  color: rgba(255,255,255,0.65);
  border: 1px solid rgba(255,255,255,0.1);
}

.fd-search__btn--secondary:hover {
  background: rgba(255,255,255,0.14);
  color: #fff;
}


/* ═══════════════════════════════════════════════════════════
   RESULTS SECTION
   ═══════════════════════════════════════════════════════════ */

.fd-results {
  padding: 40px 0 64px;
  background: #f8fafc;
}

.fd-results__inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Result count / meta bar */
.fd-results__meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 26px;
  gap: 12px;
  flex-wrap: wrap;
}

.fd-results__count {
  font-size: 13px;
  color: var(--dc-text-muted);
  font-weight: 500;
}

.fd-results__count strong {
  color: var(--dc-text-head);
  font-weight: 700;
}


/* ═══════════════════════════════════════════════════════════
   DOCTOR GRID
   Desktop: 4 cols → Laptop: 3 → Tablet: 2 → Mobile: 1
   ═══════════════════════════════════════════════════════════ */

.dc-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 22px;
  align-items: start;
}

@media (max-width: 1200px) {
  .dc-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 860px) {
  .dc-grid { grid-template-columns: repeat(2, 1fr); gap: 16px; }
}

@media (max-width: 520px) {
  .dc-grid { grid-template-columns: 1fr; gap: 14px; }
}


/* ═══════════════════════════════════════════════════════════
   DOCTOR CARD
   ═══════════════════════════════════════════════════════════ */

.dc-card {
  background: var(--dc-white);
  border-radius: var(--dc-radius);
  border: 1px solid var(--dc-border);
  box-shadow: var(--dc-shadow);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  position: relative;
  transition:
    transform 0.25s var(--dc-ease),
    box-shadow 0.25s var(--dc-ease),
    border-color 0.25s var(--dc-ease);
  /* Staggered entrance animation */
  opacity: 0;
  animation: dc-fadeUp 0.4s var(--dc-ease) forwards;
}

/* Stagger delays injected via inline style in JS */
@keyframes dc-fadeUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

.dc-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--dc-shadow-hover);
  border-color: rgba(13,148,136,0.3);
}

/* Teal accent line — reveals on hover */
.dc-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, #0d9488, #0ea5e9 60%, #2dd4bf);
  opacity: 0;
  transition: opacity 0.25s var(--dc-ease);
  z-index: 2;
}

.dc-card:hover::before { opacity: 1; }


/* ── Photo zone ─────────────────────────────── */

.dc-card__photo-zone {
  position: relative;
  height: 196px;
  flex-shrink: 0;
  overflow: hidden;
  /* Soft blue-teal gradient placeholder */
  background: linear-gradient(150deg, #e8f4f8 0%, #dff0ec 100%);
}

.dc-card__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  transition: transform 0.45s var(--dc-ease);
}

.dc-card__img--avatar {
  object-fit: contain;
  object-position: center;
  padding: 20px;
}

.dc-card:hover .dc-card__img { transform: scale(1.05); }

/* Gradient fade at the bottom of photo so text floats cleanly */
.dc-card__photo-fade {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 80px;
  background: linear-gradient(to top, rgba(255,255,255,0.96) 0%, transparent 100%);
  pointer-events: none;
}

/* Watermark logo */
.dc-card__watermark {
  position: absolute;
  bottom: 8px; right: 10px;
  width: 44px; height: 44px;
  object-fit: contain;
  opacity: 0.13;
  pointer-events: none;
  user-select: none;
}

/* Specialty pill badge */
.dc-card__specialty {
  position: absolute;
  bottom: 10px;
  left: 12px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(255,255,255,0.96);
  backdrop-filter: blur(6px);
  border: 1px solid rgba(13,148,136,0.22);
  color: var(--dc-teal-dark);
  font-size: 10.5px;
  font-weight: 700;
  padding: 4px 10px 4px 7px;
  border-radius: 999px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.09);
  white-space: nowrap;
  max-width: calc(100% - 24px);
  overflow: hidden;
  text-overflow: ellipsis;
}

.dc-card__specialty-dot {
  width: 6px;
  height: 6px;
  min-width: 6px;
  background: var(--dc-teal);
  border-radius: 50%;
}


/* ── Info body ──────────────────────────────── */

.dc-card__body {
  padding: 15px 18px 12px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 11px;
}

.dc-card__name {
  font-size: 15.5px;
  font-weight: 800;
  color: var(--dc-text-head);
  letter-spacing: -0.015em;
  line-height: 1.3;
  margin: 0 0 3px;
}

.dc-card__quals {
  font-size: 11.5px;
  color: var(--dc-text-muted);
  font-weight: 500;
  line-height: 1.55;
  margin: 0;
}

.dc-card__divider {
  height: 1px;
  background: #f1f5f9;
  margin: 0;
}


/* ── Visiting-hours block ───────────────────── */

.dc-card__schedule {
  background: var(--dc-teal-pale);
  border: 1px solid var(--dc-teal-light);
  border-radius: var(--dc-radius-sm);
  padding: 9px 11px;
}

.dc-card__sched-hdr {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-bottom: 7px;
}

.dc-card__sched-icon {
  width: 12px;
  height: 12px;
  color: var(--dc-teal);
  flex-shrink: 0;
}

.dc-card__sched-label {
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--dc-teal-dark);
}

.dc-card__sched-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
}

.dc-card__slot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(255,255,255,0.75);
  border-radius: 5px;
  padding: 4px 7px;
  gap: 4px;
}

.dc-card__slot-day {
  font-size: 10px;
  font-weight: 700;
  color: var(--dc-teal-dark);
}

.dc-card__slot-time {
  font-size: 9.5px;
  font-weight: 500;
  color: #64748b;
  white-space: nowrap;
}

.dc-card__sched-more {
  display: block;
  width: 100%;
  margin-top: 6px;
  padding: 5px 0;
  font-size: 10px;
  font-weight: 700;
  text-align: center;
  color: var(--dc-teal-dark);
  background: var(--dc-teal-light);
  border: none;
  border-radius: 5px;
  cursor: pointer;
  transition: background 0.2s var(--dc-ease);
  font-family: inherit;
}

.dc-card__sched-more:hover { background: #a7f3e0; }

/* Empty schedule */
.dc-card__no-sched {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 11.5px;
  color: var(--dc-text-muted);
}

.dc-card__no-sched-icon {
  width: 13px;
  height: 13px;
  color: #cbd5e1;
  flex-shrink: 0;
}


/* ── CTA footer ─────────────────────────────── */

.dc-card__footer {
  padding: 0 18px 18px;
}

.dc-card__cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  width: 100%;
  padding: 11px 16px;
  /* Animated gradient — slides left on hover */
  background: linear-gradient(135deg, #0c4a6e 0%, #0369a1 50%, #0ea5e9 100%);
  background-size: 200% 100%;
  background-position: right center;
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  border-radius: var(--dc-radius-sm);
  text-decoration: none;
  letter-spacing: 0.01em;
  box-shadow: 0 4px 14px rgba(14,165,233,0.28);
  transition:
    background-position 0.4s var(--dc-ease),
    box-shadow 0.25s var(--dc-ease),
    transform 0.2s var(--dc-ease);
}

.dc-card__cta:hover {
  background-position: left center;
  box-shadow: 0 6px 22px rgba(14,165,233,0.42);
  transform: translateY(-1px);
}

.dc-card__cta-icon {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}


/* ═══════════════════════════════════════════════════════════
   LOADING / EMPTY / ERROR STATES
   ═══════════════════════════════════════════════════════════ */

.dc-state {
  grid-column: 1 / -1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 80px 24px;
  text-align: center;
}

.dc-state__icon {
  width: 52px;
  height: 52px;
  margin-bottom: 14px;
  color: #cbd5e1;
}

.dc-state__icon--spin {
  color: var(--dc-teal);
  animation: dc-spin 0.75s linear infinite;
}

@keyframes dc-spin { to { transform: rotate(360deg); } }

.dc-state__title {
  font-size: 15px;
  font-weight: 700;
  color: #475569;
  margin: 0 0 5px;
}

.dc-state__sub {
  font-size: 13px;
  color: #94a3b8;
  margin: 0;
}


/* ═══════════════════════════════════════════════════════════
   SCHEDULE MODAL
   ═══════════════════════════════════════════════════════════ */

.dc-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(12,30,60,0.55);
  backdrop-filter: blur(4px);
}

.dc-modal {
  position: relative;
  background: var(--dc-white);
  border-radius: 20px;
  box-shadow: 0 24px 64px rgba(0,0,0,0.22);
  width: 100%;
  max-width: 380px;
  overflow: hidden;
  animation: dc-modalIn 0.2s var(--dc-ease);
}

@keyframes dc-modalIn {
  from { opacity: 0; transform: scale(0.94) translateY(10px); }
  to   { opacity: 1; transform: scale(1) translateY(0); }
}

.dc-modal__head {
  padding: 18px 20px;
  background: linear-gradient(135deg, #0c4a6e, #0369a1);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.dc-modal__head-title {
  font-size: 15px;
  font-weight: 800;
  color: #fff;
  margin: 0 0 2px;
}

.dc-modal__head-sub {
  font-size: 12px;
  color: rgba(255,255,255,0.68);
  margin: 0;
}

.dc-modal__close {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255,255,255,0.15);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  flex-shrink: 0;
  transition: background 0.2s var(--dc-ease);
}

.dc-modal__close:hover { background: rgba(255,255,255,0.26); }

.dc-modal__body { padding: 8px 8px 16px; }

.dc-modal__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  border-radius: 8px;
  font-size: 13px;
}

.dc-modal__row:nth-child(odd) { background: #f8fafc; }

.dc-modal__row-day  { font-weight: 700; color: var(--dc-text-head); }
.dc-modal__row-time { font-weight: 500; color: #64748b; font-size: 12px; }


/* ═══════════════════════════════════════════════════════════
   MOBILE REFINEMENTS
   ═══════════════════════════════════════════════════════════ */

@media (max-width: 640px) {
  .fd-hero { padding: 32px 0 28px; }

  /* Stack search buttons below the input */
  .fd-search__row {
    flex-wrap: wrap;
  }

  .fd-search__input-wrap {
    flex: none;
    width: 100%;
  }

  .fd-search__btn {
    flex: 1;
  }

  .fd-results { padding: 28px 0 48px; }

  .fd-results__inner { padding: 0 16px; }

  /* Touch-friendly CTA */
  .dc-card__cta { padding: 13px 16px; font-size: 14px; }

  .dc-card__footer { padding: 0 14px 14px; }
  .dc-card__body   { padding: 13px 14px 10px; }
}
