/*
 * Core Resets & Utilities
 */

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

html {
  scroll-behavior: auto; /* Disabled for Lenis smooth scroller logic */
  font-size: 16px;
}

body {
  font-family: var(--font-base);
  background-color: var(--bg-main);
  color: var(--text-main);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition:
    background-color 0.3s ease,
    color 0.3s ease;
  overflow-x: hidden;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.2;
  color: var(--text-main);
  letter-spacing: -0.02em;
}

p {
  line-height: 1.6;
  color: var(--text-muted);
}

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

ul {
  list-style: none;
}

/* Button Component */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 28px;
  border-radius: var(--radius-full);
  font-weight: 500;
  font-size: 1rem;
  letter-spacing: 0.01em;
  cursor: pointer;
  border: none;
  transition: all 0.2s ease;
  font-family: var(--font-base);
}

.btn:active {
  transform: scale(0.98);
}

.btn-primary {
  background-color: var(--primary);
  color: #ffffff;
  box-shadow: var(--shadow-md);
}

.btn-primary:hover {
  background-color: var(--primary-hover);
  box-shadow: var(--shadow-glow);
  transform: translateY(-2px);
  color: #fff;
}

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

.btn-outline:hover {
  border-color: var(--primary);
  color: var(--primary);
  background-color: var(--primary-light);
}

/* Layout Utilities */
.container {
  width: 100%;
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 var(--container-padding);
}

.section {
  padding: 96px 0;
}

