/* ==========================================================================
   Eglise St Nicolas Service Network - Core Stylesheet
   Domain: eglisestnicolas.org | Phone: (833) 582-2016
   ========================================================================== */

:root {
  --color-primary-dark: #0B132B;
  --color-secondary-dark: #1C2541;
  --color-accent-navy: #3A506B;
  --color-cta-yellow: #FFC107;
  --color-cta-yellow-hover: #E5A800;
  --color-text-white: #FFFFFF;
  --color-text-light: #F8FAFC;
  --color-text-muted: #CBD5E1;
  --color-text-body: #334155;
  --color-text-heading: #0F172A;
  --color-bg-light: #F8FAFC;
  --color-bg-white: #FFFFFF;
  --color-border: #E2E8F0;
  --color-card-bg: #FFFFFF;
  --font-family-base: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --border-radius: 8px;
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.1);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-family-base);
  color: var(--color-text-body);
  background-color: var(--color-bg-light);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  padding-bottom: 0;
}

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

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

/* Layout Containers */
.container {
  width: 100%;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 20px;
  padding-right: 20px;
}

.section {
  padding: 70px 0;
}

.section-alt {
  background-color: #EDF2F7;
}

.section-dark {
  background-color: var(--color-secondary-dark);
  color: var(--color-text-white);
}

/* ==========================================================================
   HEADER NAVIGATION ARCHITECTURE (MANDATED CONTRAST & SINGLE CTA)
   ========================================================================== */

/* Top Utility Bar */
.top-utility-bar {
  background-color: var(--color-primary-dark);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  padding: 8px 0;
  font-size: 0.875rem;
}

.top-bar-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.top-bar-left {
  color: #CBD5E1 !important;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Plain text unstyled link - STRICT: NO BUTTON STYLING */
.top-bar-right {
  color: #CBD5E1 !important;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 6px;
}

.top-bar-right a {
  color: #CBD5E1 !important;
  text-decoration: none !important;
  background: none !important;
  border: none !important;
  padding: 0 !important;
  box-shadow: none !important;
  border-radius: 0 !important;
  font-weight: 600;
}

.top-bar-right a:hover {
  color: #FFC107 !important;
}

/* Main Navigation Bar (3-Column Desktop Alignment) */
.main-header {
  background-color: var(--color-secondary-dark);
  border-bottom: 2px solid rgba(255, 193, 7, 0.3);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: var(--shadow-md);
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 72px;
  position: relative;
}

/* Left: Brand Logo */
.brand-logo {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
}

.brand-link {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--color-text-white);
  display: flex;
  align-items: center;
  gap: 8px;
  letter-spacing: -0.02em;
}

.brand-badge {
  background-color: var(--color-cta-yellow);
  color: var(--color-primary-dark);
  font-size: 0.75rem;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 4px;
  text-transform: uppercase;
}

/* Center: Horizontally Centered Navigation Menu */
.nav-menu-wrapper {
  flex: 1 1 auto;
  display: flex;
  justify-content: center;
}

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

/* Navigation Links: MANDATED CONTRAST RULES */
.nav-link,
nav a {
  color: #FFFFFF !important;
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none;
  padding: 8px 4px;
  position: relative;
  transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link.active,
nav a:hover {
  color: #FFC107 !important;
}

/* Right: STRICTLY ONE SINGLE CALL CTA BUTTON */
.nav-cta-wrapper {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
}

/* High-visibility yellow action button */
.btn-primary,
.cta-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background-color: var(--color-cta-yellow);
  color: var(--color-primary-dark) !important;
  font-weight: 700;
  font-size: 1rem;
  padding: 12px 24px;
  border-radius: var(--border-radius);
  text-decoration: none;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 10px rgba(255, 193, 7, 0.35);
  transition: all 0.25s ease;
  min-height: 48px;
  min-width: 48px;
  gap: 8px;
}

.btn-primary:hover,
.cta-button:hover {
  background-color: var(--color-cta-yellow-hover);
  color: #000000 !important;
  transform: translateY(-2px);
  box-shadow: 0 6px 14px rgba(255, 193, 7, 0.45);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background-color: transparent;
  color: var(--color-text-white);
  border: 2px solid var(--color-text-white);
  font-weight: 600;
  font-size: 1rem;
  padding: 10px 22px;
  border-radius: var(--border-radius);
  min-height: 48px;
  transition: all 0.2s ease;
}

