/* Baroudi Consulting — design system (forked from EQALL site) */

/* Hidden attribute */
[hidden] { display: none !important; }

/* Skip link — visible only when keyboard-focused */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--ink);
  color: #fff;
  padding: 12px 16px;
  border-radius: 0 0 8px 0;
  z-index: 10000;
  font-weight: 500;
}
.skip-link:focus { left: 0; }

/* Static pillar panes */
.pillar-pane { display: none; }
.pillar-pane.active { display: block; }

/* FAQ <details> styling — replaces JSX accordion */
.faq-item {
  border-bottom: 1px solid var(--line);
  padding: 24px 0;
}
.faq-item[open] summary { margin-bottom: 14px; }
.faq-item summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: flex-start;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+";
  font-size: 24px; line-height: 1;
  color: var(--ink-3);
  flex-shrink: 0;
  transition: transform 0.25s;
}
.faq-item[open] summary::after { transform: rotate(45deg); }

/* Legal prose */
.legal-page { padding: 64px 0 96px; }
.legal-prose h2 { font-family: var(--font-display); font-size: 28px; margin: 0 0 16px; color: var(--ink); letter-spacing: -0.02em; }
.legal-prose section { margin-bottom: 48px; }
.legal-prose p { color: var(--ink-2); line-height: 1.65; margin: 0 0 14px; }
.legal-prose ul { margin: 8px 0 14px 22px; padding: 0; color: var(--ink-2); line-height: 1.65; }
.legal-prose li { margin-bottom: 8px; }
.legal-prose strong { font-weight: 600; }
.legal-prose .caps { font-weight: 600; text-transform: uppercase; font-size: 13px; letter-spacing: 0.03em; color: var(--ink); }
.legal-prose .end { margin-top: 20px; color: var(--ink); font-style: italic; line-height: 1.65; }

/* JSX-mount placeholder fade-in */
[data-mount] { min-height: 320px; }

/* Video page */
.video-section { padding: 64px 0 96px; background: var(--bg-elevated); }
.video-frame-wrap {
  position: relative;
  max-width: 1100px;
  margin: 0 auto;
  border-radius: 20px;
  overflow: hidden;
  background: #050B1F;
  box-shadow: 0 24px 60px -20px rgba(13,36,25,0.35), 0 8px 24px -8px rgba(13,36,25,0.18);
  border: 1px solid rgba(13,36,25,0.08);
}
.video-frame-wrap::before {
  content: "";
  display: block;
  padding-top: 56.25%;
}
.video-frame-wrap iframe, .video-frame-wrap video {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  border: 0; display: block;
  object-fit: cover;
}

/* Expand-to-fullscreen control (visible on the small player). */
.video-expand-btn, .video-close-btn {
  position: absolute;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px; height: 40px;
  padding: 0;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.2);
  background: rgba(13,36,25,0.55);
  color: #fff;
  cursor: pointer;
  z-index: 2;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  transition: background 0.15s ease, transform 0.15s ease, opacity 0.15s ease;
}
/* Expand sits bottom-right (YouTube-style fullscreen control). The close
   button stays top-right — that's the universal "exit overlay" affordance. */
.video-expand-btn { bottom: 12px; right: 12px; }
.video-close-btn { top: 12px; right: 12px; display: none; }
.video-expand-btn:hover, .video-close-btn:hover { background: rgba(13,36,25,0.85); transform: scale(1.05); }
.video-expand-btn:focus-visible, .video-close-btn:focus-visible {
  outline: 2px solid #9FE870;
  outline-offset: 2px;
}
/* Slightly larger tap target on small screens. */
@container (max-width: 640px) {
  .video-expand-btn, .video-close-btn { width: 44px; height: 44px; }
  .video-expand-btn { bottom: 10px; right: 10px; }
  .video-close-btn { top: 10px; right: 10px; }
}

/* Fullscreen state: CSS-promote the same .video-frame-wrap to fill the
   viewport. We override the 16:9 aspect-ratio pseudo-element and pin the
   wrapper with position:fixed. The iframe stays mounted (no re-load).
   Body gets overflow:hidden via JS to lock background scroll. */
body.video-is-fullscreen .video-frame-wrap {
  position: fixed;
  inset: 0;
  max-width: none;
  margin: 0;
  border-radius: 0;
  border: 0;
  box-shadow: none;
  z-index: 1100;
  background: #000;
}
body.video-is-fullscreen .video-frame-wrap::before { display: none; }
body.video-is-fullscreen .video-frame-wrap iframe {
  /* Letterbox the 16:9 bundle inside the viewport — contain, not cover,
     so we don't crop the explainer on portrait phones. */
  object-fit: contain;
  background: #000;
}
body.video-is-fullscreen .video-expand-btn { display: none; }
body.video-is-fullscreen .video-close-btn { display: inline-flex; }

.video-meta {
  max-width: 1100px; margin: 32px auto 0;
  display: flex; flex-wrap: wrap; align-items: center;
  justify-content: space-between; gap: 16px;
}
.video-meta .chips { display: flex; gap: 8px; flex-wrap: wrap; }
.video-meta .pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 12px; border-radius: 999px;
  background: rgba(13,36,25,0.06);
  color: var(--ink-2);
  font-family: var(--font-mono);
  font-size: 12px; letter-spacing: 0.02em;
}
.video-meta .pill .dot { width: 6px; height: 6px; border-radius: 50%; background: #9FE870; }
.video-meta .actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* Play modal */
.play-modal-overlay {
  position: fixed; inset: 0; z-index: 1000;
  background: rgba(13,36,25,0.5);
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
}
.play-modal {
  background: #fff;
  border-radius: 16px;
  max-width: 420px;
  width: 100%;
  padding: 32px;
  position: relative;
}
.play-modal-close {
  position: absolute; top: 12px; right: 12px;
  width: 32px; height: 32px;
  font-size: 24px; line-height: 1;
  color: var(--ink-3);
  background: none; border: none; cursor: pointer;
}

/* AEO answer block — large readable answer cards for AI ingestion */
.aeo-answer {
  background: linear-gradient(180deg, rgba(46,187,124,0.04), transparent);
  border: 1px solid var(--line);
  border-left: 3px solid var(--brand-blue-deep);
  border-radius: 12px;
  padding: 20px 24px;
  margin: 16px 0;
}
.aeo-answer p:first-child { margin-top: 0; }
.aeo-answer p:last-child { margin-bottom: 0; }

/* Mounted chat fallback */
.chat-fallback {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 24px;
  background: var(--bg-elevated);
}
.chat-fallback h3 { margin: 0 0 12px; font-size: 18px; }
.chat-fallback ul { padding-left: 20px; color: var(--ink-2); }
