/* =====================================================
   Étincelle Sereine — style.css
   Tech Futuristic aesthetic: sleek, neon accents, modern type
   Mobile-first, Flexbox-only, with mobile menu + cookie banner
   ===================================================== */

/* ----------------------------
   1) CSS Reset & Base Setup
   ---------------------------- */
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
img { max-width: 100%; height: auto; display: block; }
a { text-decoration: none; color: inherit; }
ul, ol { margin: 0 0 16px 20px; padding: 0; }
button { background: none; border: none; cursor: pointer; }
:focus-visible { outline: 2px solid #2EC4B6; outline-offset: 2px; }

/* ----------------------------
   2) Theme Variables (with fallbacks)
   ---------------------------- */
:root {
  --primary: #0A3D62;      /* Brand primary */
  --secondary: #2EC4B6;    /* Brand secondary (teal/neon) */
  --accent: #F6F9FC;       /* Brand accent (light) */
  --bg-dark: #071F2A;      /* Futuristic deep navy */
  --bg-darker: #04141C;    /* Deeper navy for contrast */
  --text-light: #E6F1F6;   /* Light text on dark */
  --text-muted: #AFC7D6;   /* Muted text */
  --text-dark: #0A2A3C;    /* Dark text on light */
  --surface: rgba(255, 255, 255, 0.06); /* Glass-like surface */
  --border: rgba(255, 255, 255, 0.12);
  --shadow: 0 10px 30px rgba(0,0,0,0.35);
  --radius-sm: 10px;
  --radius-md: 14px;
  --radius-lg: 18px;
  --transition: 0.25s ease;
}

/* ----------------------------
   3) Base Typography
   ---------------------------- */
body {
  font-family: Verdana, Geneva, Tahoma, sans-serif; /* Brand body */
  color: var(--text-light);
  background-color: var(--bg-dark); /* Solid fallback */
  background-image: linear-gradient(180deg, #05151E 0%, #0A3D62 100%); /* subtle gradient enhancement */
  line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
  font-family: "Trebuchet MS", "Segoe UI", Arial, sans-serif; /* Brand display */
  margin: 0 0 16px 0;
  letter-spacing: 0.2px;
}

h1 { font-size: 32px; line-height: 1.2; }
h2 { font-size: 24px; line-height: 1.3; }
h3 { font-size: 18px; line-height: 1.4; }

p { margin: 0 0 16px 0; color: var(--text-light); }
strong { color: #FFFFFF; font-weight: 700; }
.subheadline { color: var(--text-muted); font-size: 16px; }

/* Larger screens typography */
@media (min-width: 768px) {
  h1 { font-size: 48px; }
  h2 { font-size: 32px; }
  h3 { font-size: 20px; }
  .subheadline { font-size: 18px; }
}

/* Links */
a { color: var(--secondary); transition: color var(--transition), opacity var(--transition); }
a:hover { color: #3BE2D0; }
a:focus-visible { outline: 2px solid var(--secondary); outline-offset: 2px; }

/* ----------------------------
   4) Layout Containers (Flexbox-only)
   ---------------------------- */
.container {
  display: flex; /* Flex container */
  flex-direction: column;
  gap: 20px;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 16px;
}
.content-wrapper {
  display: flex; /* Flex container */
  flex-direction: column;
  gap: 20px;
}

/* Mandatory spacing patterns */
.section { margin-bottom: 60px; padding: 40px 20px; }
.card-container { display: flex; flex-wrap: wrap; gap: 24px; }
.card { margin-bottom: 20px; position: relative; }
.content-grid { display: flex; flex-wrap: wrap; gap: 20px; justify-content: space-between; }
.text-image-section { display: flex; align-items: center; gap: 30px; flex-wrap: wrap; }
.testimonial-card { display: flex; align-items: center; gap: 20px; padding: 20px; }
.feature-item { display: flex; flex-direction: column; align-items: flex-start; gap: 15px; }

/* Prevent overlap with generous spacing */
section { padding: 40px 0; }
section + section { margin-top: 20px; }

/* ----------------------------
   5) Header & Navigation
   ---------------------------- */
header { position: relative; z-index: 10; background: rgba(4, 20, 28, 0.7); border-bottom: 1px solid var(--border); backdrop-filter: blur(6px); }
header .container { padding-top: 14px; padding-bottom: 14px; }
header .content-wrapper {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 20px;
}

.logo { display: flex; align-items: center; }
.logo img { height: 36px; width: auto; }
.tagline { font-size: 12px; color: var(--text-muted); margin-left: 0; }

.main-nav { display: none; align-items: center; gap: 18px; }
.main-nav a { color: var(--text-light); padding: 8px 10px; border-radius: 8px; }
.main-nav a[aria-current="page"] { color: #0A1A22; background: var(--secondary); }
.main-nav a:hover { background: rgba(46, 196, 182, 0.15); }

.header-ctas { display: flex; align-items: center; gap: 10px; margin-left: auto; }

/* Mobile burger */
.mobile-menu-toggle {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; font-size: 20px; border-radius: 10px;
  color: var(--text-light); background: var(--surface);
  transition: background var(--transition), transform var(--transition);
}
.mobile-menu-toggle:hover { background: rgba(46,196,182,0.18); transform: translateY(-1px); }

/* Mobile Menu Overlay */
.mobile-menu {
  position: fixed; inset: 0; z-index: 1000;
  display: flex; flex-direction: column; align-items: stretch; gap: 16px;
  background: rgba(4, 20, 28, 0.96);
  transform: translateX(100%);
  transition: transform 0.35s ease;
  padding: 16px;
}
.mobile-menu.open,
.mobile-menu[aria-hidden="false"],
.mobile-menu[data-open="true"] { transform: translateX(0); }

.mobile-menu-close {
  align-self: flex-end; width: 44px; height: 44px; font-size: 20px; color: var(--text-light);
  display: inline-flex; align-items: center; justify-content: center; border-radius: 10px; background: var(--surface);
}
.mobile-menu-close:hover { background: rgba(46,196,182,0.18); }

.mobile-nav { display: flex; flex-direction: column; gap: 8px; }
.mobile-nav a {
  display: flex; align-items: center;
  padding: 14px 12px; border-radius: 10px;
  color: var(--text-light); background: rgba(255,255,255,0.03);
  border: 1px solid var(--border); font-size: 16px;
}
.mobile-nav a:hover { background: rgba(46,196,182,0.12); border-color: rgba(46,196,182,0.45); }
.mobile-nav a[aria-current="page"] { background: rgba(46,196,182,0.25); border-color: var(--secondary); }

/* Desktop nav */
@media (min-width: 992px) {
  .main-nav { display: flex; }
  .mobile-menu-toggle { display: none; }
}

/* ----------------------------
   6) Buttons
   ---------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 8px; padding: 12px 16px; border-radius: 12px; font-weight: 700;
  transition: background var(--transition), transform var(--transition), box-shadow var(--transition), color var(--transition);
  border: 1px solid transparent; position: relative; overflow: hidden;
}
.btn:hover { transform: translateY(-2px); }

.btn-primary {
  background: var(--secondary); color: #08222B; border-color: var(--secondary);
  box-shadow: 0 8px 24px rgba(46,196,182,0.35), 0 0 0 0 rgba(46,196,182,0.4);
}
.btn-primary:hover {
  background: #36D7C5; box-shadow: 0 12px 28px rgba(46,196,182,0.45), 0 0 0 6px rgba(46,196,182,0.15);
}

.btn-secondary {
  background: transparent; color: var(--text-light);
  border-color: rgba(46,196,182,0.5); background-color: rgba(46,196,182,0.06);
}
.btn-secondary:hover { background-color: rgba(46,196,182,0.16); border-color: var(--secondary); }

/* ----------------------------
   7) Hero Sections & Common Blocks
   ---------------------------- */
.hero { padding: 60px 0; background: linear-gradient(180deg, rgba(10,61,98,0.35) 0%, rgba(10,61,98,0.05) 100%); border-bottom: 1px solid var(--border); }
.hero .content-wrapper { display: flex; flex-direction: column; align-items: flex-start; gap: 16px; }
.hero h1 { text-shadow: 0 0 24px rgba(46,196,182,0.25); }

.value-bullets { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.value-bullets li { display: flex; align-items: center; gap: 10px; color: var(--text-light); background: rgba(255,255,255,0.04); border: 1px solid var(--border); padding: 10px 12px; border-radius: 10px; }
.value-bullets img { width: 18px; height: 18px; }

.search-placeholder { display: flex; align-items: center; padding: 12px 14px; border: 1px dashed rgba(46,196,182,0.45); background: rgba(46,196,182,0.06); border-radius: 10px; color: var(--text-muted); }
.search-placeholder a { color: var(--secondary); text-decoration: underline; }

.hero-ctas { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }

.trust-badges { display: flex; flex-wrap: wrap; gap: 10px; }
.trust-badges span { display: flex; align-items: center; gap: 8px; padding: 8px 10px; border-radius: 999px; color: var(--text-light); background: rgba(255,255,255,0.04); border: 1px solid var(--border); }
.trust-badges img { width: 16px; height: 16px; }

/* ----------------------------
   8) Text Sections, Articles, Lists, KPIs
   ---------------------------- */
.text-section { display: flex; flex-direction: column; gap: 12px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-md); padding: 16px; }
.text-section h3 { color: #FFFFFF; }

article { display: flex; flex-direction: column; gap: 8px; padding: 16px; border-radius: var(--radius-md); background: rgba(255,255,255,0.05); border: 1px solid var(--border); transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition); }
article:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: rgba(46,196,182,0.4); }

.kpis, .micro-stats { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 12px; }
.kpis li, .micro-stats li { background: rgba(255,255,255,0.05); border: 1px solid var(--border); border-radius: 10px; padding: 10px 12px; }
.kpis strong { font-size: 20px; color: #FFFFFF; }

.accreditations { display: flex; flex-direction: column; gap: 10px; }
.accreditations p { display: flex; align-items: center; gap: 8px; margin: 0; padding: 10px 12px; background: rgba(255,255,255,0.05); border: 1px solid var(--border); border-radius: 10px; }
.accreditations img { width: 18px; height: 18px; }

.pagination { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 8px; }
.pagination a { display: inline-flex; align-items: center; justify-content: center; padding: 8px 12px; border-radius: 10px; background: rgba(255,255,255,0.05); border: 1px solid var(--border); color: var(--text-light); }
.pagination a:hover { border-color: var(--secondary); background: rgba(46,196,182,0.14); }

.note { color: var(--text-muted); font-size: 14px; }
.support-highlight { display: flex; align-items: center; gap: 10px; padding: 12px; border-radius: 10px; background: rgba(46,196,182,0.08); border: 1px solid rgba(46,196,182,0.45); color: var(--text-light); }
.support-highlight img { width: 18px; height: 18px; }

/* ----------------------------
   9) Testimonials (Light background, dark text for contrast)
   ---------------------------- */
.testimonial-card {
  background: var(--accent); /* light */
  color: var(--text-dark);   /* dark text */
  border: 1px solid #DDE6EE;
  border-radius: var(--radius-md);
  box-shadow: 0 8px 24px rgba(10,61,98,0.12);
}
.testimonial-card p { color: var(--text-dark); margin: 0; }
.testimonial-card strong { color: #08222B; }

/* ----------------------------
   10) Ordered & Unordered Lists tweaks
   ---------------------------- */
ol { display: flex; flex-direction: column; gap: 8px; padding-left: 20px; }
ul { display: flex; flex-direction: column; gap: 8px; }

/* ----------------------------
   11) Address & Contact blocks
   ---------------------------- */
address { font-style: normal; color: var(--text-light); background: rgba(255,255,255,0.04); border: 1px solid var(--border); border-radius: 10px; padding: 12px; }
address a { color: var(--secondary); text-decoration: underline; }

/* ----------------------------
   12) Footer
   ---------------------------- */
footer { background: var(--bg-darker); border-top: 1px solid var(--border); }
footer section { padding: 40px 0; }

.newsletter { display: flex; flex-direction: column; gap: 8px; background: rgba(255,255,255,0.05); border: 1px solid var(--border); border-radius: var(--radius-md); padding: 16px; }

.footer-links { display: flex; flex-direction: column; gap: 20px; }
.footer-links > div { display: flex; flex-direction: column; gap: 8px; }
.footer-links nav { display: flex; flex-direction: column; gap: 6px; }
.footer-links a { color: var(--text-light); opacity: 0.9; }
.footer-links a:hover { opacity: 1; color: #DFF7F4; }

.social { display: flex; align-items: center; gap: 10px; color: var(--text-muted); }

@media (min-width: 768px) {
  .footer-links { flex-direction: row; justify-content: space-between; }
}

/* ----------------------------
   13) Page-specific small enhancements
   ---------------------------- */
/* Pricing CTA block */
.cta { display: flex; align-items: center; gap: 10px; margin-top: 10px; }

/* Header tagline visibility on larger screens */
@media (min-width: 992px) {
  .tagline { margin-left: 8px; font-size: 13px; }
}

/* ----------------------------
   14) Responsive alignment rules for text-image sections
   ---------------------------- */
@media (max-width: 768px) {
  .text-image-section { flex-direction: column; }
}

/* ----------------------------
   15) Cards general utility (optional usage via class)
   ---------------------------- */
.card { background: rgba(255,255,255,0.05); border: 1px solid var(--border); border-radius: var(--radius-md); padding: 16px; transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition); }
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: rgba(46,196,182,0.4); }

/* ----------------------------
   16) Accessibility & Micro-interactions
   ---------------------------- */
.btn:focus-visible, .main-nav a:focus-visible, .mobile-nav a:focus-visible { box-shadow: 0 0 0 4px rgba(46,196,182,0.25); }

/* ----------------------------
   17) Mobile Menu Slide Animations (already covered)
   ---------------------------- */
/* Ensured via transform translateX transitions above */

/* ----------------------------
   18) Cookie Consent Banner & Modal
   ---------------------------- */
.cookie-banner {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 1100;
  display: flex; flex-direction: column; gap: 12px; align-items: stretch;
  background: #5a7693; color: var(--text-dark);
  border-top: 1px solid #D6E3EE; box-shadow: 0 -8px 24px rgba(10,61,98,0.12);
  padding: 14px 16px;
  transform: translateY(100%);
  transition: transform 0.35s ease;
}
.cookie-banner.show,
.cookie-banner[data-visible="true"] { transform: translateY(0); }

.cookie-banner .cookie-row { display: flex; flex-direction: column; gap: 10px; }
.cookie-actions { display: flex; flex-wrap: wrap; gap: 10px; }

.btn-cookie { display: inline-flex; align-items: center; justify-content: center; padding: 10px 14px; border-radius: 10px; border: 1px solid #C3D3E0; color: var(--text-dark); background: #FFFFFF; transition: background var(--transition), transform var(--transition); }
.btn-cookie:hover { background: #F2F7FB; transform: translateY(-1px); }
.btn-accept { background: var(--secondary); color: #08222B; border-color: var(--secondary); }
.btn-accept:hover { background: #36D7C5; }
.btn-reject { background: #FFFFFF; color: var(--text-dark); }
.btn-settings { background: #E9F3FA; color: #0A2A3C; }

/* Cookie Preferences Modal */
.cookie-overlay {
  position: fixed; inset: 0; z-index: 1150;
  display: flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,0.55);
  opacity: 0; pointer-events: none;
  transition: opacity 0.25s ease;
}
.cookie-overlay.open { opacity: 1; pointer-events: auto; }

.cookie-modal {
  display: flex; flex-direction: column; gap: 14px; width: 92%; max-width: 640px;
  background: #FFFFFF; color: var(--text-dark);
  border-radius: 14px; border: 1px solid #D6E3EE; box-shadow: 0 20px 50px rgba(10,61,98,0.25);
  padding: 18px;
}
.cookie-modal h3 { margin: 0; color: #08222B; }
.cookie-modal p, .cookie-modal li { color: #17384B; }
.cookie-modal .modal-actions { display: flex; flex-wrap: wrap; gap: 10px; justify-content: flex-end; }

/* ----------------------------
   19) Utility Classes
   ---------------------------- */
.hide { display: none !important; }
.muted { color: var(--text-muted); }
.center { display: flex; align-items: center; justify-content: center; }

/* ----------------------------
   20) Section-specific subtle surfaces for readability
   ---------------------------- */
main section .container .content-wrapper { background: rgba(255,255,255,0.03); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 16px; }
.hero .container .content-wrapper { background: transparent; border: none; padding: 0; }

/* ----------------------------
   21) Ensure adequate gaps everywhere
   ---------------------------- */
.content-wrapper > * + * { margin-top: 0; }
.container > * + * { margin-top: 0; }

/* ----------------------------
   22) Desktop refinements
   ---------------------------- */
@media (min-width: 992px) {
  .hero { padding: 90px 0; }
  main section .container .content-wrapper { padding: 24px; }
  header .content-wrapper { gap: 12px 24px; }
}

/* ----------------------------
   23) High-contrast adjustments for review sections (safety)
   ---------------------------- */
section:has(.testimonial-card) .content-wrapper { background: rgba(255,255,255,0.02); }

/* ----------------------------
   24) ARIA current/active states
   ---------------------------- */
[aria-current="page"], [aria-current="true"] { font-weight: 700; }

/* ----------------------------
   25) Prevent absolute positioning for content cards
   ---------------------------- */
/* No absolute positioning used for content cards; only relative for safe effects above */

/* ----------------------------
   26) Touch targets and spacing
   ---------------------------- */
nav a, .btn, button { min-height: 40px; }

/* ----------------------------
   27) Print safety (optional minimal)
   ---------------------------- */
@media print {
  header, footer, .mobile-menu, .cookie-banner, .cookie-overlay { display: none !important; }
  body { background: #FFFFFF; color: #000; }
}
