/* CRO enhancements for article readers (Joey 2026-07-29):
   - inline "cue" links: a highlighted word that pops a summary + CTA card
   - inline subscribe / Frontier CTA blocks with an emblem
   Loaded only on readers (linked from src/pages/[dir]/[slug].astro).
   Content lives in frontier-data/article-cro.json (copy = placeholder for Justin). */

/* ---------- inline cue link ---------- */
.fr-prose .fr-cue {
  color: #fff; text-decoration: none;
  background: rgba(255,255,255,0.09);
  border-bottom: 1.5px solid rgba(255,255,255,0.45);
  padding: 0 3px; cursor: help;
  transition: background-color .15s ease, border-color .15s ease;
}
.fr-prose .fr-cue:hover, .fr-prose .fr-cue.is-active { background: rgba(255,255,255,0.17); border-bottom-color: #fff; }
.reader-light .fr-prose .fr-cue { color: #14161a; background: rgba(0,0,0,0.06); border-bottom-color: rgba(0,0,0,0.5); }
.reader-light .fr-prose .fr-cue:hover, .reader-light .fr-prose .fr-cue.is-active { background: rgba(0,0,0,0.11); border-bottom-color: #14161a; }

/* ---------- cue popover card ---------- */
.fr-cue-card {
  position: fixed; z-index: 300; width: 300px; max-width: calc(100vw - 24px);
  background: #17181c; border: 1px solid rgba(255,255,255,0.14);
  padding: 18px; box-shadow: 0 18px 50px rgba(0,0,0,0.55);
  opacity: 0; transform: translateY(6px); transition: opacity .16s ease, transform .16s ease;
  pointer-events: none;
}
.fr-cue-card.is-open { opacity: 1; transform: translateY(0); pointer-events: auto; }
.fr-cue-label { font-family: var(--mono); font-size: 10px; letter-spacing: .12em; text-transform: uppercase; color: rgba(255,255,255,0.42); margin: 0 0 7px; }
.fr-cue-summary { font-family: var(--body); font-size: 15px; font-weight: 600; line-height: 1.35; color: #fff; margin: 0 0 10px; }
.fr-cue-desc { font-family: var(--body); font-size: 13px; line-height: 1.55; color: rgba(255,255,255,0.6); margin: 0 0 16px; }
.fr-cue-desc:empty { display: none; margin: 0; }
.fr-cue-btn { display: flex; align-items: center; justify-content: center; gap: 7px; width: 100%; padding: 11px 14px; background: #fff; color: #0a0a0a; font-family: var(--mono); font-size: 11px; letter-spacing: .07em; text-transform: uppercase; text-decoration: none; transition: background-color .15s ease; }
.fr-cue-btn:hover { background: rgba(255,255,255,0.86); }
.fr-cue-btn svg { flex: none; }
.reader-light .fr-cue-card { background: #fff; border-color: rgba(0,0,0,0.1); box-shadow: 0 18px 50px rgba(0,0,0,0.18); }
.reader-light .fr-cue-label { color: rgba(0,0,0,0.42); }
.reader-light .fr-cue-summary { color: #14161a; }
.reader-light .fr-cue-desc { color: rgba(0,0,0,0.6); }
.reader-light .fr-cue-btn { background: #14161a; color: #fff; }
.reader-light .fr-cue-btn:hover { background: #000; }

/* ---------- inline CTA block (subscribe / Frontier) ---------- */
.fr-prose .fr-inline-cta {
  display: flex; align-items: center; gap: 20px;
  padding: 22px 24px; margin: 36px 0;
  border: 1px solid rgba(255,255,255,0.14);
  background: radial-gradient(120% 140% at 0% 0%, rgba(255,255,255,0.05), rgba(255,255,255,0.015) 60%, transparent);
}
/* NOTE: qualify under .fr-prose so these beat the shared .fr-prose img / .fr-prose p rules. */
.fr-prose .fr-inline-cta-emblem { flex: none; width: 64px; height: 64px; max-width: 64px; object-fit: contain; margin: 0; border-radius: 0; }
.fr-prose .fr-inline-cta-body { flex: 1 1 auto; min-width: 0; }
.fr-prose .fr-inline-cta-h { font-family: var(--display); font-weight: 400; font-synthesis: none; font-size: 20px; line-height: 1.15; color: #fff; margin: 0 0 5px; }
.fr-prose .fr-inline-cta-sub { font-family: var(--body); font-size: 13.5px; line-height: 1.5; color: rgba(255,255,255,0.6); margin: 0; }
.fr-prose .fr-inline-cta-btn { flex: none; text-decoration: none; }

/* Service variant: brand the card in that service's own accent + engraving so it
   reads as an ad for that specific service (--svc / --svc-text set inline). */
.fr-prose .fr-inline-cta--svc {
  border-color: color-mix(in srgb, var(--svc) 42%, transparent);
  background:
    radial-gradient(130% 150% at 0% 0%, color-mix(in srgb, var(--svc) 16%, transparent), transparent 62%),
    linear-gradient(90deg, color-mix(in srgb, var(--svc) 7%, transparent), transparent 45%);
}
.fr-prose .fr-inline-cta--svc .fr-inline-cta-btn {
  background: var(--svc); color: var(--svc-text); border-color: var(--svc);
}
.fr-prose .fr-inline-cta--svc .fr-inline-cta-btn:hover { background: var(--svc); filter: brightness(1.08); }
.reader-light .fr-prose .fr-inline-cta--svc {
  border-color: color-mix(in srgb, var(--svc) 45%, transparent);
  background:
    radial-gradient(130% 150% at 0% 0%, color-mix(in srgb, var(--svc) 17%, transparent), transparent 62%),
    linear-gradient(90deg, color-mix(in srgb, var(--svc) 9%, transparent), transparent 45%);
}

.reader-light .fr-prose .fr-inline-cta { border-color: rgba(0,0,0,0.12); background: radial-gradient(120% 140% at 0% 0%, rgba(0,0,0,0.04), transparent 60%); }
.reader-light .fr-prose .fr-inline-cta-h { color: #14161a; }
.reader-light .fr-prose .fr-inline-cta-sub { color: rgba(0,0,0,0.6); }
.reader-light .fr-prose .fr-inline-cta-emblem { filter: invert(1); }
@media (max-width: 560px) { .fr-prose .fr-inline-cta { flex-direction: column; text-align: center; } }
