/* ============================================================
   ÉTERNE — Calibre Un
   Obsidian & champagne. Fraunces / Instrument Sans / IBM Plex Mono
   ============================================================ */

:root {
  --bg: #0b0a08;
  --bg-soft: #131109;
  --ink: #ece5d6;
  --ink-dim: #9b937f;
  --gold: #c9a962;
  --gold-bright: #e8cf96;
  --line: rgba(236, 229, 214, 0.14);
  --serif: "Fraunces", Georgia, serif;
  --sans: "Instrument Sans", "Helvetica Neue", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-luxe: cubic-bezier(0.65, 0, 0.13, 1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1rem;
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

::selection { background: var(--gold); color: var(--bg); }

.mono { font-family: var(--mono); font-size: 0.72rem; letter-spacing: 0.08em; text-transform: uppercase; }

em { font-style: italic; color: var(--gold-bright); }

a { color: inherit; text-decoration: none; }

/* ============ CANVAS ============ */
#scene {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  pointer-events: none;
}

/* ============ GRAIN ============ */
.grain {
  position: fixed;
  inset: -100%;
  z-index: 9;
  pointer-events: none;
  opacity: 0.06;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain-shift 0.9s steps(4) infinite;
}
@keyframes grain-shift {
  0% { transform: translate(0, 0); }
  25% { transform: translate(-2%, 3%); }
  50% { transform: translate(3%, -2%); }
  75% { transform: translate(-3%, -3%); }
  100% { transform: translate(2%, 2%); }
}

/* ============ CURSOR ============ */
.cursor, .cursor-ring { display: none; }
@media (pointer: fine) {
  .cursor {
    display: block;
    position: fixed;
    top: 0; left: 0;
    width: 6px; height: 6px;
    background: var(--gold);
    border-radius: 50%;
    z-index: 100;
    pointer-events: none;
    transform: translate(-50%, -50%);
  }
  .cursor-ring {
    display: block;
    position: fixed;
    top: 0; left: 0;
    width: 34px; height: 34px;
    border: 1px solid rgba(201, 169, 98, 0.5);
    border-radius: 50%;
    z-index: 100;
    pointer-events: none;
    transform: translate(-50%, -50%);
    transition: width 0.3s var(--ease-out), height 0.3s var(--ease-out),
                border-color 0.3s, background 0.3s;
  }
  .cursor-ring.is-hover {
    width: 64px; height: 64px;
    background: rgba(201, 169, 98, 0.08);
    border-color: var(--gold);
  }
  body { cursor: none; }
  a, button, input, [data-hover] { cursor: none; }
}

/* ============ PRELOADER ============ */
.preloader {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: var(--bg);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2rem;
  transition: opacity 0.9s var(--ease-luxe), visibility 0.9s;
}
.preloader.is-done { opacity: 0; visibility: hidden; }
.preloader__brand {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(2.4rem, 7vw, 4.5rem);
  letter-spacing: 0.42em;
  margin-right: -0.42em;
  color: var(--ink);
  display: flex;
}
.preloader__brand span {
  opacity: 0;
  transform: translateY(0.6em);
  animation: pre-letter 0.9s var(--ease-out) forwards;
}
.preloader__brand span:nth-child(1) { animation-delay: 0.05s; color: var(--gold); }
.preloader__brand span:nth-child(2) { animation-delay: 0.13s; }
.preloader__brand span:nth-child(3) { animation-delay: 0.21s; }
.preloader__brand span:nth-child(4) { animation-delay: 0.29s; }
.preloader__brand span:nth-child(5) { animation-delay: 0.37s; }
.preloader__brand span:nth-child(6) { animation-delay: 0.45s; }
@keyframes pre-letter {
  to { opacity: 1; transform: translateY(0); }
}
.preloader__bar {
  width: min(240px, 50vw);
  height: 1px;
  background: var(--line);
  overflow: hidden;
}
.preloader__bar-fill {
  height: 100%;
  width: 0%;
  background: var(--gold);
  transition: width 0.3s var(--ease-out);
}
.preloader__counter {
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  color: var(--ink-dim);
}

/* ============ NAV ============ */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.4rem clamp(1.2rem, 4vw, 3rem);
  opacity: 0;
  transform: translateY(-12px);
  transition: opacity 0.8s var(--ease-out) 0.2s, transform 0.8s var(--ease-out) 0.2s;
  mix-blend-mode: normal;
}
body.is-loaded .nav { opacity: 1; transform: none; }
.nav::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(11, 10, 8, 0.85), transparent);
  pointer-events: none;
  z-index: -1;
}
.nav__brand {
  font-family: var(--serif);
  font-weight: 400;
  letter-spacing: 0.35em;
  font-size: 1.05rem;
  color: var(--ink);
}
.nav__links {
  display: flex;
  gap: 2.2rem;
}
.nav__links a {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-dim);
  transition: color 0.3s;
  position: relative;
}
.nav__links a::after {
  content: "";
  position: absolute;
  left: 0; bottom: -5px;
  width: 100%; height: 1px;
  background: var(--gold);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.4s var(--ease-luxe);
}
.nav__links a:hover { color: var(--ink); }
.nav__links a:hover::after { transform: scaleX(1); transform-origin: left; }
.nav__right { display: flex; align-items: center; gap: 1.6rem; }
.nav__time { color: var(--ink-dim); font-variant-numeric: tabular-nums; }
.nav__cta {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--bg);
  background: var(--gold);
  padding: 0.55rem 1.1rem;
  border-radius: 2rem;
  transition: background 0.3s, transform 0.3s var(--ease-out);
}
.nav__cta:hover { background: var(--gold-bright); transform: translateY(-2px); }

