/* ==========================================================================
   AMICALE LAIQUE SAINTES - Official Non-Profit Stylesheet (Association Loi 1901)
   Architecture: Fluid CSS Grid & Flexbox | Mobile-First Performance Engine
   ========================================================================== */

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

:root {
  --top-bar-bg: #E64A19;
  --navy-primary: #0A4260;
  --navy-hover: #073046;
  --action-blue: #0082AD;
  --action-blue-hover: #00688B;
  --magenta-accent: #C2185B;
  --magenta-hover: #9C1045;
  --green-accent: #2E7D32;
  --green-hover: #1B5E20;
  --alert-cta: #D32F2F;
  --alert-cta-hover: #B71C1C;
  --heading-color: #0F172A;
  --body-color: #475569;
  --muted-slate: #64748B;
  --card-white: #FFFFFF;
  --surface-light: #F8FAFC;
  --border-color: #E5E7EB;
  --font-heading: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-body: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --max-width: 1240px;
  --radius-md: 12px;
  --radius-sm: 8px;
  --shadow-soft: 0 4px 15px rgba(0, 0, 0, 0.05);
  --shadow-elevated: 0 10px 25px rgba(10, 66, 96, 0.08);
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  color: var(--body-color);
  background-color: var(--surface-light);
  line-height: 1.72;
  font-weight: 400;
  overflow-x: hidden;
}

/* Typography & Semantic Hierarchy */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  color: var(--heading-color);
  line-height: 1.25;
  margin-bottom: 1rem;
  font-weight: 700;
  text-wrap: balance;
}

h1 {
  font-size: clamp(2rem, 4vw, 3rem);
  letter-spacing: -0.02em;
}

h2 {
  font-size: clamp(1.5rem, 2.8vw, 2.15rem);
  letter-spacing: -0.015em;
  margin-top: 2.25rem;
}

h3 {
  font-size: clamp(1.2rem, 2vw, 1.45rem);
  margin-top: 1.5rem;
}

p {
  margin-bottom: 1.25rem;
  max-width: 75ch;
}

a {
  color: var(--action-blue);
  text-decoration: none;
  transition: color 0.18s ease, background-color 0.18s ease, border-color 0.18s ease;
}

a:hover {
  color: var(--action-blue-hover);
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid var(--action-blue);
  outline-offset: 2px;
}

/* Documentary Photography & Figcaption Protocol */
figure {
  margin: 0 0 1.5rem 0;
  width: 100%;
}

img,
.doc-photo {
  width: 100%;
  height: auto;
  border-radius: 12px;
  border: 1px solid #E5E7EB;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
  margin: 20px 0 8px 0;
  object-fit: cover;
  display: block;
  max-height: 520px;
}

figcaption {
  font-size: 0.875rem;
  color: #64748B;
  margin-bottom: 20px;
  font-style: italic;
  line-height: 1.5;
}

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

.section-block {
  padding: 3.5rem 0;
}

.section-block.bg-white {
  background-color: var(--card-white);
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
}

/* Top Official Notice Bar (#E64A19) */
.top-bar {
  background-color: var(--top-bar-bg);
  color: #FFFFFF;
  font-size: 0.875rem;
  font-weight: 500;
  padding: 0.5rem 0;
}

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

