/* ============================================================
   DIVORCEOLOGY DAD | Stylesheet
   Dark editorial design, mobile-first, performance-focused
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Cormorant:ital,wght@0,300;0,400;0,500;0,600;0,700;1,400;1,500&family=Outfit:wght@300;400;500;600;700&display=swap');

/* --- Design Tokens --- */
:root {
  --bg-deep: #0a0c10;
  --bg-dark: #0f1218;
  --bg-section: #141820;
  --bg-card: #1a1f2a;
  --bg-card-hover: #212736;
  --bg-warm: #f0ebe2;
  --bg-warm-alt: #e8e1d4;

  --accent: #c08840;
  --accent-hover: #d49a52;
  --accent-muted: rgba(192, 136, 64, 0.15);
  --accent-glow: rgba(192, 136, 64, 0.3);

  --text-light: #ede9e0;
  --text-light-secondary: #9ea5b4;
  --text-dark: #1a1a1a;
  --text-dark-secondary: #5a5a5a;

  --border-subtle: rgba(255, 255, 255, 0.06);
  --border-accent: rgba(192, 136, 64, 0.25);

  --ff-display: 'Cormorant', Georgia, serif;
  --ff-body: 'Outfit', system-ui, sans-serif;

  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.76, 0, 0.24, 1);

  --container: min(1200px, 90vw);
  --container-narrow: min(900px, 90vw);
}

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

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--ff-body);
  font-weight: 400;
  line-height: 1.6;
  color: var(--text-light);
  background: var(--bg-deep);
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { text-decoration: none; color: inherit; }
button { font: inherit; cursor: pointer; border: none; background: none; }

/* --- Noise Overlay (atmosphere) --- */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 9999;
  pointer-events: none;
  opacity: 0.025;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 200px;
}

/* --- Typography --- */
h1, h2, h3, h4 {
  font-family: var(--ff-display);
  font-weight: 500;
  line-height: 1.1;
  letter-spacing: -0.01em;
}

h1 { font-size: clamp(2.8rem, 6vw, 5.5rem); }
h2 { font-size: clamp(2rem, 4vw, 3.5rem); }
h3 { font-size: clamp(1.4rem, 2.5vw, 1.8rem); }

.section-label {
  font-family: var(--ff-body);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 1.5rem;
}

.section-label::before {
  content: '';
  width: 32px;
  height: 1px;
  background: var(--accent);
}

/* --- Navigation --- */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 1.25rem 0;
  transition: all 0.4s var(--ease-out);
}

.nav.scrolled {
  background: rgba(10, 12, 16, 0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-subtle);
  padding: 0.75rem 0;
}

.nav-inner {
  width: var(--container);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  font-family: var(--ff-display);
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--text-light);
  letter-spacing: -0.02em;
}

.nav-logo span {
  color: var(--accent);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2rem;
  list-style: none;
}

.nav-links a {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-light-secondary);
  transition: color 0.3s;
  letter-spacing: 0.02em;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text-light);
}

.nav-cta {
  font-size: 0.8rem !important;
  font-weight: 600 !important;
  color: var(--bg-deep) !important;
  background: var(--accent);
  padding: 0.5rem 1.25rem;
  border-radius: 4px;
  transition: background 0.3s, transform 0.2s !important;
}

.nav-cta:hover {
  background: var(--accent-hover);
  transform: translateY(-1px);
}

/* Mobile menu toggle */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 4px;
}

.nav-toggle span {
  width: 24px;
  height: 2px;
  background: var(--text-light);
  transition: all 0.3s var(--ease-out);
  transform-origin: center;
}

.nav-toggle.open span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* --- Hero --- */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  padding: 8rem 0 6rem;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 70% 40%, rgba(192, 136, 64, 0.06) 0%, transparent 60%),
    radial-gradient(ellipse 60% 80% at 20% 80%, rgba(30, 40, 70, 0.3) 0%, transparent 50%);
  pointer-events: none;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 200px;
  background: linear-gradient(to top, var(--bg-deep), transparent);
  pointer-events: none;
}

.hero-inner {
  width: var(--container);
  margin: 0 auto;
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr;
  gap: 3rem;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--accent-muted);
  border: 1px solid var(--border-accent);
  padding: 0.4rem 1rem;
  border-radius: 100px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  width: fit-content;
  margin-bottom: 1.5rem;
}

