/* Marketing site styles. Loaded by layouts/marketing.html.erb — but
   stylesheet_link_tag :app in the app layouts also bundles every file in this folder, so this
   file must never style bare elements globally: all classes are prefixed with mh- and element
   rules are scoped to :where(.mh-body) (zero added specificity, so mh- classes still win).

   Editorial clinical look (after knowtex.ai): a cool off-white page, white rounded panels,
   serif display headings (Hedvig Letters Serif) over a clean grotesk (Instrument Sans), pill
   buttons and dark inverted bands for emphasis. Every colour comes from the logo: navy ink
   ("Med"), the blue → cyan of "History" as brand + tint. A quiet teal is reserved for
   "verified / source" cues. */

:root {
  --mh-ink:           #0f1b2d;
  --mh-muted:         #475569;
  --mh-faint:         #64748b;
  --mh-bg:            #f4f7fb;
  --mh-bg-alt:        #e8eff8;
  --mh-surface:       #ffffff;
  --mh-border:        #e1e8f2;
  --mh-border-strong: #cbd6e5;

  --mh-accent:        #1a6fe0;
  --mh-accent-dark:   #0f55b8;
  --mh-accent-soft:   #e7eefd;
  --mh-brand:         #0a6cf5;
  --mh-brand-soft:    #e6f0fe;
  --mh-cyan:          #08aef0;
  --mh-brand-gradient: linear-gradient(90deg, #0a6cf5 0%, #08aef0 100%);
  --mh-teal:          #0f7b6c;
  --mh-teal-soft:     #e3f4f0;
  --mh-alert:         #c2410c;

  --mh-inverted:      #0b1628;
  --mh-on-inverted:   #f4f7fb;
  --mh-on-inverted-muted: rgba(244, 247, 251, .66);

  --mh-radius:        12px;
  --mh-radius-lg:     20px;
  --mh-radius-xl:     28px;
  --mh-shadow:        0 1px 2px rgba(15, 27, 45, .04), 0 6px 18px -6px rgba(15, 27, 45, .08);
  --mh-shadow-lg:     0 1px 2px rgba(15, 27, 45, .05), 0 32px 64px -24px rgba(15, 27, 45, .22);

  --mh-font:  "Instrument Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --mh-serif: "Hedvig Letters Serif", Georgia, "Times New Roman", serif;
}

:where(.mh-body) *, :where(.mh-body) *::before, :where(.mh-body) *::after { box-sizing: border-box; margin: 0; padding: 0; }

html:has(.mh-body) { scroll-behavior: smooth; }

.mh-body {
  font-family: var(--mh-font);
  font-size: 16px;
  line-height: 1.6;
  color: var(--mh-ink);
  background: var(--mh-bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.mh-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
}

.mh-container--narrow { max-width: 760px; }

:where(.mh-body) :is(h1, h2) {
  font-family: var(--mh-serif);
  font-weight: 400;
  color: var(--mh-ink);
  line-height: 1.12;
  letter-spacing: -.015em;
  text-wrap: balance;
}

:where(.mh-body) h3 {
  color: var(--mh-ink);
  font-size: 18px;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -.005em;
}

:where(.mh-body) h2 { font-size: clamp(30px, 3.8vw, 46px); margin-bottom: 18px; }

:where(.mh-body) p { margin-bottom: 12px; }

:where(.mh-body) a { color: var(--mh-accent-dark); text-decoration: none; }

.mh-link {
  color: var(--mh-accent-dark);
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
}

.mh-accent { color: var(--mh-brand); }

/* Headline accent: the logo's blue → cyan, where the browser can clip a gradient to text */
@supports (-webkit-background-clip: text) or (background-clip: text) {
  .mh-accent {
    background: var(--mh-brand-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    padding-bottom: .08em;
  }
}

.mh-emphasis {
  font-weight: 600;
  color: var(--mh-ink);
  font-size: 18px;
}

/* Small pill tag above section headings */
.mh-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .01em;
  color: var(--mh-accent-dark);
  background: var(--mh-brand-soft);
  border-radius: 999px;
  padding: 5px 12px;
  margin-bottom: 20px;
}

/* ── Buttons: pills ──────────────────────────────────────── */
.mh-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-family: inherit;
  font-weight: 600;
  font-size: 15px;
  line-height: 1.4;
  transition: background .2s, border-color .2s, color .2s;
  cursor: pointer;
  white-space: nowrap;
}

.mh-btn:focus-visible { outline: 2px solid var(--mh-accent); outline-offset: 2px; }

.mh-btn--lg { padding: 14px 28px; font-size: 16px; }
.mh-btn--sm { padding: 7px 14px; font-size: 13px; }

.mh-btn--primary { background: var(--mh-ink); color: #fff; }
:where(.mh-body) .mh-btn--primary { color: #fff; }
.mh-btn--primary:hover { background: #1d3150; }

.mh-btn--secondary {
  background: var(--mh-surface);
  color: var(--mh-ink);
  border-color: var(--mh-border-strong);
}

:where(.mh-body) .mh-btn--secondary, :where(.mh-body) .mh-btn--ghost, :where(.mh-body) .mh-btn--light { color: var(--mh-ink); }

.mh-btn--secondary:hover { border-color: var(--mh-ink); }

.mh-btn--ghost:hover { background: rgba(15, 27, 45, .06); }

.mh-btn--light { background: var(--mh-bg); }
.mh-btn--light:hover { background: #fff; }

.mh-btn--block { width: 100%; justify-content: center; }

/* ── Header ──────────────────────────────────────────────── */
.mh-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(244, 247, 251, .75);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
}

.mh-header__inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
  height: 76px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 32px;
}

.mh-header__logo { justify-self: start; }

.mh-header__logo img { height: 52px; display: block; }

.mh-header__nav {
  display: flex;
  gap: 28px;
  justify-self: center;
}

:where(.mh-body) .mh-header__nav a {
  color: var(--mh-muted);
  font-weight: 500;
  font-size: 15px;
  transition: color .15s;
}

:where(.mh-body) .mh-header__nav a:hover { color: var(--mh-ink); }

.mh-header__actions {
  display: flex;
  align-items: center;
  gap: 8px;
  justify-self: end;
}

/* SR / EN switcher — two-segment pill */
.mh-lang {
  display: inline-flex;
  padding: 3px;
  border: 1px solid var(--mh-border-strong);
  border-radius: 999px;
  margin-right: 4px;
}

:where(.mh-body) .mh-lang a {
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .04em;
  color: var(--mh-faint);
}

:where(.mh-body) .mh-lang a[aria-current] { background: var(--mh-ink); color: #fff; }

:where(.mh-body) .mh-lang a:not([aria-current]):hover { color: var(--mh-ink); }

/* ── Hero: serif headline left, copy + CTAs right, metrics, then the app ── */
.mh-hero { padding: 72px 0 0; overflow: hidden; }

.mh-hero__intro {
  display: grid;
  grid-template-columns: 1.25fr 1fr;
  gap: 64px;
  align-items: end;
}

.mh-hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 500;
  color: var(--mh-muted);
  background: var(--mh-surface);
  border: 1px solid var(--mh-border);
  border-radius: 999px;
  padding: 5px 14px 5px 10px;
  margin-bottom: 28px;
}

.mh-hero__badge::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--mh-teal);
  box-shadow: 0 0 0 3px var(--mh-teal-soft);
}

:where(.mh-body) .mh-hero__headline {
  font-size: clamp(42px, 6.2vw, 76px);
  line-height: 1.04;
  letter-spacing: -.025em;
}

.mh-hero__sub {
  font-size: 18px;
  color: var(--mh-muted);
  margin-bottom: 14px;
}

.mh-hero__promise {
  font-size: 18px;
  font-weight: 500;
  color: var(--mh-ink);
}

.mh-hero__ctas {
  display: flex;
  gap: 10px;
  margin: 28px 0 0;
  flex-wrap: wrap;
}

/* Metrics row — big serif numbers, like a spec sheet */
.mh-metrics {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  margin: 64px 0 56px;
  border-top: 1px solid var(--mh-border-strong);
}

.mh-metric { padding: 22px 24px 0 0; }

.mh-metric + .mh-metric { padding-left: 24px; border-left: 1px solid var(--mh-border-strong); }

.mh-metric strong {
  display: block;
  font-family: var(--mh-serif);
  font-weight: 400;
  font-size: clamp(30px, 3.4vw, 44px);
  line-height: 1.1;
  letter-spacing: -.02em;
  color: var(--mh-ink);
}

.mh-metric span { display: block; margin-top: 6px; font-size: 14px; color: var(--mh-muted); }

/* The app preview sits on a stage tinted with the logo's blue and cyan */
.mh-hero__app {
  padding-top: 0;
  padding-bottom: 0;
}

.mh-stage {
  padding: 40px 40px 0;
  border-radius: var(--mh-radius-xl) var(--mh-radius-xl) 0 0;
  background:
    radial-gradient(120% 90% at 15% 0%, #cfe1fd 0%, transparent 55%),
    radial-gradient(90% 80% at 100% 10%, #c9eefc 0%, transparent 60%),
    var(--mh-bg-alt);
}

.mh-stage .mh-app { border-bottom-left-radius: 0; border-bottom-right-radius: 0; border-bottom: 0; }

/* ── Sections ────────────────────────────────────────────── */
.mh-section { padding: 120px 0; }

/* Alternate sections are white panels inset from the page edge */
.mh-section--alt {
  background: var(--mh-surface);
  border-radius: var(--mh-radius-xl);
  margin: 0 16px;
}

.mh-section__head {
  max-width: 820px;
  margin: 0 0 64px;
}

.mh-section__lead {
  color: var(--mh-muted);
  font-size: 18px;
  max-width: 680px;
  margin-bottom: 0;
}

.mh-section__note {
  margin-top: 40px;
  font-weight: 500;
  color: var(--mh-muted);
  font-size: 16px;
  text-align: center;
}

/* ── How it works: big serif step numbers ────────────────── */
.mh-steps {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.mh-step {
  position: relative;
  padding: 28px;
  border-radius: var(--mh-radius-lg);
  background: var(--mh-surface);
}

/* Cards are white on the lavender page, lavender inside the white --alt panels */
.mh-section--alt :is(.mh-step, .mh-feature, .mh-clinic-list li) { background: var(--mh-bg); }

.mh-step__number {
  font-family: var(--mh-serif);
  font-size: 44px;
  line-height: 1;
  color: var(--mh-brand);
  margin-bottom: 28px;
}

.mh-step h3 { margin-bottom: 10px; }

.mh-step p { font-size: 15px; color: var(--mh-muted); }

.mh-step__note {
  display: flex;
  gap: 8px;
  margin-top: 14px;
  font-size: 14px;
  color: var(--mh-ink);
}

.mh-step__note::before {
  content: "";
  flex-shrink: 0;
  width: 3px;
  border-radius: 2px;
  background: var(--mh-brand);
}

/* ── Split layout (text + visual) ────────────────────────── */
.mh-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}

.mh-split__text p { color: var(--mh-muted); font-size: 17px; }

.mh-split__text p.mh-emphasis { color: var(--mh-ink); margin-top: 20px; }

/* ── Assistant section: example questions ───────────────── */
.mh-question-list { list-style: none; margin-top: 24px; }

.mh-question-list li {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--mh-border);
  font-size: 15px;
  color: var(--mh-ink);
}

.mh-question-list li:last-child { border-bottom: 0; }

.mh-question-list li::before {
  content: "?";
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-family: var(--mh-serif);
  font-size: 14px;
  color: var(--mh-brand);
  background: var(--mh-brand-soft);
}

/* ── Product mocks: the real doctor portal, in miniature ────
   Everything under .mh-app copies the portal's own design (application.css / clinic_portal.css
   — same tokens, system font, component shapes) so the homepage shows the app as it actually
   looks. Class names mirror the portal's (mh-ap-<portal class>) to make keeping them in sync easy;
   when the patient workspace's design changes, update this block too. Partials: home/mocks/. */
.mh-app {
  --a-blue-mid:     #0055cc;
  --a-blue-accent:  #1a7fe0;
  --a-blue-light:   #e6f0ff;
  --a-blue-grad:    linear-gradient(135deg, #1a7fe0 0%, #003899 100%);
  --a-green:        #1a7a4a;
  --a-green-light:  #e8f5ee;
  --a-red:          #c0392b;
  --a-purple:       #6d4aad;
  --a-amber:        #f0b429;
  --a-amber-light:  #fff3d6;
  --a-amber-text:   #4d3800;
  --a-yellow-light: #fffbea;
  --a-g50:          #f5f7fb;
  --a-g100:         #edf0f7;
  --a-g200:         #d8dce8;
  --a-g500:         #8a92a3;
  --a-g700:         #4a5468;
  --a-g900:         #1a1f2e;
  --a-shadow-sm:    0 1px 3px rgba(0, 0, 0, .08);
  --a-shadow-md:    0 4px 16px rgba(0, 56, 153, .12);

  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 14px;
  line-height: 1.5;
  color: var(--a-g900);
  text-align: left;
  background: #fff;
  border: 1px solid var(--a-g200);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--mh-shadow-lg);
}

.mh-app svg { display: block; flex-shrink: 0; }

/* Browser-window chrome, so it reads as a screenshot of the app */
.mh-app__chrome {
  display: flex;
  align-items: center;
  gap: 14px;
  height: 36px;
  padding: 0 14px;
  background: var(--a-g100);
  border-bottom: 1px solid var(--a-g200);
}

.mh-app__dots { display: flex; gap: 6px; }

.mh-app__dots span { width: 10px; height: 10px; border-radius: 50%; background: var(--a-g200); }

.mh-app__url {
  flex: 1;
  max-width: 340px;
  margin: 0 auto;
  padding: 3px 12px;
  border-radius: 6px;
  background: #fff;
  color: var(--a-g500);
  font-size: 12px;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ── Workspace: left panel | center tabs | right side panel (patients/show) */
.mh-ws {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr) 310px;
  height: 560px;
  background: var(--a-g50);
}

.mh-ws__left {
  background: #fff;
  border-right: 1px solid var(--a-g200);
  padding: 14px 0 20px;
  overflow: hidden;
}

.mh-ws__main { padding: 10px 14px 0; overflow: hidden; display: flex; flex-direction: column; }

.mh-ws__side {
  background: #fff;
  border-left: 1px solid var(--a-g200);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* Left panel */
.mh-ap-back {
  display: flex;
  align-items: center;
  gap: 4px;
  margin: 0 18px 14px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--a-g700);
}

.mh-ap-patient { padding: 0 18px; margin: 18px 0 20px; }

.mh-ap-patient__name {
  font-size: 17px;
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -.2px;
  color: var(--a-blue-mid);
}

.mh-ap-patient__meta { font-size: 12px; color: var(--a-g700); }

.mh-ap-pill {
  display: inline-block;
  margin-top: 6px;
  padding: 1px 8px;
  border-radius: 999px;
  background: var(--a-amber-light);
  color: var(--a-amber-text);
  font-size: 11.5px;
  font-weight: 600;
}

.mh-ap-section { padding: 0 18px; margin-bottom: 18px; }

.mh-ap-section__heading {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 8px;
  color: var(--a-g500);
}

.mh-ap-section__title {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .4px;
}

/* Sažetak — plain "Label: value" lines (patients/_summary) */
.mh-ap-summary { margin: 0; }

.mh-ap-summary div { font-size: 12.5px; line-height: 1.4; padding: 1px 0; }

.mh-ap-summary dt, .mh-ap-summary dd { display: inline; margin: 0; }

.mh-ap-summary dt { font-weight: 600; color: var(--a-g900); }

.mh-ap-summary dt::after { content: ": "; }

.mh-ap-summary dd { color: var(--a-g700); }

/* Istorija timeline (patients/_timeline) — oldest on top, one blue dot per document */
.mh-ap-tl { position: relative; margin-left: 48px; padding: 4px 0; }

.mh-ap-tl::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--a-g200);
}

