/* ============================================
   Atelier CMDA Vitrail
   Light & Neutral Design System
   ============================================ */

/* --- CSS Custom Properties --- */
:root {
  /* Neutral palette — cream, beige, warm grays */
  --bg-primary: #f0e8d8;
  --bg-secondary: #e8dece;
  --bg-card: #f5efe3;
  --bg-elevated: #f2ead9;
  --bg-glass: rgba(255, 255, 255, 0.5);

  --text-primary: #2a2520;
  --text-secondary: #5a5048;
  --text-muted: #8a8179;

  --border-subtle: #e3ddd0;
  --border-medium: #d4ccba;
  --border-accent: #b89760;

  /* Accent — warm, soft, subtle */
  --accent: #a88a5c;
  --accent-light: #c4a572;
  --accent-soft: rgba(168, 138, 92, 0.12);

  /* Soft hints of vitrail color (very muted) */
  --tint-sapphire: rgba(70, 95, 130, 0.06);
  --tint-ruby: rgba(150, 70, 75, 0.06);
  --tint-emerald: rgba(90, 115, 85, 0.06);
  --tint-amber: rgba(180, 140, 80, 0.08);

  /* Typography — simple */
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  /* Spacing */
  --space-xs: 0.5rem;
  --space-sm: 1rem;
  --space-md: 2rem;
  --space-lg: 4rem;
  --space-xl: 6rem;
  --space-2xl: 8rem;

  /* Transitions */
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);

  /* Layout */
  --max-width: 1280px;
  --nav-height: 92px;
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

ul, ol {
  list-style: none;
}

button {
  cursor: pointer;
  border: none;
  background: none;
  font-family: inherit;
  color: inherit;
}

/* --- Typography --- */
h1, h2, h3, h4, h5 {
  font-family: var(--font-body);
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: -0.01em;
  color: var(--text-primary);
}

h1 {
  font-size: clamp(2rem, 4.5vw, 3.5rem);
  font-weight: 400;
  letter-spacing: -0.02em;
}

h2 {
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  font-weight: 500;
}

h3 {
  font-size: clamp(1.1rem, 1.8vw, 1.4rem);
  font-weight: 500;
}

h4 {
  font-size: 1rem;
  font-weight: 500;
}

p {
  color: var(--text-secondary);
  max-width: 65ch;
}

.text-accent {
  color: var(--accent);
}

/* --- Background ambiance --- */
.glass-mosaic {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: -1;
  background:
    radial-gradient(ellipse at 15% 20%, var(--tint-sapphire) 0%, transparent 55%),
    radial-gradient(ellipse at 85% 30%, var(--tint-ruby) 0%, transparent 55%),
    radial-gradient(ellipse at 50% 80%, var(--tint-amber) 0%, transparent 55%),
    radial-gradient(ellipse at 20% 75%, var(--tint-emerald) 0%, transparent 50%);
}

/* Lead line separator */
.lead-line {
  width: 60px;
  height: 1px;
  background: var(--border-medium);
  margin: var(--space-md) 0;
}

.lead-line--center {
  margin-left: auto;
  margin-right: auto;
}

/* --- Navigation --- */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--nav-height);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.3s var(--ease-out), backdrop-filter 0.3s var(--ease-out), box-shadow 0.3s var(--ease-out);
}

.nav.scrolled {
  background: rgba(240, 232, 216, 0.92);
  backdrop-filter: blur(16px);
  box-shadow: 0 1px 0 var(--border-subtle);
}

.nav__inner {
  width: 100%;
  max-width: var(--max-width);
  padding: 0 var(--space-md);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav__brand {
  display: flex;
  flex-direction: column;
  gap: 1px;
  line-height: 1.15;
}

.nav__brand-name {
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-primary);
}

.nav__brand-author {
  font-size: 0.72rem;
  color: var(--text-secondary);
  letter-spacing: 0.02em;
  font-style: italic;
  margin-top: 2px;
}

.nav__brand-title {
  font-size: 0.6rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-top: 1px;
}

.mof-medal {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  display: inline-block;
  vertical-align: middle;
  object-fit: contain;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav__link {
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-secondary);
  transition: color 0.3s var(--ease-out);
  position: relative;
  font-weight: 500;
}

