/* Aperium Data - PostgreSQL Expertise */
:root {
  --blue-900: #0a1628;
  --blue-800: #0f2240;
  --blue-700: #143a6b;
  --blue-600: #1a5296;
  --blue-500: #2068b8;
  --blue-400: #3a8ad8;
  --blue-300: #6aafe8;
  --blue-100: #dceaf8;
  --white: #ffffff;
  --gray-50: #f8fafc;
  --gray-100: #f1f5f9;
  --gray-200: #e2e8f0;
  --gray-300: #cbd5e1;
  --gray-600: #475569;
  --gray-700: #334155;
  --gray-800: #1e293b;
  --accent: #f59e0b;
  --accent-hover: #d97706;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--gray-800);
  line-height: 1.6;
  background: var(--white);
}

/* NAV */
nav {
  position: fixed;
  top: 0;
  width: 100%;
  background: rgba(10, 22, 40, 0.95);
  backdrop-filter: blur(10px);
  z-index: 1000;
  padding: 0 2rem;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

nav .nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 70px;
}

nav .logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: var(--white);
}

nav .logo img {
  height: 42px;
  width: auto;
}

nav .logo span {
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

nav .logo span em {
  font-style: normal;
  color: var(--blue-400);
}

nav ul {
  list-style: none;
  display: flex;
  gap: 0.25rem;
}

nav ul li a {
  color: var(--gray-300);
  text-decoration: none;
  padding: 0.5rem 1rem;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 500;
  transition: all 0.2s;
}

nav ul li a:hover,
nav ul li a.active {
  color: var(--white);
  background: rgba(255,255,255,0.1);
}

/* Language dropdown */
.lang-dropdown {
  position: relative;
}

.lang-dropdown > a {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.lang-dropdown > a::after {
  content: '';
  border: 4px solid transparent;
  border-top: 5px solid currentColor;
  margin-top: 2px;
}

.lang-dropdown ul {
  display: none !important;
  position: absolute;
  top: 100%;
  right: 0;
  background: var(--blue-900);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 10px;
  padding: 0.4rem;
  min-width: 140px;
  flex-direction: column !important;
  gap: 0 !important;
  box-shadow: 0 8px 30px rgba(0,0,0,0.4);
}

.lang-dropdown:hover ul {
  display: flex !important;
}

.lang-dropdown ul li a {
  display: block;
  padding: 0.5rem 0.85rem;
  border-radius: 6px;
  font-size: 0.9rem;
  white-space: nowrap;
}

@media (max-width: 768px) {
  .lang-dropdown ul {
    position: static;
    background: transparent;
    border: none;
    box-shadow: none;
    padding: 0 0 0 1rem;
  }

  .lang-dropdown:hover ul {
    display: flex !important;
  }
}

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 4px;
}

.hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--white);
  border-radius: 2px;
  transition: all 0.3s;
}

/* HERO */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(160deg, var(--blue-900) 0%, var(--blue-800) 40%, var(--blue-700) 100%);
  padding: 6rem 2rem 4rem;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 80%;
  height: 200%;
  background: radial-gradient(ellipse, rgba(32, 104, 184, 0.15) 0%, transparent 70%);
  pointer-events: none;
}

.hero-content {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  position: relative;
  z-index: 1;
}

.hero-text h1 {
  font-size: 3.2rem;
  font-weight: 800;
  color: var(--white);
  line-height: 1.15;
  margin-bottom: 1.5rem;
  letter-spacing: -0.03em;
}

.hero-text h1 .highlight {
  background: linear-gradient(135deg, var(--blue-300), var(--accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-text p {
  font-size: 1.2rem;
  color: var(--blue-100);
  margin-bottom: 2rem;
  max-width: 520px;
  opacity: 0.9;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 1.75rem;
  border-radius: 10px;
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.25s;
  cursor: pointer;
  border: none;
}

.btn-primary {
  background: var(--accent);
  color: var(--blue-900);
}

.btn-primary:hover {
  background: var(--accent-hover);
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(245, 158, 11, 0.3);
}

.btn-secondary {
  background: rgba(255,255,255,0.1);
  color: var(--white);
  border: 1px solid rgba(255,255,255,0.2);
}

.btn-secondary:hover {
  background: rgba(255,255,255,0.2);
  transform: translateY(-2px);
}

.hero-visual {
  display: flex;
  justify-content: center;
  align-items: center;
}

.hero-logo {
  width: 340px;
  height: 340px;
  object-fit: contain;
  filter: drop-shadow(0 20px 60px rgba(0,0,0,0.4));
  animation: float 6s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-15px); }
}

/* SECTIONS */
section {
  padding: 5rem 2rem;
}

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

.section-header h2 {
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--blue-900);
  margin-bottom: 0.75rem;
  letter-spacing: -0.02em;
}

.section-header p {
  font-size: 1.1rem;
  color: var(--gray-600);
}

.container {
  max-width: 1200px;
  margin: 0 auto;
}

/* EXPERTISE CARDS */
.expertise-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.expertise-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: 16px;
  padding: 2rem;
  transition: all 0.3s;
}

.expertise-card:hover {
  border-color: var(--blue-400);
  box-shadow: 0 8px 30px rgba(20, 58, 107, 0.1);
  transform: translateY(-4px);
}

.expertise-card .icon {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  background: var(--blue-100);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 1.25rem;
}