.mh-ap-tl__tick {
  position: relative;
  height: 20px;
}

.mh-ap-tl__tick span {
  position: absolute;
  right: calc(100% + 14px);
  top: 50%;
  transform: translateY(-50%);
  font-size: 11px;
  color: var(--a-g500);
}

.mh-ap-tl__tick::after {
  content: "";
  position: absolute;
  left: -10px;
  top: 50%;
  width: 8px;
  height: 1px;
  background: var(--a-g200);
}

.mh-ap-tl__item, .mh-ap-tl__group { position: relative; margin: 6px 0 6px 18px; }

.mh-ap-tl__item::before, .mh-ap-tl__group::before {
  content: "";
  position: absolute;
  left: -22px;
  top: 50%;
  width: 10px;
  height: 10px;
  margin-top: -5px;
  border-radius: 50%;
  background: var(--a-blue-accent);
  border: 2px solid #fff;
  box-shadow: 0 0 0 1px var(--a-blue-accent);
}

.mh-ap-tl__label {
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 4px 8px;
  border-radius: 4px;
  background: var(--a-g50);
}

.mh-ap-tl__title, .mh-ap-tl__sub {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.mh-ap-tl__title { font-size: 13px; line-height: 18px; font-weight: 600; color: var(--a-g900); }

.mh-ap-tl__sub { font-size: 11px; line-height: 14px; font-style: italic; color: var(--a-g500); }

/* The document currently open in the center tabs */
.mh-ap-tl__item.is-open .mh-ap-tl__label { background: var(--a-blue-accent); }

.mh-ap-tl__item.is-open .mh-ap-tl__title,
.mh-ap-tl__item.is-open .mh-ap-tl__sub { color: #fff; }

.mh-ap-tl__item.is-open::before { background: var(--a-blue-mid); box-shadow: 0 0 0 1px var(--a-blue-mid), 0 0 0 4px var(--a-blue-light); }

/* Documents close together in time collapse into one box */
.mh-ap-tl__group {
  border: 1px solid var(--a-g200);
  border-radius: 4px;
  background: var(--a-g50);
  box-shadow: var(--a-shadow-sm);
}

.mh-ap-tl__group .mh-ap-tl__label { background: none; border-bottom: 1px solid var(--a-g100); border-radius: 0; }

.mh-ap-tl__group .mh-ap-tl__label:last-child { border-bottom: 0; }

/* In-app nalaz: small pencil before the title */
.mh-ap-draft {
  display: inline-grid;
  place-items: center;
  width: 16px;
  height: 16px;
  margin-right: 4px;
  vertical-align: -3px;
  border-radius: 4px;
  background: var(--a-yellow-light);
  color: #856404;
}

/* Center: VS Code-style tabs over a white sheet */
.mh-ap-tabs { display: flex; align-items: flex-end; gap: 2px; }

.mh-ap-tab {
  display: flex;
  align-items: center;
  gap: 7px;
  height: 40px;
  padding: 0 8px 0 14px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--a-g700);
  white-space: nowrap;
}

.mh-ap-tab--active {
  background: #fff;
  border: 1px solid var(--a-g200);
  border-bottom: 0;
  border-radius: 6px 6px 0 0;
  height: 41px;
  margin-bottom: -1px;
  position: relative;
}

.mh-ap-tab--new { padding: 0 12px; }

.mh-ap-tab__close { display: grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; }

.mh-ap-panel {
  flex: 1;
  background: #fff;
  border: 1px solid var(--a-g200);
  border-radius: 0 6px 0 0;
  border-bottom: 0;
  box-shadow: var(--a-shadow-sm);
  padding: 22px 26px;
  overflow: hidden;
}

.mh-ap-panel--rounded { border-radius: 6px; border-bottom: 1px solid var(--a-g200); }

.mh-ap-doc__header { padding-bottom: 14px; margin-bottom: 14px; border-bottom: 1px solid var(--a-g100); }

.mh-ap-doc__title { font-size: 19px; font-weight: 700; color: var(--a-blue-mid); line-height: 1.3; }

.mh-ap-doc__subtitle { margin-top: 4px; font-size: 13.5px; font-style: italic; color: var(--a-g500); }

.mh-ap-doc__date { margin-top: 2px; font-size: 13px; color: var(--a-g500); }

.mh-ap-doctabs { display: flex; gap: 4px; border-bottom: 2px solid var(--a-g200); margin-bottom: 8px; }

.mh-ap-doctabs span {
  padding: 7px 16px;
  margin-bottom: -2px;
  font-size: 13px;
  font-weight: 600;
  color: var(--a-g500);
  border-bottom: 2px solid transparent;
}

.mh-ap-doctabs .is-active { color: var(--a-blue-accent); border-bottom-color: var(--a-blue-accent); }

/* Prepis: one row per finding */
.mh-ap-findings { list-style: none; margin: 0; padding: 0; }

.mh-ap-finding { padding: 9px 6px; border-bottom: 1px solid var(--a-g100); }

.mh-ap-finding__category {
  display: block;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .4px;
  color: var(--a-blue-accent);
}

.mh-ap-finding__text { font-size: 13.5px; line-height: 1.55; color: var(--a-g700); }

/* Where a citation lands: the portal flashes the cited row yellow */
.mh-ap-flash { background: var(--a-yellow-light); border-radius: 4px; }

/* Laboratorija table */
.mh-ap-lab { width: 100%; border-collapse: collapse; font-size: 13px; border-radius: 6px; overflow: hidden; }

.mh-ap-lab th {
  background: var(--a-blue-grad);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .6px;
  text-align: left;
  padding: 10px 14px;
}

.mh-ap-lab td { padding: 10px 14px; border-bottom: 1px solid var(--a-g100); color: var(--a-g700); }

.mh-ap-lab td:first-child { font-weight: 600; color: var(--a-g900); }

.mh-ap-lab strong { color: var(--a-g900); }

.mh-ap-lab small { font-size: 12px; color: var(--a-g500); }

.mh-ap-lab tr.is-high td { background: #fff8f0; }

.mh-ap-lab tr.is-low td { background: #f0f4ff; }

.mh-ap-lab tr.mh-ap-flash td { background: var(--a-yellow-light); }

.mh-ap-flag {
  display: inline-block;
  padding: 1px 7px;
  border-radius: 10px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
}

.mh-ap-flag--high { background: #fff0e0; color: #c05000; }

.mh-ap-flag--low { background: #e8edff; color: #2244aa; }

/* Right side panel: Asistent / DDg / Validacija */
.mh-ap-sidetabs {
  display: flex;
  min-height: 49px;
  padding: 0 8px;
  border-bottom: 1px solid var(--a-g100);
}

.mh-ap-sidetab {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 14px 10px 11px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--a-g700);
  border-bottom: 2px solid transparent;
  white-space: nowrap;
}

.mh-ap-sidetab--assistant { color: var(--a-blue-mid); border-bottom-color: var(--a-blue-accent); }

.mh-ap-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  height: 54px;
  padding: 0 14px;
  border-bottom: 1px solid var(--a-g100);
}

.mh-ap-barbtn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border: 1px solid var(--a-g200);
  border-radius: 8px;
  background: #fff;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--a-g900);
  white-space: nowrap;
}

.mh-ap-barbtn--new { color: var(--a-blue-mid); font-weight: 700; }

.mh-ap-chat { flex: 1; display: flex; flex-direction: column; gap: 12px; padding: 16px; overflow: hidden; }

.mh-ap-bubble {
  max-width: 88%;
  padding: 9px 13px;
  border-radius: 14px;
  font-size: 13.5px;
  line-height: 1.55;
}

.mh-ap-bubble p { margin: 0 0 8px; font-size: inherit; color: inherit; }

.mh-ap-bubble p:last-child { margin-bottom: 0; }

.mh-ap-bubble--user {
  align-self: flex-end;
  background: var(--a-blue-accent);
  color: #fff;
  border-bottom-right-radius: 4px;
}

.mh-ap-bubble--agent {
  align-self: flex-start;
  background: var(--a-g100);
  color: var(--a-g900);
  border-bottom-left-radius: 4px;
}

.mh-ap-bubble--agent strong { font-weight: 600; }

/* The "AI-generated" label at the top of every answer (portal: .ai-disclaimer) */
.mh-ap-ai {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  margin-bottom: 10px;
  padding: 8px 10px;
  background: var(--a-amber-light);
  border: 1px solid var(--a-amber);
  border-radius: 8px;
  color: var(--a-amber-text);
}

.mh-ap-ai__badge {
  padding: 1px 8px;
  border-radius: 999px;
  background: var(--a-amber);
  font-size: 11px;
  font-weight: 700;
}

.mh-ap-ai__text { font-size: 12px; line-height: 1.45; }

/* [N] citation marker and its popover of source documents */
.mh-ap-cite { position: relative; display: inline-block; }

.mh-ap-cite__button {
  font-size: 11px;
  font-weight: 700;
  color: var(--a-blue-mid);
  vertical-align: text-top;
}

.mh-ap-cite__popover {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-top: 6px;
  padding: 6px;
  background: #fff;
  border: 1px solid var(--a-g200);
  border-radius: 6px;
  box-shadow: var(--a-shadow-md);
}

.mh-ap-cite__link {
  padding: 6px 10px;
  border: 1px solid var(--a-g200);
  border-radius: 6px;
  background: var(--a-g50);
  font-size: 12px;
  color: var(--a-g700);
}

.mh-ap-cite__link.is-hover { background: var(--a-blue-light); color: var(--a-blue-mid); border-color: var(--a-blue-light); }

.mh-ap-suggestions { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; }

.mh-ap-suggestion {
  padding: 7px 12px;
  border: 1px solid var(--a-g200);
  border-radius: 10px;
  background: #fff;
  font-size: 13px;
  color: var(--a-g900);
}

.mh-ap-input {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  padding: 12px 14px;
  border-top: 1px solid var(--a-g100);
}

.mh-ap-input__field {
  flex: 1;
  padding: 8px 12px;
  border: 1px solid var(--a-g200);
  border-radius: 6px;
  font-size: 13.5px;
  color: var(--a-g500);
}

.mh-ap-button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: 6px;
  background: var(--a-blue-accent);
  color: #fff;
  font-size: 13.5px;
  font-weight: 600;
  box-shadow: var(--a-shadow-sm);
  white-space: nowrap;
}

.mh-ap-button--lg { padding: 11px 22px; border-radius: 8px; }

.mh-ap-linkbutton { font-size: 13.5px; font-weight: 600; color: var(--a-g700); }

/* Sažetak as a standalone card (the non-compact patient-summary) */
.mh-app--bare { background: none; border: 0; box-shadow: none; overflow: visible; border-radius: 0; }

.mh-ap-summary-card {
  max-width: 680px;
  margin: 0 auto;
  background: #fff;
  border: 1px solid var(--a-g200);
  border-radius: 10px;
  box-shadow: var(--mh-shadow-lg);
  padding: 18px 24px 20px;
}

.mh-ap-summary-card__head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  padding-bottom: 10px;
  margin-bottom: 10px;
  border-bottom: 1px solid var(--a-g100);
}

