:root {
  --grad-primary: linear-gradient(135deg, #0a4d8c 0%, #0f7ea3 45%, #14b8a6 100%);
  --grad-accent: linear-gradient(135deg, #14b8a6 0%, #22c55e 100%);
  --grad-card: linear-gradient(160deg, #ffffff 0%, #f4faf9 100%);
  --color-navy: #0a2b47;
  --color-text: #1c2b36;
  --color-muted: #64748a;
  --color-border: #e4ecf1;
  --color-bg: #f6f9fb;
  --color-white: #ffffff;
  --color-danger: #e0563f;
  --color-success: #1ea672;
  --radius-lg: 20px;
  --radius-md: 14px;
  --radius-sm: 10px;
  --shadow-sm: 0 2px 8px rgba(10, 43, 71, 0.06);
  --shadow-md: 0 8px 24px rgba(10, 43, 71, 0.10);
  --shadow-lg: 0 20px 45px rgba(10, 43, 71, 0.16);
  font-size: 16px;
}

* { box-sizing: border-box; }
/* The `hidden` attribute loses to any author rule that sets `display`
   (e.g. .btn's display:inline-flex, or the compare modal's display:flex) —
   same specificity, and author styles beat the UA stylesheet regardless of
   source order. Without this, elements marked hidden="" render anyway. */
[hidden] { display: none !important; }

body {
  margin: 0;
  font-family: "Segoe UI", -apple-system, BlinkMacSystemFont, Roboto, Helvetica, Arial, sans-serif;
  background: var(--color-bg);
  color: var(--color-text);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }
button { font-family: inherit; cursor: pointer; }

.container {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- Top bar ---------- */
.topbar {
  background: var(--color-navy);
  color: #cfe4f0;
  font-size: 0.8rem;
  padding: 8px 0;
}
.topbar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.topbar strong { color: #7fe6c9; }

/* ---------- Header ---------- */
header.site-header {
  background: var(--color-white);
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: var(--shadow-sm);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0;
  gap: 20px;
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 1.35rem;
  letter-spacing: -0.02em;
}
.logo-mark {
  width: 34px;
  height: 34px;
  flex-shrink: 0;
}
.logo-text {
  display: flex;
  flex-direction: column;
  line-height: 1.05;
}
.logo-text .za {
  font-size: 1.12rem;
  background: var(--grad-primary);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.logo-text .suffix {
  font-size: 0.62rem;
  font-weight: 700;
  color: var(--color-muted);
  letter-spacing: 0.12em;
  margin-top: 2px;
}
nav.main-nav {
  display: flex;
  gap: 28px;
  font-weight: 600;
  font-size: 0.92rem;
  color: var(--color-text);
}
nav.main-nav a {
  position: relative;
  padding: 6px 0;
  transition: color 0.2s ease;
}
nav.main-nav a:hover { color: #0f7ea3; }
nav.main-nav a.active { color: #0f7ea3; }
nav.main-nav a.active::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -2px;
  height: 2px;
  background: var(--grad-accent);
  border-radius: 2px;
}
.header-cta {
  display: flex;
  align-items: center;
  gap: 14px;
}
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: var(--radius-lg);
  font-weight: 700;
  font-size: 0.9rem;
  border: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
}
.btn-primary {
  background: var(--grad-primary);
  color: #fff;
  box-shadow: var(--shadow-md);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); filter: brightness(1.05); }
.btn-outline {
  background: transparent;
  border: 1.5px solid var(--color-border);
  color: var(--color-text);
}
.btn-outline:hover { border-color: #0f7ea3; color: #0f7ea3; transform: translateY(-2px); }
/* Unified keyboard-focus style, matching .faq-q/select — visible on Tab, silent on mouse click. */
.btn:focus-visible,
.badge-copy-btn:focus-visible,
.compare-check:focus-visible {
  outline: 2px solid #0f7ea3;
  outline-offset: 2px;
}
/* .cta-banner sits on --grad-primary, which passes through #0f7ea3 itself — swap to a
   color that stays visible against the dark gradient instead of blending into it. */
.cta-banner .btn:focus-visible {
  outline-color: #ffffff;
}
.menu-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.6rem;
  color: var(--color-navy);
}

/* ---------- Breadcrumb ---------- */
.breadcrumb {
  padding: 14px 0 0;
  font-size: 0.82rem;
  color: var(--color-muted);
}
.breadcrumb a:hover { color: #0f7ea3; }
.breadcrumb .sep { margin: 0 6px; }

/* ---------- Hero ---------- */
.hero {
  background: var(--grad-primary);
  border-radius: var(--radius-lg);
  margin: 20px auto 0;
  color: #fff;
  padding: 48px 40px;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 85% 20%, rgba(255,255,255,0.16), transparent 55%);
  pointer-events: none;
}
.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255,255,255,0.18);
  border: 1px solid rgba(255,255,255,0.3);
  padding: 6px 16px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  backdrop-filter: blur(4px);
}
.hero-tag .dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: #7fffb0;
  box-shadow: 0 0 0 3px rgba(127,255,176,0.3);
  animation: pulse 1.8s infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}
.hero h1 {
  font-size: clamp(1.9rem, 4vw, 2.7rem);
  margin: 18px 0 10px;
  letter-spacing: -0.01em;
  max-width: 700px;
}
.hero p.lead {
  max-width: 640px;
  color: #dcf1ee;
  font-size: 1.02rem;
  margin: 0 0 26px;
}
.hero-meta {
  display: flex;
  gap: 10px;
  align-items: center;
  font-size: 0.82rem;
  color: #cbe9e5;
  margin-bottom: 30px;
  flex-wrap: wrap;
}
.hero-meta b { color: #fff; }
.hero-stats {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}
.stat-pill {
  background: rgba(10,43,71,0.5);
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: var(--radius-lg);
  padding: 16px 22px;
  min-width: 140px;
  backdrop-filter: blur(6px);
  transition: transform 0.2s ease, background 0.2s ease;
}
.stat-pill:hover { transform: translateY(-3px); background: rgba(10,43,71,0.6); }
.stat-pill .num {
  font-size: 1.5rem;
  font-weight: 800;
  display: block;
}
.stat-pill .label {
  font-size: 0.76rem;
  color: #d3ede9;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* ---------- Disclaimer banner ---------- */
.disclaimer-banner {
  background: #fff6ea;
  border: 1px solid #f6d9a8;
  border-radius: var(--radius-md);
  margin: 18px auto 0;
  padding: 14px 20px;
  font-size: 0.83rem;
  color: #7a5316;
  display: flex;
  gap: 10px;
  align-items: flex-start;
}
.disclaimer-banner strong { color: #4d3208; }

/* ---------- Filters ---------- */
.filters-bar {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 18px 24px;
  margin: 26px auto 0;
  box-shadow: var(--shadow-sm);
}
.filter-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--color-muted);
  text-transform: uppercase;
  letter-spacing: 0.03em;
}
.filter-group select {
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--color-text);
  background: var(--color-white);
  min-width: 170px;
}
.filter-group select:focus { outline: 2px solid #14b8a6; }
.results-count {
  margin-left: auto;
  font-size: 0.88rem;
  color: var(--color-muted);
  font-weight: 600;
}
.results-count b { color: var(--color-navy); }

/* ---------- Price cards ---------- */
.price-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
  margin: 24px auto 0;
}
.price-card {
  background: var(--grad-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 22px 24px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
  position: relative;
}
.price-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
  border-color: #b7ded8;
}
.price-card.best {
  border: 2px solid #14b8a6;
  background: linear-gradient(160deg, #ecfdf7 0%, #ffffff 60%);
}
.badge-best {
  position: absolute;
  top: -12px;
  left: 20px;
  background: var(--grad-accent);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 800;
  padding: 5px 14px;
  border-radius: 999px;
  box-shadow: var(--shadow-sm);
  letter-spacing: 0.03em;
}
.card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.pharmacy-id {
  display: flex;
  align-items: center;
  gap: 12px;
}
.pharmacy-logo {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.95rem;
  color: #fff;
  flex-shrink: 0;
}
/* Real pharmacy/supplier logos: one fixed-size neutral tile for every brand so
   mixed aspect ratios (wordmarks vs square marks) never change row height. */
.pharmacy-logo-wrap {
  width: 64px;
  height: 64px;
  border-radius: 12px;
  background: #fff;
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  position: relative;
}
.pharmacy-logo-wrap img {
  width: 86%;
  height: 86%;
  object-fit: contain;
  display: block;
}
.pharmacy-logo-wrap .pharmacy-logo-fallback {
  width: 100%;
  height: 100%;
  border-radius: 12px;
  display: none;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.95rem;
  color: #fff;
}
.pharmacy-name { font-weight: 700; font-size: 1rem; white-space: nowrap; }
.pharmacy-name-link {
  color: inherit;
  font-weight: inherit;
  font-size: inherit;
  text-decoration: none;
  cursor: pointer;
}
.pharmacy-name-link:hover,
.pharmacy-name-link:focus-visible {
  text-decoration: underline;
  color: var(--color-success);
}
.pharmacy-type {
  font-size: 0.72rem;
  color: var(--color-muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}
.tag-row { display: flex; gap: 6px; flex-wrap: wrap; }
.tag {
  white-space: nowrap;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
  background: #eaf6f4;
  color: #0f7a6c;
}
.tag.stock-out { background: #fdecec; color: #c0392b; }
.tag.rx { background: #eef2ff; color: #4338ca; }

.card-mid {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  border-top: 1px dashed var(--color-border);
  border-bottom: 1px dashed var(--color-border);
  padding: 12px 0;
}
.product-name { font-weight: 700; font-size: 0.95rem; color: var(--color-navy); }
.dose-chip {
  font-size: 0.72rem;
  color: var(--color-muted);
  font-weight: 600;
}
.price-block { text-align: right; }
.price-value {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--color-navy);
}
.price-sub { font-size: 0.72rem; color: var(--color-muted); }
.save-badge {
  display: inline-block;
  white-space: nowrap;
  margin-top: 4px;
  font-size: 0.72rem;
  font-weight: 800;
  color: #177f57;
  background: #e8f8ef;
  padding: 3px 9px;
  border-radius: 999px;
}

.card-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.delivery-note {
  font-size: 0.78rem;
  color: var(--color-muted);
  display: flex;
  align-items: center;
  gap: 6px;
}
.view-btn {
  background: var(--grad-primary);
  color: #fff;
  border-radius: var(--radius-sm);
  padding: 10px 20px;
  font-weight: 700;
  font-size: 0.85rem;
  border: none;
  white-space: nowrap;
  transition: transform 0.18s ease, filter 0.18s ease;
}
.view-btn:hover { transform: translateY(-2px); filter: brightness(1.08); }
.view-btn:disabled {
  background: #d7dfe6;
  color: #55616d;
  cursor: not-allowed;
}
.view-btn:disabled:hover { transform: none; }

/* ---------- Brand explainer ---------- */
.section-heading {
  text-align: center;
  margin: 64px auto 30px;
  max-width: 640px;
}
.section-heading .kicker {
  color: #0f7ea3;
  font-weight: 800;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.section-heading h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  margin: 10px 0 8px;
  color: var(--color-navy);
}
.section-heading p { color: var(--color-muted); }

.brand-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.brand-card {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 26px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.brand-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.brand-icon {
  width: 52px; height: 52px;
  border-radius: var(--radius-sm);
  background: var(--grad-primary);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-weight: 800;
  font-size: 1.1rem;
  margin-bottom: 16px;
}
.brand-card h3 { margin: 0 0 6px; font-size: 1.1rem; color: var(--color-navy); }
.brand-card p { margin: 0 0 14px; color: var(--color-muted); font-size: 0.9rem; }
.brand-card .brand-price { font-weight: 800; color: #0f7ea3; font-size: 0.95rem; }

/* ---------- Suppliers strip ---------- */
.supplier-strip {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 30px;
  margin: 40px auto 0;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 16px;
  text-align: center;
}
.supplier-strip .pharmacy-logo,
.supplier-strip .pharmacy-logo-wrap { margin: 0 auto 8px; }
.supplier-strip .s-name { font-weight: 700; font-size: 0.85rem; }
.supplier-strip .s-count { font-size: 0.72rem; color: var(--color-muted); }
.supplier-strip a { display: block; color: inherit; text-decoration: none; }
.supplier-strip a:hover .s-name { color: #0f7ea3; }
.supplier-strip .s-link { display: inline-block; margin-top: 8px; font-size: 0.72rem; font-weight: 700; color: #0f7ea3; }
.supplier-strip .supplier-url { display: block; margin-top: 4px; font-size: 0.7rem; color: #0f7ea3; text-decoration: none; word-break: break-word; }

/* Compact variant: fewer than 5 cards (e.g. telehealth providers) —
   fixed-width columns + justify-content so the row centers instead of
   hugging the left edge of the 5-column pharmacy grid. */
.supplier-strip-compact {
  grid-template-columns: repeat(3, minmax(160px, 220px));
  justify-content: center;
}

/* ---------- FAQ ---------- */
.faq {
  max-width: 780px;
  margin: 0 auto;
}
.faq-item {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  margin-bottom: 12px;
  overflow: hidden;
}
.faq-q {
  width: 100%;
  padding: 18px 22px;
  font-weight: 700;
  font-size: inherit;
  text-align: left;
  background: none;
  border: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  color: var(--color-navy);
}
.faq-q:focus-visible {
  outline: 2px solid #0f7ea3;
  outline-offset: -2px;
}
.faq-q .chev { transition: transform 0.2s ease; color: #0f7ea3; }
.faq-item.open .faq-q .chev { transform: rotate(180deg); }
.faq-a {
  padding: 0 22px;
  max-height: 0;
  overflow: hidden;
  color: var(--color-muted);
  font-size: 0.92rem;
  transition: max-height 0.25s ease, padding 0.25s ease;
}
.faq-item.open .faq-a { padding: 0 22px 20px; max-height: 300px; }

/* ---------- Newsletter ---------- */
.newsletter {
  background: var(--grad-primary);
  border-radius: var(--radius-lg);
  margin: 60px auto 0;
  padding: 40px;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}
.newsletter h2 { margin: 0 0 6px; font-size: 1.4rem; }
.newsletter p { margin: 0; color: #dcf1ee; font-size: 0.92rem; }
.newsletter form {
  display: flex;
  gap: 10px;
  flex: 1;
  max-width: 420px;
  min-width: 260px;
}
.newsletter input {
  flex: 1;
  min-width: 0;
  padding: 13px 18px;
  border-radius: var(--radius-lg);
  border: none;
  font-size: 0.9rem;
}
.newsletter button {
  background: #fff;
  color: #0a4d8c;
  border-radius: var(--radius-lg);
  padding: 13px 22px;
  font-weight: 800;
  border: none;
  white-space: nowrap;
  flex-shrink: 0;
  transition: transform 0.18s ease;
}
.newsletter button:hover { transform: translateY(-2px); }

/* ---------- Footer ---------- */
footer.site-footer {
  margin-top: 60px;
  background: var(--color-navy);
  color: #a9c2d3;
  padding: 50px 0 24px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 30px;
  padding-bottom: 30px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}
.footer-grid h3 { color: #fff; font-size: 0.9rem; margin: 0 0 14px; }
.footer-grid ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; font-size: 0.85rem; }
.footer-grid ul a:hover { color: #fff; }
.footer-about p { font-size: 0.85rem; line-height: 1.6; color: #93aec1; max-width: 320px; }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 20px;
  font-size: 0.78rem;
  color: #7d97aa;
  flex-wrap: wrap;
  gap: 10px;
}
.footer-legal {
  font-size: 0.72rem;
  color: #7e94a5;
  line-height: 1.6;
  padding-top: 18px;
  max-width: 900px;
}

/* ---------- Page hero (secondary pages) ---------- */
.page-hero {
  background: var(--grad-primary);
  border-radius: var(--radius-lg);
  margin: 20px auto 0;
  color: #fff;
  padding: 40px 40px;
  position: relative;
  overflow: hidden;
}
.page-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 85% 20%, rgba(255,255,255,0.16), transparent 55%);
  pointer-events: none;
}
.page-hero h1 { font-size: clamp(1.7rem, 3.6vw, 2.4rem); margin: 14px 0 10px; max-width: 720px; }
.page-hero p.lead { max-width: 680px; color: #dcf1ee; font-size: 1rem; margin: 0; }

/* ---------- Intro / body copy ---------- */
.prose { max-width: 820px; margin: 30px auto 0; color: var(--color-text); }
.prose h2 { color: var(--color-navy); font-size: 1.4rem; margin: 38px 0 12px; }
.prose h3 { color: var(--color-navy); font-size: 1.12rem; margin: 24px 0 8px; }
.prose p { margin: 0 0 14px; color: #3b4a58; }
.prose ul, .prose ol { margin: 0 0 16px; padding-left: 22px; color: #3b4a58; }
.prose li { margin-bottom: 8px; }
.prose a { color: #0f7ea3; font-weight: 600; text-decoration: underline; text-decoration-color: rgba(15,126,163,0.35); }

/* ---------- Comparison table (Clicks vs Dis-Chem etc) ---------- */
.compare-table-wrap {
  overflow-x: auto;
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  margin: 26px auto 0;
  box-shadow: var(--shadow-sm);
}
table.compare-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 560px;
  font-size: 0.92rem;
}
table.compare-table th, table.compare-table td {
  padding: 14px 18px;
  text-align: left;
  border-bottom: 1px solid var(--color-border);
}
table.compare-table th {
  background: #f4f9fb;
  color: var(--color-navy);
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-weight: 800;
}
table.compare-table tr:last-child td { border-bottom: none; }
table.compare-table tr:hover td { background: #f9fcfd; }
table.compare-table td.price-cell { font-weight: 800; color: var(--color-navy); }
table.compare-table td.win-cell { color: var(--color-success); font-weight: 800; }

/* ---------- Verdict box ---------- */
.verdict-box {
  background: linear-gradient(160deg, #ecfdf7 0%, #ffffff 60%);
  border: 2px solid #14b8a6;
  border-radius: var(--radius-lg);
  padding: 26px 28px;
  margin: 26px auto 0;
  display: flex;
  gap: 18px;
  align-items: flex-start;
}
.verdict-box .emoji { font-size: 1.8rem; }
.verdict-box h3 { margin: 0 0 6px; color: var(--color-navy); }
.verdict-box p { margin: 0; color: #3b4a58; }

/* ---------- Steps ---------- */
.steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  margin: 26px auto 0;
}
.step-card {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 22px 20px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.step-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.step-num {
  width: 38px; height: 38px;
  border-radius: 50%;
  background: var(--grad-accent);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-weight: 800;
  margin-bottom: 14px;
}
.step-card h3 { margin: 0 0 6px; font-size: 1rem; color: var(--color-navy); }
.step-card p { margin: 0; font-size: 0.86rem; color: var(--color-muted); }

/* ---------- Process steps (telehealth "how it works", vertical) ---------- */
.process-steps { display: flex; flex-direction: column; gap: 12px; }
.process-step {
  display: flex;
  gap: 16px;
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 16px 18px;
}
.process-step .step-num { width: 34px; height: 34px; font-size: 0.85rem; flex-shrink: 0; margin-bottom: 0; }
.process-step-body h3 { margin: 0 0 4px; font-size: 0.95rem; color: var(--color-navy); }
.process-step-body p { margin: 0; font-size: 0.85rem; color: var(--color-muted); }

/* ---------- Supplier profile layout ---------- */
.supplier-header-card {
  display: flex;
  align-items: center;
  gap: 20px;
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 26px;
  margin-top: 22px;
  flex-wrap: wrap;
}
.supplier-header-card .pharmacy-logo-wrap { flex-shrink: 0; }
.shc-main { flex: 1 1 260px; min-width: 220px; }
.shc-title-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.shc-title-row h1 { margin: 0; }
.s-badge {
  display: inline-block;
  background: #eaf2f8;
  color: var(--color-navy);
  font-size: 0.72rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}
.shc-url {
  display: inline-block;
  margin-top: 6px;
  font-size: 0.85rem;
  color: #0f7ea3;
  text-decoration: none;
}
.shc-url:hover { text-decoration: underline; }
.shc-stats { margin-top: 10px; font-size: 0.85rem; color: var(--color-muted); }
.shc-stats strong { color: var(--color-navy); }
.shc-sep { margin: 0 6px; }
.shc-cta { flex-shrink: 0; }

.supplier-layout {
  display: grid;
  grid-template-columns: 7fr 3fr;
  gap: 30px;
  margin-top: 40px;
  align-items: start;
}
@media (max-width: 900px) {
  .supplier-layout { grid-template-columns: 1fr; }
}

.item-row-list { display: flex; flex-direction: column; gap: 12px; }
.item-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 16px 18px;
}
.item-row-name { font-weight: 700; font-size: 1rem; color: var(--color-navy); }
.item-row-meta { font-size: 0.8rem; color: var(--color-muted); margin-top: 2px; }
.item-row-right { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; flex-shrink: 0; }
.item-row-price { font-weight: 800; font-size: 1rem; color: var(--color-navy); white-space: nowrap; }

/* ---------- Expanded per-dose product rows (supplier pages) ---------- */
.product-group-heading {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin: 0 0 14px;
  font-size: 1.02rem;
  color: var(--color-navy);
}
.product-group-count { font-size: 0.78rem; font-weight: 600; color: var(--color-muted); }
.product-row-list { display: flex; flex-direction: column; gap: 12px; }
.product-row {
  display: flex;
  align-items: center;
  gap: 16px;
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 14px 18px;
}
.product-photo {
  width: 64px;
  height: 64px;
  flex-shrink: 0;
  border-radius: var(--radius-sm);
  border: 1px solid var(--color-border);
  background: var(--color-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.product-photo img { width: 100%; height: 100%; object-fit: contain; }
/* <picture> is a pure resource-selection wrapper here — display:contents keeps
   the <img> itself as the flex child .product-photo lays out, same as before. */
.product-photo picture { display: contents; }
.product-photo-fallback {
  display: none;
  width: 100%;
  height: 100%;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  color: var(--color-muted);
}
.product-row-main { flex: 1 1 auto; min-width: 0; }
.product-row-right { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; flex-shrink: 0; }
.product-compare-link { font-size: 0.78rem; font-weight: 700; color: #0f7ea3; white-space: nowrap; }

@media (max-width: 640px) {
  .product-row { flex-wrap: wrap; }
  .product-row-right { align-items: flex-start; margin-left: 80px; }
}

.sidebar-card {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 20px;
  margin-bottom: 20px;
}
.sidebar-card.muted { background: var(--color-bg); }
.sidebar-card h3 { margin: 0 0 12px; font-size: 0.95rem; color: var(--color-navy); }
.sidebar-card-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.sidebar-card-head h3 { margin: 0; }
.sc-counter {
  font-size: 0.72rem;
  font-weight: 800;
  color: #177f57;
  background: #e8f8ef;
  padding: 3px 9px;
  border-radius: 999px;
}
.kv-row { display: flex; justify-content: space-between; gap: 10px; padding: 8px 0; border-top: 1px solid var(--color-border); font-size: 0.85rem; }
.kv-row:first-of-type { border-top: none; padding-top: 0; }
.kv-label { color: var(--color-muted); flex-shrink: 0; }
.kv-value { color: var(--color-text); text-align: right; }
.rating-line { font-size: 1.1rem; font-weight: 800; color: var(--color-navy); }
.rating-line span { font-size: 0.85rem; font-weight: 600; color: var(--color-muted); }
.rating-meta { font-size: 0.78rem; color: var(--color-muted); margin: 4px 0 10px; }
.pc-list li.unconfirmed { color: var(--color-muted); }
.pc-list li.unconfirmed::before { content: "– "; color: var(--color-muted); font-weight: 700; }

/* ---------- Supplier badge promo (sidebar) ---------- */
.badge-promo-sub {
  font-size: 0.82rem;
  color: var(--color-muted);
  margin: -6px 0 14px;
}
.badge-preview {
  display: flex;
  justify-content: center;
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 18px;
  margin-bottom: 14px;
}
.badge-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: 999px;
  padding: 8px 14px;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--color-text);
  box-shadow: var(--shadow-sm);
}
.badge-pill-icon { width: 18px; height: 18px; flex-shrink: 0; }
.badge-embed-label {
  display: block;
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--color-muted);
  margin-bottom: 8px;
}
.badge-embed-box { position: relative; }
.badge-embed-code {
  width: 100%;
  resize: vertical;
  height: 90px;
  overflow-y: auto;
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  padding-right: 66px;
  font-family: "Courier New", Courier, monospace;
  font-size: 0.7rem;
  line-height: 1.5;
  color: var(--color-text);
  background: var(--color-bg);
}
.badge-copy-btn {
  position: absolute;
  top: 10px;
  right: 10px;
  background: var(--grad-primary);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  padding: 6px 12px;
  font-size: 0.76rem;
  font-weight: 700;
  transition: filter 0.15s ease;
}
.badge-copy-btn:hover { filter: brightness(1.08); }
.badge-copy-btn.copied { background: var(--color-success); }

/* ---------- Pharmacy compare grid ---------- */
.pharmacy-compare-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin: 26px auto 0;
}
.pharmacy-compare-card {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 24px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.pharmacy-compare-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.pharmacy-compare-card .pc-head { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.pharmacy-compare-card h3 { margin: 0; font-size: 1.05rem; color: var(--color-navy); }
.pharmacy-compare-card .pc-list { list-style: none; padding: 0; margin: 0; font-size: 0.86rem; color: #3b4a58; display: flex; flex-direction: column; gap: 8px; }
.pharmacy-compare-card .pc-list li::before { content: "✓ "; color: #1ea672; font-weight: 800; }
.pharmacy-compare-card .pc-cta {
  display: inline-block;
  margin-top: 16px;
  font-weight: 700;
  font-size: 0.85rem;
  color: #0f7ea3;
}

/* ---------- Timeline ---------- */
.timeline { max-width: 760px; margin: 26px auto 0; position: relative; padding-left: 28px; }
.timeline::before { content: ""; position: absolute; left: 8px; top: 6px; bottom: 6px; width: 2px; background: var(--color-border); }
.timeline-item { position: relative; padding-bottom: 26px; }
.timeline-item::before {
  content: "";
  position: absolute;
  left: -28px;
  top: 4px;
  width: 14px; height: 14px;
  border-radius: 50%;
  background: var(--grad-accent);
  box-shadow: 0 0 0 4px #eafaf4;
}
.timeline-item .t-date { font-weight: 800; color: #0f7ea3; font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.03em; }
.timeline-item h3 { margin: 4px 0 6px; color: var(--color-navy); font-size: 1.02rem; }
.timeline-item p { margin: 0; color: var(--color-muted); font-size: 0.9rem; }

/* ---------- Warning box ---------- */
.warning-box {
  background: #fdecec;
  border: 1px solid #f3b8ae;
  border-radius: var(--radius-md);
  padding: 18px 22px;
  margin: 26px auto 0;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  font-size: 0.9rem;
  color: #7a2418;
}
.warning-box strong { color: #5c1a10; }

/* ---------- Info cards grid (generic 2/3 col) ---------- */
.info-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin: 26px auto 0; }
.info-grid.cols-2 { grid-template-columns: repeat(2, 1fr); }
.info-grid.cols-4 { grid-template-columns: repeat(4, 1fr); }
.info-card {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 24px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.info-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.info-card h3 { margin: 0 0 8px; color: var(--color-navy); font-size: 1.02rem; }
.info-card p { margin: 0; color: var(--color-muted); font-size: 0.9rem; }

/* ---------- Simple contact form ---------- */
.contact-form {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 30px;
  margin: 26px auto 0;
  max-width: 620px;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.contact-form label { font-weight: 700; font-size: 0.85rem; color: var(--color-navy); display: flex; flex-direction: column; gap: 6px; }
.contact-form input, .contact-form textarea, .contact-form select {
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  font-size: 0.92rem;
  font-family: inherit;
  color: var(--color-text);
}
.contact-form textarea { resize: vertical; min-height: 120px; }
.contact-form button.btn { align-self: flex-start; }

/* ---------- CTA banner (reuse newsletter style, generic) ---------- */
.cta-banner {
  background: var(--grad-primary);
  border-radius: var(--radius-lg);
  margin: 50px auto 0;
  padding: 36px 40px;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}
.cta-banner h2 { margin: 0 0 6px; font-size: 1.3rem; }
.cta-banner p { margin: 0; color: #dcf1ee; font-size: 0.92rem; }

/* ---------- Profile tab nav ---------- */
html { scroll-behavior: smooth; }
[id^="profile-"], #compare-prices { scroll-margin-top: 100px; }
.profile-tabs {
  display: flex;
  justify-content: center;
  gap: 6px;
  overflow-x: auto;
  margin: 22px auto 0;
  padding-bottom: 6px;
}
.profile-tabs a {
  flex-shrink: 0;
  padding: 9px 18px;
  border-radius: 999px;
  font-size: 0.84rem;
  font-weight: 700;
  color: var(--color-muted);
  background: var(--color-white);
  border: 1px solid var(--color-border);
  white-space: nowrap;
  transition: all 0.18s ease;
}
.profile-tabs a:hover { color: #0f7ea3; border-color: #b7ded8; }
.profile-tabs a.active {
  background: var(--grad-primary);
  color: #fff;
  border-color: transparent;
}

/* ---------- Price comparison table (horizontal) ---------- */
.price-table .pharmacy-id { display: flex; align-items: center; gap: 10px; }
.price-table .pharmacy-name { font-size: 0.92rem; }
.price-table .pharmacy-type { font-size: 0.72rem; }
.price-table td.price-cell,
.price-table td.mg-cell {
  white-space: nowrap;
}
.price-table .price-cell .price-value {
  font-size: 0.98rem;
  white-space: nowrap;
}
.price-table .price-cell .save-badge {
  display: block;
  width: fit-content;
  margin-top: 3px;
  font-size: 0.625rem;
  padding: 2px 7px;
}
.price-table .not-yet-sold { font-size: 0.78rem; }
.price-table .tag {
  font-size: 0.625rem;
  padding: 3px 8px;
}
.price-table .view-btn {
  font-size: 0.75rem;
  padding: 8px 14px;
}
.price-table td.mg-cell {
  font-size: 0.88rem;
  color: var(--color-muted);
}
.price-table tbody tr.best-row td { background: #f3fdf9; }

/* Column widths for the price table only (the shared .compare-table on other
   pages has a different, simpler set of columns and must not be affected). */
table.compare-table.price-table {
  table-layout: fixed;
  min-width: 0;
}
table.compare-table.price-table col.col-compare { width: 6%; }
table.compare-table.price-table col.col-supplier { width: 27%; }
table.compare-table.price-table col.col-price { width: 12%; }
table.compare-table.price-table col.col-mg { width: 11%; }
table.compare-table.price-table col.col-stock { width: 10%; }
table.compare-table.price-table col.col-delivery { width: 14%; }
table.compare-table.price-table col.col-quality { width: 9%; }
table.compare-table.price-table col.col-visit { width: 11%; }
table.compare-table.price-table th,
table.compare-table.price-table td {
  padding: 12px 10px;
  overflow: hidden;
}
.pharmacy-logo-wrap.price-table-logo { width: 44px; height: 44px; }
.price-table .delivery-badge { white-space: nowrap; font-size: 0.75rem; }
.price-table .pharmacy-name {
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

@media (max-width: 900px) {
  table.compare-table.price-table { font-size: 0.82rem; }
  table.compare-table.price-table th,
  table.compare-table.price-table td { padding: 10px 6px; }
  .pharmacy-logo-wrap.price-table-logo { width: 32px; height: 32px; }
}
.price-table tbody tr.row-compare td { background: #eef6ff; }
.price-table input[type="checkbox"] { width: 16px; height: 16px; accent-color: #0f7ea3; cursor: pointer; }
.compare-count { font-weight: 700; color: #0f7ea3; margin-left: 10px; }
.table-footnote { font-size: 0.78rem; color: var(--color-muted); margin: 10px 4px 0; }

/* ---------- Compare selected — button + limit hint ---------- */
.compare-open-btn { margin-left: 10px; padding: 8px 16px; font-size: 0.85rem; }
.compare-limit-hint { font-size: 0.78rem; color: var(--color-muted); margin-left: 10px; }
.price-table input[type="checkbox"].compare-check:disabled { cursor: not-allowed; opacity: 0.4; accent-color: var(--color-muted); }

/* ---------- Compare modal ---------- */
.compare-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 20, 35, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  z-index: 200;
}
.compare-modal {
  background: var(--color-white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  max-width: 720px;
  width: 100%;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.compare-modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 22px;
  border-bottom: 1px solid var(--color-border);
  flex-shrink: 0;
}
.compare-modal-head h2 { margin: 0; font-size: 1.15rem; }
.compare-modal-close {
  background: none;
  border: none;
  font-size: 1.2rem;
  line-height: 1;
  color: var(--color-muted);
  cursor: pointer;
  padding: 6px;
  border-radius: var(--radius-sm);
}
.compare-modal-close:hover { color: var(--color-text); background: var(--color-bg); }
.compare-modal-body { padding: 18px 22px 22px; overflow: auto; }
.compare-modal-table { width: 100%; border-collapse: collapse; font-size: 0.88rem; }
.compare-modal-table th {
  text-align: left;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--color-muted);
  padding: 8px 10px;
  border-bottom: 2px solid var(--color-border);
  white-space: nowrap;
}
.compare-modal-table td { padding: 10px; border-bottom: 1px solid var(--color-border); vertical-align: top; }
.compare-modal-table tr:last-child td { border-bottom: none; }
.compare-modal-remove {
  background: none;
  border: none;
  color: var(--color-muted);
  font-size: 1rem;
  line-height: 1;
  cursor: pointer;
  padding: 6px;
  border-radius: var(--radius-sm);
}
.compare-modal-remove:hover { color: var(--color-danger); background: var(--color-bg); }
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
@media (max-width: 640px) {
  .compare-modal-overlay { padding: 0; align-items: flex-end; }
  .compare-modal { max-width: none; max-height: 90vh; border-radius: var(--radius-lg) var(--radius-lg) 0 0; }
  .compare-modal-body { overflow-x: auto; }
  .compare-modal-table { min-width: 480px; }
}

/* ---------- Calculator tools (/tools/) ---------- */
.calc-form {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 30px;
  margin: 26px auto 0;
  box-shadow: var(--shadow-sm);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 18px;
  align-items: end;
}
/* Dosage Calculator's Product / Pen / Dose row -- a nested grid so the three
   inputs stay on one visual baseline even when one column (Pen, with its
   field-hint line) is taller than the others. */
.dosage-row {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  align-items: start;
}
.dosage-col { min-width: 0; }

.calc-form label {
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--color-navy);
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.calc-form label[hidden] { display: none; }
.calc-form input, .calc-form select {
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  font-size: 0.92rem;
  font-family: inherit;
  color: var(--color-text);
}
.calc-form input:focus, .calc-form select:focus { outline: 2px solid #14b8a6; }
.calc-form .field-hint { font-size: 0.72rem; font-weight: 600; color: var(--color-muted); margin-top: 2px; }
.calc-form-actions { grid-column: 1 / -1; display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.calc-form-error { color: var(--color-danger); font-size: 0.85rem; font-weight: 700; }

.calc-result { margin-top: 30px; }
.calc-result[hidden] { display: none; }

.calc-entry-list { display: flex; flex-direction: column; gap: 10px; margin: 20px auto 0; }
.calc-entry-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 14px 18px;
}
.calc-entry-row .item-row-name { font-weight: 700; color: var(--color-navy); }
.calc-entry-row .item-row-meta { font-size: 0.8rem; color: var(--color-muted); margin-top: 2px; }
.calc-entry-remove {
  background: none;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  color: var(--color-muted);
  font-size: 0.78rem;
  font-weight: 700;
  padding: 6px 10px;
  cursor: pointer;
  flex-shrink: 0;
}
.calc-entry-remove:hover { border-color: var(--color-danger); color: var(--color-danger); }

.disclaimer-note {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 14px 18px;
  margin: 24px auto 0;
  font-size: 0.82rem;
  color: var(--color-muted);
  max-width: 900px;
}
.disclaimer-note strong { color: var(--color-navy); }

@media (max-width: 640px) {
  .calc-form { grid-template-columns: 1fr; padding: 22px; }
  .calc-entry-row { flex-direction: column; align-items: stretch; text-align: left; }
}

/* ---------- Profile overview header / benefits / quick stats ---------- */
.profile-header {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 4px;
}
.profile-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #eafaf4;
  color: #0f7a6c;
  font-weight: 800;
  font-size: 0.78rem;
  padding: 6px 14px;
  border-radius: 999px;
  letter-spacing: 0.02em;
  white-space: nowrap;
}
.profile-subtitle {
  color: var(--color-muted);
  font-weight: 700;
  font-size: 0.92rem;
}
.benefit-list {
  list-style: none;
  padding: 0;
  margin: 0 0 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.benefit-list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.94rem;
  color: #3b4a58;
}
.benefit-list li::before {
  content: "\2713";
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--grad-accent);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 2px;
}
.quick-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin: 10px 0 16px;
}
.quick-stat {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 16px 18px;
}
.quick-stat .qs-label {
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #0f7ea3;
  margin-bottom: 6px;
}
.quick-stat .qs-value {
  font-size: 0.86rem;
  color: var(--color-navy);
  font-weight: 600;
  line-height: 1.4;
}

/* ---------- Molecular sequence display ---------- */
.sequence-code {
  font-family: "Courier New", Courier, monospace;
  background: var(--color-navy);
  color: #7fe6c9;
  padding: 14px 18px;
  border-radius: var(--radius-md);
  font-size: 0.82rem;
  letter-spacing: 0.02em;
  line-height: 1.7;
  word-break: break-word;
  margin: 14px 0;
}
.sequence-legend {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin: 14px 0;
  font-size: 0.8rem;
  color: var(--color-muted);
  font-weight: 600;
}
.sequence-legend .legend-item { display: flex; align-items: center; gap: 6px; }
.legend-dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }
.sequence-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(68px, 1fr));
  gap: 8px;
  margin: 6px 0 22px;
}
.aa-chip {
  border-radius: 10px;
  padding: 8px 4px 7px;
  text-align: center;
  font-size: 0.74rem;
  font-weight: 800;
  color: #fff;
  cursor: default;
  transition: transform 0.15s ease;
}
.aa-chip:hover { transform: translateY(-2px); }
.aa-chip .aa-pos {
  display: block;
  font-size: 0.6rem;
  opacity: 0.9;
  font-weight: 700;
  margin-top: 3px;
}
.aa-chip.hydrophobic { background: #6b7fd7; }
.aa-chip.polar { background: #14b8a6; }
.aa-chip.positive { background: #e0563f; }
.aa-chip.negative { background: #0f7ea3; }
.aa-chip.modified { background: #a855f7; }

/* ---------- Indications ---------- */
.indication-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin: 4px 0 22px;
}
.indication-tag {
  background: #eef2ff;
  color: #4338ca;
  font-weight: 700;
  font-size: 0.78rem;
  padding: 6px 14px;
  border-radius: 999px;
}
.indication-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 22px;
}
.indication-item {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 20px 22px;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}
.indication-item:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }
.indication-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}
.indication-head h3 { margin: 0; font-size: 1rem; color: var(--color-navy); }
.indication-badge {
  font-size: 0.7rem;
  font-weight: 800;
  padding: 4px 12px;
  border-radius: 999px;
  white-space: nowrap;
}
.indication-badge.approved { background: #eafaf4; color: #0f7a6c; }
.indication-badge.offlabel { background: #fff4e0; color: #b06a00; }
.indication-item p { margin: 0; color: var(--color-muted); font-size: 0.9rem; }

/* ---------- Dosing protocol panels ---------- */
.dosing-panel {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 26px 28px;
  margin-bottom: 22px;
}
.dosing-panel-head {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  margin-bottom: 18px;
}
.dosing-format-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--grad-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  flex-shrink: 0;
}
.dosing-panel-head h3 { margin: 0 0 4px; color: var(--color-navy); font-size: 1.05rem; }
.dosing-panel-head p { margin: 0; color: var(--color-muted); font-size: 0.88rem; }
.dosing-panel h3 { margin: 18px 0 10px; color: var(--color-navy); font-size: 0.92rem; }
.dosing-panel .compare-table-wrap { margin: 0; }
.dosing-panel .benefit-list { margin: 0; }

/* ---------- Safety grid ---------- */
.safety-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin: 14px 0 20px;
}
.safety-card {
  border-radius: var(--radius-lg);
  padding: 22px 24px;
  border: 1px solid var(--color-border);
}
.safety-card h3 {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 14px;
  font-size: 0.95rem;
  color: var(--color-navy);
}
.safety-card ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 9px; }
.safety-card li {
  font-size: 0.88rem;
  color: #3b4a58;
  padding-left: 18px;
  position: relative;
}
.safety-card li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 7px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
}
.safety-card.common { background: #f4f9fb; }
.safety-card.common li::before { background: #0f7ea3; }
.safety-card.monitoring { background: #eef8f6; }
.safety-card.monitoring li::before { background: #14b8a6; }
.safety-card.stop { background: #fff8f0; border-color: #f6d9a8; }
.safety-card.stop li::before { background: #e0563f; }
.safety-card.contra { background: #fdecec; border-color: #f3b8ae; }
.safety-card.contra li::before { background: #c0392b; }

/* ---------- Quality checklist ---------- */
.quality-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin: 14px 0 20px;
}
.quality-card {
  border-radius: var(--radius-lg);
  padding: 22px 24px;
  border: 1px solid var(--color-border);
}
.quality-card h3 {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 14px;
  font-size: 0.95rem;
  color: var(--color-navy);
}
.quality-card ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; }
.quality-card li { font-size: 0.88rem; color: #3b4a58; display: flex; align-items: flex-start; gap: 8px; }
.quality-card li::before { flex-shrink: 0; font-weight: 800; font-size: 0.85rem; margin-top: 1px; }
.quality-card.good { background: #eafaf4; border-color: #b7ded8; }
.quality-card.good li::before { content: "\2713"; color: #1ea672; }
.quality-card.warn { background: #fff8f0; border-color: #f6d9a8; }
.quality-card.warn li::before { content: "!"; color: #b06a00; }
.quality-card.bad { background: #fdecec; border-color: #f3b8ae; }
.quality-card.bad li::before { content: "\2715"; color: #c0392b; }

/* ---------- Mobile ---------- */
@media (max-width: 960px) {
  .profile-tabs { justify-content: flex-start; }
  nav.main-nav { display: none; }
  nav.main-nav.mobile-open {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--color-white);
    padding: 18px 24px;
    box-shadow: var(--shadow-md);
    gap: 16px;
  }
  header.site-header { position: sticky; }
  .header-inner { position: relative; }
  .menu-toggle { display: block; }
  .price-list { grid-template-columns: 1fr; }
  .brand-grid { grid-template-columns: 1fr; }
  .supplier-strip { grid-template-columns: repeat(2, 1fr); }
  .supplier-strip-compact { grid-template-columns: repeat(3, minmax(140px, 200px)); justify-content: center; }
  .dosage-row { grid-template-columns: repeat(2, 1fr); }
  .dosage-row .dosage-col:nth-child(3) { grid-column: 1 / -1; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .pharmacy-compare-grid { grid-template-columns: 1fr; }
  .info-grid, .info-grid.cols-2, .info-grid.cols-4 { grid-template-columns: 1fr; }
  .quick-stats { grid-template-columns: repeat(2, 1fr); }
  .safety-grid { grid-template-columns: 1fr; }
  .quality-grid { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .hero, .page-hero { padding: 34px 22px; }
  .filters-bar { padding: 16px; }
  .results-count { margin-left: 0; width: 100%; }
  .newsletter, .cta-banner { flex-direction: column; text-align: center; }
  .newsletter form { width: 100%; }
  .footer-grid { grid-template-columns: 1fr; }
  .card-bottom { flex-direction: column; align-items: stretch; }
  .view-btn { width: 100%; }
  .steps { grid-template-columns: 1fr; }
  .verdict-box { flex-direction: column; }
  .quick-stats { grid-template-columns: 1fr; }
  .sequence-grid { grid-template-columns: repeat(auto-fill, minmax(52px, 1fr)); }
  .supplier-strip-compact { grid-template-columns: 1fr; }
  .dosage-row { grid-template-columns: 1fr; }
}

/* Price table → cards below 1050px. Avoids horizontal scroll and text
   squeezed unreadably small; each row becomes a self-contained card.
   Raised from 640px on 2026-08-17: table-layout:fixed made the Price/mg
   column clip its text (no ellipsis) between ~641-1030px well before any
   scrollbar would appear — measured truncation stops at 1050px. */
@media (max-width: 1050px) {
  .price-table-wrap {
    overflow-x: visible;
    background: transparent;
    border: none;
    box-shadow: none;
    border-radius: 0;
  }
  table.compare-table.price-table { table-layout: auto; font-size: 0.92rem; }
  .price-table thead { display: none; }
  .price-table, .price-table tbody { display: block; width: 100%; }
  .price-table tbody tr {
    display: block;
    position: relative;
    background: var(--color-white);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: 16px;
    max-width: 640px;
    margin: 0 auto 12px;
    box-shadow: var(--shadow-sm);
  }
  .price-table tbody tr:last-child { margin-bottom: 0; }
  .price-table td { display: block; padding: 0; border: none; overflow: visible; }
  .price-table .pharmacy-name { overflow: visible; text-overflow: clip; }
  /* Compare checkbox: top-right corner of the card */
  .price-table td:nth-child(1) { position: absolute; top: 16px; right: 16px; }
  /* Supplier: card title, full width */
  .price-table td:nth-child(2) { padding-right: 30px; margin-bottom: 10px; }
  .pharmacy-logo-wrap.price-table-logo { width: 44px; height: 44px; }
  /* Price / Price-mg / Stock / Delivery / Quality: labelled rows */
  .price-table td:nth-child(3),
  .price-table td:nth-child(4),
  .price-table td:nth-child(5),
  .price-table td:nth-child(6),
  .price-table td:nth-child(7) {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    padding: 9px 0;
    border-top: 1px solid var(--color-border);
  }
  .price-table td:nth-child(3)::before { content: "Price"; }
  .price-table td:nth-child(4)::before { content: "Price / mg"; }
  .price-table td:nth-child(5)::before { content: "Stock"; }
  .price-table td:nth-child(6)::before { content: "Delivery"; }
  .price-table td:nth-child(7)::before { content: "Quality"; }
  .price-table td:nth-child(3)::before,
  .price-table td:nth-child(4)::before,
  .price-table td:nth-child(5)::before,
  .price-table td:nth-child(6)::before,
  .price-table td:nth-child(7)::before {
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: var(--color-muted);
    flex-shrink: 0;
  }
  .price-table .price-cell-value { text-align: right; }
  /* Visit: full-width button at the bottom of the card */
  .price-table td:nth-child(8) { margin-top: 10px; }
}
