/* MontCristo — Configurador de Alianças */
:root {
  --bg: #181512;
  --bg-1: #1d1b17;
  --surface: #222019;
  --surface-2: #2a271f;
  --surface-3: #322d24;
  --line: #3a332a;
  --line-2: #4a3f30;
  --gold: #c9a961;
  --gold-soft: #b9985a;
  --gold-deep: #5e4f2a;
  --cream: #e8dcc0;
  --ivory: #f5ecd6;
  --ink: #efe6cf;
  --ink-2: #c8bda3;
  --ink-3: #8a8071;
  --ink-4: #5a5347;
  --danger: #c46a4a;

  --serif: 'Cormorant Garamond', 'Times New Roman', serif;
  --sans: 'Inter', system-ui, -apple-system, 'Helvetica Neue', sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, 'SF Mono', monospace;

  --radius-s: 4px;
  --radius-m: 8px;
  --radius-l: 14px;

  --t-fast: 180ms cubic-bezier(.2,.7,.2,1);
  --t-med: 360ms cubic-bezier(.2,.7,.2,1);
  --t-slow: 720ms cubic-bezier(.2,.7,.2,1);
}

* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; background: var(--bg); color: var(--ink); font-family: var(--sans); -webkit-font-smoothing: antialiased; }
body { overflow: hidden; }

a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }

/* ---------- TOP NAV ---------- */
.nav {
  position: fixed; inset: 0 0 auto 0; height: 64px; z-index: 50;
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  padding: 0 28px;
  background: linear-gradient(to bottom, rgba(10,9,8,0.85), rgba(10,9,8,0.0));
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.nav__left, .nav__right { display: flex; gap: 28px; align-items: center; }
.nav__right { justify-content: flex-end; }
.nav__link {
  font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--ink-2); transition: color var(--t-fast);
}
.nav__link:hover { color: var(--ivory); }
.nav__link--active { color: var(--gold); }

.brand {
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  user-select: none;
}
.brand__mark {
  font-family: var(--serif); font-weight: 400; font-size: 22px;
  letter-spacing: 0.32em; color: var(--ivory);
  display: flex; align-items: center; gap: 10px;
}
.brand__mark::before, .brand__mark::after {
  content: ''; width: 18px; height: 1px; background: var(--gold-deep);
}
.brand__tag {
  font-size: 8px; letter-spacing: 0.42em; text-transform: uppercase; color: var(--ink-3);
}

.nav__icon-btn {
  width: 32px; height: 32px; display: grid; place-items: center;
  border: 1px solid var(--line); border-radius: 999px;
  color: var(--ink-2); transition: all var(--t-fast);
}
.nav__icon-btn:hover { color: var(--gold); border-color: var(--gold-deep); }

/* ---------- APP SHELL ---------- */
.app {
  position: relative;
  display: grid; grid-template-columns: 1fr 440px; height: 100vh;
}

/* ---------- CANVAS (LEFT) ---------- */
.stage {
  position: relative; overflow: hidden;
  background:
    radial-gradient(ellipse 80% 50% at 50% 45%, rgba(201,169,97,0.12), transparent 65%),
    linear-gradient(180deg, #c8c0b6 0%, #bfb8ae 50%, #b5aea4 100%);
}
.stage::before {
  /* film grain */
  content: ''; position: absolute; inset: 0; pointer-events: none; z-index: 3;
  opacity: 0.06; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)' opacity='0.7'/></svg>");
}
.stage::after {
  /* subtle vignette */
  content: ''; position: absolute; inset: 0; pointer-events: none; z-index: 2;
  background: radial-gradient(ellipse 90% 70% at 50% 50%, transparent 50%, rgba(0,0,0,0.55) 100%);
}
.stage__canvas { position: absolute; inset: 0; z-index: 1; width: 100%; height: 100%; display: block; }

