/* Нормокард — design system.
   One palette, one type scale, one spacing scale. Every component below uses
   only these tokens, so the site looks consistent no matter what the CMS
   content contains. */

@font-face {
  font-family: "Raleway";
  src: url("/assets/fonts/Raleway-VariableFont.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  /* brand: logo blue #095DAB */
  --c-primary: #095dab;
  --c-primary-hover: #074b8b;
  --c-primary-soft: #e8f1fa;
  --c-primary-ink: #ffffff;
  --c-accent: #e2574c;          /* heart red, used sparingly: CTA highlights, alerts */
  --c-accent-soft: #fdecea;

  --c-ink: #1b2433;
  --c-ink-2: #46516a;
  --c-muted: #6b768c;
  --c-line: #e2e7ef;
  --c-line-strong: #cdd5e1;
  --c-bg: #f5f7fb;
  --c-surface: #ffffff;
  --c-surface-2: #f0f4f9;

  --c-success: #1f8a5b;
  --c-success-soft: #e6f5ee;
  --c-warning: #a36a00;
  --c-warning-soft: #fff4dc;
  --c-danger: #c23a30;
  --c-danger-soft: #fdecea;

  --font-display: "Raleway", system-ui, sans-serif;
  --font-body: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  --fs-xs: 0.8125rem;
  --fs-sm: 0.9375rem;
  --fs-md: 1rem;
  --fs-lg: 1.125rem;
  --fs-xl: 1.375rem;
  --fs-2xl: clamp(1.5rem, 1.2rem + 1.2vw, 2rem);
  --fs-3xl: clamp(1.875rem, 1.4rem + 2vw, 2.75rem);

  --sp-1: 0.25rem;
  --sp-2: 0.5rem;
  --sp-3: 0.75rem;
  --sp-4: 1rem;
  --sp-5: 1.5rem;
  --sp-6: 2rem;
  --sp-7: 3rem;
  --sp-8: 4.5rem;

  --radius-sm: 8px;
  --radius: 14px;
  --radius-lg: 22px;
  --shadow-sm: 0 1px 2px rgb(16 32 64 / 6%);
  --shadow: 0 2px 6px rgb(16 32 64 / 6%), 0 8px 24px rgb(16 32 64 / 6%);
  --shadow-lg: 0 12px 40px rgb(16 32 64 / 12%);

  --container: 1280px;
  --header-h: 72px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

/* ---------- base ---------- */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: calc(var(--header-h) + var(--sp-4));
}

body {
  margin: 0;
  background: var(--c-bg);
  color: var(--c-ink);
  font: 400 var(--fs-md) / 1.6 var(--font-body);
  font-variant-numeric: lining-nums;
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: var(--c-primary);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

a:hover {
  color: var(--c-primary-hover);
}

:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--c-primary) 45%, transparent);
  outline-offset: 2px;
  border-radius: 4px;
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-display);
  font-variant-numeric: lining-nums;
  line-height: 1.2;
  color: var(--c-ink);
  margin: 0 0 var(--sp-4);
  text-wrap: balance;
}

h1 {
  font-size: var(--fs-3xl);
  font-weight: 700;
}

h2 {
  font-size: var(--fs-2xl);
  font-weight: 700;
}

h3 {
  font-size: var(--fs-xl);
  font-weight: 650;
}

h4 {
  font-size: var(--fs-lg);
  font-weight: 650;
}

p {
  margin: 0 0 var(--sp-4);
}

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* ---------- layout ---------- */

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--sp-4);
}

@media (min-width: 768px) {
  .container {
    padding-inline: var(--sp-5);
  }
}

.app {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main {
  flex: 1;
}

.page {
  padding-block: var(--sp-6) var(--sp-8);
}

.page-head {
  margin-bottom: var(--sp-6);
}

.page-head p {
  color: var(--c-ink-2);
  font-size: var(--fs-lg);
  max-width: 62ch;
}

.section {
  padding-block: var(--sp-7);
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: var(--sp-4);
  margin-bottom: var(--sp-5);
  flex-wrap: wrap;
}

.section-head h2 {
  margin: 0;
}

.grid {
  display: grid;
  gap: var(--sp-5);
}

.grid-2 {
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 420px), 1fr));
}

.grid-3 {
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr));
}

.grid-4 {
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 230px), 1fr));
}

.stack > * + * {
  margin-top: var(--sp-5);
}

.muted {
  color: var(--c-muted);
}

/* ---------- buttons ---------- */

.btn {
  --btn-bg: var(--c-primary);
  --btn-fg: var(--c-primary-ink);
  --btn-bd: var(--c-primary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  min-height: 44px;
  padding: 0 var(--sp-5);
  border-radius: 999px;
  border: 1.5px solid var(--btn-bd);
  background: var(--btn-bg);
  color: var(--btn-fg);
  font: 600 var(--fs-sm) / 1 var(--font-body);
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.15s, border-color 0.15s, transform 0.15s var(--ease), box-shadow 0.15s;
}

.btn:hover {
  --btn-bg: var(--c-primary-hover);
  --btn-bd: var(--c-primary-hover);
  color: var(--btn-fg);
  box-shadow: var(--shadow-sm);
}

.btn:active {
  transform: translateY(1px);
}

.btn[disabled] {
  opacity: 0.55;
  cursor: not-allowed;
}

.btn-outline {
  --btn-bg: transparent;
  --btn-fg: var(--c-primary);
  --btn-bd: var(--c-line-strong);
}

.btn-outline:hover {
  --btn-bg: var(--c-primary-soft);
  --btn-fg: var(--c-primary);
  --btn-bd: var(--c-primary);
}

.btn-ghost {
  --btn-bg: transparent;
  --btn-fg: var(--c-ink-2);
  --btn-bd: transparent;
}

.btn-ghost:hover {
  --btn-bg: var(--c-surface-2);
  --btn-fg: var(--c-ink);
  --btn-bd: transparent;
}

.btn-lg {
  min-height: 52px;
  padding: 0 var(--sp-6);
  font-size: var(--fs-md);
}

.btn-sm {
  min-height: 36px;
  padding: 0 var(--sp-4);
  font-size: var(--fs-xs);
}

/* ---------- cards ---------- */

.card {
  background: var(--c-surface);
  border: 1px solid var(--c-line);
  border-radius: var(--radius);
  padding: var(--sp-5);
  box-shadow: var(--shadow-sm);
}

a.card,
.card-link {
  color: inherit;
  text-decoration: none;
  transition: box-shadow 0.2s var(--ease), transform 0.2s var(--ease), border-color 0.2s;
}

a.card:hover,
.card-link:hover {
  color: inherit;
  border-color: var(--c-line-strong);
  box-shadow: var(--shadow);
  transform: translateY(-2px);
}

.card h3 {
  font-size: var(--fs-lg);
  margin-bottom: var(--sp-2);
}

.card p:last-child {
  margin-bottom: 0;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-1);
  padding: 2px 10px;
  border-radius: 999px;
  background: var(--c-primary-soft);
  color: var(--c-primary);
  font-size: var(--fs-xs);
  font-weight: 600;
}

.badges {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2);
}

/* doctor card */

.doc-card {
  display: grid;
  grid-template-columns: 88px 1fr;
  gap: var(--sp-4);
  align-items: start;
}

.avatar {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--c-surface-2);
  border: 3px solid var(--c-surface);
  box-shadow: 0 0 0 1px var(--c-line);
}

.avatar-lg {
  width: 168px;
  height: 168px;
}

.doc-card h3 {
  margin-bottom: var(--sp-1);
}

.doc-card .meta {
  color: var(--c-muted);
  font-size: var(--fs-sm);
  margin-bottom: var(--sp-3);
}

.doc-card .actions {
  display: flex;
  gap: var(--sp-2);
  flex-wrap: wrap;
  margin-top: var(--sp-3);
}

/* ---------- breadcrumbs ---------- */

.crumbs {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2);
  list-style: none;
  padding: 0;
  margin: 0 0 var(--sp-4);
  font-size: var(--fs-sm);
  color: var(--c-muted);
}

.crumbs li + li::before {
  content: "/";
  margin-right: var(--sp-2);
  color: var(--c-line-strong);
}

.crumbs a {
  color: var(--c-muted);
  text-decoration: none;
}

.crumbs a:hover {
  color: var(--c-primary);
}

/* ---------- rich text (CMS content) ---------- */

.prose {
  color: var(--c-ink);
}

