/* 2TP Services - Modern 2026 Impeccable UI & Design System */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@400;500;600;700;800;900&family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&display=swap');

:root {
  /* Brand Palette */
  --primary: #1E40AF;
  --primary-hover: #1D4ED8;
  --primary-light: #EFF6FF;
  --primary-dark: #1E3A8A;
  
  --secondary: #0D9488;
  --secondary-hover: #0F766E;
  
  --accent: #EAB308;
  --accent-light: #FEF08A;
  --accent-glow: rgba(234, 179, 8, 0.35);
  
  /* Surface & Background */
  --bg-main: #F8FAFC;
  --bg-surface: #FFFFFF;
  --bg-card: #FFFFFF;
  --bg-glass: rgba(255, 255, 255, 0.92);
  
  --text-main: #0F172A;
  --text-muted: #475569;
  --text-light: #94A3B8;
  
  --border-color: #E2E8F0;
  
  /* Elevation Shadows */
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 14px -2px rgba(0, 0, 0, 0.06), 0 2px 6px -1px rgba(0, 0, 0, 0.03);
  --shadow-lg: 0 12px 32px -4px rgba(30, 64, 175, 0.14), 0 4px 12px -2px rgba(0, 0, 0, 0.04);
  --shadow-hover: 0 20px 40px -6px rgba(30, 64, 175, 0.22);
  
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-full: 9999px;
  
  --font-heading: 'Outfit', -apple-system, sans-serif;
  --font-body: 'Plus Jakarta Sans', -apple-system, sans-serif;
  
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="dark"] {
  --bg-main: #0B1120;
  --bg-surface: #1E293B;
  --bg-card: #1E293B;
  --bg-glass: rgba(30, 41, 59, 0.92);
  
  --text-main: #F8FAFC;
  --text-muted: #CBD5E1;
  --text-light: #64748B;
  
  --border-color: #334155;
  --shadow-md: 0 4px 14px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 12px 32px rgba(0, 0, 0, 0.4);
}

/* Keyframe Animations */
@keyframes floatCard {
  0% { transform: translateY(0px) rotate(0deg); }
  50% { transform: translateY(-10px) rotate(0.5deg); }
  100% { transform: translateY(0px) rotate(0deg); }
}

@keyframes pulseBtn {
  0% { box-shadow: 0 0 0 0 rgba(30, 64, 175, 0.5); }
  70% { box-shadow: 0 0 0 12px rgba(30, 64, 175, 0); }
  100% { box-shadow: 0 0 0 0 rgba(30, 64, 175, 0); }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes rotateGlow {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Reset & Base Layout */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

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

body {
  font-family: var(--font-body);
  background-color: var(--bg-main);
  color: var(--text-main);
  line-height: 1.6;
  transition: var(--transition);
  overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.25;
  color: var(--text-main);
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: var(--transition);
}

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

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

/* Top Announcement Bar */
.top-bar {
  background: linear-gradient(90deg, #0F172A 0%, #1E3A8A 50%, #1E40AF 100%);
  color: #FFFFFF;
  font-size: 0.875rem;
  padding: 0.55rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

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

.top-bar-contact {
  display: flex;
  gap: 1.5rem;
  align-items: center;
}

.top-bar-contact a {
  color: #E2E8F0;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-weight: 500;
}

.top-bar-contact a:hover {
  color: var(--accent);
}

.top-bar-badge {
  background: rgba(234, 179, 8, 0.2);
  color: var(--accent-light);
  padding: 0.25rem 0.85rem;
  border-radius: var(--radius-full);
  font-weight: 700;
  font-size: 0.75rem;
  border: 1px solid rgba(234, 179, 8, 0.35);
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

/* Navigation Bar */
.navbar {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--bg-glass);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-color);
  padding: 0.75rem 0;
  transition: var(--transition);
}

.navbar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-brand {
  display: flex;
  align-items: center;
  text-decoration: none;
}

.nav-brand img {
  height: 58px;
  width: auto;
  object-fit: contain;
  transition: var(--transition);
}

.nav-brand:hover img {
  transform: scale(1.03);
}

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

.nav-link {
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text-main);
  position: relative;
  padding: 0.5rem 0.25rem;
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2.5px;
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  border-radius: 2px;
  transition: var(--transition);
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

.nav-link.active {
  color: var(--primary);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

/* Page Header (Subpages) */
.page-banner {
  background: linear-gradient(135deg, #0F172A 0%, #1E3A8A 60%, #0D9488 100%);
  color: #FFF;
  padding: 4.5rem 0 3.5rem;
  position: relative;
  overflow: hidden;
}

.page-banner-title {
  font-size: clamp(1.75rem, 7vw, 2.8rem);
  font-weight: 800;
  color: #FFF;
  margin-bottom: 0.75rem;
}

.breadcrumb {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.breadcrumb a {
  color: #94A3B8;
}

.breadcrumb a:hover {
  color: #FFF;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.8rem 1.6rem;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.95rem;
  border-radius: var(--radius-md);
  border: none;
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-hover));
  color: #FFFFFF;
  box-shadow: 0 4px 14px rgba(30, 64, 175, 0.35);
}

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(30, 64, 175, 0.45);
  color: #FFFFFF;
}

.pulse-btn {
  animation: pulseBtn 2.5s infinite;
}

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

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

.btn-whatsapp {
  background: #25D366;
  color: #FFFFFF;
}

.btn-whatsapp:hover {
  background: #1EBE5D;
  color: #FFFFFF;
  transform: translateY(-2px);
}

/* Hero Section */
.hero {
  position: relative;
  padding: 5rem 0 4rem;
  background: radial-gradient(circle at 90% 10%, rgba(30, 64, 175, 0.08) 0%, transparent 60%),
              radial-gradient(circle at 10% 90%, rgba(13, 148, 136, 0.08) 0%, transparent 60%);
  animation: fadeInUp 0.8s ease-out;
}

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

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--primary-light);
  color: var(--primary);
  padding: 0.45rem 1.1rem;
  border-radius: var(--radius-full);
  font-weight: 700;
  font-size: 0.85rem;
  margin-bottom: 1.5rem;
  border: 1px solid rgba(30, 64, 175, 0.2);
}

.hero-title {
  font-size: clamp(2rem, 8vw, 3.4rem);
  font-weight: 900;
  letter-spacing: -0.02em;
  margin-bottom: 1.25rem;
}

.hero-title span {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-desc {
  font-size: clamp(1rem, 4vw, 1.15rem);
  color: var(--text-muted);
  margin-bottom: 2rem;
}

.hero-ctas {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 2.5rem;
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border-color);
}

.stat-item {
  display: flex;
  flex-direction: column;
}

.stat-val {
  font-family: var(--font-heading);
  font-size: 2.2rem;
  font-weight: 900;
  color: var(--primary);
}

.stat-lbl {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 600;
}

.hero-image-card {
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border-color);
  animation: floatCard 6s ease-in-out infinite;
  transition: var(--transition);
}