/* Animations - Diag-Nose Style Buttery Reveal */
@keyframes butteryReveal {
  from {
    opacity: 0;
    transform: translateY(40px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-on-scroll {
  opacity: 0;
  will-change: opacity, transform;
}
.animate-on-scroll.is-visible {
  animation: butteryReveal 1.2s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

/* Base delays for static elements */
.delay-100 {
  animation-delay: 100ms;
}
.delay-200 {
  animation-delay: 200ms;
}
.delay-300 {
  animation-delay: 300ms;
}

/* Grid Staggering (Applied dynamically via JS) */
.stagger-item {
  opacity: 0;
  will-change: opacity, transform;
}
.stagger-item.is-visible {
  animation: butteryReveal 1.2s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

/* Global Header Components */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
  background-color: var(--glass-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--glass-border);
  transition: all 0.3s ease;
}

.site-header-scrolled {
  box-shadow: var(--shadow-md);
}

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

.brand-logo {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-main);
  display: flex;
  align-items: center;
}
.brand-logo span {
  color: var(--primary);
}
.brand-logo img {
  max-height: 40px;
  width: auto;
}

.nav-menu ul {
  display: flex;
  gap: 32px;
  align-items: center;
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav-menu li a {
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--text-muted);
  position: relative;
}

.nav-menu li a:hover {
  color: var(--text-main);
}

.nav-menu li a::after {
  content: "";
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0%;
  height: 2px;
  background-color: var(--primary);
  transition: width 0.2s ease;
  border-radius: 2px;
}

.nav-menu li a:hover::after,
.nav-menu li.current-menu-item > a::after {
  width: 100%;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.theme-toggle {
  background: none;
  border: none;
  font-size: 1.25rem;
  cursor: pointer;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  transition: all 0.2s;
}

.theme-toggle:hover {
  background-color: var(--bg-surface-hover);
  color: var(--text-main);
}

/* Footer Components */
.site-footer {
  background-color: var(--bg-surface);
  border-top: 1px solid var(--border-color);
  padding: 80px 0 40px;
}

.footer-top {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1.5fr;
  gap: 48px;
  margin-bottom: 64px;
}

.footer-links ul {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin: 0;
  padding: 0;
}

.footer-links li a {
  color: var(--text-muted);
  font-weight: 500;
}
.footer-links li a:hover {
  color: var(--primary);
}

.newsletter-form {
  display: flex;
  gap: 8px;
  width: 100%;
}

.newsletter-form input {
  flex-grow: 1;
  padding: 12px 16px;
  border: 1px solid var(--border-color-strong);
  border-radius: var(--radius-md);
  background-color: var(--bg-main);
  color: var(--text-main);
  font-family: inherit;
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.2s;
}
.newsletter-form input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-light);
}

.footer-bottom {
  border-top: 1px solid var(--border-color);
  width: 100%;
  text-align: center;
  padding-top: 32px;
  color: var(--text-muted);
  font-size: 0.875rem;
}

/* Standard Eyebrow */
.eyebrow {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 16px;
  background-color: var(--primary-light);
  padding: 4px 12px;
  border-radius: var(--radius-full);
}

/* TEMPLATE STYLES */

/* Home */
.hero-section {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  overflow: hidden;
  padding-top: 80px; /* Offset header */
  background-color: transparent;
}

/* Diag-nose.io inspired Morphing Blob */
.blob-container {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 600px;
  height: 600px;
  z-index: 0;
  pointer-events: none;
  filter: blur(80px); /* Creates the hazy, gaseous look */
  opacity: 0.6;
}
.blob {
  width: 100%;
  height: 100%;
  background: linear-gradient(
    135deg,
    var(--primary-light) 0%,
    var(--primary) 50%,
    var(--accent-light) 100%
  );
  animation:
    morph 20s ease-in-out infinite,
    spin 30s linear infinite;
  transform-origin: 50% 50%;
  border-radius: 40% 60% 70% 30% / 40% 40% 60% 50%;
  transition: background 0.5s ease;
}

@keyframes morph {
  0%,
  100% {
    border-radius: 40% 60% 70% 30% / 40% 40% 60% 50%;
  }
  34% {
    border-radius: 70% 30% 50% 50% / 30% 30% 70% 70%;
  }
  67% {
    border-radius: 100% 60% 60% 100% / 100% 100% 60% 60%;
  }
}
@keyframes spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}
.hero-content {
  position: relative;
  z-index: 10;
}
.hero-title {
  font-size: clamp(3rem, 6vw, 5rem);
  margin-bottom: 24px;
  max-width: 1000px;
  margin-left: auto;
  margin-right: auto;
  letter-spacing: -0.03em;
}
.hero-subtitle {
  font-size: 1.25rem;
  max-width: 650px;
  margin: 0 auto 40px;
}
.hero-btns {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}
.services-section {
  background-color: var(--bg-surface);
}
.service-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 32px;
  margin-top: 48px;
}
.service-card {
  background-color: var(--bg-main);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 40px;
  opacity: 0; /* JS stagger reveal */
  transition: all 0.3s ease;
}
.service-card:hover {
  border-color: var(--primary);
  box-shadow: var(--shadow-lg);
  transform: translateY(-5px);
}
.service-card ul {
  margin: 24px 0;
}
.service-card li {
  position: relative;
  padding-left: 24px;
  margin-bottom: 12px;
  color: var(--text-muted);
}
.service-card li::before {
  content: "→";
  position: absolute;
  left: 0;
  color: var(--primary);
  font-weight: bold;
}

/* Pillars */
.pillars {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  margin-top: 56px;
}
.pillar {
  padding: 32px 0;
  border-top: 1px solid var(--border-color);
}
.pillar-num {
  font-size: 2rem;
  color: var(--border-color);
  margin-bottom: 14px;
  font-weight: 500;
}
.pillar h4 {
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 8px;
}
.pillar p {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.7;
}

