/* 2B Groups — Design system */
:root {
  --bg: #F8F5EF;
  --text: #111111;
  --text-secondary: #555555;
  --gold: #B08A45;
  --gold-hover: #9A7839;
  --line: #E6DED2;
  --footer-bg: #080808;
  --footer-text: #FFFFFF;
  --footer-muted: #BEBEBE;
  --white: #FFFFFF;
  --card-bg: #FDFCF9;
  --font-serif: "Playfair Display", "Cormorant Garamond", "Libre Baskerville", Georgia, serif;
  --font-sans: "Inter", "Helvetica Neue", Arial, sans-serif;
  --header-height: 80px;
  --container: 1280px;
  --transition: 0.25s ease;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
}

body {
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
ul { list-style: none; }

.container {
  width: min(100% - 48px, var(--container));
  margin-inline: auto;
}

/* ─── Typography ─── */
.label {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold);
}

.title-serif {
  font-family: var(--font-serif);
  font-weight: 400;
  line-height: 1.15;
  color: var(--text);
  letter-spacing: -0.01em;
}

.title-serif--xl { font-size: clamp(2.4rem, 4.5vw, 3.75rem); }
.title-serif--lg { font-size: clamp(1.75rem, 3vw, 2.5rem); }
.title-serif--md { font-size: clamp(1.35rem, 2vw, 1.75rem); }

.text-body { color: var(--text-secondary); font-size: 15px; line-height: 1.7; }
.text-body--sm { font-size: 13px; }

.gold-line {
  width: 48px;
  height: 1px;
  background: var(--gold);
  margin: 24px 0;
}

.gold-line--wide { width: 100%; max-width: 120px; }

/* ─── Button ─── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 28px;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  transition: background var(--transition), transform var(--transition);
}

.btn--gold {
  background: var(--gold);
  color: var(--white);
}

.btn--gold:hover {
  background: var(--gold-hover);
  transform: translateY(-1px);
}

.btn__arrow {
  font-size: 14px;
  line-height: 1;
}

/* ─── Section Title ─── */
.section-title {
  margin-bottom: 56px;
}

.section-title .label { margin-bottom: 20px; display: block; }
.section-title .title-serif { max-width: 720px; }

/* ─── Header ─── */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
  height: var(--header-height);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  gap: 32px;
}

/* Logo 2B Groups — header (fond clair) */
.site-logo {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
  text-decoration: none;
}

.site-logo__2b {
  font-family: var(--font-serif);
  font-size: 2.15rem;
  font-weight: 400;
  line-height: 1;
  color: var(--text);
  letter-spacing: -0.02em;
}

.site-logo__line {
  width: 1px;
  height: 30px;
  background: var(--text);
  opacity: 0.35;
  flex-shrink: 0;
}

.site-logo__groups {
  font-family: var(--font-sans);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.34em;
  color: transparent;
  -webkit-text-stroke: 1px var(--text);
  text-stroke: 1px var(--text);
  paint-order: stroke fill;
  text-transform: uppercase;
  padding-top: 2px;
}

.header__nav {
  display: flex;
  align-items: center;
  gap: 32px;
}

.header__links {
  display: flex;
  align-items: center;
  gap: 28px;
}

.header__link {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text);
  position: relative;
  padding-bottom: 4px;
  transition: color var(--transition);
  white-space: nowrap;
}

.header__link:hover { color: var(--gold); }

.header__link--active::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: var(--gold);
}

.header__cta { flex-shrink: 0; }

.header__burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
}

.header__burger span {
  display: block;
  width: 22px;
  height: 1.5px;
  background: var(--text);
  transition: var(--transition);
}

/* ─── Hero ─── */
.hero {
  padding: 72px 0 96px;
}

.hero__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}

.hero__content { max-width: 520px; }

.hero__content .label { margin-bottom: 28px; }
.hero__content .title-serif { margin-bottom: 0; }
.hero__content .text-body { margin-top: 28px; max-width: 440px; }
.hero__content .btn { margin-top: 40px; }

.hero__image {
  position: relative;
  aspect-ratio: 4 / 3.2;
  overflow: hidden;
}

.hero__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.85) contrast(0.95);
}