/* particle layer */
.particles { position: absolute; inset: 0; pointer-events: none; z-index: 4; opacity: 0.5; }
.particles span {
  position: absolute; width: 2px; height: 2px; border-radius: 999px;
  background: var(--gold);
  filter: blur(0.5px); opacity: 0;
  animation: drift linear infinite;
}
@keyframes drift {
  0% { transform: translateY(20px); opacity: 0; }
  10% { opacity: 0.6; }
  90% { opacity: 0.4; }
  100% { transform: translateY(-120vh); opacity: 0; }
}

/* stage overlays — labels & meta */
.stage__overlay { position: absolute; z-index: 5; pointer-events: none; color: var(--ink-3); font-size: 10px; letter-spacing: 0.28em; text-transform: uppercase; }
.stage__overlay--tl { top: 96px; left: 32px; }
.stage__overlay--bl { bottom: 28px; left: 32px; display: flex; gap: 18px; align-items: center; }
.stage__overlay--br { bottom: 28px; right: 32px; display: flex; gap: 18px; align-items: center; pointer-events: auto; }
.crosshair {
  width: 14px; height: 14px; position: relative; display: inline-block;
}
.crosshair::before, .crosshair::after {
  content: ''; position: absolute; background: var(--gold-deep);
}
.crosshair::before { left: 6px; top: 0; bottom: 0; width: 1px; }
.crosshair::after { top: 6px; left: 0; right: 0; height: 1px; }

.stage__rot-hint {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, calc(50% + 230px));
  z-index: 5; color: var(--ink-4); font-size: 10px; letter-spacing: 0.28em; text-transform: uppercase;
  pointer-events: none;
  animation: pulse 3s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 0; }
  20%, 80% { opacity: 0.7; }
}

.stage__view-controls {
  position: absolute; right: 32px; top: 50%; transform: translateY(-50%);
  z-index: 5; display: flex; flex-direction: column; gap: 6px;
}
.stage__view-controls button {
  width: 36px; height: 36px; display: grid; place-items: center;
  border: 1px solid var(--line); border-radius: 999px; color: var(--ink-2);
  background: rgba(15,13,11,0.6); backdrop-filter: blur(6px);
  transition: all var(--t-fast);
}
.stage__view-controls button:hover { color: var(--gold); border-color: var(--gold-deep); }

/* badge bottom-right */
.atelier-badge {
  display: flex; flex-direction: column; align-items: flex-end; gap: 4px;
}
.atelier-badge__line { font-size: 9px; letter-spacing: 0.32em; color: var(--ink-4); }
.atelier-badge__name { font-family: var(--serif); font-style: italic; font-size: 14px; color: var(--cream); letter-spacing: 0.04em; }

/* ceremony CTA */
.ceremony-cta {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 10px 18px;
  border: 1px solid var(--gold-deep); border-radius: 999px;
  font-size: 10px; letter-spacing: 0.28em; text-transform: uppercase;
  color: var(--cream); background: rgba(20,17,13,0.5); backdrop-filter: blur(6px);
  transition: all var(--t-med);
}
.ceremony-cta:hover { border-color: var(--gold); color: var(--gold); transform: translateY(-1px); }
.ceremony-cta__dot { width: 6px; height: 6px; border-radius: 999px; background: var(--gold); box-shadow: 0 0 12px var(--gold); }

