/*
 * Rozhdestvensky clinic UI
 * A warm, editorial medical system built around trust, clarity and real people.
 */

:root {
  --ink: #20342f;
  --lime: #57bb54;
  --lime-hover: #50aa4d;
  --green: #477b49;
  --green-2: #3f7342;
  --green-deep: #173d24;
  --hero-surface: #e8f4e4;
  --hero-accent: #57bb54;
  --hero-accent-hover: #50aa4d;
  --hero-emphasis: #477b49;
  --brand-soft: #d5e8cf;
  --brand-panel: #b7d8ad;
  --warm-section: #f1e8dc;
  --sage: #ddeed9;
  --sage-soft: #f1f7ee;
  --blush: #efd9d5;
  --rose: #b96f72;
  --rose-deep: #94565b;
  --peach: #e5b7a1;
  --cream: #f6f1e9;
  --paper: #fffdfa;
  --white: #fff;
  --muted: #687871;
  --line: rgba(23, 61, 36, .14);
  --line-light: rgba(255, 255, 255, .18);
  --shadow: 0 24px 70px rgba(23, 61, 36, .12);
  --shadow-soft: 0 14px 40px rgba(23, 61, 36, .07);
  --radius: 22px;
  --radius-sm: 14px;
  --radius-media: 22px;
  --page: calc(100% - clamp(28px, 3vw, 64px));
  --sans: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --display: var(--sans);
  --serif: var(--display);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 92px;
}

body {
  margin: 0;
  overflow-x: hidden;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.65;
  font-variant-numeric: lining-nums tabular-nums;
  font-feature-settings: "lnum" 1, "tnum" 1;
  -webkit-font-smoothing: antialiased;
}

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

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

button,
input,
select,
textarea {
  font: inherit;
  font-variant-numeric: inherit;
}

.container {
  width: var(--page);
  max-width: none;
  margin-inline: auto;
  padding-inline: 0;
}

.narrow {
  max-width: 850px;
}

h1,
h2,
h3 {
  margin-top: 0;
  color: var(--ink);
  font-family: var(--serif);
  font-weight: 640;
  letter-spacing: -.04em;
}

h1 {
  margin-bottom: 0;
  font-size: clamp(46px, 3.8vw, 68px);
  line-height: 1.04;
}

h2 {
  margin-bottom: 0;
  font-size: clamp(34px, 2.7vw, 48px);
  line-height: 1.08;
}

h3 {
  font-size: clamp(22px, 1.5vw, 27px);
  line-height: 1.18;
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 11px;
  margin: 0 0 20px;
  color: var(--green-2);
  font-size: 12px;
  font-weight: 750;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.eyebrow::before {
  content: "";
  flex: 0 0 19px;
  width: 19px;
  height: 1px;
  background: var(--lime);
  opacity: 1;
}

.eyebrow-light {
  color: rgba(255, 255, 255, .72);
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 54px;
  padding: 0 27px;
  border: 1px solid var(--lime);
  border-radius: 13px;
  background: var(--lime);
  color: var(--ink);
  font-size: 15px;
  font-weight: 720;
  letter-spacing: 0;
  text-transform: none;
  cursor: pointer;
  transition: background .2s ease, border-color .2s ease, color .2s ease, transform .2s ease,
    box-shadow .2s ease;
}

.button:hover {
  border-color: var(--lime-hover);
  background: var(--lime-hover);
  color: var(--ink);
  transform: translateY(-2px);
  box-shadow: 0 12px 26px rgba(23, 61, 36, .17);
}

.button:focus-visible,
.text-link:focus-visible,
.card-link:focus-visible,
.site-nav a:focus-visible {
  outline: 3px solid rgba(87, 187, 84, .38);
  outline-offset: 4px;
}

.button-small {
  min-height: 44px;
  padding-inline: 20px;
  border-radius: 11px;
  font-size: 14px;
}

.button-outline {
  border-color: rgba(71, 123, 73, .34);
  background: transparent;
  color: var(--green);
}

.button-outline:hover {
  border-color: var(--green-deep);
  background: var(--green-deep);
  color: white;
}

.button-light {
  border-color: var(--paper);
  background: var(--paper);
  color: var(--green-deep);
}

.button-light:hover {
  border-color: white;
  background: white;
  color: var(--green-deep);
}

.text-link,
.card-link {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: var(--green);
  font-size: 15px;
  font-weight: 720;
  letter-spacing: 0;
  text-transform: none;
}

.text-link span,
.card-link span {
  display: inline-block;
  font-size: 19px;
  transition: transform .2s ease;
}

.text-link:hover,
.card-link:hover {
  color: var(--green-2);
}

.text-link:hover span,
.card-link:hover span {
  transform: translateX(4px);
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid transparent;
  background: rgba(255, 253, 250, .9);
  backdrop-filter: blur(18px);
  transition: background .25s ease, border-color .25s ease, box-shadow .25s ease;
}

.site-header.is-scrolled {
  border-color: var(--line);
  background: rgba(255, 253, 250, .97);
  box-shadow: 0 8px 30px rgba(23, 61, 36, .06);
}

.header-row {
  display: flex;
  align-items: center;
  min-height: 88px;
  gap: clamp(20px, 2.5vw, 42px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-right: auto;
}

.brand-mark {
  display: block;
  width: 48px;
  height: 40px;
  border: 0;
  border-radius: 0;
  flex: 0 0 48px;
}

.brand-mark img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.brand strong,
.brand small {
  display: block;
}

.brand strong {
  font: 640 19px/1.05 var(--display);
  letter-spacing: -.02em;
}

.brand small {
  margin-top: 5px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 750;
  letter-spacing: .18em;
  text-transform: uppercase;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(18px, 2vw, 32px);
}

.site-nav a {
  position: relative;
  padding: 10px 0;
  color: #4b5e58;
  font-size: 14px;
  font-weight: 650;
}

.site-nav a::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: 5px;
  left: 0;
  height: 1px;
  background: var(--lime);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .2s ease;
}

.site-nav a:hover::after {
  transform: scaleX(1);
}

.header-phone {
  display: none;
}

.header-cta {
  flex: 0 0 auto;
}

.menu-button {
  display: none;
  padding: 8px 0;
  border: 0;
  background: none;
  color: var(--ink);
  font-size: 14px;
  font-weight: 700;
}

/* Home hero */
.hero {
  position: relative;
  padding: 26px 0 74px;
  overflow: hidden;
  background: var(--paper);
}

.hero::before {
  display: none;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, .94fr) minmax(500px, 1.06fr);
  min-height: 720px;
  gap: 0;
  align-items: stretch;
  padding-block: 0;
  overflow: hidden;
  border-radius: 34px;
  background: var(--hero-surface);
  box-shadow: var(--shadow);
}

.hero-copy {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(54px, 5.2vw, 88px);
}

.hero-copy::after {
  display: none;
}

.hero-copy .eyebrow {
  color: var(--green-2);
}

.hero-copy h1 {
  max-width: 10.8ch;
  color: var(--ink);
  font-size: clamp(50px, 3.9vw, 72px);
  line-height: 1.04;
}

.hero-copy h1 em {
  display: inline;
  color: inherit;
  font-style: normal;
}

.hero-lead {
  max-width: 580px;
  margin: 30px 0 0;
  color: #53665e;
  font-size: clamp(17px, 1.1vw, 19px);
  line-height: 1.65;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 26px;
  margin-top: 36px;
}

.hero-actions .button {
  border-color: var(--hero-accent);
  background: var(--hero-accent);
  color: var(--ink);
}

.hero-actions .button:hover {
  border-color: var(--hero-accent-hover);
  background: var(--hero-accent-hover);
}

.hero-actions .text-link {
  color: var(--green-deep);
}

.trust-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 22px;
  margin: 42px 0 0;
  padding: 26px 0 0;
  border-top: 1px solid rgba(71, 123, 73, .18);
  color: #596c63;
  font-size: 13px;
  list-style: none;
}

.trust-list li {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0;
  border: 0;
}

.trust-list li::before {
  display: block;
  content: "";
  width: 13px;
  height: 1px;
  background: var(--hero-accent);
}

.hero-media {
  position: relative;
  display: block;
  height: auto;
  min-height: 720px;
  margin: 0;
  overflow: hidden;
  border: 0;
  border-radius: 0;
  background: #d7dfda;
  box-shadow: none;
}

.hero-media::after {
  content: "";
  position: absolute;
  inset: 0;
  display: block;
  background: linear-gradient(90deg, rgba(23, 61, 36, .18), transparent 26%),
    linear-gradient(180deg, transparent 62%, rgba(23, 61, 36, .18));
  pointer-events: none;
}

.hero-media > .hero-media-main {
  width: 100%;
  height: 100%;
  min-height: 720px;
  object-fit: cover;
  object-position: 66% center;
  filter: saturate(.83) contrast(.98);
  transform: scale(1.01);
  transition: transform 1s cubic-bezier(.2, .8, .2, 1), filter .4s ease;
}

.hero-media:hover > .hero-media-main {
  filter: saturate(.94) contrast(1);
  transform: scale(1.025);
}

.hero-media figcaption {
  position: absolute;
  z-index: 2;
  right: 28px;
  bottom: 28px;
  left: 28px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 22px;
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, .48);
  border-radius: 18px;
  background: rgba(255, 253, 250, .9);
  color: var(--ink);
  box-shadow: 0 15px 45px rgba(23, 61, 36, .14);
  backdrop-filter: blur(14px);
}

.hero-media figcaption > span,
.hero-doctor-link > span {
  display: grid;
  gap: 3px;
}

.hero-media figcaption small {
  color: var(--green-2);
  font-size: 11px;
  font-weight: 780;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.hero-media figcaption strong {
  font: 630 clamp(18px, 1.25vw, 22px)/1.2 var(--display);
  letter-spacing: -.025em;
}

.hero-doctor-link {
  display: grid;
  grid-template-columns: 46px auto 18px;
  align-items: center;
  gap: 11px;
  min-width: 250px;
  padding-left: 20px;
  border-left: 1px solid var(--line);
}

.hero-doctor-link > img {
  width: 46px !important;
  height: 46px !important;
  border-radius: 4px;
  object-fit: cover !important;
  object-position: center 18% !important;
  filter: saturate(.9);
}

.hero-doctor-link > span strong {
  font: 680 14px/1.3 var(--sans);
}

.hero-doctor-link i {
  color: var(--rose-deep);
  font-size: 16px;
  font-style: normal;
}

/* Section rhythm */
.section {
  padding: clamp(92px, 8.2vw, 142px) 0;
}

.home-page .section {
  padding: clamp(76px, 6.6vw, 112px) 0;
}

.section-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 42px;
  margin-bottom: clamp(42px, 5vw, 72px);
}

.section-heading h2 {
  max-width: 16ch;
}

.section-note {
  max-width: 500px;
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.65;
}

/* Services */
.section:has(.service-grid) {
  background: var(--paper);
}

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

.service-card {
  position: relative;
  display: flex;
  grid-column: span 4;
  flex-direction: column;
  min-height: 330px;
  padding: 30px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--cream);
  box-shadow: none;
  transition: transform .25s ease, border-color .25s ease, box-shadow .25s ease;
}

.service-card:nth-child(2),
.service-card:nth-child(5) {
  background: var(--sage-soft);
}

.service-card:nth-child(3),
.service-card:nth-child(6) {
  background: #faf0ec;
}

.service-card::after {
  display: none;
}

.service-card:hover {
  z-index: 1;
  border-color: rgba(71, 123, 73, .28);
  box-shadow: var(--shadow-soft);
  transform: translateY(-6px);
}

.service-icon {
  position: relative;
  z-index: 1;
  display: block;
  align-self: flex-start;
  width: 34px;
  height: auto;
  padding-top: 7px;
  border: 0;
  border-top: 2px solid var(--rose);
  border-radius: 0;
  background: transparent;
  color: var(--rose-deep);
  box-shadow: none;
  font: 700 11px/1.1 var(--sans);
  letter-spacing: .08em;
}

.service-icon::before,
.service-icon::after {
  display: none;
}

.service-category {
  margin: 30px 0 0;
  color: var(--green-2);
  font-size: 11px;
  font-weight: 760;
  letter-spacing: .11em;
  text-transform: uppercase;
}

.service-card h3 {
  margin: 10px 0 13px;
}

.service-card > p:not(.service-category) {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.6;
}

.service-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}

.service-meta strong,
.price-actions strong,
.detail-hero aside strong {
  font: 700 20px/1.2 var(--sans);
  letter-spacing: -.02em;
}

.service-meta span {
  color: var(--muted);
  font-size: 13px;
}

.service-card .card-link {
  margin-top: 16px;
}

/* Media story */
.media-story-section {
  position: relative;
  overflow: hidden;
  background: var(--paper);
  color: var(--ink);
}

.media-story-section::before {
  display: none;
}

.media-story-section .eyebrow {
  color: var(--rose-deep);
}

.media-story-section .section-note {
  color: #755f5e;
}

.media-story-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.45fr .85fr;
  grid-template-rows: repeat(2, minmax(240px, 1fr));
  min-height: 680px;
  gap: 16px;
}

.media-tile,
.media-tile-main {
  position: relative;
  width: 100%;
  min-width: 0;
  padding: 0;
  overflow: hidden;
  border: 0;
  border-radius: var(--radius-media);
  background: #28312f;
  color: white;
  box-shadow: none;
  text-align: left;
  cursor: zoom-in;
}

.media-tile-main {
  grid-row: 1 / 3;
}

.media-tile img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(.78) contrast(.98);
  transition: transform .8s cubic-bezier(.2, .8, .2, 1), filter .35s ease;
}

.media-tile::before {
  display: none;
}

.media-tile::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 42%, rgba(17, 45, 26, .82));
}

.media-tile:hover img,
.media-tile:focus-visible img {
  filter: saturate(.94);
  transform: scale(1.035);
}

.media-tile-copy {
  position: absolute;
  z-index: 2;
  right: clamp(22px, 3vw, 38px);
  bottom: clamp(22px, 3vw, 36px);
  left: clamp(22px, 3vw, 38px);
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: end;
  gap: 8px 18px;
}

