/* ============================================
   Tennessee Rheumatology — Design System
   ============================================ */

:root {
  --navy: #14324a;
  --navy-dark: #0c2130;
  --navy-light: #1f4a68;
  --ink: #1c2a2f;
  --terracotta: #bb5f36;
  --terracotta-dark: #a24f2a;
  --sage: #71876f;
  --sage-light: #eef1e9;
  --sand: #f7f2ea;
  --sand-deep: #efe7d8;
  --white: #ffffff;
  --line: #e3dccd;
  --muted: #5c6a6e;

  --font-display: "Fraunces", "Iowan Old Style", "Georgia", serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --container: 1200px;
  --radius: 14px;
  --radius-sm: 8px;
  --shadow-sm: 0 1px 3px rgba(20, 50, 74, 0.08), 0 1px 2px rgba(20, 50, 74, 0.06);
  --shadow-md: 0 8px 24px rgba(20, 50, 74, 0.10);
  --shadow-lg: 0 20px 48px rgba(12, 33, 48, 0.16);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  line-height: 1.6;
}

img { max-width: 100%; display: block; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  color: var(--navy-dark);
  line-height: 1.15;
  margin: 0 0 0.5em;
  font-weight: 600;
}

h1 { font-size: clamp(2.4rem, 4.4vw, 3.6rem); font-weight: 500; }
h2 { font-size: clamp(1.9rem, 3vw, 2.5rem); font-weight: 500; }
h3 { font-size: 1.35rem; }
p { margin: 0 0 1em; color: var(--muted); }

a { color: inherit; text-decoration: none; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--terracotta);
  margin-bottom: 14px;
}
.eyebrow::before {
  content: "";
  width: 22px;
  height: 2px;
  background: var(--terracotta);
  display: inline-block;
}

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

section { padding: 88px 0; }
@media (max-width: 780px) { section { padding: 56px 0; } }

