/* ==========================================================================
   polish.css — cosmetic pass (2026-09). Loaded last on every page.
   Visual only: no layout moves, no copy changes. Base spacing unit: 8px.
   ========================================================================== */

/* ---------- 1. Contrast (WCAG AA on the dark theme) ---------- */

/* Button gradient: its light end measured 4.2:1 with white text. Deeper end -> 6.2:1. */
:root {
  --wp--preset--gradient--midnight: linear-gradient(135deg, #02037f 0%, #1a56db 100%);
  /* Pricing "Software" cells: pale text on this gradient measured 3.4:1. Deeper blues -> 4.8:1+. */
  --wp--preset--gradient--primary-500-300: linear-gradient(135deg, #1d4ed8 0%, #2563eb 100%);
  /* Nothing below 14px: the theme's 12px and 13px ("small") presets become 14px. */
  --wp--preset--font-size--12: 14px;
  --wp--preset--font-size--small: 14px;
}
.has-primary-500-300-gradient-background { background: linear-gradient(135deg, #1d4ed8 0%, #2563eb 100%) !important; }

/* Near-black text on the bright-blue panels measured 3.9:1. White on #125EFF is 5.2:1. */
.has-custom-azul-brillante-background-color,
.has-custom-azul-brillante-background-color :is(p, li, span, strong, em, h1, h2, h3, h4, h5, h6, small),
.has-custom-azul-brillante-background-color .has-neutral-0-color {
  color: #fff !important;
}

/* Blue labels on the navy gradients (#3B82F6 measured 2.8:1). Lighter blue #93C5FD -> 5.8:1+. */
.has-primary-500-color,
.has-light-gradient-background .has-primary-500-color,
.has-primary-transparent-gradient-background p.util-38e8281d,
.has-light-gradient-background p.util-38e8281d,
.has-light-gradient-background .is-style-sub-heading {
  color: #93c5fd !important;
}

/* Links inside prose: clearly distinguishable from body text. */
.entry-content a:not(.wp-block-button__link) {
  color: #93c5fd;
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
}
.entry-content a:not(.wp-block-button__link):hover { color: #bfdbfe; }

/* ---------- 2. Typography ---------- */

/* Nothing below 14px. */
.has-12-font-size, .has-13-font-size, .wp-block-post-date, .wp-block-post-date time, .util-29c583a8 { font-size: 14px !important; }
small, .has-small-font-size { font-size: max(14px, 0.875em); }

/* Long-form pages (articles, FAQ, Media Coverage, legal): readable measure + rhythm. */
/* ~72-75 characters per line at 16px Inter (the ch unit overshoots with this font). */
.entry-content > :is(p, ul, ol, h2, h3, h4, hr, blockquote, .qa-cta-row) {
  max-width: min(620px, calc(100% - 44px)); /* 22px gutters on phones, aligned with the header */
}
.entry-content :where(p, li) { line-height: 1.65; }
.entry-content > p { margin-top: 0; margin-bottom: 16px; }
.entry-content > :where(ul, ol) { margin-top: 0; margin-bottom: 24px; padding-left: 24px; }
.entry-content li + li { margin-top: 8px; }
.entry-content > h2 {
  font-size: clamp(26px, 1.6vw + 16px, 34px);
  line-height: 1.2;
  margin-top: 48px;
  margin-bottom: 16px;
}
.entry-content > h3 {
  font-size: clamp(20px, 0.8vw + 16px, 24px);
  line-height: 1.3;
  margin-top: 32px;
  margin-bottom: 8px;
}
.entry-content > hr { margin-top: 40px; margin-bottom: 40px; border-color: rgba(255, 255, 255, 0.12); }
.entry-content > figure { margin-top: 32px; margin-bottom: 32px; }

/* ---------- 3. Buttons / CTAs ---------- */

/* One primary (filled gradient) and one secondary (outline). Same shape, height and padding. */
.wp-block-button .wp-block-button__link {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 999px;
  transition: filter .15s ease, border-color .15s ease, background-color .15s ease, transform .15s ease;
}
.wp-block-button.is-style-fill .wp-block-button__link:not(.has-midnight-gradient-background):not(.has-transparent-background-color),
.wp-block-button:not(.is-style-outline) .wp-block-button__link.has-custom-azul-brillante-background-color {
  background: var(--wp--preset--gradient--midnight) !important;
  color: #fff !important;
}
.wp-block-button .wp-block-button__link:hover { filter: brightness(1.12); }
.wp-block-button.is-style-outline .wp-block-button__link:hover { background-color: rgba(255, 255, 255, 0.08) !important; filter: none; }

/* Visible keyboard focus everywhere. */
a:focus-visible,
button:focus-visible,
summary:focus-visible,
.wp-block-button__link:focus-visible {
  outline: 2px solid #93c5fd !important;
  outline-offset: 3px !important;
  border-radius: 6px;
}

/* ---------- 4. Mobile (<= 781px) ---------- */
@media (max-width: 781px) {
  /* Tap targets >= 44px. */
  .wp-block-navigation__responsive-container-open,
  .wp-block-navigation__responsive-container-close {
    min-width: 44px;
    min-height: 44px;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
  }
  .wp-block-navigation__responsive-container .wp-block-navigation-item__content { min-height: 44px; display: inline-flex; align-items: center; }
  .wp-block-site-logo a, .custom-logo-link { min-width: 44px; min-height: 44px; display: inline-flex !important; align-items: center; }
  footer.wp-block-template-part p a { display: inline-flex; align-items: center; min-height: 44px; }
  footer.wp-block-template-part p { margin-top: 0; margin-bottom: 0; }
  .wp-block-button .wp-block-button__link { min-height: 48px; }

  /* Prose on phones: 16px minimum body, comfortable side gutters. */
  .entry-content :where(p, li) { font-size: max(16px, 1em); }
  .entry-content > h2 { margin-top: 40px; }
}

/* ---------- 5. Motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
