/* Runelapse Studio — site vitrine. Charte graphique v1.0 (novembre 2026) :
   Nuit / Pierre / Os, Lueur rare (quelques % de la composition),
   Syncopate en capitales espacées pour les titres courts, Space Grotesk pour le texte. */

@font-face { font-family: "Syncopate"; src: url("/assets/fonts/Syncopate-Regular.ttf") format("truetype"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Syncopate"; src: url("/assets/fonts/Syncopate-Bold.ttf") format("truetype"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Space Grotesk"; src: url("/assets/fonts/SpaceGrotesk-Variable.ttf") format("truetype"); font-weight: 300 700; font-display: swap; }

:root {
  --nuit: #0E0F12;
  --pierre: #2A2D33;
  --os: #EDE8DE;
  --lueur: #6FE0D2;
  --lueur-profonde: #1F8F84;
  --os-60: rgba(237, 232, 222, .62);
  --os-40: rgba(237, 232, 222, .4);
  --os-15: rgba(237, 232, 222, .15);
  --os-08: rgba(237, 232, 222, .08);
  --display: "Syncopate", "Arial Black", sans-serif;
  --text: "Space Grotesk", system-ui, -apple-system, "Segoe UI", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; }
body {
  margin: 0;
  background: var(--nuit);
  color: var(--os);
  font-family: var(--text);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
p, h1, h2, h3, ol, ul { margin: 0; }
::selection { background: var(--lueur); color: var(--nuit); }

.wrap { width: min(1200px, 100% - 48px); margin-inline: auto; }
.skip { position: absolute; left: -9999px; top: 8px; padding: 10px 16px; background: var(--os); color: var(--nuit); z-index: 100; }
.skip:focus { left: 8px; }
:focus-visible { outline: 2px solid var(--lueur); outline-offset: 3px; }

/* ---------- Typo ---------- */
.label {
  font-weight: 500; font-size: .74rem; letter-spacing: .28em; text-transform: uppercase;
  color: var(--os-60);
}
.display, .title, .next-title {
  font-family: var(--display); text-transform: uppercase; line-height: 1.12;
}
.display { font-size: clamp(2.1rem, 5.6vw, 4.6rem); letter-spacing: .14em; margin: 26px 0 30px; }
.display span { display: block; }
.b { font-weight: 700; }
.r { font-weight: 400; }
.title { font-size: clamp(1.45rem, 3.2vw, 2.35rem); font-weight: 700; letter-spacing: .2em; margin: 16px 0 22px; }
.intro { font-size: 1.12rem; color: var(--os-60); max-width: 640px; }
.lead { font-size: 1.15rem; color: var(--os-60); max-width: 540px; }

/* ---------- Nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 40;
  background: rgba(14, 15, 18, .82);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--os-08);
}
.nav-inner { height: 76px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.nav-logo img { width: 184px; }
.nav-links { display: flex; align-items: center; gap: 34px; }
.nav-links a {
  text-decoration: none; font-size: .76rem; font-weight: 500; letter-spacing: .22em; text-transform: uppercase;
  color: var(--os-60); transition: color .2s;
}
.nav-links a:hover { color: var(--os); }
.nav-links .nav-cta { color: var(--os); padding: 10px 18px; border: 1px solid var(--os-40); }
.nav-links .nav-cta:hover { border-color: var(--os); }

/* ---------- Boutons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 16px 26px; background: var(--os); color: var(--nuit); text-decoration: none;
  font-size: .78rem; font-weight: 600; letter-spacing: .2em; text-transform: uppercase;
  border: 1px solid var(--os); transition: background .2s, color .2s;
}
.btn:hover { background: transparent; color: var(--os); }
.btn-line { background: transparent; color: var(--os); border-color: var(--os-40); }
.btn-line:hover { border-color: var(--os); }

/* ---------- Hero ---------- */
.hero { position: relative; min-height: min(calc(100svh - 76px), 920px); display: flex; align-items: center; padding: 64px 0 96px; }
.hero-grid { display: grid; grid-template-columns: 1.15fr .85fr; align-items: center; gap: 64px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 40px; }
.hero-seal { display: grid; justify-items: center; gap: 22px; }
.seal { width: min(400px, 100%); height: auto; overflow: visible; }
.seal .tick, .seal .glass { fill: var(--os); }
.seal .grain { fill: var(--lueur); }
.seal-caption { font-size: .82rem; color: var(--os-40); text-align: center; max-width: 300px; }

/* Animation du sceau (usage prévu par la charte : écran d'ouverture / indicateur) :
   les graduations apparaissent dans le sens horaire, puis le grain prend la place de midi. */
.js .seal .tick { opacity: 0; animation: tick-in .5s ease forwards, tick-pulse 11s linear infinite; animation-delay: calc(.35s + var(--i) * .11s), calc(2.2s + var(--i) * 1s); }
.js .seal .glass { opacity: 0; animation: fade-in 1s ease .1s forwards; }
.js .seal .grain-core { opacity: 0; animation: fade-in .8s ease 1.1s forwards; }
.js .seal .grain-noon { opacity: 0; transform-box: fill-box; transform-origin: center; animation: grain-in .9s cubic-bezier(.2, .8, .2, 1) 1.75s forwards; }
@keyframes tick-in { to { opacity: 1; } }
@keyframes fade-in { to { opacity: 1; } }
@keyframes grain-in { from { opacity: 0; transform: translateY(-14px); } to { opacity: 1; transform: none; } }
/* Une seule graduation « passe » à la fois, comme une trotteuse lente */
@keyframes tick-pulse { 0%, 100% { opacity: 1; } 3% { opacity: .25; } 7% { opacity: 1; } }

.scroll-hint { position: absolute; left: 50%; bottom: 28px; transform: translateX(-50%); width: 22px; height: 36px; border: 1px solid var(--os-40); border-radius: 12px; }
.scroll-hint span { position: absolute; left: 50%; top: 7px; width: 3px; height: 7px; margin-left: -1.5px; background: var(--os-60); border-radius: 2px; animation: scroll 2.2s ease-in-out infinite; }
@keyframes scroll { 0% { opacity: 0; transform: translateY(0); } 30% { opacity: 1; } 70% { opacity: 0; transform: translateY(12px); } 100% { opacity: 0; } }

/* ---------- Sections ---------- */
.section { padding: 128px 0; }
.head { margin-bottom: 64px; }

/* Fond clair : Os + accent Lueur profonde */
.section-os { background: var(--os); color: var(--nuit); }
.section-os .label { color: rgba(14, 15, 18, .55); }
.section-os .intro { color: rgba(14, 15, 18, .7); }

.concept { list-style: none; padding: 0; display: grid; grid-template-columns: 1fr auto 1fr auto 1fr; gap: 28px; align-items: start; }
.concept-step p:last-child { color: rgba(14, 15, 18, .7); font-size: .98rem; max-width: 340px; }
.concept-art { aspect-ratio: 1; max-width: 240px; background: #E2DDD2; display: grid; place-items: center; margin-bottom: 22px; }
.concept-art svg { width: 62%; height: 62%; }
.concept-art .stroke { fill: none; stroke: var(--nuit); stroke-width: 7; stroke-linecap: square; stroke-linejoin: miter; }
.concept-art img { width: 30%; }
.concept-n { font-size: .78rem; font-weight: 600; letter-spacing: .22em; text-transform: uppercase; margin-bottom: 12px; }
.concept-arrow { align-self: center; margin-top: -90px; font-size: 1.4rem; color: rgba(14, 15, 18, .5); }
.concept-step:nth-child(1) .stroke { transition: transform 1.2s cubic-bezier(.6, 0, .2, 1); transform-origin: 50% 50%; }
.concept-step:nth-child(1):hover .stroke { transform: rotate(90deg); }

/* Applications */
.app {
  display: grid; grid-template-columns: 1.05fr .95fr; background: var(--pierre); overflow: hidden;
}
.app-visual { display: flex; align-items: center; background: #0F0F1A; overflow: hidden; }
.app-visual img { width: 100%; height: auto; transition: transform .8s ease; -webkit-mask-image: linear-gradient(180deg, transparent, #000 14%, #000 86%, transparent); mask-image: linear-gradient(180deg, transparent, #000 14%, #000 86%, transparent); }
.app:hover .app-visual img { transform: scale(1.03); }
.app-body { padding: 48px 48px 44px; display: grid; gap: 22px; align-content: center; }
.app-id { display: flex; align-items: center; gap: 18px; }
.app-id img { width: 64px; height: 64px; border-radius: 16px; }
.app-id h3 { font-family: var(--display); font-weight: 700; font-size: 1.35rem; letter-spacing: .18em; text-transform: uppercase; }
.app-tag { color: var(--os-60); font-size: .95rem; }
.app-body > p { color: var(--os-60); }
.app-facts { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.app-facts li { font-size: .72rem; font-weight: 500; letter-spacing: .18em; text-transform: uppercase; padding: 7px 12px; border: 1px solid var(--os-15); color: var(--os-60); }
.app-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 20px; margin-top: 6px; }
.status { display: inline-flex; align-items: center; gap: 10px; font-size: .74rem; font-weight: 500; letter-spacing: .2em; text-transform: uppercase; color: var(--os-60); }
.status i { width: 7px; height: 7px; background: var(--lueur); transform: rotate(45deg); }

.next {
  margin-top: 24px; display: flex; align-items: center; gap: 28px;
  padding: 36px 44px; border: 1px dashed var(--os-15);
}
.next img { flex: none; width: 40px; height: 40px; opacity: .85; }
.next-title { font-size: clamp(.95rem, 2vw, 1.2rem); letter-spacing: .22em; }
.next-sub { color: var(--os-40); margin-top: 8px; font-size: .98rem; }

/* Approche */
.section-stone { background: linear-gradient(180deg, var(--nuit), #15171b 30%, #15171b 70%, var(--nuit)); }
.principles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; border-top: 1px solid var(--os-15); }
.principle { padding: 36px 28px 8px 0; }
.principle + .principle { padding-left: 28px; border-left: 1px solid var(--os-15); }
.principle-n { font-family: var(--display); font-weight: 700; font-size: .85rem; letter-spacing: .2em; color: var(--os-40); margin-bottom: 26px; }
.principle h3 { font-size: 1.2rem; font-weight: 600; margin-bottom: 12px; }
.principle p:last-child { color: var(--os-60); font-size: .98rem; }

/* Contact */
.contact { text-align: center; }
.contact-inner { display: grid; justify-items: center; }
.contact-emblem { width: 72px; margin-bottom: 40px; }
.contact .intro { margin-inline: auto; }
.mail {
  margin-top: 40px; font-family: var(--display); font-weight: 400; text-transform: uppercase;
  font-size: clamp(.95rem, 3.4vw, 2rem); letter-spacing: .12em; text-decoration: none;
  padding-bottom: 10px; border-bottom: 1px solid var(--os-40); transition: border-color .2s;
  overflow-wrap: anywhere;
}
.mail:hover { border-color: var(--lueur); }
.contact-note { margin-top: 28px; color: var(--os-40); font-size: .95rem; }
.contact-note a { color: var(--os-60); }

/* Footer */
.footer { border-top: 1px solid var(--os-08); padding: 48px 0 32px; }
.footer-inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 28px; }
.footer-logo { width: 184px; }
.footer nav { display: flex; flex-wrap: wrap; gap: 28px; }
.footer nav a { text-decoration: none; font-size: .74rem; font-weight: 500; letter-spacing: .2em; text-transform: uppercase; color: var(--os-60); }
.footer nav a:hover { color: var(--os); }
.footer-bottom { margin-top: 36px; padding-top: 22px; border-top: 1px solid var(--os-08); color: var(--os-40); font-size: .85rem; }

/* Pages de texte (mentions légales, 404) */
.page { padding: 96px 0 128px; }
.page .wrap { max-width: 760px; }
.page h2 { font-size: 1.15rem; font-weight: 600; margin: 44px 0 12px; }
.page p, .page li { color: var(--os-60); }
.page a { color: var(--os); }
.page-404 { min-height: calc(100svh - 76px - 180px); display: grid; place-items: center; text-align: center; }
.page-404 .wrap { display: grid; justify-items: center; gap: 8px; }
.page-404 img { width: 72px; margin-bottom: 28px; }
.page-404 .btn { margin-top: 32px; }

/* Apparition au scroll */
.js .reveal { opacity: 0; transform: translateY(22px); transition: opacity .8s ease, transform .8s ease; }
.js .reveal.is-in { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 1000px) {
  .hero-grid { grid-template-columns: 1fr; gap: 56px; text-align: center; }
  .hero-copy { display: grid; justify-items: center; }
  .hero-actions { justify-content: center; }
  .seal { width: min(300px, 80%); }
  .concept { grid-template-columns: 1fr; gap: 48px; }
  .concept-arrow { display: none; }
  .concept-art { max-width: 200px; }
  .app { grid-template-columns: 1fr; }
  .principles { grid-template-columns: 1fr 1fr; }
  .principle:nth-child(3) { padding-left: 0; border-left: 0; }
  .principle:nth-child(n+3) { border-top: 1px solid var(--os-15); margin-top: 28px; }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .wrap { width: min(1200px, 100% - 36px); }
  .nav-inner { height: 64px; }
  .nav-logo img { width: 164px; }
  .nav-links a:not(.nav-cta) { display: none; }
  .nav-links .nav-cta { padding: 8px 12px; letter-spacing: .16em; }
  .hero { min-height: auto; padding: 56px 0 100px; }
  .display { letter-spacing: .08em; }
  .title { letter-spacing: .14em; }
  .section { padding: 88px 0; }
  .head { margin-bottom: 44px; }
  .app-body { padding: 32px 24px; }
  .next { flex-direction: column; align-items: flex-start; padding: 28px 24px; }
  .principles { grid-template-columns: 1fr; }
  .principle, .principle + .principle { padding: 28px 0 0; border-left: 0; }
  .principle + .principle { border-top: 1px solid var(--os-15); margin-top: 28px; }
  .footer-logo { width: 164px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
  .js .reveal, .js .seal .tick, .js .seal .glass, .js .seal .grain { opacity: 1 !important; transform: none !important; }
}