/* Readable line length for text; blocks (galleries, cards, maps) keep full width. */
.prose > :is(p, ul, ol, h2, h3, h4, h5, blockquote) {
  max-width: 76ch;
}

.prose h2 {
  margin-top: var(--sp-6);
}

.prose h3 {
  margin-top: var(--sp-5);
  margin-bottom: var(--sp-3);
}

.prose h4 {
  margin-top: var(--sp-4);
  margin-bottom: var(--sp-2);
}

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

.prose ul,
.prose ol {
  padding-left: 1.4em;
  margin: 0 0 var(--sp-4);
}

.prose li {
  margin-bottom: var(--sp-1);
}

.prose li::marker {
  color: var(--c-primary);
}

.prose blockquote {
  margin: var(--sp-5) 0;
  padding: var(--sp-4) var(--sp-5);
  border-left: 4px solid var(--c-primary);
  background: var(--c-primary-soft);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

.prose code {
  background: var(--c-surface-2);
  padding: 0.1em 0.35em;
  border-radius: 4px;
  font-size: 0.9em;
}

.prose figure {
  margin: var(--sp-5) 0;
}

.prose .align-left {
  float: left;
  margin: 0 var(--sp-5) var(--sp-4) 0;
  max-width: 45%;
}

.prose .align-right {
  float: right;
  margin: 0 0 var(--sp-4) var(--sp-5);
  max-width: 45%;
}

@media (max-width: 640px) {
  .prose .align-left,
  .prose .align-right {
    float: none;
    max-width: 100%;
    margin: var(--sp-4) 0;
  }
}

figure img {
  border-radius: var(--radius);
}

figure.small img {
  max-width: 320px;
}

figure.bordered img {
  border: 1px solid var(--c-line);
}

figure.square img {
  border-radius: 0;
}

figcaption {
  margin-top: var(--sp-2);
  font-size: var(--fs-sm);
  color: var(--c-muted);
}

/* ---------- blocks ---------- */

.block {
  margin-bottom: var(--sp-6);
}

.block-title {
  margin-bottom: var(--sp-4);
}

.columns {
  display: grid;
  gap: var(--sp-6);
}

@media (min-width: 900px) {
  .columns {
    grid-template-columns: var(--cols);
  }
}

.collapsible {
  background: var(--c-surface);
  border: 1px solid var(--c-line);
  border-radius: var(--radius);
}

.collapsible > summary,
.faq summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-4);
  font: 650 var(--fs-lg) / 1.3 var(--font-display);
}

.collapsible > summary {
  padding: var(--sp-4) var(--sp-5);
}

.collapsible > summary::-webkit-details-marker,
.faq summary::-webkit-details-marker {
  display: none;
}

.collapsible > summary::after,
.faq summary::after {
  content: "";
  flex-shrink: 0;
  width: 10px;
  height: 10px;
  border-right: 2px solid var(--c-primary);
  border-bottom: 2px solid var(--c-primary);
  transform: rotate(45deg) translateY(-3px);
  transition: transform 0.2s var(--ease);
}

details[open] > summary::after {
  transform: rotate(-135deg) translateY(-3px);
}

.collapsible > .collapsible-body {
  padding: 0 var(--sp-5) var(--sp-5);
}

.banner {
  display: flex;
  gap: var(--sp-4);
  padding: var(--sp-5);
  border-radius: var(--radius);
  border: 1px solid;
}

.banner.info {
  background: var(--c-primary-soft);
  border-color: color-mix(in srgb, var(--c-primary) 25%, transparent);
}

.banner.warning {
  background: var(--c-warning-soft);
  border-color: color-mix(in srgb, var(--c-warning) 30%, transparent);
}

.banner.error {
  background: var(--c-danger-soft);
  border-color: color-mix(in srgb, var(--c-danger) 30%, transparent);
}

.banner.success {
  background: var(--c-success-soft);
  border-color: color-mix(in srgb, var(--c-success) 30%, transparent);
}

.banner .prose > :last-child {
  margin-bottom: 0;
}

.gallery {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: min(80%, 420px);
  gap: var(--sp-4);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding-bottom: var(--sp-3);
  scrollbar-width: thin;
}

.gallery figure {
  margin: 0;
  scroll-snap-align: start;
}

.gallery img {
  aspect-ratio: 4 / 3;
  width: 100%;
  object-fit: cover;
}

.map {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--c-line);
  aspect-ratio: 16 / 9;
  background: var(--c-surface-2);
}

.map iframe {
  width: 100%;
  height: 100%;
  border: 0;
}

.doc-list {
  display: grid;
  gap: var(--sp-2);
  list-style: none;
  padding: 0;
  margin: 0 0 var(--sp-4);
}

.doc-item {
  display: flex;
  align-items: center;
  gap: var(--sp-4);
  padding: var(--sp-3) var(--sp-4);
  background: var(--c-surface);
  border: 1px solid var(--c-line);
  border-radius: var(--radius-sm);
  text-decoration: none;
  color: var(--c-ink);
}

.doc-item:hover {
  border-color: var(--c-primary);
  color: var(--c-ink);
}

.doc-item .ext {
  flex-shrink: 0;
  display: grid;
  place-items: center;
  width: 40px;
  height: 48px;
  border-radius: 6px;
  background: var(--c-accent-soft);
  color: var(--c-accent);
  font-size: 11px;
  font-weight: 750;
  text-transform: uppercase;
}

.doc-item small {
  display: block;
  color: var(--c-muted);
}

.faq {
  display: grid;
  border-top: 1px solid var(--c-line-strong);
}

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

.faq summary {
  padding: var(--sp-5) 0;
  font-size: var(--fs-lg);
  transition: color 0.15s;
}

.faq summary:hover {
  color: var(--c-primary);
}

/* plus that turns into a minus */
.faq summary::after {
  width: 14px;
  height: 14px;
  border: 0;
  transform: none;
  background:
    linear-gradient(var(--c-primary), var(--c-primary)) center / 14px 2px no-repeat,
    linear-gradient(var(--c-primary), var(--c-primary)) center / 2px 14px no-repeat;
  transition: background-size 0.2s var(--ease);
}

.faq details[open] > summary::after {
  transform: none;
  background-size: 14px 2px, 2px 0;
}

.faq details p {
  max-width: 72ch;
  color: var(--c-ink-2);
  padding-bottom: var(--sp-3);
}

/* ---------- forms ---------- */

.field {
  display: grid;
  gap: var(--sp-1);
}

.field label {
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--c-ink-2);
}

.input,
select.input,
textarea.input {
  width: 100%;
  min-height: 46px;
  padding: var(--sp-2) var(--sp-4);
  border: 1.5px solid var(--c-line-strong);
  border-radius: var(--radius-sm);
  background: var(--c-surface);
  color: var(--c-ink);
  font: inherit;
  transition: border-color 0.15s, box-shadow 0.15s;
}

textarea.input {
  min-height: 96px;
  resize: vertical;
}

.input:focus {
  outline: none;
  border-color: var(--c-primary);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--c-primary) 18%, transparent);
}

.input[aria-invalid="true"] {
  border-color: var(--c-danger);
}

.field .error {
  color: var(--c-danger);
  font-size: var(--fs-xs);
}

.check {
  display: flex;
  gap: var(--sp-3);
  align-items: flex-start;
  font-size: var(--fs-sm);
  color: var(--c-ink-2);
}

.check input {
  width: 20px;
  height: 20px;
  margin-top: 2px;
  accent-color: var(--c-primary);
  flex-shrink: 0;
}

.form-grid {
  display: grid;
  gap: var(--sp-4);
}

@media (min-width: 640px) {
  .form-grid {
    grid-template-columns: 1fr 1fr;
  }

  .form-grid .full {
    grid-column: 1 / -1;
  }
}

.hp {
  position: absolute;
  left: -10000px;
}

.search {
  position: relative;
  max-width: 480px;
}

.search .input {
  padding-left: 44px;
}

.search::before {
  content: "";
  position: absolute;
  left: 16px;
  top: 50%;
  width: 14px;
  height: 14px;
  border: 2px solid var(--c-muted);
  border-radius: 50%;
  transform: translateY(-60%);
}

.filters {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-3);
  align-items: center;
  margin-bottom: var(--sp-5);
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2);
}

.chip {
  min-height: 36px;
  padding: 0 var(--sp-4);
  border-radius: 999px;
  border: 1.5px solid var(--c-line-strong);
  background: var(--c-surface);
  color: var(--c-ink-2);
  font: 550 var(--fs-sm) / 1 var(--font-body);
  cursor: pointer;
}

