:root {
  --ink: #0b0e12;
  --ink-2: #141a22;
  --bone: #f0f4f8;
  --mist: #98a4b3;
  --line: rgba(240, 244, 248, 0.14);
  --display: "Shippori Mincho B1", "Hiragino Mincho ProN", "Yu Mincho", serif;
  --text: "Zen Kaku Gothic New", "Hiragino Sans", "Yu Gothic", system-ui, sans-serif;
  --pad: clamp(20px, 5vw, 56px);
}

* { box-sizing: border-box; }

html { background: var(--ink); color-scheme: dark; }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--ink);
  color: var(--bone);
  font-family: var(--text);
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }
:focus-visible { outline: 2px solid var(--bone); outline-offset: 3px; border-radius: 6px; }

/* ---------- Mur de couvertures ---------- */

.wall {
  position: fixed;
  inset: 0;
  z-index: 0;
  display: flex;
  gap: 10px;
  padding: 0 10px;
  overflow: hidden;
  opacity: 0;
  transition: opacity 1.6s ease;
  pointer-events: none;
}
.wall.on { opacity: 1; }

/* voile : garde le centre lisible, laisse les bords respirer */
.wall::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 70% 60% at 50% 42%, rgba(11, 14, 18, 0.94) 0%, rgba(11, 14, 18, 0.82) 55%, rgba(11, 14, 18, 0.6) 100%),
    linear-gradient(to bottom, rgba(11, 14, 18, 0.7), rgba(11, 14, 18, 0) 18%, rgba(11, 14, 18, 0) 70%, var(--ink));
}

.col {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
  animation: drift var(--t, 90s) linear infinite;
  animation-direction: var(--dir, normal);
  will-change: transform;
}
.col:nth-child(n + 5) { display: none; }

.cover {
  display: block;
  width: 100%;
  aspect-ratio: 2 / 3;
  border-radius: 6px;
  background: var(--c, #1b2430);
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.8s ease;
  filter: saturate(0.85);
}
.cover.in { opacity: 0.55; }

@keyframes drift {
  from { transform: translateY(0); }
  to { transform: translateY(-50%); }
}

@media (min-width: 640px) { .col:nth-child(n + 5) { display: flex; } .col:nth-child(n + 7) { display: none; } }
@media (min-width: 1000px) { .col:nth-child(n + 7) { display: flex; } .col:nth-child(n + 9) { display: none; } }

/* ---------- Barre du haut ---------- */

.top {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: max(18px, env(safe-area-inset-top)) var(--pad) 0;
}
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-family: var(--display); font-weight: 700; font-size: 1.2rem; }
.brand img { display: block; border-radius: 50%; }
.top-link { color: var(--mist); font-size: 0.9rem; text-decoration: none; padding: 8px 0; }
.top-link:hover { color: var(--bone); }

main, .foot { position: relative; z-index: 1; }

/* ---------- Hero ---------- */

.hero {
  min-height: min(calc(100svh - 64px), 860px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 24px var(--pad) 56px;
}

.mark { width: min(46vw, 236px); aspect-ratio: 1; }
.mark svg { display: block; width: 100%; height: 100%; overflow: visible; }

.ring { fill: none; stroke: var(--bone); stroke-opacity: 0.16; stroke-width: 1.5; }
.orbit { transform-origin: 400px 400px; animation: orbit 36s linear infinite; }
.moon { fill: var(--bone); opacity: 0.85; }
.disc { fill: var(--bone); transform-origin: 400px 400px; animation: disc-in 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) both; }
.ripple { fill: none; stroke: var(--bone); stroke-width: 2; opacity: 0; transform-origin: 400px 400px; animation: ripple 1.8s ease-out 1.9s both; }

.stroke {
  fill: none;
  stroke: #15191e;
  stroke-linejoin: miter;
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
  animation: draw 0.42s cubic-bezier(0.5, 0, 0.2, 1) forwards;
}
.s1 { stroke-width: 18; animation-delay: 0.75s; }
.s2 { stroke-width: 32; animation-delay: 1.1s; animation-duration: 0.7s; }
.s3 { stroke-width: 26; animation-delay: 1.65s; }
.s4 { stroke-width: 29; animation-delay: 1.9s; }

@keyframes disc-in { from { transform: scale(0.72); opacity: 0; } to { transform: scale(1); opacity: 1; } }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes ripple { 0% { transform: scale(1); opacity: 0.55; } 100% { transform: scale(1.55); opacity: 0; } }
@keyframes orbit { to { transform: rotate(360deg); } }