/* ─── Companies ─── */
.companies {
  padding: 80px 0 120px;
  border-top: 1px solid var(--line);
}

.companies__grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 18px;
  background: transparent;
  border: none;
}

.company-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 24px 14px 44px;
  position: relative;
  min-height: 320px;
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: 16px;
  overflow: hidden;
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.35s ease, border-color var(--transition);
}

.company-card:hover {
  transform: scale(1.035);
  z-index: 2;
}

.company-card__logo-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  flex: 1;
  min-height: 168px;
  margin-bottom: 16px;
  position: relative;
  z-index: 1;
}

.company-card__logo {
  width: 92%;
  height: auto;
  max-height: 148px;
  object-fit: contain;
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}

.company-card:hover .company-card__logo {
  transform: scale(1.03);
}

.company-card__category {
  display: block;
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin-bottom: 10px;
  opacity: 0.75;
  position: relative;
  z-index: 1;
}

.company-card__desc {
  font-size: 13px;
  font-weight: 400;
  color: var(--text-secondary);
  line-height: 1.65;
  letter-spacing: 0.01em;
  max-width: 168px;
  flex: 1;
  position: relative;
  z-index: 1;
}

.company-card__arrow {
  position: absolute;
  bottom: 18px;
  right: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  font-size: 12px;
  color: var(--gold);
  background: rgba(255, 255, 255, 0.08);
  opacity: 0.85;
  transition: opacity var(--transition), transform var(--transition), background var(--transition);
  z-index: 1;
}

.company-card:hover .company-card__arrow {
  opacity: 1;
  transform: translate(1px, -1px);
}

/* ─── Cartes entreprises — fond uni = fond du logo ─── */