/* ---------- CONTROL RAIL (RIGHT) ---------- */
.rail {
  position: relative;
  background: linear-gradient(180deg, #0e0c0a 0%, #0a0908 100%);
  border-left: 1px solid var(--line);
  display: flex; flex-direction: column;
  overflow: hidden;
}
.rail__head {
  padding: 90px 32px 18px;
  border-bottom: 1px solid var(--line);
}
.rail__eyebrow {
  font-size: 10px; letter-spacing: 0.32em; text-transform: uppercase; color: var(--gold);
  display: flex; align-items: center; gap: 10px;
}
.rail__eyebrow::before {
  content: ''; width: 24px; height: 1px; background: var(--gold-deep);
}
.rail__title {
  font-family: var(--serif); font-weight: 400; font-size: 32px; line-height: 1.05; letter-spacing: 0.005em;
  margin: 14px 0 4px; color: var(--ivory);
}
.rail__title em { font-style: italic; color: var(--gold); }
.rail__sub {
  font-size: 12px; color: var(--ink-3); line-height: 1.5;
}
.rail__sub-num { font-family: var(--mono); color: var(--ink-2); font-size: 10px; letter-spacing: 0.18em; }

.rail__scroll {
  flex: 1; overflow-y: auto;
  scrollbar-width: thin; scrollbar-color: var(--line-2) transparent;
}
.rail__scroll::-webkit-scrollbar { width: 6px; }
.rail__scroll::-webkit-scrollbar-thumb { background: var(--line-2); border-radius: 999px; }

.section {
  padding: 24px 32px;
  border-bottom: 1px solid var(--line);
}
.section__head {
  display: flex; align-items: baseline; justify-content: space-between;
  margin-bottom: 16px;
}
.section__title {
  font-size: 10px; letter-spacing: 0.32em; text-transform: uppercase; color: var(--ink-2);
}
.section__step {
  font-family: var(--mono); font-size: 9px; letter-spacing: 0.18em; color: var(--ink-4);
}

/* swatches */
.swatch-row { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; }
.swatch {
  position: relative; padding-top: 100%; border-radius: var(--radius-m);
  border: 1px solid var(--line); cursor: pointer; overflow: hidden;
  transition: all var(--t-fast);
}
.swatch__inner {
  position: absolute; inset: 6px; border-radius: 6px;
  background: radial-gradient(circle at 30% 30%, var(--c1, #fcd28d), var(--c2, #8a6b32) 80%);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.18), inset 0 -10px 16px rgba(0,0,0,0.4);
}
.swatch__label {
  position: absolute; left: 0; right: 0; bottom: -22px; text-align: center;
  font-size: 9px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--ink-4);
  transition: color var(--t-fast);
}
.swatch:hover { border-color: var(--gold-deep); }
.swatch:hover .swatch__label { color: var(--ink-2); }
.swatch.is-active { border-color: var(--gold); }
.swatch.is-active .swatch__label { color: var(--gold); }
.swatch.is-active::after {
  content: ''; position: absolute; inset: -1px; border-radius: var(--radius-m);
  box-shadow: 0 0 0 1px var(--gold), 0 0 22px rgba(201,169,97,0.25);
  pointer-events: none;
}
.swatch-grid { margin-bottom: 28px; }

/* finish — list */
.finish-list { display: grid; gap: 6px; }
.finish-item {
  display: grid; grid-template-columns: 36px 1fr auto; align-items: center; gap: 14px;
  padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--radius-m);
  cursor: pointer; transition: all var(--t-fast);
}
.finish-item:hover { border-color: var(--line-2); background: var(--surface); }
.finish-item.is-active { border-color: var(--gold-deep); background: var(--surface); }
.finish-item.is-active .finish-item__name { color: var(--gold); }
.finish-preview {
  width: 36px; height: 36px; border-radius: 999px;
  background: radial-gradient(circle at 35% 30%, #fcd28d, #8a6b32 70%);
}
.finish-preview--polido { background: radial-gradient(circle at 30% 25%, #fff1c8 0%, #d2a753 60%, #6e5226 100%); }
.finish-preview--fosco { background: radial-gradient(circle at 50% 50%, #b48b46, #7a5a28); filter: contrast(0.85); }
.finish-preview--escovado {
  background:
    repeating-linear-gradient(90deg, #d4ad5b 0px, #d4ad5b 1px, #a9883f 1px, #a9883f 2px),
    radial-gradient(circle at 50% 30%, #e7c172, #836528);
}
.finish-preview--diamantado {
  background: conic-gradient(from 0deg, #fff1c8, #c9a961, #6e5226, #c9a961, #fff1c8);
}
.finish-item__name { font-size: 12px; color: var(--ink); letter-spacing: 0.04em; }
.finish-item__meta { font-family: var(--mono); font-size: 9px; color: var(--ink-4); letter-spacing: 0.18em; }

/* sliders */
.slider-block { margin-bottom: 18px; }
.slider-head {
  display: flex; justify-content: space-between; align-items: baseline;
  margin-bottom: 8px;
}
.slider-label { font-size: 11px; color: var(--ink-2); letter-spacing: 0.04em; }
.slider-value {
  font-family: var(--mono); font-size: 11px; color: var(--gold); letter-spacing: 0.06em;
}
input[type="range"] {
  -webkit-appearance: none; appearance: none;
  width: 100%; height: 24px; background: transparent; cursor: pointer;
}
input[type="range"]::-webkit-slider-runnable-track {
  height: 1px; background: var(--line-2);
}
input[type="range"]::-moz-range-track { height: 1px; background: var(--line-2); }
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none; width: 14px; height: 14px;
  background: var(--gold); border-radius: 999px;
  margin-top: -7px;
  box-shadow: 0 0 0 4px rgba(201,169,97,0.12), 0 0 14px rgba(201,169,97,0.35);
  transition: transform var(--t-fast);
}
input[type="range"]::-webkit-slider-thumb:hover { transform: scale(1.15); }
input[type="range"]::-moz-range-thumb {
  width: 14px; height: 14px; background: var(--gold); border: 0; border-radius: 999px;
  box-shadow: 0 0 0 4px rgba(201,169,97,0.12);
}

/* segment buttons */
.segments { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.segments--3 { grid-template-columns: repeat(3, 1fr); }
.segments--4 { grid-template-columns: repeat(4, 1fr); }
.segments--sub { grid-template-columns: repeat(3, 1fr); margin-top: 6px; }

/* model description card */
.model-desc {
  display: flex; gap: 10px; align-items: flex-start;
  padding: 10px 12px; margin: 12px 0 16px;
  border: 1px solid var(--line); border-radius: var(--radius-m);
  background: var(--surface);
  font-size: 11px; color: var(--ink-2); line-height: 1.6;
}
.model-desc__icon {
  flex-shrink: 0; font-size: 16px; opacity: 0.55; margin-top: 1px;
}

/* friso carve controls — appear when a friso count is selected */
.friso-controls {
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px dashed var(--line);
}
.friso-controls[hidden] { display: none; }
.seg {
  padding: 10px 6px; border: 1px solid var(--line); border-radius: var(--radius-s);
  font-size: 10px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-3);
  transition: all var(--t-fast);
}
.seg:hover { border-color: var(--line-2); color: var(--ink-2); }
.seg.is-active { border-color: var(--gold); color: var(--gold); background: rgba(201,169,97,0.06); }

/* stones row */
.stones-row { display: flex; gap: 8px; }
.stone-btn {
  flex: 1; padding: 14px 6px 10px; border: 1px solid var(--line); border-radius: var(--radius-m);
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  transition: all var(--t-fast);
}
.stone-btn:hover { border-color: var(--line-2); }
.stone-btn.is-active { border-color: var(--gold-deep); }
.stone-btn.is-active .stone-btn__label { color: var(--gold); }
.stone-pip {
  width: 12px; height: 12px; transform: rotate(45deg);
  background: linear-gradient(135deg, #ffffff 0%, #cfd9e6 50%, #8aa0b8 100%);
  box-shadow: 0 0 6px rgba(255,255,255,0.35);
}
.stone-pip--none {
  background: transparent; border: 1px dashed var(--line-2); box-shadow: none;
}
.stone-btn__label {
  font-family: var(--mono); font-size: 9px; letter-spacing: 0.18em; color: var(--ink-4);
}

/* engraving */
.engrave-block { display: grid; gap: 10px; }
.engrave-field {
  display: flex; align-items: center;
  border: 1px solid var(--line); border-radius: var(--radius-m);
  padding: 0 14px; height: 44px;
  background: var(--surface);
}
.engrave-field:focus-within { border-color: var(--gold-deep); }
.engrave-field__icon { color: var(--ink-4); margin-right: 12px; font-size: 12px; font-family: var(--serif); font-style: italic; }
.engrave-field input {
  flex: 1; background: transparent; border: 0; outline: 0;
  font-family: var(--serif); font-style: italic; font-size: 16px; color: var(--cream);
  letter-spacing: 0.03em;
}
.engrave-field input::placeholder { color: var(--ink-4); font-style: italic; }
.engrave-field__count {
  font-family: var(--mono); font-size: 9px; color: var(--ink-4); letter-spacing: 0.18em;
}
.engrave-preview {
  margin-top: 6px;
  padding: 14px 16px;
  border: 1px dashed var(--line-2); border-radius: var(--radius-m);
  display: flex; align-items: center; gap: 14px;
  background: linear-gradient(180deg, rgba(20,17,13,0.6), rgba(10,9,8,0.6));
}
.engrave-preview__ring {
  width: 64px; height: 22px; border-radius: 999px;
  border: 1px solid var(--gold-deep);
  display: grid; place-items: center;
  background: linear-gradient(180deg, rgba(201,169,97,0.06), transparent);
}
.engrave-preview__text {
  flex: 1; font-family: var(--serif); font-style: italic; color: var(--cream); font-size: 14px;
  letter-spacing: 0.04em;
  display: flex; gap: 12px; align-items: baseline;
}
.engrave-preview__text small {
  font-family: var(--mono); font-style: normal; font-size: 9px; color: var(--ink-4); letter-spacing: 0.18em;
}

/* ---------- FOOTER (price) ---------- */
.rail__foot {
  border-top: 1px solid var(--line);
  padding: 22px 32px 26px;
  background: linear-gradient(180deg, transparent, rgba(0,0,0,0.4));
}
.price-row {
  display: flex; justify-content: space-between; align-items: baseline;
  margin-bottom: 14px;
}
.price-row__label {
  font-size: 10px; letter-spacing: 0.28em; text-transform: uppercase; color: var(--ink-3);
}
.price-row__value {
  font-family: var(--serif); font-size: 30px; color: var(--ivory);
  letter-spacing: 0.01em;
  display: flex; align-items: baseline; gap: 6px;
}
.price-row__value sup { font-family: var(--mono); font-size: 10px; color: var(--ink-3); letter-spacing: 0.18em; }
.price-row__delta {
  font-family: var(--mono); font-size: 10px; color: var(--gold); letter-spacing: 0.12em;
  opacity: 0; transition: opacity var(--t-med);
}
.price-row__delta.is-visible { opacity: 1; }

.btn-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.btn-row--single { grid-template-columns: 1fr; }
.btn {
  height: 52px; border-radius: var(--radius-s);
  font-size: 10px; letter-spacing: 0.28em; text-transform: uppercase;
  display: flex; align-items: center; justify-content: center; gap: 10px;
  transition: all var(--t-med);
}
.btn--primary {
  background: linear-gradient(180deg, #d4b06a, #a78641);
  color: #1a1308;
  box-shadow: 0 6px 20px rgba(201,169,97,0.18), inset 0 1px 0 rgba(255,255,255,0.3);
}
.btn--primary:hover {
  background: linear-gradient(180deg, #e2c07a, #b89146);
  box-shadow: 0 10px 28px rgba(201,169,97,0.32), inset 0 1px 0 rgba(255,255,255,0.4);
  transform: translateY(-1px);
}
.btn--ghost {
  border: 1px solid var(--gold-deep); color: var(--cream);
}
.btn--ghost:hover { border-color: var(--gold); color: var(--gold); }

.foot-meta {
  margin-top: 14px; display: flex; justify-content: space-between; gap: 18px;
  font-size: 9px; letter-spacing: 0.22em; text-transform: uppercase; color: var(--ink-4);
}
.foot-meta__item { display: flex; align-items: center; gap: 8px; }
.foot-meta__dot { width: 4px; height: 4px; border-radius: 999px; background: var(--gold); }

/* ---------- TWEAKS PANEL ---------- */
.tweaks {
  position: fixed; right: 24px; bottom: 24px; z-index: 90;
  width: 280px;
  background: rgba(14,12,10,0.92);
  backdrop-filter: blur(12px);
  border: 1px solid var(--line-2);
  border-radius: var(--radius-l);
  box-shadow: 0 24px 60px rgba(0,0,0,0.5), 0 0 0 1px rgba(201,169,97,0.06);
  font-family: var(--sans);
  display: none;
  overflow: hidden;
}
.tweaks.is-open { display: block; }
.tweaks__head {
  display: flex; justify-content: space-between; align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
}
.tweaks__title { font-size: 10px; letter-spacing: 0.28em; text-transform: uppercase; color: var(--gold); }
.tweaks__close { color: var(--ink-3); font-size: 18px; line-height: 1; padding: 4px 8px; }
.tweaks__close:hover { color: var(--ivory); }
.tweaks__body { padding: 16px; }
.tweak-group { margin-bottom: 14px; }
.tweak-group:last-child { margin-bottom: 0; }
.tweak-group__label {
  font-size: 9px; letter-spacing: 0.22em; text-transform: uppercase; color: var(--ink-3);
  margin-bottom: 8px;
}
.tweak-options { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.tweak-opt {
  padding: 10px 4px; border: 1px solid var(--line); border-radius: 6px;
  font-size: 9px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-3);
}
.tweak-opt:hover { border-color: var(--line-2); color: var(--ink-2); }
.tweak-opt.is-active { border-color: var(--gold); color: var(--gold); background: rgba(201,169,97,0.06); }

/* ---------- CEREMONY OVERLAY ---------- */
.ceremony {
  position: fixed; inset: 0; z-index: 100;
  background: #050403;
  opacity: 0; pointer-events: none; transition: opacity 600ms ease;
}
.ceremony.is-open { opacity: 1; pointer-events: auto; }
.ceremony__canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.ceremony__grain {
  position: absolute; inset: 0; pointer-events: none;
  opacity: 0.18; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='200' height='200'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='1.2' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)' opacity='0.85'/></svg>");
}
.ceremony__vignette {
  position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(ellipse 70% 55% at 50% 50%, transparent 30%, rgba(0,0,0,0.85) 100%);
}
.ceremony__bars {
  position: absolute; left: 0; right: 0; pointer-events: none;
  background: #050403; height: 64px;
  transition: transform 700ms cubic-bezier(.2,.7,.2,1);
}
.ceremony__bars--top { top: 0; transform: translateY(-100%); }
.ceremony__bars--bot { bottom: 0; transform: translateY(100%); }
.ceremony.is-open .ceremony__bars--top { transform: translateY(0); }
.ceremony.is-open .ceremony__bars--bot { transform: translateY(0); }

.ceremony__caption {
  position: absolute; left: 0; right: 0; bottom: 130px;
  text-align: center; color: var(--ivory);
  font-family: var(--serif); font-style: italic; font-size: 56px;
  letter-spacing: 0.04em; line-height: 1.1;
  opacity: 0; transform: translateY(20px); transition: all 1.2s ease;
}
.ceremony__caption.is-visible { opacity: 1; transform: translateY(0); }
.ceremony__caption small {
  display: block; font-family: var(--sans); font-style: normal;
  font-size: 10px; letter-spacing: 0.42em; text-transform: uppercase;
  color: var(--gold); margin-top: 16px;
}

.ceremony__timecode {
  position: absolute; top: 20px; left: 28px;
  font-family: var(--mono); font-size: 10px; letter-spacing: 0.18em; color: var(--gold);
  display: flex; gap: 14px; align-items: center;
}
.ceremony__rec {
  width: 8px; height: 8px; border-radius: 999px; background: #c46a4a;
  animation: blink 1.2s ease-in-out infinite;
}
@keyframes blink { 50% { opacity: 0.25; } }

.ceremony__brand {
  position: absolute; top: 20px; right: 28px;
  font-family: var(--serif); font-size: 14px; color: var(--cream); letter-spacing: 0.32em;
}

.ceremony__close {
  position: absolute; bottom: 24px; right: 28px;
  padding: 10px 18px; border: 1px solid var(--gold-deep); border-radius: 999px;
  font-size: 10px; letter-spacing: 0.28em; text-transform: uppercase; color: var(--cream);
  background: rgba(20,17,13,0.6); backdrop-filter: blur(6px);
}
.ceremony__close:hover { border-color: var(--gold); color: var(--gold); }

.ceremony__progress {
  position: absolute; bottom: 80px; left: 50%; transform: translateX(-50%);
  width: 220px; height: 1px; background: rgba(201,169,97,0.2);
}
.ceremony__progress-fill { height: 100%; background: var(--gold); width: 0%; transition: width 200ms linear; }

/* atelier mode — fundo claro */
body[data-mood="atelier"] .stage {
  background: linear-gradient(180deg, #f5f3ef 0%, #e8e4de 60%, #d8d2ca 100%);
}
body[data-mood="atelier"] .stage::before { opacity: 0; }
body[data-mood="atelier"] .stage::after { background: none; }
body[data-mood="atelier"] .stage__rot-hint { color: #6a6055; }
body[data-mood="atelier"] .rail__head { background: var(--surface); }
body[data-mood="atelier"] .stage__overlay--tl { color: #8a7d6e; }
body[data-mood="atelier"] .stage__overlay--bl { color: #8a7d6e; }
body[data-mood="atelier"] .stage__overlay--bl::after {
  content: 'ATELIER MODE — TECH DRAFT'; font-family: var(--mono); color: var(--gold-soft); margin-left: 18px;
}
body[data-mood="atelier"] .stage__measurements { display: block; }
.stage__measurements { display: none; position: absolute; inset: 0; z-index: 4; pointer-events: none; font-family: var(--mono); font-size: 9px; color: var(--gold-soft); letter-spacing: 0.12em; }

body[data-mood="editorial"] .stage { background: linear-gradient(180deg, #14110e 0%, #0c0a09 50%, #080706 100%); }
body[data-mood="editorial"] .stage::before { opacity: 0.02; }
body[data-mood="editorial"] .particles { opacity: 0.15; }
body[data-mood="editorial"] .rail__title { font-size: 38px; }

/* ---------- toast on save ---------- */
.toast {
  position: fixed; left: 50%; bottom: 36px; transform: translate(-50%, 40px);
  background: rgba(20,17,13,0.95); border: 1px solid var(--gold-deep); border-radius: 999px;
  padding: 12px 22px;
  font-size: 10px; letter-spacing: 0.28em; text-transform: uppercase; color: var(--cream);
  opacity: 0; pointer-events: none; transition: all var(--t-med); z-index: 95;
}
.toast.is-open { opacity: 1; transform: translate(-50%, 0); }
.toast .toast__dot { display: inline-block; width: 6px; height: 6px; border-radius: 999px; background: var(--gold); margin-right: 10px; vertical-align: middle; }

/* ── default: tab nav hidden (desktop shows all sections) ── */
.rail__tabs { display: none; }
.rail__scroll .section { display: block; }

/* small screens fallback */
@media (max-width: 1100px) {
  .app { grid-template-columns: 1fr 380px; }
}

/* ── MOBILE ────────────────────────────────────────────────── */
@media (max-width: 768px) {
  body { overflow: hidden; }

  .app {
    grid-template-columns: 1fr;
    grid-template-rows: 40vh 1fr;
    height: 100dvh;
  }

  /* 3D stage */
  .stage { height: 40vh; }

  /* hide clutter */
  .stage__overlay--tl,
  .stage__measurements,
  .stage__rot-hint { display: none; }

  /* bottom-left REF label */
  .stage__overlay--bl { font-size: 8px; gap: 8px; bottom: 10px; left: 12px; }
  .stage__overlay--br { bottom: 10px; right: 10px; }

  /* ceremony CTA */
  .ceremony-cta { padding: 7px 12px; font-size: 9px; gap: 7px; }
  .ceremony-cta__dot { width: 5px; height: 5px; }

  /* view controls */
  .stage__view-controls { top: 10px; right: 8px; transform: none; gap: 4px; }
  .stage__view-controls button { width: 30px; height: 30px; }

  /* ── RAIL ── */
  .rail {
    border-left: 0;
    border-top: 1px solid var(--line);
    height: 60vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
  }
  .rail__head { display: none; }

  /* ── TABS ── */
  .rail__tabs {
    display: flex;
    overflow-x: auto;
    scrollbar-width: none;
    flex-shrink: 0;
    border-bottom: 1px solid var(--line);
    background: var(--surface);
  }
  .rail__tabs::-webkit-scrollbar { display: none; }

  .rail__tab {
    flex: 0 0 auto;
    padding: 0 18px;
    height: 50px;
    font-family: var(--sans);
    font-size: 13px;
    font-weight: 400;
    letter-spacing: 0.01em;
    text-transform: none;
    color: var(--ink-3);
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    cursor: pointer;
    white-space: nowrap;
    transition: color var(--t-fast), border-color var(--t-fast);
  }
  .rail__tab.is-active {
    color: var(--gold);
    border-bottom-color: var(--gold);
    background: rgba(201,169,97,0.04);
  }

  /* ── SECTION CONTENT ── */
  .rail__scroll {
    flex: 1;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
  }
  .rail__scroll .section { display: none; padding: 18px 20px; }
  .rail__scroll .section.is-mob-active { display: block; }

  /* ── FOOTER ── */
  .rail__foot {
    flex-shrink: 0;
    padding: 10px 16px 14px;
    border-top: 1px solid var(--line);
    background: linear-gradient(180deg, var(--surface) 0%, #0a0908 100%);
  }
  .price-row { margin-bottom: 8px; }
  .price-row__label { font-size: 9px; }
  .price-row__value { font-size: 24px; }
  .btn-row { gap: 8px; }
  .btn { height: 48px; font-size: 11px; }
  .foot-meta { display: none; }

  /* ── TOUCH-FRIENDLY CONTROLS ── */

  /* swatches */
  .swatch-row { gap: 8px; }
  .swatch__inner { inset: 5px; }

  /* finish */
  .finish-list { gap: 6px; }
  .finish-item { padding: 12px; }
  .finish-preview { width: 38px; height: 38px; }
  .finish-item__name { font-size: 13px; }

  /* sliders */
  .slider-block { margin-bottom: 18px; }
  .slider-label { font-size: 13px; }
  .slider-value { font-size: 12px; }
  input[type="range"] { height: 40px; }
  input[type="range"]::-webkit-slider-thumb { width: 22px; height: 22px; margin-top: -11px; }
  input[type="range"]::-moz-range-thumb { width: 22px; height: 22px; }

  /* segments */
  .segments { gap: 6px; }
  .seg { padding: 12px 8px; font-size: 11px; min-height: 44px; letter-spacing: 0.06em; }
  .segments--sub .seg { padding: 10px 8px; font-size: 10px; }

  /* stone buttons */
  .stone-btn { padding: 14px 10px; }
  .stone-btn__label { font-size: 10px; }

  /* engraving */
  .engrave-field { padding: 0 14px; height: 50px; }
  .engrave-field input { font-size: 16px; }
  .engrave-preview { padding: 12px 14px; }

  /* model desc card */
  .model-desc { font-size: 12px; }

  /* friso controls */
  .friso-controls { padding-top: 6px; }
}

/* ── medium screens ── */
@media (min-width: 769px) and (max-width: 900px) {
  .app { grid-template-columns: 1fr; grid-template-rows: 1fr auto; }
  .rail { border-left: 0; border-top: 1px solid var(--line); max-height: 50vh; }
  .rail__head { padding-top: 24px; }
  .nav__left, .nav__right { gap: 14px; }
  .nav__link { font-size: 10px; }
}