/* How It Works (Premium Steps) */
.steps-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  margin-top: 56px;
  position: relative;
  z-index: 1;
}
/* Connecting Line */
.steps-row::before {
  content: "";
  position: absolute;
  top: 32px; /* Center of the badge */
  left: 40px;
  right: calc(100% / 3 + 40px);
  height: 2px;
  background: dashed 2px var(--border-color);
  background-image: repeating-linear-gradient(
    90deg,
    var(--border-color) 0,
    var(--border-color) 8px,
    transparent 8px,
    transparent 16px
  );
  z-index: -1;
}
.step-card {
  background: var(--bg-main);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 40px 32px;
  position: relative;
  box-shadow: var(--shadow-sm);
  text-align: left;
  transition:
    transform 0.3s ease,
    border-color 0.3s ease,
    box-shadow 0.3s ease;
}
.step-card:hover {
  transform: translateY(-5px);
  border-color: var(--primary);
  box-shadow: var(--shadow-md);
}
.step-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--primary-light);
  color: var(--primary);
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 24px;
  position: relative;
  border: 4px solid var(--bg-surface);
}
.step-card h4 {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 12px;
}
.step-card p {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* Trust Strip */
.trust-strip {
  background: var(--bg-inverse);
  padding: 96px 20px;
  text-align: center;
  color: var(--text-inverse);
}
.trust-strip h2 {
  font-size: clamp(2rem, 3.5vw, 2.75rem);
  color: #fff;
  margin-bottom: 12px;
}
.trust-strip p {
  font-size: 1.1rem;
  color: rgba(255, 255, 255, 0.6);
  margin-bottom: 36px;
}
.trust-btns {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

/* Featured Programs */
.bg-inverse {
  background-color: var(--bg-inverse);
  color: var(--text-inverse);
}
.featured-programs-section {
  padding: 96px 0;
}
.fp-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 32px;
  margin-top: 48px;
}
.fp-card {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 32px;
  text-align: center;
  opacity: 0; /* JS stagger reveal */
  transition: all 0.3s ease;
}
.bg-inverse-card {
  background-color: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.1);
}
.bg-inverse-card:hover {
  border-color: var(--primary-light);
  background-color: rgba(255, 255, 255, 0.08);
}
.fp-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
  border-color: var(--primary);
}
.fp-icon {
  font-size: 2.5rem;
  margin-bottom: 16px;
  display: block;
}

/* Global Inner Page Hero */
.global-hero {
  padding: 200px 0 120px;
  background-color: var(--bg-inverse);
  color: var(--text-inverse);
  text-align: center;
  position: relative;
  overflow: hidden;
}
/* Subtle creative background pattern */
.global-hero::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: radial-gradient(
    var(--border-color-strong) 1px,
    transparent 1px
  );
  background-size: 24px 24px;
  opacity: 0.15;
  pointer-events: none;
}
.global-hero h1,
.global-hero p,
.global-hero .eyebrow {
  position: relative;
  z-index: 2;
}
.global-hero h1,
.global-hero p {
  color: inherit;
}
.global-hero p {
  opacity: 0.8;
}
/* Tutoring specifics */
.chips-container {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 24px;
}
.chip {
  padding: 8px 16px;
  border-radius: var(--radius-full);
  background-color: var(--primary-light);
  color: var(--primary-hover);
  font-weight: 500;
  font-size: 0.875rem;
}
.tutoring-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: start;
}

.mission-box {
  background-color: var(--primary);
  color: #fff;
  padding: 64px;
  border-radius: var(--radius-lg);
  margin-top: -80px;
  position: relative;
  z-index: 10;
  box-shadow: var(--shadow-lg);
}
.mission-box blockquote {
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  font-family: var(--font-display);
  line-height: 1.4;
  font-style: italic;
  opacity: 0.95;
}
.values-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 32px;
  margin-top: 48px;
}
.value-card {
  background-color: var(--bg-surface);
  padding: 32px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  opacity: 0; /* JS stagger reveal */
}
.value-icon {
  width: 48px;
  height: 48px;
  background-color: var(--primary-light);
  border-radius: var(--radius-full);
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
}

/* FAQ */
.faq-container {
  max-width: 800px;
  margin: 0 auto;
}
.faq-category {
  margin-bottom: 48px;
}
.faq-category-title {
  font-size: 1.5rem;
  margin-bottom: 24px;
  color: var(--primary);
  border-bottom: 2px solid var(--border-color);
  padding-bottom: 12px;
}
.faq-item {
  border: 1px solid var(--border-color);
  background-color: var(--bg-surface);
  border-radius: var(--radius-md);
  margin-bottom: 16px;
  overflow: hidden;
  transition: all 0.2s ease;
}
.faq-item:hover {
  border-color: var(--border-color-strong);
}
.faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px;
  cursor: pointer;
  font-weight: 600;
  color: var(--text-main);
  font-family: var(--font-display);
  font-size: 1.125rem;
  user-select: none;
}
.faq-answer {
  padding: 0 24px 24px;
  color: var(--text-muted);
  display: none;
  line-height: 1.7;
}
.faq-item.is-open .faq-answer {
  display: block;
}
.faq-icon {
  font-size: 1.5rem;
  color: var(--primary);
  transition: transform 0.3s;
}
.faq-item.is-open .faq-icon {
  transform: rotate(45deg);
}