.mh-ap-summary-card__title {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .6px;
  color: var(--a-g700);
}

.mh-ap-summary-card__source { font-size: 12px; color: var(--a-g700); }

.mh-ap-summary-card .mh-ap-summary div { font-size: 14.5px; line-height: 1.5; padding: 4px 0; }

/* Upload: dropzone, file list, per-document progress (patient_uploads) */
.mh-ap-upload { display: grid; grid-template-columns: 1fr 1fr; }

.mh-ap-upload__col { padding: 22px 24px; }

.mh-ap-upload__col + .mh-ap-upload__col { border-left: 1px solid var(--a-g100); background: var(--a-g50); }

.mh-ap-paper-title { font-size: 17px; font-weight: 700; color: var(--a-blue-mid); margin-bottom: 2px; }

.mh-ap-paper-meta { font-size: 13px; color: var(--a-g700); margin-bottom: 16px; }

.mh-ap-dropzone {
  padding: 26px 20px;
  border: 2px dashed var(--a-blue-accent);
  border-radius: 6px;
  background: var(--a-blue-light);
  text-align: center;
}

.mh-ap-dropzone__text { font-size: 14px; font-weight: 500; color: var(--a-g700); }

.mh-ap-dropzone__text span { color: var(--a-blue-accent); font-weight: 600; text-decoration: underline; }