.media-tile-copy small {
  grid-column: 1 / -1;
  color: #dfecdc;
  font-size: 11px;
  font-weight: 760;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.media-tile-copy strong,
.media-tile:not(.media-tile-main) .media-tile-copy strong {
  color: white;
  font: 640 clamp(22px, 1.8vw, 32px)/1.12 var(--display);
  letter-spacing: -.03em;
}

.media-tile:not(.media-tile-main) .media-tile-copy strong {
  font-size: clamp(20px, 1.35vw, 25px);
}

.media-tile-copy i {
  color: #dfecdc;
  font-size: 12px;
  font-style: normal;
  font-weight: 700;
  text-transform: none;
  opacity: 1;
  transform: none;
}

.media-story-foot {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid rgba(148, 86, 91, .16);
}

.media-story-foot p {
  max-width: 760px;
  margin: 0;
  color: #7a6563;
  font-size: 14px;
}

.media-story-foot .text-link {
  color: var(--rose-deep);
}

/* Doctor */
.section-tint {
  background: var(--brand-soft);
  color: var(--ink);
}

.doctor-grid {
  display: grid;
  grid-template-columns: minmax(360px, .78fr) minmax(0, 1.22fr);
  align-items: center;
  gap: clamp(56px, 8vw, 130px);
}

.doctor-photo {
  position: relative;
  min-height: 630px;
  margin: 0;
  overflow: hidden;
  border: 0;
  border-radius: var(--radius-media);
  background: var(--blush);
  box-shadow: 0 25px 70px rgba(23, 61, 36, .14);
}

.doctor-photo img {
  width: 100%;
  height: 660px;
  object-fit: cover;
  object-position: center 20%;
}

.doctor-photo figcaption {
  position: absolute;
  right: 18px;
  bottom: 18px;
  left: 18px;
  padding: 10px 13px;
  border-radius: 10px;
  background: rgba(255, 253, 250, .9);
  color: var(--muted);
  font-size: 11px;
  text-align: center;
  backdrop-filter: blur(8px);
}

.doctor-copy .eyebrow {
  color: var(--green-2);
}

.doctor-copy h2,
.doctor-copy blockquote {
  color: var(--ink);
}

.doctor-title {
  color: var(--green-2);
  font-weight: 700;
}

.doctor-copy > p:not(.eyebrow, .doctor-title) {
  max-width: 690px;
  color: #53665e;
  font-size: 17px;
  line-height: 1.75;
}

blockquote {
  margin: 34px 0;
  padding: 28px 0;
  border-block: 1px solid rgba(71, 123, 73, .2);
  font: 560 clamp(22px, 1.55vw, 28px)/1.45 var(--display);
  letter-spacing: -.025em;
}

.doctor-actions {
  display: flex;
  align-items: center;
  gap: 26px;
  flex-wrap: wrap;
}

.doctor-copy .button-outline {
  border-color: var(--lime);
  background: var(--lime);
  color: var(--ink);
}

.doctor-copy .text-link {
  color: var(--green-deep);
}

/* Advantages */
.advantages-section {
  background: var(--paper);
}

.advantages-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  border-block: 1px solid var(--line);
}

.advantages-grid article {
  min-height: 220px;
  padding: 34px clamp(22px, 3vw, 44px);
  border: 0;
  border-right: 1px solid var(--line);
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.advantages-grid article:nth-child(3n) {
  border-right: 0;
}

.advantages-grid article:nth-child(n + 4) {
  border-top: 1px solid var(--line);
}

.advantages-grid article > span {
  display: block;
  width: auto;
  height: auto;
  border: 0;
  border-radius: 0;
  background: none;
  color: var(--rose);
  font: 700 12px/1 var(--sans);
  letter-spacing: .1em;
}

.advantages-grid h3 {
  margin: 50px 0 12px;
}

.advantages-grid p {
  color: var(--muted);
  font-size: 16px;
  line-height: 1.6;
}

/* Process */
.process-section {
  position: relative;
  overflow: hidden;
  background: var(--warm-section);
  color: var(--ink);
}

.process-section::before {
  display: none;
}

.process-section .eyebrow {
  color: var(--rose-deep);
}

.steps {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.steps li {
  display: grid;
  grid-template-columns: 46px 1fr;
  gap: 18px;
  min-height: 240px;
  padding: 30px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 253, 250, .74);
}

.steps > li > span {
  display: block;
  width: 34px;
  height: auto;
  padding-top: 7px;
  border: 0;
  border-top: 2px solid var(--rose);
  border-radius: 0;
  color: var(--rose-deep);
  font-size: 12px;
  font-weight: 750;
}

.steps h3 {
  margin: 5px 0 13px;
  color: var(--ink);
  font: 640 clamp(22px, 1.4vw, 26px)/1.18 var(--display);
}

.steps p {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.6;
}

/* Symptom guide */
.care-guide-section {
  background: var(--paper);
}

.care-guide-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.care-guide-grid article,
.care-guide-grid article:not(.care-guide-urgent) {
  display: flex;
  min-height: 310px;
  padding: 30px;
  border: 1px solid rgba(71, 123, 73, .12);
  border-radius: var(--radius);
  background: var(--paper);
  box-shadow: none;
  flex-direction: column;
}

.care-guide-grid article:hover {
  border-color: rgba(71, 123, 73, .26);
  box-shadow: var(--shadow-soft);
  transform: translateY(-4px);
}

.care-guide-grid article > span {
  align-self: flex-start;
  padding: 6px 10px;
  border-radius: 8px;
  background: var(--sage);
  color: var(--green);
  font-size: 11px;
  font-weight: 760;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.care-guide-grid h3 {
  margin: 34px 0 13px;
}

.care-guide-grid p {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.6;
}

.care-guide-grid a {
  margin-top: auto;
  padding-top: 24px;
  color: var(--green);
  font-size: 14px;
  font-weight: 720;
}

.care-guide-grid .care-guide-urgent {
  border-color: rgba(185, 111, 114, .2);
  background: #faece9;
}

.care-guide-urgent > span {
  background: var(--blush) !important;
  color: var(--rose-deep) !important;
}

/* Articles */
.articles-section {
  background: var(--paper);
}

.article-grid,
.article-grid-media,
.article-grid-page {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.article-card,
.article-card-media {
  position: relative;
  display: flex;
  min-height: 380px;
  padding: 30px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  box-shadow: none;
  flex-direction: column;
  transition: transform .25s ease, border-color .25s ease, box-shadow .25s ease;
}

.article-card:hover,
.article-card-media:hover {
  border-color: rgba(71, 123, 73, .28);
  box-shadow: var(--shadow-soft);
  transform: translateY(-5px);
}

.article-card-media {
  display: grid;
  grid-template-rows: 245px 1fr;
  min-height: 570px;
  padding: 0;
}

.article-card-media:nth-child(2n),
.article-card:nth-child(2n) {
  background: var(--paper);
}

.article-card-cover {
  position: relative;
  display: block;
  overflow: hidden;
}

.article-card-cover::after {
  display: none;
}

.article-card-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(.78);
  transition: transform .7s ease, filter .3s ease;
}

.article-card-media:hover .article-card-cover img {
  filter: saturate(.95);
  transform: scale(1.04);
}

.article-card-cover > span,
.article-number {
  display: none;
}

.article-card-content {
  display: flex;
  padding: 28px;
  flex-direction: column;
}

.article-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  color: var(--muted);
  font-size: 12px;
}

.article-card-meta span:first-child {
  color: var(--rose-deep);
  font-weight: 750;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.article-card h2,
.article-card h3,
.article-card-content h3 {
  margin: 32px 0 13px;
  font-size: clamp(23px, 1.5vw, 27px);
  line-height: 1.2;
}

.article-card p,
.article-card-content > p {
  margin: 0 0 25px;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.6;
}

.article-card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-top: auto;
}

.article-card time {
  color: var(--muted);
  font-size: 12px;
}

/* FAQ and CTA */
.faq-section {
  background: var(--warm-section);
}

.faq-list {
  margin-top: 42px;
}

.faq-list details {
  padding: 0;
  border-top: 1px solid var(--line);
}

.faq-list details:last-child {
  border-bottom: 1px solid var(--line);
}

.faq-list summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
  padding: 26px 0;
  color: var(--ink);
  font: 620 clamp(19px, 1.35vw, 24px)/1.35 var(--display);
  letter-spacing: -.02em;
  list-style: none;
  cursor: pointer;
}

.faq-list summary > span:last-child {
  display: grid;
  flex: 0 0 28px;
  place-items: center;
  width: 28px;
  height: 28px;
  border: 0;
  border-radius: 0;
  color: var(--green-2);
  font: 300 22px/1 var(--sans);
  transition: transform .2s ease, background .2s ease;
}

.faq-list details[open] summary > span:last-child {
  background: transparent;
  transform: rotate(45deg);
}

.faq-list details[open] summary > .faq-question-copy {
  transform: none;
}

.faq-list details p {
  max-width: 760px;
  margin: 0 70px 28px 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.65;
}

.contact-section {
  padding: 76px 0;
  background: var(--paper);
}

.contact-card {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 50px;
  padding: clamp(46px, 5vw, 76px);
  overflow: hidden;
  border: 0;
  border-radius: 30px;
  background: var(--rose);
  color: white;
  box-shadow: var(--shadow-soft);
}

.contact-card::after {
  display: none;
}

.contact-card > * {
  position: relative;
  z-index: 1;
}

.contact-card h2 {
  max-width: 760px;
  color: white;
}

.contact-card p:last-child {
  color: rgba(255, 255, 255, .78);
}

/* Contacts directory */
.contacts-page .inner-page-intro {
  margin-bottom: clamp(42px, 5vw, 72px);
}

.contact-directory-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.18fr) minmax(340px, .82fr);
  gap: 16px;
}

.contact-call-panel,
.contact-channels-panel {
  padding: clamp(30px, 4vw, 54px);
  border: 1px solid var(--line);
  border-radius: 26px;
}

.contact-call-panel {
  background: var(--brand-panel);
}

.contact-channels-panel {
  background: var(--cream);
}

.contact-call-panel h2,
.contact-channels-panel h2 {
  margin-bottom: 34px;
  font-size: clamp(30px, 2.7vw, 44px);
  line-height: 1.08;
}

.contact-phone-list {
  border-top: 1px solid rgba(40, 49, 47, .16);
}

.contact-phone-link {
  display: block;
  padding: 22px 0;
  border-bottom: 1px solid rgba(40, 49, 47, .16);
}

.contact-phone-link span,
.contact-phone-link strong,
.contact-phone-link small,
.contact-channel span,
.contact-channel strong,
.contact-channel small {
  display: block;
}

.contact-phone-link span,
.contact-channel span,
.contact-hours > span {
  color: var(--green-2);
  font-size: 10px;
  font-weight: 760;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.contact-phone-link strong {
  margin: 5px 0;
  color: var(--ink);
  font: 650 clamp(27px, 2.4vw, 40px)/1.1 var(--display);
  letter-spacing: -.025em;
}

.contact-phone-link small,
.contact-channel small {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.contact-phone-link:hover strong,
.contact-channel:hover strong {
  color: var(--green);
}

.contact-hours {
  margin-top: 30px;
  padding-top: 26px;
}

.contact-hours strong {
  display: block;
  margin-top: 8px;
  font-size: 20px;
}

.contact-hours p {
  max-width: 570px;
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
}

.contact-channel {
  display: block;
  padding: 18px 0;
  border-top: 1px solid var(--line);
}

.contact-channel strong {
  margin: 5px 0;
  overflow-wrap: anywhere;
  font-size: 19px;
}

.contact-channel-note {
  margin: 24px 0 0;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.contact-locations,
.contact-preparation {
  margin-top: clamp(78px, 8vw, 126px);
}

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

.contact-location-card {
  display: flex;
  min-height: 340px;
  padding: clamp(28px, 3vw, 42px);
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--cream);
  flex-direction: column;
}

.contact-location-number {
  color: var(--rose-deep);
  font-size: 12px;
  font-weight: 760;
  letter-spacing: .1em;
}

.contact-location-label {
  margin: 34px 0 8px;
  color: var(--green-2);
  font-size: 11px;
  font-weight: 760;
  letter-spacing: .11em;
  text-transform: uppercase;
}

.contact-location-card h3 {
  max-width: 19ch;
  margin: 0;
  font-size: clamp(25px, 2vw, 34px);
  line-height: 1.15;
}

.contact-location-rule {
  width: 52px;
  height: 2px;
  margin: 24px 0;
  background: var(--lime);
}

.contact-location-description {
  max-width: 590px;
  margin: 0 0 28px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.6;
}

.contact-map-links {
  display: flex;
  gap: 22px;
  flex-wrap: wrap;
  margin-top: auto;
}

.contact-map-links a {
  color: var(--green);
  font-size: 13px;
  font-weight: 720;
}

.contact-info-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-block: 1px solid var(--line);
}

.contact-info-grid article {
  min-height: 270px;
  padding: 30px;
  border-right: 1px solid var(--line);
}

.contact-info-grid article:last-child {
  border-right: 0;
}

.contact-info-grid article > span {
  color: var(--rose-deep);
  font-size: 11px;
  font-weight: 760;
  letter-spacing: .1em;
}

.contact-info-grid h3 {
  margin: 54px 0 14px;
  font-size: 23px;
}

.contact-info-grid p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.65;
}

.contact-info-urgent {
  background: #f8eeeb;
}

.contact-info-urgent a {
  display: inline-block;
  margin-top: 18px;
  color: #8d3f43;
  font-size: 13px;
  font-weight: 760;
}

.contact-license-strip {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 50px;
  margin-top: clamp(78px, 8vw, 126px);
  padding: clamp(34px, 4vw, 56px);
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--sage);
  color: var(--ink);
}

.contact-license-strip h2 {
  max-width: 800px;
  margin-bottom: 12px;
  color: var(--ink);
  font-size: clamp(28px, 2.5vw, 40px);
}

.contact-license-strip p:last-child {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
}

.contact-license-actions {
  display: flex;
  align-items: flex-start;
  gap: 18px;
  flex-direction: column;
}

.contact-license-actions .button-outline {
  border-color: rgba(71, 123, 73, .38);
  background: rgba(255, 255, 255, .46);
  color: var(--green);
}

.contact-license-actions .text-link {
  color: var(--green-deep);
}

@media (max-width: 1100px) {
  .contact-directory-grid {
    grid-template-columns: 1fr;
  }

  .contact-info-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .contact-info-grid article:nth-child(2) {
    border-right: 0;
  }

  .contact-info-grid article:nth-child(n + 3) {
    border-top: 1px solid var(--line);
  }
}

@media (max-width: 760px) {
  .contact-location-grid,
  .contact-license-strip {
    grid-template-columns: 1fr;
  }

  .contact-location-card {
    min-height: 0;
  }

  .contact-license-strip {
    gap: 30px;
  }
}