.hero-image-card:hover {
  animation-play-state: paused;
  transform: scale(1.02);
  box-shadow: var(--shadow-hover);
}

.hero-image-card img {
  width: 100%;
  border-radius: var(--radius-md);
  display: block;
}

/* Common Sections */
.section {
  padding: 5.5rem 0;
  animation: fadeInUp 0.6s ease-out;
}

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

.section-header {
  text-align: center;
  max-width: 750px;
  margin: 0 auto 3.5rem;
}

.section-subtitle {
  font-family: var(--font-heading);
  color: var(--secondary);
  font-weight: 800;
  text-transform: uppercase;
  font-size: 0.85rem;
  letter-spacing: 0.1em;
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
}

.section-title {
  font-size: clamp(1.6rem, 6vw, 2.5rem);
  margin-bottom: 1rem;
}

.section-desc {
  color: var(--text-muted);
  font-size: 1.1rem;
}

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

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

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

@media (max-width: 992px) {
  .grid-4, .grid-3 {
    grid-template-columns: repeat(2, 1fr);
  }
  .hero-grid {
    grid-template-columns: 1fr;
  }
}

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

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 2.25rem;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.feature-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  opacity: 0;
  transition: var(--transition);
}

.feature-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-hover);
  border-color: var(--primary);
}

.feature-card:hover::before {
  opacity: 1;
}

.feature-icon {
  width: 64px;
  height: 64px;
  border-radius: var(--radius-md);
  background: var(--primary-light);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.75rem;
  margin-bottom: 1.25rem;
  transition: var(--transition);
}

.feature-card:hover .feature-icon {
  background: var(--primary);
  color: #FFF;
  transform: scale(1.1) rotate(5deg);
}

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

.feature-card p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* Founders Quote Box */
.founders-box {
  background: linear-gradient(135deg, rgba(30, 64, 175, 0.05), rgba(13, 148, 136, 0.05));
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  position: relative;
  box-shadow: var(--shadow-md);
}

.quote-icon {
  font-size: 3rem;
  color: var(--primary);
  opacity: 0.25;
  margin-bottom: 1rem;
}

.founders-text {
  font-size: 1.1rem;
  line-height: 1.8;
  color: var(--text-main);
  margin-bottom: 1.5rem;
  font-style: italic;
}

.founders-author {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.author-avatar {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-full);
  background: var(--primary);
  color: #FFF;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-family: var(--font-heading);
}

/* Calculator Box */
.calc-box {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-lg);
  padding: 3rem;
}

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

.form-label {
  display: block;
  font-weight: 700;
  font-size: 0.95rem;
  margin-bottom: 0.5rem;
}