/* ============ LAYOUT COMMON ============ */
main { position: relative; z-index: 2; }
section { position: relative; padding: clamp(4rem, 10vh, 8rem) clamp(1.2rem, 6vw, 6rem); }
.section-label {
  color: var(--gold);
  margin-bottom: 1.4rem;
  display: inline-block;
}

/* ============ REVEALS ============ */
[data-reveal] {
  opacity: 0;
  transform: translateY(36px);
  transition: opacity 1s var(--ease-out), transform 1s var(--ease-out);
}
[data-reveal].is-in { opacity: 1; transform: none; }
.line { display: block; overflow: hidden; }
[data-reveal-line] {
  display: inline-block;
  transform: translateY(110%);
  transition: transform 1.1s var(--ease-luxe);
}
.is-in [data-reveal-line], [data-reveal-line].is-in { transform: none; }

/* ============ HERO ============ */
.hero {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-top: 12vh;
}
.hero__eyebrow { color: var(--ink-dim); margin-bottom: 2rem; }
.hero__title {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(3.4rem, 11.5vw, 10.5rem);
  line-height: 0.98;
  letter-spacing: -0.02em;
  max-width: 12ch;
}
.hero__title em { font-weight: 400; }
.hero__meta {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 2rem;
  margin-top: 3rem;
  max-width: 46rem;
}
.hero__desc { color: var(--ink-dim); max-width: 34rem; font-size: 0.95rem; }
.hero__num { color: var(--gold); white-space: nowrap; }
.hero__scroll {
  position: absolute;
  bottom: 2.2rem;
  left: clamp(1.2rem, 6vw, 6rem);
  display: flex;
  align-items: center;
  gap: 0.8rem;
  color: var(--ink-dim);
  font-size: 0.65rem;
}
.hero__scroll-line {
  display: block;
  width: 3.4rem;
  height: 1px;
  background: var(--gold);
  transform-origin: left;
  animation: scroll-pulse 2.2s var(--ease-luxe) infinite;
}
@keyframes scroll-pulse {
  0% { transform: scaleX(0); opacity: 1; }
  60% { transform: scaleX(1); opacity: 1; }
  100% { transform: scaleX(1); opacity: 0; }
}
.hero__side {
  position: absolute;
  right: clamp(0.6rem, 2vw, 2rem);
  top: 50%;
  transform: rotate(90deg) translateX(-50%);
  transform-origin: right center;
  color: var(--ink-dim);
  opacity: 0.55;
  white-space: nowrap;
}