@media (max-width: 560px) {
  .contact-call-panel,
  .contact-channels-panel,
  .contact-location-card,
  .contact-license-strip {
    padding: 26px 20px;
    border-radius: 18px;
  }

  .contact-info-grid {
    grid-template-columns: 1fr;
  }

  .contact-info-grid article,
  .contact-info-grid article:nth-child(2) {
    min-height: 0;
    border-top: 1px solid var(--line);
    border-right: 0;
  }

  .contact-info-grid article:first-child {
    border-top: 0;
  }

  .contact-info-grid h3 {
    margin-top: 30px;
  }

  .contact-phone-link strong {
    font-size: 27px;
  }
}

/* Footer */
.site-footer {
  padding: 76px 0 30px;
  background: #28312f;
  color: white;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.35fr 1.1fr .75fr .8fr 1fr;
  gap: clamp(30px, 4vw, 64px);
}

.brand-light small,
.footer-note {
  color: #b6bfbc;
}

.footer-note {
  max-width: 270px;
  margin-top: 24px;
  font-size: 14px;
}

.footer-grid h2 {
  margin: 8px 0 22px;
  color: #a9b3af;
  font: 760 11px/1.3 var(--sans);
  letter-spacing: .14em;
  text-transform: uppercase;
}

.footer-grid > div > a:not(.brand),
.link-button {
  display: block;
  margin: 9px 0;
  padding: 0;
  border: 0;
  background: none;
  color: #edf1ef;
  font-size: 14px;
  text-align: left;
  cursor: pointer;
}

.footer-grid > div > a:hover,
.link-button:hover {
  color: var(--lime);
}

.legal-row {
  display: flex;
  justify-content: space-between;
  gap: 40px;
  margin-top: 62px;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, .1);
  color: #98a39f;
  font-size: 12px;
  line-height: 1.55;
}

.legal-row p:last-child {
  max-width: 720px;
  text-align: right;
}

/* Floating booking action */
.quick-booking {
  position: fixed;
  z-index: 18;
  right: 22px;
  bottom: 22px;
  display: flex;
  align-items: center;
  gap: 12px;
  max-width: 455px;
  padding: 9px 9px 9px 16px;
  border: 1px solid rgba(71, 123, 73, .2);
  border-radius: 16px;
  background: rgba(232, 244, 228, .97);
  color: var(--ink);
  box-shadow: 0 20px 55px rgba(23, 61, 36, .17);
  backdrop-filter: blur(16px);
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  transition: opacity .3s ease, transform .3s ease, visibility .3s ease;
}

.quick-booking.is-visible {
  opacity: 1;
  visibility: visible;
  transform: none;
}

.quick-booking-pulse {
  flex: 0 0 16px;
  width: 16px;
  height: 2px;
  border-radius: 0;
  background: var(--lime);
  box-shadow: none;
}

.quick-booking-pulse::after {
  display: none;
}

.quick-booking-copy {
  min-width: 155px;
}

.quick-booking-copy small,
.quick-booking-copy strong {
  display: block;
}

.quick-booking-copy small {
  color: var(--green-2);
  font-size: 11px;
  font-weight: 760;
  letter-spacing: .13em;
  text-transform: uppercase;
}

.quick-booking-copy strong {
  font: 650 13px/1.35 var(--sans);
}

.quick-booking-phone {
  display: grid;
  flex: 0 0 38px;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1px solid rgba(71, 123, 73, .22);
  border-radius: 11px;
}

.quick-booking .button {
  min-height: 40px;
  padding-inline: 16px;
  border-color: var(--lime);
  border-radius: 10px;
  background: var(--lime);
  color: var(--ink);
  font-size: 12px;
}

.media-lightbox-close,
.media-lightbox-arrow,
.document-modal-controls > button,
.document-modal-loading span {
  border-radius: 6px;
}

/* Public inner-page headers */
.inner-page-section {
  --inner-page-top: clamp(34px, 3.6vw, 58px);
  padding-block: var(--inner-page-top) clamp(76px, 7vw, 118px);
}

.inner-page-intro {
  max-width: none;
  margin-top: calc(-1 * var(--inner-page-top));
  margin-bottom: clamp(30px, 3vw, 46px);
  padding-block: var(--inner-page-top) clamp(30px, 3vw, 46px);
  background: var(--brand-soft);
  box-shadow: 0 0 0 100vmax var(--brand-soft);
  clip-path: inset(0 -100vmax);
  color: var(--ink);
}

.inner-page-intro h1 {
  max-width: 18ch;
  color: var(--ink);
  font-size: clamp(38px, 4vw, 58px);
  line-height: 1.02;
  overflow-wrap: anywhere;
}

.inner-page-intro:not(.detail-hero) {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, .58fr);
  align-items: end;
  gap: 8px clamp(36px, 6vw, 100px);
}

.inner-page-intro:not(.detail-hero) > .eyebrow,
.inner-page-intro:not(.detail-hero) > h1 {
  grid-column: 1;
}

.inner-page-intro:not(.detail-hero) > .eyebrow {
  margin-bottom: 8px;
  color: var(--green-2);
}

.inner-page-intro:not(.detail-hero) > p:last-child {
  grid-column: 2;
  grid-row: 1 / span 2;
  align-self: end;
  max-width: 560px;
  margin: 0 0 2px;
  color: #53665e;
  font-size: 15px;
  line-height: 1.65;
}

.narrow .inner-page-intro:not(.detail-hero) {
  grid-template-columns: 1fr;
}

.narrow .inner-page-intro:not(.detail-hero) > p:last-child {
  grid-column: 1;
  grid-row: auto;
  margin-top: 16px;
}

.detail-hero > div > p:last-child {
  max-width: 760px;
  margin: 20px 0 0;
  color: #53665e;
  font-size: 16px;
  line-height: 1.65;
}

.post-header {
  position: relative;
  padding: clamp(82px, 8vw, 126px) 0;
  overflow: hidden;
  background: var(--brand-soft);
  color: var(--ink);
}

.post-header::after {
  display: none;
}

.post-header > .container {
  position: relative;
  z-index: 1;
}

.post-header .eyebrow {
  color: var(--green-2);
}

.post-header h1 {
  max-width: 13ch;
  color: var(--ink);
}

.post-header .narrow > p:not(.eyebrow, .post-review-meta) {
  max-width: 720px;
  margin: 28px 0 0;
  color: #53665e;
  font-size: 18px;
  line-height: 1.75;
}

.filter-pills {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 42px;
}

.filter-pills a {
  padding: 10px 16px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: transparent;
  color: var(--muted);
  font-size: 14px;
  font-weight: 650;
  transition: background .2s ease, color .2s ease, border-color .2s ease;
}

.filter-pills a:hover {
  border-color: var(--lime);
  color: var(--green);
}

.filter-pills a.active {
  border-color: var(--lime);
  background: var(--lime);
  color: var(--ink);
}

/* Service catalogue and detail */
.price-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.price-list article {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  min-height: 240px;
  padding: 30px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--cream);
  transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}

.price-list article:last-child {
  border-bottom: 1px solid var(--line);
}

.price-list article:hover {
  border-color: rgba(71, 123, 73, .28);
  box-shadow: var(--shadow-soft);
  transform: translateY(-3px);
}

.price-list article p {
  margin: 0;
  color: var(--rose-deep);
  font-size: 11px;
  font-weight: 760;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.price-list article h2 {
  margin: 16px 0 12px;
  font-size: clamp(24px, 1.6vw, 29px);
  line-height: 1.2;
}

.price-list article span {
  color: var(--muted);
  font-size: 16px;
  line-height: 1.6;
}

.price-actions {
  display: flex;
  align-items: flex-end;
  flex-direction: column;
  gap: 3px;
  min-width: 120px;
}

.price-actions strong {
  margin-top: 3px;
  font-size: 20px;
}

.price-actions small {
  color: var(--muted);
  font-size: 13px;
}

.detail-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  align-items: end;
  gap: clamp(50px, 7vw, 110px);
  max-width: none;
}

.detail-hero h1 {
  color: white;
  font-size: clamp(38px, 4vw, 58px);
}

.detail-hero .eyebrow {
  color: #b8d9b2;
}

.detail-hero aside {
  padding: 30px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--cream);
  color: var(--ink);
}

.detail-hero aside > * {
  display: block;
}

.detail-hero aside strong {
  color: var(--ink);
  font-size: 32px;
}

.detail-hero aside span {
  margin: 7px 0 24px;
  color: var(--muted);
}

.detail-hero aside small {
  margin: -13px 0 20px;
  color: var(--muted);
  font-size: 12px;
}

.detail-hero aside .button {
  border-color: var(--peach);
  background: var(--peach);
  color: var(--green-deep);
}

.service-detail-body {
  margin-top: clamp(56px, 6vw, 92px);
}

.service-detail-body > h2:first-child,
.inner-page-intro + .prose > h2:first-child {
  margin-top: 0;
}

.prose {
  max-width: 850px;
  font-size: 18px;
}

.prose h2 {
  margin: 58px 0 20px;
  font-size: clamp(34px, 3vw, 46px);
}

.prose h2:first-child {
  margin-top: 0;
}

.prose p,
.prose li {
  color: #4e625b;
}

.prose a {
  color: var(--rose-deep);
  text-decoration: underline;
  text-decoration-color: rgba(185, 111, 114, .35);
  text-underline-offset: 4px;
}

.notice {
  margin-top: 48px;
  padding: 26px 28px;
  border: 0;
  border-left: 4px solid var(--rose);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  background: #faeeeb;
}

.notice p {
  margin: 5px 0 0;
  font-size: 16px;
}

/* Doctor page */
.doctor-page-hero {
  padding: clamp(56px, 6vw, 92px) 0 clamp(84px, 8vw, 126px);
  background: var(--cream);
}

.doctor-page-grid {
  display: grid;
  grid-template-columns: minmax(390px, .82fr) minmax(0, 1.18fr);
  align-items: center;
  gap: clamp(58px, 8vw, 130px);
}

.doctor-page-photo {
  position: relative;
  height: 700px;
  margin: 0;
  overflow: hidden;
  border: 0;
  border-radius: var(--radius-media);
  background: var(--blush);
  box-shadow: var(--shadow);
}

.doctor-page-photo::after {
  content: "";
  position: absolute;
  inset: 0;
  border: 1px solid rgba(255, 255, 255, .35);
  border-radius: inherit;
  pointer-events: none;
}

.doctor-page-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 23%;
  filter: saturate(.94);
}

.doctor-page-photo figcaption {
  position: absolute;
  right: 18px;
  bottom: 18px;
  left: 18px;
  padding: 10px 13px;
  border-radius: 10px;
  background: rgba(255, 253, 250, .9);
  color: var(--muted);
  font-size: 12px;
  text-align: center;
  backdrop-filter: blur(10px);
}

.doctor-page-intro h1 {
  max-width: 11ch;
  font-size: clamp(46px, 3.7vw, 64px);
  line-height: 1.05;
}

.doctor-page-lead {
  max-width: 760px;
  margin: 25px 0;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.65;
}

.doctor-facts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 36px 0;
}

.doctor-facts div {
  padding: 20px;
  border: 1px solid rgba(71, 123, 73, .1);
  border-radius: var(--radius-sm);
  background: var(--sage-soft);
}

.doctor-facts strong,
.doctor-facts span {
  display: block;
}

.doctor-facts strong {
  color: var(--green);
  font: 700 28px/1.1 var(--sans);
}

.doctor-facts span {
  margin-top: 7px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.doctor-expertise-section {
  background: var(--paper);
}

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

.expertise-grid article {
  min-height: 270px;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--cream);
}

.expertise-grid article > span {
  color: var(--rose);
  font: 700 12px/1 var(--sans);
  letter-spacing: .1em;
}

.expertise-grid h3 {
  margin: 42px 0 12px;
  font-size: 23px;
}

.expertise-grid p {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.6;
}

.doctor-quote-section {
  padding: clamp(84px, 8vw, 130px) 0;
  background: var(--rose);
  color: white;
  text-align: center;
}

.doctor-quote-section blockquote {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0;
  border: 0;
  color: white;
  font: 620 clamp(30px, 2.8vw, 48px)/1.2 var(--display);
}

.doctor-quote-section p {
  margin: 28px 0 0;
  color: rgba(255, 255, 255, .7);
  font-size: 11px;
  font-weight: 720;
  letter-spacing: .13em;
  text-transform: uppercase;
}

.credentials-section {
  background: var(--cream);
}

.credentials-layout {
  display: grid;
  grid-template-columns: .8fr 1.2fr;
  align-items: start;
  gap: clamp(50px, 8vw, 120px);
}

.credentials-heading {
  position: sticky;
  top: 124px;
}

.credentials-heading > p:last-child {
  max-width: 500px;
  color: var(--muted);
}

.credentials-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.credentials-list li {
  display: grid;
  grid-template-columns: 100px 1fr;
  gap: 30px;
  padding: 28px 0;
  border-top: 1px solid var(--line);
}

.credentials-list li:last-child {
  border-bottom: 1px solid var(--line);
}

.credentials-list time {
  color: var(--rose-deep);
  font: 700 17px/1.3 var(--sans);
}

.credentials-list p {
  margin: 0 0 6px;
  color: var(--green-2);
  font-size: 11px;
  font-weight: 750;
  letter-spacing: .11em;
  text-transform: uppercase;
}

.credentials-list h3 {
  margin: 0 0 8px;
  font-size: 22px;
  line-height: 1.25;
}

.credentials-list span {
  color: var(--muted);
  font-size: 15px;
  line-height: 1.6;
}

/* Articles and FAQ directories */
.post-header {
  padding-bottom: 80px;
}

.post-header .back-link {
  display: inline-block;
  margin-bottom: 50px;
  color: var(--green);
  font-size: 13px;
}

.post-header .narrow > p:last-of-type {
  color: #53665e;
}

.post-review-meta {
  display: flex;
  gap: 22px;
  margin-top: 28px;
  color: var(--muted);
  font-size: 12px;
}

.post-cover {
  margin-top: 50px;
}

.post-cover img {
  width: 100%;
  max-height: 680px;
  border-radius: var(--radius-media);
  object-fit: cover;
}

.post-body {
  padding-top: 70px;
}

.post-cta {
  margin-top: 70px;
  margin-bottom: 110px;
  padding: 52px;
  border-radius: var(--radius);
  background: var(--blush);
  text-align: center;
}

.post-cta h2 {
  font-size: 38px;
}

.article-source {
  margin-top: 48px;
  padding: 25px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--sage-soft);
}

.faq-directory {
  background: var(--cream);
}

