/* =========================================
   Bipolarist Lab — Layout & Components (site4.css)
   Pairs with colors4.css
========================================= */

/* Base typography & behavior */
html {
  font-size: 18px;
  scroll-behavior: smooth;
}

body {
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, Segoe UI,
               Roboto, Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji";
  color: var(--ink);
}

/* Reveal animation (used across Time + Lab pages) */
.reveal {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Parallax text hook */
.parallax {
  will-change: transform;
}

/* Generic container for content blocks */
.wrap {
  max-width: 72rem;
  margin-left: auto;
  margin-right: auto;
  padding-left: 1.25rem;
  padding-right: 1.25rem;
}

/* Hero shells (Time pages + Lab hero) */
.hero-shell {
  max-width: 56rem;
  margin: 0 auto;
  padding: 3.5rem 1.25rem 3.75rem;
  border-radius: 1.75rem;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid var(--shell-border);
  box-shadow: var(--shell-shadow);
}

/* Lab hero wrapper (kits.html section.hero-neon) */
.hero-neon {
  position: relative;
}
.hero-neon::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at top, rgba(224, 236, 255, 0.8), transparent 60%);
  mix-blend-mode: normal;
  pointer-events: none;
}

/* Skip link for accessibility */
.skip-link {
  position: absolute;
  left: -9999px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
}
.skip-link:focus {
  left: 8px;
  top: 8px;
  width: auto;
  height: auto;
  background: #111827;
  color: #ffffff;
  padding: 0.5rem 0.75rem;
  border-radius: 0.5rem;
  z-index: 999;
}

/* Simple utility classes used on content pages */
.container {
  max-width: 72rem;
  margin: 0 auto;
}

.rounded-2xl {
  border-radius: 1rem;
}

.border {
  border: 1px solid var(--border-subtle);
}

.shadow-2xl {
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1),
              0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

/* Card / tile visuals (used by Time cards + Lab cards) */
.card,
.section-card,
.reading-inner,
figure.block,
article.rounded-2xl {
  background: var(--shell-bg);
  border: 1px solid var(--shell-border);
  border-radius: 1.25rem;
  box-shadow: var(--shell-shadow);
}

/* Images */
figure img {
  max-width: 100%;
  height: auto;
}

/* Text colors */
.text-neutral-900 {
  color: #111827;
}
.text-neutral-700 {
  color: #374151;
}
.text-neutral-600 {
  color: #4b5563;
}

/* Links (general text links, not buttons) */
a {
  color: #111827;
  text-decoration: none;
}
a:hover {
  opacity: 0.85;
}

/* Progress bar (top scroll bar) */
#progressBar {
  transform-origin: 0 50%;
}

/* Brain Lottie container (Time Part I) */
#brainLottie {
  background: #ffffff;
  border: 1px dashed var(--border-subtle);
  border-radius: 14px;
  overflow: hidden;
}

/* Metadata chips / bubbles (in case markup uses specific classes) */
.meta-chip {
  font-size: 0.75rem;
  font-weight: 500;
}

/* Recipe tags & pills in Lab */
.pill {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem 0.65rem;
  border-radius: 999px;
  border: 1px solid var(--chip-border);
  background: #f9fafb;
  color: var(--chip-text);
  font-size: 0.75rem;
}

/* Buttons (hooked up to indigo gradient in colors4.css) */
.btn-primary,
.btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.7rem 1.3rem;
  border-radius: 1rem;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.08s ease, box-shadow 0.15s ease;
}
.btn-primary:hover,
.btn-outline:hover {
  transform: translateY(-1px);
}

/* Respect reduced motion */
@media (prefers-reduced-motion: reduce) {
  .reveal {
    transition: none;
  }
}