/* Contact */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: start;
  margin-top: -60px;
  position: relative;
  z-index: 10;
}
.meta-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 32px;
}
.meta-card {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 24px;
  box-shadow: var(--shadow-sm);
}
.meta-card h4 {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 8px;
}
.meta-card div {
  font-weight: 500;
  color: var(--text-main);
}

/* CF7 Form Overrides */
.wpcf7-form {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-color);
  padding: 40px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}
.wpcf7-form label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  margin-bottom: 8px;
  color: var(--text-main);
}
.wpcf7-form input[type="text"],
.wpcf7-form input[type="email"],
.wpcf7-form input[type="tel"],
.wpcf7-form textarea,
.wpcf7-form select {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid var(--border-color-strong);
  border-radius: var(--radius-md);
  background-color: var(--bg-main);
  color: var(--text-main);
  font-family: inherit;
  font-size: 1rem;
  transition: all 0.2s ease;
  margin-bottom: 20px;
}
.wpcf7-form input:focus,
.wpcf7-form textarea:focus,
.wpcf7-form select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-light);
}
.wpcf7-form input[type="submit"] {
  width: 100%;
  background-color: var(--primary);
  color: #fff;
  border: none;
  padding: 14px;
  border-radius: var(--radius-full);
  font-weight: 500;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.2s;
}
.wpcf7-form input[type="submit"]:hover {
  background-color: var(--primary-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

@media (max-width: 768px) {
  .nav-menu ul {
    display: none;
  }
  .header-actions .btn {
    display: none;
  }
  .section {
    padding: 64px 0;
  }
  h1 {
    font-size: 2.5rem !important;
  }
  .tutoring-grid,
  .contact-grid,
  .footer-top {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .pillars,
  .steps-row {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .steps-row::before {
    display: none;
  }
  .trust-strip {
    padding: 60px 20px;
  }
}

/* Two-Col and Form Group Utilities for Inner Pages */
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: start;
}
@media (max-width: 720px) {
  .two-col {
    grid-template-columns: 1fr;
  }
}

.info-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 28px 30px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
@media (max-width: 600px) {
  .form-row {
    grid-template-columns: 1fr;
  }
}
.form-group {
  margin-bottom: 14px;
}

/* Tutoring Page Specific Improvements */
.advantage-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  margin-bottom: 64px;
}
.subject-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 20px;
}
.subject-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  padding: 24px;
  border-radius: var(--radius-md);
  text-align: center;
  transition: all 0.3s ease;
  cursor: pointer;
}
.subject-card:hover {
  transform: translateY(-8px);
  border-color: var(--primary);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.05);
  background: #fff;
}
.subject-card i {
  font-size: 2rem;
  color: var(--primary);
  margin-bottom: 16px;
  display: block;
}
.subject-card h4 {
  font-size: 1rem;
  font-weight: 600;
  margin: 0;
  color: var(--text-main);
}

.form-focal-section {
  max-width: 700px;
  margin: 0 auto;
}

.support-banner {
  background: var(--primary-light);
  border-radius: var(--radius-lg);
  padding: 48px;
  text-align: center;
  margin-top: 64px;
}
.support-banner h3 {
  font-size: 1.75rem;
  margin-bottom: 8px;
  color: var(--primary);
}
.support-banner p {
  color: var(--text-muted);
  margin-bottom: 24px;
}

/* - Program Catalog Archive - */
.program-catalog {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 32px;
}

