/* =============================================
   PYR — Project Youth Rising
   2026 Redesign — Dark theme, ember/teal/offwhite
   ============================================= */

/* --- Reset & Base --- */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  /* Brand Colors — Ember Orange + Teal + Matte Off-White */
  --bg-primary: #0A0A0A;
  --bg-secondary: #111111;
  --bg-card: #161616;
  --bg-nav: rgba(30, 30, 30, 0.85);
  --ember: #E8622C;
  --ember-light: #F07A4A;
  --ember-dark: #C94E1C;
  --teal: #2EC4B6;
  --teal-light: #4DD8CC;
  --teal-dark: #1FA99C;
  --offwhite: #F0EDE8;
  --offwhite-soft: rgba(240, 237, 232, 0.85);
  --offwhite-muted: rgba(240, 237, 232, 0.5);
  --offwhite-faint: rgba(240, 237, 232, 0.25);
  --border: rgba(240, 237, 232, 0.08);

  /* Legacy aliases */
  --white: var(--offwhite);
  --white-soft: var(--offwhite-soft);
  --white-muted: var(--offwhite-muted);
  --white-faint: var(--offwhite-faint);

  /* Spacing — tighter than before */
  --section-pad: clamp(72px, 9vw, 120px);
  --section-pad-sm: clamp(48px, 6vw, 80px);

  /* Transitions */
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --transition: 0.4s var(--ease);
}

html { scroll-behavior: smooth; overflow-x: hidden; }

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--white);
  background: var(--bg-primary);
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

.container { max-width: 1200px; margin: 0 auto; padding: 0 clamp(24px, 5vw, 64px); }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }

::selection { background: var(--ember); color: var(--offwhite); }

/* --- Scroll Reveal Animations --- */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* --- Typography --- */
h1, h2, h3, h4 {
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.03em;
}
h1 { font-size: clamp(3rem, 8vw, 6rem); font-weight: 800; }
h2 { font-size: clamp(2rem, 5vw, 3.5rem); }
h3 { font-size: clamp(1.25rem, 2vw, 1.6rem); font-weight: 600; }

.accent { color: var(--ember); }
.accent-teal { color: var(--teal); }

/* --- Navigation (Floating Pill) --- */
.site-header {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1000;
}
.nav-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-nav);
  backdrop-filter: blur(20px);
  border: 1px solid var(--border);
  border-radius: 100px;
  padding: 8px 12px;
}
.nav-logo {
  display: flex;
  align-items: center;
  padding: 0 12px;
}
.nav-logo span {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: 4px;
  color: var(--ember);
}
.nav-link {
  padding: 8px 20px;
  border-radius: 100px;
  font-size: 14px;
  font-weight: 500;
  color: var(--white-muted);
  transition: all var(--transition);
}
.nav-link:hover, .nav-link.active {
  color: var(--white);
  background: rgba(255, 255, 255, 0.08);
}

/* --- Hero --- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: var(--bg-primary);
  overflow: hidden;
}
/* Subtle grid texture */
.hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(240, 237, 232, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(240, 237, 232, 0.03) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse at 50% 50%, black 30%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse at 50% 50%, black 30%, transparent 70%);
  pointer-events: none;
}
/* Stronger ambient glow */
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 30% 50%, rgba(232, 98, 44, 0.18) 0%, transparent 50%),
    radial-gradient(ellipse at 70% 40%, rgba(46, 196, 182, 0.12) 0%, transparent 55%),
    radial-gradient(ellipse at 50% 100%, rgba(232, 98, 44, 0.06) 0%, transparent 40%);
  pointer-events: none;
}
.hero-content {
  position: relative;
  z-index: 1;
  max-width: 900px;
  padding: 0 24px;
}
.hero h1 { margin-bottom: 24px; }
.hero-sub {
  font-size: clamp(1.1rem, 1.8vw, 1.35rem);
  color: var(--white-soft);
  max-width: 600px;
  margin: 0 auto 48px;
  line-height: 1.7;
}
.hero-cta {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 32px;
  border-radius: 100px;
  font-weight: 600;
  font-size: 15px;
  transition: all var(--transition);
  cursor: pointer;
  border: none;
  font-family: inherit;
}
.btn-primary {
  background: var(--ember);
  color: var(--offwhite);
}
.btn-primary:hover {
  background: var(--ember-light);
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(232, 98, 44, 0.35);
}
.btn-outline {
  background: transparent;
  color: var(--white);
  border: 1px solid var(--white-faint);
}
.btn-outline:hover {
  border-color: var(--white-soft);
  background: rgba(255, 255, 255, 0.05);
}

