:root {
  color-scheme: dark;
  --bg: #0b0f14;
  --bg-soft: #111825;
  --bg-glow: #0e1624;
  --ink: #e6f1ff;
  --muted: #96a0ad;
  --accent: #46fcd3;
  --accent-strong: #1be4b9;
  --stroke: rgba(70, 252, 211, 0.25);
  --shadow: 0 20px 50px rgba(4, 8, 16, 0.55);
  --radius: 18px;
  --radius-sm: 14px;
  --max-width: 1100px;
  --title-font: "Space Mono", "JetBrains Mono", "IBM Plex Mono", "SFMono-Regular", monospace;
  --body-font: "Sora", "Manrope", "Avenir Next", "Segoe UI", sans-serif;
}

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

body {
  font-family: var(--body-font);
  color: var(--ink);
  background: radial-gradient(circle at 20% 20%, #1a2a3d 0%, #0b0f14 55%, #080b10 100%);
  min-height: 100vh;
  letter-spacing: 0.01em;
}

.page {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 36px 20px 60px;
  display: flex;
  flex-direction: column;
  gap: 40px;
}

.site-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  padding: 18px 20px;
  border: 1px solid rgba(70, 252, 211, 0.12);
  border-radius: var(--radius);
  background: linear-gradient(140deg, rgba(15, 23, 35, 0.9), rgba(11, 15, 20, 0.95));
  box-shadow: var(--shadow);
}

.brand {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.35em;
  font-size: 0.7rem;
  color: var(--accent);
}

h1 {
  font-family: var(--title-font);
  font-size: clamp(2.4rem, 4vw, 4rem);
  line-height: 1.05;
}

.subtitle {
  color: var(--muted);
  font-size: 1.05rem;
}

.header-actions {
  display: flex;
  flex-direction: column;
  gap: 16px;
  align-items: flex-end;
}

.main-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.nav-link {
  text-decoration: none;
  color: var(--ink);
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(13, 21, 32, 0.8);
  border: 1px solid rgba(70, 252, 211, 0.15);
  font-size: 0.85rem;
  font-weight: 600;
  transition: border 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link:focus-visible {
  color: var(--accent);
  border-color: var(--accent);
  transform: translateY(-1px);
}

.nav-link.is-active {
  color: #091017;
  background: var(--accent);
  border-color: var(--accent);
}

.lang-switch {
  display: flex;
  gap: 10px;
  align-items: center;
}

.lang-btn {
  border: none;
  background: rgba(15, 23, 35, 0.9);
  padding: 10px 12px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  color: var(--ink);
  border: 1px solid rgba(70, 252, 211, 0.2);
  transition: transform 0.2s ease, box-shadow 0.2s ease, color 0.2s ease;
}

.lang-btn:hover,
.lang-btn:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(4, 8, 16, 0.5);
  color: var(--accent);
}

.lang-btn[aria-pressed="true"] {
  background: rgba(70, 252, 211, 0.2);
  color: var(--accent);
  border-color: var(--accent);
}

.flag {
  width: 20px;
  height: 14px;
  border-radius: 2px;
  box-shadow: inset 0 0 0 1px rgba(70, 252, 211, 0.4);
}

.flag-it {
  background: linear-gradient(90deg, #18a957 0 33%, #f5f5f5 33% 66%, #d6423b 66% 100%);
}

.flag-en {
  background: linear-gradient(90deg, #123f8f 0 33%, #f5f5f5 33% 66%, #d6423b 66% 100%);
}

.flag-fr {
  background: linear-gradient(90deg, #1a3fa0 0 33%, #f5f5f5 33% 66%, #d6423b 66% 100%);
}

.hero {
  display: grid;
  grid-template-columns: 1.25fr 0.75fr;
  gap: 32px;
  align-items: stretch;
  animation: fade-in 0.8s ease both;
}

.hero h2,
.section-header h2 {
  font-family: var(--title-font);
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  margin-bottom: 12px;
}

.lead,
.section-lead {
  font-size: 1.05rem;
  line-height: 1.7;
  color: var(--muted);
}

.hero-card {
  background: linear-gradient(160deg, rgba(17, 24, 37, 0.95), rgba(10, 15, 22, 0.98));
  padding: 24px;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  gap: 14px;
  border: 1px solid rgba(70, 252, 211, 0.15);
}

.hero-card ul {
  list-style: none;
  display: grid;
  gap: 10px;
  color: var(--muted);
  font-size: 0.95rem;
}

.cta-row {
  margin-top: 20px;
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.cta {
  text-decoration: none;
  background: var(--accent);
  color: #071019;
  padding: 10px 18px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.9rem;
  letter-spacing: 0.03em;
  box-shadow: 0 12px 24px rgba(4, 8, 16, 0.45);
  transition: transform 0.2s ease;
}

.cta:hover,
.cta:focus-visible {
  transform: translateY(-2px);
}

.cta.ghost {
  background: transparent;
  color: var(--accent);
  border: 1px solid var(--accent);
}

.grid {
  display: grid;
  gap: 24px;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
}

.panel {
  background: linear-gradient(160deg, rgba(18, 26, 38, 0.95), rgba(11, 16, 24, 0.98));
  padding: 24px;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow);
  display: grid;
  gap: 16px;
  border: 1px solid rgba(70, 252, 211, 0.15);
  animation: rise 0.8s ease both;
}

.panel h3 {
  font-family: var(--title-font);
  font-size: 1.3rem;
}

.panel h3 a {
  color: inherit;
  text-decoration: none;
}

.panel h3 a:hover,
.panel h3 a:focus-visible {
  color: var(--accent);
}

.panel-link-card {
  text-decoration: none;
  color: inherit;
  cursor: pointer;
}

.panel-link-card:hover,
.panel-link-card:focus-visible {
  border-color: var(--accent);
  transform: translateY(-2px);
}

.panel-link {
  text-decoration: none;
  color: var(--accent);
  font-weight: 600;
  font-size: 0.9rem;
}

.section-header {
  padding: 10px 0;
  display: grid;
  gap: 8px;
}

.timeline {
  display: grid;
  gap: 24px;
}

.item-meta {
  color: var(--muted);
  font-size: 0.9rem;
}

.chips {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chips li {
  background: rgba(70, 252, 211, 0.12);
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 0.85rem;
  border: 1px solid rgba(70, 252, 211, 0.2);
}

.list {
  list-style: none;
  display: grid;
  gap: 8px;
  color: var(--muted);
}

.site-footer {
  text-align: center;
  color: var(--muted);
  font-size: 0.95rem;
  padding-top: 12px;
}

@keyframes fade-in {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}

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

@media (max-width: 980px) {
  .site-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .header-actions {
    align-items: flex-start;
  }

  .main-nav {
    justify-content: flex-start;
  }

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

@media (max-width: 600px) {
  .page {
    padding: 28px 16px 50px;
  }

  .nav-link {
    font-size: 0.78rem;
  }

  .lang-btn {
    padding: 8px 10px;
  }

  .lang-code {
    display: none;
  }
}
