/* =============================================================
 * mvet.ch — modern veterinary polish
 *
 * Three concerns in one stylesheet:
 *   1. `.mvet-cta-subtitle`  — price line INSIDE every booking CTA
 *      (primary integration — reads as part of the button text).
 *   2. `.mvet-price-badge`   — compact caption fallback for empty
 *      overlay anchors where no text hook is available.
 *   3. Global cosmetic overrides that lift the Tilda export from
 *      "pet shop" to "modern medical clinic" WITHOUT touching layout
 *      (no widths / heights / positions / paddings), so Tilda's
 *      pixel-pinned absolute positioning keeps working.
 *
 * Specificity strategy: Tilda emits per-record selectors like
 * `#recXXXXX .tn-atom`. We match or beat them with `html body` prefixes
 * + `!important` on the few declarations we override.
 * ============================================================= */

/* ------------------------------------------------------------ *
 * 1. Inline subtitle inside the button — the primary integration
 * ------------------------------------------------------------ *
 * Applied to either:
 *   .tn-atom__button-content  (Tilda molecule buttons, e.g. team cards)
 *   or a text atom rendering the button label next to an overlay anchor
 *     (hero CTA). In both cases the main label remains untouched and
 *   the price line appears as a slim, subordinate second line.
 */

/* Tilda molecule button → stack the main label + our subtitle. */
html body .tn-atom__button-content.mvet-cta-content {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  row-gap: 3px !important;
  line-height: 1.1 !important;
}

/* Tilda molecule buttons set the text span to block; preserve that
 * while making the hero label atom let our line render below. */
html body .mvet-cta-label.tn-atom {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  row-gap: 4px !important;
  overflow: visible !important;
}

/* Give the artboard-wrapper permission to grow / overflow so the extra
 * subtitle line isn't clipped by a fixed-size text atom. */
html body .mvet-cta-label-wrap {
  overflow: visible !important;
  height: auto !important;
}

/* The subtitle itself — small, dotted leader, slightly orange so it
 * reads as a price cue without screaming. */
html body .mvet-cta-subtitle {
  display: inline-flex !important;
  align-items: center !important;
  gap: 5px !important;
  padding: 2px 9px 2px 7px !important;
  border-radius: 999px !important;
  background: linear-gradient(135deg, #ff6a1f 0%, #ff4d1f 100%) !important;
  color: #fff !important;
  font-family: 'Spartan', 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif !important;
  font-weight: 700 !important;
  font-size: 10px !important;
  line-height: 1 !important;
  letter-spacing: 0.02em !important;
  text-transform: none !important;
  white-space: nowrap !important;
  box-shadow: 0 1px 3px rgba(255, 77, 31, 0.28) !important;
  /* Sit below the main button label rather than next to it. */
  align-self: center !important;
}

html body .mvet-cta-subtitle__dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #fff;
  flex: 0 0 auto;
  display: inline-block;
}

html body .mvet-cta-subtitle__prefix {
  font-weight: 600;
  opacity: 0.95;
  text-transform: lowercase;
}

html body .mvet-cta-subtitle__amount {
  font-weight: 800;
  letter-spacing: 0.03em;
}

html body .mvet-cta-subtitle__sep {
  opacity: 0.6;
}

html body .mvet-cta-subtitle__suffix {
  font-weight: 600;
  opacity: 0.95;
}

html body .mvet-cta-subtitle__suffix sup {
  font-size: 8px;
  vertical-align: super;
  line-height: 0;
  margin-right: 1px;
}

/* Hero CTAs — the first fold of the homepage and each clinic page uses a
 * big white pill with lots of breathing room. The default compact badge
 * gets visually swamped there, so bump the subtitle up to match the
 * main label's visual weight. Scoped to the "inline-neighbour" variant
 * (attached to an external label atom, i.e. the hero layout) so the
 * denser team-card buttons keep their tight subtitle. */