/* --- Scroll Indicator --- */
.scroll-indicator {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: var(--white-muted);
  font-size: 14px;
  font-weight: 500;
  animation: bounce 2s ease-in-out infinite;
}
@keyframes bounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(8px); }
}

/* --- Section: Values --- */
.section-feature {
  position: relative;
  padding: var(--section-pad) 0;
  background: var(--bg-primary);
  overflow: hidden;
}
.section-feature::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 50%;
  height: 100%;
  background: linear-gradient(135deg, rgba(232, 98, 44, 0.07) 0%, transparent 60%);
  pointer-events: none;
}
.section-feature h2 {
  margin-bottom: 48px;
  max-width: 700px;
}

/* --- Card Grid --- */
.card-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 40px 32px;
  transition: all var(--transition);
  opacity: 0;
  transform: translateY(24px);
}
.reveal.visible .card {
  opacity: 1;
  transform: translateY(0);
}
.card:hover {
  border-color: var(--teal);
  transform: translateY(-4px);
}
.card-number {
  font-size: 48px;
  font-weight: 800;
  color: var(--teal);
  line-height: 1;
  margin-bottom: 16px;
}
.card h3 { margin-bottom: 12px; }
.card p {
  color: var(--white-muted);
  font-size: 15px;
  line-height: 1.7;
}

/* --- Section: Programs --- */
.section-programs {
  padding: var(--section-pad) 0;
  background: var(--bg-secondary);
}
.section-programs h2 {
  margin-bottom: 48px;
}
.program-row {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 32px;
  padding: 36px 0;
  border-top: 1px solid var(--border);
  align-items: start;
}
.program-row:last-child { border-bottom: 1px solid var(--border); }
.program-number {
  font-size: 14px;
  font-weight: 700;
  color: var(--teal);
  letter-spacing: 2px;
  padding-top: 4px;
}
.program-title {
  font-size: clamp(1.5rem, 2.5vw, 2rem);
  font-weight: 700;
  margin-bottom: 8px;
  transition: color var(--transition);
}
.program-row:hover .program-title { color: var(--ember); }
.program-desc {
  color: var(--white-muted);
  font-size: 15px;
  line-height: 1.7;
  max-width: 500px;
}

/* --- Section: Quote --- */
.section-quote {
  position: relative;
  padding: var(--section-pad-sm) 0;
  background: var(--bg-primary);
  text-align: center;
  overflow: hidden;
}
.section-quote::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 50%, rgba(46, 196, 182, 0.06) 0%, transparent 60%);
  pointer-events: none;
}
.section-quote .container {
  position: relative;
}
.quote-decoration {
  font-size: clamp(4rem, 8vw, 7rem);
  font-weight: 800;
  color: var(--teal);
  line-height: 0.6;
  margin-bottom: 16px;
  opacity: 0.6;
}
.quote-text {
  font-size: clamp(1.4rem, 3vw, 2.2rem);
  font-style: italic;
  font-weight: 400;
  line-height: 1.6;
  max-width: 700px;
  margin: 0 auto 24px;
  color: var(--offwhite);
}
.quote-line {
  width: 48px;
  height: 2px;
  background: var(--ember);
  margin: 0 auto 16px;
}
.quote-attr {
  font-size: 14px;
  color: var(--white-muted);
  text-transform: uppercase;
  letter-spacing: 2px;
  font-weight: 500;
}

/* --- Section: CTA / Signup --- */
.section-cta {
  position: relative;
  padding: var(--section-pad) 0;
  text-align: center;
  background: var(--bg-primary);
  overflow: hidden;
}
.section-cta::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 80%, rgba(232, 98, 44, 0.12) 0%, transparent 60%);
}
.section-cta .container { position: relative; }
.section-cta h2 {
  margin-bottom: 16px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}
