/* =========================================================
   VISIORO — Haute Joaillerie sur Mesure
   Design: Éditorial noir profond · Or liquide · Raffiné
   ========================================================= */

:root {
  /* Palette */
  --ink:       #0e0d0b;
  --ink2:      #161410;
  --surface:   #1a1815;
  --card:      #1f1d19;
  --card2:     #252219;

  --gold:      #c9a55a;
  --gold-lt:   #d9be87;
  --gold-dk:   #8a6e35;
  --gold-glow: rgba(201,165,90,.18);

  --text:      rgba(240,234,220,.92);
  --text-2:    rgba(240,234,220,.55);
  --text-3:    rgba(240,234,220,.32);

  --stroke:    rgba(201,165,90,.14);
  --stroke2:   rgba(255,255,255,.06);

  --radius:    20px;
  --radius-sm: 12px;

  --shadow-card: 0 60px 140px rgba(0,0,0,.70), 0 20px 50px rgba(0,0,0,.40);
  --shadow-btn:  0 20px 60px rgba(0,0,0,.50), 0 0 0 1px rgba(201,165,90,.25);
}

/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; }
html, body { height: 100%; }

body {
  font-family: 'Jost', system-ui, sans-serif;
  background: var(--ink);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* ── Background ── */
.bg-canvas {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.bg-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
}

.orb1 {
  width: 700px; height: 500px;
  top: -200px; left: -200px;
  background: radial-gradient(circle, rgba(180,130,60,.12) 0%, transparent 70%);
}

.orb2 {
  width: 600px; height: 600px;
  bottom: -250px; right: -150px;
  background: radial-gradient(circle, rgba(100,80,40,.10) 0%, transparent 70%);
}

.bg-grain {
  position: absolute;
  inset: 0;
  opacity: .035;
  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='.75' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='300' height='300' filter='url(%23n)'/%3E%3C/svg%3E");
  mix-blend-mode: overlay;
}

/* ── Layout ── */
.shell {
  position: relative;
  z-index: 1;
  min-height: 100%;
  display: grid;
  place-items: center;
  padding: 60px 20px;
}

.wrap {
  width: min(860px, 100%);
  display: grid;
  gap: 32px;
  justify-items: center;
}

/* ── Brand ── */
.brand {
  text-align: center;
  display: grid;
  gap: 16px;
  justify-items: center;
}

.brand-logo-wrap {
  position: relative;
  display: inline-block;
}

.logo {
  width: 180px;
  height: auto;
  position: relative;
  z-index: 1;
  filter: brightness(1.08) contrast(1.1);
  transition: transform .9s cubic-bezier(.2,.8,.2,1), filter .9s ease;
}

/* Invert logo to white for dark background */
.logo {
  filter: invert(1) brightness(1.4);
}

.brand:hover .logo {
  transform: translateY(-3px);
}

.logo-glow {
  position: absolute;
  inset: -30px;
  background: radial-gradient(circle, var(--gold-glow), transparent 65%);
  border-radius: 50%;
  z-index: 0;
  opacity: 0;
  transition: opacity .7s ease;
}

.brand:hover .logo-glow {
  opacity: 1;
}

/* Rule ornement */
.brand-rule {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 200px;
  margin-top: -4px;
}

.rule-line {
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold-dk), transparent);
  opacity: .7;
}

.rule-gem {
  font-size: 7px;
  color: var(--gold);
  opacity: .85;
  letter-spacing: 0;
}

.tagline {
  font-size: 12.5px;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--text-2);
  line-height: 2;
  font-weight: 300;
}

.tagline em {
  font-style: normal;
  font-weight: 500;
  color: var(--gold-lt);
  letter-spacing: .25em;
}

/* ── Card ── */
.card {
  width: 100%;
  background: linear-gradient(160deg, var(--card) 0%, var(--card2) 100%);
  border-radius: var(--radius);
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow-card);
  padding: 52px 48px;
  position: relative;
  overflow: hidden;
}