.hero-badge::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  animation: pulse-dot 2s infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

.hero h1 {
  margin-bottom: 1.5rem;
  max-width: 800px;
}

.hero h1 em {
  font-style: italic;
  color: var(--accent);
}

.hero-sub {
  font-size: clamp(1rem, 1.5vw, 1.2rem);
  color: var(--text-light-secondary);
  max-width: 560px;
  line-height: 1.7;
  margin-bottom: 2.5rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--ff-body);
  font-size: 0.9rem;
  font-weight: 600;
  padding: 0.9rem 2rem;
  border-radius: 4px;
  transition: all 0.3s var(--ease-out);
  letter-spacing: 0.02em;
}

.btn-primary {
  background: var(--accent);
  color: var(--bg-deep);
}

.btn-primary:hover {
  background: var(--accent-hover);
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(192, 136, 64, 0.25);
}

.btn-outline {
  border: 1px solid var(--border-accent);
  color: var(--accent);
  background: transparent;
}

.btn-outline:hover {
  background: var(--accent-muted);
  border-color: var(--accent);
  transform: translateY(-2px);
}

.btn svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

/* --- Divider line --- */
.divider {
  width: var(--container);
  margin: 0 auto;
  height: 1px;
  background: linear-gradient(to right, transparent, var(--border-subtle) 20%, var(--border-subtle) 80%, transparent);
}

/* --- About Section --- */
.about {
  padding: 7rem 0;
  background: var(--bg-dark);
  position: relative;
}

.about-inner {
  width: var(--container);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5rem;
  align-items: center;
}

.about-text h2 {
  margin-bottom: 1.5rem;
}

.about-text p {
  color: var(--text-light-secondary);
  margin-bottom: 1.25rem;
  line-height: 1.8;
}

.about-text p strong {
  color: var(--text-light);
  font-weight: 600;
}

.about-photo {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

.keegan-portrait {
  width: 100%;
  max-width: 420px;
  border-radius: 10px;
  border: 2px solid var(--border-accent);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4), 0 0 80px rgba(192, 136, 64, 0.08);
  transition: all 0.5s var(--ease-out);
}

.keegan-portrait:hover {
  transform: translateY(-4px);
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.5), 0 0 100px rgba(192, 136, 64, 0.12);
}

.about-name-card {
  text-align: center;
}

.about-name-card h3 {
  margin-bottom: 0.3rem;
}

.about-name-card .host-role,
.host-role {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

/* --- Pillars/Services --- */
.pillars {
  padding: 7rem 0;
  background: var(--bg-deep);
  position: relative;
}

.pillars-inner {
  width: var(--container);
  margin: 0 auto;
}

.pillars-header {
  text-align: center;
  max-width: 600px;
  margin: 0 auto 4rem;
}

.pillars-header .section-label {
  justify-content: center;
}

.pillars-header .section-label::before { display: none; }

.pillars-header p {
  color: var(--text-light-secondary);
  margin-top: 1rem;
  line-height: 1.7;
}

.pillars-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.pillar-card {
  background: var(--bg-section);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 2.5rem 2rem;
  transition: all 0.4s var(--ease-out);
  position: relative;
  overflow: hidden;
}

.pillar-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(to right, var(--accent), transparent);
  opacity: 0;
  transition: opacity 0.4s;
}

.pillar-card:hover {
  border-color: var(--border-accent);
  transform: translateY(-4px);
  box-shadow: 0 16px 50px rgba(0, 0, 0, 0.3);
}

.pillar-card:hover::before { opacity: 1; }

.pillar-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-muted);
  border-radius: 8px;
  margin-bottom: 1.5rem;
  color: var(--accent);
}

.pillar-icon svg {
  width: 24px;
  height: 24px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.pillar-card h3 {
  margin-bottom: 0.75rem;
}

.pillar-card p {
  color: var(--text-light-secondary);
  font-size: 0.95rem;
  line-height: 1.7;
}

/* --- Featured Videos --- */
.featured-videos {
  padding: 7rem 0;
  background: var(--bg-dark);
}

.featured-videos-inner {
  width: var(--container);
  margin: 0 auto;
}

.featured-videos-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 3rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.featured-videos-header h2 {
  max-width: 500px;
}

.see-all {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--accent);
  display: flex;
  align-items: center;
  gap: 6px;
  transition: gap 0.3s var(--ease-out);
}

