/* ==========================================================================
   Our BETTER Project (OBP) — Documentary Editorial Stylesheet
   Aesthetic: High-Impact Editorial · Cinematic Space · Human Dignity
   ========================================================================== */

:root {
  --bg-deep: #05070b;
  --bg-surface: #0a0e17;
  --bg-card: rgba(14, 20, 32, 0.65);
  
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --text-dim: #8190a5;
  
  --gold: #d4af37;
  --gold-warm: #fef08a;
  --gold-dim: rgba(212, 175, 55, 0.25);
  
  --border-hairline: rgba(255, 255, 255, 0.08);
  --border-gold-subtle: rgba(212, 175, 55, 0.3);

  --font-heading: 'Montserrat', -apple-system, sans-serif;
  --font-body: 'Plus Jakarta Sans', -apple-system, sans-serif;
  --font-serif: 'Cinzel', Georgia, serif;
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
  background-color: var(--bg-deep);
  color: var(--text-main);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
}

body {
  line-height: 1.7;
  overflow-x: hidden;
}

/* Accessibility Focus */
a:focus-visible, button:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
}

img, video {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
  transition: all 0.2s ease;
}

/* Editorial Container & Spacing */
.editorial-container {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 2rem;
}

.editorial-section {
  padding: 9rem 0;
  position: relative;
}

.editorial-section-sm {
  padding: 5rem 0;
}

.divider-line {
  width: 100%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border-hairline), transparent);
}

#main-content {
  position: relative;
}

/* Ambient Vertical Hanging Chain Backdrop - Full Image Reveal & Dynamic Scroll */
.story-chain-parallax-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: 0;
  pointer-events: none;
  background: url('../assets/images/user_vertical_chain_master.jpg') no-repeat center top;
  background-size: cover;
  opacity: 0;
  filter: contrast(125%) brightness(1.05);
  mix-blend-mode: screen;
  transition: opacity 0.4s ease;
  will-change: background-position, opacity;
}

.story-chain-parallax-backdrop.visible {
  opacity: 0.22;
}

.editorial-container, .grant-editorial-box, .creed-monolith {
  position: relative;
  z-index: 2;
}

/* ==========================================================================
   Minimalist Documentary Header
   ========================================================================== */
.editorial-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  padding: 1.5rem 0;
  background: linear-gradient(180deg, rgba(5, 7, 11, 0.9) 0%, rgba(5, 7, 11, 0) 100%);
  transition: background 0.3s ease;
}

.editorial-header.scrolled {
  background: rgba(5, 7, 11, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-hairline);
  padding: 1rem 0;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand-monogram {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.brand-monogram img {
  height: 42px !important;
  max-height: 42px !important;
  width: 42px !important;
  max-width: 42px !important;
  object-fit: contain;
  border-radius: 8px;
  display: block;
}

.brand-monogram span {
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: #fff;
}

.editorial-nav {
  display: flex;
  align-items: center;
  gap: 2.5rem;
}

.editorial-nav a {
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  text-transform: uppercase;
}

.editorial-nav a:hover {
  color: #fff;
}

.header-cta {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.btn-editorial-support {
  padding: 0.6rem 1.4rem;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: #000;
  background: var(--gold);
  border-radius: 6px;
  transition: all 0.2s ease;
}

.btn-editorial-support:hover {
  background: #fff;
  transform: translateY(-1px);
}

.btn-editorial-meeting {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--gold-warm);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.btn-editorial-meeting:hover {
  color: #fff;
}

/* ==========================================================================
   Hero: Cinematic Film Poster Aesthetic
   ========================================================================== */
.hero-editorial {
  min-height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  padding: 8rem 0 5rem;
  background: #05070b;
  overflow: hidden;
}

.hero-backdrop-media {
  position: absolute;
  inset: 0;
  z-index: 0;
  opacity: 0.88;
  filter: contrast(125%) brightness(1.05);
}

.hero-backdrop-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 40%;
}

.hero-backdrop-gradient {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: radial-gradient(circle at 75% 45%, rgba(5, 7, 11, 0.05) 0%, rgba(5, 7, 11, 0.55) 75%),
              linear-gradient(180deg, rgba(5, 7, 11, 0.25) 0%, rgba(5, 7, 11, 0.92) 100%);
}

.hero-editorial-content {
  position: relative;
  z-index: 2;
  max-width: 900px;
}

.hero-eyebrow {
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--gold);
  margin-bottom: 1.25rem;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.95);
}