.chip:hover {
  border-color: var(--c-primary);
  color: var(--c-primary);
}

.chip[aria-pressed="true"] {
  background: var(--c-primary);
  border-color: var(--c-primary);
  color: #fff;
}

/* ---------- prices ---------- */

.price-group {
  background: var(--c-surface);
  border: 1px solid var(--c-line);
  border-radius: var(--radius);
  overflow: hidden;
}

.price-group > summary {
  padding: var(--sp-4) var(--sp-5);
}

.price-group > summary .count {
  margin-left: auto;
  margin-right: var(--sp-3);
  color: var(--c-muted);
  font: 500 var(--fs-sm) / 1 var(--font-body);
}

.price-table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--fs-sm);
}

.price-table td {
  padding: var(--sp-3) var(--sp-5);
  border-top: 1px solid var(--c-line);
  vertical-align: top;
}

.price-table tr:hover td {
  background: var(--c-surface-2);
}

.price-table .code {
  width: 1%;
  white-space: nowrap;
  color: var(--c-muted);
  font-size: var(--fs-xs);
}

.price-table .price {
  width: 1%;
  white-space: nowrap;
  text-align: right;
  font-weight: 650;
}

@media (max-width: 640px) {
  .price-table .code {
    display: none;
  }

  .price-table td {
    padding-inline: var(--sp-4);
  }
}

/* ---------- appointment ---------- */

.steps {
  display: flex;
  gap: var(--sp-2);
  list-style: none;
  padding: 0;
  margin: 0 0 var(--sp-6);
  counter-reset: step;
  flex-wrap: wrap;
}

.steps li {
  counter-increment: step;
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  padding: var(--sp-2) var(--sp-4) var(--sp-2) var(--sp-2);
  border-radius: 999px;
  background: var(--c-surface);
  border: 1px solid var(--c-line);
  color: var(--c-muted);
  font-size: var(--fs-sm);
  font-weight: 550;
}

.steps li::before {
  content: counter(step);
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--c-surface-2);
  font-size: var(--fs-xs);
}

.steps li[data-state="current"] {
  border-color: var(--c-primary);
  color: var(--c-primary);
}

.steps li[data-state="current"]::before {
  background: var(--c-primary);
  color: #fff;
}

.steps li[data-state="done"] {
  color: var(--c-success);
}

.steps li[data-state="done"]::before {
  content: "✓";
  background: var(--c-success-soft);
}

.days {
  display: flex;
  gap: var(--sp-2);
  overflow-x: auto;
  padding-bottom: var(--sp-2);
  margin-bottom: var(--sp-4);
}

.day {
  flex-shrink: 0;
  display: grid;
  justify-items: center;
  gap: 2px;
  min-width: 64px;
  padding: var(--sp-2) var(--sp-3);
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--c-line);
  background: var(--c-surface);
  color: var(--c-ink-2);
  font: inherit;
  cursor: pointer;
}

.day small {
  font-size: var(--fs-xs);
  color: var(--c-muted);
  text-transform: capitalize;
}

.day strong {
  font: 700 var(--fs-lg) / 1 var(--font-display);
}

.day:hover {
  border-color: var(--c-primary);
}

.day[aria-pressed="true"] {
  background: var(--c-primary);
  border-color: var(--c-primary);
  color: #fff;
}

.day[aria-pressed="true"] small {
  color: rgb(255 255 255 / 80%);
}

.slots {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(84px, 1fr));
  gap: var(--sp-2);
}

.slot {
  min-height: 42px;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--c-line-strong);
  background: var(--c-surface);
  color: var(--c-ink);
  font: 600 var(--fs-sm) / 1 var(--font-body);
  cursor: pointer;
}

.slot:hover {
  border-color: var(--c-primary);
  color: var(--c-primary);
}

.slot[aria-pressed="true"] {
  background: var(--c-primary);
  border-color: var(--c-primary);
  color: #fff;
}

.summary {
  display: grid;
  gap: var(--sp-2);
  padding: var(--sp-4) var(--sp-5);
  background: var(--c-primary-soft);
  border-radius: var(--radius);
  margin-bottom: var(--sp-5);
}

.summary div {
  display: flex;
  gap: var(--sp-3);
}

.summary dt {
  color: var(--c-muted);
  min-width: 90px;
}

.summary dd {
  margin: 0;
  font-weight: 600;
}

.option-list {
  display: grid;
  gap: var(--sp-2);
}

.option {
  display: flex;
  align-items: center;
  gap: var(--sp-4);
  width: 100%;
  padding: var(--sp-3) var(--sp-4);
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--c-line);
  background: var(--c-surface);
  color: var(--c-ink);
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.option:hover {
  border-color: var(--c-primary);
}

.option .avatar {
  width: 52px;
  height: 52px;
}

.option small {
  display: block;
  color: var(--c-muted);
}

/* ---------- doctor profile ---------- */

.profile {
  display: grid;
  gap: var(--sp-6);
}

@media (min-width: 900px) {
  .profile {
    grid-template-columns: 1fr 380px;
    align-items: start;
  }

  .profile aside {
    position: sticky;
    top: calc(var(--header-h) + var(--sp-4));
  }
}

.profile-head {
  display: flex;
  gap: var(--sp-5);
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: var(--sp-5);
}

.facts {
  display: grid;
  gap: var(--sp-3);
  margin: 0 0 var(--sp-5);
}

.facts div {
  display: grid;
  gap: 2px;
}

.facts dt {
  color: var(--c-muted);
  font-size: var(--fs-sm);
}

.facts dd {
  margin: 0;
  white-space: pre-line;
}

/* ---------- states ---------- */

.skeleton {
  border-radius: var(--radius);
  background: linear-gradient(90deg, var(--c-surface-2) 0%, var(--c-surface) 50%, var(--c-surface-2) 100%);
  background-size: 200% 100%;
  animation: shimmer 1.2s linear infinite;
  min-height: 120px;
}

@keyframes shimmer {
  to {
    background-position: -200% 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .js-reveal [data-reveal]:not(.is-visible) {
    opacity: 1;
    transform: none;
  }

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}

.empty {
  padding: var(--sp-6);
  text-align: center;
  color: var(--c-muted);
  background: var(--c-surface);
  border: 1px dashed var(--c-line-strong);
  border-radius: var(--radius);
}

.notice {
  padding: var(--sp-4) var(--sp-5);
  border-radius: var(--radius);
  background: var(--c-warning-soft);
  color: var(--c-ink);
}

.notice.error {
  background: var(--c-danger-soft);
}

.notice.success {
  background: var(--c-success-soft);
}

/* ---------- CTA band ---------- */

.cta-band {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-5);
  padding: var(--sp-6);
  border-radius: var(--radius-lg);
  background: var(--c-primary-soft);
}

.cta-band h2 {
  margin-bottom: var(--sp-2);
}

.cta-band p {
  margin: 0;
  color: var(--c-ink-2);
}

/* ---------- footer ---------- */

.site-footer {
  background: #0f1e33;
  color: rgb(255 255 255 / 72%);
  font-size: var(--fs-sm);
  padding-top: var(--sp-7);
}

.site-footer a {
  color: rgb(255 255 255 / 86%);
  text-decoration: none;
}

.site-footer a:hover {
  color: #fff;
  text-decoration: underline;
}

.footer-grid {
  display: grid;
  gap: var(--sp-6);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr));
  padding-bottom: var(--sp-6);
}

.site-footer h4 {
  color: #fff;
  font-size: var(--fs-md);
  margin-bottom: var(--sp-3);
}

.site-footer ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: var(--sp-2);
}

.footer-bottom {
  border-top: 1px solid rgb(255 255 255 / 12%);
  padding-block: var(--sp-4) var(--sp-5);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: var(--sp-3);
  font-size: var(--fs-xs);
  color: rgb(255 255 255 / 55%);
}

.footer-logo {
  height: 38px;
  width: auto;
  margin-bottom: var(--sp-4);
  border-radius: 6px;
}

/* ---------- cookie banner ---------- */