.btn-secondary:hover {
  background-color: rgba(255, 255, 255, 0.1);
  color: var(--color-cta-yellow);
  border-color: var(--color-cta-yellow);
}

/* Mobile Hamburger Menu Toggle */
.mobile-nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 10px;
  color: var(--color-text-white);
  min-width: 48px;
  min-height: 48px;
}

.hamburger-line {
  display: block;
  width: 26px;
  height: 3px;
  background-color: var(--color-text-white);
  margin: 5px 0;
  transition: transform 0.3s ease, opacity 0.3s ease;
  border-radius: 2px;
}

/* ==========================================================================
   HERO SECTION & COMPLIANCE BADGES
   ========================================================================== */

.hero-section {
  background: linear-gradient(135deg, var(--color-primary-dark) 0%, var(--color-secondary-dark) 100%);
  color: var(--color-text-white);
  padding: 70px 0 60px 0;
  position: relative;
  overflow: hidden;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 40px;
  align-items: center;
}

.hero-content h1 {
  font-size: 2.75rem;
  line-height: 1.2;
  font-weight: 800;
  color: var(--color-text-white);
  margin-bottom: 20px;
  letter-spacing: -0.02em;
}

.hero-lead {
  font-size: 1.15rem;
  color: var(--color-text-light);
  margin-bottom: 25px;
  line-height: 1.6;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 25px;
}

/* Partner & Referral Hero Disclosure */
.hero-disclosure-box {
  background: rgba(255, 255, 255, 0.08);
  border-left: 4px solid var(--color-cta-yellow);
  padding: 12px 16px;
  border-radius: 4px;
  font-size: 0.85rem;
  color: var(--color-text-muted);
  line-height: 1.5;
  margin-top: 15px;
}

.hero-disclosure-box strong {
  color: var(--color-text-white);
}

.hero-image-wrapper {
  position: relative;
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: 0 20px 30px rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.hero-image-wrapper img {
  width: 100%;
  height: 380px;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.hero-badge-overlay {
  position: absolute;
  bottom: 16px;
  left: 16px;
  right: 16px;
  background: rgba(11, 19, 43, 0.9);
  padding: 12px 16px;
  border-radius: 6px;
  backdrop-filter: blur(4px);
  border: 1px solid rgba(255, 193, 7, 0.3);
  font-size: 0.875rem;
  color: var(--color-text-white);
}

/* Trust Bar / Stats Bar */
.trust-bar {
  background-color: #0E1A38;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  padding: 20px 0;
  color: var(--color-text-white);
}

.trust-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  text-align: center;
}

.trust-item h4 {
  color: var(--color-cta-yellow);
  font-size: 1.4rem;
  font-weight: 700;
  margin-bottom: 4px;
}

.trust-item p {
  color: var(--color-text-muted);
  font-size: 0.875rem;
}

/* ==========================================================================
   FEATURE CARDS & SERVICES GRID
   ========================================================================== */

.section-header {
  text-align: center;
  max-width: 800px;
  margin: 0 auto 50px auto;
}

.section-header h2 {
  font-size: 2.25rem;
  font-weight: 800;
  color: var(--color-text-heading);
  margin-bottom: 15px;
  letter-spacing: -0.02em;
}

.section-header p {
  font-size: 1.1rem;
  color: #64748B;
  line-height: 1.6;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 30px;
}

.card {
  background: var(--color-card-bg);
  border-radius: var(--border-radius);
  padding: 32px 28px;
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-sm);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  display: flex;
  flex-direction: column;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(255, 193, 7, 0.4);
}

.card-icon {
  width: 52px;
  height: 52px;
  background-color: #FEF3C7;
  color: #B45309;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  font-size: 1.5rem;
}

.card h3 {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--color-text-heading);
  margin-bottom: 12px;
}

.card p {
  color: #475569;
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: 20px;
  flex-grow: 1;
}

.card-link {
  font-weight: 600;
  color: var(--color-secondary-dark);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: color 0.2s ease;
}

.card-link:hover {
  color: #B45309;
}

/* Feature Split Section */
.feature-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 50px;
  align-items: center;
}

.feature-split-reverse {
  direction: rtl;
}

.feature-split-reverse > * {
  direction: ltr;
}

