/* relief.css – Modul „Relief“ (Produktseite). */

/* ---------------------------------------------------- Vorschau über dem Foto */
.rl-stage { position: absolute; inset: 0; z-index: 4; overflow: hidden; container-type: size;
  display: flex; align-items: center; justify-content: center; background: var(--ink-1, #f6efe2); }
.rl-stage[hidden] { display: none; }
.rl-stage .rl-comp { width: min(88cqw, calc(88cqh * var(--a, 1))); }
.pdp-stage.rl-on { transform: none !important; opacity: 1 !important; transition: none !important; }
.pdp-stage.rl-on .pdp-gal-nav { z-index: 6; }
@media (min-width: 901px) {
  /* Foto bleibt beim Auswählen im Blick (wie beim Personalisieren) */
  .pdp-hero:has(.rl-buy) > .pdp-stage { grid-row: 1 / span 2; }
  .pdp-hero:has(.rl-buy) > .pdp-badges { grid-row: 3; }
  .pdp-stage.rl-on { position: sticky; top: var(--rl-top, 130px); align-self: start; }
  .rl-mini { display: none; }
}
@media (max-width: 900px) {
  /* Handy: Vorschau steckt im Bedienfeld direkt unter dem Upload */
  .rl-stage { display: none !important; }
  .pdp-stage.rl-on { position: relative; }
}

.rl-wood { position: absolute; right: 12px; bottom: 12px; z-index: 5; padding: 6px 12px; font: inherit; font-size: .8rem; font-weight: 600;
  color: #3a2a14; background: rgba(255,255,255,.9); border: 1px solid var(--line, #d9cdb4); border-radius: 999px; cursor: pointer; }
.rl-wood[aria-pressed="true"] { color: #fff; background: #285c14; border-color: #285c14; }

/* ---- Komposition: Fenster mit Foto, Rahmen darüber ---- */
.rl-comp { position: relative; aspect-ratio: var(--a, 1); max-width: 100%; user-select: none; -webkit-user-select: none; }
.rl-comp[hidden] { display: none; }
.rl-clip { position: absolute; inset: 0; -webkit-mask-size: 100% 100%; mask-size: 100% 100%; -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat; }
.rl-win { position: absolute; overflow: hidden; }
.rl-comp.has-frame .rl-win { cursor: grab; touch-action: none; }
.rl-comp.is-drag .rl-win { cursor: grabbing; }
/* .rl-comp img… schlägt die Produktbild-Regeln der Shops (.pdp-stage img: 84 %, contain, Schatten) */
.rl-comp img.rl-ph { position: absolute; max-width: none; max-height: none; display: block; object-fit: fill; filter: none;
  transform: none; pointer-events: none; -webkit-user-drag: none; }
.rl-comp img.rl-fr { position: absolute; left: 0; top: 0; width: 100%; height: 100%; max-width: none; max-height: none; object-fit: fill;
  transform: none; pointer-events: none; -webkit-user-drag: none; filter: drop-shadow(0 6px 14px rgba(0,0,0,.18)); }
.rl-comp:not(.has-frame) .rl-clip { border-radius: 6px; overflow: hidden; box-shadow: 0 6px 18px rgba(0,0,0,.15); }
/* Holzoptik: grobe Andeutung, wie das Motiv im Holz wirkt */
.rl-comp.is-wood img.rl-ph { filter: grayscale(1) sepia(.85) saturate(1.35) contrast(1.08) brightness(1.04) hue-rotate(-6deg); }

/* ------------------------------------------------------- Bedienfeld */
.rl-buy { margin: 0 0 14px; padding: 14px; background: #fff; color: #241a0c;
  border: 1px solid var(--line, #d9cdb4); border-radius: 14px; }
.rl-head { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.rl-title { font-weight: 700; font-size: 1rem; }
.rl-extra { margin-left: auto; font-size: .82rem; color: #285c14; font-weight: 600; }
.rl-sec { margin: 0 0 16px; }
.rl-sec-h { margin: 0 0 6px; font-weight: 600; font-size: .9rem; }
.rl-opt-l { font-weight: 400; color: #8a7a5c; font-size: .8rem; }
.rl-help { margin: 6px 0 0; font-size: .8rem; color: #6b5a3c; white-space: pre-line; }

/* Upload */
.rl-drop { position: relative; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 18px 14px; text-align: center;
  background: #fbf6ec; border: 2px dashed #c9b993; border-radius: 12px; cursor: pointer; transition: border-color .15s, background .15s; }
.rl-drop:hover, .rl-drop.is-over { border-color: #285c14; background: #f3f9ee; }
.rl-drop[hidden] { display: none; }
.rl-drop input { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; }
.rl-drop-ic { font-size: 1.3rem; color: #285c14; line-height: 1; }
.rl-drop-t { font-weight: 600; color: #285c14; }
.rl-drop-s { font-size: .76rem; color: #8a7a5c; }
.rl-file { display: flex; align-items: center; gap: 10px; padding: 8px; background: #fbf6ec; border: 1px solid var(--line, #d9cdb4); border-radius: 12px; }
.rl-file[hidden] { display: none; }
.rl-file img { width: 54px; height: 54px; object-fit: cover; border-radius: 8px; flex: none; }
.rl-file-i { display: flex; flex-direction: column; min-width: 0; font-size: .84rem; }
.rl-file-i strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rl-file-i span { color: #8a7a5c; font-size: .78rem; }
.rl-swap { margin-left: auto; flex: none; padding: 7px 12px; font: inherit; font-size: .82rem; font-weight: 600; color: #285c14;
  background: #eef6e8; border: 1px solid #b9d7a6; border-radius: 999px; cursor: pointer; }
.rl-prog { height: 6px; margin-top: 8px; background: #eee3cf; border-radius: 3px; overflow: hidden; }
.rl-prog[hidden] { display: none; }
.rl-prog span { display: block; height: 100%; width: 0; background: #285c14; transition: width .2s; }
.rl-warn { margin: 8px 0 0; padding: 8px 10px; font-size: .8rem; color: #7a4a00; background: #fff4dc; border-radius: 9px; }
.rl-warn[hidden] { display: none; }
.rl-mini { margin-top: 10px; }
.rl-mini .rl-comp { width: min(100%, calc(52vh * var(--a, 1))); margin: 0 auto; }
.rl-crop { margin-top: 10px; }
.rl-crop[hidden] { display: none; }
.rl-rng { display: grid; grid-template-columns: 78px 1fr 52px; align-items: center; gap: 8px; font-size: .84rem; color: #3a2a14; }
.rl-rng input { width: 100%; accent-color: #285c14; }
.rl-rng output { text-align: right; font-variant-numeric: tabular-nums; color: #6b5a3c; }
.rl-tip { margin: 4px 0 0; font-size: .78rem; color: #8a7a5c; }
.rl-link { padding: 0; font: inherit; color: #285c14; text-decoration: underline; background: none; border: 0; cursor: pointer; }
.rl-woodopt { display: flex; align-items: center; gap: 6px; margin-top: 8px; font-size: .82rem; color: #3a2a14; cursor: pointer; }
.rl-woodopt[hidden] { display: none; }
.rl-woodopt input { accent-color: #285c14; width: 16px; height: 16px; }

/* Rahmen-Kacheln */
.rl-frames { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(96px, 100%), 1fr)); gap: 8px; }
.rl-fr-t { display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 8px 6px; font: inherit; font-size: .74rem; color: #3a2a14;
  background: #fbf6ec; border: 1px solid var(--line, #d9cdb4); border-radius: 10px; cursor: pointer; text-align: center; }
.rl-fr-t:hover { border-color: #285c14; }
.rl-fr-t.is-on { border-color: #285c14; background: #e3f1d9; box-shadow: inset 0 0 0 1px #285c14; }
.rl-fr-img { display: flex; align-items: center; justify-content: center; width: 100%; height: 72px; }
.rl-fr-img img { max-width: 100%; max-height: 100%; object-fit: contain; }
.rl-fr-none { position: relative; width: 46px; height: 60px; margin: 6px auto; border: 2px dashed #b9a882; border-radius: 6px; }
.rl-fr-none::after { content: ''; position: absolute; left: 50%; top: -6px; bottom: -6px; border-left: 2px solid #b9a882; transform: rotate(38deg); }
.rl-fr-n { font-weight: 600; line-height: 1.2; }
.rl-fr-p { color: #285c14; font-weight: 600; }

/* Auswahllisten */
.rl-sel { width: 100%; padding: 9px 10px; font: inherit; font-size: .88rem; color: #241a0c; background: #fff;
  border: 1px solid var(--line, #d9cdb4); border-radius: 9px; }
.rl-radios { display: flex; flex-direction: column; gap: 6px; }
.rl-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(110px, 100%), 1fr)); gap: 8px; }
.rl-opt { display: flex; align-items: center; gap: 8px; padding: 9px 11px; font-size: .86rem; color: #3a2a14;
  background: #fbf6ec; border: 1px solid var(--line, #d9cdb4); border-radius: 10px; cursor: pointer; }
.rl-opt:hover { border-color: #285c14; }
.rl-opt.is-on { border-color: #285c14; background: #e3f1d9; box-shadow: inset 0 0 0 1px #285c14; }
.rl-opt input { accent-color: #285c14; margin: 0; flex: none; }
.rl-opt-p { margin-left: auto; color: #285c14; font-weight: 600; white-space: nowrap; font-size: .8rem; }
.rl-opt-t { flex-direction: column; text-align: center; gap: 4px; padding: 8px; }
.rl-opt-t input { position: absolute; opacity: 0; pointer-events: none; }
.rl-opt-t { position: relative; }
.rl-opt-t img, .rl-opt-ph { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 7px; background: #eee3cf; }
.rl-opt-t .rl-opt-n { font-weight: 600; line-height: 1.2; }
.rl-opt-t .rl-opt-p { margin: 0; }
.rl-opt:has(input:focus-visible) { outline: 2px solid #285c14; outline-offset: 2px; }
.rl-det { margin-top: 6px; font-size: .8rem; color: #3a2a14; }
.rl-det summary { cursor: pointer; color: #285c14; font-weight: 600; }
.rl-det div { margin-top: 6px; padding: 10px 12px; white-space: pre-line; background: #fbf6ec; border-radius: 9px; line-height: 1.45; }
.rl-note { width: 100%; padding: 8px 10px; font: inherit; font-size: .88rem; color: #241a0c; background: #fff;
  border: 1px solid var(--line, #d9cdb4); border-radius: 9px; resize: vertical; }

.rl-msg { margin: 10px 0 0; font-size: .84rem; color: #3a2a14; }
.rl-msg.is-err { color: #a33; }
.rl-msg[hidden] { display: none; }
.rl-need { margin: 10px 0 0; font-size: .86rem; color: #a35a00; }
.rl-need[hidden] { display: none; }
.rl-buy .rtg-ack { margin: 10px 0 0; font-size: .82rem; }
.rl-buy .rtg-ack[hidden] { display: none; }
.rl-buy .rtg-ack .custom-note { margin: 0; }
