/* --- Variables --- */
:root {
  --color-bg: #f8fafc;
  --color-surface: #ffffff;
  --color-primary: #0e7490;
  --color-primary-dark: #0c636d;
  --color-accent: #10b981;
  --color-text: #1e293b;
  --color-text-muted: #64748b;
  --font-display: 'DM Serif Display', Georgia, serif;
  --font-body: 'Outfit', system-ui, sans-serif;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.08), 0 2px 4px -2px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.08), 0 4px 6px -4px rgba(0, 0, 0, 0.04);
  --radius: 12px;
  --radius-lg: 20px;
  --transition: 0.3s ease;
}

/* --- Reset & base --- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--color-text);
  background: var(--color-bg);
  overflow-x: hidden;
}

/* --- Header --- */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 1rem 1.5rem;
  background: rgba(255, 255, 255, 0.9);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow-sm);
  transition: background var(--transition), box-shadow var(--transition);
}
.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.logo {
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--color-primary);
  text-decoration: none;
  letter-spacing: 0.02em;
}
.nav {
  display: flex;
  gap: 1.5rem;
}
.nav a {
  color: var(--color-text);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  transition: color var(--transition);
}
.nav a:hover { color: var(--color-primary); }

/* --- Hero --- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6rem 1.5rem 4rem;
  overflow: hidden;
}
.hero-bg {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, #0e7490 0%, #0c636d 35%, #0f766e 70%, #059669 100%);
  background-size: 200% 200%;
  animation: gradientShift 12s ease infinite;
}
.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 80% 50% at 50% 0%, rgba(255,255,255,0.12) 0%, transparent 50%);
  pointer-events: none;
}
@keyframes gradientShift {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}
.hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
  color: #fff;
}
.hero-title {
  font-family: var(--font-display);
  font-size: clamp(3rem, 10vw, 5rem);
  font-weight: 400;
  margin: 0 0 0.25rem;
  letter-spacing: -0.02em;
  text-shadow: 0 2px 20px rgba(0,0,0,0.15);
}
.hero-subtitle {
  font-size: clamp(1.1rem, 2.5vw, 1.35rem);
  font-weight: 400;
  margin: 0;
  opacity: 0.95;
  letter-spacing: 0.02em;
}
.hero-by {
  margin: 1rem 0 2rem;
  font-size: 1rem;
  opacity: 0.9;
}
.hero-by strong { font-weight: 600; }
.hero-cta {
  display: inline-block;
  padding: 0.9rem 2rem;
  background: #fff;
  color: var(--color-primary-dark);
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none;
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  transition: transform var(--transition), box-shadow var(--transition);
}
.hero-cta:hover {
  transform: scale(1.05);
  box-shadow: 0 14px 28px rgba(0, 0, 0, 0.15);
}

/* --- Animations: load --- */
.animate-on-load {
  opacity: 0;
  transform: translateY(24px);
  animation: fadeInUp 0.8s ease forwards;
}
@keyframes fadeInUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* --- Animations: scroll (triggered by JS) --- */
.animate-on-scroll {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.animate-on-scroll.is-visible {
  opacity: 1;
  transform: translateY(0);
}
.card-0.animate-on-scroll { transition-delay: 0s; }
.card-1.animate-on-scroll { transition-delay: 0.1s; }
.card-2.animate-on-scroll { transition-delay: 0.2s; }
.card-3.animate-on-scroll { transition-delay: 0.3s; }

/* --- Sections common --- */
.section {
  padding: 4rem 1.5rem;
}
.container {
  max-width: 1000px;
  margin: 0 auto;
}
.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  font-weight: 400;
  color: var(--color-text);
  margin: 0 0 1rem;
  text-align: center;
}
.section-lead {
  font-size: 1.1rem;
  color: var(--color-text-muted);
  max-width: 640px;
  margin: 0 auto;
  text-align: center;
  line-height: 1.7;
}

/* --- Presentation --- */
.presentation { background: var(--color-surface); }

/* --- Fonctionnalités (cards) --- */
.fonctionnalites .section-title { margin-bottom: 2rem; }
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
}
.card {
  background: var(--color-surface);
  padding: 1.75rem;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  transition: transform var(--transition), box-shadow var(--transition);
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}
.card-icon {
  font-size: 2rem;
  margin-bottom: 0.75rem;
  line-height: 1;
}
.card-title {
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--color-text);
  margin: 0 0 0.5rem;
}
.card-text {
  font-size: 0.95rem;
  color: var(--color-text-muted);
  margin: 0;
  line-height: 1.55;
}

/* --- Téléchargements (Adoptium-style) --- */
.telechargements {
  background: linear-gradient(180deg, var(--color-bg) 0%, #e2e8f0 100%);
}
.download-block {
  text-align: center;
  padding: 2rem 1rem;
}
.download-block .section-title { margin-bottom: 0.5rem; }
.download-intro {
  color: var(--color-text-muted);
  margin: 0 0 2rem;
  font-size: 1rem;
}
.download-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: center;
  align-items: center;
}
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 1rem 1.75rem;
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  border-radius: var(--radius);
  transition: transform var(--transition), box-shadow var(--transition), background var(--transition), color var(--transition);
  border: none;
  cursor: pointer;
}
.btn-primary {
  flex-direction: column;
  background: var(--color-primary);
  color: #fff;
  box-shadow: 0 4px 14px rgba(14, 116, 144, 0.4);
}
.btn-primary:hover {
  background: var(--color-primary-dark);
  transform: scale(1.03);
  box-shadow: 0 6px 20px rgba(14, 116, 144, 0.45);
}
.btn-primary .btn-label { display: block; }
.btn-primary .btn-hint {
  display: block;
  font-size: 0.75rem;
  font-weight: 500;
  opacity: 0.9;
}
.btn-secondary {
  background: var(--color-surface);
  color: var(--color-text);
  border: 2px solid var(--color-primary);
}
.btn-secondary:hover {
  background: rgba(14, 116, 144, 0.08);
  transform: scale(1.02);
}

/* --- Footer --- */
.footer {
  padding: 2rem 1.5rem;
  background: var(--color-text);
  color: rgba(255, 255, 255, 0.85);
  text-align: center;
}
.footer-brand {
  font-weight: 700;
  font-size: 1.1rem;
  margin: 0 0 0.25rem;
}
.footer-copy {
  font-size: 0.9rem;
  margin: 0;
  opacity: 0.8;
}

/* --- Responsive --- */
@media (max-width: 640px) {
  .nav { gap: 1rem; }
  .nav a { font-size: 0.9rem; }
  .download-buttons { flex-direction: column; }
  .btn { width: 100%; max-width: 280px; }
}
