:root {
  --ink-950: #12181f;
  --ink-800: #1e2732;
  --teal-700: #155f6b;
  --teal-600: #1c7683;
  --teal-100: #e6f3f4;
  --teal-50: #f4f9fa;
  --brass: #b8863c;
  --brass-100: #fbf1e0;
  --paper: #f6f7f9;
  --card: #ffffff;
  --line: #e7eaee;
  --line-soft: #f0f2f4;
  --text-900: #151b24;
  --text-600: #4c5666;
  --text-400: #8a94a3;
  --success-t: #1d8f5e;
  --success-bg: #e7f7ef;
  --success-bd: #cdeddb;
  --r-lg: 18px;
  --r-md: 12px;
  --r-sm: 9px;
  --shadow-card:
    0 1px 2px rgba(10, 18, 31, 0.04), 0 12px 30px -14px rgba(10, 18, 31, 0.12);
  --shadow-pop: 0 20px 45px -18px rgba(10, 18, 31, 0.22);
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--paper);
  color: var(--text-900);
  font-family: "Inter", sans-serif;
  -webkit-font-smoothing: antialiased;
}
html::-webkit-scrollbar {
  display: none;
}
.serif {
  font-family: "Source Serif 4", serif;
}
.num {
  font-variant-numeric: tabular-nums;
}

/* ============ TOP NAV ============ */
.topnav {
  background: var(--ink-950);
  color: #e7eaee;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 40px;
  position: sticky;
  top: 0;
  z-index: 40;
}
.brand {
  display: flex;
  align-items: center;
  gap: 11px;
}
.brand-mark {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: linear-gradient(150deg, var(--teal-600), var(--ink-800));
  border: 1px solid rgba(184, 134, 60, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 10px -2px rgba(28, 118, 131, 0.4);
}
.brand-text .name {
  font-family: "Source Serif 4", serif;
  font-weight: 600;
  font-size: 17px;
  color: #fff;
  line-height: 1.1;
}
.brand-text .sub {
  font-size: 9.5px;
  color: var(--brass);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin-top: 2px;
  font-weight: 600;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 30px;
}
.nav-links a {
  color: #b7c0cc;
  text-decoration: none;
  font-size: 13.6px;
  font-weight: 500;
}
.nav-links a.active {
  color: #fff;
  font-weight: 600;
}
.nav-right {
  display: flex;
  align-items: center;
  gap: 16px;
}
.nav-icon {
  color: #b7c0cc;
  cursor: pointer;
}
.nav-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--brass), #8a6a32);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: "Source Serif 4", serif;
  font-weight: 600;
  font-size: 13px;
}

/* ============ HERO / SEARCH ============ */
.hero {
  background: linear-gradient(175deg, var(--ink-950) 0%, #16202b 100%);
  padding: 44px 40px 92px;
  color: #fff;
  text-align: center;
  position: relative;
}
.hero-eyebrow {
  font-size: 11.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--brass);
  font-weight: 700;
  margin-bottom: 12px;
}
.hero h1 {
  font-family: "Source Serif 4", serif;
  font-size: clamp(26px, 3vw, 36px);
  font-weight: 600;
  margin: 0 0 10px;
  letter-spacing: -0.01em;
}
.hero p {
  font-size: 14.5px;
  color: #aab4c0;
  margin: 0 auto 30px;
  max-width: 520px;
}

.search-panel {
  max-width: 980px;
  margin: 0 auto;
  background: var(--card);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-pop);
  padding: 8px;
  text-align: left;
  position: relative;
  z-index: 2;
}
.search-row {
  display: flex;
  align-items: center;
  gap: 4px;
}
.search-field {
  flex: 1.5;
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 14px 18px;
  border-right: 1px solid var(--line-soft);
}
.search-field.loc {
  flex: 1;
}
.search-field svg {
  color: var(--text-400);
  flex-shrink: 0;
}
.search-field input {
  border: none;
  outline: none;
  font-size: 14px;
  width: 100%;
  font-family: "Inter", sans-serif;
  color: var(--text-900);
  background: none;
}
.search-field input::placeholder {
  color: var(--text-400);
}
.search-field .fl {
  display: flex;
  flex-direction: column;
  width: 100%;
}
.search-field .fl label {
  font-size: 10px;
  font-weight: 700;
  color: var(--text-400);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 2px;
}
.btn-find {
  display: flex;
  align-items: center;
  gap: 9px;
  background: linear-gradient(135deg, var(--teal-600), var(--teal-700));
  color: #fff;
  border: none;
  padding: 0 26px;
  height: 52px;
  border-radius: 12px;
  font-size: 14.5px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 8px 20px -8px rgba(21, 95, 107, 0.5);
  flex-shrink: 0;
}