.feature-content h2 {
  font-size: 2.1rem;
  font-weight: 800;
  color: var(--color-text-heading);
  margin-bottom: 18px;
  letter-spacing: -0.02em;
}

.feature-content p {
  color: #475569;
  font-size: 1.05rem;
  line-height: 1.7;
  margin-bottom: 20px;
}

.feature-list {
  list-style: none;
  margin-bottom: 28px;
}

.feature-list li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 12px;
  color: #334155;
  font-size: 0.95rem;
}

.feature-list-icon {
  color: #10B981;
  font-weight: bold;
}

/* Consultation Form Block */
.form-box {
  background: #FFFFFF;
  border-radius: var(--border-radius);
  padding: 35px;
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-md);
}

.form-box h3 {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--color-text-heading);
  margin-bottom: 8px;
}

.form-box p {
  color: #64748B;
  font-size: 0.9rem;
  margin-bottom: 20px;
}

.form-group {
  margin-bottom: 18px;
}

.form-group label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  color: #1E293B;
  margin-bottom: 6px;
}

.form-control {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--color-border);
  border-radius: 6px;
  font-size: 0.95rem;
  font-family: inherit;
  transition: border-color 0.2s ease;
  min-height: 48px;
}

.form-control:focus {
  outline: none;
  border-color: #3A506B;
  box-shadow: 0 0 0 3px rgba(58, 80, 107, 0.15);
}

textarea.form-control {
  min-height: 100px;
  resize: vertical;
}

/* ==========================================================================
   FOOTER NAVIGATION STRUCTURE
   ========================================================================== */

/* Pre-Footer Callout Banner */
.pre-footer-banner {
  background: linear-gradient(135deg, var(--color-primary-dark) 0%, #162447 100%);
  color: var(--color-text-white);
  padding: 50px 0;
  border-top: 3px solid var(--color-cta-yellow);
  text-align: center;
}

.pre-footer-inner {
  max-width: 800px;
  margin: 0 auto;
}

.pre-footer-banner h2 {
  font-size: 2rem;
  font-weight: 800;
  margin-bottom: 14px;
  color: var(--color-text-white);
}

.pre-footer-banner p {
  font-size: 1.1rem;
  color: var(--color-text-muted);
  margin-bottom: 24px;
}

.pre-footer-actions {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

/* Main Global Footer */
.global-footer {
  background-color: #070D1F;
  color: #94A3B8;
  padding: 60px 0 30px 0;
  font-size: 0.9rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

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

.footer-col h4 {
  color: var(--color-text-white);
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 20px;
  position: relative;
  padding-bottom: 8px;
}

.footer-col h4::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 32px;
  height: 2px;
  background-color: var(--color-cta-yellow);
}

.footer-col p {
  line-height: 1.6;
  margin-bottom: 16px;
  color: #94A3B8;
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-links li {
  margin-bottom: 10px;
}

.footer-links a {
  color: #CBD5E1;
  text-decoration: none;
  transition: color 0.2s ease, padding-left 0.2s ease;
  display: inline-block;
}

.footer-links a:hover {
  color: var(--color-cta-yellow);
  padding-left: 4px;
}

.footer-contact-item {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  color: #E2E8F0;
}

.footer-contact-item a {
  color: var(--color-cta-yellow);
  font-weight: 700;
}

/* Partner Compliance Disclaimer in Footer */
.footer-disclaimer-text {
  font-size: 0.8rem;
  color: #64748B;
  line-height: 1.5;
  margin-top: 14px;
}

/* Footer Bottom Bar */
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 25px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 15px;
  font-size: 0.85rem;
}

.footer-bottom-copy {
  color: #64748B;
}

.footer-bottom-links {
  display: flex;
  gap: 20px;
}

.footer-bottom-links a {
  color: #94A3B8;
}

.footer-bottom-links a:hover {
  color: var(--color-text-white);
}

/* ==========================================================================
   MOBILE STICKY CALL BAR (<768px)
   ========================================================================== */

.mobile-sticky-bar {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background-color: var(--color-primary-dark);
  border-top: 2px solid var(--color-cta-yellow);
  padding: 10px 16px;
  z-index: 9999;
  box-shadow: 0 -4px 10px rgba(0, 0, 0, 0.3);
}

.mobile-sticky-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  background-color: var(--color-cta-yellow);
  color: var(--color-primary-dark) !important;
  font-weight: 800;
  font-size: 1.1rem;
  padding: 12px 20px;
  border-radius: 6px;
  text-decoration: none;
  min-height: 48px;
  gap: 8px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

/* ==========================================================================
   LEGAL / POLICY PAGES CONTENT STYLING
   ========================================================================== */

.legal-content-box {
  background: #FFFFFF;
  border-radius: var(--border-radius);
  padding: 40px;
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-sm);
  margin-top: -30px;
  position: relative;
  z-index: 2;
}

.legal-content-box h2 {
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--color-text-heading);
  margin-top: 30px;
  margin-bottom: 12px;
  border-bottom: 2px solid #EDF2F7;
  padding-bottom: 8px;
}

