/* Accueil : une grande photo, puis une couleur vive par catégorie de cours.
   Ce fichier ne sert qu'à index.html ; les autres pages utilisent style.css. */
@view-transition { navigation: auto; }

:root {
  --ink: #0f1d45;
  --ink-2: #44526f;
  --paper: #ffffff;
  --yellow: #ffc72c;
  --blue: #2446ee;
  --coral: #ff6242;
  --violet: #5a2ad6;
  --font: "Bricolage Grotesque", "Trebuchet MS", "Segoe UI", sans-serif;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; scroll-padding-top: 6rem; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 1.125rem/1.6 var(--font); overflow-x: clip; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-underline-offset: .2em; }
h1, h2, h3, p, ul, fieldset { margin: 0; }
ul { padding: 0; list-style: none; }
h1, h2, h3 { font-weight: 800; line-height: 1.02; letter-spacing: -.025em; text-wrap: balance; }
h1 { font-size: clamp(2.5rem, 5vw, 4.5rem); }
h2 { font-size: clamp(2.4rem, 6vw, 4.5rem); }
button, input { font: inherit; }
:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; }
.wrap { width: 100%; max-width: 82rem; margin-inline: auto; padding-inline: clamp(20px, 4vw, 48px); }
.skip { position: absolute; left: 1rem; top: -5rem; z-index: 40; padding: .6rem 1rem; background: var(--ink); color: #fff; }
.skip:focus { top: .6rem; }

.btn { display: inline-block; padding: 1.05rem 2rem; border: 0; border-radius: .6rem; background: var(--ink); color: #fff; font: 600 1.15rem/1.2 var(--font); text-decoration: none; cursor: pointer; transition: background-color .15s; }
.btn:hover { background: var(--blue); }
.btn--line { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 3px var(--ink); }
.btn--line:hover { background: var(--ink); color: #fff; }
.btn--small { padding: .75rem 1.25rem; font-size: 1.05rem; }
.btn--soft { background: #e8ebf5; color: var(--ink); }
.btn:disabled { opacity: .6; cursor: progress; }
.actions { display: flex; flex-wrap: wrap; gap: .75rem; }

/* En-tête */
.top { position: sticky; top: 0; z-index: 20; background: var(--paper); }
.top__in { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 5rem; }
.brand { display: flex; align-items: center; gap: .7rem; font: 800 1.5rem/1 var(--font); text-decoration: none; }
.brand img { width: 5.4rem; }
.brand small { display: none; }
.menu { display: flex; align-items: center; gap: clamp(1rem, 1.9vw, 2.1rem); }
.menu a:not(.btn) { font-weight: 600; text-decoration: none; }
.menu a:not(.btn):hover { color: var(--blue); text-decoration: underline; }
.burger { display: none; padding: .75rem 1.25rem; border: 0; border-radius: .6rem; background: var(--yellow); color: var(--ink); font: 600 1.05rem/1.2 var(--font); cursor: pointer; }

/* Accueil : pièces flottantes */
.home { overflow: hidden; padding-bottom: 2.5rem; background: radial-gradient(60rem 40rem at 78% 20%, #fff 0, transparent 70%), linear-gradient(#e4ebfb, #f6f8fe 70%, #fff); }
.h-top { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); align-items: center; gap: 2rem; min-height: min(44rem, calc(100vh - 13rem)); padding-block: 1.5rem; }
.h-title { position: relative; z-index: 1; display: grid; gap: 1.6rem; justify-items: start; }
.h-title h1 { font-size: clamp(2.7rem, 5.6vw, 5.5rem); }
.h-title p { font-size: clamp(1.2rem, 1.9vw, 1.5rem); }
.pieces { position: relative; aspect-ratio: 1.12; width: 100%; max-width: 44rem; margin-inline: auto; }
.h-circuit { position: absolute; inset: 0; width: 100%; overflow: visible; pointer-events: none; }
.h-circuit path, .h-circuit .hc-fine circle { fill: none; stroke-linecap: round; stroke-linejoin: round; }
.hc-fine { stroke: #c3d0f3; stroke-width: 3; }
.hc-pulse { stroke: var(--blue); stroke-width: 5; filter: drop-shadow(0 0 6px rgb(36 70 238 / .6)); }
.hc-pulse path { stroke-dasharray: 6 194; animation: hc-run 5s linear var(--d) infinite; }
@keyframes hc-run { from { stroke-dashoffset: -30; } to { stroke-dashoffset: -106; } }
.hc-ring { fill: none; stroke: var(--violet); stroke-width: 4; stroke-dasharray: 3 24; stroke-linecap: round; transform-origin: 510px 455px; animation: hc-turn 60s linear infinite; }
.hc-in { fill: none; stroke: rgb(255 255 255 / .55); stroke-width: 3; }
@keyframes hc-turn { to { transform: rotate(1turn); } }
.h-title em { background: linear-gradient(95deg, var(--blue), #8a3ffc); background-clip: text; -webkit-background-clip: text; color: transparent; font-style: normal; }
.pieces a { position: absolute; left: var(--x); top: var(--y); width: var(--w); text-decoration: none; translate: calc(var(--mx, 0) * var(--d)) calc(var(--my, 0) * var(--d)); transition: translate .5s cubic-bezier(.2, .8, .2, 1); }
.pieces i { display: block; rotate: var(--r); animation: h-float var(--t) ease-in-out infinite alternate; }
.pieces img { width: 100%; filter: drop-shadow(0 1.4rem 1.2rem rgb(15 29 69 / .34)); transition: scale .35s cubic-bezier(.2, .8, .2, 1); }
.pieces a:hover img, .pieces a:focus-visible img { scale: 1.08; }
.pieces span { position: absolute; left: 50%; bottom: -.4rem; z-index: 2; padding: .3rem .9rem; border-radius: 99px; background: var(--ink); color: #fff; font-size: 1rem; font-weight: 600; line-height: 1.3; white-space: nowrap; translate: -50% 0; opacity: 0; transition: opacity .2s; }
.pieces a:hover, .pieces a:focus-visible { z-index: 9; }
.pieces a:hover span, .pieces a:focus-visible span { opacity: 1; }
.pieces a:focus-visible { outline-offset: 8px; border-radius: 1rem; }
.p-refroidissement { --x: 33%; --y: 9%; --w: 34%; --r: 4deg; --t: 4.5s; --d: 10px; z-index: 3; }
.p-gpu { --x: 31%; --y: 63%; --w: 64%; --r: -7deg; --t: 5.5s; --d: 24px; z-index: 5; }
.p-cpu { --x: 3%; --y: 36%; --w: 27%; --r: -9deg; --t: 4s; --d: 34px; z-index: 6; }
.p-ram { --x: 66%; --y: 24%; --w: 36%; --r: 64deg; --t: 5s; --d: 28px; z-index: 4; }
.p-alimentation { --x: 7%; --y: 67%; --w: 27%; --r: 2deg; --t: 6s; --d: 18px; z-index: 6; }
.p-ssd-m2 { --x: 3%; --y: 12%; --w: 29%; --r: -20deg; --t: 4.8s; --d: 38px; z-index: 4; }
@keyframes h-float { from { transform: translateY(-.5rem); } to { transform: translateY(.6rem); } }
.h-steps { position: relative; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin: 0; padding: 0; overflow: hidden; border-radius: 1.5rem; background: #fff; box-shadow: 0 1rem 3rem rgb(15 29 69 / .14); list-style: none; }
.h-steps li + li { border-left: 1px solid #dde4f2; }
.h-steps a { display: flex; align-items: center; gap: 1.1rem; height: 100%; padding: 1.5rem clamp(1rem, 1.8vw, 1.75rem); line-height: 1.3; text-decoration: none; transition: background-color .2s; }
.h-steps a:hover { background: #fff6d9; }
.h-steps i { flex: none; display: grid; place-items: center; width: 3.1rem; height: 3.1rem; border-radius: 50%; background: var(--c); color: #fff; font-size: 1.4rem; font-style: normal; font-weight: 800; }
.h-steps li:nth-child(1) { --c: var(--ink); }
.h-steps li:nth-child(2) { --c: var(--blue); }
.h-steps li:nth-child(3) { --c: var(--violet); }
.h-steps li:nth-child(4) { --c: #d63c1c; }
.h-steps b { display: block; font-size: 1.35rem; font-weight: 800; letter-spacing: -.02em; }
.h-steps span { color: var(--ink-2); }
.h-steps b { color: var(--ink); }
.h-credit { padding-top: .9rem; color: var(--ink-2); font-size: .85rem; }
.h-credit summary { width: fit-content; cursor: pointer; }

/* Publicité des services */
.services .wrap { padding-block: clamp(3rem, 6vw, 5.5rem); }
.s-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1.5rem 3rem; }
.s-head h2 { max-width: 16ch; font-size: clamp(2.2rem, 4.6vw, 3.8rem); }
.s-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(1.25rem, 2.5vw, 2.25rem); margin-top: 2.5rem; }
.s-pic { position: relative; overflow: hidden; border-radius: 1.5rem; aspect-ratio: 5 / 6; background: var(--ink); }
.s-grid img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .7s cubic-bezier(.2, .8, .2, 1); }
.s-grid li:first-child img { object-position: 42% 50%; }
.s-grid li:nth-child(2) img { object-position: 15% 50%; }
.s-grid li:hover img { transform: scale(1.06); }
.s-pic svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.s-hud { fill: none; stroke: #fff; stroke-width: 1; stroke-linecap: round; stroke-linejoin: round; }
.s-rec { fill: #ff3b4e; animation: s-blink 1.6s ease-in-out infinite; }
@keyframes s-blink { 50% { opacity: .15; } }
.s-wifi circle { fill: var(--yellow); }
.s-wifi path { fill: none; stroke: var(--ink); stroke-width: 1.6; stroke-linecap: round; }
.s-grid h3 { margin-top: 1.2rem; font-size: clamp(1.6rem, 2.4vw, 2.1rem); }
.s-grid p { margin-top: .4rem; color: var(--ink-2); line-height: 1.4; }

/* Inscription */
.signup-section { background: var(--violet); color: #fff; }
.signup { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 2rem clamp(2rem, 6vw, 6rem); padding-block: clamp(3.5rem, 7vw, 6.5rem); }
.signup > div:first-child { display: grid; gap: 1.1rem; align-content: start; }
.signup p { font-size: 1.15rem; }
.signup :focus-visible { outline-color: var(--yellow); }
.form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.35rem; }
.field { display: grid; gap: .45rem; align-content: start; min-width: 0; }
.field--wide { grid-column: 1 / -1; }
.field label, .field legend { padding: 0; font-weight: 600; }
.field input:not([type="checkbox"]) { width: 100%; min-height: 3.5rem; padding: .8rem 1.1rem; border: 0; border-radius: .6rem; background: #fff; color: var(--ink); }
.field .check { display: flex; align-items: flex-start; gap: .75rem; font-weight: 400; cursor: pointer; }
.check input { flex: none; width: 1.35rem; height: 1.35rem; margin: .2rem 0 0; accent-color: var(--yellow); }
.form .btn { background: var(--yellow); color: var(--ink); }
.form .btn:hover { background: #fff; }
.trap { position: absolute; left: -9999px; }
.status:empty { display: none; }
.status[data-kind="error"] { padding: 1rem 1.2rem; border-radius: .6rem; background: #fff; color: var(--ink); }
.thanks { display: grid; gap: .75rem; padding: 2rem; border-radius: .6rem; background: var(--yellow); color: var(--ink); }
.thanks h3 { font-size: 1.8rem; }

.who { display: flex; align-items: center; gap: 1.5rem; margin: .5rem 0 0; }
.who img { flex: none; width: clamp(8rem, 13vw, 11rem); aspect-ratio: 1; border-radius: 50%; object-fit: cover; object-position: 50% 30%; background: #fff; box-shadow: 0 0 0 .4rem var(--yellow); }
.who figcaption { line-height: 1.3; }
.who b { display: block; font-size: clamp(1.4rem, 2.2vw, 1.8rem); font-weight: 800; letter-spacing: -.02em; }
.contact { display: grid; gap: .75rem; margin-top: .75rem; }
.contact a { display: flex; align-items: center; gap: 1.1rem; padding: 1.1rem 1.3rem; border-radius: 1.2rem; background: rgb(255 255 255 / .12); line-height: 1.3; text-decoration: none; overflow-wrap: anywhere; transition: background-color .15s; }
.contact a:hover { background: rgb(255 255 255 / .22); }
.contact svg { flex: none; width: 3rem; height: 3rem; padding: .6rem; border-radius: 50%; background: var(--yellow); fill: none; stroke: var(--ink); stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; }
.contact b { display: block; font-size: 1.25rem; }

.linkish { padding: 0; border: 0; background: none; color: inherit; text-decoration: underline; text-underline-offset: .2em; cursor: pointer; }
.thanks .btn { margin-top: .5rem; }
.thanks :focus-visible { outline-color: var(--ink); }
.thanks:focus { outline: 0; }
.h-steps em { font-style: normal; }

/* Appel à l'inscription */
.join { display: grid; align-content: center; justify-items: start; gap: 1.1rem; height: 100%; padding: clamp(1.75rem, 4vw, 3.5rem); border-radius: 1.75rem; background: linear-gradient(120deg, #2446ee, #8a3ffc); }
.join svg { width: 5rem; fill: none; stroke: var(--yellow); stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }
.join h3 { font-size: clamp(2rem, 3.6vw, 3rem); }
.join p { overflow-wrap: anywhere; }
.join .btn { background: var(--yellow); color: var(--ink); }
.join .btn:hover { background: #fff; }
.join .btn--line { background: transparent; color: #fff; box-shadow: inset 0 0 0 3px #fff; }
.join .btn--line:hover { color: var(--ink); }

/* Cookies et pied de page */
.cookies { position: fixed; inset: auto 1rem 1rem; z-index: 25; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem; max-width: 60rem; margin-inline: auto; padding: 1.2rem 1.5rem; border-radius: .8rem; background: #fff; box-shadow: 0 10px 50px rgb(15 29 69 / .4); }
.cookies p { flex: 1 1 22rem; }
.foot { padding-block: 2.25rem; }
.foot__in { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1.25rem 2.5rem; }
.foot img { width: 7rem; }
.foot nav { display: flex; flex-wrap: wrap; gap: .75rem 1.75rem; }
.foot button { padding: 0; border: 0; background: none; color: inherit; text-decoration: underline; text-underline-offset: .2em; cursor: pointer; }

@media (max-width: 62rem) {
  .burger { display: block; }
  .menu { display: none; position: absolute; inset: 100% 0 auto; flex-direction: column; align-items: stretch; gap: 0; max-height: calc(100vh - 5rem); overflow-y: auto; padding: .25rem 20px 1.5rem; background: #fff; box-shadow: 0 16px 24px rgb(15 29 69 / .15); }
  .menu.is-open { display: flex; }
  .menu a:not(.btn) { padding-block: .85rem; }
  .menu .btn { margin-top: .75rem; text-align: center; }
    }
@media (min-width: 48.01rem) and (max-width: 68rem) { .h-steps a { gap: .75rem; padding: 1.1rem .9rem; } .h-steps i { width: 2.4rem; height: 2.4rem; font-size: 1.1rem; } .h-steps span { font-size: .95rem; } .h-steps b { font-size: 1.15rem; } }
@media (max-width: 48rem) {
  .h-top { grid-template-columns: minmax(0, 1fr); min-height: 0; gap: 2.75rem; }
  .h-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .h-steps li:nth-child(3) { border-left: 0; }
  .h-steps li:nth-child(n + 3) { border-top: 1px solid #dde4f2; }
  .s-grid { grid-template-columns: minmax(0, 1fr); gap: 2.25rem; }
  .signup { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 36rem) {
  .h-steps a { flex-direction: column; align-items: flex-start; gap: .6rem; padding: 1.1rem; }
  .h-steps i { width: 2.5rem; height: 2.5rem; font-size: 1.15rem; }
  .form { grid-template-columns: minmax(0, 1fr); }
  .brand img { width: 4.6rem; }
}
@media (prefers-reduced-motion: reduce) {
  @view-transition { navigation: none; }
  html { scroll-behavior: auto; }
  * { transition: none !important; animation: none !important; }
}
