/* Jetons : toute couleur, taille et durée du site est ici. */
:root {
  --fond: #f6f4ef;
  --surface: #ffffff;
  --encre: #161616;
  --encre-douce: #55524c;
  --trait: #dcd8cf;
  --accent: #8a5a2b;
  --accent-texte: #ffffff;

  --serif: "Iowan Old Style", "Charter", "Palatino Linotype", Palatino, Georgia, serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", "Helvetica Neue", Arial, sans-serif;

  --t-petit: 0.875rem;
  --t-corps: 1.0625rem;
  --t-chapeau: clamp(1.25rem, 1.1rem + 0.6vw, 1.5rem);
  --t-h2: clamp(2rem, 1.5rem + 2.2vw, 3.25rem);
  --t-h1: clamp(2.75rem, 1.8rem + 4.5vw, 5.5rem);

  --largeur: 72rem;
  --gouttiere: clamp(1rem, 0.5rem + 2.5vw, 2.5rem);
  --espace-section: clamp(4rem, 3rem + 5vw, 8rem);
  --rayon: 0.5rem;
  --duree: 180ms;
}

@media (prefers-color-scheme: dark) {
  :root {
    --fond: #121212;
    --surface: #1b1b1b;
    --encre: #ece9e3;
    --encre-douce: #a8a39a;
    --trait: #2f2d2a;
    --accent: #d9a46c;
    --accent-texte: #161616;
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 5rem;
  -webkit-text-size-adjust: 100%;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}

body {
  margin: 0;
  background: var(--fond);
  color: var(--encre);
  font: 400 var(--t-corps) / 1.65 var(--sans);
  text-rendering: optimizeLegibility;
}

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

a {
  color: inherit;
  text-decoration-color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
  transition: color var(--duree);
}

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

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

h1,
h2 {
  font-family: var(--serif);
  font-weight: 400;
  letter-spacing: -0.01em;
  line-height: 1.05;
  margin: 0;
}

.cadre {
  width: min(100% - 2 * var(--gouttiere), var(--largeur));
  margin-inline: auto;
}

.evitement {
  position: absolute;
  left: -100vw;
}

.evitement:focus {
  left: var(--gouttiere);
  top: 0.5rem;
  z-index: 10;
  background: var(--surface);
  padding: 0.5rem 1rem;
}

/* En-tête */
.entete {
  position: sticky;
  top: 0;
  z-index: 5;
  background: color-mix(in srgb, var(--fond) 88%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--trait);
}

.entete__barre {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 4rem;
}

.marque {
  font-family: var(--serif);
  font-size: 1.125rem;
  text-decoration: none;
}

.menu {
  display: flex;
  gap: clamp(1rem, 3vw, 2rem);
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: var(--t-petit);
}

.menu a {
  text-decoration: none;
}

@media (max-width: 30rem) {
  .menu li:first-child {
    display: none;
  }
}

/* Héros */
.heros {
  display: grid;
  gap: clamp(2rem, 5vw, 5rem);
  align-items: center;
  padding-block: clamp(3rem, 6vw, 6rem) var(--espace-section);
}

@media (min-width: 56rem) {
  .heros {
    grid-template-columns: 1fr 26rem;
  }
}

.surtitre,
.projet__num,
.projet__role,
.index__num,
.index__quoi,
.parcours dt {
  font-size: var(--t-petit);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--encre-douce);
}

.surtitre {
  margin: 0 0 1rem;
}

.heros h1 {
  font-size: var(--t-h1);
  margin-bottom: 1.5rem;
}

.chapeau {
  font-family: var(--serif);
  font-size: var(--t-chapeau);
  line-height: 1.4;
  margin: 0 0 1.25rem;
  max-width: 34ch;
}

.heros__texte > p:not(.surtitre):not(.chapeau) {
  color: var(--encre-douce);
  max-width: 58ch;
}

.heros__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 2rem;
}

.heros__photo {
  margin: 0;
  justify-self: center;
  width: min(100%, 26rem);
}

.heros__photo img {
  border-radius: var(--rayon);
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: 50% 20%;
}

.bouton {
  display: inline-block;
  padding: 0.8rem 1.4rem;
  border-radius: 999px;
  background: var(--encre);
  color: var(--fond);
  font-size: var(--t-petit);
  font-weight: 600;
  text-decoration: none;
  overflow-wrap: anywhere;
  transition: background var(--duree), color var(--duree);
}

