/* ==========================================================================
   THE HEADBANGERS - Plateforme Institutionnelle Association Loi 1901
   Architecture CSS Fluide & Responsive (Sans Framework)
   RNA: W313023320 | SIREN: 838348845 | 31110 Bagnères-de-Luchon
   ========================================================================== */

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

:root {
  --navy: #0E2335;
  --navy-dark: #081724;
  --navy-light: #163652;
  --teal: #00A3E0;
  --teal-hover: #008ac0;
  --teal-light: #e6f6fc;
  --coral: #E54838;
  --coral-hover: #cf3c2d;
  --coral-light: #fdeeecee;
  --canvas: #F4F6F8;
  --white: #FFFFFF;
  --slate: #1A1A1A;
  --slate-light: #4A5568;
  --muted: #64748B;
  --border: #DDE3EA;
  --border-light: #EEF2F6;
  --shadow-sm: 0 2px 4px rgba(14, 35, 53, 0.05);
  --shadow-md: 0 4px 12px rgba(14, 35, 53, 0.08);
  --shadow-lg: 0 8px 24px rgba(14, 35, 53, 0.12);
  --radius-sm: 2px;
  --font-heading: 'Montserrat', Arial, sans-serif;
  --font-body: 'Open Sans', 'Roboto', sans-serif;
}

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

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

body {
  font-family: var(--font-body);
  font-size: 1.0625rem; /* 17px */
  line-height: 1.6;
  color: var(--slate);
  background-color: var(--canvas);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  text-transform: uppercase;
  line-height: 1.15;
  color: var(--navy);
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 0.75rem;
}

h1 { font-size: 2.25rem; }
h2 { font-size: 1.75rem; }
h3 { font-size: 1.35rem; }
h4 { font-size: 1.15rem; }

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

a {
  color: var(--teal);
  text-decoration: none;
  transition: color 0.2s ease, background-color 0.2s ease, border-color 0.2s ease;
}

a:hover {
  color: var(--teal-hover);
}

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

.container {
  width: 100%;
  max-width: 1240px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}

/* ==========================================================================
   TOP UTILITY STRIP
   ========================================================================== */
.utility-strip {
  background-color: var(--navy-dark);
  color: #c4d1db;
  font-size: 0.8125rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.utility-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 42px;
  flex-wrap: wrap;
  gap: 0.75rem;
  padding-top: 0.25rem;
  padding-bottom: 0.25rem;
}

.utility-left {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.utility-badge {
  background-color: rgba(255, 255, 255, 0.1);
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-sm);
  color: #fff;
  font-weight: 600;
  letter-spacing: 0.03em;
}

.utility-right {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.utility-link {
  color: #c4d1db;
  text-decoration: none;
  font-weight: 500;
}

.utility-link:hover {
  color: #ffffff;
  text-decoration: underline;
}

.btn-donate-strip {
  background-color: var(--coral);
  color: #ffffff !important;
  font-family: var(--font-heading);
  text-transform: uppercase;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  padding: 0.5rem 1rem;
  border-radius: var(--radius-sm);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  white-space: nowrap;
}

.btn-donate-strip:hover {
  background-color: var(--coral-hover);
  color: #ffffff !important;
}

/* ==========================================================================
   MAIN NAVIGATION
   ========================================================================== */
.main-header {
  background-color: var(--white);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: var(--shadow-sm);
}

.nav-wrapper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 76px;
}

.brand-block {
  display: flex;
  flex-direction: column;
}

.brand-title {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 900;
  color: var(--navy);
  letter-spacing: 0.04em;
  text-decoration: none;
  line-height: 1.1;
}

.brand-subtitle {
  font-size: 0.75rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 600;
}

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

.nav-item {
  position: relative;
}

.nav-link {
  font-family: var(--font-heading);
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--navy);
  padding: 1.25rem 0.85rem;
  display: flex;
  align-items: center;
  gap: 0.35rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  min-height: 44px;
}