.faq-directory .filter-pills {
  margin-bottom: 54px;
}

.faq-directory-layout {
  display: grid;
  grid-template-columns: minmax(280px, .65fr) minmax(0, 1.35fr);
  align-items: start;
  gap: clamp(50px, 8vw, 120px);
}

.faq-directory-layout > aside {
  position: sticky;
  top: 124px;
  padding: 30px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
}

.faq-directory-layout > aside h2 {
  font-size: 34px;
}

.faq-directory-layout > aside p {
  color: var(--muted);
  font-size: 16px;
}

.faq-directory-layout > aside p a {
  font-weight: 800;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.faq-question-copy {
  display: grid;
  gap: 5px;
}

.faq-question-copy small {
  display: block;
  margin-bottom: 6px;
  color: var(--rose-deep);
  font: 750 11px/1.25 var(--sans);
  letter-spacing: .11em;
  text-transform: uppercase;
}

.faq-urgent {
  padding-left: 18px !important;
  border-left: 3px solid #a75c53;
}

/* Booking and patient */
.booking-page {
  position: relative;
  overflow: clip;
  padding: clamp(70px, 7vw, 110px) 0;
  background: var(--sage-soft);
}

.booking-page::before {
  display: none;
}

.booking-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(330px, .78fr) minmax(0, 1.22fr);
  align-items: start;
  gap: clamp(56px, 8vw, 125px);
}

.booking-intro {
  position: sticky;
  top: 126px;
}

.booking-intro h1 {
  max-width: 10ch;
  font-size: clamp(44px, 3.5vw, 60px);
  line-height: 1.06;
}

.booking-intro > p:not(.eyebrow) {
  max-width: 560px;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.65;
}

.privacy-note {
  display: flex;
  gap: 14px;
  margin: 34px 0;
  padding: 20px;
  border: 1px solid rgba(71, 123, 73, .12);
  border-radius: var(--radius-sm);
  background: rgba(255, 253, 250, .62);
}

.privacy-note > span {
  display: grid;
  flex: 0 0 30px;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 4px;
  background: var(--lime);
  color: var(--ink);
  font-size: 12px;
}

.privacy-note strong,
.privacy-note p {
  display: block;
  margin: 0;
}

.privacy-note p {
  color: var(--muted);
  font-size: 14px;
}

.location-note {
  display: grid;
  gap: 3px;
}

.location-note small {
  margin-top: 17px;
  color: var(--green-2);
  font-size: 11px;
  font-weight: 760;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.location-note strong,
.location-note a {
  font-size: 15px;
  font-weight: 650;
}

.booking-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
  padding: clamp(30px, 4vw, 52px);
  border: 1px solid rgba(71, 123, 73, .12);
  border-radius: 26px;
  background: var(--paper);
  box-shadow: var(--shadow);
}

.booking-form h2 {
  grid-column: 1 / -1;
  margin-bottom: 12px;
  font-size: 34px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.field.full,
.full {
  grid-column: 1 / -1;
}

.field label {
  color: #405650;
  font-size: 14px;
  font-weight: 700;
}

.field label span {
  color: var(--muted);
  font-weight: 400;
}

.field input,
.field select,
.field textarea,
.login-card input,
.status-form select,
.call-card select,
.call-card textarea,
.compact-form input,
.compact-form select,
.compact-form textarea,
.inline-crm-form textarea {
  width: 100%;
  min-height: 50px;
  padding: 13px 14px;
  border: 1px solid rgba(32, 52, 47, .16);
  border-radius: 11px;
  background: white;
  outline: 0;
}

.field textarea {
  min-height: 112px;
  resize: vertical;
}

.field input:focus,
.field select:focus,
.field textarea:focus,
.login-card input:focus {
  border-color: var(--lime);
  box-shadow: 0 0 0 4px rgba(87, 187, 84, .16);
}

.checkbox-field {
  display: grid;
  grid-template-columns: 20px 1fr;
  align-items: start;
  gap: 10px;
  font-size: 14px;
}

.checkbox-field input {
  width: 18px;
  height: 18px;
  accent-color: var(--lime);
}

.form-footnote {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  text-align: center;
}

.status-page,
.login-page {
  display: grid;
  min-height: 72vh;
  place-items: center;
  padding: 80px 20px;
  background: var(--sage-soft);
}

.status-card,
.login-card {
  width: 100%;
  max-width: 690px;
  padding: clamp(34px, 5vw, 58px);
  border: 1px solid var(--line);
  border-radius: 26px;
  background: var(--paper);
  box-shadow: var(--shadow);
  text-align: center;
}

.success-mark {
  display: grid;
  place-items: center;
  width: 62px;
  height: 62px;
  margin: 0 auto 26px;
  border-radius: 6px;
  background: var(--lime);
  color: var(--ink);
  font-size: 25px;
}

.status-card h1 {
  font-size: clamp(42px, 4vw, 58px);
}

.status-card > p {
  color: var(--muted);
}

.appointment-summary {
  display: grid;
  gap: 4px;
  margin: 30px 0;
  padding: 22px;
  border-radius: var(--radius-sm);
  background: var(--cream);
}

.appointment-summary span,
.appointment-summary small {
  color: var(--muted);
  font-size: 14px;
}

.login-card {
  max-width: 480px;
  text-align: left;
}

.login-card h1 {
  margin-bottom: 28px;
  font-size: 46px;
}

.patient-portal {
  min-height: 72vh;
  padding: 70px 0 100px;
  background: var(--sage-soft);
}

.patient-portal-wrap {
  max-width: 1120px;
}

.patient-portal header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 30px;
  margin-bottom: 40px;
}

.patient-portal header h1 {
  font-size: 50px;
}

.portal-list {
  display: grid;
  gap: 14px;
}

.portal-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  padding: 30px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
}

.portal-card h2 {
  margin: 8px 0;
  font-size: 31px;
}

.portal-card time,
.portal-card p {
  color: var(--muted);
  font-size: 14px;
}

.status-pill {
  display: inline-flex;
  padding: 5px 9px;
  border-radius: 7px;
  background: var(--sage);
  font-size: 11px;
  font-weight: 760;
  letter-spacing: .09em;
  text-transform: uppercase;
}

/* Documents and media dialogs */
.document-modal {
  width: min(1120px, calc(100vw - 48px));
  height: min(880px, calc(100dvh - 48px));
  border: 1px solid rgba(23, 61, 36, .13);
  border-radius: 20px;
  background: var(--paper);
  box-shadow: 0 28px 90px rgba(23, 52, 43, .24);
}

.document-modal::backdrop {
  background: rgba(23, 52, 47, .5);
  backdrop-filter: blur(9px);
}

.document-modal-shell,
.document-modal-header,
.document-modal-body {
  min-width: 0;
}

.document-modal-header {
  min-height: 82px;
  padding: 17px 20px 17px 26px;
  border-bottom-color: var(--line);
  background: #fffefa;
}

.document-modal-header > div:first-child {
  display: grid;
  gap: 3px;
}

.document-modal-header span {
  color: var(--green-2);
  font-size: 10px;
  letter-spacing: .13em;
}

.document-modal-header h2 {
  margin: 0;
  font: 650 clamp(23px, 2vw, 28px)/1.12 var(--sans);
  letter-spacing: -.035em;
  overflow-wrap: anywhere;
}

.document-modal-controls {
  gap: 8px;
}

.document-modal-controls > a {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 0 14px;
  border: 1px solid rgba(71, 123, 73, .26);
  border-radius: 11px;
  color: var(--green);
  font-size: 12px;
  text-decoration: none;
}

.document-modal-controls > button {
  width: 42px;
  height: 42px;
  border-color: rgba(71, 123, 73, .26);
  border-radius: 11px;
  background: var(--paper);
}

.document-modal-controls > button:hover,
.document-modal-controls > a:hover {
  border-color: var(--green);
  background: var(--sage-soft);
}

.document-modal-body {
  padding: clamp(20px, 2.6vw, 32px);
  background: #f4f7f1;
}

.document-modal-body > .legal-document-copy {
  width: 100%;
}

.document-modal-body .license-document {
  max-width: 980px;
  gap: 18px;
}

.document-modal-body .license-document-summary {
  align-items: center;
  padding: 28px 30px;
  border: 1px solid rgba(71, 123, 73, .18);
  border-radius: 18px;
  background: var(--sage);
  color: var(--ink);
}

.document-modal-body .license-document-summary .eyebrow {
  margin-bottom: 9px;
  color: var(--green-2);
}

.document-modal-body .license-document-summary h2 {
  color: var(--ink);
  font: 650 clamp(30px, 3.1vw, 39px)/1.08 var(--sans);
  letter-spacing: -.035em;
  overflow-wrap: anywhere;
}

.document-modal-body .license-document-summary p {
  margin-top: 9px;
  color: var(--muted);
  font-size: 15px;
}

.document-modal-body .license-status {
  padding: 8px 12px;
  border: 1px solid rgba(71, 123, 73, .2);
  border-radius: 9px;
  background: rgba(255, 255, 255, .6);
  color: var(--green-deep) !important;
}

.document-modal-body .license-facts {
  border-radius: 16px;
  box-shadow: none;
}

.document-modal-body .license-facts > div {
  padding: 18px 20px;
}

.document-modal-body .license-facts dt {
  font-size: 10px;
}

.document-modal-body .license-facts dd {
  margin-top: 7px;
  font-size: 14px;
  line-height: 1.45;
}

.document-modal-body .license-addresses {
  gap: 12px;
}

.document-modal-body .license-addresses article {
  padding: 22px 24px;
  border-radius: 16px;
}

.document-modal-body .license-addresses article > span {
  border-radius: 7px;
}

.document-modal-body .license-addresses h3 {
  margin: 16px 0 8px;
  font-size: 22px;
}

.document-modal-body .license-addresses p {
  font-size: 13px;
  line-height: 1.55;
}

.document-modal-body .license-actions {
  gap: 9px;
}

.document-modal-body .license-actions .button {
  min-height: 44px;
  border-radius: 11px;
  font-size: 13px;
}

.document-modal-body .license-registry-hint {
  margin-top: -4px;
  font-size: 12px;
  line-height: 1.55;
}

.document-modal-body .copy-license {
  padding: 3px 8px;
  border-radius: 7px;
  background: var(--brand-soft);
}

.document-modal-body .license-document-pages {
  gap: 12px;
}

.document-modal-body .license-document-pages figure {
  padding: 8px;
  border-radius: 14px;
  box-shadow: 0 10px 28px rgba(23, 61, 36, .06);
}

@media (max-width: 700px) {
  .document-modal {
    width: calc(100vw - 12px);
    height: calc(100dvh - 12px);
    border-radius: 16px;
  }

  .document-modal-header {
    min-height: 70px;
    gap: 8px;
    padding: 11px 10px 11px 16px;
  }

  .document-modal-header > div:first-child {
    max-width: none;
  }

  .document-modal-header > div:first-child > span {
    display: none;
  }

  .document-modal-header h2 {
    max-width: none;
    font-size: 21px;
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
  }

  .document-modal-controls > a {
    min-height: 40px;
    padding: 0 10px;
    font-size: 0;
  }

  .document-modal-controls > a::after {
    content: "Отдельно";
    font-size: 10px;
  }

  .document-modal-controls > button {
    width: 40px;
    height: 40px;
  }

  .document-modal-body {
    padding: 10px;
  }

  .document-modal-body .license-document {
    gap: 10px;
  }

  .document-modal-body .license-document-summary {
    align-items: flex-start;
    gap: 18px;
    padding: 20px;
    border-radius: 14px;
  }

  .document-modal-body .license-document-summary h2 {
    font-size: clamp(25px, 7.4vw, 29px);
  }

  .document-modal-body .license-document-summary p {
    font-size: 14px;
  }

  .document-modal-body .license-status {
    align-self: flex-start;
  }

  .document-modal-body .license-facts {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    border-radius: 14px;
  }

  .document-modal-body .license-facts > div,
  .document-modal-body .license-facts > div:nth-child(3),
  .document-modal-body .license-facts > div:nth-child(4) {
    padding: 16px;
    border-top: 1px solid var(--line);
    border-left: 0;
  }

  .document-modal-body .license-facts > div:first-child {
    border-top: 0;
  }

  .document-modal-body .license-facts > div:nth-child(2) {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .document-modal-body .license-facts > div:nth-child(3),
  .document-modal-body .license-facts > div:nth-child(4) {
    grid-row: 3;
  }

  .document-modal-body .license-facts > div:nth-child(4) {
    border-left: 1px solid var(--line);
  }

  .document-modal-body .license-addresses article {
    padding: 19px;
    border-radius: 14px;
  }

  .document-modal-body .license-addresses h3 {
    font-size: 21px;
  }

  .document-modal-body .license-actions .button {
    width: 100%;
  }

  .document-modal-body .document-secondary-link {
    margin-top: 6px;
    font-size: 12px;
  }
}

@media (max-width: 360px) {
  .document-modal-controls > a {
    display: none;
  }

  .document-modal-header h2 {
    font-size: 20px;
  }
}

.media-lightbox,
.media-lightbox::backdrop {
  background: rgba(13, 36, 20, .97);
}

.media-lightbox figure img {
  border-radius: 18px;
}

/* CRM: operational, compact and deliberately separate from marketing pages */
.crm-body {
  --crm-background: #f1f4f2;
  --crm-surface: #fff;
  --crm-surface-muted: #fbfcfb;
  --crm-surface-soft: #f5f7f6;
  --crm-field: #fbfcfb;
  --crm-sidebar-background: #173d24;
  --crm-sidebar-text: #dcebd8;
  --crm-sidebar-muted: #abc5a6;
  --crm-sidebar-line: rgba(255, 255, 255, .11);
  --crm-card-border: rgba(32, 52, 47, .11);
  --crm-card-shadow: 0 6px 20px rgba(23, 61, 36, .035);
  background: var(--crm-background);
  color-scheme: light;
}

.crm-body h1,
.crm-body h2,
.crm-body h3 {
  font-family: var(--sans);
  font-weight: 700;
  letter-spacing: -.03em;
}

.crm-shell {
  display: grid;
  grid-template-columns: 272px minmax(0, 1fr);
  min-height: 100vh;
  background: var(--crm-background);
}

.crm-sidebar {
  position: sticky;
  top: 0;
  display: flex;
  align-self: start;
  height: 100vh;
  padding: 28px 22px;
  background: var(--crm-sidebar-background);
  color: white;
  flex-direction: column;
}

.crm-sidebar-brand {
  display: flex;
  align-items: center;
  gap: 11px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--crm-sidebar-line);
}