.legal-content-box h2:first-child {
  margin-top: 0;
}

.legal-content-box p {
  color: #475569;
  font-size: 1rem;
  line-height: 1.7;
  margin-bottom: 18px;
}

.legal-content-box ul,
.legal-content-box ol {
  margin-left: 24px;
  margin-bottom: 20px;
  color: #475569;
}

.legal-content-box li {
  margin-bottom: 8px;
  line-height: 1.6;
}

/* Page Header Banner for Inner Pages */
.inner-page-header {
  background: linear-gradient(135deg, var(--color-primary-dark) 0%, var(--color-secondary-dark) 100%);
  color: var(--color-text-white);
  padding: 50px 0 60px 0;
}

.inner-page-header h1 {
  font-size: 2.4rem;
  font-weight: 800;
  margin-bottom: 12px;
  letter-spacing: -0.02em;
}

.inner-page-header p {
  font-size: 1.1rem;
  color: var(--color-text-light);
  max-width: 750px;
}

/* ==========================================================================
   MOBILE RESPONSIVENESS & TOUCH OPTIMIZATION DIRECTIVES
   ========================================================================== */

@media (max-width: 992px) {
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 35px;
  }
  
  .hero-image-wrapper img {
    height: 300px;
  }

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

  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
  }
}

@media (max-width: 768px) {
  /* Provide padding at bottom for mobile sticky call bar */
  body {
    padding-bottom: 70px;
  }

  /* Show mobile sticky call bar */
  .mobile-sticky-bar {
    display: block;
  }

  /* Top bar adjustments */
  .top-bar-inner {
    flex-direction: column;
    text-align: center;
    justify-content: center;
    gap: 4px;
  }

  .top-bar-left,
  .top-bar-right {
    justify-content: center;
    font-size: 0.8rem;
  }

  /* Navigation adjustments */
  .mobile-nav-toggle {
    display: block;
  }

  .nav-cta-wrapper {
    display: none; /* Hide header CTA in bar on mobile since it moves inside the hamburger menu */
  }

  .nav-menu-wrapper {
    display: none;
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    background-color: var(--color-secondary-dark);
    padding: 20px 24px;
    border-bottom: 3px solid var(--color-cta-yellow);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.4);
    z-index: 1001;
  }

  .nav-menu-wrapper.is-open {
    display: block;
  }

  .nav-menu {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }

  .nav-link,
  nav a {
    display: block;
    padding: 12px 14px;
    border-radius: 6px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  }

  .mobile-menu-cta {
    display: block;
    margin-top: 15px;
    text-align: center;
  }

  /* Responsive Grid Layouts: Force vertical stacking */
  .grid-3,
  .grid-2,
  .feature-split,
  .trust-grid {
    grid-template-columns: 1fr !important;
    gap: 24px;
  }

  .feature-split-reverse {
    direction: ltr;
  }

  /* Headings scale down appropriately to prevent awkward wrapping */
  .hero-content h1,
  .inner-page-header h1 {
    font-size: 1.75rem !important;
    line-height: 1.25;
  }

  .section-header h2,
  .feature-content h2,
  .pre-footer-banner h2 {
    font-size: 1.6rem !important;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }

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

  .footer-bottom-links {
    justify-content: center;
    flex-wrap: wrap;
  }

  .legal-content-box {
    padding: 24px 18px;
  }
}

@media (max-width: 480px) {
  .hero-content h1 {
    font-size: 1.5rem !important;
  }

  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .hero-actions .btn-primary,
  .hero-actions .btn-secondary {
    width: 100%;
    text-align: center;
  }

  .card {
    padding: 22px 18px;
  }

  .form-box {
    padding: 22px 16px;
  }
}