h1 {
  margin: 28px 0 0;
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(3.4rem, 15vw, 6.6rem);
  line-height: 1;
  letter-spacing: -0.02em;
}

.lead {
  margin: 14px 0 0;
  max-width: 24em;
  color: #c9d2dd;
  font-size: clamp(1.05rem, 3.6vw, 1.25rem);
}

/* ---------- Téléchargement ---------- */

.get { margin-top: 32px; width: 100%; max-width: 440px; display: flex; flex-direction: column; align-items: center; gap: 12px; }
.get-state { margin: 0; color: var(--mist); font-size: 0.95rem; }
.get-buttons { display: flex; flex-direction: column; gap: 10px; width: 100%; }
.get-hint { margin: 0; color: var(--mist); font-size: 0.9rem; max-width: 30em; }
.get-hint a { color: var(--bone); }

.btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 58px;
  padding: 10px 26px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--bone);
  font: 700 1.05rem/1.2 var(--text);
  text-decoration: none;
  transition: transform 0.15s ease, background-color 0.2s ease, border-color 0.2s ease;
}
.btn svg { flex: none; width: 22px; height: 22px; }
.btn small { display: block; font-weight: 500; font-size: 0.82rem; opacity: 0.7; }
.btn:hover { border-color: rgba(240, 244, 248, 0.4); }
.btn:active { transform: scale(0.98); }

.btn.primary { background: var(--bone); border-color: var(--bone); color: var(--ink); }
.btn.primary:hover { background: #fff; }

.btn-text { display: flex; flex-direction: column; align-items: flex-start; text-align: left; }

.get-other { color: var(--mist); font-size: 0.95rem; }

/* ---------- Sections ---------- */

.notes, .install {
  max-width: 44rem;
  margin: 0 auto;
  padding: 56px var(--pad) 8px;
}
.notes { border-top: 1px solid var(--line); }
.notes, .install { background: var(--ink); }

h2 { margin: 0; font-family: var(--display); font-weight: 700; font-size: 1.7rem; line-height: 1.2; }
.notes-meta { margin: 6px 0 22px; color: var(--mist); font-size: 0.95rem; }

.notes-body { position: relative; }
.notes-body.folded { max-height: 24rem; overflow: hidden; }
.notes-body.folded::after { content: ""; position: absolute; inset: auto 0 0 0; height: 7rem; background: linear-gradient(to bottom, rgba(11, 14, 18, 0), var(--ink)); pointer-events: none; }
.notes-more { margin-top: 14px; min-height: 44px; padding: 8px 20px; border-radius: 999px; border: 1px solid var(--line); background: transparent; color: var(--bone); font: 700 0.95rem var(--text); cursor: pointer; transition: border-color 0.2s ease; }
.notes-more:hover { border-color: rgba(240, 244, 248, 0.4); }

.notes-body h3 { margin: 26px 0 8px; font-size: 1.05rem; font-weight: 700; }
.notes-body h3:first-child { margin-top: 0; }
.notes-body ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.notes-body li { position: relative; padding-left: 20px; max-width: 62ch; color: #d4dce6; }
.notes-body li::before { content: ""; position: absolute; left: 0; top: 0.72em; width: 8px; height: 1px; background: var(--mist); }
.notes-body p { max-width: 62ch; color: #d4dce6; }
.notes-body strong { color: var(--bone); font-weight: 700; }
.muted { color: var(--mist); }

.install ol { margin: 18px 0 0; padding-left: 1.3em; display: grid; gap: 10px; max-width: 56ch; color: #d4dce6; }
.install li::marker { color: var(--mist); font-family: var(--display); font-weight: 700; }

.foot {
  max-width: 44rem;
  margin: 0 auto;
  padding: 56px var(--pad) calc(40px + env(safe-area-inset-bottom));
  background: var(--ink);
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  color: var(--mist);
  font-size: 0.9rem;
}
.foot a { color: var(--bone); }

@media (min-width: 640px) {
  .get-buttons { flex-direction: row; justify-content: center; }
  .get-buttons.single { flex-direction: column; }
  .btn { flex: 1; }
  .get-buttons.single .btn { flex: none; }
}

/* ---------- Mouvement réduit ---------- */

@media (prefers-reduced-motion: reduce) {
  .col, .orbit, .disc, .ripple, .stroke { animation: none !important; }
  .stroke { stroke-dashoffset: 0; }
  .ripple { opacity: 0; }
  .wall { transition: none; }
}