.nav-link:hover, .nav-item:hover > .nav-link {
  color: var(--teal);
}

.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  background-color: var(--white);
  min-width: 250px;
  border-top: 3px solid var(--teal);
  box-shadow: var(--shadow-lg);
  list-style: none;
  padding: 0.5rem 0;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
  z-index: 999;
}

.nav-item:hover .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-item a {
  display: block;
  padding: 0.65rem 1.25rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--slate);
  text-decoration: none;
  min-height: 44px;
  display: flex;
  align-items: center;
}

.dropdown-item a:hover {
  background-color: var(--canvas);
  color: var(--teal);
  padding-left: 1.45rem;
}

.nav-toggle-btn {
  display: none;
  background: transparent;
  border: 1px solid var(--border);
  padding: 0.5rem 0.75rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  min-width: 44px;
  min-height: 44px;
  align-items: center;
  justify-content: center;
}

.nav-toggle-bar {
  display: block;
  width: 22px;
  height: 2px;
  background-color: var(--navy);
  margin: 4px 0;
}

/* ==========================================================================
   BUTTONS & CTAs
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  text-transform: uppercase;
  font-weight: 700;
  font-size: 0.875rem;
  letter-spacing: 0.05em;
  padding: 0.75rem 1.5rem; /* 2x horizontal padding rule */
  border-radius: var(--radius-sm);
  text-decoration: none;
  cursor: pointer;
  border: 2px solid transparent;
  transition: background-color 0.2s ease, transform 0.15s ease, border-color 0.2s ease;
  min-height: 44px;
  white-space: nowrap;
}

.btn-primary {
  background-color: var(--teal);
  color: #ffffff !important;
  border-color: var(--teal);
}

.btn-primary:hover {
  background-color: var(--teal-hover);
  border-color: var(--teal-hover);
  transform: translateY(-1px);
}

.btn-coral {
  background-color: var(--coral);
  color: #ffffff !important;
  border-color: var(--coral);
}

.btn-coral:hover {
  background-color: var(--coral-hover);
  border-color: var(--coral-hover);
  transform: translateY(-1px);
}

.btn-outline {
  background-color: transparent;
  color: var(--navy) !important;
  border-color: var(--navy);
}

.btn-outline:hover {
  background-color: var(--navy);
  color: #ffffff !important;
}

.btn-outline-white {
  background-color: transparent;
  color: #ffffff !important;
  border-color: #ffffff;
}

.btn-outline-white:hover {
  background-color: #ffffff;
  color: var(--navy) !important;
}

/* ==========================================================================
   HERO SECTIONS
   ========================================================================== */
.hero-portal {
  position: relative;
  background-color: var(--navy);
  color: #ffffff;
  padding: 5rem 0 4.5rem;
  overflow: hidden;
  border-bottom: 4px solid var(--teal);
}

.hero-portal::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: linear-gradient(135deg, rgba(14, 35, 53, 0.94) 0%, rgba(8, 23, 36, 0.85) 100%);
  z-index: 1;
}

.hero-bg-img {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  object-fit: cover;
  z-index: 0;
  opacity: 0.35;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 860px;
}

.hero-badge {
  display: inline-block;
  background-color: var(--teal);
  color: #ffffff;
  font-family: var(--font-heading);
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 0.35rem 0.85rem;
  border-radius: var(--radius-sm);
  margin-bottom: 1.25rem;
}

.hero-portal h1 {
  color: #ffffff;
  font-size: 2.75rem;
  line-height: 1.1;
  margin-bottom: 1.25rem;
}

.hero-lead-summary {
  font-size: 1.25rem;
  line-height: 1.6;
  color: #e2e8f0;
  margin-bottom: 2rem;
  font-weight: 400;
}

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

/* Internal Page Hero */
.page-hero {
  background-color: var(--navy);
  color: #ffffff;
  padding: 3.5rem 0 3rem;
  border-bottom: 4px solid var(--teal);
  position: relative;
}