.nav__link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--accent);
  transition: width 0.3s var(--ease-out);
}

.nav__link:hover,
.nav__link.active {
  color: var(--text-primary);
}

.nav__link:hover::after,
.nav__link.active::after {
  width: 100%;
}

/* Dropdown */
.nav__dropdown {
  position: relative;
}

.nav__dropdown-toggle {
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-secondary);
  transition: color 0.3s var(--ease-out);
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 500;
}

.nav__dropdown-toggle:hover {
  color: var(--text-primary);
}

.nav__dropdown-toggle svg {
  width: 10px;
  height: 10px;
  transition: transform 0.3s var(--ease-out);
}

.nav__dropdown:hover .nav__dropdown-toggle svg {
  transform: rotate(180deg);
}

.nav__dropdown-menu {
  position: absolute;
  top: calc(100% + 10px);
  left: 50%;
  transform: translateX(-50%);
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  padding: 0.5rem 0;
  min-width: 220px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s var(--ease-out), visibility 0.3s;
  box-shadow: 0 8px 30px rgba(42, 37, 32, 0.08);
}

.nav__dropdown:hover .nav__dropdown-menu {
  opacity: 1;
  visibility: visible;
}

.nav__dropdown-item {
  display: block;
  padding: 0.5rem 1.2rem;
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  color: var(--text-secondary);
  transition: all 0.2s var(--ease-out);
}

.nav__dropdown-item:hover {
  color: var(--text-primary);
  background: var(--accent-soft);
}

/* Mobile menu */
.nav__burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 4px;
}

.nav__burger span {
  width: 22px;
  height: 1.5px;
  background: var(--text-primary);
  transition: all 0.3s var(--ease-out);
}

.nav__burger.open span:nth-child(1) {
  transform: rotate(45deg) translateY(4.5px);
}

.nav__burger.open span:nth-child(2) {
  opacity: 0;
}

.nav__burger.open span:nth-child(3) {
  transform: rotate(-45deg) translateY(-4.5px);
}

.nav__mobile-menu {
  display: none;
  position: fixed;
  top: var(--nav-height);
  left: 0;
  width: 100%;
  height: calc(100vh - var(--nav-height));
  background: var(--bg-primary);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-md);
  z-index: 999;
}

.nav__mobile-menu.open {
  display: flex;
}

.nav__mobile-menu a {
  font-size: 1.2rem;
  color: var(--text-secondary);
  transition: color 0.3s;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.nav__mobile-menu a:hover {
  color: var(--accent);
}

/* --- Hero Section --- */
.hero {
  min-height: 92vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  padding-top: var(--nav-height);
}

.hero__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero__bg::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 30% 40%, var(--tint-sapphire) 0%, transparent 55%),
    radial-gradient(ellipse at 70% 60%, var(--tint-ruby) 0%, transparent 55%),
    radial-gradient(ellipse at 50% 50%, var(--tint-amber) 0%, transparent 60%);
}

.hero__content {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: var(--space-md);
  max-width: 800px;
  margin: 0 auto;
}

.hero__subtitle {
  font-size: 0.75rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: var(--space-md);
  font-weight: 500;
}

.hero__title {
  margin-bottom: var(--space-md);
  color: var(--text-primary);
}

.hero__title span {
  display: block;
  font-size: 0.35em;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-top: var(--space-sm);
  font-weight: 400;
}

.hero__description {
  font-size: 1rem;
  max-width: 52ch;
  margin: 0 auto var(--space-lg);
  color: var(--text-secondary);
  line-height: 1.7;
}

.hero__cta {
  display: inline-flex;
  gap: var(--space-sm);
  flex-wrap: wrap;
  justify-content: center;
}

.hero__scroll {
  position: absolute;
  bottom: var(--space-md);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-muted);
  font-size: 0.65rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  animation: scrollBounce 2s var(--ease-in-out) infinite;
}

.hero__scroll-line {
  width: 1px;
  height: 32px;
  background: var(--border-medium);
}

@keyframes scrollBounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(6px); }
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0.85rem 1.8rem;
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 500;
  transition: all 0.3s var(--ease-out);
  border-radius: 2px;
}

