/* #lithophane — stilurile secțiunii, scopate pe #lithophane */

/* --light: 0 = LED stins, 1 = LED aprins. Fără JS rămâne 1 (aprins). */
#lithophane .litho__stage { --light: 1; }

#lithophane .litho__grid {
  display: grid;
  gap: clamp(28px, 5vw, 56px);
  align-items: start;
}
@media (min-width: 900px) {
  #lithophane .litho__grid { grid-template-columns: 1.1fr 1fr; }
}

/* ---------- Demo ---------- */
#lithophane .litho__demo { min-width: 0; }
#lithophane .litho__fig { margin: 0; }

#lithophane .litho__stage {
  position: relative;
  display: grid;
  place-items: center;
  padding: clamp(28px, 6vw, 56px) clamp(16px, 5vw, 48px) clamp(22px, 4vw, 36px);
  border-radius: var(--radius);
  overflow: hidden;
  background:
    radial-gradient(70% 60% at 50% 45%, rgb(255 176 92 / calc(var(--light) * 0.32)), transparent 70%),
    linear-gradient(180deg, #1d2140 0%, var(--navy) 55%, var(--night) 100%);
  box-shadow: var(--shadow);
  isolation: isolate;
}

#lithophane .litho__stand {
  width: min(100%, 460px);
  display: grid;
  justify-items: center;
}

#lithophane .litho__frame {
  position: relative;
  width: 100%;
  padding: 10px;
  border-radius: 6px;
  background: linear-gradient(180deg, #f2efe8, #d9d4c8);
  box-shadow:
    0 14px 30px rgb(0 0 0 / 0.45),
    0 0 calc(var(--light) * 70px) calc(var(--light) * 10px) rgb(255 170 80 / calc(var(--light) * 0.5)),
    0 0 calc(var(--light) * 22px) rgb(255 214 150 / calc(var(--light) * 0.7));
  transition: box-shadow 0.3s var(--ease);
}

#lithophane .litho__plate {
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  border-radius: 2px;
  background: #f4efe2;
  /* Interpolare stins → aprins */
  filter:
    brightness(calc(1.04 - var(--light) * 0.06))
    contrast(calc(0.92 + var(--light) * 0.18))
    saturate(calc(0.85 + var(--light) * 0.25));
}

/* Stins: PLA crem, poza vizibilă doar ca relief slab */
#lithophane .litho__relief { opacity: calc(0.95 - var(--light) * 0.95); }
/* Aprins: lumina caldă trece prin zonele subțiri */
#lithophane .litho__photo { opacity: calc(var(--light) * var(--light) * 0.4 + var(--light) * 0.6); }

#lithophane .litho__tag {
  position: absolute;
  left: 16px;
  bottom: 16px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #3b3a35;
  background: rgb(255 255 255 / 0.78);
  padding: 2px 8px;
  border-radius: 999px;
  pointer-events: none;
}

#lithophane .litho__base {
  position: relative;
  width: 112%;
  max-width: calc(100% + 32px);
  height: 26px;
  margin-top: -2px;
  border-radius: 4px 4px 10px 10px;
  background: linear-gradient(180deg, #2c2f45 0%, #14162a 100%);
  box-shadow: 0 10px 24px rgb(0 0 0 / 0.5);
}
#lithophane .litho__led {
  position: absolute;
  left: 12%;
  right: 12%;
  top: 6px;
  height: 4px;
  border-radius: 4px;
  background: color-mix(in srgb, #ffcf8a calc(var(--light) * 100%), #4a4c5e);
  box-shadow: 0 0 calc(var(--light) * 14px) calc(var(--light) * 3px) rgb(255 190 110 / calc(var(--light) * 0.9));
}

#lithophane .litho__cap {
  margin: 12px 2px 0;
  font-size: var(--step--1);
}

/* ---------- Controale ---------- */
#lithophane .litho__controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 18px;
  margin-top: 16px;
}
#lithophane .litho__controls[hidden] { display: none; }
#lithophane .litho__toggle { flex: none; }
#lithophane .litho__slider {
  flex: 1 1 220px;
  display: grid;
  grid-template-columns: auto 1fr 3.2em;
  align-items: center;
  gap: 12px;
  min-height: 44px;
}
#lithophane .litho__slider label { font-weight: 700; }
#lithophane .litho__slider input {
  width: 100%;
  min-height: 44px;
  margin: 0;
  accent-color: var(--accent);
  cursor: pointer;
}
#lithophane .litho__val { text-align: right; color: var(--muted); font-size: var(--step--1); }

/* ---------- Text ---------- */
#lithophane .litho__text { min-width: 0; }
#lithophane .litho__text h3 { margin-bottom: 0.8em; }

#lithophane .litho__steps {
  list-style: none;
  margin: 0 0 20px;
  padding: 0;
  display: grid;
  gap: 16px;
  counter-reset: litho-step;
}
#lithophane .litho__steps li {
  position: relative;
  display: grid;
  gap: 2px;
  padding-left: 48px;
  counter-increment: litho-step;
}
#lithophane .litho__steps li::before {
  content: counter(litho-step);
  position: absolute;
  left: 0;
  top: 0;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent);
  font-weight: 800;
}
#lithophane .litho__steps span { color: var(--muted); }
#lithophane .litho__steps a { overflow-wrap: anywhere; }

#lithophane .litho__tips {
  border-left: 3px solid var(--accent);
  padding: 4px 0 4px 14px;
  margin-bottom: 24px;
}
#lithophane .litho__tips p { margin: 0; color: var(--muted); }
#lithophane .litho__tips strong { color: var(--text); }

#lithophane .litho__buy { display: grid; gap: 12px; justify-items: start; }
#lithophane .litho__buy .btn { justify-self: stretch; }
#lithophane .litho__size,
#lithophane .litho__note { margin: 0; font-size: var(--step--1); }
#lithophane .litho__price .price__launch { font-size: var(--step-2); }

/* ---------- Mod glow: placa rămâne „aprinsă", suportul devine neon ---------- */
html[data-mode="glow"] #lithophane .litho__stage { background: #000; box-shadow: 0 0 0 1px #15161f; }
html[data-mode="glow"] #lithophane .litho__led {
  box-shadow: 0 0 calc(var(--light) * 12px) calc(var(--light) * 2px) var(--glow-color);
  background: color-mix(in srgb, var(--glow-color) calc(var(--light) * 100%), #2b2d3a);
}

@media (prefers-reduced-motion: reduce) {
  #lithophane .litho__frame { transition: none; }
}