.card-glow {
  position: absolute;
  top: -120px; left: -80px;
  width: 500px; height: 350px;
  background: radial-gradient(ellipse, rgba(201,165,90,.07), transparent 65%);
  pointer-events: none;
}

/* Subtle top border highlight */
.card::before {
  content: "";
  position: absolute;
  top: 0; left: 10%; right: 10%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold-dk), var(--gold), var(--gold-dk), transparent);
  opacity: .6;
}

/* ── Card Head ── */
.kicker {
  font-size: 10px;
  letter-spacing: .35em;
  text-transform: uppercase;
  color: var(--gold);
  font-weight: 400;
  margin-bottom: 16px;
  opacity: .85;
}

h1 {
  font-family: 'Playfair Display', serif;
  font-weight: 400;
  font-size: 52px;
  line-height: 1.1;
  letter-spacing: -.5px;
  color: var(--text);
  margin-bottom: 14px;
}

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

.sub {
  font-size: 14px;
  color: var(--text-2);
  line-height: 1.8;
  font-weight: 300;
  max-width: 50ch;
}

/* ── Divider ── */
.card-head {
  padding-bottom: 36px;
  border-bottom: 1px solid var(--stroke2);
  margin-bottom: 36px;
}

/* ── Form ── */
.form { }

.grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 24px 20px;
}

.span-6  { grid-column: span 6; }
.span-12 { grid-column: span 12; }

.field {
  display: grid;
  gap: 10px;
}

.label {
  font-size: 10px;
  letter-spacing: .28em;
  text-transform: uppercase;
  color: var(--text-3);
  font-weight: 400;
}

.label-unit {
  color: var(--gold);
  opacity: .7;
}

input, textarea {
  width: 100%;
  padding: 15px 18px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--stroke2);
  background: rgba(255,255,255,.03);
  color: var(--text);
  font-family: 'Jost', sans-serif;
  font-size: 15px;
  font-weight: 300;
  outline: none;
  transition: border-color .25s ease, box-shadow .25s ease, background .25s ease, transform .2s ease;
}

textarea {
  min-height: 160px;
  resize: vertical;
}

input::placeholder, textarea::placeholder {
  color: var(--text-3);
  font-weight: 300;
}

input:focus, textarea:focus {
  border-color: rgba(201,165,90,.45);
  background: rgba(255,255,255,.05);
  box-shadow: 0 0 0 4px rgba(201,165,90,.08), 0 2px 12px rgba(0,0,0,.25);
  transform: translateY(-1px);
}

.field-note {
  font-size: 11.5px;
  color: var(--text-3);
  margin-top: -4px;
  font-weight: 300;
}

/* Honeypot */
.hp {
  position: absolute;
  left: -9999px;
  width: 1px; height: 1px;
  opacity: 0;
  pointer-events: none;
}

/* ── Actions ── */
.actions {
  display: flex;
  align-items: center;
  gap: 24px;
  margin-top: 32px;
  flex-wrap: wrap;
}

/* ── Button ── */
.btn {
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  padding: 0;
  background: none;
  border: none;
  cursor: pointer;
  text-decoration: none;
  user-select: none;
  transition: transform .3s cubic-bezier(.2,.8,.2,1);
}

.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0) scale(.98); }

.btn:disabled { opacity: .5; cursor: not-allowed; transform: none; }

.btn-inner {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 15px 32px;
  border-radius: 999px;
  border: 1px solid rgba(201,165,90,.45);
  background: linear-gradient(135deg, rgba(201,165,90,.20), rgba(201,165,90,.06));
  box-shadow: var(--shadow-btn);
  font-family: 'Jost', sans-serif;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .28em;
  text-transform: uppercase;
  color: var(--gold-lt);
  transition: background .3s ease, border-color .3s ease, box-shadow .3s ease;
}

