/* Solpark: lysboks for bilder og figurer i kortene (solpark-lysboks.js) */
:root {
  --splb-bak: oklch(0.16 0.01 80 / 0.92);
  --splb-flate: oklch(0.99 0.004 80);
  --splb-tekst: oklch(0.96 0.01 80);
  --splb-knapp: oklch(0.30 0.012 80 / 0.85);
  --splb-knapp-hover: oklch(0.40 0.014 80 / 0.95);
}
.solpark-panel [data-lysboks-merket], .spg-innhold [data-lysboks-merket] { cursor: zoom-in; }
.splb { position: fixed; inset: 0; z-index: 12000; display: none; background: var(--splb-bak); color: var(--splb-tekst); }
.splb--aapen { display: block; }
.splb__flate { position: absolute; inset: 56px 64px 24px; display: flex; align-items: center; justify-content: center; overflow: hidden; touch-action: none; cursor: grab; }
.splb__flate:active { cursor: grabbing; }
.splb__innhold { max-width: 100%; max-height: 100%; width: 100%; transform-origin: center center; display: flex; align-items: center; justify-content: center; will-change: transform; }
.splb__innhold > img, .splb__innhold > canvas { max-width: 100%; max-height: calc(100vh - 80px); object-fit: contain; user-select: none; -webkit-user-drag: none; pointer-events: none; }
.splb__innhold--svg { background: var(--splb-flate); border-radius: 6px; max-height: calc(100vh - 80px); height: auto; }
.splb__innhold--svg > svg { display: block; pointer-events: none; }
.splb__topp { position: absolute; left: 0; right: 0; top: 0; height: 56px; display: flex; align-items: center; gap: 12px; padding: 0 12px 0 16px; font: 14px/1.3 system-ui, sans-serif; }
.splb__teller { flex: none; opacity: 0.75; font-variant-numeric: tabular-nums; }
.splb__tekst { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.splb__knapper { flex: none; display: flex; gap: 6px; }
.splb button { font: 600 18px/1 system-ui, sans-serif; color: var(--splb-tekst); background: var(--splb-knapp); border: 0; border-radius: 8px; min-width: 40px; height: 40px; cursor: pointer; }
.splb button:hover, .splb button:focus-visible { background: var(--splb-knapp-hover); outline: 2px solid oklch(0.85 0.08 75); outline-offset: 1px; }
.splb__pil { position: absolute; top: 50%; transform: translateY(-50%); font-size: 30px !important; height: 64px !important; }
.splb__pil--forrige { left: 10px; }
.splb__pil--neste { right: 10px; }
.splb--en .splb__pil { display: none; }
@media (max-width: 700px) {
  .splb__flate { inset: 56px 8px 8px; }
  .splb__pil { top: auto; bottom: 12px; transform: none; }
  .splb__tekst { font-size: 12px; white-space: normal; max-height: 48px; }
}