.form-control {
  width: 100%;
  padding: 0.9rem 1.1rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  background: var(--bg-main);
  color: var(--text-main);
  font-family: var(--font-body);
  font-size: 0.95rem;
  transition: var(--transition);
}

.form-control:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(30, 64, 175, 0.15);
}

/* ULTRA-RICH MULTI-COLUMN FOOTER STYLING */
.footer {
  background: #0B1120;
  color: #F8FAFC;
  padding: 4.5rem 0 2rem;
  border-top: 1px solid #1E293B;
  position: relative;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1.2fr 1.2fr 1.6fr;
  gap: 3rem;
  margin-bottom: 3.5rem;
}

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

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

.footer-brand p {
  color: #94A3B8;
  margin: 1rem 0 1.5rem;
  font-size: 0.95rem;
  line-height: 1.6;
}

.footer-socials {
  display: flex;
  gap: 0.75rem;
}

.footer-socials a {
  width: 42px;
  height: 42px;
  border-radius: var(--radius-full);
  background: #1E293B;
  color: #94A3B8;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  transition: var(--transition);
}

.footer-socials a:hover {
  background: var(--primary);
  color: #FFFFFF;
  transform: translateY(-3px) scale(1.1);
  box-shadow: 0 4px 14px rgba(30, 64, 175, 0.4);
}

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

.footer-col h4::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 35px;
  height: 2.5px;
  background: var(--secondary);
  border-radius: 2px;
}

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

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

.footer-links a {
  color: #94A3B8;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  transition: var(--transition);
}

.footer-links a:hover {
  color: #FFFFFF;
  transform: translateX(4px);
}

.footer-bottom {
  border-top: 1px solid #1E293B;
  padding-top: 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  color: #64748B;
  font-size: 0.875rem;
}

.footer-badge {
  background: rgba(13, 148, 136, 0.15);
  color: #2DD4BF;
  border: 1px solid rgba(45, 212, 191, 0.3);
  padding: 0.2rem 0.65rem;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

/* ==========================================================================
   Adaptation mobile
   La feuille d'origine ne prevoyait rien pour la navigation : logo, six liens
   et bouton tenaient sur une seule rangee, d'ou pres de 570 px de debordement
   horizontal sur un telephone.
   ========================================================================== */

/* Le bouton hamburger n'existe qu'en dessous du point de rupture. */
.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm, 8px);
  color: inherit;
  font-size: 1.6rem;
  line-height: 1;
  padding: 0.35rem 0.55rem;
  cursor: pointer;
}

.nav-brand img {
  height: 58px;
  width: auto;
}

/* Panneau deroulant, replie par defaut. */
.nav-mobile {
  display: none;
  flex-direction: column;
  gap: 0.35rem;
  padding: 0 1rem 1.25rem;
  border-top: 1px solid var(--border-color);
}

.nav-mobile ul {
  list-style: none;
  margin: 0 0 0.75rem;
  padding: 0;
}

.nav-mobile li + li {
  border-top: 1px solid var(--border-color);
}

.nav-mobile .nav-link {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.95rem 0.25rem;
  font-size: 1rem;
}

.nav-mobile .nav-link.is-active {
  color: var(--primary, #1E40AF);
  font-weight: 700;
}

.nav-mobile .btn {
  width: 100%;
  justify-content: center;
  margin-top: 0.35rem;
}

@media (max-width: 992px) {
  /* La navigation horizontale et le bouton cedent la place au hamburger. */
  .nav-desktop,
  .nav-actions {
    display: none;
  }

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

  .nav-mobile.is-open {
    display: flex;
  }

  /* Le panneau occupe la hauteur restante et defile s'il est trop long. */
  .nav-mobile.is-open {
    max-height: calc(100vh - 120px);
    overflow-y: auto;
  }

  .nav-brand img {
    height: 46px;
  }
}

@media (max-width: 640px) {
  /* Les coordonnees de la barre superieure passent a la ligne plutot que
     de forcer la largeur de la page. */
  .top-bar {
    font-size: 0.78rem;
  }

  .top-bar .container,
  .top-bar-contact {
    flex-wrap: wrap;
    gap: 0.35rem 0.9rem;
    justify-content: center;
    text-align: center;
  }

  .nav-brand img {
    height: 40px;
  }

  /* Rien ne doit imposer une largeur superieure a l'ecran. */
  img,
  table,
  pre {
    max-width: 100%;
  }
}

/* Sous 400 px, le bloc « hero » depassait de 14 px : les elements d'une grille
   ont un « min-width: auto » implicite qui les empeche de retrecir sous la
   largeur de leur contenu. Les trois chiffres cote a cote imposaient donc
   leur largeur a toute la colonne. */
@media (max-width: 400px) {
  .hero-grid > *,
  .hero-content,
  .hero-stats > * {
    min-width: 0;
  }

  .hero-stats {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.25rem;
  }

  .stat-val {
    font-size: 1.7rem;
  }

  .container {
    padding: 0 1rem;
  }
}