html body .mvet-cta-label .mvet-cta-subtitle {
  padding: 5px 14px 5px 11px !important;
  gap: 7px !important;
  font-size: 14px !important;
  letter-spacing: 0.025em !important;
  box-shadow:
    0 3px 10px rgba(255, 77, 31, 0.28),
    0 1px 0 rgba(255, 255, 255, 0.22) inset !important;
}

html body .mvet-cta-label .mvet-cta-subtitle__dot {
  width: 7px;
  height: 7px;
}

html body .mvet-cta-label .mvet-cta-subtitle__amount {
  font-size: 15px;
  font-weight: 800;
}

html body .mvet-cta-label .mvet-cta-subtitle__suffix sup {
  font-size: 10px;
}

@media (max-width: 640px) {
  html body .mvet-cta-label .mvet-cta-subtitle {
    padding: 4px 11px 4px 9px !important;
    font-size: 12px !important;
  }
  html body .mvet-cta-label .mvet-cta-subtitle__amount {
    font-size: 13px;
  }
  html body .mvet-cta-label .mvet-cta-subtitle__dot {
    width: 6px;
    height: 6px;
  }
}

/* Guard: Tilda's .tn-atom__button-text is often `display:block` with
 * fixed line-height — reset line-height so the subtitle line renders
 * tight against the main label. */
html body .mvet-cta-content .tn-atom__button-text {
  line-height: 1.15 !important;
}

/* Tilda clips .tn-atom and .tn-atom__button-content by default when the
 * button has a fixed height; allow our subtitle to render without
 * clipping on the CTAs we touched. */
a.mvet-booking-cta,
a.mvet-booking-cta .tn-atom__button-content,
a.mvet-booking-cta .tn-atom__button-text,
.t396__elem.mvet-booking-ancestor,
.tn-group.mvet-booking-ancestor,
.t396__group.mvet-booking-ancestor,
.t396__artboard.mvet-booking-ancestor,
.t396__filter.mvet-booking-ancestor,
.t396__carrier.mvet-booking-ancestor,
.r.t-rec.mvet-booking-ancestor {
  overflow: visible !important;
}

/* ------------------------------------------------------------ *
 * 2. Fallback floating badge (only for empty overlay anchors
 *    where neither hook above matched)
 * ------------------------------------------------------------ */
.mvet-price-badge {
  --mvet-badge-bg: #ff6a1f;
  --mvet-badge-bg-2: #ff4d1f;
  --mvet-badge-ink: #ffffff;

  position: absolute;
  /* Directly below the button, flush to its bottom-right corner so it
   * reads as a "connected" caption, not a floating island. */
  top: calc(100% + 2px);
  right: 8px;
  z-index: 10;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 10px 3px 8px;
  border-radius: 0 0 999px 999px;
  font-family: 'Spartan', 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-weight: 700;
  font-size: 10px;
  line-height: 1;
  letter-spacing: 0.02em;
  white-space: nowrap;
  color: var(--mvet-badge-ink);
  background: linear-gradient(135deg, var(--mvet-badge-bg) 0%, var(--mvet-badge-bg-2) 100%);
  box-shadow: 0 2px 6px rgba(255, 77, 31, 0.22);
  pointer-events: none;
}

.mvet-price-badge__dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #ffffff;
  flex: 0 0 auto;
}

.mvet-price-badge__amount {
  font-weight: 800;
  font-size: 11px;
  letter-spacing: 0.03em;
}

.mvet-price-badge__suffix {
  opacity: 0.92;
  font-weight: 600;
  font-size: 9px;
}

.mvet-price-badge__suffix sup {
  font-size: 7px;
  vertical-align: super;
  line-height: 0;
  margin-right: 1px;
}

@media (max-width: 480px) {
  .mvet-price-badge {
    top: calc(100% + 1px);
    right: 6px;
    padding: 2px 8px 2px 7px;
    font-size: 9px;
  }
  .mvet-price-badge__amount { font-size: 10px; }
  .mvet-price-badge__suffix { font-size: 8px; }

  html body .mvet-cta-subtitle {
    font-size: 9px !important;
    padding: 2px 7px !important;
  }
}