.hero-headline {
  font-family: 'Black Ops One', 'Saira Stencil One', 'Allerta Stencil', Impact, sans-serif;
  font-size: clamp(3.2rem, 7.5vw, 5.6rem);
  font-weight: 900;
  line-height: 1.02;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: url('../assets/images/prison_stencil_grunge_uniform.jpg') repeat,
              linear-gradient(180deg, #ffffff 0%, #f4efe6 50%, #e2d7c7 100%);
  background-size: 500px auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  -webkit-text-stroke: 0.5px rgba(255, 255, 255, 0.25);
  filter: drop-shadow(0 8px 25px rgba(0, 0, 0, 1)) drop-shadow(0 2px 8px rgba(0, 0, 0, 0.95));
  margin-bottom: 1.8rem;
}

.hero-standfirst {
  font-size: 1.25rem;
  font-weight: 500;
  line-height: 1.6;
  color: #e2e8f0;
  max-width: 680px;
  margin-bottom: 2.8rem;
  text-shadow: 0 3px 18px rgba(0, 0, 0, 0.95), 0 1px 6px rgba(0, 0, 0, 0.8);
}

.hero-action-line {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.btn-scroll-film {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: 1rem;
  font-weight: 700;
  color: #fff;
  border-bottom: 1px solid var(--gold);
  padding-bottom: 4px;
}

.btn-scroll-film span {
  transition: transform 0.2s ease;
}

.btn-scroll-film:hover span {
  transform: translateY(3px);
}

/* ==========================================================================
   Editorial Chapter Header
   ========================================================================== */
.chapter-number {
  font-family: var(--font-mono, monospace);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--gold);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-bottom: 0.8rem;
  display: block;
}

.chapter-title {
  font-family: var(--font-heading);
  font-size: clamp(2.2rem, 4vw, 3.4rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: #fff;
  margin-bottom: 1.5rem;
}

.chapter-lead {
  font-size: 1.2rem;
  line-height: 1.7;
  color: #cbd5e1;
  max-width: 780px;
  margin-bottom: 3.5rem;
}

/* ==========================================================================
   01 — The Movement (Asymmetric Narrative)
   ========================================================================== */
.editorial-asymmetric-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 5rem;
  align-items: center;
}

.prose-block p {
  font-size: 1.08rem;
  line-height: 1.75;
  color: #94a3b8;
  margin-bottom: 1.8rem;
}

.prose-block p strong {
  color: #fff;
}

.editorial-callout-quote {
  font-family: var(--font-heading);
  font-size: clamp(1.4rem, 2.5vw, 1.85rem);
  font-weight: 800;
  line-height: 1.35;
  color: var(--gold-warm);
  border-left: 2px solid var(--gold);
  padding-left: 1.8rem;
  margin: 3rem 0;
}

.full-aspect-frame {
  border-radius: 12px;
  overflow: hidden;
  position: relative;
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.7);
}

.full-aspect-frame img {
  width: 100%;
  height: 520px;
  object-fit: cover;
  filter: contrast(105%);
}

.frame-caption {
  font-size: 0.85rem;
  color: var(--text-dim);
  padding: 0.9rem 0;
  border-bottom: 1px solid var(--border-hairline);
}

/* ==========================================================================
   02 — The Work (Film Showcase & Lean Progression)
   ========================================================================== */
.cinematic-film-stage {
  margin: 3rem 0 5rem;
  border-radius: 16px;
  overflow: hidden;
  background: #000;
  border: 1px solid var(--border-hairline);
  box-shadow: 0 25px 80px rgba(0, 0, 0, 0.8);
}

.film-selector-bar {
  display: flex;
  border-bottom: 1px solid var(--border-hairline);
  background: rgba(10, 14, 23, 0.9);
}