.cookie {
  position: fixed;
  z-index: 60;
  inset: auto var(--sp-4) var(--sp-4);
  max-width: 560px;
  margin-inline: auto;
  display: flex;
  align-items: center;
  gap: var(--sp-4);
  padding: var(--sp-4) var(--sp-5);
  background: var(--c-surface);
  border: 1px solid var(--c-line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  font-size: var(--fs-sm);
}

.cookie p {
  margin: 0;
}

/* =========================================================
   Header
   ========================================================= */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--c-surface) 90%, transparent);
  backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.site-header.scrolled {
  border-bottom-color: var(--c-line);
  box-shadow: 0 6px 24px rgb(16 32 64 / 6%);
}

.header-bar {
  height: var(--header-h);
  display: flex;
  align-items: center;
  gap: var(--sp-5);
}

.logo {
  display: flex;
  flex-shrink: 0;
  border-radius: 6px;
  overflow: hidden;
}

.logo img {
  display: block;
  height: 34px;
  width: auto;
}

.nav {
  display: none;
  align-items: center;
  gap: 2px;
  margin-right: auto;
  white-space: nowrap;
}

.nav-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 40px;
  padding: 0 12px;
  border: 0;
  border-radius: 999px;
  background: none;
  color: var(--c-ink-2);
  font: 550 var(--fs-sm) / 1 var(--font-body);
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.nav-link:hover,
.nav-link[aria-current="page"],
.nav-link.active,
.nav-drop:focus-within > .nav-link {
  color: var(--c-primary);
  background: var(--c-primary-soft);
}

.nav-link svg {
  transition: transform 0.2s var(--ease);
}

.nav-drop {
  position: relative;
}

.nav-drop:hover > .nav-link svg,
.nav-drop:focus-within > .nav-link svg {
  transform: rotate(180deg);
}

.nav-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  min-width: 260px;
  display: grid;
  padding: var(--sp-2);
  background: var(--c-surface);
  border: 1px solid var(--c-line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: opacity 0.18s, transform 0.18s var(--ease), visibility 0.18s;
}

/* hover bridge so the menu does not close on the way down */
.nav-menu::before {
  content: "";
  position: absolute;
  inset: -10px 0 auto;
  height: 10px;
}

.nav-drop:hover .nav-menu,
.nav-drop:focus-within .nav-menu {
  opacity: 1;
  visibility: visible;
  transform: none;
}

.nav-menu a {
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  color: var(--c-ink);
  text-decoration: none;
  font-size: var(--fs-sm);
}

.nav-menu a:hover,
.nav-menu a[aria-current="page"] {
  background: var(--c-surface-2);
  color: var(--c-primary);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  margin-left: auto;
  flex-shrink: 0;
}

.icon-btn {
  display: inline-grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  color: var(--c-ink-2);
  background: transparent;
  transition: background 0.15s, transform 0.15s var(--ease), color 0.15s;
}

.icon-btn:hover {
  background: var(--c-surface-2);
  color: var(--c-primary);
  transform: translateY(-1px);
}

.header-phone {
  display: none;
  padding: 0 var(--sp-2);
  color: var(--c-ink);
  font-weight: 650;
  text-decoration: none;
  white-space: nowrap;
}

.header-phone:hover {
  color: var(--c-primary);
}

.header-cta {
  min-height: 42px;
}

.burger {
  position: relative;
  width: 44px;
  height: 44px;
  border: 1px solid var(--c-line);
  border-radius: 50%;
  background: var(--c-surface);
  cursor: pointer;
}

.burger span {
  position: absolute;
  left: 13px;
  right: 13px;
  height: 2px;
  border-radius: 2px;
  background: var(--c-ink);
  transition: transform 0.25s var(--ease), opacity 0.2s, top 0.25s var(--ease);
}

.burger span:nth-child(1) { top: 15px; }
.burger span:nth-child(2) { top: 21px; }
.burger span:nth-child(3) { top: 27px; }

.open .burger span:nth-child(1) { top: 21px; transform: rotate(45deg); }
.open .burger span:nth-child(2) { opacity: 0; }
.open .burger span:nth-child(3) { top: 21px; transform: rotate(-45deg); }

/* mobile sheet */

.mobile-nav {
  position: fixed;
  inset: var(--header-h) 0 0;
  overflow-y: auto;
  padding: var(--sp-3) 0 var(--sp-7);
  background: var(--c-surface);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-12px);
  transition: opacity 0.22s, transform 0.25s var(--ease), visibility 0.22s;
}

.mobile-nav.open {
  opacity: 1;
  visibility: visible;
  transform: none;
}

body.menu-open {
  overflow: hidden;
}

body.menu-open .mobile-cta {
  transform: translateY(110%);
}

.mobile-nav {
  z-index: 49;
}

.m-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0;
  border-bottom: 1px solid var(--c-line);
  color: var(--c-ink);
  font: 600 var(--fs-lg) / 1.2 var(--font-display);
  text-decoration: none;
  list-style: none;
  cursor: pointer;
}

.m-link::-webkit-details-marker {
  display: none;
}

.m-group > summary::after {
  content: "";
  width: 9px;
  height: 9px;
  border-right: 2px solid var(--c-muted);
  border-bottom: 2px solid var(--c-muted);
  transform: rotate(45deg);
  transition: transform 0.2s var(--ease);
}

.m-group[open] > summary::after {
  transform: rotate(-135deg);
}

.m-sub {
  display: grid;
  padding: var(--sp-2) 0 var(--sp-3) var(--sp-4);
  border-bottom: 1px solid var(--c-line);
}

.m-sub a {
  padding: 10px 0;
  color: var(--c-ink-2);
  text-decoration: none;
}

.m-contacts {
  display: grid;
  gap: var(--sp-4);
  margin-top: var(--sp-5);
}

.m-phone {
  font: 700 var(--fs-xl) / 1 var(--font-display);
  color: var(--c-ink);
  text-decoration: none;
}

.m-social {
  display: flex;
  gap: var(--sp-2);
}

.m-social .icon-btn {
  background: var(--c-surface-2);
  width: 48px;
  height: 48px;
}

@media (min-width: 1140px) {
  .nav { display: flex; }
  .burger, .mobile-nav { display: none; }
  .header-actions { margin-left: 0; }
}

@media (min-width: 1300px) {
  .header-phone { display: inline; }
}

@media (max-width: 640px) {
  :root { --header-h: 64px; }
  .logo img { height: 28px; }
  .hide-sm, .header-cta { display: none; }
}

/* sticky bottom CTA on phones */

.mobile-cta {
  position: fixed;
  z-index: 45;
  left: 0;
  right: 0;
  bottom: 0;
  display: none;
  gap: var(--sp-2);
  padding: var(--sp-2) var(--sp-4) calc(var(--sp-2) + env(safe-area-inset-bottom));
  background: color-mix(in srgb, var(--c-surface) 94%, transparent);
  backdrop-filter: blur(10px);
  border-top: 1px solid var(--c-line);
  transition: transform 0.25s var(--ease);
}

.mobile-cta .btn {
  flex: 1;
}

.mobile-cta.hidden {
  transform: translateY(110%);
}

@media (max-width: 760px) {
  .mobile-cta { display: flex; }
  .site-footer { padding-bottom: 72px; }
  .cookie { bottom: 80px; }
}

/* =========================================================
   Hero
   ========================================================= */

.hero {
  padding-top: var(--sp-4);
}

.hero-frame {
  position: relative;
  display: grid;
  min-height: clamp(480px, 42vw, 600px);
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: #0b3f75;
  isolation: isolate;
}

.hero-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 20% 40%;
  z-index: -2;
  animation: hero-zoom 14s var(--ease) both;
}

/* photo stays clear on the left, fades into brand blue under the text */
.hero-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(90deg, rgb(8 52 98 / 0%) 18%, rgb(8 52 98 / 72%) 48%, rgb(8 52 98 / 96%) 66%),
    linear-gradient(0deg, rgb(8 40 76 / 35%), transparent 40%);
}

.hero-content {
  justify-self: end;
  align-self: center;
  width: min(600px, 100%);
  padding: var(--sp-7) clamp(var(--sp-5), 5vw, var(--sp-8)) var(--sp-7) 0;
  color: #fff;
}

.hero-content > * {
  animation: rise 0.7s var(--ease) both;
}

.hero-content > :nth-child(2) { animation-delay: 0.06s; }
.hero-content > :nth-child(3) { animation-delay: 0.12s; }
.hero-content > :nth-child(4) { animation-delay: 0.18s; }
.hero-content > :nth-child(5) { animation-delay: 0.24s; }

