/* ============================================================
   Marketing pages (home, testimonials, contact).
   The pages keep the Claude Design inline styles verbatim; this file
   holds what the design runtime used to inject: the <helmet> rules,
   hover states (style-hover="…" became .hv-* classes) and the
   behaviour hooks for the mobile menu, FAQ and video.
   Loaded after rra.css (tokens + components).
   ============================================================ */

/* ---- From the design's <helmet> blocks ---------------------- */
@keyframes rra-marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@keyframes rra-floaty { 0%,100% { translate: 0 0; } 50% { translate: 0 -9px; } }
@keyframes rra-floaty2 { 0%,100% { translate: 0 0; } 50% { translate: 0 7px; } }
@keyframes rra-blink { 0%,100% { opacity: 1; } 50% { opacity: .3; } }
@keyframes rra-rise { from { opacity: 0; transform: translateY(22px); } to { opacity: 1; transform: none; } }
@keyframes rra-grow { from { transform: scaleY(0); } to { transform: scaleY(1); } }

[data-menu-btn] { display: none; }
@media (max-width: 860px) {
  [data-desktop-links] { display: none !important; }
  [data-menu-btn] { display: inline-flex !important; }
  [data-float] { display: none !important; }
}
@media (min-width: 861px) {
  /* The mobile panel never shows on desktop, even if it was left open. */
  [data-mobile-panel] { max-height: 0 !important; }
}
@media (prefers-reduced-motion: reduce) {
  [data-marquee], [data-float], [data-bar], [data-dot] { animation: none !important; }
  html { scroll-behavior: auto; }
}

/* Testimonials page helmet: default link colours (inline styles win).
   :where() keeps the design's low specificity so buttons keep their colours. */
:where(.page-testimonials) a { color: var(--teal-700); }
:where(.page-testimonials) a:hover { color: var(--teal-500); }

/* ---- Hover states (design: style-hover="…") ----------------- */
/* !important is needed to beat the element's inline style, exactly as the
   design runtime's hover state did. Keyboard focus gets the same look. */
.hv-c-gold500:hover, .hv-c-gold500:focus-visible { color: var(--gold-500) !important; }
.hv-c-gold600:hover, .hv-c-gold600:focus-visible { color: var(--gold-600) !important; }
.hv-c-teal500:hover, .hv-c-teal500:focus-visible { color: var(--teal-500) !important; }
.hv-bg-gold600:hover, .hv-bg-gold600:focus-visible { background: var(--gold-600) !important; }
.hv-bg-n200:hover { background: var(--neutral-200) !important; }
.hv-pause:hover { animation-play-state: paused !important; }

/* ---- Keyboard focus visibility ------------------------------ */
/* Keyboard focus only (:focus-visible) — mouse and touch look unchanged.
   The design system's button ring is a faint halo, so buttons and checkboxes
   get a solid teal outline; on navy sections (header, footer, .sec-dark set
   by the importer) the teal would vanish, so those use gold. */
.rra-btn:focus-visible, .rra-iconbtn:focus-visible { outline: 2px solid var(--teal-500); outline-offset: 2px; }
.rra-check__input:focus-visible + .rra-check__box { outline: 2px solid var(--teal-500); outline-offset: 2px; }
.site-nav :focus-visible, .site-footer-dark :focus-visible, .sec-dark :focus-visible {
  outline: 2px solid var(--gold-500);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ---- FAQ accordion ------------------------------------------ */
[data-faq-toggle] { color: inherit; font: inherit; }
[data-faq-toggle]:focus-visible { outline: 2px solid var(--teal-500); outline-offset: 2px; border-radius: 6px; }

/* ---- Testimonial video (click to load) ---------------------- */
.tv-facade { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; text-decoration: none; cursor: pointer; }
.tv-facade img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.tv-facade::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(14, 24, 40, 0.12), rgba(14, 24, 40, 0.5));
  transition: background var(--duration-base) var(--ease-standard);
}
.tv-facade__play { position: relative; z-index: 1; transition: transform var(--duration-base) var(--ease-spring); }
.tv-facade:hover .tv-facade__play, .tv-facade:focus-visible .tv-facade__play { transform: scale(1.07); }
.tv-facade:hover::after { background: linear-gradient(180deg, rgba(14, 24, 40, 0.05), rgba(14, 24, 40, 0.38)); }
.tv-facade:focus-visible { outline: 3px solid var(--gold-500); outline-offset: -3px; }

/* ---- Contact form ------------------------------------------- */
.cf-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-4) var(--space-5); }
.cf-grid .cf-span { grid-column: 1 / -1; }
@media (max-width: 640px) { .cf-grid { grid-template-columns: 1fr; } }
.cf-grid .rra-input--lg, .cf-grid .rra-textarea__control { font-size: var(--text-base); }
.cf-grid .rra-textarea__control { min-height: 150px; }
/* Field edges and placeholder text need 3:1 / 4.5:1 contrast (WCAG 1.4.11 / 1.4.3). */
/* :where() keeps this at the base components' specificity, so the hover, focus,
   checked and red "invalid" borders still win. */
:where(.cf-grid) .rra-input, :where(.cf-grid) .rra-textarea__control, :where(.cf-grid) .rra-check__box { border-color: var(--neutral-500); }
.cf-grid .rra-input__control::placeholder, .cf-grid .rra-textarea__control::placeholder { color: var(--neutral-600); }
.cf-hp { position: absolute !important; left: -10000px !important; width: 1px; height: 1px; overflow: hidden; }
.cf-alert {
  display: flex; gap: var(--space-3); align-items: flex-start; padding: var(--space-4);
  border-radius: var(--radius-md); font-size: var(--text-sm); line-height: 1.5;
  background: var(--negative-50); border: 1px solid var(--negative-100); color: var(--negative-700);
}
.cf-alert a { color: inherit; font-weight: 600; }
.cf-submit[aria-busy="true"] { opacity: 0.7; cursor: progress; }
.cf-status:focus { outline: none; }