.btn--primary {
  background: var(--text-primary);
  color: var(--bg-primary);
}

.btn--primary:hover {
  background: var(--accent);
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(168, 138, 92, 0.25);
}

.btn--outline {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border-medium);
}

.btn--outline:hover {
  border-color: var(--text-primary);
  transform: translateY(-1px);
}

.btn--small {
  padding: 0.55rem 1.2rem;
  font-size: 0.72rem;
}

/* --- Sections --- */
.section {
  padding: var(--space-xl) var(--space-md);
  position: relative;
}

.section--alt {
  background: var(--bg-secondary);
}

.section__header {
  text-align: center;
  margin-bottom: var(--space-lg);
}

.section__label {
  font-size: 0.72rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: var(--space-sm);
  font-weight: 500;
}

.section__title {
  margin-bottom: var(--space-sm);
}

.section__description {
  margin: 0 auto;
  text-align: center;
  font-size: 1rem;
  color: var(--text-secondary);
  max-width: 60ch;
}

.container {
  max-width: var(--max-width);
  margin: 0 auto;
}

/* --- Mosaic (homepage featured series) ---
   Varied-size grid with hover zoom + click to open lightbox */
.mosaic {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: 180px;
  gap: 12px;
}

.mosaic__item {
  position: relative;
  overflow: hidden;
  cursor: pointer;
  background: var(--bg-secondary);
  transition: transform 0.5s var(--ease-out);
}

.mosaic__item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.8s var(--ease-out), filter 0.4s var(--ease-out);
}

.mosaic__item:hover img {
  transform: scale(1.05);
  filter: brightness(1.05);
}

.mosaic__item__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 50%, rgba(42, 37, 32, 0.75) 100%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.2rem;
  opacity: 0;
  transition: opacity 0.4s var(--ease-out);
}

.mosaic__item:hover .mosaic__item__overlay {
  opacity: 1;
}

.mosaic__item__title {
  color: #fff;
  font-size: 1.1rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  margin-bottom: 0.2rem;
}

.mosaic__item__subtitle {
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

/* Mosaic tile sizes — organic magazine layout */
.mosaic__item--xl { grid-column: span 2; grid-row: span 2; }
.mosaic__item--l  { grid-column: span 2; grid-row: span 1; }
.mosaic__item--tall { grid-column: span 1; grid-row: span 2; }
.mosaic__item--wide { grid-column: span 2; grid-row: span 1; }

@media (max-width: 900px) {
  .mosaic { grid-template-columns: repeat(2, 1fr); }
  .mosaic__item--xl { grid-column: span 2; grid-row: span 2; }
  .mosaic__item--l { grid-column: span 2; }
  .mosaic__item--tall { grid-column: span 1; grid-row: span 2; }
  .mosaic__item--wide { grid-column: span 2; }
}

@media (max-width: 540px) {
  .mosaic { grid-template-columns: 1fr; grid-auto-rows: 220px; }
  .mosaic__item--xl,
  .mosaic__item--l,
  .mosaic__item--tall,
  .mosaic__item--wide { grid-column: span 1; grid-row: span 1; }
}

/* --- Standard gallery grid (vitraux.html) --- */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}

.gallery-card {
  position: relative;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  cursor: pointer;
  background: var(--bg-secondary);
  transition: transform 0.4s var(--ease-out), box-shadow 0.4s var(--ease-out);
}

.gallery-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 30px rgba(42, 37, 32, 0.12);
}

.gallery-card__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s var(--ease-out);
}

.gallery-card:hover .gallery-card__image {
  transform: scale(1.04);
}

.gallery-card__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 55%, rgba(42, 37, 32, 0.85) 100%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1rem;
  opacity: 0;
  transition: opacity 0.4s var(--ease-out);
}

.gallery-card:hover .gallery-card__overlay {
  opacity: 1;
}

.gallery-card__title {
  color: #fff;
  font-size: 1rem;
  font-weight: 500;
  margin-bottom: 0.2rem;
}

.gallery-card__subtitle {
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

/* --- Feature cards --- */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: var(--space-md);
}