.page-hero h1 {
  color: #ffffff;
  margin-bottom: 0.5rem;
}

.page-hero p.lead {
  font-size: 1.15rem;
  color: #cbd5e1;
  margin-bottom: 0;
}

.breadcrumbs {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8125rem;
  color: #94a3b8;
  margin-bottom: 1rem;
  text-transform: uppercase;
  font-weight: 600;
  letter-spacing: 0.04em;
}

.breadcrumbs a {
  color: #cbd5e1;
}

.breadcrumbs a:hover {
  color: var(--teal);
}

/* ==========================================================================
   CARDS & GRIDS
   ========================================================================== */
.card {
  background-color: var(--white);
  border-radius: var(--radius-sm);
  border-top: 4px solid var(--teal);
  box-shadow: var(--shadow-sm);
  padding: 2rem;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  position: relative;
  display: flex;
  flex-direction: column;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.card-coral {
  border-top-color: var(--coral);
}

.card-img-wrap {
  margin: -2rem -2rem 1.5rem -2rem;
  overflow: hidden;
  height: 220px;
}

.card-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.card:hover .card-img-wrap img {
  transform: scale(1.03);
}

.card-badge {
  font-family: var(--font-heading);
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--teal);
  margin-bottom: 0.5rem;
}

.card h3 {
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
}

.card p {
  color: var(--slate-light);
  font-size: 0.95rem;
  margin-bottom: 1.25rem;
  flex-grow: 1;
}

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

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

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

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

/* Split Grid */
.split-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}

/* ==========================================================================
   CALLOUTS, SECTIONS & STATUTORY BLOCKS
   ========================================================================== */
.section {
  padding: 4.5rem 0;
}

.section-alt {
  background-color: var(--white);
}

.section-header {
  margin-bottom: 2.75rem;
  text-align: left;
}

.section-tag {
  color: var(--teal);
  font-family: var(--font-heading);
  font-size: 0.8125rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 0.5rem;
}

.statutory-callout {
  background-color: #f0f7fb;
  border-left: 4px solid var(--teal);
  padding: 2rem 2.25rem;
  border-radius: var(--radius-sm);
  margin: 2.5rem 0;
}

.statutory-callout h3 {
  color: var(--navy);
  margin-bottom: 0.75rem;
}

.statutory-quote {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--navy);
  font-style: italic;
  line-height: 1.6;
  margin-top: 0.75rem;
}

.teal-intake-banner {
  background-color: var(--teal);
  color: #ffffff;
  padding: 3.5rem 0;
  border-radius: var(--radius-sm);
  margin: 3rem 0;
}

.teal-intake-banner h2 {
  color: #ffffff;
  margin-bottom: 0.75rem;
}

.teal-intake-banner p {
  color: #f0f9ff;
  font-size: 1.1rem;
}

.teal-form {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-top: 1.5rem;
}

.teal-form input {
  flex: 1;
  min-width: 260px;
  padding: 0.75rem 1.25rem;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.4);
  font-size: 1rem;
  background-color: #ffffff;
  color: var(--slate);
  min-height: 44px;
}

.circular-update-card {
  text-align: center;
  background-color: var(--white);
  padding: 1.75rem 1rem;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
  border-top: 3px solid var(--teal);
}

.circular-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background-color: var(--teal-light);
  color: var(--teal);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.25rem;
  font-size: 1.5rem;
  font-weight: 800;
  font-family: var(--font-heading);
}

/* ==========================================================================
   TABLES & FINANCIAL DISCLOSURES
   ========================================================================== */
.table-responsive {
  width: 100%;
  overflow-x: auto;
  margin: 2rem 0;
  border: 1px solid var(--border);
  background-color: var(--white);
  border-radius: var(--radius-sm);
}

.table-custom {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}

.table-custom th, .table-custom td {
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--border-light);
}

.table-custom th {
  background-color: var(--navy);
  color: #ffffff;
  font-family: var(--font-heading);
  text-transform: uppercase;
  font-size: 0.8125rem;
  letter-spacing: 0.05em;
}