.eyebrow {
  display: inline-block;
  margin-bottom: var(--sp-4);
  padding: 6px 12px;
  border-radius: 999px;
  background: rgb(255 255 255 / 14%);
  color: rgb(255 255 255 / 92%);
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.02em;
}

.hero h1 {
  color: #fff;
  font-size: clamp(2rem, 1.4rem + 2.2vw, 3.25rem);
  line-height: 1.08;
  margin-bottom: var(--sp-4);
}

.hero .lead {
  font-size: var(--fs-lg);
  line-height: 1.55;
  color: rgb(255 255 255 / 88%);
  margin-bottom: var(--sp-6);
}

.hero .btn {
  --btn-bg: #fff;
  --btn-fg: var(--c-primary);
  --btn-bd: #fff;
}

.hero .btn:hover {
  --btn-bg: var(--c-primary-soft);
  --btn-bd: var(--c-primary-soft);
}

.hero .btn-outline {
  --btn-bg: transparent;
  --btn-fg: #fff;
  --btn-bd: rgb(255 255 255 / 55%);
}

.hero .btn-outline:hover {
  --btn-bg: rgb(255 255 255 / 12%);
  --btn-fg: #fff;
  --btn-bd: #fff;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-3);
}

.hero-facts {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-5) var(--sp-6);
  margin: var(--sp-6) 0 0;
  padding: var(--sp-5) 0 0;
  list-style: none;
  border-top: 1px solid rgb(255 255 255 / 22%);
  font-size: var(--fs-sm);
  color: rgb(255 255 255 / 75%);
}

.hero-facts strong {
  display: block;
  color: #fff;
  font: 650 var(--fs-md) / 1.3 var(--font-display);
}

@media (max-width: 860px) {
  .hero {
    padding-top: 0;
  }

  .hero .container {
    padding-inline: 0;
  }

  .hero-frame {
    min-height: 0;
    border-radius: 0;
    grid-template-rows: auto auto;
    background: linear-gradient(180deg, #0a447f, #083462);
  }

  .hero-photo {
    position: relative;
    aspect-ratio: 16 / 10;
    height: auto;
    z-index: 0;
    animation: none;
  }

  .hero-frame::after {
    inset: 0 0 auto;
    aspect-ratio: 16 / 10;
    height: auto;
    background: linear-gradient(180deg, transparent 55%, #0a447f 100%);
    z-index: 1;
  }

  .hero-content {
    justify-self: stretch;
    width: 100%;
    margin-top: -48px;
    padding: 0 var(--sp-4) var(--sp-6);
    position: relative;
    z-index: 2;
  }

  .hero-actions .btn {
    flex: 1 1 100%;
  }
}

/* =========================================================
   Content tiles, tags, stats, features
   ========================================================= */

.section-alt {
  background: var(--c-surface);
}

.tiles {
  --cols: 3;
  display: grid;
  grid-template-columns: repeat(var(--cols), minmax(0, 1fr));
  gap: var(--sp-6) var(--sp-5);
}

.tile {
  display: flex;
  flex-direction: column;
  color: var(--c-ink);
  text-decoration: none;
}

.tile-media {
  aspect-ratio: 4 / 3;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--c-surface-2);
  margin-bottom: var(--sp-4);
}

.tile-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 0;
  transition: transform 0.6s var(--ease);
}

.tile:hover .tile-media img {
  transform: scale(1.05);
}

.tile-title {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: var(--sp-3);
  font-size: var(--fs-xl);
  margin-bottom: var(--sp-2);
  transition: color 0.15s;
}

.tile .arrow {
  color: var(--c-primary);
  transition: transform 0.25s var(--ease);
}

.tile:hover {
  color: var(--c-ink);
}

.tile:hover .tile-title {
  color: var(--c-primary);
}

.tile:hover .arrow {
  transform: translateX(4px);
}

.tile-text {
  margin: 0;
  color: var(--c-ink-2);
  font-size: var(--fs-sm);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2);
  list-style: none;
  padding: 0;
  margin: var(--sp-6) 0 0;
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid var(--c-line-strong);
  border-radius: 999px;
  background: var(--c-surface);
  color: var(--c-ink);
  font-weight: 550;
  text-decoration: none;
  transition: border-color 0.15s, color 0.15s, background 0.15s, transform 0.15s var(--ease);
}

.tag:hover {
  border-color: var(--c-primary);
  color: var(--c-primary);
  background: var(--c-primary-soft);
  transform: translateY(-1px);
}

/* stats: editorial numbers, no boxes */

.stats {
  --cols: 4;
  display: grid;
  grid-template-columns: repeat(var(--cols), minmax(0, 1fr));
  margin: 0;
  border-top: 1px solid var(--c-line-strong);
}

.stat {
  padding: var(--sp-5) var(--sp-5) var(--sp-6) 0;
  border-bottom: 1px solid var(--c-line);
}

.stat + .stat {
  padding-left: var(--sp-5);
  border-left: 1px solid var(--c-line);
}

.stat:nth-child(4n + 1) {
  padding-left: 0;
  border-left: 0;
}

.stat dt {
  font: 700 clamp(2.25rem, 1.6rem + 2vw, 3.25rem) / 1 var(--font-display);
  color: var(--c-primary);
  letter-spacing: -0.01em;
  margin-bottom: var(--sp-3);
  font-variant-numeric: lining-nums tabular-nums;
}

.stat dd {
  margin: 0;
  max-width: 22ch;
  color: var(--c-ink-2);
  font-size: var(--fs-sm);
  line-height: 1.45;
}

/* features (advantages) */

.features {
  --cols: 4;
  display: grid;
  grid-template-columns: repeat(var(--cols), minmax(0, 1fr));
  gap: var(--sp-6) var(--sp-5);
}

.feature h3 {
  font-size: var(--fs-lg);
  line-height: 1.3;
  margin: 0 0 var(--sp-2);
}

.feature .prose {
  font-size: var(--fs-sm);
  color: var(--c-ink-2);
}

.feature-media {
  position: relative;
  aspect-ratio: 4 / 5;
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: var(--sp-4);
  background: var(--c-surface-2);
}

.feature-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 0;
  transition: transform 0.6s var(--ease);
}

.feature:hover .feature-media img {
  transform: scale(1.04);
}

.feature-num {
  position: absolute;
  left: 14px;
  top: 14px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgb(255 255 255 / 88%);
  backdrop-filter: blur(6px);
  color: var(--c-primary);
  font: 700 var(--fs-xs) / 1.4 var(--font-display);
}

details.more > summary {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: var(--sp-2);
  color: var(--c-primary);
  font-weight: 600;
  font-size: var(--fs-sm);
  cursor: pointer;
  list-style: none;
}

details.more > summary::-webkit-details-marker {
  display: none;
}

details.more > summary::after {
  content: "";
  width: 7px;
  height: 7px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg) translateY(-2px);
  transition: transform 0.2s var(--ease);
}

details.more[open] > summary::after {
  transform: rotate(-135deg) translateY(-1px);
}

details.more .prose {
  margin-top: var(--sp-3);
}

@media (max-width: 1080px) {
  .features, .tiles {
    --cols: 2 !important;
  }

  .stats {
    --cols: 2 !important;
  }

  .stat:nth-child(4n + 1) {
    padding-left: var(--sp-5);
    border-left: 1px solid var(--c-line);
  }

  .stat:nth-child(2n + 1) {
    padding-left: 0;
    border-left: 0;
  }
}

/* on phones advantages become a swipeable row instead of a long column */
@media (max-width: 640px) {
  .tiles {
    --cols: 2 !important;
    gap: var(--sp-5) var(--sp-3);
  }

  .tile-media {
    aspect-ratio: 1;
    margin-bottom: var(--sp-2);
  }

  .tile-title {
    font-size: var(--fs-md);
  }

  .tile-text,
  .tile .arrow {
    display: none;
  }

  .features {
    display: flex;
    gap: var(--sp-4);
    margin-inline: calc(-1 * var(--sp-4));
    padding: 0 var(--sp-4) var(--sp-2);
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
  }

  .features::-webkit-scrollbar {
    display: none;
  }

  .feature {
    flex: 0 0 78%;
    scroll-snap-align: start;
  }

  .stat {
    padding-right: var(--sp-3);
  }

  .stat + .stat,
  .stat:nth-child(4n + 1) {
    padding-left: var(--sp-3);
  }

  .stat:nth-child(2n + 1) {
    padding-left: 0;
  }
}

/* =========================================================
   Motion
   ========================================================= */

@keyframes rise {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: none; }
}