/* ============ MARQUEE ============ */
.marquee {
  position: relative;
  z-index: 2;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  overflow: hidden;
  padding: 0.85rem 0;
  background: rgba(11, 10, 8, 0.55);
  backdrop-filter: blur(6px);
}
.marquee__track {
  display: flex;
  white-space: nowrap;
  animation: marquee 30s linear infinite;
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold);
}
@keyframes marquee {
  to { transform: translateX(-50%); }
}

/* ============ MOVEMENT (sticky exploded view) ============ */
.movement { padding: 0; }
.movement__sticky {
  position: sticky;
  top: 0;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: clamp(5rem, 14vh, 9rem) clamp(1.2rem, 6vw, 6rem) clamp(2.5rem, 6vh, 4rem);
  pointer-events: none;
}
.movement__sticky > * { pointer-events: auto; }
.movement__spacer { height: 260svh; }
.movement__copy { max-width: 30rem; }
.movement__title {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(2.6rem, 6.5vw, 5.5rem);
  line-height: 1.02;
}
.movement__desc { color: var(--ink-dim); margin-top: 1.4rem; max-width: 26rem; font-size: 0.95rem; }
.movement__parts {
  list-style: none;
  align-self: flex-end;
  text-align: right;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  font-size: 0.68rem;
  color: var(--ink-dim);
}
.movement__parts li {
  opacity: 0.25;
  transition: opacity 0.5s, color 0.5s;
}
.movement__parts li i {
  font-style: normal;
  color: var(--gold);
  margin-right: 0.9em;
  opacity: 0.7;
}
.movement__parts li.is-active { opacity: 1; color: var(--ink); }

/* ============ CRAFT ============ */
.craft__title {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(2.6rem, 7vw, 6rem);
  line-height: 1.02;
  margin-bottom: clamp(2.5rem, 6vh, 4.5rem);
}
.craft__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}
.craft-card {
  background: var(--bg);
  padding: clamp(1.6rem, 3vw, 2.6rem);
  position: relative;
  overflow: hidden;
  transition: background 0.5s;
}
.craft-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 50%),
              rgba(201, 169, 98, 0.12), transparent 65%);
  opacity: 0;
  transition: opacity 0.5s;
}
.craft-card:hover::before { opacity: 1; }
.craft-card__num {
  color: var(--gold);
  font-size: 0.8rem;
  display: block;
  margin-bottom: 2.6rem;
}
.craft-card h3 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.45rem;
  margin-bottom: 0.8rem;
}
.craft-card p { color: var(--ink-dim); font-size: 0.9rem; }

/* ============ QUOTE ============ */
.quote {
  min-height: 72svh;
  display: grid;
  place-items: center;
  text-align: center;
}
.quote blockquote { max-width: 52rem; }
.quote p {
  font-family: var(--serif);
  font-weight: 300;
  font-style: italic;
  font-size: clamp(1.7rem, 4.2vw, 3.4rem);
  line-height: 1.25;
}
.quote cite {
  display: block;
  margin-top: 2.2rem;
  color: var(--gold);
  font-style: normal;
}

/* ============ SPECS ============ */
.specs__title {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(2.6rem, 7vw, 6rem);
  margin-bottom: clamp(2.5rem, 6vh, 4rem);
}
.specs__stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 1.5rem;
  margin-bottom: clamp(3rem, 7vh, 5rem);
}
.stat { border-top: 1px solid var(--gold); padding-top: 1.1rem; }
.stat__value {
  font-size: clamp(2rem, 4.5vw, 3.4rem);
  color: var(--ink);
  letter-spacing: 0;
  text-transform: none;
  display: block;
  font-variant-numeric: tabular-nums;
}
.stat__label { color: var(--ink-dim); font-size: 0.82rem; }
.specs__table { border-top: 1px solid var(--line); max-width: 56rem; }
.specs__row {
  display: grid;
  grid-template-columns: minmax(120px, 1fr) 2fr;
  gap: 1rem;
  padding: 1.05rem 0.4rem;
  border-bottom: 1px solid var(--line);
  transition: background 0.35s, padding-left 0.35s var(--ease-out);
}
.specs__row:hover { background: rgba(201, 169, 98, 0.05); padding-left: 1rem; }
.specs__row dt { color: var(--ink-dim); font-size: 0.88rem; }
.specs__row dd { color: var(--ink); text-align: right; font-size: 0.7rem; }