.see-all:hover {
  gap: 12px;
}

.see-all svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
}

.video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(340px, 100%), 1fr));
  gap: 1.5rem;
}

.video-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  overflow: hidden;
  transition: all 0.4s var(--ease-out);
  cursor: pointer;
}

.video-card:hover {
  border-color: var(--border-accent);
  transform: translateY(-4px);
  box-shadow: 0 16px 50px rgba(0, 0, 0, 0.3);
}

.video-thumb {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--bg-section);
}

.video-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s var(--ease-out);
}

.video-card:hover .video-thumb img {
  transform: scale(1.05);
}

.video-thumb .play-btn {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 64px;
  height: 64px;
  background: rgba(192, 136, 64, 0.9);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s var(--ease-out);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
}

.video-card:hover .play-btn {
  background: var(--accent);
  transform: translate(-50%, -50%) scale(1.1);
  box-shadow: 0 8px 30px rgba(192, 136, 64, 0.4);
}

.play-btn svg {
  width: 24px;
  height: 24px;
  fill: var(--bg-deep);
  margin-left: 3px;
}

.video-info {
  padding: 1.25rem 1.5rem;
}

.video-info h3 {
  font-family: var(--ff-body);
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.5;
  color: var(--text-light);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Active video (iframe loaded) */
.video-thumb.active {
  aspect-ratio: 16 / 9;
}

.video-thumb.active img,
.video-thumb.active .play-btn {
  display: none;
}

.video-thumb iframe {
  width: 100%;
  height: 100%;
  position: absolute;
  inset: 0;
  border: none;
}

/* --- Guide CTA Section --- */
.guide-section {
  padding: 7rem 0;
  background: var(--bg-deep);
  position: relative;
}

.guide-inner {
  width: var(--container-narrow);
  margin: 0 auto;
  background: linear-gradient(135deg, var(--bg-card) 0%, var(--bg-section) 100%);
  border: 1px solid var(--border-accent);
  border-radius: 12px;
  padding: 4rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.guide-inner::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, var(--accent-glow) 0%, transparent 70%);
  pointer-events: none;
}

.guide-inner .section-label {
  justify-content: center;
}

.guide-inner .section-label::before { display: none; }

.guide-inner h2 {
  margin-bottom: 1rem;
  position: relative;
}

.guide-inner p {
  color: var(--text-light-secondary);
  max-width: 500px;
  margin: 0 auto 2rem;
  line-height: 1.7;
  position: relative;
}

.guide-inner .btn {
  position: relative;
}

.guide-list {
  list-style: none;
  max-width: 460px;
  margin: 0 auto 2rem;
  text-align: left;
}

.guide-list li {
  padding: 0.5rem 0;
  color: var(--text-light-secondary);
  font-size: 0.95rem;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  line-height: 1.6;
}

.guide-list li::before {
  content: '';
  width: 6px;
  height: 6px;
  min-width: 6px;
  border-radius: 50%;
  background: var(--accent);
  margin-top: 8px;
}

/* --- Footer --- */
.footer {
  padding: 4rem 0 2rem;
  background: var(--bg-deep);
  border-top: 1px solid var(--border-subtle);
}

.footer-inner {
  width: var(--container);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 3rem;
}

.footer-brand .nav-logo {
  margin-bottom: 1rem;
  display: inline-block;
}

.footer-brand p {
  color: var(--text-light-secondary);
  font-size: 0.9rem;
  line-height: 1.7;
  max-width: 340px;
}

.footer-col h4 {
  font-family: var(--ff-body);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-light);
  margin-bottom: 1.25rem;
}

.footer-col ul {
  list-style: none;
}

.footer-col ul li {
  margin-bottom: 0.6rem;
}

.footer-col ul a {
  font-size: 0.9rem;
  color: var(--text-light-secondary);
  transition: color 0.3s;
}

.footer-col ul a:hover {
  color: var(--accent);
}

.footer-bottom {
  width: var(--container);
  margin: 3rem auto 0;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-subtle);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.footer-bottom p {
  font-size: 0.8rem;
  color: var(--text-light-secondary);
}

.footer-social {
  display: flex;
  gap: 1rem;
}