.bouton:hover {
  background: var(--accent);
  color: var(--accent-texte);
}

.bouton--discret {
  background: transparent;
  color: var(--encre);
  box-shadow: inset 0 0 0 1px var(--trait);
}

/* Sections */
.titre-section {
  font-size: var(--t-h2);
  margin-bottom: clamp(1.5rem, 3vw, 2.5rem);
}

.index {
  padding-bottom: var(--espace-section);
}

.index__liste {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--encre);
}

.index__liste a {
  display: grid;
  grid-template-columns: 3rem 1fr;
  gap: 0.25rem 1rem;
  align-items: baseline;
  padding: 1.25rem 0;
  border-bottom: 1px solid var(--trait);
  text-decoration: none;
}

.index__nom {
  font-family: var(--serif);
  font-size: clamp(1.5rem, 1.2rem + 1.5vw, 2.25rem);
  line-height: 1.2;
}

.index__quoi {
  grid-column: 2;
}

@media (min-width: 48rem) {
  .index__liste a {
    grid-template-columns: 4rem 1fr auto;
  }

  .index__quoi {
    grid-column: auto;
  }
}

.index__liste a:hover .index__nom {
  color: var(--accent);
}

/* Fiches des entreprises */
.projet {
  display: grid;
  gap: 1.5rem clamp(2rem, 5vw, 5rem);
  padding-block: clamp(2.5rem, 5vw, 4rem);
  border-top: 1px solid var(--trait);
}

@media (min-width: 56rem) {
  .projet {
    grid-template-columns: 18rem 1fr;
  }

  .projet__tete {
    position: sticky;
    top: 6rem;
    align-self: start;
  }
}

.projet__tete p {
  margin: 0;
}

.projet__tete h2 {
  font-size: var(--t-h2);
  margin: 0.5rem 0 0.75rem;
}

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

.projet__corps {
  max-width: 44rem;
}

.projet__accroche {
  font-family: var(--serif);
  font-size: var(--t-chapeau);
  line-height: 1.4;
  margin-top: 0;
}

.projet__corps > p:not(.projet__accroche):not(.projet__liens) {
  color: var(--encre-douce);
}

.projet__faits {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr));
  gap: 1px;
  margin: 2rem 0;
  padding: 0;
  list-style: none;
  background: var(--trait);
  border: 1px solid var(--trait);
  border-radius: var(--rayon);
  overflow: hidden;
}

.projet__faits li {
  background: var(--surface);
  padding: 1rem 1.25rem;
  font-size: var(--t-petit);
  color: var(--encre-douce);
}

.projet__faits strong {
  display: block;
  font-family: var(--serif);
  font-size: 1.5rem;
  font-weight: 400;
  color: var(--encre);
  line-height: 1.2;
  margin-bottom: 0.25rem;
}

.projet__liens {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  margin: 0;
  font-size: var(--t-petit);
}

.projet__liens a::after {
  content: " \2197";
  color: var(--accent);
}

.lien-site {
  font-family: var(--serif);
  font-size: 1.25rem;
  line-height: 1.3;
}

/* Parcours */
.parcours {
  padding-block: var(--espace-section);
  border-top: 1px solid var(--encre);
}

.parcours__liste {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: 2rem;
  margin: 0;
}

.parcours dd {
  margin: 0.5rem 0 0;
  color: var(--encre-douce);
}

/* Pied */
.pied {
  border-top: 1px solid var(--trait);
  padding-block: 2.5rem;
  font-size: var(--t-petit);
  color: var(--encre-douce);
}

.pied__grille {
  display: grid;
  gap: 1.25rem;
}

@media (min-width: 48rem) {
  .pied__grille {
    grid-template-columns: auto 1fr;
    align-items: center;
  }

  .pied__mentions {
    grid-column: 1 / -1;
  }
}

.pied__nom {
  font-family: var(--serif);
  font-size: 1.125rem;
  color: var(--encre);
  margin: 0;
}

.pied__liens {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

@media (min-width: 48rem) {
  .pied__liens {
    justify-content: flex-end;
  }
}

.pied__mentions summary {
  cursor: pointer;
}

.pied__mentions p {
  max-width: 60ch;
}