.crm-sidebar-brand .brand-mark {
  width: 42px;
  height: 35px;
  flex-basis: 42px;
}

.crm-sidebar-brand strong,
.crm-sidebar-brand small,
.crm-user small,
.crm-user strong {
  display: block;
}

.crm-sidebar-brand strong {
  font-size: 14px;
}

.crm-sidebar-brand small,
.crm-user small {
  margin-top: 3px;
  color: #a1bea0;
  font-size: 11px;
  font-weight: 720;
  letter-spacing: .13em;
  text-transform: uppercase;
}

.crm-user {
  padding: 24px 10px 10px;
}

.crm-user strong {
  margin-top: 4px;
  font-size: 14px;
}

.crm-sidebar nav {
  display: grid;
  gap: 4px;
  margin-top: 18px;
}

.crm-sidebar nav a {
  padding: 11px 12px;
  border-radius: 9px;
  color: var(--crm-sidebar-text);
  font-size: 14px;
  transition: background .18s ease, color .18s ease;
}

.crm-sidebar nav a:hover {
  background: rgba(255, 255, 255, .08);
  color: white;
}

.crm-sidebar-secondary {
  display: grid;
  gap: 5px;
  margin-top: 0;
  padding-top: 22px;
  border-top: 1px solid var(--crm-sidebar-line);
}

.crm-sidebar-secondary a,
.crm-sidebar-secondary button {
  padding: 4px 0;
  border: 0;
  background: none;
  color: var(--crm-sidebar-muted);
  font-size: 12px;
  text-align: left;
  cursor: pointer;
}

.crm-theme-toggle {
  display: flex;
  align-items: center;
  gap: 11px;
  width: 100%;
  min-height: 48px;
  margin-top: auto;
  margin-bottom: 13px;
  padding: 8px 10px;
  border: 1px solid var(--crm-sidebar-line);
  border-radius: 10px;
  background: rgba(255, 255, 255, .055);
  color: var(--crm-sidebar-text);
  text-align: left;
  cursor: pointer;
  transition: background .18s ease, border-color .18s ease, color .18s ease;
}

.crm-theme-toggle:hover {
  border-color: rgba(255, 255, 255, .24);
  background: rgba(255, 255, 255, .1);
  color: white;
}

.crm-theme-toggle:focus-visible {
  outline: 3px solid rgba(87, 187, 84, .42);
  outline-offset: 3px;
}

.crm-theme-icons {
  display: grid;
  flex: 0 0 30px;
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: rgba(255, 255, 255, .09);
  place-items: center;
}

.crm-theme-icons svg {
  grid-area: 1 / 1;
}

.crm-theme-icon-sun {
  display: none;
}

.crm-theme-copy strong,
.crm-theme-copy small {
  display: block;
}

.crm-theme-copy strong {
  font-size: 12px;
  line-height: 1.3;
}

.crm-theme-copy small {
  margin-top: 2px;
  color: var(--crm-sidebar-muted);
  font-size: 9px;
  line-height: 1.35;
}

html[data-workspace-theme="dark"] .crm-theme-icon-moon {
  display: none;
}

html[data-workspace-theme="dark"] .crm-theme-icon-sun {
  display: block;
}

.crm-main {
  min-width: 0;
  padding: 48px clamp(24px, 4vw, 64px) 84px;
}

.crm-page-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 30px;
  margin-bottom: 32px;
}

.crm-page-head h1 {
  font-size: clamp(36px, 3vw, 48px);
}

.crm-page-head > div > p:last-child {
  color: var(--muted);
}

.crm-head-actions,
.dashboard-actions {
  display: flex;
  gap: 9px;
  flex-wrap: wrap;
}

.phone-booking-form {
  max-width: 980px;
}

.phone-booking-form > .button {
  margin-top: 4px;
}

.crm-metrics,
.metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 28px 0 36px;
}

.crm-metrics-five,
.analytics-metrics {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.crm-metrics > a,
.crm-metrics > div,
.metrics > div {
  min-width: 0;
  padding: 20px;
  border: 1px solid var(--crm-card-border);
  border-radius: 13px;
  background: var(--crm-surface);
  box-shadow: var(--crm-card-shadow);
}

.crm-metrics span,
.crm-metrics strong,
.crm-metrics small,
.metrics span,
.metrics strong {
  display: block;
}

.crm-metrics span,
.metrics span {
  color: var(--muted);
  font-size: 13px;
}

.crm-metrics strong,
.metrics strong {
  margin: 7px 0 2px;
  font: 700 32px/1.1 var(--sans);
}

.crm-panel,
.appointment-item,
.call-card,
.patient-table,
.portal-security {
  border: 1px solid var(--crm-card-border);
  border-radius: 14px;
  background: var(--crm-surface);
  box-shadow: var(--crm-card-shadow);
}

.crm-panel {
  padding: 27px;
}

.crm-panel h2 {
  font-size: 24px;
}

.dashboard-tabs {
  display: flex;
  gap: 24px;
  margin-bottom: 18px;
  border-bottom: 1px solid var(--line);
}

.dashboard-tabs a {
  padding: 13px 0;
  border-bottom: 2px solid transparent;
  font-size: 14px;
  font-weight: 700;
}

.dashboard-tabs a.active {
  border-color: var(--lime);
  color: var(--green-deep);
}

.appointment-item {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr) 200px;
  gap: 28px;
  margin-bottom: 10px;
  padding: 24px;
}

.appointment-date strong {
  font: 700 27px/1.2 var(--sans);
}

.appointment-person h2 {
  margin: 0 0 5px;
  font-size: 20px;
}

.schedule-layout,
.analytics-grid,
.patient-detail-grid {
  gap: 16px;
}

.patient-row:hover {
  background: var(--sage-soft);
}

.priority-badge,
.status-failed,
.status-cancelled,
.status-no_show {
  background: #f8e2de;
  color: #8d4648;
}

/* CRM reminders and delivery control */
.panel-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 22px;
}

.panel-heading h2 {
  margin: 3px 0 0;
}

.reminder-workspace,
.reminder-queue {
  margin-top: 18px;
}

.reminder-status-grid,
.reminder-health > div {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
}

.reminder-health {
  padding: 0;
}

.reminder-health > div {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border: 0;
  border-radius: inherit;
}

.reminder-status-grid > div,
.reminder-health > div > div {
  min-width: 0;
  padding: 18px 20px;
  background: var(--crm-surface-muted);
  border-right: 1px solid var(--line);
}

.reminder-status-grid > div:last-child,
.reminder-health > div > div:last-child {
  border-right: 0;
}

.reminder-status-grid span,
.reminder-status-grid strong,
.reminder-health span,
.reminder-health strong,
.reminder-health small {
  display: block;
}

.reminder-status-grid span,
.reminder-health span {
  color: var(--muted);
  font-size: 12px;
}

.reminder-status-grid strong,
.reminder-health strong {
  margin-top: 7px;
  color: var(--green-deep);
  font-size: 15px;
  line-height: 1.35;
}

.reminder-health small {
  margin-top: 5px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.45;
}

.reminder-history {
  margin: 24px -27px -27px;
}

.reminder-queue-list {
  display: grid;
  border-top: 1px solid var(--line);
}

.reminder-queue-list article {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) 150px 150px auto auto;
  align-items: center;
  gap: 20px;
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
}

.reminder-queue-list article:last-child {
  border-bottom: 0;
}

.reminder-queue-list time,
.reminder-queue-list p,
.reminder-queue-list article > div > span {
  display: block;
  margin: 0;
  color: var(--muted);
  font-size: 12px;
}

.reminder-queue-list h3 {
  margin: 4px 0 3px;
  font-size: 17px;
}

.reminder-queue-list article > div > strong {
  display: block;
  margin-top: 4px;
  font-size: 13px;
}

.reminder-state-due {
  background: #f8e2de;
  color: #8d4648;
}

.reminder-state-complete {
  background: var(--sage);
  color: var(--green-deep);
}

.reminder-state-disabled {
  background: #e6e7eb;
  color: #4f5664;
}

.notification-filters {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) 190px 170px auto;
  width: 100%;
  margin: 28px 0 0;
}

.notification-filters input,
.notification-filters select {
  min-width: 0;
  min-height: 46px;
  padding: 10px 13px;
  border: 1px solid #cbd6d1;
  border-right: 0;
  border-radius: 0;
  background: white;
  color: var(--ink);
  font: 500 14px/1.3 var(--sans);
}

.notification-filters input {
  border-radius: 9px 0 0 9px;
}

.notification-filters button {
  min-height: 46px;
  padding-inline: 20px;
  border-radius: 0 9px 9px 0;
}

.portal-reminder-toggle {
  padding: 0 0 3px;
  border: 0;
  border-bottom: 1px solid currentColor;
  background: transparent;
  color: var(--green-deep);
  font: 700 12px/1.35 var(--sans);
  cursor: pointer;
}

.compact-form input[type="checkbox"] {
  width: 19px;
  height: 19px;
  min-height: 0;
  margin: 2px 0 5px;
  accent-color: var(--lime);
}

/* CRM finance: factual income register */
.finance-metrics {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.finance-entry-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(320px, .65fr);
  align-items: start;
  gap: 16px;
}

.finance-entry-form,
.finance-category-panel {
  min-width: 0;
}

.finance-fact-badge {
  display: inline-flex;
  padding: 7px 10px;
  border: 1px solid #bed7cc;
  border-radius: 7px;
  background: #edf6f1;
  color: #245e4f;
  font-size: 11px;
  font-weight: 750;
  white-space: nowrap;
}

.finance-category-panel > .panel-heading > span {
  display: grid;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--sage-soft);
  font-weight: 750;
  place-items: center;
}

.finance-category-list {
  display: grid;
  border-top: 1px solid var(--line);
}

.finance-category-list article {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  padding: 15px 0;
  border-bottom: 1px solid var(--line);
}

.finance-category-list article.is-archived {
  opacity: .58;
}

.finance-category-list strong,
.finance-category-list small,
.finance-category-list span {
  display: block;
}

.finance-category-list small,
.finance-category-list span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
}

.finance-category-list button,
.finance-row-actions a {
  padding: 0;
  border: 0;
  border-bottom: 1px solid currentColor;
  background: transparent;
  color: var(--green-deep);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.finance-category-form {
  display: grid;
  gap: 12px;
  margin-top: 24px;
}

.finance-category-form .button {
  justify-self: start;
}

.finance-register,
.appointment-income-panel {
  margin-top: 16px;
}

.finance-register > .panel-heading > strong,
.appointment-income-panel > .panel-heading > strong {
  color: var(--green-deep);
  font-size: 22px;
}

.finance-filters {
  display: grid;
  grid-template-columns: repeat(4, minmax(130px, 1fr));
  align-items: end;
  gap: 10px;
  margin-bottom: 28px;
  padding: 18px;
  border-radius: 11px;
  background: #f5f7f6;
}

.finance-filters > div {
  min-width: 0;
}

.finance-filters label {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.finance-filters input,
.finance-filters select {
  width: 100%;
  min-width: 0;
  min-height: 44px;
  padding: 9px 11px;
  border: 1px solid #cbd6d1;
  border-radius: 8px;
  background: white;
  color: var(--ink);
}

.finance-filter-search {
  grid-column: 1 / span 3;
}

.finance-filters > .button {
  width: 100%;
}

.finance-breakdown {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-bottom: 28px;
}

.finance-breakdown p {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin: 0 0 7px;
  font-size: 12px;
}

.finance-breakdown p strong {
  text-align: right;
}

.finance-breakdown i {
  display: block;
  height: 6px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--lime) var(--bar), var(--sage-soft) var(--bar));
}

.finance-table {
  min-width: 960px;
}

.finance-table td > small,
.finance-table td > time {
  display: block;
}

.finance-table td > small {
  max-width: 280px;
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
}

.finance-amount {
  color: var(--green-deep);
  font-size: 16px;
  white-space: nowrap;
}

.finance-row-actions {
  display: flex;
  gap: 12px;
}

.finance-row-actions .danger-link {
  color: #93443d;
  text-decoration: none;
}

.appointment-income-list {
  display: grid;
  border-top: 1px solid var(--line);
}

.appointment-income-list article {
  display: grid;
  grid-template-columns: 100px minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 18px;
  padding: 15px 0;
  border-bottom: 1px solid var(--line);
}

.appointment-income-list article > div > strong,
.appointment-income-list article > div > small {
  display: block;
}

.appointment-income-list article > div > small,
.appointment-income-list time {
  color: var(--muted);
  font-size: 12px;
}

.appointment-income-list article > a {
  color: var(--green-deep);
  font-size: 12px;
  font-weight: 700;
}

