/* ==========================================================================
   Morcegão FM — Base element styling & helpers
   Sets the dark stage, warm paper text, link colors, selection.
   ========================================================================== */

*,
*::before,
*::after { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg-page);
  color: var(--text-body);
  font-family: var(--font-body);
  font-size: var(--text-md);
  line-height: var(--lh-normal);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* Headings default to condensed display voice */
h1, h2, h3, h4 {
  font-family: var(--font-heading);
  color: var(--text-strong);
  line-height: var(--lh-snug);
  font-weight: var(--fw-semibold);
  margin: 0 0 var(--space-3);
}

/* Links — bluesy default, amber on hover (the house link language) */
a {
  color: var(--link);
  text-decoration: none;
  transition: color var(--dur-fast) var(--ease-out);
}
a:hover { color: var(--link-hover); }

::selection {
  background: var(--amber-500);
  color: var(--bat-black);
}

/* A11y: estado de foco visível e consistente (anel âmbar) */
:focus-visible {
  outline: 3px solid var(--highlight);
  outline-offset: 2px;
  border-radius: var(--radius-xs);
}

/* A11y: respeita preferência de movimento reduzido globalmente */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* Utility: poster headline */
.mfm-poster {
  font-family: var(--font-display);
  text-transform: uppercase;
  line-height: var(--lh-tight);
  letter-spacing: var(--ls-tight);
  color: var(--text-strong);
}

/* Utility: mono meta label ("ON AIR", timecodes) */
.mfm-label {
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: var(--ls-label);
  font-size: var(--text-2xs);
  color: var(--text-faint);
}

/* Utility: film-grain texture overlay for the dark stage */
.mfm-grain::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: var(--grain-opacity);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url%28%23n%29'/%3E%3C/svg%3E");
}