.mh-ap-dropzone__hint { font-size: 12px; color: var(--a-g500); margin-top: 2px; }

.mh-ap-camera { margin: 10px 0 14px; font-size: 13px; font-weight: 600; color: var(--a-blue-accent); }

.mh-ap-pages {
  list-style: none;
  margin: 0;
  padding: 0;
  background: #fff;
  border: 1px solid var(--a-g200);
  border-radius: 6px;
  box-shadow: var(--a-shadow-sm);
}

.mh-ap-pages li {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 9px 14px;
  border-bottom: 1px solid var(--a-g100);
  font-size: 13.5px;
}

.mh-ap-pages li:last-child { border-bottom: 0; }

.mh-ap-pages small { font-size: 12px; color: var(--a-g500); text-decoration: underline; }

.mh-ap-progress { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }

.mh-ap-progress li {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 9px 12px;
  border-radius: 6px;
  font-size: 14px;
  color: var(--a-g900);
}

.mh-ap-progress li:hover { background: #fff; }

.mh-ap-progress__done { color: var(--a-green); }

.mh-ap-spinner {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 2px solid var(--a-blue-light);
  border-top-color: var(--a-blue-accent);
  animation: mh-ap-spin .8s linear infinite;
  flex-shrink: 0;
}

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

.mh-ap-actions { display: flex; justify-content: space-between; align-items: center; margin-top: 18px; }

/* Trust section: assistant answer next to the document it cites */
.mh-ap-cited { display: grid; grid-template-columns: 300px minmax(0, 1fr); }

.mh-ap-cited .mh-ws__side { border-left: 0; border-right: 1px solid var(--a-g200); }

.mh-ap-cited__doc { background: var(--a-g50); padding: 14px; }

/* Standalone left-panel card (timeline section) */
.mh-app--panel { max-width: 400px; margin: 0 auto; padding: 18px 0 14px; }

.mh-app--panel .mh-ap-tl__label { max-width: 300px; }

/* Standalone side panel (assistant section) */
.mh-app--side { max-width: 460px; margin: 0 auto; display: flex; flex-direction: column; height: 500px; }

.mh-app--side .mh-ws__side { border-left: 0; flex: 1; }

.mh-ap-button--secondary { background: #fff; color: var(--a-g700); box-shadow: inset 0 0 0 1px var(--a-g200), var(--a-shadow-sm); }

.mh-ap-button--success { background: var(--a-green); }

/* Doctor home (dashboard/doctor_home) */
.mh-ap-home { background: var(--a-g50); padding: 20px 28px 26px; }

.mh-ap-home__bar { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 18px; flex-wrap: wrap; }

.mh-ap-home__logo { font-weight: 700; font-size: 14px; }

.mh-ap-home__account { display: flex; align-items: center; gap: 12px; font-size: 13px; color: var(--a-g700); }

.mh-ap-home__help { font-weight: 600; color: var(--a-blue-mid); }

.mh-ap-trial { padding: 3px 9px; border-radius: 6px; background: var(--a-green-light); color: var(--a-green); font-size: 11.5px; font-weight: 600; }

.mh-ap-onboarding { background: #fff; border: 1px solid var(--a-g200); border-radius: 10px; box-shadow: var(--a-shadow-sm); padding: 14px 18px 6px; margin-bottom: 18px; }

.mh-ap-onboarding__title { font-size: 15px; font-weight: 700; }

.mh-ap-onboarding__progress { font-size: 12.5px; color: var(--a-g700); }

.mh-ap-onboarding__bar { height: 4px; border-radius: 999px; background: var(--a-g100); margin: 10px 0 4px; overflow: hidden; }

.mh-ap-onboarding__bar span { display: block; height: 100%; background: var(--a-green); }

.mh-ap-onboarding__step { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-top: 1px solid var(--a-g100); font-size: 13.5px; }

.mh-ap-onboarding__step:nth-of-type(1) { border-top: 0; }

.mh-ap-onboarding__check { display: grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; border: 1px solid var(--a-g200); background: var(--a-g50); color: var(--a-g500); font-size: 11px; font-weight: 700; }

.mh-ap-onboarding__step.is-done { color: var(--a-g500); text-decoration: line-through; }

.mh-ap-onboarding__step.is-done .mh-ap-onboarding__check { background: var(--a-green-light); border-color: var(--a-green-light); color: var(--a-green); }

.mh-ap-onboarding__link { font-weight: 600; color: var(--a-blue-mid); }

.mh-ap-home__head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }

.mh-ap-home__h1 { font-size: 18px; font-weight: 700; color: #0d1b3e; }

.mh-ap-home__search { max-width: 360px; margin-bottom: 12px; background: #fff; }

.mh-ap-home__list { list-style: none; margin: 0; padding: 0; background: #fff; border: 1px solid var(--a-g200); border-radius: 6px; }

.mh-ap-home__list li { display: flex; align-items: center; gap: 14px; padding: 11px 16px; border-top: 1px solid var(--a-g100); color: var(--a-g500); }

.mh-ap-home__list li:first-child { border-top: 0; }

.mh-ap-home__name { flex: 1; font-weight: 600; color: var(--a-g900); font-size: 14px; }

.mh-ap-home__dob { font-size: 13px; }

/* "Novi dokument" picker + the Izveštaj paper, as standalone center panes */
.mh-ap-picker { padding: 10px 14px 14px; background: var(--a-g50); }

.mh-ap-picker .mh-ap-panel { border-bottom: 1px solid var(--a-g200); border-radius: 0 6px 6px 6px; }

.mh-ap-picker__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }

.mh-ap-picker__option { display: flex; flex-direction: column; gap: 6px; padding: 16px; border: 1px solid var(--a-g200); border-radius: 6px; color: var(--a-blue-accent); }

.mh-ap-picker__option strong { font-size: 14.5px; color: var(--a-g900); }

.mh-ap-picker__option span { font-size: 12.5px; line-height: 1.5; color: var(--a-g700); }

.mh-ap-picker__option.is-hover { border-color: var(--a-blue-accent); box-shadow: var(--a-shadow-sm); }

.mh-ap-paper__head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }

.mh-ap-paper__updated { font-size: 12.5px; color: var(--a-g500); }

.mh-ap-paper__meta { font-size: 13px; color: var(--a-g700); white-space: nowrap; }

.mh-ap-paper__saved { margin-left: 8px; font-size: 12.5px; font-weight: 600; color: var(--a-green); }

.mh-ap-paper__inserts { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 14px 0 10px; font-size: 12.5px; color: var(--a-g700); }

.mh-ap-paper__inserts span { padding: 4px 10px; border: 1px solid var(--a-g200); border-radius: 999px; font-weight: 600; }

.mh-ap-paper__editor { border: 1px solid var(--a-g200); border-radius: 8px; padding: 14px 16px; font-size: 14.5px; line-height: 1.7; min-height: 150px; }

.mh-ap-paper__editor p { margin: 0 0 6px; font-size: inherit; color: var(--a-g900); }

.mh-ap-paper__actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }

/* Hero spacing + responsive collapse, mirroring how the portal itself collapses panels */
.mh-hero__app { margin: 64px auto 0; max-width: 1180px; }

.mh-how__app { margin-top: 64px; }

@media (max-width: 1100px) {
  .mh-ws { grid-template-columns: 240px minmax(0, 1fr); }

  .mh-ws > .mh-ws__side { display: none; }
}

@media (max-width: 760px) {
  .mh-ws { grid-template-columns: minmax(0, 1fr); height: 480px; }

  .mh-ws > .mh-ws__left { display: none; }

  .mh-ap-upload,
  .mh-ap-cited,
  .mh-ap-picker__grid { grid-template-columns: 1fr; }

  .mh-ap-home { padding: 16px; }

  .mh-ap-upload__col + .mh-ap-upload__col { border-left: 0; border-top: 1px solid var(--a-g100); }

  .mh-ap-cited .mh-ws__side { border-right: 0; border-bottom: 1px solid var(--a-g200); }

  .mh-ap-panel { padding: 18px; }

  .mh-ap-lab th, .mh-ap-lab td { padding: 8px 10px; }
}

@media (prefers-reduced-motion: reduce) {
  .mh-ap-spinner { animation: none; }
}

/* ── Security: dark inverted band ────────────────────────── */
.mh-section--dark {
  background: var(--mh-inverted);
  color: var(--mh-on-inverted);
  border-radius: var(--mh-radius-xl);
  margin: 0 16px;
}

:where(.mh-body) .mh-section--dark :is(h2, h3) { color: #fff; }

.mh-section--dark .mh-section__lead { color: var(--mh-on-inverted-muted); }

.mh-section--dark .mh-eyebrow { background: rgba(255, 255, 255, .1); color: #9cc8ff; }

.mh-security-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.mh-security-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 22px;
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: var(--mh-radius-lg);
  background: rgba(255, 255, 255, .03);
  font-weight: 500;
  font-size: 16px;
}

.mh-security-item svg {
  flex-shrink: 0;
  width: 38px;
  height: 38px;
  padding: 9px;
  border-radius: 10px;
  background: rgba(255, 255, 255, .08);
  color: #6cc4f5;
}

/* ── Final CTA: dark panel ───────────────────────────────── */
.mh-final-cta { padding: 16px 16px 0; }

.mh-final-cta__panel {
  background:
    radial-gradient(80% 120% at 0% 0%, rgba(10, 108, 245, .4) 0%, transparent 60%),
    radial-gradient(70% 100% at 100% 100%, rgba(8, 174, 240, .28) 0%, transparent 60%),
    var(--mh-inverted);
  color: var(--mh-on-inverted);
  text-align: center;
  padding: 120px 24px;
  border-radius: var(--mh-radius-xl);
}

:where(.mh-body) .mh-final-cta h2 {
  color: #fff;
  font-size: clamp(34px, 5vw, 60px);
  margin-bottom: 36px;
}

.mh-final-cta__hint { margin-top: 18px; font-size: 14px; color: var(--mh-on-inverted-muted); }

:where(.mh-body) .mh-final-cta__hint a { color: #fff; text-decoration: underline; }

/* ── Hero trial line ─────────────────────────────────────── */
.mh-hero__trial {
  margin-top: 16px;
  font-size: 14px;
  font-weight: 500;
  color: var(--mh-teal);
}

/* ── Features grid ───────────────────────────────────────── */
.mh-features {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.mh-feature {
  background: var(--mh-surface);
  border-radius: var(--mh-radius-lg);
  padding: 32px 28px;
  transition: transform .2s, box-shadow .2s;
}

.mh-feature:hover { transform: translateY(-2px); box-shadow: var(--mh-shadow); }

.mh-feature svg {
  width: 44px;
  height: 44px;
  padding: 11px;
  border-radius: 12px;
  background: var(--mh-brand-soft);
  color: var(--mh-brand);
  margin-bottom: 40px;
}

.mh-feature h3 { margin-bottom: 8px; }

.mh-feature p { font-size: 15px; color: var(--mh-muted); margin: 0; }

/* Responsible AI: the portal's safeguards, under the cited-answer mock */
.mh-features--trust { margin-top: 48px; }

/* Four steps instead of three */
.mh-steps--four { grid-template-columns: repeat(4, 1fr); gap: 16px; }

/* ── Checklist (pricing card, signup intro) ──────────────── */
.mh-checklist { list-style: none; padding: 0; margin: 0 0 28px; }

.mh-checklist li {
  position: relative;
  padding: 8px 0 8px 30px;
  font-size: 16px;
  color: var(--mh-ink);
}

.mh-checklist li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 11px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--mh-teal-soft)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230f7b6c' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E")
    center / 11px no-repeat;
}

/* ── Free trial: copy left, card right ───────────────────── */
.mh-pricing {
  display: grid;
  grid-template-columns: 1fr 460px;
  gap: 64px;
  align-items: center;
}

.mh-pricing .mh-section__head { margin-bottom: 0; }

.mh-pricing-card {
  max-width: 460px;
  width: 100%;
  margin: 0 auto;
  background: var(--mh-bg);
  border: 1px solid var(--mh-border);
  border-radius: var(--mh-radius-xl);
  padding: 40px;
}

.mh-pricing-card__price {
  display: flex;
  align-items: baseline;
  gap: 12px;
  padding-bottom: 24px;
  margin-bottom: 20px;
  border-bottom: 1px solid var(--mh-border-strong);
}

.mh-pricing-card__price strong {
  font-family: var(--mh-serif);
  font-weight: 400;
  font-size: 56px;
  line-height: 1;
  letter-spacing: -.02em;
  color: var(--mh-ink);
}

.mh-pricing-card__price span { font-size: 18px; color: var(--mh-teal); font-weight: 600; }

/* ── For clinics ─────────────────────────────────────────── */
.mh-clinic-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.mh-clinic-list li {
  padding: 24px;
  border-radius: var(--mh-radius-lg);
  background: var(--mh-surface);
  font-size: 15px;
  color: var(--mh-muted);
}

.mh-clinic-list strong { display: block; color: var(--mh-ink); margin-bottom: 6px; font-size: 16px; }

/* ── Signup page ─────────────────────────────────────────── */
.mh-signup { padding: 72px 0 120px; }

.mh-signup__inner {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 72px;
  align-items: start;
}

:where(.mh-body) .mh-signup__intro h1 {
  font-size: clamp(36px, 4.6vw, 56px);
  line-height: 1.06;
  letter-spacing: -.02em;
  margin-bottom: 20px;
}

.mh-signup__intro > p { color: var(--mh-muted); font-size: 17px; margin-bottom: 24px; }

.mh-signup__clinic { font-size: 15px; }

.mh-form-card {
  background: var(--mh-surface);
  border-radius: var(--mh-radius-xl);
  padding: 40px;
  box-shadow: var(--mh-shadow-lg);
}

.mh-form { display: grid; gap: 18px; }

.mh-form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: start; }

.mh-field { display: grid; gap: 6px; }

.mh-field label { font-size: 14px; font-weight: 500; color: var(--mh-ink); }

.mh-field input {
  font: inherit;
  font-size: 15px;
  padding: 11px 14px;
  border: 1px solid var(--mh-border-strong);
  border-radius: var(--mh-radius);
  background: #fff;
  color: var(--mh-ink);
  width: 100%;
  transition: border-color .15s, box-shadow .15s;
}

.mh-field input:focus { outline: none; border-color: var(--mh-brand); box-shadow: 0 0 0 3px var(--mh-brand-soft); }

.mh-field small { font-size: 13px; color: var(--mh-faint); }

/* Rails wraps an invalid field in .field_with_errors */
.mh-field .field_with_errors { display: contents; }

.mh-field .field_with_errors input { border-color: var(--mh-alert); }

.mh-checkbox {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  font-size: 14px;
  color: var(--mh-muted);
  background: var(--mh-bg);
  border-radius: var(--mh-radius);
  padding: 14px 16px;
  cursor: pointer;
}

.mh-checkbox input { margin-top: 3px; width: 16px; height: 16px; flex-shrink: 0; accent-color: var(--mh-ink); }

.mh-checkbox .field_with_errors { display: contents; }

.mh-form-errors {
  background: #fff4ed;
  border: 1px solid #fed7aa;
  color: var(--mh-alert);
  border-radius: var(--mh-radius);
  padding: 12px 16px;
  font-size: 14px;
  margin-bottom: 18px;
}

.mh-form .mh-form-errors { margin-bottom: 0; }

.mh-form-errors ul { margin: 0; padding-left: 18px; }

.mh-form__hint { text-align: center; font-size: 13px; color: var(--mh-teal); font-weight: 500; margin: -6px 0 0; }

.mh-form__footer {
  text-align: center;
  font-size: 14px;
  color: var(--mh-muted);
  margin: 22px 0 0;
  padding-top: 20px;
  border-top: 1px solid var(--mh-border);
}

/* ── Guide page (/guide) ─────────────────────────────────── */
.mh-guide-hero {
  padding: 88px 0 56px;
  text-align: center;
}

:where(.mh-body) .mh-guide-hero h1 { font-size: clamp(40px, 5.6vw, 68px); line-height: 1.06; letter-spacing: -.025em; margin-bottom: 18px; }

.mh-guide-hero .mh-section__lead { margin: 0 auto; }

.mh-guide-toc {
  list-style: none;
  counter-reset: toc;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin: 32px 0 0;
  padding: 0;
}

.mh-guide-toc li { counter-increment: toc; }

:where(.mh-body) .mh-guide-toc a {
  display: inline-block;
  padding: 8px 16px;
  border: 1px solid var(--mh-border-strong);
  border-radius: 999px;
  background: var(--mh-surface);
  font-size: 14px;
  font-weight: 500;
  color: var(--mh-ink);
  transition: border-color .15s;
}

.mh-guide-toc li:not(.mh-guide-toc__plain) a::before { content: counter(toc) ". "; color: var(--mh-brand); font-weight: 600; }

/* "Za lekare" / "Za klinike" — the guide's two parts, each with its own numbered list */
.mh-guide-toc__label {
  margin: 32px 0 0;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--mh-faint);
}

.mh-guide-toc__label + .mh-guide-toc { margin-top: 12px; }

/* The dark band that opens the clinic part */
.mh-guide-part { padding: 72px 0; scroll-margin-top: 76px; }

.mh-guide-part .mh-section__lead { color: var(--mh-on-inverted-muted); }

:where(.mh-body) .mh-guide-toc a:hover { border-color: var(--mh-ink); }

.mh-guide-step { padding: 96px 0; scroll-margin-top: 76px; }

.mh-guide-step + .mh-guide-step:not(.mh-section--alt) { padding-top: 96px; }

#faq { scroll-margin-top: 76px; }

.mh-guide-tip {
  padding: 14px 18px;
  border-left: 3px solid var(--mh-teal);
  background: var(--mh-teal-soft);
  border-radius: 0 var(--mh-radius) var(--mh-radius) 0;
  font-size: 15px !important;
  color: var(--mh-ink) !important;
}

.mh-guide-cols {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  margin: 40px 0;
}

.mh-guide-cols h3 { margin-bottom: 6px; }

.mh-guide-cols p { font-size: 15px; color: var(--mh-muted); margin: 0; }

.mh-guide-visual { margin-top: 8px; }

.mh-faq { display: grid; gap: 10px; }

.mh-faq__item {
  background: var(--mh-surface);
  border-radius: var(--mh-radius-lg);
  padding: 0 24px;
}

.mh-faq__item summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 0;
  font-weight: 600;
  font-size: 16px;
  color: var(--mh-ink);
}