/* ------------------------------------------------------------ *
 * 3. Team cards — subordinate the cabinet label
 * ------------------------------------------------------------ *
 * "CABINET PLAINPALAIS, EAUX-VIVES" and siblings were rendered with
 * the same weight / transform as the doctor's name, so the cabinet
 * line visually competed with the vet identity. Push them back to a
 * quiet subtitle (smaller, medium weight, muted teal, no uppercase)
 * — consistent across every team card in rec1384966451.
 */
/* Ioana — the card the user flagged. Tilda shipped this field as
 * `font-weight: 700; text-transform: uppercase; font-size: 16px;` so
 * it read as loudly as the doctor's name. Push it back to a teal
 * subtitle and drop the uppercase so it reads as "(location)". */
html body #rec1384966451 .tn-elem[data-elem-id="1764166397077000009"] .tn-atom {
  font-weight: 500 !important;
  font-size: 12px !important;
  color: #0a9ca3 !important;
  text-transform: none !important;
  letter-spacing: 0.06em !important;
  opacity: 0.9;
}

/* Unify the other cabinet labels on the same team block so the card
 * rhythm is "NAME (bold) / cabinet (subtle) / flags / bio / button". */
html body #rec1384966451 .tn-atom[field="tn_text_175698195597176030"],
html body #rec1384966451 .tn-atom[field="tn_text_175697798069890150"],
html body #rec1384966451 .tn-atom[field="tn_text_175697797123350140"],
html body #rec1384966451 .tn-atom[field="tn_text_175698158227870270"] {
  font-weight: 500 !important;
  color: #0a9ca3 !important;
  text-transform: none !important;
  letter-spacing: 0.06em !important;
  opacity: 0.9;
}

/* ------------------------------------------------------------ *
 * 4. Global cosmetic polish — "clinic, not pet shop"
 * ------------------------------------------------------------ *
 * Scope: colors, typography, shadows, borders, radii only.
 * NEVER touch width / height / top / left / padding / margin —
 * Tilda positions everything in absolute pixels and any layout
 * change cascades into broken overlaps across breakpoints.
 */

html body,
html body .t-rec,
html body .tn-atom {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

html body h1.tn-atom,
html body h2.tn-atom,
html body h3.tn-atom {
  letter-spacing: -0.015em !important;
}

html body a.tn-atom.js-click-zero-stat,
html body a.tn-group.js-click-zero-stat {
  transition:
    transform 0.18s ease,
    box-shadow 0.22s ease,
    background-color 0.22s ease !important;
  will-change: transform;
}

html body a.tn-atom.js-click-zero-stat:hover,
html body a.tn-group.js-click-zero-stat:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 32px rgba(10, 60, 70, 0.16), 0 2px 6px rgba(10, 60, 70, 0.08) !important;
}

html body .t396__artboard[style*="#00aeb5"],
html body .t396__artboard[style*="#00AEB5"],
html body .t396__carrier[style*="#00aeb5"],
html body .t396__carrier[style*="#00AEB5"] {
  filter: saturate(0.82) brightness(0.97);
}

html body .tn-atom p,
html body .tn-atom li,
html body .tn-atom[field^="tn_text_"] {
  color: #0f2a3a;
}

html body a.tn-atom.js-click-zero-stat[href^="tel:"],
html body a.tn-atom.js-click-zero-stat[href^="Tel:"] {
  letter-spacing: 0.02em !important;
}

html body .t-rec hr,
html body .t-rec .t-separator__line {
  border-color: rgba(10, 156, 163, 0.22) !important;
}

html body a:focus-visible,
html body button:focus-visible {
  outline: 3px solid rgba(10, 156, 163, 0.55) !important;
  outline-offset: 2px;
  border-radius: inherit;
}