.expertise-card h3 {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--blue-900);
  margin-bottom: 0.5rem;
}

.expertise-card p {
  color: var(--gray-600);
  font-size: 0.95rem;
}

/* BG ALT */
.bg-alt {
  background: var(--gray-50);
}

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

.formation-card {
  background: var(--white);
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--gray-200);
  transition: all 0.3s;
  display: flex;
  flex-direction: column;
}

.formation-card:hover {
  box-shadow: 0 12px 40px rgba(20, 58, 107, 0.12);
  transform: translateY(-4px);
}

.formation-header {
  padding: 1.75rem 1.75rem 0;
}

.formation-badge {
  display: inline-block;
  padding: 0.3rem 0.75rem;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.badge-debutant { background: #dcfce7; color: #166534; }
.badge-avance { background: #dbeafe; color: #1e40af; }
.badge-expert { background: #fce7f3; color: #9d174d; }

.formation-card h3 {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--blue-900);
  margin-bottom: 0.5rem;
  line-height: 1.3;
}

.formation-card .duration {
  font-size: 0.9rem;
  color: var(--gray-600);
  margin-bottom: 1rem;
}

.formation-body {
  padding: 0 1.75rem 1.75rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.formation-body ul {
  list-style: none;
  margin-bottom: 1.5rem;
  flex: 1;
}

.formation-body ul li {
  padding: 0.35rem 0;
  font-size: 0.9rem;
  color: var(--gray-700);
  padding-left: 1.5rem;
  position: relative;
}

.formation-body ul li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.7rem;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--blue-400);
}

.formation-card .btn {
  width: 100%;
  justify-content: center;
}

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

.service-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: 16px;
  padding: 2.25rem;
  display: flex;
  gap: 1.5rem;
  align-items: flex-start;
  transition: all 0.3s;
}

.service-card:hover {
  border-color: var(--blue-400);
  box-shadow: 0 8px 30px rgba(20, 58, 107, 0.1);
}

.service-icon {
  width: 56px;
  height: 56px;
  min-width: 56px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--blue-600), var(--blue-700));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
}

.service-content h3 {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--blue-900);
  margin-bottom: 0.4rem;
}

.service-content p {
  color: var(--gray-600);
  font-size: 0.95rem;
  margin-bottom: 0.75rem;
}

.service-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.service-tag {
  display: inline-block;
  padding: 0.2rem 0.6rem;
  background: var(--blue-100);
  color: var(--blue-700);
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 500;
}

/* CTA */
.cta-section {
  background: linear-gradient(160deg, var(--blue-900), var(--blue-700));
  text-align: center;
  padding: 5rem 2rem;
}

.cta-section h2 {
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--white);
  margin-bottom: 1rem;
}

.cta-section p {
  color: var(--blue-100);
  font-size: 1.1rem;
  margin-bottom: 2rem;
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
}

/* FOOTER */
footer {
  background: var(--blue-900);
  color: var(--gray-300);
  padding: 3rem 2rem 2rem;
  text-align: center;
}

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

footer .footer-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}

footer .footer-logo img {
  height: 36px;
}

footer .footer-logo span {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--white);
}

footer .footer-links {
  display: flex;
  justify-content: center;
  gap: 2rem;
  margin-bottom: 2rem;
}

footer .footer-links a {
  color: var(--gray-300);
  text-decoration: none;
  font-size: 0.95rem;
  transition: color 0.2s;
}

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

footer .copyright {
  font-size: 0.85rem;
  color: var(--gray-600);
  border-top: 1px solid rgba(255,255,255,0.08);
  padding-top: 1.5rem;
}

/* PAGE HERO (for sub-pages) */
.page-hero {
  background: linear-gradient(160deg, var(--blue-900) 0%, var(--blue-800) 60%, var(--blue-700) 100%);
  padding: 8rem 2rem 4rem;
  text-align: center;
}

.page-hero h1 {
  font-size: 2.8rem;
  font-weight: 800;
  color: var(--white);
  margin-bottom: 0.75rem;
}

.page-hero p {
  font-size: 1.15rem;
  color: var(--blue-100);
  max-width: 560px;
  margin: 0 auto;
}

/* RESPONSIVE */
@media (max-width: 968px) {
  .hero-content {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .hero-text h1 { font-size: 2.4rem; }
  .hero-text p { margin: 0 auto 2rem; }
  .hero-buttons { justify-content: center; }

  .hero-visual { order: -1; }
  .hero-logo { width: 220px; height: 220px; }

  .expertise-grid,
  .formations-grid {
    grid-template-columns: 1fr;
    max-width: 480px;
    margin: 0 auto;
  }

  .services-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  nav ul {
    display: none;
    position: absolute;
    top: 70px;
    left: 0;
    right: 0;
    background: var(--blue-900);
    flex-direction: column;
    padding: 1rem;
    border-bottom: 1px solid rgba(255,255,255,0.08);
  }

  nav ul.open {
    display: flex;
  }

  nav ul li a {
    display: block;
    padding: 0.75rem 1rem;
  }

  .hamburger {
    display: flex;
  }

  .hero-text h1 { font-size: 2rem; }
  .page-hero h1 { font-size: 2rem; }
  .section-header h2 { font-size: 1.8rem; }

  .service-card {
    flex-direction: column;
  }
}