.mh-faq__item summary::-webkit-details-marker { display: none; }

.mh-faq__item summary::after { content: "+"; color: var(--mh-brand); font-size: 22px; line-height: 1; }

.mh-faq__item[open] summary::after { content: "−"; }

.mh-faq__item p { color: var(--mh-muted); font-size: 15px; padding-bottom: 20px; margin: 0; }

@media (max-width: 900px) {
  .mh-guide-cols { grid-template-columns: 1fr; gap: 20px; }

  .mh-guide-step { padding: 64px 0; }
}

/* ── Legal pages: a white sheet on the lavender page ─────── */
.mh-legal { padding: 56px 16px 96px; }

.mh-legal > .mh-container {
  background: var(--mh-surface);
  border-radius: var(--mh-radius-xl);
  padding: 64px 56px;
}

:where(.mh-body) .mh-legal h1 { font-size: clamp(34px, 4.4vw, 48px); letter-spacing: -.02em; margin-bottom: 8px; }

.mh-legal__meta {
  color: var(--mh-faint);
  font-size: 14px;
  margin-bottom: 36px;
}

:where(.mh-body) .mh-legal h2 { font-size: 26px; margin: 40px 0 12px; }

.mh-legal h3 { font-size: 16px; margin: 20px 0 8px; }