.section-head { max-width: 680px; margin-bottom: 48px; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.section-head p { font-size: 1.08rem; }

.bg-sand { background: var(--sand); }
.bg-navy { background: var(--navy); color: rgba(255,255,255,0.92); }
.bg-navy h2, .bg-navy h3 { color: var(--white); }
.bg-navy p { color: rgba(255,255,255,0.72); }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 26px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.96rem;
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease, color 0.15s ease, border-color .15s ease;
  white-space: nowrap;
}
.btn svg { width: 17px; height: 17px; flex-shrink: 0; }
.btn-primary { background: var(--terracotta); color: var(--white); box-shadow: var(--shadow-sm); }
.btn-primary:hover { background: var(--terracotta-dark); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-ghost { background: transparent; border-color: rgba(255,255,255,0.4); color: var(--white); }
.btn-ghost:hover { border-color: #fff; background: rgba(255,255,255,0.08); }
.btn-outline { background: transparent; border-color: var(--navy); color: var(--navy); }
.btn-outline:hover { background: var(--navy); color: #fff; }
.btn-sand { background: var(--white); color: var(--navy); }
.btn-sand:hover { background: var(--sand-deep); transform: translateY(-1px); }
.btn-block { width: 100%; }

/* ============ Header ============ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 28px;
  max-width: var(--container);
  margin: 0 auto;
  gap: 24px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}
.brand img { width: 40px; height: 40px; object-fit: contain; opacity: 0.9; }
.brand-text { font-family: var(--font-display); line-height: 1.1; }
.brand-text .name { display: block; font-size: 1.18rem; font-weight: 600; color: var(--navy-dark); }
.brand-text .doc { display: block; font-size: 0.72rem; letter-spacing: 0.06em; color: var(--terracotta); text-transform: uppercase; font-family: var(--font-body); font-weight: 600; margin-top: 2px; }

.main-nav { display: flex; align-items: center; gap: 26px; }
.main-nav a {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--ink);
  position: relative;
  padding: 6px 0;
  white-space: nowrap;
}
.main-nav a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 2px;
  background: var(--terracotta);
  transform: scaleX(0);
  transition: transform 0.2s ease;
}
.main-nav a:hover::after, .main-nav a.active::after { transform: scaleX(1); }
.main-nav a.active { color: var(--terracotta); }

.header-cta { display: flex; align-items: center; gap: 14px; flex-shrink: 0; }
.header-phone { display: flex; align-items: center; gap: 8px; font-weight: 600; color: var(--navy-dark); font-size: 0.95rem; }
.header-phone svg { width: 17px; height: 17px; color: var(--terracotta); }

.nav-toggle { display: none; background: none; border: none; cursor: pointer; padding: 6px; }
.nav-toggle svg { width: 26px; height: 26px; color: var(--navy-dark); }

@media (max-width: 980px) {
  .main-nav { position: fixed; inset: 68px 0 0 0; background: var(--white); flex-direction: column; align-items: flex-start; padding: 28px; gap: 8px; transform: translateX(100%); transition: transform 0.25s ease; overflow-y: auto; }
  .main-nav.open { transform: translateX(0); }
  .main-nav a { font-size: 1.15rem; padding: 12px 0; width: 100%; border-bottom: 1px solid var(--line); }
  .header-phone span { display: none; }
  .nav-toggle { display: block; }
}

/* ============ Hero ============ */
.hero {
  position: relative;
  color: var(--white);
  min-height: 84vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}
.hero-media { position: absolute; inset: 0; z-index: 0; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; object-position: 30% 82%; }
.hero-media::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(105deg, rgba(9,26,38,0.96) 0%, rgba(12,33,48,0.9) 32%, rgba(15,40,56,0.78) 58%, rgba(20,50,74,0.68) 100%);
}
.hero-content { position: relative; z-index: 1; max-width: 640px; padding: 120px 0 90px; }
.hero-content .eyebrow { color: #e2a67f; }
.hero-content .eyebrow::before { background: #e2a67f; }
.hero h1 { color: var(--white); margin-bottom: 22px; }
.hero-lead { font-size: 1.15rem; color: rgba(255,255,255,0.82); max-width: 540px; margin-bottom: 34px; }
.hero-actions { display: flex; gap: 16px; flex-wrap: wrap; margin-bottom: 44px; }
.hero-facts { display: flex; gap: 34px; flex-wrap: wrap; padding-top: 30px; border-top: 1px solid rgba(255,255,255,0.18); }
.hero-facts div strong { display: block; font-family: var(--font-display); font-size: 1.5rem; color: var(--white); font-weight: 600; }
.hero-facts div span { font-size: 0.82rem; color: rgba(255,255,255,0.65); }

/* Page banner (interior pages) */
.page-banner { position: relative; color: #fff; padding: 150px 0 70px; overflow: hidden; }
.page-banner-media { position: absolute; inset: 0; z-index: 0; }
.page-banner-media img { width: 100%; height: 100%; object-fit: cover; }
.page-banner-media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(120deg, rgba(9,26,38,0.94), rgba(20,50,74,0.8)); }
.page-banner-content { position: relative; z-index: 1; max-width: 640px; }
.page-banner h1 { color: #fff; margin-bottom: 12px; }
.page-banner .eyebrow { color: #e2a67f; }
.page-banner .eyebrow::before { background: #e2a67f; }
.page-banner p { color: rgba(255,255,255,0.78); font-size: 1.05rem; max-width: 560px; }
.breadcrumb { font-size: 0.85rem; color: rgba(255,255,255,0.55); margin-bottom: 18px; }
.breadcrumb a:hover { color: #fff; }

/* ============ Trust strip ============ */
.trust-strip { background: var(--navy-dark); padding: 20px 0; }
.trust-strip .container { display: flex; flex-wrap: wrap; gap: 28px; justify-content: space-between; align-items: center; }
.trust-item { display: flex; align-items: center; gap: 10px; color: rgba(255,255,255,0.85); font-size: 0.92rem; font-weight: 500; }
.trust-item svg { width: 19px; height: 19px; color: #e2a67f; flex-shrink: 0; }

/* ============ Two column ============ */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; }
.split.reverse .split-media { order: 2; }
.split-media img { border-radius: var(--radius); box-shadow: var(--shadow-lg); width: 100%; aspect-ratio: 4/3.1; object-fit: cover; }
.split-media.frame { position: relative; }
.split-media.frame::before {
  content: "";
  position: absolute; top: -18px; left: -18px; right: 18px; bottom: 18px;
  border: 2px solid var(--terracotta);
  border-radius: var(--radius);
  z-index: -1;
}
@media (max-width: 900px) {
  .split { grid-template-columns: 1fr; gap: 36px; }
  .split.reverse .split-media { order: 0; }
}

.lead-text { font-size: 1.1rem; color: var(--ink); }

.checklist { list-style: none; padding: 0; margin: 22px 0; display: grid; gap: 12px; }
.checklist li { display: flex; align-items: flex-start; gap: 12px; color: var(--ink); font-size: 0.98rem; }
.checklist svg { width: 20px; height: 20px; color: var(--sage); flex-shrink: 0; margin-top: 2px; }

/* ============ Cards / Grids ============ */
.grid { display: grid; gap: 26px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 980px) { .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 620px) { .grid-3, .grid-4, .grid-2 { grid-template-columns: 1fr; } }

.card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 32px 28px;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color .2s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); border-color: transparent; }
.card .icon-wrap {
  width: 54px; height: 54px;
  border-radius: 14px;
  background: var(--sage-light);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 20px;
}
.card .icon-wrap svg { width: 28px; height: 28px; color: var(--sage); }
.card h3 { margin-bottom: 8px; font-size: 1.15rem; }
.card p { margin-bottom: 0; font-size: 0.94rem; }
.card .tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.card .tags span { font-size: 0.72rem; background: var(--sand); color: var(--muted); padding: 4px 10px; border-radius: 999px; }

.condition-card { text-align: left; }
.condition-card.large { grid-column: span 2; display: flex; gap: 24px; align-items: flex-start; background: var(--navy); border-color: var(--navy); }
.condition-card.large h3, .condition-card.large p { color: #fff; }
.condition-card.large p { color: rgba(255,255,255,0.75); }
.condition-card.large .icon-wrap { background: rgba(255,255,255,0.12); flex-shrink: 0; }
.condition-card.large .icon-wrap svg { color: #e2a67f; }
@media (max-width: 620px) { .condition-card.large { grid-column: span 1; flex-direction: column; } }

/* ============ Provider profile ============ */
.provider {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 48px;
  padding: 48px 0;
  border-bottom: 1px solid var(--line);
}
.provider:last-child { border-bottom: none; }
.provider-photo { border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-md); }
.provider-photo img { width: 100%; aspect-ratio: 3/3.6; object-fit: cover; }
.provider-name { font-size: 1.7rem; margin-bottom: 2px; }
.provider-role { color: var(--terracotta); font-weight: 600; font-size: 0.9rem; text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 18px; display: block; }
.provider-body p { font-size: 1rem; }
.provider-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.provider-tags span { font-size: 0.8rem; background: var(--sage-light); color: var(--sage); padding: 6px 14px; border-radius: 999px; font-weight: 600; }
@media (max-width: 760px) {
  .provider { grid-template-columns: 1fr; }
  .provider-photo { max-width: 240px; }
}

/* ============ Stats ============ */
.stats-bar { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; text-align: center; }
.stats-bar .stat strong { display: block; font-family: var(--font-display); font-size: 2.4rem; color: var(--navy-dark); font-weight: 600; }
.stats-bar .stat span { color: var(--muted); font-size: 0.88rem; }
@media (max-width: 760px) { .stats-bar { grid-template-columns: repeat(2, 1fr); gap: 32px; } }

/* ============ Insurance ============ */
.insurance-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px 32px; }
.insurance-grid .group h4 { font-size: 0.82rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--terracotta); margin-bottom: 14px; }
.insurance-grid ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.insurance-grid li { display: flex; align-items: center; gap: 10px; font-size: 0.95rem; color: var(--ink); }
.insurance-grid li svg { width: 16px; height: 16px; color: var(--sage); flex-shrink: 0; }
@media (max-width: 780px) { .insurance-grid { grid-template-columns: 1fr; gap: 28px; } }

/* ============ Forms page ============ */
.form-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  transition: box-shadow .2s ease, transform .2s ease;
}
.form-card:hover { box-shadow: var(--shadow-md); transform: translateY(-4px); }
.form-card .icon-wrap { width: 52px; height: 52px; border-radius: 12px; background: var(--sand-deep); display: flex; align-items: center; justify-content: center; }
.form-card .icon-wrap svg { width: 26px; height: 26px; color: var(--terracotta); }
.form-card h3 { margin-bottom: 4px; }
.form-card p { font-size: 0.9rem; margin-bottom: 4px; }
.steps { display: grid; gap: 20px; counter-reset: step; }
.steps li { list-style: none; display: flex; gap: 18px; }
.steps li::before {
  counter-increment: step;
  content: counter(step);
  flex-shrink: 0;
  width: 34px; height: 34px;
  border-radius: 50%;
  background: var(--navy);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-display); font-weight: 600; font-size: 0.95rem;
}

/* ============ Contact ============ */
.contact-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px;
  display: flex; gap: 16px; align-items: flex-start;
}
.contact-card .icon-wrap { width: 46px; height: 46px; border-radius: 12px; background: var(--sage-light); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.contact-card .icon-wrap svg { width: 22px; height: 22px; color: var(--sage); }
.contact-card h4 { margin-bottom: 4px; font-size: 1rem; font-family: var(--font-body); font-weight: 700; }
.contact-card p, .contact-card a { font-size: 0.95rem; margin-bottom: 2px; }
.contact-card a:hover { color: var(--terracotta); }

.hours-table { width: 100%; border-collapse: collapse; }
.hours-table td { padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 0.95rem; }
.hours-table td:last-child { text-align: right; font-weight: 600; color: var(--navy-dark); }

.map-wrap { border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-md); border: 1px solid var(--line); }
.map-wrap iframe { width: 100%; height: 100%; min-height: 420px; border: 0; display: block; }

/* ============ CTA banner ============ */
.cta-banner {
  background: linear-gradient(120deg, var(--navy-dark), var(--navy));
  border-radius: 22px;
  padding: 60px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 30px;
  color: #fff;
  flex-wrap: wrap;
}
.cta-banner h2 { color: #fff; margin-bottom: 8px; }
.cta-banner p { color: rgba(255,255,255,0.7); margin-bottom: 0; }
.cta-actions { display: flex; gap: 14px; flex-wrap: wrap; }
@media (max-width: 760px) { .cta-banner { padding: 40px 28px; text-align: center; justify-content: center; } }

/* ============ Footer ============ */
.site-footer { background: var(--navy-dark); color: rgba(255,255,255,0.65); padding: 72px 0 28px; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.2fr; gap: 40px; padding-bottom: 48px; border-bottom: 1px solid rgba(255,255,255,0.1); }
.footer-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.footer-brand img { width: 36px; height: 36px; opacity: 0.85; filter: invert(1) brightness(1.8); }
.footer-brand span { font-family: var(--font-display); color: #fff; font-size: 1.1rem; font-weight: 600; }
.site-footer h5 { color: #fff; font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 18px; font-family: var(--font-body); font-weight: 700; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 11px; }
.site-footer a:hover { color: #fff; }
.site-footer p { color: rgba(255,255,255,0.55); font-size: 0.92rem; }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; padding-top: 26px; flex-wrap: wrap; gap: 12px; font-size: 0.82rem; color: rgba(255,255,255,0.45); }
.footer-bottom a:hover { color: #fff; }
@media (max-width: 900px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .footer-grid { grid-template-columns: 1fr; } }

/* Utility */
.mt-0 { margin-top: 0; }
.text-center { text-align: center; }
.muted-sm { font-size: 0.85rem; color: var(--muted); }
