/* ===========================================================================
   ArbeeStudios — base layer
   Reset, shared scroll-reveal system, and accessibility helpers.
   The Playground theme itself lives in playground.css.
   =========================================================================== */

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

html { -webkit-text-size-adjust: 100%; overflow-x: hidden; }

body {
  margin: 0;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: inherit; }

img, svg { display: block; max-width: 100%; }

:focus-visible {
  outline: 3px solid var(--ink, #2a2438);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ---- skip link --------------------------------------------------------- */
.skip-link {
  position: fixed;
  left: 50%;
  top: -60px;
  transform: translateX(-50%);
  z-index: 50;
  background: var(--ink, #2a2438);
  color: #fff;
  font-family: "Fredoka", system-ui, sans-serif;
  font-weight: 500;
  font-size: 14px;
  padding: 10px 18px;
  border-radius: 999px;
  text-decoration: none;
  transition: top 0.2s ease;
}
.skip-link:focus-visible { top: 14px; }

/* ===========================================================================
   Scroll reveal
   No-JS (and reduced-motion) → everything is visible at rest, never trapped.
   JS-on → content lifts in once it enters the viewport, ending fully visible.
   The `js` class is added by js/app.js once it runs, so a failed/blocked script
   leaves the no-JS default (everything visible) intact.
   =========================================================================== */
.reveal { opacity: 1; transform: none; }

.js .reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
              transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
  transition-delay: var(--reveal-delay, 0s);
  will-change: opacity, transform;
}
.js .reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
  .js .reveal { opacity: 1; transform: none; transition: none; }
}
