@font-face { font-family: Inter; font-weight: 200; font-style: italic; font-display: swap; src: url(../assets/fonts/inter-latin-200-italic.woff2) format("woff2"); }
@font-face { font-family: Inter; font-weight: 300; font-display: swap; src: url(../assets/fonts/inter-latin-300-normal.woff2) format("woff2"); }
@font-face { font-family: Inter; font-weight: 400; font-display: swap; src: url(../assets/fonts/inter-latin-400-normal.woff2) format("woff2"); }
@font-face { font-family: Inter; font-weight: 500; font-display: swap; src: url(../assets/fonts/inter-latin-500-normal.woff2) format("woff2"); }

:root {
  --paper: #f6f6f8;
  --ink: #111114;
  --soft: rgb(17 17 20 / .68);
  --line: rgb(17 17 20 / .14);
  --gap: clamp(10px, 1.1vw, 20px);
  --side: clamp(16px, 2.6vw, 48px);
  --out: cubic-bezier(.23, 1, .32, 1);
  color-scheme: light;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 300 15px/1.45 Inter, system-ui, sans-serif; -webkit-font-smoothing: antialiased; }
button, a { font: inherit; color: inherit; -webkit-tap-highlight-color: transparent; }
svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; flex: none; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }

/* ——— La page tient sur un écran d'ordinateur : l'en-tête, puis deux rangées qui se partagent la hauteur. */
.page { height: 100dvh; min-height: 620px; display: grid; grid-template-rows: auto 1fr; padding: 0 var(--side) clamp(14px, 1.6vw, 28px); }
.top { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 24px; padding: clamp(14px, 1.5vw, 24px) 0; }
.brand { display: inline-flex; align-items: center; gap: 14px; text-decoration: none; justify-self: start; }
.bee { width: 40px; height: 40px; padding: 8px; border-radius: 12px; background: linear-gradient(45deg, #2563eb, #a855f7, #f97316); transition: transform .4s var(--out); }
.bee img { display: block; width: 100%; height: 100%; object-fit: contain; }
.word { font-size: 18px; letter-spacing: .2em; text-transform: uppercase; line-height: 1.1; display: grid; }
.word small { font-size: 8px; font-weight: 500; letter-spacing: .4em; margin-top: 4px; background: linear-gradient(to right, #2563eb, #9333ea, #c2410c); -webkit-background-clip: text; background-clip: text; color: transparent; width: max-content; }
h1 { margin: 0; font-size: clamp(22px, 2vw, 34px); font-weight: 300; letter-spacing: -.03em; line-height: 1.1; white-space: nowrap; }
h1 em { font-weight: 200; color: var(--soft); }
.acts { display: flex; gap: 10px; justify-self: end; }
.btn { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; padding: 0 22px; border: 1px solid var(--ink); border-radius: 99px; background: var(--ink); color: #fff; font-size: 14px; font-weight: 400; text-decoration: none; white-space: nowrap; cursor: pointer; transition: background-color .25s, color .25s, transform .2s var(--out); }
.btn.ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn.ghost svg { fill: currentColor; stroke: none; width: 11px; height: 11px; }
.btn:active, .round:active { transform: scale(.96); }

.grid { display: grid; grid-template-columns: repeat(12, 1fr); grid-template-rows: 1.22fr 1fr; gap: var(--gap); min-height: 0; }
.card {
  grid-column: span var(--w); min-height: 0; display: grid; grid-template-rows: 1fr auto; padding: 7px 7px 0; border-radius: 22px; text-decoration: none;
  background: linear-gradient(150deg, color-mix(in srgb, var(--c) 42%, white), color-mix(in srgb, var(--c) 64%, white));
  box-shadow: 0 1px 2px rgb(17 17 20 / .06), 0 22px 44px -28px rgb(17 17 20 / .4);
  transition: transform .5s var(--out), box-shadow .5s var(--out);
}
.shot { position: relative; min-height: 0; overflow: hidden; border-radius: 15px; background: #0b0b0c; display: block; }
.shot video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: top; transition: transform .9s var(--out); }
.bar { display: flex; align-items: baseline; gap: 12px; padding: 11px 10px 13px; white-space: nowrap; min-width: 0; }
.bar strong { font-weight: 500; font-size: 15px; }
.bar span { color: var(--soft); font-size: 14px; overflow: hidden; text-overflow: ellipsis; flex: 1; }
.bar i { font-style: normal; font-size: 13px; color: var(--soft); }
@media (hover: hover) {
  .card:hover { transform: translateY(-3px); box-shadow: 0 1px 2px rgb(17 17 20 / .06), 0 34px 60px -30px rgb(17 17 20 / .5); }
  .card:hover video { transform: scale(1.025); }
  .brand:hover .bee { transform: scale(1.06); }
  .btn:hover { background: #fff; color: var(--ink); }
  .btn.ghost:hover, .round:hover { background: var(--ink); color: #fff; }
}

/* Entrée : les cartes se posent l'une après l'autre, une seule fois. */
@media (prefers-reduced-motion: no-preference) {
  .js .card { animation: pose .9s var(--out) both; }
  .js .card:nth-child(2) { animation-delay: .07s; } .js .card:nth-child(3) { animation-delay: .14s; }
  .js .card:nth-child(4) { animation-delay: .21s; } .js .card:nth-child(5) { animation-delay: .28s; }
  @keyframes pose { from { opacity: 0; transform: translateY(26px) scale(.985); } }
}

/* ——— La planche */
.plate { width: 100vw; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: clamp(16px, 2vw, 34px) var(--side); border: 0; color: var(--ink); overflow: hidden;
  background: linear-gradient(160deg, color-mix(in srgb, var(--c, #ddd) 14%, var(--paper)), var(--paper) 55%); }
.plate[open] { display: grid; grid-template-rows: auto 1fr auto; gap: clamp(14px, 1.8vw, 28px); }
.plate::backdrop { background: var(--paper); }
.steps { display: flex; gap: 6px; padding-right: 64px; align-self: center; min-height: 44px; align-items: center; }
.steps span { flex: 1; height: 3px; border-radius: 3px; background: var(--line); overflow: hidden; }
.steps span::after { content: ""; display: block; height: 100%; background: var(--ink); transform: scaleX(var(--p, 0)); transform-origin: left; }
.round { display: inline-grid; place-items: center; width: 44px; height: 44px; border: 1px solid var(--line); border-radius: 50%; background: rgb(255 255 255 / .7); cursor: pointer; transition: background-color .2s, color .2s, transform .2s var(--out); }
.close { position: absolute; top: clamp(16px, 2vw, 34px); right: var(--side); }

.screens { min-height: 0; display: flex; align-items: center; justify-content: center; gap: clamp(16px, 2.2vw, 44px); container-type: size; }
.desk, .phone { overflow: hidden; background: #0b0b0c; box-shadow: 0 2px 4px rgb(17 17 20 / .08), 0 50px 90px -40px rgb(17 17 20 / .5); }
/* Largeur totale = 1,6 h (ordinateur) + 0,462 × 0,9 h (téléphone) + l'écart : la hauteur est celle qui fait tenir les deux. */
.desk { height: min(100cqh, calc((100cqw - 44px) / 2.02)); aspect-ratio: 1.6; border-radius: clamp(12px, 1.2vw, 20px); border: clamp(5px, .5vw, 9px) solid #1b1b1d; }
.phone { height: min(90cqh, calc((100cqw - 44px) / 2.02 * .9)); aspect-ratio: 390 / 844; border-radius: clamp(20px, 2.1vw, 36px); border: clamp(5px, .5vw, 9px) solid #1b1b1d; }
.screens video { display: block; width: 100%; height: 100%; object-fit: cover; object-position: top; }

.foot { display: grid; grid-template-columns: 1fr auto auto; align-items: end; gap: 24px clamp(24px, 3vw, 56px); }
.foot h2 { margin: 0 0 6px; font-size: clamp(30px, 3.2vw, 56px); font-weight: 200; letter-spacing: -.04em; line-height: 1; }
.foot p { margin: 0; max-width: 62ch; color: var(--soft); font-size: clamp(15px, 1.05vw, 17px); text-wrap: pretty; }
.links { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; }
.nav { display: flex; align-items: center; gap: 12px; }
.nav span { min-width: 46px; text-align: center; font-variant-numeric: tabular-nums; color: var(--soft); }

/* Changement de site : fondu glissé ; ouverture : la carte grandit (View Transitions). */
@media (prefers-reduced-motion: no-preference) {
  .swap .desk, .swap .phone, .swap .info { animation: swap .55s var(--out) both; }
  .swap .phone { animation-delay: .06s; } .swap .info { animation-delay: .1s; }
  @keyframes swap { from { opacity: 0; transform: translateX(calc(var(--d, 1) * 36px)); } }
  ::view-transition-group(shot) { animation-duration: .6s; animation-timing-function: var(--out); }
  ::view-transition-old(root), ::view-transition-new(root) { animation-duration: .35s; }
  ::view-transition-old(shot), ::view-transition-new(shot) { height: 100%; width: 100%; object-fit: cover; object-position: top; overflow: clip; border-radius: 16px; }
}

/* ——— Écrans étroits : une colonne qui défile. */
@media (max-width: 1080px) {
  .page { height: auto; min-height: 0; padding-bottom: calc(28px + env(safe-area-inset-bottom)); }
  .top { grid-template-columns: 1fr auto; }
  h1 { grid-column: 1 / -1; grid-row: 2; font-size: clamp(34px, 8vw, 56px); padding: 18px 0 10px; }
  .grid { grid-template-rows: none; grid-template-columns: repeat(2, 1fr); }
  .card { grid-column: span 1; }
  .card:first-child { grid-column: 1 / -1; }
  .shot { aspect-ratio: 1.6; }
  .bar { flex-wrap: wrap; gap: 0 12px; }
  .bar strong { flex: 1; } .bar span { order: 3; flex-basis: 100%; }
  .foot { grid-template-columns: 1fr auto; align-items: center; }
  .info { grid-column: 1 / -1; }
  .links { justify-content: flex-start; }
}
@media (max-width: 700px) {
  .acts .ghost { display: none; }
  .btn { padding: 0 18px; }
  .grid { grid-template-columns: 1fr; gap: 18px; }
  .word { font-size: 15px; }
  .brand { gap: 10px; }
  .plate[open] { grid-template-rows: auto minmax(0, 1fr) auto; gap: 14px; }
  .screens { flex-direction: row; position: relative; }
  .desk { height: auto; width: 100cqw; aspect-ratio: 1.6; align-self: flex-start; }
  .phone { position: absolute; right: 0; bottom: 0; height: min(72cqh, 66cqw * 2.16); max-height: calc(100cqh - 34cqw); }
  .foot { gap: 14px; padding-bottom: env(safe-area-inset-bottom); }
  .links { grid-column: 1 / -1; flex-wrap: nowrap; gap: 6px; }
  .links .btn { flex: 1; justify-content: center; padding: 0 8px; gap: 7px; font-size: 13px; }
  .nav { grid-column: 1 / -1; justify-content: space-between; }
}