/* CRM greetings: consent-aware campaigns */
.greeting-metrics {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

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

.greeting-campaign-card {
  display: grid;
  min-width: 0;
  gap: 22px;
}

.greeting-campaign-card.is-inactive {
  background: #f8faf8;
}

.greeting-campaign-status {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.greeting-campaign-status > span:last-child {
  color: var(--muted);
  font-size: 11px;
}

.greeting-campaign-card h2 {
  margin: 5px 0 8px;
}

.greeting-campaign-card p {
  margin: 0;
  color: var(--muted);
}

.greeting-campaign-card dl,
.greeting-preview-copy dl {
  display: grid;
  gap: 10px;
  margin: 0;
}

.greeting-campaign-card dl > div,
.greeting-preview-copy dl > div {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 16px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}

.greeting-campaign-card dt,
.greeting-preview-copy dt {
  color: var(--muted);
  font-size: 11px;
}

.greeting-campaign-card dd,
.greeting-preview-copy dd {
  margin: 0;
  font-size: 13px;
  font-weight: 650;
}

.greeting-editor-form {
  max-width: 1120px;
}

.greeting-field-include_tags ul,
.greeting-field-exclude_tags ul {
  display: flex;
  gap: 8px;
  margin: 0;
  padding: 0;
  flex-wrap: wrap;
  list-style: none;
}

.greeting-field-include_tags li label,
.greeting-field-exclude_tags li label {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfb;
  font-weight: 600;
}

.greeting-field-selected_patients select {
  min-height: 220px;
}

.greeting-form-note {
  margin-top: 24px;
  padding: 18px;
  border-left: 3px solid var(--lime);
  background: var(--sage-soft);
}

.greeting-form-note p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.greeting-detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(300px, .65fr);
  align-items: start;
  gap: 16px;
}

.greeting-preview-copy > p {
  padding: 22px;
  border-radius: 11px;
  background: var(--sage-soft);
  font-size: 16px;
  line-height: 1.7;
}

.greeting-preview-copy > .panel-heading > span {
  color: var(--muted);
  font-size: 12px;
}

.greeting-launch-panel > p {
  color: var(--muted);
}

.greeting-launch-panel form {
  display: grid;
  gap: 9px;
  margin-top: 20px;
}

.greeting-launch-panel label {
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.greeting-launch-panel input {
  width: 100%;
  min-height: 46px;
  padding: 10px 12px;
  border: 1px solid #cbd6d1;
  border-radius: 8px;
  background: white;
}

.greeting-launch-panel button:disabled {
  opacity: .45;
  cursor: not-allowed;
}

.greeting-launch-panel > small {
  display: block;
  margin-top: 15px;
  color: var(--muted);
  line-height: 1.5;
}

.greeting-audience-panel,
.greeting-history-panel {
  margin-top: 16px;
}

.greeting-audience-table {
  min-width: 820px;
}

.greeting-audience-table td > small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
}

.patient-greeting-status {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
}

.patient-greeting-status > div {
  padding: 15px;
  border-right: 1px solid var(--line);
}

.patient-greeting-status > div:last-child {
  border-right: 0;
}

.patient-greeting-status span,
.patient-greeting-status strong {
  display: block;
}

.patient-greeting-status span,
.patient-greeting-history time,
.patient-greeting-history small {
  color: var(--muted);
  font-size: 11px;
}

.patient-greeting-status strong {
  margin-top: 5px;
  font-size: 13px;
}

.patient-greeting-history {
  display: grid;
  margin-top: 18px;
  border-top: 1px solid var(--line);
}

.patient-greeting-history article {
  display: grid;
  grid-template-columns: 130px minmax(0, 1fr);
  gap: 18px;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
}

.patient-greeting-history strong,
.patient-greeting-history small {
  display: block;
}

/* Custom back office */
.cms-module-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.cms-module-card,
.cms-content-row {
  border: 1px solid var(--crm-card-border);
  border-radius: 13px;
  background: var(--crm-surface);
  box-shadow: var(--crm-card-shadow);
}

.cms-content-row.cms-access-row {
  grid-template-columns: minmax(0, 1fr) auto minmax(150px, 220px) auto;
}

.cms-module-card {
  display: flex;
  min-height: 220px;
  padding: 25px;
  flex-direction: column;
  transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}

.cms-module-card:hover {
  border-color: rgba(24, 81, 67, .32);
  box-shadow: 0 13px 34px rgba(23, 61, 36, .08);
  transform: translateY(-2px);
}

.cms-module-card > span {
  align-self: flex-start;
  padding: 5px 9px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
}

.cms-module-card h2 {
  margin: 30px 0 8px;
  font-size: 22px;
}

.cms-module-card p {
  margin: 0 0 22px;
  color: var(--muted);
  font-size: 14px;
}

.cms-module-card > strong {
  margin-top: auto;
  color: var(--green-deep);
  font-size: 13px;
}

.cms-content-list {
  display: grid;
  gap: 9px;
}

.cms-content-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 24px;
  padding: 20px 22px;
}

.cms-content-row h2 {
  margin: 0 0 5px;
  font-size: 18px;
}

.cms-content-row h2 a:hover {
  color: var(--rose-deep);
}

.cms-content-row p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.cms-status {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 9px;
  border: 1px solid rgba(32, 52, 47, .12);
  border-radius: 6px;
  background: #f5f7f6;
  color: var(--muted);
  font-size: 11px;
  font-weight: 750;
  letter-spacing: .03em;
  white-space: nowrap;
}

.cms-status-positive {
  border-color: #bed7cc;
  background: #edf6f1;
  color: #245e4f;
}

.cms-status-color {
  border-left: 8px solid var(--cms-status-color);
}

.cms-row-action,
.cms-table-action {
  color: var(--green-deep);
  font-size: 13px;
  font-weight: 750;
  white-space: nowrap;
}

.cms-table-action {
  padding: 0;
  border: 0;
  border-bottom: 1px solid currentColor;
  background: none;
  cursor: pointer;
}

.cms-user-role {
  color: var(--muted);
  font-size: 13px;
}

.cms-role-value {
  font-size: clamp(18px, 2vw, 25px) !important;
}

.cms-editor-form {
  max-width: 1100px;
}

.cms-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 21px 18px;
}

.cms-field {
  min-width: 0;
}

.cms-field label {
  display: block;
  margin-bottom: 7px;
  color: var(--green-deep);
  font-size: 13px;
  font-weight: 750;
}

.cms-field input:not([type="checkbox"]):not([type="color"]),
.cms-field select,
.cms-field textarea {
  width: 100%;
  min-height: 46px;
  padding: 11px 13px;
  border: 1px solid #cbd6d1;
  border-radius: 8px;
  outline: none;
  background: var(--crm-field);
  color: var(--ink);
  font: 500 15px/1.45 var(--sans);
  transition: border-color .18s ease, box-shadow .18s ease;
}

.cms-field textarea {
  resize: vertical;
}

.cms-field input:focus,
.cms-field select:focus,
.cms-field textarea:focus {
  border-color: var(--lime);
  box-shadow: 0 0 0 3px rgba(87, 187, 84, .14);
}

.cms-field input[type="file"] {
  padding: 9px;
}

.cms-field input[type="color"] {
  width: 88px;
  height: 46px;
  padding: 4px;
  border: 1px solid #cbd6d1;
  border-radius: 8px;
  background: var(--crm-field);
}

.cms-field input[type="checkbox"] {
  width: 18px;
  height: 18px;
  margin: 5px 0;
  accent-color: var(--lime);
}

.cms-field-hidden {
  display: none;
}

.cms-field small {
  display: block;
  margin-top: 6px;
  color: var(--muted);
  font-size: 11px;
}

.cms-field .errorlist,
.cms-editor-form > .errorlist {
  margin: 7px 0 0;
  padding: 9px 11px;
  border-left: 3px solid #a84f54;
  background: #fff2f1;
  color: #873c41;
  font-size: 12px;
  list-style: none;
}

.cms-form-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 30px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
  flex-wrap: wrap;
}

.cms-delete-link {
  margin-left: auto;
  color: #97454b;
  font-size: 13px;
  font-weight: 750;
}

.cms-confirm-panel {
  max-width: 720px;
}

.cms-danger-button {
  border-color: #963f45;
  background: #963f45;
}

.cms-audit-table td:nth-child(3) {
  min-width: 330px;
}

/* Workspace theme: shared by the doctor CRM and the custom CMS. */
html[data-workspace-theme="dark"] .crm-body {
  --ink: #edf4ef;
  --muted: #9eafa7;
  --line: rgba(224, 240, 230, .12);
  --paper: #18211d;
  --cream: #202a25;
  --sage: #263a2f;
  --sage-soft: #1d2b24;
  --green: #82ca7e;
  --green-2: #97d493;
  --green-deep: #9bd297;
  --lime: #65c962;
  --lime-hover: #74d470;
  --rose-deep: #e09a9e;
  --crm-background: #0f1512;
  --crm-surface: #18211d;
  --crm-surface-muted: #151d19;
  --crm-surface-soft: #1c2721;
  --crm-field: #121a16;
  --crm-sidebar-background: #0a0f0c;
  --crm-sidebar-text: #dce9df;
  --crm-sidebar-muted: #91a69a;
  --crm-sidebar-line: rgba(231, 244, 235, .12);
  --crm-card-border: rgba(224, 240, 230, .12);
  --crm-card-shadow: 0 12px 32px rgba(0, 0, 0, .16);
  color-scheme: dark;
}

.crm-body,
.crm-shell,
.crm-main,
.crm-sidebar,
.crm-panel,
.crm-metrics > a,
.crm-metrics > div,
.metrics > div,
.appointment-item,
.call-card,
.patient-table,
.cms-module-card,
.cms-content-row {
  transition: background-color .22s ease, border-color .22s ease, color .22s ease,
    box-shadow .22s ease;
}

html[data-workspace-theme="dark"] .crm-body,
html[data-workspace-theme="dark"] .crm-shell,
html[data-workspace-theme="dark"] .crm-main {
  background: var(--crm-background);
  color: var(--ink);
}

html[data-workspace-theme="dark"] .crm-sidebar {
  border-right: 1px solid var(--crm-sidebar-line);
  background: var(--crm-sidebar-background);
}

html[data-workspace-theme="dark"] .crm-sidebar-brand small,
html[data-workspace-theme="dark"] .crm-user small {
  color: var(--crm-sidebar-muted);
}

html[data-workspace-theme="dark"] .crm-sidebar nav a:hover,
html[data-workspace-theme="dark"] .crm-sidebar nav a:focus-visible {
  background: rgba(101, 201, 98, .12);
  color: #f4faf5;
}

html[data-workspace-theme="dark"] .crm-page-head h1,
html[data-workspace-theme="dark"] .crm-body h2,
html[data-workspace-theme="dark"] .crm-body h3,
html[data-workspace-theme="dark"] .appointment-date strong,
html[data-workspace-theme="dark"] .crm-metrics strong,
html[data-workspace-theme="dark"] .metrics strong,
html[data-workspace-theme="dark"] .finance-register > .panel-heading > strong,
html[data-workspace-theme="dark"] .appointment-income-panel > .panel-heading > strong {
  color: var(--ink);
}

html[data-workspace-theme="dark"] .crm-body .field label {
  color: #c5d2cc;
}

html[data-workspace-theme="dark"] .crm-metrics > a,
html[data-workspace-theme="dark"] .crm-metrics > div,
html[data-workspace-theme="dark"] .metrics > div,
html[data-workspace-theme="dark"] .crm-panel,
html[data-workspace-theme="dark"] .appointment-item,
html[data-workspace-theme="dark"] .call-card,
html[data-workspace-theme="dark"] .patient-table,
html[data-workspace-theme="dark"] .portal-security,
html[data-workspace-theme="dark"] .cms-module-card,
html[data-workspace-theme="dark"] .cms-content-row {
  border-color: var(--crm-card-border);
  background: var(--crm-surface);
  box-shadow: var(--crm-card-shadow);
}

html[data-workspace-theme="dark"] .crm-metrics > a:hover,
html[data-workspace-theme="dark"] .cms-module-card:hover {
  border-color: rgba(101, 201, 98, .36);
  background: #1b2721;
  box-shadow: 0 15px 38px rgba(0, 0, 0, .22);
}

html[data-workspace-theme="dark"] .button {
  color: #102016;
}

html[data-workspace-theme="dark"] .button-outline {
  border-color: rgba(130, 202, 126, .42);
  background: transparent;
  color: #a7dda4;
}

html[data-workspace-theme="dark"] .button-outline:hover {
  border-color: #65c962;
  background: rgba(101, 201, 98, .14);
  color: #d9f2d7;
}

html[data-workspace-theme="dark"] .crm-search input,
html[data-workspace-theme="dark"] .notification-filters input,
html[data-workspace-theme="dark"] .notification-filters select,
html[data-workspace-theme="dark"] .finance-filters input,
html[data-workspace-theme="dark"] .finance-filters select,
html[data-workspace-theme="dark"] .greeting-launch-panel input,
html[data-workspace-theme="dark"] .field input,
html[data-workspace-theme="dark"] .field select,
html[data-workspace-theme="dark"] .field textarea,
html[data-workspace-theme="dark"] .status-form select,
html[data-workspace-theme="dark"] .call-card select,
html[data-workspace-theme="dark"] .call-card textarea,
html[data-workspace-theme="dark"] .compact-form input,
html[data-workspace-theme="dark"] .compact-form select,
html[data-workspace-theme="dark"] .compact-form textarea,
html[data-workspace-theme="dark"] .inline-crm-form textarea,
html[data-workspace-theme="dark"] .cms-field input:not([type="checkbox"]):not([type="color"]),
html[data-workspace-theme="dark"] .cms-field select,
html[data-workspace-theme="dark"] .cms-field textarea,
html[data-workspace-theme="dark"] .cms-field input[type="color"] {
  border-color: rgba(224, 240, 230, .17);
  background: var(--crm-field);
  color: var(--ink);
}

html[data-workspace-theme="dark"] .crm-body input::placeholder,
html[data-workspace-theme="dark"] .crm-body textarea::placeholder {
  color: #708079;
  opacity: 1;
}

html[data-workspace-theme="dark"] .crm-search button,
html[data-workspace-theme="dark"] .status-form button,
html[data-workspace-theme="dark"] .call-card form button,
html[data-workspace-theme="dark"] .compact-form > button,
html[data-workspace-theme="dark"] .inline-crm-form button {
  background: #5fbd5c;
  color: #0c1a11;
}

html[data-workspace-theme="dark"] .dashboard-tabs a.active,
html[data-workspace-theme="dark"] .cms-module-card > strong,
html[data-workspace-theme="dark"] .cms-row-action,
html[data-workspace-theme="dark"] .cms-table-action,
html[data-workspace-theme="dark"] .finance-category-list button,
html[data-workspace-theme="dark"] .finance-row-actions a,
html[data-workspace-theme="dark"] .appointment-income-list article > a,
html[data-workspace-theme="dark"] .portal-reminder-toggle {
  color: #91d58d;
}

html[data-workspace-theme="dark"] .patient-row:hover {
  background: #1c2a22;
}

html[data-workspace-theme="dark"] .patient-table-head,
html[data-workspace-theme="dark"] .notification-table th {
  background: #202a25;
  color: #a8b7b0;
}

html[data-workspace-theme="dark"] .reminder-status-grid > div,
html[data-workspace-theme="dark"] .reminder-health > div > div,
html[data-workspace-theme="dark"] .greeting-field-include_tags li label,
html[data-workspace-theme="dark"] .greeting-field-exclude_tags li label {
  background: var(--crm-surface-muted);
}

html[data-workspace-theme="dark"] .finance-filters,
html[data-workspace-theme="dark"] .greeting-campaign-card.is-inactive,
html[data-workspace-theme="dark"] .window-row.is-closed {
  background: var(--crm-surface-soft);
}

html[data-workspace-theme="dark"] .note-list article,
html[data-workspace-theme="dark"] .greeting-preview-copy > p,
html[data-workspace-theme="dark"] .greeting-form-note,
html[data-workspace-theme="dark"] .calendar-card,
html[data-workspace-theme="dark"] .calendar-card-compact {
  background: #202b25;
}

html[data-workspace-theme="dark"] .calendar-option,
html[data-workspace-theme="dark"] .calendar-option > span {
  border-color: var(--line);
  background: #151e1a;
}