.mh-legal p, .mh-legal li { color: var(--mh-muted); font-size: 15px; }

.mh-legal strong { color: var(--mh-ink); }

.mh-legal ul {
  margin: 0 0 12px;
  padding-left: 22px;
}

.mh-legal li { margin-bottom: 6px; }

/* ── Footer ──────────────────────────────────────────────── */
.mh-footer { padding: 88px 0 0; }

.mh-footer__inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px 56px;
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 40px;
}

.mh-footer__brand img { height: 38px; margin-bottom: 14px; }

.mh-footer__brand p {
  font-family: var(--mh-serif);
  font-size: 20px;
  line-height: 1.3;
  color: var(--mh-ink);
  max-width: 280px;
}

.mh-footer__nav {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.mh-footer__heading {
  font-size: 13px;
  font-weight: 600;
  color: var(--mh-faint);
  margin-bottom: 4px;
}

:where(.mh-body) .mh-footer__nav a { color: var(--mh-ink); font-size: 15px; }

:where(.mh-body) .mh-footer__nav a:hover { color: var(--mh-brand); }

.mh-footer__legal {
  max-width: 1200px;
  margin: 0 auto;
  border-top: 1px solid var(--mh-border-strong);
  padding: 22px 32px 32px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--mh-faint);
}

/* ── Scroll reveal: hidden only once marketing_reveal_controller has connected (it adds
   .mh-reveal-ready), so without JS everything simply shows ── */