@keyframes hero-zoom {
  from { transform: scale(1.06); }
  to { transform: scale(1); }
}

/* Scroll reveal, driven by the observer in index.html; without JS nothing is hidden. */
.js-reveal [data-reveal]:not(.is-visible) {
  opacity: 0;
  transform: translateY(18px);
}

.js-reveal [data-reveal] {
  transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
  transition-delay: calc(var(--i, 0) * 60ms);
}

/* smooth open/close for native <details> where supported */
:root {
  interpolate-size: allow-keywords;
}

details::details-content {
  block-size: 0;
  overflow: clip;
  transition: block-size 0.3s var(--ease), content-visibility 0.3s allow-discrete;
}

details[open]::details-content {
  block-size: auto;
}

/* =========================================================
   Admin
   ========================================================= */

.admin {
  display: grid;
  grid-template-columns: 240px 1fr;
  min-height: 100vh;
}

.admin-side {
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  gap: var(--sp-5);
  padding: var(--sp-5) var(--sp-4);
  background: #0f1e33;
  color: rgb(255 255 255 / 80%);
}

.admin-brand {
  color: #fff;
  font: 700 var(--fs-md) / 1.2 var(--font-display);
  text-decoration: none;
  padding-inline: var(--sp-3);
}

.admin-side nav {
  display: grid;
  gap: 2px;
}

.admin-side nav a {
  padding: var(--sp-2) var(--sp-3);
  border-radius: var(--radius-sm);
  color: rgb(255 255 255 / 78%);
  text-decoration: none;
  font-size: var(--fs-sm);
  font-weight: 550;
}

.admin-side nav a:hover {
  background: rgb(255 255 255 / 8%);
  color: #fff;
}

.admin-side nav a[aria-current="page"] {
  background: var(--c-primary);
  color: #fff;
}

.admin-user {
  margin-top: auto;
  display: grid;
  gap: var(--sp-2);
  padding-inline: var(--sp-3);
  font-size: var(--fs-sm);
}

.admin-user a {
  color: rgb(255 255 255 / 80%);
}

.admin-user .btn-ghost {
  --btn-fg: rgb(255 255 255 / 80%);
  justify-self: start;
  padding-inline: 0;
}

.admin > * {
  min-width: 0;
}

.admin-main {
  padding: var(--sp-6) var(--sp-6) 120px;
}

.row-actions select.input {
  width: auto;
}

@media (max-width: 900px) {
  .admin {
    grid-template-columns: 1fr;
  }

  .admin-side {
    position: static;
    height: auto;
  }

  .admin-side nav {
    grid-auto-flow: column;
    overflow-x: auto;
  }

  .admin-main {
    padding: var(--sp-4) var(--sp-4) 120px;
  }
}

.admin-head {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-4);
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--sp-5);
}

.admin-head h1 {
  font-size: var(--fs-2xl);
  margin: 0;
}

.admin-sub {
  font-size: var(--fs-xl);
  margin: var(--sp-6) 0 var(--sp-4);
}

.admin-form {
  max-width: 980px;
}

.row-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2);
  align-items: center;
}

.checks {
  display: grid;
  gap: var(--sp-2);
  align-content: center;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--c-surface);
  border: 1px solid var(--c-line);
  border-radius: var(--radius);
  overflow: hidden;
  font-size: var(--fs-sm);
}

.admin-table th {
  text-align: left;
  font-weight: 600;
  color: var(--c-muted);
  background: var(--c-surface-2);
}

.admin-table th,
.admin-table td {
  padding: var(--sp-3) var(--sp-4);
  border-bottom: 1px solid var(--c-line);
  vertical-align: middle;
}

.admin-table tr:last-child td {
  border-bottom: 0;
}

.badge-muted {
  background: var(--c-surface-2);
  color: var(--c-muted);
}

.input-sm {
  min-height: 34px;
  padding: 4px var(--sp-3);
  font-size: var(--fs-sm);
}

.input.code {
  font: 13px / 1.5 ui-monospace, SFMono-Regular, Menlo, monospace;
}

.field-error {
  color: var(--c-danger);
  font-size: var(--fs-sm);
  margin: var(--sp-2) 0 0;
}

.ok {
  color: var(--c-success);
  font-weight: 600;
}

.btn.danger,
.btn-ghost.danger {
  --btn-fg: var(--c-danger);
}

label.btn input[hidden] {
  display: none;
}

.btn.disabled {
  opacity: 0.6;
  pointer-events: none;
}

.save-bar {
  position: fixed;
  z-index: 40;
  left: 240px;
  right: 0;
  bottom: 0;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: var(--sp-4);
  padding: var(--sp-3) var(--sp-6);
  background: color-mix(in srgb, var(--c-surface) 94%, transparent);
  backdrop-filter: blur(8px);
  border-top: 1px solid var(--c-line);
}

@media (max-width: 900px) {
  .save-bar {
    left: 0;
  }
}

.block-editor {
  margin-bottom: var(--sp-4);
  padding: var(--sp-4) var(--sp-5);
}

.block-editor-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--sp-3);
  margin-bottom: var(--sp-4);
  padding-bottom: var(--sp-3);
  border-bottom: 1px solid var(--c-line);
}

.col-editors {
  display: grid;
  gap: var(--sp-4);
  margin: var(--sp-4) 0 var(--sp-2);
}

.col-editor {
  display: grid;
  gap: var(--sp-2);
}

.add-blocks {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2);
  align-items: center;
  padding: var(--sp-4);
  border: 1px dashed var(--c-line-strong);
  border-radius: var(--radius);
}

/* rich text editor */

.rt {
  border: 1.5px solid var(--c-line-strong);
  border-radius: var(--radius-sm);
  background: var(--c-surface);
}

.rt:focus-within {
  border-color: var(--c-primary);
}

.rt-toolbar {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  flex-wrap: wrap;
  gap: 2px;
  padding: var(--sp-1);
  border-bottom: 1px solid var(--c-line);
  background: var(--c-surface-2);
  border-radius: var(--radius-sm) var(--radius-sm) 0 0;
}

.tb {
  min-width: 32px;
  height: 32px;
  padding: 0 var(--sp-2);
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--c-ink-2);
  font: 600 var(--fs-sm) / 1 var(--font-body);
  cursor: pointer;
}

.tb:hover {
  background: var(--c-surface);
  color: var(--c-primary);
}

.tb-sep {
  width: 1px;
  margin: 4px 2px;
  background: var(--c-line-strong);
}

.rt-area {
  min-height: 160px;
  padding: var(--sp-4) var(--sp-5);
  outline: none;
}

.rt.compact .rt-area {
  min-height: 80px;
}

.rt-block {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  margin: var(--sp-3) 0;
  padding: var(--sp-2) var(--sp-3);
  border: 1px dashed var(--c-primary);
  border-radius: var(--radius-sm);
  background: var(--c-primary-soft);
  color: var(--c-primary);
  font-size: var(--fs-sm);
  user-select: none;
}

.rt-block span {
  flex: 1;
  font-weight: 600;
}

.rt-block button {
  border: 0;
  background: var(--c-surface);
  color: var(--c-ink-2);
  border-radius: 6px;
  padding: 4px 10px;
  font: inherit;
  cursor: pointer;
}

.rt-block button[data-remove] {
  color: var(--c-danger);
}

/* modal */

.modal-back {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: var(--sp-4);
  background: rgb(15 30 51 / 45%);
}

.modal {
  width: min(640px, 100%);
  max-height: 90vh;
  overflow: auto;
  display: grid;
  gap: var(--sp-3);
}

.modal-wide {
  width: min(960px, 100%);
}

/* media */

.media-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: var(--sp-4);
}

.media-grid.picker {
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: var(--sp-2);
}

.media-item {
  padding: 0;
  overflow: hidden;
}

.media-item img,
.media-pick img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 0;
  background: var(--c-surface-2);
}

.media-meta {
  display: grid;
  gap: var(--sp-2);
  padding: var(--sp-3);
}

.media-pick {
  padding: 0;
  border: 2px solid transparent;
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: none;
  cursor: pointer;
}

.media-pick:hover {
  border-color: var(--c-primary);
}

.asset-field {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
}

.asset-field img {
  width: 96px;
  height: 64px;
  object-fit: cover;
  border-radius: var(--radius-sm);
}

.doc-row {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: var(--sp-4);
  align-items: start;
}

.doc-row .doc-item {
  border: 0;
  padding: 0;
  background: none;
}