.stat-row {
  display: flex;
  justify-content: center;
  gap: 44px;
  margin-top: 30px;
  flex-wrap: wrap;
}
.stat {
  text-align: center;
}
.stat .v {
  font-family: "Source Serif 4", serif;
  font-size: 21px;
  font-weight: 600;
  color: #fff;
}
.stat .l {
  font-size: 11px;
  color: #8994a2;
  margin-top: 3px;
  letter-spacing: 0.03em;
}

/* ============ BODY LAYOUT ============ */
.body-wrap {
  max-width: 1280px;
  margin: -52px auto 60px;
  padding: 0 40px;
  display: grid;
  grid-template-columns: 270px 1fr;
  gap: 24px;
  align-items: start;
  position: relative;
  z-index: 3;
}

/* FILTER SIDEBAR */
.filters-card {
  background: var(--card);
  border: 1px solid var(--line-soft);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-card);
  padding: 22px 20px;
}
.filters-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
}
.filters-head h3 {
  font-size: 14.5px;
  font-weight: 700;
  margin: 0;
}
.filters-reset {
  font-size: 12px;
  font-weight: 600;
  color: var(--teal-700);
  cursor: pointer;
}
.f-group {
  margin-bottom: 22px;
}
.f-group:last-child {
  margin-bottom: 0;
}
.f-label {
  font-size: 11.5px;
  font-weight: 700;
  color: var(--text-600);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 11px;
}
.f-chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}
.f-chip {
  padding: 7px 13px;
  border-radius: 20px;
  border: 1.3px solid var(--line);
  font-size: 12.4px;
  font-weight: 600;
  color: var(--text-600);
  cursor: pointer;
  background: #fff;
}
.f-chip.active {
  background: var(--teal-100);
  border-color: var(--teal-600);
  color: var(--teal-700);
}
.f-check-list {
  display: flex;
  flex-direction: column;
  gap: 11px;
}
.f-check {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13.2px;
  color: var(--text-600);
  cursor: pointer;
}
.f-check input {
  width: 15px;
  height: 15px;
  accent-color: var(--teal-600);
}
.f-check .fc-count {
  margin-left: auto;
  font-size: 11.5px;
  color: var(--text-400);
}
.range-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  color: var(--text-400);
  margin-bottom: 8px;
  font-weight: 600;
}
.range-track {
  height: 5px;
  border-radius: 3px;
  background: var(--line-soft);
  position: relative;
}
.range-fill {
  position: absolute;
  left: 8%;
  right: 35%;
  top: 0;
  bottom: 0;
  background: var(--teal-600);
  border-radius: 3px;
}
.range-handle {
  position: absolute;
  top: 50%;
  width: 15px;
  height: 15px;
  border-radius: 50%;
  background: #fff;
  border: 2.5px solid var(--teal-600);
  transform: translate(-50%, -50%);
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.15);
}
.stars-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 0;
  cursor: pointer;
}
.stars {
  display: flex;
  gap: 1px;
  color: var(--brass);
}

/* RESULTS */
.results-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  flex-wrap: wrap;
  gap: 10px;
}
.results-count {
  font-size: 13.6px;
  color: var(--text-600);
}
.results-count b {
  color: var(--text-900);
}
.sort-row {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 13px;
  color: var(--text-600);
}
.sort-select {
  border: 1.3px solid var(--line);
  border-radius: var(--r-sm);
  padding: 8px 12px;
  font-size: 13px;
  color: var(--text-900);
  background: #fff;
  font-family: "Inter", sans-serif;
}

