/* Couleurs du site : changer les codes ici suffit à les changer partout. */
:root {
  --paper: #f6f3ee;
  --ink: #1d1d1b;
  --muted: #7a756d;
  --green: #1f4a36;
  --pink: #f6b3cf;
  --highlight: var(--pink); /* couleur du surligneur */
  --gutter: clamp(16px, 3vw, 40px);
  --gap: clamp(12px, 1.6vw, 22px);
  --serif: "Instrument Serif", "Times New Roman", serif;
  --sans: "DM Sans", system-ui, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
::selection { background: var(--pink); color: var(--ink); }
a { color: inherit; text-decoration: none; }
img { display: block; width: 100%; height: auto; }
.label { font-size: clamp(12px, 0.9vw, 14px); letter-spacing: 0.12em; text-transform: uppercase; }

/* Logo (le SVG sert de masque : il prend la couleur du texte) */
.logo, .biglogo {
  display: block; aspect-ratio: 941 / 109; background: currentColor;
  -webkit-mask: url(images/logo.svg) no-repeat left center / contain;
  mask: url(images/logo.svg) no-repeat left center / contain;
}

/* En-tête */
.header {
  position: sticky; top: 0; z-index: 10;
  display: flex; justify-content: space-between; align-items: center;
  padding: clamp(18px, 1.7vw, 28px) var(--gutter);
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  backdrop-filter: blur(8px);
}
.logo { height: clamp(18px, 1.9vw, 30px); }
.nav { display: flex; gap: clamp(16px, 3vw, 44px); font-size: clamp(12px, 0.95vw, 14px); letter-spacing: 0.12em; text-transform: uppercase; }
.nav a { padding: 2px 0; background: linear-gradient(var(--highlight), var(--highlight)) no-repeat 0 100% / 0 45%; transition: background-size .25s; }
.nav a:hover, .nav a.current { background-size: 100% 45%; }

/* Accroche */
.intro { padding: clamp(44px, 6vw, 96px) var(--gutter) clamp(32px, 4.5vw, 64px); }
.intro h1 {
  margin: 0; max-width: 19ch;
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(40px, 6vw, 96px); line-height: 0.98; letter-spacing: -0.015em;
}
.intro h1 em { font-style: italic; }
.intro h1 mark { color: inherit; font-style: italic; background: linear-gradient(var(--highlight), var(--highlight)) no-repeat 0 78% / 100% 34%; }

/* Grille de projets : 3 colonnes, puis 2 sur tablette et 1 sur mobile */
.section-head {
  display: flex; justify-content: space-between; align-items: baseline;
  margin: 0 var(--gutter); padding: 12px 0; border-top: 1px solid var(--ink);
}
.grid {
  display: grid; grid-template-columns: repeat(6, 1fr);
  gap: clamp(28px, 3.5vw, 48px) var(--gap);
  padding: 12px var(--gutter) clamp(64px, 9vw, 128px);
}
.card { display: block; grid-column: span 2; }
.card .thumb { position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: #e9e5dd; }
.card .thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .7s cubic-bezier(.2,.7,.2,1); }
a.card:hover .thumb img { transform: scale(1.035); }
.card .meta { display: flex; justify-content: space-between; gap: 12px; align-items: baseline; margin-top: 10px; }
.card h3 { margin: 0; font-size: clamp(12px, 0.9vw, 14px); font-weight: 500; letter-spacing: 0.1em; text-transform: uppercase; }
.card h3 b { font-weight: inherit; background: linear-gradient(var(--highlight), var(--highlight)) no-repeat 0 100% / 0 45%; transition: background-size .25s; }
a.card:hover h3 b { background-size: 100% 45%; }
.card span { font-family: var(--serif); font-style: italic; font-size: clamp(16px, 1.25vw, 19px); color: var(--muted); text-align: right; }

/* Page About */
.about-head { padding: clamp(36px, 5vw, 76px) var(--gutter) clamp(28px, 4vw, 52px); }
.about-head h1 {
  margin: 0; max-width: 26ch;
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(30px, 4vw, 60px); line-height: 1.04; letter-spacing: -0.01em;
}
.about-head h1 mark { color: inherit; font-style: italic; background: linear-gradient(var(--highlight), var(--highlight)) no-repeat 0 78% / 100% 34%; }
.about-body {
  display: grid; grid-template-columns: repeat(12, 1fr); gap: var(--gap); align-items: start;
  margin: 0 var(--gutter); padding: var(--gap) 0 clamp(48px, 7vw, 96px); border-top: 1px solid var(--ink);
}
.about-body .portrait { grid-column: 1 / span 4; }
.about-body .portrait img { aspect-ratio: 4 / 5; object-fit: cover; }
.about-body .text { grid-column: 6 / span 7; columns: 2; column-gap: clamp(20px, 3vw, 44px); font-size: clamp(15px, 1.25vw, 18px); }
.about-body .text p { margin: 0 0 14px; break-inside: avoid; }

.facts {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--gap);
  margin: 0 var(--gutter); padding: 12px 0 clamp(64px, 9vw, 128px); border-top: 1px solid var(--ink);
}
.facts h2 { margin: 0 0 14px; font-size: 12px; font-weight: 400; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
.facts ul { list-style: none; margin: 0; padding: 0; font-family: var(--serif); font-size: clamp(22px, 2.2vw, 30px); line-height: 1.25; }

/* Pied de page / contact */
.contact { background: var(--green); color: var(--pink); padding: clamp(32px, 4.5vw, 60px) var(--gutter) 18px; }
.contact p { margin: 0 0 10px; font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase; }
.contact .mail {
  display: inline-block; overflow-wrap: anywhere;
  font-family: var(--serif); font-size: clamp(26px, 3.6vw, 48px); line-height: 1.05; letter-spacing: -0.01em;
  transition: color .2s;
}
.contact .mail:hover { color: var(--paper); }

.contact .foot {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px;
  margin-top: clamp(28px, 4vw, 52px); padding-top: 14px; border-top: 1px solid currentColor;
  font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase;
}
.contact .top { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 20px 32px; }
.contact .social { display: flex; gap: 24px; padding-bottom: 6px; font-size: clamp(12px, 0.9vw, 14px); letter-spacing: 0.12em; text-transform: uppercase; }
.contact .social a:hover { color: var(--paper); }

/* Page projet */
.project-head {
  display: grid; grid-template-columns: 1fr 1fr; gap: var(--gutter); align-items: end;
  padding: clamp(40px, 7vw, 100px) var(--gutter) clamp(28px, 4vw, 56px);
}
.project-head h1 { margin: 0; font-family: var(--serif); font-weight: 400; font-size: clamp(44px, 8vw, 120px); line-height: 0.95; letter-spacing: -0.015em; }
.project-head .cat { margin: 0 0 14px; color: var(--muted); }
.project-head .desc p { margin: 0 0 12px; max-width: 52ch; }
.gallery { display: grid; grid-template-columns: minmax(0, 1fr); align-items: start; gap: var(--gap); padding: 0 var(--gutter) clamp(48px, 7vw, 96px); }
.gallery .row { display: flex; align-items: flex-start; gap: var(--gap); }
.gallery img { background: #e9e5dd; }
.gallery .row img { flex: 1 1 0; min-width: 0; width: auto; height: auto; }
.gallery .framed { display: grid; place-items: center; padding: clamp(32px, 7vw, 96px) var(--gutter); }
.gallery .framed img { width: min(100%, 520px); background: #fff; }
.next {
  display: flex; justify-content: space-between; align-items: baseline; gap: 16px;
  margin: 0 var(--gutter); padding: 16px 0 clamp(48px, 7vw, 96px); border-top: 1px solid var(--ink);
}
.next strong { font-family: var(--serif); font-weight: 400; font-size: clamp(32px, 6vw, 84px); line-height: 1; }
.next:hover strong { font-style: italic; }

@media (max-width: 900px) {
  .card { grid-column: span 3; }
  .project-head { grid-template-columns: 1fr; }
  .about-body .portrait { grid-column: 1 / span 5; }
  .about-body .text { grid-column: 6 / span 7; columns: 1; }
}
@media (max-width: 560px) {
  .card { grid-column: span 6; }
  .logo { height: 14px; }
  .nav { gap: 14px; font-size: 11px; }
  .contact { padding-bottom: 76px; }
  .gallery .row { display: block; }
  .gallery .row img { display: block; width: 100%; height: auto; }
  .gallery .row img + img { margin-top: var(--gap); }
  .about-body .portrait, .about-body .text { grid-column: 1 / -1; }
  .about-body .portrait { max-width: 280px; }
  .facts { grid-template-columns: 1fr; gap: 28px; }
}