.film-select-btn {
  flex: 1;
  padding: 1.1rem 1.5rem;
  font-family: var(--font-heading);
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text-muted);
  background: transparent;
  text-align: left;
  border-bottom: 2px solid transparent;
  transition: all 0.2s ease;
}

.film-select-btn.active {
  color: #fff;
  border-bottom-color: var(--gold);
  background: rgba(212, 175, 55, 0.05);
}

.film-player-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
}

.film-player-wrapper video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Minimalist Editorial 4-Phase Track */
.phase-editorial-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
  margin-top: 3.5rem;
  border-top: 1px solid var(--border-hairline);
  padding-top: 2.5rem;
}

.phase-editorial-col {
  display: flex;
  flex-direction: column;
}

.phase-editorial-num {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  font-weight: 900;
  color: var(--gold);
  margin-bottom: 0.5rem;
}

.phase-editorial-title {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 0.6rem;
}

.phase-editorial-desc {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.55;
}

/* ==========================================================================
   03 — Made With Purpose (Crochet Gallery Feature)
   ========================================================================== */
.crochet-editorial-layout {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 4.5rem;
  align-items: center;
}

.crochet-photo-mosaic {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
}

.mosaic-item {
  border-radius: 12px;
  overflow: hidden;
  background: var(--bg-surface);
  border: 1px solid var(--border-hairline);
}

.mosaic-item img {
  width: 100%;
  height: 240px;
  object-fit: cover;
}

/* ==========================================================================
   04 — Transformation Beyond The Gate (Family & Reentry)
   ========================================================================== */
.reentry-editorial-layout {
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  gap: 4.5rem;
  align-items: center;
  margin: 3rem 0;
}

.reentry-portrait-frame {
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--border-hairline);
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.7);
  background: var(--bg-surface);
}

.reentry-portrait-frame img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: contain;
}

.reentry-text-col h3 {
  font-family: var(--font-heading);
  font-size: 2rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 1.25rem;
  line-height: 1.2;
}

.reentry-text-col p {
  font-size: 1.08rem;
  line-height: 1.75;
  color: #94a3b8;
  margin-bottom: 1.5rem;
}

.reentry-text-col p strong {
  color: #fff;
}

.reentry-pillars {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  margin-top: 1.8rem;
  border-top: 1px solid var(--border-hairline);
  padding-top: 1.8rem;
}

.reentry-pillar-item {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.95rem;
  color: #cbd5e1;
}

.reentry-pillar-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gold);
}

/* ==========================================================================
   05 — The Proof (CDCR RIGHT 3.0)
   ========================================================================== */
.grant-editorial-box {
  border-left: 2px solid var(--gold);
  padding: 2.5rem 0 2.5rem 3rem;
  margin: 3rem 0;
  max-width: 920px;
}

.grant-editorial-box h3 {
  font-family: var(--font-heading);
  font-size: 1.85rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 1rem;
}

.grant-editorial-box p {
  font-size: 1.1rem;
  line-height: 1.75;
  color: #94a3b8;
  margin-bottom: 1.5rem;
}

/* ==========================================================================
   06 — The Inscription (The Chainbreakers Creed)
   ========================================================================== */
.creed-monolith {
  max-width: 880px;
  margin: 4rem auto;
  padding: 4.5rem 3.5rem;
  text-align: center;
  background: radial-gradient(circle at 50% 50%, rgba(212, 175, 55, 0.06) 0%, rgba(10, 14, 23, 0.95) 100%);
  border: 1px solid var(--border-gold-subtle);
  border-radius: 16px;
}

.creed-symbol {
  font-size: 1.6rem;
  color: var(--gold);
  margin-bottom: 1.5rem;
}

.creed-statement {
  font-family: var(--font-heading);
  font-size: clamp(1.25rem, 2.2vw, 1.65rem);
  font-weight: 700;
  line-height: 1.65;
  color: #f1f5f9;
  font-style: italic;
}

/* ==========================================================================
   07 — Action & Stewardship
   ========================================================================== */
.action-editorial-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2.5rem;
  margin-top: 3rem;
  border-top: 1px solid var(--border-hairline);
  padding-top: 3.5rem;
}

.action-editorial-item h4 {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 0.75rem;
}