.feature-card {
  padding: var(--space-md);
  border: 1px solid var(--border-subtle);
  background: var(--bg-card);
  transition: all 0.3s var(--ease-out);
  position: relative;
  border-radius: 4px;
}

.feature-card:hover {
  border-color: var(--border-medium);
  transform: translateY(-3px);
  box-shadow: 0 12px 30px rgba(42, 37, 32, 0.06);
}

.feature-card__icon {
  width: 36px;
  height: 36px;
  margin-bottom: var(--space-md);
  color: var(--accent);
  stroke-width: 1.5;
}

.feature-card__title {
  margin-bottom: var(--space-sm);
}

.feature-card__text {
  font-size: 0.92rem;
  line-height: 1.7;
}

/* --- Split layout --- */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-xl);
  align-items: center;
}

.split--reverse { direction: rtl; }
.split--reverse > * { direction: ltr; }

.split__image {
  position: relative;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  border-radius: 2px;
}

.split__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.split__content { padding: var(--space-md) 0; }

.split__label {
  font-size: 0.72rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: var(--space-sm);
  font-weight: 500;
}

.split__title {
  margin-bottom: var(--space-md);
}

.split__text {
  margin-bottom: var(--space-md);
  font-size: 0.98rem;
  line-height: 1.75;
}

.split__text + .split__text {
  margin-top: calc(-1 * var(--space-sm));
}

/* Stats */
.stats {
  display: flex;
  gap: var(--space-lg);
  margin-top: var(--space-lg);
  padding-top: var(--space-md);
  border-top: 1px solid var(--border-subtle);
}

.stat__number {
  font-size: 2rem;
  font-weight: 400;
  color: var(--accent);
  line-height: 1;
  letter-spacing: -0.02em;
}

.stat__label {
  font-size: 0.7rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-top: 0.4rem;
}

/* --- Testimonial --- */
.testimonial {
  text-align: center;
  max-width: 700px;
  margin: 0 auto;
  padding: var(--space-lg) var(--space-md);
}

.testimonial__quote {
  font-size: clamp(1.1rem, 2vw, 1.5rem);
  font-style: italic;
  color: var(--text-primary);
  line-height: 1.6;
  margin-bottom: var(--space-md);
  font-weight: 300;
}

.testimonial__author {
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 500;
}

/* --- Course cards (cours.html) --- */
.courses-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--space-md);
}

.course-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  padding: var(--space-lg) var(--space-md);
  border-radius: 4px;
  transition: all 0.3s var(--ease-out);
  display: flex;
  flex-direction: column;
}

.course-card:hover {
  transform: translateY(-3px);
  border-color: var(--border-medium);
  box-shadow: 0 15px 40px rgba(42, 37, 32, 0.06);
}

.course-card--featured {
  border-color: var(--accent);
  position: relative;
}

.course-card--featured::before {
  content: 'Recommandé';
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--accent);
  color: #fff;
  padding: 0.3rem 1rem;
  font-size: 0.65rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  border-radius: 2px;
  font-weight: 500;
}

.course-card__duration {
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: var(--space-sm);
  font-weight: 500;
}

.course-card__title {
  font-size: 1.5rem;
  font-weight: 400;
  margin-bottom: var(--space-sm);
}

.course-card__price {
  display: flex;
  align-items: baseline;
  gap: 0.3rem;
  margin-bottom: var(--space-md);
  padding-bottom: var(--space-md);
  border-bottom: 1px solid var(--border-subtle);
}