.top-bar-notice {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.top-bar-links {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.top-bar-links a {
  color: #FFFFFF;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}

.top-bar-links a:hover {
  color: #F8FAFC;
  opacity: 0.9;
}

/* Main Navigation Header (#0A4260) */
.site-header {
  background-color: var(--navy-primary);
  color: #FFFFFF;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 4px 12px rgba(10, 66, 96, 0.18);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 76px;
  gap: 1.5rem;
}

.brand-logo {
  display: flex;
  flex-direction: column;
  color: #FFFFFF;
  text-decoration: none;
  padding: 0.5rem 0;
}

.brand-logo:hover {
  color: #FFFFFF;
}

.brand-title {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: #FFFFFF;
  line-height: 1.15;
}

.brand-subtitle {
  font-size: 0.75rem;
  color: #CBD5E1;
  font-weight: 500;
  letter-spacing: 0.02em;
}

/* Mobile Menu Button */
.mobile-nav-toggle {
  display: none;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.35);
  color: #FFFFFF;
  border-radius: var(--radius-sm);
  min-width: 44px;
  min-height: 44px;
  padding: 0.5rem 0.75rem;
  font-family: var(--font-heading);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  align-items: center;
  gap: 0.5rem;
}

/* Navigation Dropdown Architecture */
.main-nav ul {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.nav-item {
  position: relative;
}

.nav-link,
.dropdown-toggle {
  color: #FFFFFF;
  font-weight: 600;
  font-size: 0.94rem;
  padding: 0.65rem 0.9rem;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  border-radius: var(--radius-sm);
  background: transparent;
  border: none;
  cursor: pointer;
  font-family: var(--font-body);
  white-space: nowrap;
}

.nav-link:hover,
.dropdown-toggle:hover,
.nav-item:focus-within > .dropdown-toggle {
  background-color: var(--navy-hover);
  color: #FFFFFF;
}

.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 240px;
  background-color: var(--card-white);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-elevated);
  padding: 0.5rem 0;
  display: none;
  flex-direction: column;
  z-index: 1100;
}

.nav-item:hover > .dropdown-menu,
.nav-item:focus-within > .dropdown-menu,
.nav-item.open > .dropdown-menu {
  display: flex;
}

.dropdown-menu li {
  width: 100%;
}

.dropdown-menu a {
  color: var(--heading-color);
  font-size: 0.9rem;
  font-weight: 500;
  padding: 0.65rem 1.15rem;
  min-height: 44px;
  display: flex;
  align-items: center;
  width: 100%;
}

.dropdown-menu a:hover {
  background-color: var(--surface-light);
  color: var(--navy-primary);
}

.nav-cta-btn {
  background-color: var(--alert-cta);
  color: #FFFFFF !important;
  padding: 0.65rem 1.15rem;
  border-radius: var(--radius-sm);
  font-weight: 700;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  margin-left: 0.4rem;
}

.nav-cta-btn:hover {
  background-color: var(--alert-cta-hover);
}

/* Hero Section */
.hero-banner {
  background: linear-gradient(135deg, #0A4260 0%, #073046 100%);
  color: #FFFFFF;
  padding: 3.5rem 0;
  border-bottom: 4px solid var(--action-blue);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 2.5rem;
  align-items: center;
}

.hero-banner h1 {
  color: #FFFFFF;
  margin-bottom: 1rem;
}

.hero-summary-lead {
  font-size: 1.15rem;
  color: #F1F5F9;
  line-height: 1.65;
  margin-bottom: 1.5rem;
  background: rgba(255, 255, 255, 0.08);
  padding: 1.15rem 1.35rem;
  border-left: 4px solid #E64A19;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

.hero-meta-line {
  font-size: 0.875rem;
  color: #CBD5E1;
  margin-bottom: 1rem;
  letter-spacing: 0.02em;
}

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

.hero-figure figcaption {
  color: #CBD5E1;
}

/* Buttons & Interactive Controls (Min 44x44px touch target) */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius-sm);
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  text-decoration: none;
  border: none;
  transition: background-color 0.18s ease, transform 0.15s ease;
  white-space: nowrap;
}

.btn-primary {
  background-color: var(--alert-cta);
  color: #FFFFFF;
}

.btn-primary:hover {
  background-color: var(--alert-cta-hover);
  color: #FFFFFF;
}

.btn-action {
  background-color: var(--action-blue);
  color: #FFFFFF;
}

.btn-action:hover {
  background-color: var(--action-blue-hover);
  color: #FFFFFF;
}

.btn-green {
  background-color: var(--green-accent);
  color: #FFFFFF;
}

.btn-green:hover {
  background-color: var(--green-hover);
  color: #FFFFFF;
}

.btn-magenta {
  background-color: var(--magenta-accent);
  color: #FFFFFF;
}

.btn-magenta:hover {
  background-color: var(--magenta-hover);
  color: #FFFFFF;
}

.btn-outline-light {
  background-color: transparent;
  color: #FFFFFF;
  border: 2px solid rgba(255, 255, 255, 0.75);
}

.btn-outline-light:hover {
  background-color: rgba(255, 255, 255, 0.12);
  color: #FFFFFF;
}

/* Standalone 'Notre Mission' Block */
.notre-mission-box {
  background-color: var(--card-white);
  border: 1px solid var(--border-color);
  border-left: 6px solid var(--navy-primary);
  border-radius: var(--radius-md);
  padding: 2.25rem;
  margin: 2.5rem 0;
  box-shadow: var(--shadow-soft);
}

.notre-mission-box h2 {
  margin-top: 0;
  color: var(--navy-primary);
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.notre-mission-box p {
  max-width: 100%;
  font-size: 1.06rem;
  color: var(--heading-color);
  margin-bottom: 0;
}

/* Reinvestment & Public Funding Guarantee Banner */
.funding-guarantee-banner {
  background-color: #EFF6FF;
  border: 1px solid #BFDBFE;
  border-left: 5px solid var(--green-accent);
  border-radius: var(--radius-md);
  padding: 1.5rem 2rem;
  margin: 2rem 0;
}

.funding-guarantee-banner strong {
  color: var(--navy-primary);
  display: block;
  margin-bottom: 0.35rem;
  font-family: var(--font-heading);
  font-size: 1.05rem;
}

/* Grid Systems & Content Cards */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
}

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

.content-card {
  background-color: var(--card-white);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.85rem;
  box-shadow: var(--shadow-soft);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.content-card h3 {
  margin-top: 0.25rem;
  color: var(--navy-primary);
}

.card-meta {
  font-size: 0.82rem;
  color: var(--muted-slate);
  margin-bottom: 0.6rem;
  font-weight: 600;
}

/* Editorial Long-Form Layout */
.editorial-layout {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 3rem;
  align-items: start;
}

.editorial-prose p {
  margin-bottom: 1.35rem;
  text-align: left;
}

.editorial-sidebar {
  background-color: var(--card-white);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.75rem;
  box-shadow: var(--shadow-soft);
  position: sticky;
  top: 96px;
}

/* Data Tables */
.table-responsive {
  width: 100%;
  overflow-x: auto;
  margin: 1.75rem 0;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  background: var(--card-white);
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.94rem;
  font-variant-numeric: tabular-nums;
}

.data-table th,
.data-table td {
  padding: 1rem 1.15rem;
  text-align: left;
  border-bottom: 1px solid var(--border-color);
}

.data-table th {
  background-color: var(--navy-primary);
  color: #FFFFFF;
  font-family: var(--font-heading);
  font-weight: 600;
}

.data-table tr:nth-child(even) {
  background-color: var(--surface-light);
}

/* Forms & AJAX Modal */
.form-card {
  background-color: var(--card-white);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 2.25rem;
  box-shadow: var(--shadow-soft);
}

.form-group {
  margin-bottom: 1.35rem;
}

.form-group label {
  display: block;
  font-weight: 600;
  color: var(--heading-color);
  margin-bottom: 0.45rem;
  font-size: 0.92rem;
}

.form-control {
  width: 100%;
  min-height: 46px;
  padding: 0.75rem 1rem;
  border: 1px solid #CBD5E1;
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: 0.96rem;
  color: var(--heading-color);
  background-color: #FFFFFF;
}

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

.form-checkbox-row {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin-bottom: 1.35rem;
  font-size: 0.9rem;
}

.form-checkbox-row input[type="checkbox"] {
  width: 20px;
  height: 20px;
  margin-top: 0.2rem;
  flex-shrink: 0;
}

/* AJAX Thank You Modal */
.ajax-modal-backdrop {
  position: fixed;
  inset: 0;
  background-color: rgba(15, 23, 42, 0.7);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  padding: 1.5rem;
}

.ajax-modal-backdrop.active {
  display: flex;
}

.ajax-modal-content {
  background-color: var(--card-white);
  border-radius: var(--radius-md);
  max-width: 520px;
  width: 100%;
  padding: 2.25rem;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
  border-top: 6px solid var(--green-accent);
  text-align: left;
}

/* Footer Architecture */
.site-footer {
  background-color: #072A3E;
  color: #E2E8F0;
  padding: 4rem 0 2rem 0;
  margin-top: 4rem;
  border-top: 5px solid var(--top-bar-bg);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  gap: 2.25rem;
  margin-bottom: 2.5rem;
}

.site-footer h3,
.site-footer h4 {
  color: #FFFFFF;
  font-size: 1.1rem;
  margin-top: 0;
  margin-bottom: 1rem;
}

.footer-links {
  list-style: none;
}

.footer-links li {
  margin-bottom: 0.55rem;
}

.footer-links a {
  color: #CBD5E1;
  font-size: 0.92rem;
  min-height: 36px;
  display: inline-flex;
  align-items: center;
}

.footer-links a:hover {
  color: #FFFFFF;
  text-decoration: underline;
}

.footer-disclosure-box {
  background-color: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-sm);
  padding: 1.35rem 1.5rem;
  margin-bottom: 2rem;
  font-size: 0.9rem;
  color: #F1F5F9;
  line-height: 1.65;
}

.footer-bottom-bar {
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  padding-top: 1.5rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  font-size: 0.86rem;
  color: #CBD5E1;
}

.footer-legal-nav {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.footer-legal-nav a {
  color: #FFFFFF;
  font-weight: 600;
  text-decoration: underline;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}

/* Responsive Breakpoints */
@media (max-width: 992px) {
  .hero-grid,
  .editorial-layout,
  .grid-3 {
    grid-template-columns: 1fr;
  }

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

  .editorial-sidebar {
    position: static;
  }

  .mobile-nav-toggle {
    display: inline-flex;
  }

  .main-nav {
    display: none;
    width: 100%;
    padding: 1rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.15);
  }

  .main-nav.active {
    display: block;
  }

  .header-inner {
    flex-wrap: wrap;
  }

  .main-nav ul {
    flex-direction: column;
    align-items: stretch;
    gap: 0.25rem;
  }

  .nav-link,
  .dropdown-toggle {
    width: 100%;
    justify-content: space-between;
  }

  .dropdown-menu {
    position: static;
    box-shadow: none;
    border: none;
    background-color: rgba(0, 0, 0, 0.2);
    padding-left: 1rem;
  }

  .dropdown-menu a {
    color: #E2E8F0;
  }

  .dropdown-menu a:hover {
    background-color: rgba(255, 255, 255, 0.08);
    color: #FFFFFF;
  }

  .nav-cta-btn {
    margin-left: 0;
    margin-top: 0.5rem;
    justify-content: center;
  }
}

@media (max-width: 768px) {
  .grid-2,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .top-bar-inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.35rem;
  }

  .section-block {
    padding: 2.5rem 0;
  }

  .notre-mission-box,
  .form-card,
  .content-card {
    padding: 1.35rem;
  }

  .footer-bottom-bar {
    flex-direction: column;
    align-items: flex-start;
  }
}