/* Golden Arena — fond noir du logo */
.company-card--golden-arena {
  background: #000000;
  border-color: rgba(212, 175, 55, 0.12);
}
.company-card--golden-arena .company-card__category { color: rgba(212, 175, 55, 0.9); }
.company-card--golden-arena .company-card__desc { color: rgba(245, 235, 210, 0.82); font-weight: 300; }
.company-card--golden-arena .company-card__arrow { color: #D4AF37; background: rgba(212, 175, 55, 0.12); }
.company-card--golden-arena .company-card__logo { max-height: 156px; }
.company-card--golden-arena:hover {
  border-color: rgba(212, 175, 55, 0.45);
  box-shadow: 0 12px 40px rgba(212, 175, 55, 0.2);
}

/* Pooly — fond blanc du logo */
.company-card--pooly {
  background: #ffffff;
  border-color: rgba(107, 70, 254, 0.1);
}
.company-card--pooly .company-card__category { color: #6B46FE; opacity: 0.85; }
.company-card--pooly .company-card__desc { color: #4a4560; font-weight: 400; }
.company-card--pooly .company-card__arrow { color: #6B46FE; background: rgba(107, 70, 254, 0.08); }
.company-card--pooly .company-card__logo { max-height: 164px; }
.company-card--pooly:hover {
  border-color: rgba(107, 70, 254, 0.35);
  box-shadow: 0 12px 36px rgba(107, 70, 254, 0.15);
}

/* Creatis — fond noir du logo */
.company-card--creatis {
  background: #000000;
  border-color: rgba(56, 189, 248, 0.1);
}
.company-card--creatis .company-card__category { color: #38BDF8; }
.company-card--creatis .company-card__desc { color: rgba(226, 232, 240, 0.88); font-weight: 300; }
.company-card--creatis .company-card__arrow { color: #F97316; background: rgba(255, 255, 255, 0.06); }
.company-card--creatis .company-card__logo { max-height: 132px; }
.company-card--creatis:hover {
  border-color: rgba(56, 189, 248, 0.4);
  box-shadow: 0 12px 36px rgba(56, 189, 248, 0.12);
}

/* Abondant Pizza — fond rouge du logo */
.company-card--abondant-pizza {
  background: #d21217;
  border-color: rgba(255, 255, 255, 0.15);
}
.company-card--abondant-pizza .company-card__category { color: rgba(255, 255, 255, 0.75); }
.company-card--abondant-pizza .company-card__desc { color: rgba(255, 255, 255, 0.92); font-weight: 300; }
.company-card--abondant-pizza .company-card__arrow { color: #fff; background: rgba(255, 255, 255, 0.12); }
.company-card--abondant-pizza .company-card__logo { max-height: 160px; }
.company-card--abondant-pizza:hover {
  border-color: rgba(255, 255, 255, 0.45);
  box-shadow: 0 12px 40px rgba(210, 18, 23, 0.32);
}

/* ASCEND — fond noir du logo */
.company-card--ascend {
  background: #000000;
  border-color: rgba(184, 115, 51, 0.15);
}
.company-card--ascend .company-card__category { color: #B87333; }
.company-card--ascend .company-card__desc { color: rgba(220, 210, 200, 0.85); font-weight: 300; }
.company-card--ascend .company-card__arrow { color: #B87333; background: rgba(184, 115, 51, 0.12); }
.company-card--ascend .company-card__logo { max-height: 128px; }
.company-card--ascend:hover {
  border-color: rgba(184, 115, 51, 0.5);
  box-shadow: 0 12px 40px rgba(184, 115, 51, 0.18);
}

/* Grid variant for entreprises page */
.companies__grid--page {
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

/* ─── Page hero (inner pages) ─── */
.page-hero {
  padding: 80px 0 64px;
  border-bottom: 1px solid var(--line);
}

.page-hero .label { margin-bottom: 20px; display: block; }
.page-hero .title-serif { max-width: 800px; }
.page-hero .text-body { margin-top: 24px; max-width: 640px; }

/* ─── Content sections ─── */
.content-section {
  padding: 80px 0;
}

.content-section + .content-section {
  border-top: 1px solid var(--line);
}

.content-section__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: start;
}

.content-section__grid .title-serif { margin-bottom: 20px; }

/* ─── Articles ─── */
.articles-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}

.article-card {
  background: var(--card-bg);
  padding: 40px 32px;
  transition: background var(--transition);
}

.article-card:hover { background: var(--white); }

.article-card__date {
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 16px;
}

.article-card__title {
  font-family: var(--font-serif);
  font-size: 1.35rem;
  font-weight: 400;
  line-height: 1.3;
  margin-bottom: 16px;
}

.article-card__excerpt {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.65;
}

/* ─── Contact ─── */
.contact-section {
  padding: 80px 0 120px;
}

.contact-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 80px;
  align-items: start;
}

.form-group { margin-bottom: 24px; }

.form-group label {
  display: block;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-secondary);
  margin-bottom: 10px;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 14px 16px;
  font-family: var(--font-sans);
  font-size: 14px;
  color: var(--text);
  background: var(--white);
  border: 1px solid var(--line);
  transition: border-color var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--gold);
}

.form-group textarea { min-height: 160px; resize: vertical; }

.contact-info { padding-top: 8px; }

.contact-info__block { margin-bottom: 36px; }

.contact-info__label {
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 12px;
}

.contact-info__value {
  font-size: 15px;
  color: var(--text);
  line-height: 1.6;
}

.contact-info__value a:hover { color: var(--gold); }

.form-success {
  display: none;
  padding: 20px 24px;
  background: var(--white);
  border: 1px solid var(--gold);
  font-size: 14px;
  color: var(--text);
  margin-top: 24px;
}

.form-success.visible { display: block; }

/* ─── Footer ─── */
.footer {
  background: var(--footer-bg);
  color: var(--footer-text);
  padding: 72px 0 40px;
}

.footer__top {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 48px;
  padding-bottom: 56px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.footer__logo img {
  height: 32px;
  width: auto;
  margin-bottom: 20px;
}

.footer__tagline {
  font-size: 13px;
  color: var(--footer-muted);
  max-width: 260px;
  line-height: 1.6;
}

.footer__col-title {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--footer-muted);
  margin-bottom: 20px;
}

.footer__links li { margin-bottom: 10px; }

.footer__links a {
  font-size: 13px;
  color: var(--footer-text);
  transition: color var(--transition);
}

.footer__links a:hover { color: var(--gold); }

.footer__bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 32px;
  font-size: 12px;
  color: var(--footer-muted);
}

/* ─── Animations ─── */
.fade-in {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ─── Homepage — maquette : hero en haut, cartes en bas (1er écran) ─── */
body[data-page="home"] .home-main {
  min-height: calc(100svh - var(--header-height));
  display: flex;
  flex-direction: column;
}

body[data-page="home"] .hero--home {
  flex: 1 1 auto;
  padding: 36px 0 0;
}

body[data-page="home"] .hero--home .hero__grid {
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: start;
}

body[data-page="home"] .hero--home .hero__content {
  max-width: 540px;
  padding-top: 8px;
}

body[data-page="home"] .hero--home .hero__content .label {
  margin-bottom: 22px;
}

body[data-page="home"] .hero--home .hero__content .title-serif--xl {
  font-size: clamp(2rem, 3.6vw, 3.25rem);
  line-height: 1.14;
}

body[data-page="home"] .hero__text--home,
body[data-page="home"] .hero__cta--home {
  display: none;
}

body[data-page="home"] .hero__image--home {
  aspect-ratio: 4 / 3.2;
  max-height: min(36vh, 300px);
  width: 100%;
}

body[data-page="home"] .hero__image--home img {
  object-position: center 40%;
}

body[data-page="home"] .companies--home {
  flex-shrink: 0;
  padding: 0 0 24px;
  border-top: none;
}

body[data-page="home"] .companies--home__label {
  text-align: center;
  margin-bottom: 18px;
}

body[data-page="home"] .companies__grid--home {
  grid-template-columns: repeat(5, 1fr);
  gap: 18px;
}

.section-title--home {
  text-align: center;
  margin-bottom: 48px;
}

.section-title--home .label {
  margin-bottom: 20px;
}

.section-title--home .title-serif--lg {
  margin-inline: auto;
  max-width: 820px;
}

.section-title--home .gold-line--wide {
  margin-inline: auto;
  margin-top: 28px;
}

.companies__grid--home {
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
}

.companies__grid--page .company-card__logo {
  max-height: 172px;
}

.companies__grid--page .company-card__logo-wrap {
  min-height: 188px;
}

/* ─── Responsive ─── */
@media (max-width: 999px) {
  .companies__grid { grid-template-columns: repeat(3, 1fr); gap: 16px; }
  .companies__grid--home { grid-template-columns: repeat(3, 1fr); gap: 14px; }

  body[data-page="home"] .home-main {
    min-height: 0;
  }

  body[data-page="home"] .hero--home {
    flex: none;
    padding: 32px 0 24px;
  }

  body[data-page="home"] .hero__text--home,
  body[data-page="home"] .hero__cta--home {
    display: block;
  }

  body[data-page="home"] .hero__text--home {
    margin-top: 16px;
    font-size: 14px;
    max-width: 420px;
  }

  body[data-page="home"] .hero__cta--home {
    margin-top: 20px;
  }

  body[data-page="home"] .hero__image--home {
    max-height: 280px;
  }

  body[data-page="home"] .companies__grid--home {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 900px) {
  .header__nav {
    position: fixed;
    inset: var(--header-height) 0 auto 0;
    background: var(--bg);
    border-bottom: 1px solid var(--line);
    flex-direction: column;
    align-items: stretch;
    padding: 24px;
    gap: 20px;
    transform: translateY(-120%);
    opacity: 0;
    pointer-events: none;
    transition: var(--transition);
  }

  .header__nav.open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .header__links {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }

  .header__burger { display: flex; }
  .header__cta { width: 100%; }
  .header__cta .btn { width: 100%; justify-content: center; }

  .hero__grid,
  .content-section__grid,
  .contact-grid { grid-template-columns: 1fr; gap: 40px; }

  .hero__image { order: -1; aspect-ratio: 16/10; }

  .companies__grid,
  .companies__grid--page { grid-template-columns: repeat(2, 1fr); gap: 14px; }

  .articles-grid { grid-template-columns: 1fr; }

  .footer__top { grid-template-columns: 1fr 1fr; gap: 32px; }
}

@media (max-width: 560px) {
  .companies__grid,
  .companies__grid--page { grid-template-columns: 1fr; gap: 12px; }

  .footer__top { grid-template-columns: 1fr; }

  .footer__bottom { flex-direction: column; gap: 12px; text-align: center; }
}