.course-card__price-value {
  font-size: 2.2rem;
  font-weight: 400;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.course-card__price-unit {
  font-size: 0.75rem;
  color: var(--text-muted);
  letter-spacing: 0.05em;
}

.course-card__description {
  font-size: 0.92rem;
  color: var(--text-secondary);
  margin-bottom: var(--space-md);
  flex-grow: 1;
}

.course-card__list {
  margin-bottom: var(--space-md);
}

.course-card__list li {
  padding: 0.4rem 0;
  font-size: 0.88rem;
  color: var(--text-secondary);
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
}

.course-card__list li::before {
  content: '✓';
  color: var(--accent);
  font-weight: 600;
  flex-shrink: 0;
}

.course-card__cta {
  margin-top: auto;
}

/* --- Contact form --- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-xl);
}

.form-group {
  margin-bottom: var(--space-sm);
}

.form-group label {
  display: block;
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.4rem;
  font-weight: 500;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 0.8rem 0.9rem;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  font-family: inherit;
  font-size: 0.92rem;
  transition: border-color 0.3s var(--ease-out), box-shadow 0.3s var(--ease-out);
  outline: none;
  border-radius: 3px;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.form-group textarea {
  resize: vertical;
  min-height: 130px;
}

.contact-info__item {
  display: flex;
  align-items: flex-start;
  gap: var(--space-sm);
  margin-bottom: var(--space-md);
}

.contact-info__icon {
  width: 18px;
  height: 18px;
  color: var(--accent);
  flex-shrink: 0;
  margin-top: 3px;
  stroke-width: 1.5;
}

.contact-info__label {
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.3rem;
  font-weight: 500;
}

.contact-info__value {
  color: var(--text-primary);
  font-size: 0.95rem;
  line-height: 1.5;
}

/* --- Page header (inner pages) --- */
.page-header {
  min-height: 40vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: calc(var(--nav-height) + var(--space-lg)) var(--space-md) var(--space-lg);
  position: relative;
  overflow: hidden;
}

.page-header__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.page-header__bg::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 30% 40%, var(--tint-sapphire) 0%, transparent 55%),
    radial-gradient(ellipse at 70% 60%, var(--tint-ruby) 0%, transparent 55%);
}

.page-header__content {
  position: relative;
  z-index: 1;
}

.page-header__label {
  font-size: 0.72rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: var(--space-sm);
  font-weight: 500;
}

.page-header__title {
  margin-bottom: var(--space-sm);
}

.page-header__description {
  font-size: 1rem;
  max-width: 55ch;
  margin: 0 auto;
  color: var(--text-secondary);
}

/* --- Footer --- */
.footer {
  padding: var(--space-lg) var(--space-md) var(--space-md);
  border-top: 1px solid var(--border-subtle);
  background: var(--bg-secondary);
  position: relative;
}

.footer__inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: var(--space-lg);
}

.footer__brand { margin-bottom: var(--space-sm); }

.footer__brand-name {
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-primary);
  margin-bottom: 0.3rem;
}

.footer__brand-title {
  font-size: 0.65rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: var(--space-sm);
  font-weight: 500;
}

.footer__brand p {
  font-size: 0.85rem;
  max-width: 35ch;
}

.footer__heading {
  font-size: 0.78rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-primary);
  margin-bottom: var(--space-sm);
  font-weight: 600;
}

.footer__link {
  display: block;
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 0.5rem;
  transition: color 0.3s;
}

.footer__link:hover {
  color: var(--accent);
}

.footer__bottom {
  max-width: var(--max-width);
  margin: var(--space-md) auto 0;
  padding-top: var(--space-md);
  border-top: 1px solid var(--border-subtle);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.footer__social {
  display: flex;
  gap: 0.6rem;
}

.footer__social a {
  width: 34px;
  height: 34px;
  border: 1px solid var(--border-medium);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  transition: all 0.3s var(--ease-out);
}

.footer__social a:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.footer__social svg {
  width: 14px;
  height: 14px;
}

/* --- Animations --- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal--delay-1 { transition-delay: 0.08s; }
.reveal--delay-2 { transition-delay: 0.16s; }
.reveal--delay-3 { transition-delay: 0.24s; }
.reveal--delay-4 { transition-delay: 0.32s; }

/* --- Lightbox --- */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(42, 37, 32, 0.95);
  z-index: 2000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: var(--space-md);
}

.lightbox.active {
  display: flex;
}

.lightbox__close {
  position: absolute;
  top: var(--space-md);
  right: var(--space-md);
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1.5rem;
  cursor: pointer;
  z-index: 1;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  backdrop-filter: blur(10px);
  transition: background 0.3s;
}

.lightbox__close:hover {
  background: rgba(255, 255, 255, 0.2);
}

.lightbox__img {
  max-width: 92vw;
  max-height: 88vh;
  object-fit: contain;
  border-radius: 2px;
  animation: lightboxFade 0.4s var(--ease-out);
}