.catalog-card {
  background: #fff;
  border: 1px solid var(--border-color);
  border-radius: 20px;
  padding: 40px;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
  position: relative;
  overflow: hidden;
}

.catalog-card:hover {
  transform: translateY(-10px);
  border-color: var(--primary);
  box-shadow: 0 40px 80px -20px rgba(8, 17, 30, 0.2);
}

.catalog-card-icon {
  font-size: 2.5rem;
  color: var(--primary);
  margin-bottom: 24px;
  display: inline-block;
}

.catalog-card h3 {
  font-size: 1.5rem;
  color: var(--text-main);
  margin-bottom: 12px;
}

.catalog-card p {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 0;
}

.program-badge {
  position: absolute;
  top: 40px;
  right: 40px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 6px 12px;
  background: var(--bg-surface);
  color: var(--text-muted);
  border-radius: 30px;
}

/* - Sub-Program Matrix (Pricing) - */
.sub-program-matrix {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 32px;
}

/* Logic for Single/Duo Centering */
.sub-program-matrix.is-single {
  grid-template-columns: 1fr;
  max-width: 500px;
  margin: 0 auto;
}

.sub-program-matrix.is-duo {
  grid-template-columns: repeat(2, 1fr);
  max-width: 860px;
  margin: 0 auto;
}

.sub-program-card {
  background: #fff;
  border: 1px solid var(--border-color);
  border-radius: 24px;
  padding: 40px;
  display: flex;
  flex-direction: column;
  height: 100%;
  transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
  box-shadow: var(--shadow-sm);
}

.sub-program-card:hover {
  transform: translateY(-8px);
  border-color: var(--primary);
  box-shadow: 0 40px 80px -20px rgba(8, 17, 30, 0.2);
}

.sub-program-price {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 20px;
  display: flex;
  align-items: baseline;
  gap: 4px;
}

.sub-program-price span {
  font-size: 0.95rem;
  font-weight: 400;
  color: var(--text-muted);
}

.sub-program-features {
  list-style: none;
  padding: 0;
  margin: 24px 0 32px 0;
  border-top: 1px solid var(--bg-surface);
  padding-top: 24px;
}