.section-cta p {
  color: var(--white-muted);
  font-size: 1.1rem;
  max-width: 480px;
  margin: 0 auto 32px;
}
.signup-form {
  display: flex;
  gap: 12px;
  max-width: 440px;
  margin: 0 auto 16px;
  justify-content: center;
}
.signup-form input {
  flex: 1;
  padding: 14px 20px;
  border-radius: 100px;
  border: 1px solid var(--border);
  background: var(--bg-card);
  color: var(--offwhite);
  font-family: inherit;
  font-size: 15px;
  outline: none;
  transition: border-color var(--transition);
}
.signup-form input::placeholder {
  color: var(--white-muted);
}
.signup-form input:focus {
  border-color: var(--ember);
}
.signup-form .btn {
  white-space: nowrap;
  flex-shrink: 0;
}
.signup-note {
  font-size: 13px;
  color: var(--white-muted);
  margin: 0 auto;
  max-width: 400px;
}

/* --- Footer --- */
.site-footer {
  padding: 56px 0 28px;
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}
.footer-brand .logo-text {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: 4px;
  color: var(--ember);
  margin-bottom: 12px;
}
.footer-tagline {
  color: var(--white-muted);
  font-size: 14px;
  line-height: 1.7;
  max-width: 260px;
}
.footer-location {
  color: var(--teal);
  font-size: 13px;
  font-weight: 500;
  margin-top: 12px;
  letter-spacing: 0.5px;
}
.footer-col h4 {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--white-muted);
  margin-bottom: 20px;
}
.footer-col a {
  display: block;
  font-size: 14px;
  color: var(--white-muted);
  margin-bottom: 12px;
  transition: color var(--transition);
}
.footer-col a:hover { color: var(--ember); }
.footer-bottom {
  padding-top: 20px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  color: var(--white-muted);
}

/* --- Mobile Menu Button --- */
.mobile-menu-btn {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px 12px;
  background: none;
  border: none;
  cursor: pointer;
}
.mobile-menu-btn span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--white);
  border-radius: 2px;
  transition: all 0.3s var(--ease);
}
.mobile-menu-btn.open span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.mobile-menu-btn.open span:nth-child(2) { opacity: 0; }
.mobile-menu-btn.open span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* --- Mobile Nav Overlay --- */
.mobile-nav-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 10, 10, 0.97);
  backdrop-filter: blur(20px);
  z-index: 999;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s var(--ease);
}
.mobile-nav-overlay.open {
  opacity: 1;
  pointer-events: all;
}
.mobile-nav {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
}
.mobile-nav a {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--white-soft);
  transition: color var(--transition);
}
.mobile-nav a:hover,
.mobile-nav a.active { color: var(--ember); }

/* --- Responsive --- */
@media (max-width: 900px) {
  .card-grid { grid-template-columns: 1fr; }
  .program-row { grid-template-columns: 1fr; gap: 8px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
  .nav-pill .nav-link { display: none; }
  .mobile-menu-btn { display: flex; }
  .nav-pill { padding: 8px 8px 8px 12px; }

  .hero { min-height: 100svh; padding: 0 16px; }
  .hero h1 { font-size: clamp(2.2rem, 10vw, 3.5rem); }
  .hero-sub { font-size: 1rem; margin-bottom: 32px; }
  .hero-cta { flex-direction: column; align-items: center; gap: 12px; }
  .hero-cta .btn { width: 100%; max-width: 280px; justify-content: center; }

  .section-feature h2,
  .section-programs h2,
  .section-cta h2 { font-size: clamp(1.6rem, 6vw, 2.2rem); margin-bottom: 32px; }

  .card { padding: 28px 24px; }
  .card-number { font-size: 36px; }

  .program-title { font-size: 1.3rem; }
  .program-desc { font-size: 14px; }

  .quote-text { font-size: clamp(1.1rem, 4vw, 1.6rem); }
  .quote-decoration { font-size: clamp(3rem, 6vw, 4rem); }

  .section-feature,
  .section-programs,
  .section-quote,
  .section-cta { padding: clamp(48px, 8vw, 80px) 0; }

  .signup-form { flex-direction: column; align-items: center; }
  .signup-form input { width: 100%; max-width: 300px; }

  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .footer-bottom { flex-direction: column; gap: 12px; text-align: center; }

  .btn { padding: 12px 28px; font-size: 14px; }
  .scroll-indicator { bottom: 24px; font-size: 13px; }
}