/* ============ ACQUIRE ============ */
.acquire {
  min-height: 90svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-align: center;
  align-items: center;
}
.acquire__title {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(3rem, 9vw, 8rem);
  line-height: 1;
}
.acquire__desc {
  color: var(--ink-dim);
  max-width: 30rem;
  margin: 1.8rem 0 2.6rem;
  font-size: 0.95rem;
}
.acquire__form {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.9rem;
}
.acquire__input {
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 3rem;
  color: var(--ink);
  padding: 0.95rem 1.5rem;
  min-width: min(20rem, 76vw);
  outline: none;
  transition: border-color 0.3s;
  text-transform: none;
  letter-spacing: 0.04em;
  font-size: 0.78rem;
}
.acquire__input:focus { border-color: var(--gold); }
.acquire__input::placeholder { color: var(--ink-dim); }
.btn-magnetic {
  position: relative;
  border: 1px solid var(--gold);
  background: transparent;
  border-radius: 3rem;
  padding: 0.95rem 2.2rem;
  overflow: hidden;
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
  transition: color 0.35s;
}
.btn-magnetic__fill {
  position: absolute;
  inset: 0;
  background: var(--gold);
  border-radius: inherit;
  transform: translateY(101%);
  transition: transform 0.45s var(--ease-luxe);
}
.btn-magnetic:hover .btn-magnetic__fill { transform: translateY(0); }
.btn-magnetic__label { position: relative; z-index: 1; }
.btn-magnetic:hover { color: var(--bg); }
.acquire__note { margin-top: 2.2rem; color: var(--ink-dim); }

/* ============ FOOTER ============ */
.footer {
  position: relative;
  z-index: 2;
  border-top: 1px solid var(--line);
  padding: clamp(2.5rem, 6vh, 4rem) clamp(1.2rem, 6vw, 6rem) 1.6rem;
  background: rgba(11, 10, 8, 0.7);
  backdrop-filter: blur(8px);
}
.footer__top {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 2.5rem;
  margin-bottom: 3rem;
}
.footer__brand {
  font-family: var(--serif);
  font-size: clamp(2.4rem, 6vw, 4.5rem);
  font-weight: 300;
  letter-spacing: 0.28em;
}
.footer__cols {
  display: flex;
  flex-wrap: wrap;
  gap: 3rem;
  color: var(--ink-dim);
  font-size: 0.68rem;
  line-height: 2;
}
.footer__cols span { color: var(--gold); }
.footer__cols a { transition: color 0.3s; }
.footer__cols a:hover { color: var(--ink); }
.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.8rem;
  padding-top: 1.4rem;
  border-top: 1px solid var(--line);
  color: var(--ink-dim);
  font-size: 0.62rem;
}
#footerTime { color: var(--gold); font-variant-numeric: tabular-nums; }

/* ============ RESPONSIVE ============ */
@media (max-width: 760px) {
  .hero { justify-content: flex-start; padding-top: 16vh; }
  .hero__meta { margin-top: 2rem; }
  .nav__links { display: none; }
  .nav__time { display: none; }
  .hero__side { display: none; }
  .hero__meta { flex-direction: column; align-items: flex-start; }
  .movement__parts { text-align: left; align-self: flex-start; }
  .specs__row dd { text-align: left; }
}

/* ============ REDUCED MOTION ============ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001s !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001s !important;
  }
  [data-reveal], [data-reveal-line] { opacity: 1; transform: none; }
}