.table-custom tr:nth-child(even) {
  background-color: #fafbfc;
}

.table-custom tr:hover {
  background-color: #f1f5f9;
}

.badge-status {
  display: inline-block;
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-sm);
  font-family: var(--font-heading);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  background-color: #e6f6fc;
  color: #0077a8;
}

.badge-coral {
  background-color: #fee2e2;
  color: #991b1b;
}

/* ==========================================================================
   FORMS & INTAKE MODULES
   ========================================================================== */
.form-group {
  margin-bottom: 1.5rem;
}

.form-label {
  display: block;
  font-family: var(--font-heading);
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

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

.form-control:focus {
  outline: none;
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(0, 163, 224, 0.15);
}

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

/* ==========================================================================
   FOOTER ARCHITECTURE
   ========================================================================== */
.master-footer {
  background-color: var(--navy);
  color: #cbd5e1;
  padding-top: 4.5rem;
  border-top: 4px solid var(--teal);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1.25fr 1.75fr;
  gap: 3rem;
  margin-bottom: 4rem;
}

.footer-col h4 {
  color: #ffffff;
  font-size: 1.0625rem;
  margin-bottom: 1.25rem;
  position: relative;
  padding-bottom: 0.5rem;
}

.footer-col h4::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 36px;
  height: 2px;
  background-color: var(--teal);
}

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

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

.footer-links a {
  color: #94a3b8;
  font-size: 0.9375rem;
  text-decoration: none;
}

.footer-links a:hover {
  color: #ffffff;
  padding-left: 4px;
}

.footer-legal-notice {
  font-size: 0.875rem;
  line-height: 1.6;
  color: #94a3b8;
}

.footer-bottom-strip {
  background-color: var(--navy-dark);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  padding: 1.75rem 0;
  color: #94a3b8;
  font-size: 0.8125rem;
  line-height: 1.6;
}

.footer-bottom-strip strong {
  color: #ffffff;
}

/* ==========================================================================
   RESPONSIVE BREAKPOINTS (992px & 768px)
   ========================================================================== */
@media (max-width: 992px) {
  .grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }
  .grid-5 {
    grid-template-columns: repeat(3, 1fr);
  }
  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 2.5rem;
  }
  .split-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
}

@media (max-width: 768px) {
  /* Force all multi-column CSS Grid structures to single column */
  .grid-2, .grid-3, .grid-4, .grid-5, .footer-grid, .split-grid {
    grid-template-columns: 1fr !important;
  }

  h1 { font-size: 1.85rem; }
  h2 { font-size: 1.45rem; }
  h3 { font-size: 1.2rem; }

  .hero-portal {
    padding: 3.5rem 0 3rem;
  }
  .hero-portal h1 {
    font-size: 2rem;
  }
  .hero-lead-summary {
    font-size: 1.05rem;
  }

  .utility-inner {
    flex-direction: column;
    align-items: flex-start;
  }
  .utility-right {
    width: 100%;
    justify-content: space-between;
  }

  .nav-toggle-btn {
    display: flex;
  }

  .nav-menu {
    display: none;
    flex-direction: column;
    width: 100%;
    background-color: var(--white);
    border-top: 1px solid var(--border);
    padding: 1rem 0;
  }

  .nav-menu.active {
    display: flex;
  }

  .nav-item {
    width: 100%;
  }

  .nav-link {
    padding: 0.85rem 1.25rem;
    width: 100%;
    justify-content: space-between;
  }

  .dropdown-menu {
    position: static;
    opacity: 1;
    visibility: visible;
    transform: none;
    box-shadow: none;
    border-top: none;
    border-left: 3px solid var(--teal);
    background-color: var(--canvas);
    margin-left: 1.25rem;
    margin-right: 1.25rem;
    display: none;
  }

  .nav-item.dropdown-open .dropdown-menu {
    display: block;
  }

  .teal-form {
    flex-direction: column;
  }
}