html[data-workspace-theme="dark"] .finance-fact-badge,
html[data-workspace-theme="dark"] .cms-status-positive,
html[data-workspace-theme="dark"] .status-confirmed,
html[data-workspace-theme="dark"] .status-completed,
html[data-workspace-theme="dark"] .status-sent,
html[data-workspace-theme="dark"] .reminder-state-complete {
  border-color: rgba(113, 198, 111, .28);
  background: rgba(80, 154, 78, .2);
  color: #a9dfa6;
}

html[data-workspace-theme="dark"] .priority-badge,
html[data-workspace-theme="dark"] .status-failed,
html[data-workspace-theme="dark"] .status-cancelled,
html[data-workspace-theme="dark"] .status-no_show,
html[data-workspace-theme="dark"] .reminder-state-due {
  background: rgba(178, 79, 83, .22);
  color: #f0a7aa;
}

html[data-workspace-theme="dark"] .status-skipped {
  background: rgba(177, 143, 69, .22);
  color: #e6c982;
}

html[data-workspace-theme="dark"] .status-pending,
html[data-workspace-theme="dark"] .reminder-state-disabled,
html[data-workspace-theme="dark"] .cms-status {
  border-color: rgba(224, 240, 230, .12);
  background: #28312d;
  color: #bdc9c3;
}

html[data-workspace-theme="dark"] .cms-field .errorlist,
html[data-workspace-theme="dark"] .cms-editor-form > .errorlist {
  background: rgba(168, 79, 84, .16);
  color: #f1abad;
}

html[data-workspace-theme="dark"] .cms-delete-link,
html[data-workspace-theme="dark"] .finance-row-actions .danger-link,
html[data-workspace-theme="dark"] .danger-link {
  color: #eea2a6;
}

html[data-workspace-theme="dark"] .empty-state {
  border: 1px solid var(--crm-card-border);
  background: var(--crm-surface);
}

html[data-workspace-theme="dark"] .crm-body ::selection {
  background: rgba(101, 201, 98, .28);
  color: white;
}

html[data-workspace-theme="dark"] .crm-body * {
  scrollbar-color: #3b4e44 #111814;
}

/* Motion */
.reveal-item {
  opacity: .98;
  transform: translateY(12px);
  transition: opacity .7s ease, transform .75s cubic-bezier(.2, .75, .25, 1);
}

.reveal-item.reveal-visible {
  opacity: 1;
  transform: none;
}