.mh-reveal-ready .mh-reveal { opacity: 0; transform: translateY(16px); transition: opacity .7s ease, transform .7s ease; }

.mh-reveal-ready .mh-reveal.is-visible { opacity: 1; transform: none; }

/* ── Responsive ──────────────────────────────────────────── */
@media (max-width: 1000px) {
  .mh-hero__intro { grid-template-columns: 1fr; gap: 28px; }

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

  .mh-pricing { grid-template-columns: 1fr; gap: 40px; }
}

@media (max-width: 900px) {
  .mh-header__nav { display: none; }

  .mh-header__inner { grid-template-columns: 1fr auto; }

  .mh-section { padding: 80px 0; }

  .mh-hero { padding-top: 48px; }

  .mh-metrics { grid-template-columns: 1fr 1fr; margin: 48px 0 40px; }

  .mh-metric:nth-child(3) { padding-left: 0; border-left: 0; }

  .mh-split,
  .mh-steps,
  .mh-security-grid,
  .mh-signup__inner {
    grid-template-columns: 1fr;
  }

  .mh-features { grid-template-columns: 1fr 1fr; }

  .mh-footer__inner { grid-template-columns: 1fr 1fr; }

  .mh-footer__brand { grid-column: 1 / -1; }

  .mh-signup__inner { gap: 40px; }

  .mh-signup { padding-top: 48px; }

  .mh-split { gap: 40px; }

  .mh-stage { padding: 20px 20px 0; }

  .mh-legal > .mh-container { padding: 40px 24px; }
}