.btn:hover .btn-inner {
  background: linear-gradient(135deg, rgba(201,165,90,.30), rgba(201,165,90,.12));
  border-color: rgba(201,165,90,.65);
  box-shadow: 0 24px 70px rgba(0,0,0,.55), 0 0 0 1px rgba(201,165,90,.35), 0 0 40px rgba(201,165,90,.12);
}

.btn-icon {
  font-size: 8px;
  opacity: .75;
}

.btn-shine {
  position: absolute;
  top: 0; left: -70%;
  width: 50%;
  height: 100%;
  background: linear-gradient(120deg, transparent, rgba(255,255,255,.15), transparent);
  transform: skewX(-22deg);
  pointer-events: none;
}

.btn:hover .btn-shine {
  animation: shine .9s ease forwards;
}

@keyframes shine {
  from { left: -70%; }
  to   { left: 130%; }
}

.hint {
  font-size: 12px;
  color: var(--text-3);
  line-height: 1.8;
  font-weight: 300;
}

/* ── Alert ── */
.alert {
  display: none;
  margin-top: 16px;
  padding: 14px 18px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--stroke2);
  background: rgba(255,255,255,.04);
  color: var(--text-2);
  font-size: 13px;
  line-height: 1.6;
}
.alert.show { display: block; }

/* ── Footer ── */
.footer {
  text-align: center;
  font-size: 12px;
  color: var(--text-3);
  letter-spacing: .12em;
  font-weight: 300;
}

.link {
  color: var(--text-2);
  text-decoration: none;
  transition: color .2s ease;
}
.link:hover { color: var(--gold-lt); }

.sep {
  margin: 0 10px;
  font-size: 7px;
  color: var(--gold-dk);
  opacity: .6;
  vertical-align: middle;
}

/* ── Success page ── */
.card.success {
  text-align: center;
}

.success-emblem {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 60px; height: 60px;
  border-radius: 50%;
  border: 1px solid var(--stroke);
  margin-bottom: 24px;
  background: rgba(201,165,90,.07);
  font-size: 14px;
  color: var(--gold);
}

/* ── Overlay ── */
.overlay {
  position: fixed;
  inset: 0;
  background: rgba(14,13,11,.75);
  backdrop-filter: blur(14px);
  display: grid;
  place-items: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity .4s ease;
  z-index: 1000;
}

.overlay.show {
  opacity: 1;
  pointer-events: auto;
}

.loader-ring {
  width: 62px;
  height: 62px;
}

.loader-ring svg {
  width: 100%;
  height: 100%;
}

.ring-spin {
  transform-origin: center;
  animation: spinRing 3s linear infinite;
}

@keyframes spinRing {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

/* ── Entrance animations ── */
@media (prefers-reduced-motion: no-preference) {
  .brand {
    animation: fadeUp 1s cubic-bezier(.2,.8,.2,1) both;
  }

  .card {
    animation: fadeUp 1s cubic-bezier(.2,.8,.2,1) .12s both;
  }

  .kicker   { animation: fadeUp .8s ease .22s both; }
  h1        { animation: fadeUp .8s ease .30s both; }
  .sub      { animation: fadeUp .8s ease .38s both; }

  .field:nth-child(1) { animation: fadeUp .7s ease .42s both; }
  .field:nth-child(2) { animation: fadeUp .7s ease .48s both; }
  .field:nth-child(3) { animation: fadeUp .7s ease .54s both; }
  .field:nth-child(4) { animation: fadeUp .7s ease .60s both; }

  .actions { animation: fadeUp .7s ease .68s both; }
  .footer  { animation: fadeUp .7s ease .75s both; }
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── Responsive ── */
@media (max-width: 680px) {
  .span-6 { grid-column: span 12; }

  h1 { font-size: 38px; }

  .card { padding: 32px 24px; }

  .logo { width: 150px; }

  .shell { padding: 40px 16px; }

  .actions { flex-direction: column; align-items: flex-start; gap: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    transition: none !important;
    animation: none !important;
  }
}