/* Tablet */
@media (max-width: 1180px) {
  .site-nav {
    gap: 18px;
  }

  .hero-grid {
    grid-template-columns: minmax(0, .95fr) minmax(430px, 1.05fr);
    min-height: 660px;
  }

  .hero-copy {
    padding: 54px 48px;
  }

  .hero-copy h1 {
    font-size: clamp(48px, 4.8vw, 62px);
  }

  .hero-media,
  .hero-media > .hero-media-main {
    min-height: 660px;
  }

  .service-card {
    grid-column: span 6;
  }

  .price-list {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .expertise-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .crm-metrics-five,
  .analytics-metrics,
  .greeting-metrics {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .appointment-detail-grid {
    grid-template-columns: 1fr;
  }

  .finance-entry-layout {
    grid-template-columns: 1fr;
  }

  .greeting-detail-grid {
    grid-template-columns: 1fr;
  }

  .reminder-status-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .reminder-status-grid > div:nth-child(2) {
    border-right: 0;
  }

  .reminder-status-grid > div:nth-child(-n + 2) {
    border-bottom: 1px solid var(--line);
  }

  .reminder-queue-list article {
    grid-template-columns: minmax(220px, 1fr) 140px 140px;
  }

  .reminder-queue-list article > .status-pill,
  .reminder-queue-list article > form {
    justify-self: start;
  }

  .notification-filters {
    grid-template-columns: 1fr 1fr;
  }

  .notification-filters input {
    grid-column: 1 / -1;
    border-right: 1px solid #cbd6d1;
    border-radius: 9px 9px 0 0;
  }

  .notification-filters select:nth-of-type(2) {
    border-right: 1px solid #cbd6d1;
  }

  .notification-filters button {
    grid-column: 1 / -1;
    border-radius: 0 0 9px 9px;
  }
}

@media (max-width: 980px) {
  .cms-module-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .header-row {
    min-height: 76px;
  }

  .site-nav {
    position: absolute;
    top: 76px;
    right: 0;
    left: 0;
    display: none;
    align-items: stretch;
    gap: 2px;
    padding: 20px 24px 26px;
    border-bottom: 1px solid var(--line);
    background: var(--paper);
    box-shadow: 0 20px 40px rgba(23, 61, 36, .08);
    flex-direction: column;
  }

  .site-nav.open {
    display: flex;
  }

  .site-nav a {
    padding: 10px 0;
    font-size: 15px;
  }

  .menu-button {
    display: block;
  }

  .header-cta {
    display: none;
  }

  .hero-grid {
    grid-template-columns: 1fr;
  }

  .hero-copy {
    min-height: 610px;
    padding: 62px;
  }

  .hero-copy h1 {
    max-width: 12ch;
    font-size: 60px;
  }

  .hero-media,
  .hero-media > .hero-media-main {
    min-height: 620px;
  }

  .media-story-grid {
    min-height: 600px;
  }

  .doctor-grid,
  .doctor-page-grid {
    grid-template-columns: 1fr 1.05fr;
    gap: 42px;
  }

  .doctor-photo,
  .doctor-page-photo {
    min-height: 570px;
    height: 600px;
  }

  .doctor-photo img {
    height: 600px;
  }

  .care-guide-grid,
  .article-grid,
  .article-grid-media,
  .article-grid-page {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .article-grid-media .article-card-media:last-child {
    grid-column: 1 / -1;
    grid-template-columns: .9fr 1.1fr;
    grid-template-rows: 1fr;
    min-height: 390px;
  }

  .steps {
    grid-template-columns: 1fr;
  }

  .steps li {
    min-height: 0;
  }

  .advantages-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .advantages-grid article,
  .advantages-grid article:nth-child(3n) {
    border-right: 1px solid var(--line);
  }

  .advantages-grid article:nth-child(2n) {
    border-right: 0;
  }

  .advantages-grid article:nth-child(n + 3) {
    border-top: 1px solid var(--line);
  }

  .booking-grid,
  .credentials-layout,
  .faq-directory-layout {
    grid-template-columns: 1fr;
  }

  .faq-directory-layout {
    gap: 42px;
  }

  .booking-intro,
  .credentials-heading,
  .faq-directory-layout > aside {
    position: static;
  }

  .detail-hero {
    grid-template-columns: 1fr 280px;
  }

  .crm-shell {
    grid-template-columns: 224px minmax(0, 1fr);
  }

  .crm-sidebar {
    padding-inline: 16px;
  }

  .crm-metrics-five,
  .analytics-metrics,
  .greeting-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .greeting-campaign-list {
    grid-template-columns: 1fr;
  }

  .patient-greeting-status {
    grid-template-columns: 1fr 1fr;
  }

  .patient-greeting-status > div:nth-child(2) {
    border-right: 0;
  }

  .patient-greeting-status > div:nth-child(-n + 2) {
    border-bottom: 1px solid var(--line);
  }

  .finance-metrics,
  .finance-breakdown,
  .finance-filters {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .finance-filter-search,
  .finance-filters > .button {
    grid-column: 1 / -1;
  }

  .reminder-health > div {
    grid-template-columns: 1fr;
  }

  .reminder-health > div > div {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .reminder-health > div > div:last-child {
    border-bottom: 0;
  }

  .reminder-queue-list article {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .reminder-queue-list article > div:first-child {
    grid-column: 1 / -1;
  }

  .notification-filters {
    grid-template-columns: 1fr 1fr;
  }

  .notification-filters input {
    grid-column: 1 / -1;
    border-right: 1px solid #cbd6d1;
    border-radius: 9px 9px 0 0;
  }

  .notification-filters select:nth-of-type(2) {
    border-right: 1px solid #cbd6d1;
  }

  .notification-filters button {
    grid-column: 1 / -1;
    border-radius: 0 0 9px 9px;
  }
}

/* Mobile */
@media (max-width: 700px) {
  .cms-module-grid,
  .cms-form-grid {
    grid-template-columns: 1fr;
  }

  .cms-module-card {
    min-height: 190px;
  }

  .cms-content-row {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .cms-content-row.cms-access-row {
    grid-template-columns: 1fr;
  }

  .cms-row-action {
    justify-self: start;
  }

  .cms-delete-link {
    width: 100%;
    margin: 8px 0 0;
  }

  :root {
    --page: calc(100% - 28px);
    --radius: 18px;
    --radius-sm: 12px;
    --radius-media: 20px;
  }

  html {
    scroll-padding-top: 72px;
  }

  .container {
    width: var(--page);
    padding-inline: 0;
  }

  h1 {
    font-size: clamp(38px, 10vw, 46px);
  }

  h2 {
    font-size: clamp(30px, 8.5vw, 38px);
  }

  h3 {
    font-size: 22px;
  }

  .section {
    padding: 78px 0;
  }

  .home-page .section {
    padding: 64px 0;
  }

  .inner-page-section {
    --inner-page-top: 28px;
    padding-block: var(--inner-page-top) 72px;
  }

  .inner-page-intro:not(.detail-hero) {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .inner-page-intro:not(.detail-hero) > p:last-child {
    grid-column: 1;
    grid-row: auto;
    margin-top: 16px;
  }

  .section-heading {
    align-items: flex-start;
    margin-bottom: 36px;
    flex-direction: column;
  }

  .header-row {
    min-height: 72px;
  }

  .brand-mark {
    width: 42px;
    height: 35px;
    flex-basis: 42px;
  }

  .brand strong {
    font-size: 16px;
  }

  .brand small {
    font-size: 11px;
  }

  .site-nav {
    top: 72px;
    right: -14px;
    left: -14px;
    padding-inline: 28px;
  }

  .hero {
    padding: 14px 0 62px;
  }

  .hero-grid {
    min-height: 0;
    border-radius: 22px;
  }

  .hero-copy {
    min-height: 0;
    padding: 42px 24px 46px;
  }

  .hero-copy::after {
    right: 20px;
    bottom: 20px;
    width: 46px;
    height: 46px;
  }

  .hero-copy h1 {
    max-width: 10.7ch;
    font-size: clamp(40px, 11.5vw, 46px);
  }

  .hero-lead {
    margin-top: 24px;
    font-size: 16px;
  }

  .hero-actions {
    align-items: stretch;
    gap: 18px;
    margin-top: 28px;
    flex-direction: column;
  }

  .hero-actions .button {
    width: 100%;
  }

  .hero-actions .text-link {
    align-self: flex-start;
  }

  .trust-list {
    gap: 8px 16px;
    margin-top: 32px;
    padding-right: 50px;
    padding-top: 20px;
    font-size: 12px;
  }

  .hero-media,
  .hero-media > .hero-media-main {
    min-height: 480px;
  }

  .hero-media {
    height: 480px;
    border-radius: 0;
  }

  .hero-media figcaption {
    right: 14px;
    bottom: 14px;
    left: 14px;
    grid-template-columns: 1fr;
    gap: 14px;
    padding: 15px;
    border-radius: 14px;
  }

  .hero-media figcaption > span {
    padding-bottom: 12px;
    border-bottom: 1px solid var(--line);
  }

  .hero-doctor-link {
    grid-template-columns: 40px 1fr 18px;
    min-width: 0;
    padding-left: 0;
    border-left: 0;
  }

  .hero-doctor-link > img {
    width: 40px !important;
    height: 40px !important;
  }

  .service-grid {
    grid-template-columns: 1fr;
  }

  .service-card {
    grid-column: auto;
    min-height: 310px;
    padding: 26px;
  }

  .media-story-grid {
    display: flex;
    min-height: 0;
    gap: 12px;
    margin-right: -14px;
    padding-right: 14px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
  }

  .media-story-grid::-webkit-scrollbar {
    display: none;
  }

  .media-tile,
  .media-tile-main {
    flex: 0 0 84vw;
    height: 460px;
    border-radius: var(--radius-media);
    scroll-snap-align: center;
  }

  .media-tile-copy {
    grid-template-columns: 1fr;
  }

  .media-tile-copy i {
    display: none;
  }

  .media-story-heading h2 br {
    display: none;
  }

  .media-story-foot {
    align-items: flex-start;
    flex-direction: column;
  }

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

  .doctor-photo,
  .doctor-page-photo {
    min-height: 520px;
    height: 560px;
    border-radius: var(--radius-media);
  }

  .doctor-photo img {
    height: 560px;
  }

  .doctor-page-intro h1 {
    max-width: none;
    font-size: 42px;
  }

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

  .advantages-grid,
  .care-guide-grid,
  .article-grid,
  .article-grid-media,
  .article-grid-page,
  .expertise-grid {
    grid-template-columns: 1fr;
  }

  .advantages-grid article,
  .advantages-grid article:nth-child(2n),
  .advantages-grid article:nth-child(3n) {
    min-height: 190px;
    border-right: 0;
  }

  .advantages-grid article:nth-child(n + 2) {
    border-top: 1px solid var(--line);
  }

  .article-grid-media .article-card-media:last-child,
  .article-card-media {
    grid-column: auto;
    grid-template-columns: 1fr;
    grid-template-rows: 220px 1fr;
    min-height: 530px;
  }

  .article-card,
  .article-card-media {
    min-height: 0;
  }

  .steps li {
    grid-template-columns: 42px 1fr;
    padding: 25px;
  }

  .contact-card {
    align-items: flex-start;
    padding: 38px 26px;
    border-radius: 20px;
    flex-direction: column;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .legal-row {
    flex-direction: column;
  }

  .legal-row p:last-child {
    text-align: left;
  }

  .post-header {
    padding: 70px 0;
  }

  .post-header h1 {
    max-width: none;
  }

  .price-list {
    grid-template-columns: 1fr;
  }

  .price-list article {
    grid-template-columns: 1fr;
    min-height: 0;
    padding: 26px;
  }

  .price-actions {
    align-items: flex-start;
  }

  .detail-hero {
    grid-template-columns: 1fr;
  }

  .post-review-meta {
    flex-direction: column;
    gap: 4px;
  }

  .post-cta {
    padding: 34px 24px;
  }

  .post-cta h2 {
    font-size: 32px;
  }

  .credentials-list li {
    grid-template-columns: 74px 1fr;
    gap: 18px;
  }

  .booking-page {
    padding: 58px 0 78px;
  }

  .booking-grid {
    grid-template-columns: 1fr;
  }

  .booking-intro h1 {
    max-width: none;
    font-size: 42px;
  }

  .booking-form {
    grid-template-columns: 1fr;
    padding: 26px 20px;
    border-radius: 20px;
  }

  .field {
    grid-column: 1 / -1;
  }

  .status-card,
  .login-card {
    padding: 34px 22px;
    border-radius: 20px;
  }

  .patient-portal header,
  .portal-card {
    align-items: flex-start;
    flex-direction: column;
  }

  .portal-actions {
    align-items: stretch;
    width: 100%;
  }

  .quick-booking {
    right: 10px;
    bottom: calc(10px + env(safe-area-inset-bottom));
    left: 10px;
    max-width: none;
    padding-left: 13px;
    border-radius: 14px;
  }

  .quick-booking-copy {
    min-width: 0;
    margin-right: auto;
  }

  .quick-booking-copy strong {
    font-size: 12px;
  }

  .quick-booking-phone {
    display: none;
  }

  .crm-shell {
    display: block;
  }

  .crm-sidebar {
    position: static;
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    height: auto;
    padding: 18px 14px;
    flex-direction: row;
  }

  .crm-sidebar-brand,
  .crm-user,
  .crm-sidebar-secondary {
    display: none;
  }

  .crm-sidebar nav {
    display: flex;
    min-width: 0;
    gap: 6px;
    margin: 0;
    overflow-x: auto;
    flex: 1 1 auto;
  }

  .crm-sidebar nav a {
    flex: 0 0 auto;
    padding: 9px 11px;
    background: rgba(255, 255, 255, .06);
    white-space: nowrap;
  }

  .crm-theme-toggle {
    display: grid;
    flex: 0 0 42px;
    width: 42px;
    min-height: 42px;
    height: 42px;
    margin: 0;
    padding: 0;
    place-items: center;
  }

  .crm-theme-icons {
    width: 30px;
    height: 30px;
  }

  .crm-theme-copy {
    display: none;
  }

  .crm-main {
    padding: 32px 14px 70px;
  }

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

  .crm-search {
    width: 100%;
    min-width: 0;
  }

  .crm-search input {
    width: 100%;
  }

  .crm-metrics,
  .metrics,
  .crm-metrics-five,
  .analytics-metrics {
    grid-template-columns: 1fr 1fr;
  }

  .finance-metrics,
  .finance-breakdown,
  .greeting-metrics {
    grid-template-columns: 1fr 1fr;
  }

  .finance-filters {
    grid-template-columns: 1fr;
  }

  .finance-filter-search {
    grid-column: auto;
  }

  .appointment-income-list article {
    grid-template-columns: 1fr;
    gap: 5px;
  }

  .patient-greeting-status {
    grid-template-columns: 1fr;
  }

  .patient-greeting-status > div,
  .patient-greeting-status > div:nth-child(2) {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .patient-greeting-status > div:last-child {
    border-bottom: 0;
  }

  .patient-greeting-history article {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .appointment-item,
  .appointment-item-rich,
  .call-card,
  .patient-row,
  .patient-table-head {
    grid-template-columns: 1fr;
  }

  .patient-table-head {
    display: none;
  }

  .schedule-layout,
  .analytics-grid,
  .patient-detail-grid {
    grid-template-columns: 1fr;
  }

  .panel-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .reminder-status-grid {
    grid-template-columns: 1fr;
  }

  .reminder-status-grid > div,
  .reminder-status-grid > div:nth-child(2) {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .reminder-status-grid > div:last-child {
    border-bottom: 0;
  }

  .reminder-queue-list article {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .notification-filters {
    grid-template-columns: 1fr;
  }

  .notification-filters input,
  .notification-filters select,
  .notification-filters select:nth-of-type(2) {
    grid-column: auto;
    border-right: 1px solid #cbd6d1;
    border-bottom: 0;
    border-radius: 0;
  }

  .notification-filters input {
    border-radius: 9px 9px 0 0;
  }

  .notification-filters button {
    grid-column: auto;
  }
}

@media (max-width: 380px) {
  .hero-copy h1,
  .doctor-page-intro h1,
  .booking-intro h1 {
    font-size: 38px;
  }

  .quick-booking-copy strong {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    transition: none !important;
    animation: none !important;
  }

  .reveal-item {
    opacity: 1;
    transform: none;
  }
}

@media print {
  .site-header,
  .site-footer,
  .quick-booking {
    display: none !important;
  }
}

/* Editorial layer: hierarchy and magazine-like rhythm without compromising clarity. */
:root {
  --editorial: "Iowan Old Style", "Palatino Linotype", Georgia, serif;
}

.hero-copy h1 em,
.journal-intro h1 em {
  color: var(--peach);
  font-family: var(--editorial);
  font-style: italic;
  font-weight: 400;
  letter-spacing: -.055em;
}

.hero-copy h1 em {
  display: inline;
  color: var(--hero-emphasis);
}

.editorial-manifest {
  padding: clamp(28px, 3vw, 44px) 0;
  background: var(--warm-section);
}

.editorial-manifest-grid {
  display: grid;
  grid-template-columns: minmax(190px, .65fr) minmax(440px, 1.65fr) minmax(250px, .7fr);
  align-items: center;
  gap: clamp(30px, 4vw, 72px);
  padding-block: 0;
  border-block: 0;
}

.editorial-manifest-grid p {
  margin: 0;
}

.editorial-manifest-label {
  display: grid;
  gap: 8px;
  color: var(--green);
  font-size: 11px;
  font-weight: 760;
  letter-spacing: .12em;
  line-height: 1.4;
  text-transform: uppercase;
}

.editorial-manifest-label small {
  color: var(--muted);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .06em;
}

.editorial-manifest-statement {
  display: grid;
  gap: 3px;
  color: var(--ink);
  line-height: 1;
}

.editorial-manifest-statement > span {
  display: grid;
  grid-template-columns: minmax(118px, .72fr) minmax(0, 1fr);
  align-items: baseline;
  gap: clamp(16px, 2vw, 32px);
  padding: 9px 0 10px;
}

.editorial-manifest-statement small {
  color: var(--muted);
  font-size: 10px;
  font-weight: 730;
  letter-spacing: .12em;
  line-height: 1.35;
  text-transform: uppercase;
}

.editorial-manifest-statement strong {
  color: var(--green);
  font: italic 400 clamp(35px, 2.65vw, 50px)/.92 var(--editorial);
  letter-spacing: -.045em;
}

.editorial-manifest-statement > span:nth-child(2) strong {
  color: var(--rose-deep);
}

.editorial-manifest-note {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.65;
}

.article-grid-editorial {
  grid-template-columns: repeat(12, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(345px, auto));
}

.article-grid-editorial .article-card-media {
  min-height: 0;
  border-radius: 3px;
}

.article-grid-editorial .article-card-media:first-child {
  grid-column: span 7;
  grid-row: 1 / 3;
  grid-template-rows: minmax(360px, .9fr) minmax(320px, .8fr);
}

.article-grid-editorial .article-card-media:nth-child(n + 2) {
  grid-column: span 5;
  grid-template-columns: minmax(220px, .84fr) minmax(280px, 1.16fr);
  grid-template-rows: 1fr;
}

.article-grid-editorial .article-card-media:first-child .article-card-content {
  background: var(--brand-panel);
  color: var(--ink);
}

.article-grid-editorial .article-card-media:first-child h3,
.article-grid-editorial .article-card-media:first-child .card-link {
  color: var(--ink);
}

.article-grid-editorial .article-card-media:first-child h3 {
  max-width: 17ch;
  font-size: clamp(30px, 2.2vw, 42px);
}

.article-grid-editorial .article-card-media:first-child .article-card-content > p,
.article-grid-editorial .article-card-media:first-child time {
  color: #53665e;
}

.article-grid-editorial .article-card-media:first-child .article-card-meta span:first-child {
  color: var(--green-2);
}

.article-grid-editorial .article-card-media:first-child .article-card-foot {
  border-color: rgba(71, 123, 73, .2);
}

.article-grid-editorial .article-card-media:nth-child(2) {
  background: var(--sage-soft);
}

.article-grid-editorial .article-card-media:nth-child(3) {
  background: #faefec;
}

.article-grid-editorial .article-card-media:nth-child(n + 2) .article-card-content {
  padding: 24px;
}

.article-grid-editorial .article-card-media:nth-child(n + 2) .article-card-content h3 {
  margin-top: 22px;
  font-size: clamp(22px, 1.35vw, 27px);
}

.article-grid-editorial .article-card-cover > span {
  position: absolute;
  z-index: 2;
  top: 18px;
  left: 18px;
  display: block;
  color: rgba(255, 255, 255, .92);
  font: 650 11px/1 var(--sans);
  letter-spacing: .1em;
}

/* Journal directory */
.journal-intro h1 em {
  color: var(--peach);
}

.journal-directory {
  background: var(--paper);
}

.journal-directory .filter-pills {
  margin-bottom: 54px;
}

.journal-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 1px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: var(--line);
}

.journal-grid .article-card {
  grid-column: span 4;
  min-height: 390px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: var(--paper);
}

.journal-grid .article-card:hover {
  z-index: 1;
  box-shadow: inset 0 0 0 1px rgba(71, 123, 73, .24);
  transform: none;
}

.journal-card-copy {
  position: relative;
  display: flex;
  height: 100%;
  padding: 34px;
  flex-direction: column;
}

.journal-grid .article-number {
  position: absolute;
  top: 23px;
  right: 27px;
  display: block;
  color: rgba(71, 123, 73, .09);
  font: 650 62px/.9 var(--sans);
  font-variant-numeric: lining-nums tabular-nums;
  letter-spacing: -.07em;
}

.journal-grid .article-card-meta {
  position: relative;
  z-index: 1;
  padding-right: 64px;
}

.journal-grid .article-card h2 {
  max-width: 18ch;
  margin-top: 64px;
  font-size: clamp(25px, 1.55vw, 31px);
}

.journal-grid .article-card-featured {
  display: grid;
  grid-column: span 8;
  grid-row: span 2;
  grid-template-columns: minmax(0, 1.18fr) minmax(330px, .82fr);
  min-height: 781px;
  background: var(--cream);
}

.journal-card-cover {
  position: relative;
  min-height: 100%;
  overflow: hidden;
}

.journal-card-cover::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 55%, rgba(23, 61, 36, .42));
}

.journal-card-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(.78);
  transition: filter .35s ease, transform .8s cubic-bezier(.2, .8, .2, 1);
}

.article-card-featured:hover .journal-card-cover img {
  filter: saturate(.94);
  transform: scale(1.025);
}

.journal-card-cover span {
  position: absolute;
  z-index: 2;
  left: 26px;
  bottom: 24px;
  padding-top: 10px;
  border-top: 1px solid rgba(255, 255, 255, .6);
  color: white;
  font-size: 9px;
  font-weight: 760;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.journal-grid .article-card-featured .journal-card-copy {
  padding: clamp(34px, 3.2vw, 58px);
}

.journal-grid .article-card-featured h2 {
  margin-top: auto;
  font-size: clamp(34px, 2.7vw, 52px);
  line-height: 1.06;
}

.journal-grid .article-card-featured .article-card-foot {
  margin-top: 26px;
}

.post-folio {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
  margin-bottom: 50px;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(71, 123, 73, .2);
}

.post-folio .back-link {
  margin: 0;
}

.post-folio > span {
  color: var(--muted);
  font-size: 9px;
  font-weight: 760;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.post-header-editorial h1 {
  max-width: 14ch;
}

.post-body > p:first-of-type::first-letter {
  float: left;
  margin: .06em .11em 0 0;
  color: var(--rose-deep);
  font: 400 4.6em/.72 var(--editorial);
}

@media (max-width: 1100px) {
  .editorial-manifest-grid {
    grid-template-columns: minmax(180px, .55fr) minmax(0, 1.45fr);
  }

  .editorial-manifest-note {
    grid-column: 2;
  }

  .article-grid-editorial {
    grid-template-rows: auto;
  }

  .article-grid-editorial .article-card-media:first-child {
    grid-column: 1 / -1;
    grid-row: auto;
    grid-template-columns: 1.05fr .95fr;
    grid-template-rows: minmax(420px, auto);
  }

  .article-grid-editorial .article-card-media:nth-child(n + 2) {
    grid-column: span 6;
    grid-template-columns: 1fr;
    grid-template-rows: 230px 1fr;
  }

  .journal-grid .article-card-featured {
    grid-column: 1 / -1;
    grid-row: auto;
    min-height: 620px;
  }

  .journal-grid .article-card {
    grid-column: span 6;
  }
}

@media (max-width: 700px) {
  .editorial-manifest {
    padding-bottom: 24px;
  }

  .editorial-manifest-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .editorial-manifest-statement {
    width: 100%;
  }

  .editorial-manifest-statement > span {
    grid-template-columns: minmax(98px, .58fr) minmax(0, 1fr);
    gap: 14px;
    padding-block: 8px 9px;
  }

  .editorial-manifest-statement strong {
    font-size: clamp(32px, 10vw, 40px);
  }

  .editorial-manifest-note {
    grid-column: auto;
    padding: 0;
  }

  .article-grid-editorial {
    display: grid;
    grid-template-columns: 1fr;
  }

  .article-grid-editorial .article-card-media:first-child,
  .article-grid-editorial .article-card-media:nth-child(n + 2) {
    grid-column: auto;
    grid-template-columns: 1fr;
    grid-template-rows: 230px 1fr;
    min-height: 530px;
  }

  .article-grid-editorial .article-card-media:first-child .article-card-content {
    min-height: 330px;
  }

  .journal-directory .filter-pills {
    margin-bottom: 36px;
  }

  .journal-grid {
    grid-template-columns: 1fr;
  }

  .journal-grid .article-card,
  .journal-grid .article-card-featured {
    display: flex;
    grid-column: auto;
    min-height: 0;
    flex-direction: column;
  }

  .journal-grid .article-card-featured {
    grid-row: auto;
  }

  .journal-card-cover {
    min-height: 360px;
  }

  .journal-card-copy,
  .journal-grid .article-card-featured .journal-card-copy {
    min-height: 390px;
    padding: 28px;
  }

  .journal-grid .article-card h2,
  .journal-grid .article-card-featured h2 {
    margin-top: 56px;
    font-size: 29px;
    line-height: 1.12;
  }

  .post-folio {
    align-items: flex-start;
    flex-direction: column;
    gap: 12px;
  }
}