@keyframes lightboxFade {
  from { opacity: 0; transform: scale(0.96); }
  to { opacity: 1; transform: scale(1); }
}

/* --- Responsive --- */
@media (max-width: 960px) {
  .nav__links { display: none; }
  .nav__burger { display: flex; }

  .split {
    grid-template-columns: 1fr;
    gap: var(--space-lg);
  }
  .split--reverse { direction: ltr; }

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

  .footer__inner {
    grid-template-columns: 1fr 1fr;
    gap: var(--space-md);
  }

  .stats { gap: var(--space-md); }
}

@media (max-width: 640px) {
  :root {
    --space-xl: 4rem;
    --space-2xl: 5rem;
  }

  .gallery-grid { grid-template-columns: 1fr 1fr; }
  .features-grid { grid-template-columns: 1fr; }
  .footer__inner { grid-template-columns: 1fr; }

  .footer__bottom {
    flex-direction: column;
    gap: var(--space-sm);
    text-align: center;
  }

  .stats {
    flex-direction: column;
    gap: var(--space-md);
  }

  .hero__cta {
    flex-direction: column;
    align-items: center;
  }
}

/* --- JS glow cursor --- */
.js-glass-glow {
  will-change: transform, opacity;
}

/* ============================================
   HOME — image pleine hauteur + panneau droit
   ============================================ */

.body--home {
  overflow: hidden;
  height: 100vh;
}

.home {
  position: fixed;
  top: var(--nav-height);
  left: 0;
  right: 0;
  bottom: 0;
  display: grid;
  grid-template-columns: 1fr 440px;
}

/* Grande image — remplit tout le côté gauche */
.home__image {
  display: block;
  overflow: hidden;
  cursor: pointer;
  position: relative;
}

.home__image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  display: block;
  transition: transform 1.5s var(--ease-out);
  background: var(--bg-secondary);
}

.home__image:hover img {
  transform: scale(1.02);
}

/* Flèches — fixes aux bords du conteneur image */
.home__arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.88);
  border: none;
  border-radius: 50%;
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.3s, background 0.3s;
  z-index: 2;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.home__image:hover .home__arrow {
  opacity: 1;
}

.home__arrow:hover {
  background: #fff;
}

.home__arrow svg {
  width: 18px;
  height: 18px;
  color: var(--text-primary);
}

.home__arrow--prev { left: 12px; }
.home__arrow--next { right: 12px; }

/* Transition fondu sur l'image */
.home__image img {
  transition: transform 1.5s var(--ease-out), opacity 0.4s ease;
}

.home__image img.fading {
  opacity: 0.3;
}

/* Panneau droit */
.home__side {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: var(--space-lg) var(--space-md) var(--space-md);
  border-left: 1px solid var(--border-subtle);
}

/* Texte — centré verticalement dans l'espace restant */
.home__text {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.home__label {
  font-size: 0.68rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.8rem;
  font-weight: 500;
}

.home__title {
  font-size: 2rem;
  font-weight: 400;
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin-bottom: var(--space-sm);
}

.home__desc {
  font-size: 0.88rem;
  line-height: 1.7;
  color: var(--text-secondary);
  margin-bottom: var(--space-md);
}

.home__actions {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

/* Vignettes — grille 3×2 calée en bas */
.home__thumbs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  flex-shrink: 0;
}

.home__thumb {
  display: block;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: 2px;
  cursor: pointer;
}

.home__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s var(--ease-out);
}

.home__thumb:hover img {
  transform: scale(1.1);
}

/* === Responsive === */
@media (max-width: 900px) {
  .body--home {
    overflow: auto;
    height: auto;
  }

  .home {
    position: relative;
    top: auto;
    grid-template-columns: 1fr;
    grid-template-rows: 60vh auto;
    padding-top: var(--nav-height);
  }

  .home__side {
    padding: var(--space-md) var(--space-sm);
    gap: var(--space-md);
    border-left: none;
    border-top: 1px solid var(--border-subtle);
  }

  .home__text { flex: none; }
}

@media (max-width: 540px) {
  .home {
    grid-template-rows: 50vh auto;
  }
}