.doctor-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.doc-card {
  background: var(--card);
  border: 1px solid var(--line-soft);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-card);
  padding: 22px;
  display: flex;
  gap: 20px;
  align-items: flex-start;
  transition:
    box-shadow 0.15s,
    border-color 0.15s;
}
.doc-card:hover {
  box-shadow: 0 6px 20px -8px rgba(10, 18, 31, 0.14);
  border-color: var(--line);
}
.doc-photo {
  width: 78px;
  height: 78px;
  border-radius: 16px;
  flex-shrink: 0;
  position: relative;
  background: linear-gradient(150deg, var(--teal-600), var(--ink-800));
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: "Source Serif 4", serif;
  font-weight: 600;
  font-size: 24px;
}
.doc-photo .online-dot {
  position: absolute;
  bottom: 2px;
  right: 2px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--success-t);
  border: 2.5px solid #fff;
}
.doc-main {
  flex: 1;
  min-width: 0;
}
.doc-top-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}
.doc-name {
  font-family: "Source Serif 4", serif;
  font-size: 17.5px;
  font-weight: 600;
  color: var(--text-900);
  display: flex;
  align-items: center;
  gap: 8px;
}
.verified {
  color: var(--teal-600);
  flex-shrink: 0;
}
.doc-spec {
  font-size: 13px;
  color: var(--teal-700);
  font-weight: 600;
  margin-top: 3px;
}
.doc-meta {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: 9px;
  font-size: 12.6px;
  color: var(--text-400);
}
.doc-meta span {
  display: flex;
  align-items: center;
  gap: 5px;
}
.rating-badge {
  display: flex;
  align-items: center;
  gap: 5px;
  background: var(--brass-100);
  color: #8a6a32;
  padding: 4px 10px;
  border-radius: 8px;
  font-size: 12.4px;
  font-weight: 700;
  flex-shrink: 0;
}
.doc-tags {
  display: flex;
  gap: 7px;
  margin-top: 12px;
  flex-wrap: wrap;
}
.tag {
  font-size: 11px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 6px;
  background: var(--paper);
  color: var(--text-600);
  border: 1px solid var(--line-soft);
}
.tag.top {
  background: var(--brass-100);
  color: #8a6a32;
  border-color: transparent;
}

.doc-side {
  width: 190px;
  flex-shrink: 0;
  text-align: right;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
}
.fee {
  font-family: "Source Serif 4", serif;
  font-size: 20px;
  font-weight: 600;
  color: var(--text-900);
}
.fee span {
  font-size: 12px;
  color: var(--text-400);
  font-weight: 400;
  font-family: "Inter", sans-serif;
}
.next-slot {
  font-size: 12px;
  color: var(--success-t);
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 5px;
}
.btn-book {
  width: 100%;
  padding: 11px;
  border-radius: var(--r-sm);
  border: none;
  background: linear-gradient(135deg, var(--teal-600), var(--teal-700));
  color: #fff;
  font-size: 13.4px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 6px 14px -6px rgba(21, 95, 107, 0.4);
}
.btn-view {
  width: 100%;
  padding: 10px;
  border-radius: var(--r-sm);
  border: 1.3px solid var(--line);
  background: #fff;
  color: var(--text-600);
  font-size: 12.8px;
  font-weight: 600;
  cursor: pointer;
}

.load-more {
  display: block;
  margin: 26px auto 0;
  padding: 12px 30px;
  border-radius: var(--r-sm);
  border: 1.3px solid var(--line);
  background: #fff;
  font-size: 13.4px;
  font-weight: 700;
  color: var(--text-600);
  cursor: pointer;
  box-shadow: var(--shadow-card);
}

@media (max-width: 980px) {
  .body-wrap {
    grid-template-columns: 1fr;
    margin-top: -30px;
  }
  .filters-card {
    position: static;
  }
}
@media (max-width: 720px) {
  .topnav {
    padding: 14px 18px;
  }
  .nav-links {
    display: none;
  }
  .hero {
    padding: 32px 18px 70px;
  }
  .search-row {
    flex-direction: column;
  }
  .search-field {
    border-right: none;
    border-bottom: 1px solid var(--line-soft);
    width: 100%;
  }
  .btn-find {
    width: calc(100% - 16px);
    margin: 8px;
    height: 48px;
  }
  .body-wrap {
    padding: 0 16px;
  }
  .doc-card {
    flex-direction: column;
  }
  .doc-side {
    width: 100%;
    align-items: stretch;
    text-align: left;
  }
  .fee {
    text-align: left;
  }
  .stat-row {
    gap: 26px;
  }
}