.footer-social a {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  border: 1px solid var(--border-subtle);
  color: var(--text-light-secondary);
  transition: all 0.3s;
}

.footer-social a:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-muted);
}

.footer-social svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

/* ============================================================
   VIDEOS PAGE
   ============================================================ */

.page-header {
  padding: 10rem 0 4rem;
  background: var(--bg-dark);
  text-align: center;
  position: relative;
}

.page-header::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 60% 50% at 50% 30%, rgba(192, 136, 64, 0.04) 0%, transparent 60%);
  pointer-events: none;
}

.page-header-inner {
  width: var(--container);
  margin: 0 auto;
  position: relative;
}

.page-header p {
  color: var(--text-light-secondary);
  max-width: 560px;
  margin: 1rem auto 0;
  line-height: 1.7;
  font-size: 1.1rem;
}

.videos-section {
  padding: 4rem 0 7rem;
  background: var(--bg-deep);
}

.videos-section-inner {
  width: var(--container);
  margin: 0 auto;
}

.videos-count {
  font-size: 0.85rem;
  color: var(--text-light-secondary);
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border-subtle);
}

.videos-count strong {
  color: var(--accent);
  font-weight: 600;
}

/* Full videos grid - 3 cols on desktop */
.videos-full-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(320px, 100%), 1fr));
  gap: 1.5rem;
}

/* --- Scroll Animations --- */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s var(--ease-out), transform 0.8s var(--ease-out);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
.reveal-delay-4 { transition-delay: 0.4s; }

/* --- Responsive --- */
@media (max-width: 1024px) {
  .about-inner {
    grid-template-columns: 1fr;
    gap: 3rem;
  }

  .pillars-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .footer-inner {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(10, 12, 16, 0.98);
    backdrop-filter: blur(20px);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 2rem;
    padding: 2rem;
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links a {
    font-size: 1.2rem;
  }

  .nav-toggle {
    display: flex;
    z-index: 1001;
  }

  .hero {
    min-height: auto;
    padding: 8rem 0 5rem;
  }

  h1 { font-size: clamp(2.2rem, 8vw, 3.2rem); }

  .hero-actions {
    flex-direction: column;
  }

  .btn {
    justify-content: center;
    width: 100%;
  }

  .about {
    padding: 5rem 0;
  }

  .about-inner {
    gap: 2.5rem;
  }

  .keegan-portrait {
    max-width: 280px;
  }

  .pillars {
    padding: 5rem 0;
  }

  .pillars-grid {
    grid-template-columns: 1fr;
  }

  .featured-videos {
    padding: 5rem 0;
  }

  .video-grid {
    grid-template-columns: 1fr;
  }

  .videos-full-grid {
    grid-template-columns: 1fr;
  }

  .guide-inner {
    padding: 2.5rem 1.5rem;
  }

  .guide-section {
    padding: 5rem 0;
  }

  .page-header {
    padding: 7rem 0 3rem;
  }

  .page-header p {
    font-size: 1rem;
  }

  .videos-section {
    padding: 2.5rem 0 5rem;
  }

  .footer-inner {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .footer-bottom {
    flex-direction: column;
    text-align: center;
  }

  .featured-videos-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .section-label {
    font-size: 0.7rem;
  }
}

@media (max-width: 480px) {
  :root {
    --container: 92vw;
  }

  .hero {
    padding: 6.5rem 0 3.5rem;
  }

  .hero-badge {
    font-size: 0.65rem;
    padding: 0.35rem 0.75rem;
  }

  .hero-sub {
    font-size: 0.95rem;
    margin-bottom: 2rem;
  }

  h2 { font-size: clamp(1.6rem, 6vw, 2rem); }

  .about {
    padding: 4rem 0;
  }

  .keegan-portrait {
    max-width: 220px;
  }

  .pillar-card {
    padding: 2rem 1.5rem;
  }

  .video-card .video-info {
    padding: 1rem;
  }

  .play-btn {
    width: 52px !important;
    height: 52px !important;
  }

  .play-btn svg {
    width: 20px !important;
    height: 20px !important;
  }

  .guide-inner {
    padding: 2rem 1.25rem;
  }

  .guide-list li {
    font-size: 0.9rem;
  }

  .page-header {
    padding: 6.5rem 0 2.5rem;
  }

  .footer {
    padding: 3rem 0 1.5rem;
  }
}