/* login */

.admin-login {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: var(--sp-4);
}

.admin-login form {
  width: min(400px, 100%);
  display: grid;
  gap: var(--sp-4);
  padding: var(--sp-6);
}

.admin-login img {
  height: 36px;
  width: auto;
  justify-self: start;
}

.admin-login h1 {
  font-size: var(--fs-xl);
  margin: 0;
}

/* =========================================================
   Doctors
   ========================================================= */

.doc-list-rows {
  display: grid;
  border-top: 1px solid var(--c-line);
}

.doc-row {
  display: grid;
  grid-template-columns: 96px 1fr auto;
  gap: var(--sp-5);
  align-items: center;
  padding: var(--sp-5) 0;
  border-bottom: 1px solid var(--c-line);
}

.doc-row-photo img {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  object-fit: cover;
  object-position: 50% 20%;
  background: var(--c-surface-2);
  transition: transform 0.3s var(--ease);
}

.doc-row:hover .doc-row-photo img {
  transform: scale(1.04);
}

.doc-row h3 {
  font-size: var(--fs-xl);
  margin-bottom: var(--sp-1);
}

.doc-row h3 a {
  color: var(--c-ink);
  text-decoration: none;
}

.doc-row h3 a:hover {
  color: var(--c-primary);
}

.doc-row .meta {
  color: var(--c-ink-2);
  margin-bottom: var(--sp-2);
}

@media (max-width: 640px) {
  .doc-row {
    grid-template-columns: 72px 1fr;
    gap: var(--sp-4);
    align-items: start;
  }

  .doc-row-photo img {
    width: 72px;
    height: 72px;
  }

  .doc-row h3 {
    font-size: var(--fs-lg);
  }

  .doc-row-cta {
    grid-column: 1 / -1;
  }
}

.doc-tiles {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--sp-5);
}

.doc-tile {
  color: var(--c-ink);
  text-decoration: none;
}

.doc-tile:hover {
  color: var(--c-ink);
}