.sub-program-features li {
  font-size: 0.9rem;
  color: var(--text-main);
  margin-bottom: 12px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.sub-program-features li i {
  color: var(--primary);
  font-size: 1.125rem;
  margin-top: 1px;
}

@media (max-width: 900px) {
  .sub-program-matrix.is-duo {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .advantage-strip,
  .subject-grid,
  .program-catalog {
    grid-template-columns: 1fr;
  }
}

.social-link:hover {
  color: var(--primary) !important;
}

/* - Universal Modal - */
.modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(8, 17, 30, 0.45);
  backdrop-filter: blur(12px);
  display: none; /* hidden by default */
  align-items: center;
  justify-content: center;
  z-index: 10000;
  opacity: 0;
  transition: opacity 0.3s ease;
  padding: 24px;
}

.modal-backdrop.is-active {
  display: flex;
  opacity: 1;
}

.modal-card {
  background: #fff;
  width: 100%;
  max-width: 600px;
  max-height: 85vh;
  padding: 56px;
  border-radius: 28px;
  box-shadow: 0 40px 100px -20px rgba(8, 17, 30, 0.35);
  position: relative;
  transform: translateY(24px);
  transition: transform 0.5s cubic-bezier(0.165, 0.84, 0.44, 1);
  overflow-y: auto;
  scrollbar-width: thin;
}

.modal-backdrop.is-active .modal-card {
  transform: translateY(0);
}

.modal-close {
  position: absolute;
  top: 24px;
  right: 24px;
  background: var(--bg-surface);
  border: none;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  z-index: 10;
}

.modal-close:hover {
  background: #eee;
  transform: rotate(90deg);
}

/* Contact Page Balanced 60/40 Split */
.balanced-split {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 48px;
  align-items: start;
}
@media (max-width: 900px) {
  .balanced-split {
    grid-template-columns: 1fr;
    gap: 32px;
  }
}

/* - Footer Newsletter Inline Fix & Reset - */
.site-footer .wpcf7-form {
  background: transparent !important;
  border: none !important;
  padding: 0 !important;
  box-shadow: none !important;
  margin: 0 !important;
}
.footer-newsletter-wrap {
  display: flex !important;
  gap: 8px;
  background: #fff;
  padding: 6px;
  border-radius: 12px;
  border: 1px solid var(--border-color);
  margin-top: 24px;
  align-items: center;
}
.footer-newsletter-wrap .wpcf7-form-control-wrap {
  flex-grow: 1;
}
.footer-newsletter-wrap input[type="email"] {
  width: 100%;
  border: none !important;
  background: transparent !important;
  padding: 8px 12px;
  font-size: 0.95rem;
  box-shadow: none !important;
  color: var(--text-main) !important;
  margin-bottom: 0 !important;
}
.footer-newsletter-wrap .btn-primary {
  padding: 10px 20px !important;
  border-radius: 8px !important;
  font-size: 0.875rem !important;
  white-space: nowrap;
  margin: 0 !important;
  margin-bottom: 0 !important;
}

/* Ensure CF7 success/error messages match footer dark theme */
.site-footer .wpcf7-response-output {
  margin: 12px 0 0 0 !important;
  padding: 8px !important;
  font-size: 0.8rem;
  border-radius: 8px;
  border: none !important;
  background: rgba(255, 255, 255, 0.05);
  color: rgba(255, 255, 255, 0.7);
}
/* ── Mobile Navigation Drawer ── */
.mobile-nav-toggle {
    display: none;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    width: 44px; height: 44px;
    border-radius: 12px;
    align-items: center; justify-content: center;
    font-size: 20px;
    color: var(--text-main);
    cursor: pointer;
    transition: all 0.2s;
}

.mobile-overlay {
    position: fixed;
    inset: 0;
    background: rgba(8, 17, 30, 0.4);
    backdrop-filter: blur(8px);
    z-index: 999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

.mobile-overlay.is-active {
    opacity: 1;
    pointer-events: auto;
}

.mobile-drawer {
    position: fixed;
    top: 0; right: 0;
    width: 100%;
    max-width: 360px;
    height: 100%;
    background: #fff;
    z-index: 1000;
    padding: 40px;
    display: flex;
    flex-direction: column;
    transform: translateX(100%);
    transition: transform 0.5s cubic-bezier(0.165, 0.84, 0.44, 1);
    box-shadow: -20px 0 60px rgba(8, 17, 30, 0.1);
}

.mobile-drawer.is-open {
    transform: translateX(0);
}

.drawer-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 60px;
}

.drawer-close {
    background: var(--bg-surface);
    border: none;
    width: 36px; height: 36px;
    border-radius: 50%;
    font-size: 18px;
    cursor: pointer;
}

.drawer-menu ul {
    display: flex;
    flex-direction: column;
    gap: 32px;
}

.drawer-menu a {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-main);
}

.drawer-footer {
    margin-top: auto;
    padding-top: 40px;
    border-top: 1px solid var(--border-color);
}

/* ── Screen Refinements ── */
@media (max-width: 991px) {
    .nav-menu { display: none; }
    .mobile-nav-toggle { display: flex; }
    .header-actions .btn { display: none; } /* Hide in header, show in drawer footer */
}

@media (max-width: 768px) {
    .section { padding: 80px 0; }
    h1 { font-size: 2.75rem !important; }
    h2 { font-size: 2rem !important; }
    
    /* Grid Resets */
    .service-grid, .fp-grid, .program-catalog, .sub-program-matrix {
        grid-template-columns: 1fr !important;
        gap: 24px;
    }

    .modal-card { padding: 40px 24px; border-radius: 0; max-height: 100vh; border-radius: 20px; }
}

@media (max-width: 480px) {
    .hero-title { font-size: 2.25rem !important; }
    .mobile-drawer { max-width: 100%; padding: 32px; }
    .drawer-menu a { font-size: 1.25rem; }
}

/* Fix for very small phones (SE) */
.service-grid { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.program-catalog { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.sub-program-matrix { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