@media (max-width: 560px) {
  .mh-container, .mh-header__inner { padding: 0 16px; }

  .mh-header__inner { gap: 8px; }

  .mh-header__logo img { height: 40px; }

  .mh-header__actions .mh-btn--ghost { display: none; }

  .mh-header__actions .mh-btn--primary { padding: 8px 14px; font-size: 14px; }

  .mh-section--alt, .mh-section--dark { margin: 0 8px; border-radius: var(--mh-radius-lg); }

  .mh-final-cta { padding: 8px 8px 0; }

  .mh-final-cta__panel { padding: 80px 20px; }

  .mh-hero__sub, .mh-hero__promise { font-size: 17px; }

  .mh-hero__ctas { flex-direction: column; }

  .mh-hero__ctas .mh-btn { justify-content: center; }

  .mh-metric { padding-right: 12px; }

  .mh-metric + .mh-metric { padding-left: 12px; }

  .mh-features,
  .mh-steps--four,
  .mh-clinic-list,
  .mh-form__row { grid-template-columns: 1fr; }

  .mh-form-card, .mh-pricing-card { padding: 24px 20px; }

  .mh-stage { padding: 12px 12px 0; border-radius: var(--mh-radius-lg) var(--mh-radius-lg) 0 0; }

  .mh-legal { padding: 24px 8px 64px; }
}

/* Narrow phones: the hero already carries the main CTA, so the header keeps logo, language, login */
@media (max-width: 420px) {
  .mh-header__actions .mh-btn--primary { display: none; }

  .mh-header__actions .mh-btn--ghost { display: inline-flex; padding: 8px 10px; }
}

@media (prefers-reduced-motion: reduce) {
  html:has(.mh-body) { scroll-behavior: auto; }

  .mh-reveal-ready .mh-reveal { opacity: 1; transform: none; transition: none; }

  .mh-feature { transition: none; }
}