.action-editorial-item p {
  font-size: 0.92rem;
  color: var(--text-muted);
  line-height: 1.65;
  margin-bottom: 1.5rem;
}

.action-editorial-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--gold-warm);
  border-bottom: 1px solid var(--gold-dim);
  padding-bottom: 2px;
}

.action-editorial-link:hover {
  color: #fff;
  border-bottom-color: #fff;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.editorial-footer {
  padding: 5rem 0 3rem;
  border-top: 1px solid var(--border-hairline);
  background: #030407;
}

.footer-top-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 3rem;
}

.footer-brand h5 {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 0.5rem;
}

.footer-brand p {
  font-size: 0.85rem;
  color: var(--text-dim);
  max-width: 420px;
}

.footer-nav-list {
  display: flex;
  gap: 2rem;
  list-style: none;
}

.footer-nav-list a {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.footer-nav-list a:hover {
  color: #fff;
}

.footer-bottom-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.78rem;
  color: var(--text-dim);
  border-top: 1px solid var(--border-hairline);
  padding-top: 2rem;
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1024px) {
  .editorial-asymmetric-grid, .crochet-editorial-layout {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
  .phase-editorial-strip {
    grid-template-columns: repeat(2, 1fr);
  }
  .action-editorial-row {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
}

@media (max-width: 768px) {
  .editorial-nav, .btn-editorial-meeting {
    display: none;
  }
  .hero-headline {
    font-size: 2.6rem;
  }
  .phase-editorial-strip {
    grid-template-columns: 1fr;
  }
  .crochet-photo-mosaic {
    grid-template-columns: 1fr;
  }
  .reentry-hero-banner {
    height: 420px;
  }
  .reentry-hero-overlay {
    padding: 1.5rem;
  }
  .creed-monolith {
    padding: 2.5rem 1.5rem;
  }
  .footer-top-row {
    flex-direction: column;
    gap: 2rem;
  }
  .footer-bottom-row {
    flex-direction: column;
    gap: 0.8rem;
  }
}

/* ==========================================================================
   High-Fidelity Document & Photo Lightbox Modal
   ========================================================================== */
.lightbox-trigger {
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.lightbox-trigger:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.6);
}

.lightbox-trigger::after {
  content: '🔍 Click to expand full image';
  position: absolute;
  bottom: 12px;
  right: 12px;
  background: rgba(5, 7, 11, 0.88);
  backdrop-filter: blur(8px);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 5px 12px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.25s ease, transform 0.25s ease;
  pointer-events: none;
  z-index: 5;
}

.lightbox-trigger:hover::after {
  opacity: 1;
  transform: translateY(0);
}

.editorial-lightbox {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}

.lightbox-backdrop {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(5, 7, 11, 0.94);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.lightbox-dialog {
  position: relative;
  z-index: 2;
  max-width: 95vw;
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  background: #0d1117;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 12px;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.8);
  overflow: hidden;
  animation: lightboxPop 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes lightboxPop {
  from { opacity: 0; transform: scale(0.95); }
  to { opacity: 1; transform: scale(1); }
}

.lightbox-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.85rem 1.25rem;
  background: #161b22;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  gap: 1rem;
}

.lightbox-caption {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-bright);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lightbox-actions {
  display: flex;
  gap: 8px;
  align-items: center;
}

.lightbox-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: var(--text-bright);
  font-size: 0.8rem;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 6px;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  transition: all 0.2s ease;
}

.lightbox-btn:hover {
  background: var(--gold-accent);
  color: #000;
  border-color: var(--gold-accent);
}

.lightbox-body {
  padding: 1rem;
  overflow: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  max-height: calc(92vh - 60px);
}

.lightbox-body img {
  max-width: 100%;
  max-height: calc(90vh - 80px);
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 4px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
}

.expandable-brochure-card {
  margin-top: 2.5rem;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-hairline);
  border-radius: 8px;
  padding: 1.5rem;
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 2rem;
  align-items: center;
}

.expandable-brochure-card img {
  width: 100%;
  height: auto;
  border-radius: 4px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.5);
}

@media (max-width: 768px) {
  .expandable-brochure-card {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
}