.doc-tile-photo {
  display: grid;
  place-items: center;
  aspect-ratio: 1;
  border-radius: var(--radius);
  margin-bottom: var(--sp-4);
  background:
    radial-gradient(circle at 50% 42%, #fff 0 38%, transparent 39%),
    linear-gradient(160deg, var(--c-primary-soft), #dbe8f6);
}

/* RNova photos come in mixed crops (some pre-cut circles on white); one circle unifies them. */
.doc-tile-photo img {
  width: 76%;
  aspect-ratio: 1;
  border-radius: 50%;
  object-fit: cover;
  object-position: 50% 18%;
  box-shadow: 0 10px 30px rgb(9 93 171 / 16%);
  transition: transform 0.5s var(--ease);
}

.doc-tile:hover .doc-tile-photo img {
  transform: scale(1.04);
}

.doc-tile h3 {
  font-size: var(--fs-lg);
  margin-bottom: var(--sp-1);
  transition: color 0.15s;
}

.doc-tile:hover h3 {
  color: var(--c-primary);
}

.doc-tile .meta {
  margin: 0;
  color: var(--c-ink-2);
  font-size: var(--fs-sm);
}

.doc-tile .exp {
  margin: var(--sp-1) 0 0;
  color: var(--c-muted);
  font-size: var(--fs-xs);
}

@media (max-width: 1080px) {
  .doc-tiles {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .doc-tiles {
    display: flex;
    margin-inline: calc(-1 * var(--sp-4));
    padding: 0 var(--sp-4) var(--sp-2);
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
  }

  .doc-tile {
    flex: 0 0 62%;
    scroll-snap-align: start;
  }
}

/* small layout fixes */

.prose ul.tags {
  padding-left: 0;
}

.tags li {
  margin: 0;
}

.block:not(:has(*)) {
  display: none;
}

.section-head .btn {
  flex-shrink: 0;
}

/* grid/flex children must be allowed to shrink, or scroll rows push the page wide */
.columns > *,
.stack > *,
.block {
  min-width: 0;
}

.btn {
  max-width: 100%;
}

@media (max-width: 640px) {
  .eyebrow {
    display: none;
  }

  .cta-band {
    padding: var(--sp-5);
  }

  .cta-band .hero-actions,
  .cta-band .btn {
    width: 100%;
  }

  .section {
    padding-block: var(--sp-6);
  }

  .section-head {
    flex-wrap: nowrap;
  }

  .section-head h2 {
    font-size: var(--fs-xl);
  }

  .page {
    padding-block: var(--sp-4) var(--sp-7);
  }

  .page-head p {
    font-size: var(--fs-md);
  }

  .block {
    margin-bottom: var(--sp-6);
  }
}

@media (max-width: 640px) {
  .tags {
    gap: 6px;
    margin-top: var(--sp-5);
  }

  .tag {
    min-height: 36px;
    padding: 0 14px;
    font-size: var(--fs-sm);
  }
}

.mobile-cta.hidden {
  visibility: hidden;
}

@media (max-width: 640px) {
  .steps {
    flex-wrap: nowrap;
    gap: 6px;
  }

  .steps li {
    flex: 1;
    justify-content: center;
    padding: 6px 8px 6px 6px;
    font-size: var(--fs-xs);
    white-space: nowrap;
  }

  .steps li::before {
    width: 22px;
    height: 22px;
  }
}

/* price list: same divider language as the FAQ, no boxes */
details.price-group.collapsible {
  background: none;
  border: 0;
  border-bottom: 1px solid var(--c-line);
  border-radius: 0;
  overflow: visible;
}

.stack > details.price-group + details.price-group {
  margin-top: 0;
}

details.price-group > summary {
  padding: var(--sp-5) 0;
}

details.price-group .price-table td {
  padding-inline: 0 var(--sp-4);
}

details.price-group .price-table td.price {
  padding-right: 0;
}

details.price-group .price-table tr:hover td {
  background: none;
  color: var(--c-primary);
}

.price-group:not(details) {
  background: var(--c-surface);
}

.price-list {
  border-top: 1px solid var(--c-line-strong);
}

@media (max-width: 640px) {
  .doc-row-cta {
    grid-column: 2;
    justify-self: start;
    min-height: 36px;
    padding: 0 var(--sp-4);
    font-size: var(--fs-xs);
  }

  /* specialty filters: one swipeable row instead of a wall of chips */
  .chips.filters {
    flex-wrap: nowrap;
    overflow-x: auto;
    margin-inline: calc(-1 * var(--sp-4));
    padding: 0 var(--sp-4) var(--sp-2);
    scrollbar-width: none;
  }

  .chips.filters::-webkit-scrollbar {
    display: none;
  }

  .chip {
    flex-shrink: 0;
  }
}

.bio {
  margin-top: var(--sp-6);
}

.bio h2 {
  font-size: var(--fs-xl);
}

.bio .prose ul {
  columns: 2 260px;
  column-gap: var(--sp-6);
}

.bio .prose li {
  break-inside: avoid;
}

.slots-jump {
  display: none;
}

@media (max-width: 900px) {
  .slots-jump {
    display: inline-flex;
    width: 100%;
  }
}

/* patient office (RNova widget) */

.office {
  min-height: 320px;
  padding: var(--sp-5);
}

.office-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-3);
  min-height: 260px;
  color: var(--c-muted);
}

.spinner {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 3px solid var(--c-primary-soft);
  border-top-color: var(--c-primary);
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.office-fallback {
  max-width: 560px;
  padding: var(--sp-5) 0;
}

.office-fallback h2 {
  font-size: var(--fs-xl);
}

.office-fallback p {
  color: var(--c-ink-2);
}

/* =========================================================
   Document pages (CMS): about, rules, legal, privacy
   ========================================================= */

.doc-head h1 {
  max-width: 18ch;
}

.doc-lead {
  max-width: 56ch !important;
  font-size: clamp(1.125rem, 1rem + 0.5vw, 1.375rem) !important;
  line-height: 1.5;
  color: var(--c-ink-2);
}

.doc-layout {
  display: grid;
  gap: var(--sp-7);
  counter-reset: chapter;
}

@media (min-width: 1100px) {
  .doc-layout:has(.toc) {
    grid-template-columns: minmax(0, 1fr) 260px;
  }
}

.doc-content {
  min-width: 0;
  max-width: 780px;
}

/* chapters: every section heading gets a number and a rule */
.doc-content .block-title,
.doc-content .prose > h2 {
  counter-increment: chapter;
  position: relative;
  margin: var(--sp-7) 0 var(--sp-4);
  padding-top: var(--sp-5);
  border-top: 1px solid var(--c-line-strong);
  font-size: var(--fs-2xl);
  scroll-margin-top: calc(var(--header-h) + var(--sp-5));
}

.doc-content .block-title::before,
.doc-content .prose > h2::before {
  content: counter(chapter, decimal-leading-zero);
  display: block;
  margin-bottom: var(--sp-2);
  color: var(--c-primary);
  font: 700 var(--fs-sm) / 1 var(--font-display);
  letter-spacing: 0.08em;
}

.doc-content > .block:first-child .prose > h2:first-child,
.doc-content > .block:first-child > .block-title {
  margin-top: 0;
}

.doc-content .prose {
  font-size: 1.0625rem;
  line-height: 1.7;
}

.doc-content .prose p,
.doc-content .prose li {
  color: var(--c-ink);
}

/* numbered lists read as steps */
.doc-content .prose ol {
  list-style: none;
  counter-reset: step;
  padding-left: 0;
  display: grid;
  gap: var(--sp-3);
  margin: var(--sp-5) 0;
}

.doc-content .prose ol > li {
  counter-increment: step;
  position: relative;
  padding: var(--sp-4) var(--sp-5) var(--sp-4) 64px;
  background: var(--c-surface);
  border: 1px solid var(--c-line);
  border-radius: var(--radius);
}

.doc-content .prose ol > li::before {
  content: counter(step);
  position: absolute;
  left: var(--sp-5);
  top: var(--sp-4);
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--c-primary);
  color: #fff;
  font: 700 var(--fs-sm) / 1 var(--font-display);
}

/* quote: one large editorial quotation */
.doc-content .prose blockquote,
.prose blockquote {
  position: relative;
  margin: var(--sp-5) 0;
  padding: var(--sp-6) var(--sp-6) var(--sp-5);
  border: 0;
  border-radius: var(--radius-lg);
  background: var(--c-primary-soft);
}

.prose blockquote::before {
  content: "“";
  position: absolute;
  top: -6px;
  left: var(--sp-5);
  color: var(--c-primary);
  font: 700 88px / 1 Georgia, serif;
  opacity: 0.25;
}

.prose blockquote p {
  position: relative;
  max-width: none;
  font: 500 var(--fs-lg) / 1.6 var(--font-display);
  color: var(--c-ink);
}

.prose blockquote p:last-child {
  margin-bottom: 0;
}

/* attribution right after a quote: name, then role */
.prose blockquote + p {
  margin: var(--sp-5) 0 var(--sp-1);
  font: 700 var(--fs-lg) / 1.3 var(--font-display);
}

.prose blockquote + p + p {
  color: var(--c-ink-2) !important;
  font-size: var(--fs-sm);
}

/* image-only column: portrait card */
.col-media figure {
  margin: 0;
}

.col-media img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: 50% 15%;
  border-radius: var(--radius-lg);
  background: linear-gradient(160deg, var(--c-primary-soft), #dbe8f6);
}

@media (min-width: 900px) {
  .columns:has(.col-media) {
    align-items: start;
  }

  .col-media {
    position: sticky;
    top: calc(var(--header-h) + var(--sp-5));
  }
}

@media (max-width: 899px) {
  .columns:has(.col-media) .col-media {
    order: -1;
    max-width: 280px;
  }
}

/* table of contents */

.toc {
  display: none;
}

@media (min-width: 1100px) {
  .toc {
    display: block;
    position: sticky;
    top: calc(var(--header-h) + var(--sp-5));
    align-self: start;
    padding-left: var(--sp-5);
    border-left: 1px solid var(--c-line);
  }
}

.toc-title {
  margin-bottom: var(--sp-3);
  color: var(--c-muted);
  font-size: var(--fs-xs);
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.toc ol {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 2px;
}

.toc a {
  position: relative;
  display: block;
  padding: 6px 0;
  color: var(--c-ink-2);
  font-size: var(--fs-sm);
  line-height: 1.4;
  text-decoration: none;
  transition: color 0.15s;
}

.toc a::before {
  content: "";
  position: absolute;
  left: calc(-1 * var(--sp-5) - 1px);
  top: 6px;
  bottom: 6px;
  width: 2px;
  border-radius: 2px;
  background: var(--c-primary);
  transform: scaleY(0);
  transition: transform 0.2s var(--ease);
}

.toc a:hover,
.toc a[aria-current="true"] {
  color: var(--c-primary);
}

.toc a[aria-current="true"]::before {
  transform: scaleY(1);
}

/* about intro: facts + photo mosaic */

.about-intro {
  margin-bottom: var(--sp-7);
}

.about-facts {
  margin-bottom: var(--sp-6);
}

.about-facts .stat dt {
  font-size: clamp(1.75rem, 1.3rem + 1.4vw, 2.5rem);
}

.mosaic {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 1fr);
  grid-template-rows: repeat(2, minmax(0, 1fr));
  gap: var(--sp-3);
  height: clamp(320px, 38vw, 520px);
}

.mosaic img {
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: cover;
  border-radius: var(--radius-lg);
}

.mosaic .m-main {
  grid-row: 1 / 3;
  object-position: 25% 40%;
}

@media (max-width: 640px) {
  .mosaic {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: 220px 140px;
    height: auto;
  }

  .mosaic .m-main {
    grid-column: 1 / 3;
    grid-row: 1;
  }

  .doc-content .prose ol > li {
    padding: var(--sp-4) var(--sp-4) var(--sp-4) 56px;
  }

  .doc-content .prose ol > li::before {
    left: var(--sp-4);
  }

  .prose blockquote {
    padding: var(--sp-5) var(--sp-4) var(--sp-4);
  }

  .prose blockquote p {
    font-size: var(--fs-md);
  }
}

/* compact professions list under the tiles */
.tags-group {
  margin-top: var(--sp-7);
  padding-top: var(--sp-5);
  border-top: 1px solid var(--c-line);
}

.prose .tags-label,
.tags-label {
  margin: 0 0 var(--sp-3);
  color: var(--c-muted);
  font-size: var(--fs-xs);
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.prose ul.tags,
.tags-group .tags {
  margin: 0;
}

@media (max-width: 640px) {
  .tags-group {
    margin-top: var(--sp-6);
  }
}

/* rhythm between CMS sections */
.block {
  margin-bottom: clamp(var(--sp-6), 5vw, var(--sp-8));
}

.doc-content .block-title,
.doc-content .prose > h2 {
  font-size: clamp(1.25rem, 1.05rem + 0.7vw, 1.625rem);
  max-width: 40ch;
}

@media (min-width: 1100px) {
  .toc {
    max-height: calc(100vh - var(--header-h) - var(--sp-7));
    overflow-y: auto;
    scrollbar-width: thin;
  }
}

.toc a {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.toc a::before {
  display: none;
}

.toc li {
  position: relative;
}

.toc li::before {
  content: "";
  position: absolute;
  left: calc(-1 * var(--sp-5) - 1px);
  top: 6px;
  bottom: 6px;
  width: 2px;
  border-radius: 2px;
  background: var(--c-primary);
  transform: scaleY(0);
  transition: transform 0.2s var(--ease);
}

.toc li:has(a[aria-current="true"])::before {
  transform: scaleY(1);
}

/* the toc scrolls itself, so keep the indicator inside its padding box */
@media (min-width: 1100px) {
  .toc {
    padding-left: var(--sp-5);
  }

  .toc li::before {
    left: calc(-1 * var(--sp-5) + 1px);
  }
}

/* long or nested numbered lists: compact, no cards */
.doc-content .prose ol:has(> li:nth-child(7)),
.doc-content .prose li ol {
  gap: var(--sp-2);
}

.doc-content .prose ol:has(> li:nth-child(7)) > li,
.doc-content .prose li ol > li {
  padding: 0 0 0 40px;
  background: none;
  border: 0;
  border-radius: 0;
}

.doc-content .prose ol:has(> li:nth-child(7)) > li::before,
.doc-content .prose li ol > li::before {
  left: 0;
  top: 2px;
  width: 24px;
  height: 24px;
  background: var(--c-primary-soft);
  color: var(--c-primary);
  font-size: var(--fs-xs);
}

.doc-content .prose li ol {
  margin: var(--sp-3) 0 var(--sp-1);
}

.doc-content .block-title,
.doc-content .prose > h2 {
  max-width: none;
}
