/* ==========================================================================
   TRICOM — konfigurator.css
   3D konfigurator krova i oluka. Čita tokene iz base.css (boje obe teme,
   tipografija) i dugmad iz components.css; sve ostalo je lokalno.
   Raspored: zaglavlje po pravilima sajta (--header-h), šina sa koracima
   01–06 levo (mono indeks i klizna traka), panel sa opcijama desno, traka
   „Prikaz“ dole u sredini. Telefon: donja traka sa koracima + list koji se
   izvlači. Pozadina 3D scene je pozadina strane u boji teme (--hero-*):
   platno je providno u studijskom prikazu.
   ========================================================================== */

.k-body {
  --k-panel-w: 404px;
  --k-panel-wide: min(660px, 50vw);
  --k-rail-w: 216px;
  --k-rail-item: 58px;
  --k-top: var(--header-h);
  --k-right: 0px;
  --k-gap: 14px;                                   /* staklene ploče lebde ovoliko od ivica scene */
  --k-ink: var(--tricom);
  /* „Forged Glass“ nad živom 3D scenom: ista receptura kao .g-card (base.css
     tokeni), ali gušća ispuna — iza stakla prolazi i nebo u podne, i sneg,
     i noćna scena, pa tekst mora ostati AA nad čisto belom / čisto crnom.
     Svetla: mlečno staklo .86; tamna: dimljena tinta .88 (v. _qa/forged/konf). */
  --glass-fill:   rgba(255, 255, 255, .86);
  --glass-fill-2: rgba(255, 255, 255, .94);
  --k-well:   rgba(255, 255, 255, .62);           /* ugnježdeno u staklo: pilule, čipovi, ploče (bez zamućenja) */
  --k-well-2: #FFFFFF;
  --k-hover:  rgba(10, 14, 20, .06);
  --hero-bg: linear-gradient(180deg, var(--hero-wall-1) 0%, var(--hero-wall-2) 60%, var(--hero-floor-2) 100%);
  position: fixed; inset: 0;
  overflow: hidden;
  color: var(--fg);
  background: var(--bg);
  overscroll-behavior: none;
}
html[data-theme="dark"] .k-body {
  --k-ink: var(--arc);
  --glass-fill:   rgba(16, 20, 27, .92);
  --glass-fill-2: rgba(30, 36, 46, .95);
  --k-well:   rgba(255, 255, 255, .05);
  --k-well-2: rgba(255, 255, 255, .12);
  --k-hover:  rgba(255, 255, 255, .07);
}
/* slab hardver / bez backdrop-filter-a: puna površina (kao base.css za .g-card) */
html.tier-low .k-body { --glass-fill: var(--glass-fill-solid); --glass-fill-2: var(--glass-fill-solid); }
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .k-body { --glass-fill: var(--glass-fill-solid); --glass-fill-2: var(--glass-fill-solid); }
}
body.k-open { --k-right: var(--k-panel-w); }
body.k-open.k-wide { --k-right: var(--k-panel-wide); }

/* ---- Staklo L2 (zamućeno; budžet ≤ 6 u kadru: šina, panel, traka, lista, inspektor
        + list na telefonu) i L3 pilule bez zamućenja. Zaglavlje .k-top ostaje puna
        traka (--header-solid). Toast i vodič su pune površine. ---------------------- */
.k-rail, .k-panel, .k-dock, .k-listpop, .k-ins {
  background: var(--glass-fill);
  border: 1px solid var(--glass-stroke);
  box-shadow: inset 0 1px 0 var(--glass-highlight), var(--glass-shadow);
  -webkit-backdrop-filter: var(--glass-bf);
          backdrop-filter: var(--glass-bf);
}
/* L3 pilule (A/B, očitavanje, pomoć, izlaz, zamena): --glass-fill-2 + obod + 1 px
   svetla linija, bez zamućenja — pravila stoje uz svaki element niže. */
/* ugnježdena staklena kartica u panelu (korak 06): pilula-jezičak dole desno nosi ukupno m² */
.k-card { position: relative; padding: 16px 18px 18px; background: var(--k-well); border: 1px solid var(--glass-stroke); border-radius: var(--r-m); box-shadow: inset 0 1px 0 var(--glass-highlight); }
.k-card--tab { margin-bottom: 28px; }
.k-card__tab {
  position: absolute; right: 18px; bottom: -16px; z-index: 1;
  display: inline-flex; align-items: center; gap: 8px; height: 34px; padding: 0 14px 0 15px;
  font-family: var(--ff-mono); font-size: var(--t-label); font-weight: 500; letter-spacing: var(--track-label); text-transform: uppercase; color: var(--fg-muted);
  background: var(--k-well-2); border: 1px solid var(--glass-stroke); border-radius: var(--r-pill);
  box-shadow: inset 0 1px 0 var(--glass-highlight), var(--glass-shadow-sm); white-space: nowrap;
}
.k-card__tab b { font-family: var(--ff-display); font-size: 15px; font-weight: 700; letter-spacing: 0; text-transform: none; color: var(--fg-strong); font-variant-numeric: tabular-nums; }
.k-card__tab b:empty { display: none; }

/* ---- Scena ---------------------------------------------------------------- */
.k-stage { position: absolute; inset: var(--k-top) 0 0 0; background: var(--hero-bg); }
.k-stage canvas { display: block; width: 100%; height: 100%; max-width: none; touch-action: none; outline: none; cursor: grab; }
.k-stage canvas:active { cursor: grabbing; }

.k-loader {
  position: fixed; inset: 0; z-index: calc(var(--z-overlay) + 10);
  display: grid; place-items: center; background: var(--bg);
  transition: opacity 500ms var(--ease);
}
.k-loader.is-done { opacity: 0; pointer-events: none; }
.k-loader__in { width: min(300px, 70vw); text-align: center; }
.k-loader__in img { width: 190px; margin: 0 auto var(--sp-5, 20px); }
.k-loader__bar { height: 2px; background: var(--line); overflow: hidden; }
.k-loader__bar span { display: block; height: 100%; background: var(--brand); transform: scaleX(0.04); transform-origin: left; transition: transform 300ms var(--ease); }
.k-loader p { margin-top: 12px; font-size: var(--t-xs); letter-spacing: .08em; text-transform: uppercase; color: var(--fg-faint); }

/* ---- Zaglavlje (isto kao na sajtu) ---------------------------------------- */
.k-top {
  position: fixed; left: 0; right: 0; top: 0; z-index: calc(var(--z-panel) + 4);     /* above the panel: the inquiry-list popover lives in here */
  height: var(--header-h);
  display: flex; align-items: center; gap: 10px;
  padding-inline: var(--gutter);
  background: var(--header-solid);
  border-bottom: 1px solid var(--line);
}
.k-top__brand { display: flex; align-items: center; flex: none; margin-right: 6px; }
.k-top__brand img { height: 44px; width: auto; transition: transform var(--dur) var(--ease); }
.k-top__brand:hover img { transform: scale(1.03); }
@media (min-width: 900px) { .k-top__brand img { height: 50px; } }
.k-top__back {
  flex: none; display: inline-flex; align-items: center; gap: 8px;
  height: 40px; padding: 0 14px;
  border: 1px solid var(--line-strong); border-radius: var(--r-pill);
  font-size: var(--t-sm); font-weight: 500; color: var(--fg-strong);
  transition: border-color var(--dur-fast), color var(--dur-fast);
}
.k-top__back svg { width: 16px; height: 16px; flex: none; }
.k-top__back:hover { border-color: var(--accent); color: var(--accent); }
.k-top__title { display: flex; flex-direction: column; gap: 1px; margin-left: 10px; padding-left: 14px; border-left: 1px solid var(--line); line-height: 1.2; }
.k-top__title .label { color: var(--accent); }
.k-top__title span:last-child { font-size: var(--t-sm); color: var(--fg-muted); }
.k-top__sp { flex: 1; min-width: 4px; }
.k-top__list {
  position: relative; flex: none; display: inline-flex; align-items: center; gap: 8px;
  height: 40px; padding: 0 12px 0 13px;
  border: 1px solid var(--line-strong); border-radius: var(--r-pill);
  font-size: var(--t-sm); font-weight: 500; color: var(--fg-strong);
  transition: border-color var(--dur-fast), color var(--dur-fast);
}
.k-top__list svg { width: 17px; height: 17px; flex: none; }
.k-top__list:hover, .k-top__list[aria-expanded="true"] { border-color: var(--accent); color: var(--accent); }
.k-badge {
  min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px;
  display: inline-grid; place-items: center;
  font-family: var(--ff-mono); font-size: 11px; font-weight: 500;
  background: var(--surface-3); color: var(--fg-muted);
}
.k-top__list.has-items .k-badge { background: var(--brand); color: var(--brand-ink); }
.k-top__cta { flex: none; white-space: nowrap; }
.k-top__cta svg { width: 15px; height: 15px; }

.themesw {
  position: relative; flex: none;
  width: 40px; height: 40px;
  display: grid; place-items: center;
  border: 1px solid var(--line-strong); border-radius: 50%;
  color: var(--fg-strong);
  transition: border-color var(--dur-fast), color var(--dur-fast);
}
.themesw:hover { border-color: var(--accent); color: var(--accent); }
.themesw svg { width: 18px; height: 18px; overflow: visible; }
.themesw__core { transform-origin: 12px 12px; transform: scale(.56); transition: transform 520ms var(--ease); }
.themesw__cut  { transform: translate(9px, -9px); transition: transform 520ms var(--ease); }
.themesw__rays { transform-origin: 12px 12px; transition: transform 520ms var(--ease), opacity 320ms var(--ease); }
.themesw[aria-pressed="true"] .themesw__core { transform: scale(1); }
.themesw[aria-pressed="true"] .themesw__cut  { transform: translate(0, 0); }
.themesw[aria-pressed="true"] .themesw__rays { transform: rotate(-60deg) scale(.4); opacity: 0; }

/* prekidač jezika SR | EN (logika: js/lang.js) — isti „pill“ kao na sajtu (layout.css se ovde ne učitava), vidljiv na svim širinama */
.k-top .langsw {
  display: flex; align-items: center; gap: 8px; flex: none;
  height: 40px; padding: 0 14px;
  border: 1px solid var(--line-strong); border-radius: var(--r-pill);
}
.k-top .langsw__b {
  font-family: var(--ff-mono); font-size: var(--t-label); letter-spacing: var(--track-label); text-transform: uppercase;
  color: var(--fg-faint); padding: 4px 0;
  transition: color var(--dur-fast) var(--ease);
}
.k-top .langsw__b:hover { color: var(--accent); }
.k-top .langsw__b[aria-current="true"] { color: var(--fg-strong); font-weight: 500; }
.k-top .langsw__sep { width: 1px; height: 12px; background: var(--line-strong); flex: none; }

/* lista za upit — iskačući panel ispod dugmeta u zaglavlju */
.k-listpop {
  position: fixed; top: calc(var(--header-h) + 10px); right: var(--gutter); z-index: calc(var(--z-panel) + 3);
  width: min(380px, calc(100vw - 20px)); max-height: calc(100vh - var(--header-h) - 24px); overflow-y: auto;
  padding: 16px 18px 18px; border-radius: var(--r-m);
}
.k-listpop[hidden] { display: none; }
.k-listpop .k-list { margin-top: 0; border-top: 0; }
.k-listpop__h { display: flex; align-items: center; justify-content: space-between; padding-bottom: 6px; border-bottom: 1px solid var(--line); }
.k-listpop__h b { font-family: var(--ff-display); font-size: 1.05rem; color: var(--fg-strong); }
.k-listpop .k-chip { margin-top: 12px; }

@media (max-width: 1279px) { .k-top__title { display: none; } }
@media (max-width: 1099px) { .k-top__back span, .k-top__ll { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; } .k-top__back { padding: 0 11px; } }

/* ---- Šina sa koracima: vertikalni mono indeks 01–06 i klizna traka ---------- */
.k-rail {
  position: fixed; left: var(--k-gap); top: calc(var(--k-top) + var(--k-gap)); bottom: var(--k-gap); z-index: calc(var(--z-panel) - 1);
  width: calc(var(--k-rail-w) - var(--k-gap));
  display: flex; flex-direction: column;
  padding: 14px 0;
  border-radius: var(--r-l);
  overflow: hidden;
}
.k-rail__bar {
  position: absolute; left: 6px; top: calc(14px + 9px); width: 3px; height: calc(var(--k-rail-item) - 18px);
  border-radius: 3px; background: var(--brand);
  transform: translateY(calc(var(--i, 0) * var(--k-rail-item)));
  opacity: 0; transition: transform 380ms var(--ease-cine, var(--ease)), opacity 200ms;
}
.k-rail.has-active .k-rail__bar { opacity: 1; }
.k-rail__b {
  position: relative; flex: none;
  display: grid; grid-template-columns: 42px 1fr; align-items: center;
  height: var(--k-rail-item); margin: 0 10px 0 12px; padding: 0 10px 0 14px;
  border-radius: var(--r-s);
  text-align: left; color: var(--fg-muted);
  transition: background var(--dur-fast), color var(--dur-fast);
}
.k-rail__n { font-family: var(--ff-mono); font-weight: 500; font-size: 13px; letter-spacing: .02em; color: var(--fg-faint); transition: color var(--dur-fast); }
.k-rail__l { font-family: var(--ff-display); font-weight: 600; font-size: 14.5px; line-height: 1.2; color: var(--fg-strong); }
.k-rail__l small { display: block; margin-top: 2px; font-family: var(--ff-mono); font-weight: 400; font-size: 10px; letter-spacing: .04em; text-transform: uppercase; color: var(--fg-faint); }
.k-rail__s { display: none; }
.k-rail__b:hover { background: var(--k-hover); }
.k-rail__b.is-active { background: var(--k-well-2); box-shadow: inset 0 0 0 1px var(--glass-stroke), inset 0 1px 0 var(--glass-highlight); }
.k-rail__b.is-active .k-rail__n { color: var(--accent); }
.k-rail__b.is-secondary { border-top: 1px dashed var(--line-strong); border-radius: 0 0 var(--r-s) var(--r-s); }
.k-rail__b.is-secondary .k-rail__l { color: var(--fg-muted); font-weight: 500; }
.k-rail__b:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
@media (min-width: 821px) and (max-width: 1199px) {
  .k-body { --k-rail-w: 72px; }
  .k-rail__b { grid-template-columns: 1fr; margin: 0 6px; padding: 0; justify-items: center; }
  .k-rail__bar { left: 3px; }
  .k-rail__n { font-size: 14px; }
  .k-rail__l { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
}

/* ---- Tačke na modelu (otvaraju korak) ---------------------------------------- */
.k-hotspots { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
/* HUD prsten (recept .hud iz components.css, lokalno): 44 px staklo, 1 px obod,
   unutrašnji prsten na 70 % u --arc-line, mono broj; aktivan: prsten i broj u
   brendu + brend tačka na vrhu oboda. Bez zamućenja (budžet). */
.k-hot {
  position: absolute; left: 0; top: 0; width: 44px; height: 44px; pointer-events: auto;
  display: grid; place-items: center; border-radius: 50%;
  background: var(--glass-fill); color: var(--fg-muted);
  border: 1px solid var(--glass-stroke);
  box-shadow: inset 0 1px 0 var(--glass-highlight), var(--glass-shadow-sm);
  transition: background var(--dur-fast), border-color var(--dur-fast), color var(--dur-fast), opacity var(--dur);
}
.k-hot::before { content: ''; position: absolute; inset: 15%; border: 1px solid var(--arc-line); border-radius: 50%; pointer-events: none; transition: border-color var(--dur-fast), transform var(--dur) var(--ease); }
.k-hot::after { content: ''; position: absolute; left: 50%; top: -4px; width: 7px; height: 7px; margin-left: -3.5px; border-radius: 50%; background: var(--brand); box-shadow: 0 0 0 2px var(--glass-fill-2); opacity: 0; transform: scale(.4); pointer-events: none; transition: opacity var(--dur-fast), transform var(--dur-fast) var(--ease); }
.k-hot span { position: relative; font-family: var(--ff-mono); font-weight: 500; font-size: 11px; letter-spacing: .04em; font-variant-numeric: tabular-nums; }
.k-hot:hover { color: var(--fg-strong); border-color: var(--line-strong); background: var(--glass-fill-2); }
.k-hot:hover::before { transform: scale(1.08); }
.k-hot.is-active { color: var(--accent); border-color: var(--accent-line); background: var(--glass-fill-2); }
.k-hot.is-active::before { border-color: var(--accent); }
.k-hot.is-active::after { opacity: 1; transform: scale(1); }
.k-hot:focus-visible { outline: 2px solid var(--brand); outline-offset: 3px; }
body.k-kote-on .k-hot, body.k-ins-on .k-hot { opacity: 0; pointer-events: none; }
body.k-ins-on .k-help { display: none; }

/* ---- Kote ------------------------------------------------------------------- */
.k-kote { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
.k-kota {
  position: absolute; left: 0; top: 0; padding: 3px 8px 2px; border-radius: var(--r-xs);
  font-family: var(--ff-mono); font-size: 12px; white-space: nowrap; color: #fff;
  background: rgba(6, 80, 197, .92); box-shadow: 0 0 0 1px rgba(255, 255, 255, .6);
  transition: opacity 200ms;
}
.k-kota.is-hid { opacity: 0; }

/* ---- Poređenje A / B --------------------------------------------------------------- */
.k-cmp { position: absolute; inset: 0; pointer-events: none; overflow: hidden; z-index: 3; }
.k-cmp[hidden] { display: none; }
.k-cmp__div { position: absolute; top: 0; bottom: 0; left: -16px; width: 32px; pointer-events: auto; cursor: ew-resize; touch-action: none; outline: none; }
.k-cmp__div::before { content: ''; position: absolute; left: 15px; top: 0; bottom: 0; width: 2px; background: #fff; box-shadow: 0 0 0 1px rgba(11, 14, 19, .25); }
.k-cmp__div i {
  position: absolute; left: 50%; top: 50%; width: 36px; height: 36px; margin: -18px 0 0 -18px; border-radius: 50%;
  background: #fff; box-shadow: 0 0 0 1px rgba(10, 14, 20, .12), 0 8px 24px rgba(0, 0, 0, .28);
}
.k-cmp__div i::before { content: '‹ ›'; position: absolute; inset: 0; display: grid; place-items: center; font-family: var(--ff-mono); font-size: 13px; color: #0B0E13; }
.k-cmp__div:focus-visible i, .k-cmp__div.is-drag i { box-shadow: 0 0 0 3px var(--brand), 0 6px 18px rgba(0, 0, 0, .28); }
#kSwap {
  position: absolute; left: 50%; top: 62px; transform: translateX(-50%); height: 30px; padding: 0 12px; pointer-events: auto;
  border-radius: var(--r-pill); background: var(--glass-fill-2); border: 1px solid var(--glass-stroke); box-shadow: inset 0 1px 0 var(--glass-highlight), var(--glass-shadow-sm);
  color: var(--fg-strong); font-family: var(--ff-mono); font-size: 11px; letter-spacing: .06em; text-transform: uppercase;
  transition: background var(--dur-fast), color var(--dur-fast), border-color var(--dur-fast);
}
#kSwap:hover { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
.k-cmp__side {
  position: absolute; top: 14px; display: flex; align-items: center; gap: 0; max-width: 40%; height: 36px; padding: 0 14px 0 0; pointer-events: auto;
  border: 1px solid var(--glass-stroke); border-radius: var(--r-pill); overflow: hidden;
  background: var(--glass-fill-2); box-shadow: inset 0 1px 0 var(--glass-highlight), var(--glass-shadow-sm);
  font-size: var(--t-sm); color: var(--fg-muted); white-space: nowrap;
  transition: border-color var(--dur-fast), color var(--dur-fast);
}
.k-cmp__side b { flex: none; display: grid; place-items: center; width: 28px; height: 28px; margin: 0 9px 0 3px; border-radius: 50%; background: var(--k-well-2); box-shadow: inset 0 0 0 1px var(--glass-stroke); font-family: var(--ff-mono); font-weight: 500; font-size: 12px; color: var(--fg-strong); }
.k-cmp__side span { overflow: hidden; text-overflow: ellipsis; }
.k-cmp__side.is-active { border-color: var(--accent-line); color: var(--fg-strong); }
.k-cmp__side.is-active b { background: var(--brand); box-shadow: none; color: var(--brand-ink); }

/* ---- Očitavanje kiše, pomoć -------------------------------------------------------- */
.k-readout {
  position: absolute; top: 16px; left: calc(var(--k-rail-w) + 16px); z-index: 2; max-width: 380px;
  padding: 10px 16px 11px 14px; border-radius: var(--r-s);
  background: var(--glass-fill-2); border: 1px solid var(--glass-stroke); border-left: 3px solid #2f9e6b;
  box-shadow: inset 0 1px 0 var(--glass-highlight), var(--glass-shadow-sm);
}
.k-readout[hidden] { display: none; }
.k-readout b { display: block; font-family: var(--ff-mono); font-weight: 500; font-size: var(--t-sm); color: var(--fg-strong); }
.k-readout small { display: block; margin-top: 2px; font-size: var(--t-xs); color: var(--fg-muted); }
.k-readout.is-bad { border-left-color: var(--danger); }
.k-readout.is-bad small { color: var(--danger); }
body.k-cmp-on .k-readout { top: 62px; }
/* „?“ sedi u praznom donjem levom uglu staklene šine (iznad nje u redosledu slojeva), da ne seče traku „Prikaz“ */
.k-help {
  position: absolute; left: calc(var(--k-gap) + 22px); bottom: calc(var(--k-gap) + 22px); z-index: var(--z-panel);
  width: 40px; height: 40px; display: grid; place-items: center; border-radius: 50%;
  background: var(--glass-fill-2); border: 1px solid var(--glass-stroke); box-shadow: inset 0 1px 0 var(--glass-highlight), var(--glass-shadow-sm);
  font-family: var(--ff-mono); font-weight: 500; font-size: 15px; color: var(--fg-strong);
  transition: background var(--dur-fast), color var(--dur-fast), border-color var(--dur-fast);
}
.k-help:hover { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }

/* ---- Traka „Prikaz“ (staklo L2, pilula) ------------------------------------------------ */
.k-dock {
  position: absolute; bottom: 18px; z-index: 4;
  left: calc(var(--k-rail-w) + (100vw - var(--k-rail-w) - var(--k-right)) / 2);
  transform: translateX(-50%);
  display: flex; align-items: center; gap: 2px;
  padding: 6px; border-radius: var(--r-pill);
  transition: left 420ms var(--ease);
}
.k-dock__t {
  padding: 0 10px 0 12px; margin-right: 2px; align-self: stretch; display: flex; align-items: center;
  font-family: var(--ff-mono); font-size: var(--t-label, 11.5px); letter-spacing: var(--track-label, .14em); text-transform: uppercase; color: var(--fg-faint);
  border-right: 1px solid var(--line);
}
.k-dock__i { position: relative; }
.k-tool {
  display: inline-flex; align-items: center; gap: 7px; height: 38px; padding: 0 13px;
  border-radius: var(--r-pill); color: var(--fg-strong);
  font-family: var(--ff-mono); font-size: 11px; font-weight: 500; letter-spacing: .08em; text-transform: uppercase;
  transition: background var(--dur-fast), color var(--dur-fast);
}
.k-tool svg { width: 18px; height: 18px; flex: none; }
.k-tool:hover, .k-tool[aria-expanded="true"] { background: var(--k-hover); }
.k-tool.is-on, .k-tool[aria-pressed="true"] { background: var(--brand); color: var(--brand-ink); }
.k-tool:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
/* iskačući meniji trake: puna površina (zamućenje unutar zamućene trake ne bi imalo šta da zamuti) */
.k-pop {
  position: absolute; bottom: calc(100% + 12px); left: 50%; transform: translateX(-50%);
  min-width: 250px; padding: 8px; border-radius: var(--r-m);
  background: var(--glass-fill-solid); border: 1px solid var(--glass-stroke);
  box-shadow: inset 0 1px 0 var(--glass-highlight), var(--glass-shadow);
  display: grid; gap: 1px;
}
.k-pop[hidden] { display: none; }
.k-pop button { display: block; width: 100%; padding: 10px 12px; text-align: left; border-radius: var(--r-s); box-shadow: inset 2px 0 0 transparent; transition: background var(--dur-fast), box-shadow var(--dur-fast); }
.k-pop button:hover { background: var(--k-hover); }
.k-pop button b { display: block; font-family: var(--ff-display); font-weight: 600; font-size: var(--t-sm); color: var(--fg-strong); }
.k-pop button small { display: block; margin-top: 1px; font-size: var(--t-xs); color: var(--fg-muted); }
.k-pop button.is-on, .k-pop button[aria-pressed="true"], .k-pop button[aria-checked="true"] { box-shadow: inset 2px 0 0 var(--brand); background: var(--accent-soft); }
.k-pop button[aria-pressed="true"] b::after, .k-pop button[aria-checked="true"] b::after { content: ' · uključeno'; font-family: var(--ff-mono); font-weight: 400; font-size: 10.5px; color: var(--accent); }
.k-tool--ico { padding: 0 10px; }
.k-tool[disabled] { opacity: .35; cursor: default; }
.k-tool[disabled]:hover { background: none; }
.k-dock__sep { width: 1px; height: 22px; margin: 0 4px; background: var(--line); }

/* Pogledi kamere kao HUD brojčanik (≥ 821 px): postojećih 7 dugmadi raspoređeno
   po krugu kao HUD prstenovi 01–07; naziv pogleda (b/small iz markupa) se pri
   hover/fokusu ispisuje u sredini brojčanika (vraćen kontra-transformom), a
   naziv grupe u sredini dolazi iz postojećeg aria-label-a. Na telefonu ostaje
   obična lista (poništeno u @media max-width: 820px). */
.k-pop--dial {
  --k-dial-r: 88px;
  display: block; min-width: 0; width: 244px; height: 244px; padding: 0; border-radius: 50%;
  counter-reset: dial;
}
.k-pop--dial[hidden] { display: none; }
.k-pop--dial::before { content: ''; position: absolute; inset: 46px; border: 1px solid var(--arc-line); border-radius: 50%; pointer-events: none; }
.k-pop--dial::after {
  content: attr(aria-label); position: absolute; left: 50%; top: 50%; width: 110px; transform: translate(-50%, -50%);
  text-align: center; font-family: var(--ff-mono); font-size: 10px; letter-spacing: .12em; text-transform: uppercase; line-height: 1.4; color: var(--fg-faint);
  pointer-events: none; transition: opacity var(--dur-fast);
}
.k-pop--dial:has(button:hover, button:focus-visible)::after { opacity: 0; }
.k-pop--dial button {
  position: absolute; left: 50%; top: 50%; width: 44px; height: 44px; margin: -22px 0 0 -22px; padding: 0;
  border-radius: 50%; background: var(--glass-fill); border: 1px solid var(--glass-stroke); box-shadow: inset 0 1px 0 var(--glass-highlight);
  transform: rotate(var(--a, 0deg)) translate(var(--k-dial-r)) rotate(calc(-1 * var(--a, 0deg)));
  counter-increment: dial; text-align: center;
  transition: background var(--dur-fast), border-color var(--dur-fast), box-shadow var(--dur-fast);
}
.k-pop--dial button::before { content: counter(dial, decimal-leading-zero); font-family: var(--ff-mono); font-weight: 500; font-size: 11px; letter-spacing: .04em; color: var(--fg-muted); font-variant-numeric: tabular-nums; }
.k-pop--dial button::after { content: ''; position: absolute; inset: 15%; border: 1px solid var(--arc-line); border-radius: 50%; pointer-events: none; transition: border-color var(--dur-fast); }
.k-pop--dial button:nth-child(1) { --a: -90deg; }
.k-pop--dial button:nth-child(2) { --a: -38.571deg; }
.k-pop--dial button:nth-child(3) { --a: 12.857deg; }
.k-pop--dial button:nth-child(4) { --a: 64.286deg; }
.k-pop--dial button:nth-child(5) { --a: 115.714deg; }
.k-pop--dial button:nth-child(6) { --a: 167.143deg; }
.k-pop--dial button:nth-child(7) { --a: 218.571deg; }
.k-pop--dial button b, .k-pop--dial button small {
  position: absolute; left: 50%; width: 124px; margin-left: -62px; text-align: center; pointer-events: none; opacity: 0;
  transform: rotate(var(--a, 0deg)) translate(calc(-1 * var(--k-dial-r))) rotate(calc(-1 * var(--a, 0deg)));
  transition: opacity var(--dur-fast);
}
.k-pop--dial button b { top: calc(50% - 20px); font-size: var(--t-sm); line-height: 1.25; }
.k-pop--dial button small { top: calc(50% + 10px); margin-top: 0; font-size: 10.5px; line-height: 1.3; }
.k-pop--dial button:hover, .k-pop--dial button:focus-visible { background: var(--glass-fill-2); border-color: var(--accent-line); box-shadow: inset 0 1px 0 var(--glass-highlight), 0 0 0 4px var(--accent-soft); }
.k-pop--dial button:hover::before, .k-pop--dial button:focus-visible::before { color: var(--accent); }
.k-pop--dial button:hover::after, .k-pop--dial button:focus-visible::after { border-color: var(--accent); }
.k-pop--dial button:hover b, .k-pop--dial button:focus-visible b, .k-pop--dial button:hover small, .k-pop--dial button:focus-visible small { opacity: 1; }
@media (max-width: 1279px) and (min-width: 821px) { .k-tool span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; } .k-tool { padding: 0 11px; } }
@media (max-width: 1499px) and (min-width: 821px) { body.k-open .k-dock__t { display: none; } }
@media (max-width: 1799px) and (min-width: 821px) {
  body.k-open .k-tool span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  body.k-open .k-tool { padding: 0 11px; }
}
/* presentation: only the stage and a way out */
body.k-present .k-top, body.k-present .k-rail, body.k-present .k-dock, body.k-present .k-help, body.k-present .k-hotspots, body.k-present .k-panel, body.k-present .k-ins, body.k-present .k-readout, body.k-present .k-listpop { display: none !important; }
body.k-present .k-stage { inset: 0; }
.k-present__x { position: fixed; right: 18px; top: 18px; z-index: 50; height: 40px; padding: 0 16px; border-radius: var(--r-pill); background: var(--glass-fill-2); border: 1px solid var(--glass-stroke); box-shadow: inset 0 1px 0 var(--glass-highlight), var(--glass-shadow-sm); color: var(--fg-strong); font-family: var(--ff-mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; transition: background var(--dur-fast), color var(--dur-fast), border-color var(--dur-fast); }
.k-present__x[hidden] { display: none; }
body.k-present .k-present__x { display: inline-flex; align-items: center; }
.k-present__x:hover { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
/* measure and section labels (kota style) */
.k-kota--meas { background: rgba(11, 14, 19, .9); font-weight: 500; }
.k-kota--sec { background: rgba(11, 14, 19, .82); font-size: 11px; }
body.k-meas-on .k-stage canvas { cursor: crosshair; }
@media (max-width: 1799px) and (min-width: 821px) {
  body.k-wide .k-dock__t { display: none; }
  body.k-wide .k-tool span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  body.k-wide .k-tool { padding: 0 11px; }
}

/* ---- Panel sa opcijama -------------------------------------------------------------- */
.k-panel {
  position: fixed; right: var(--k-gap); top: calc(var(--k-top) + var(--k-gap)); bottom: var(--k-gap); z-index: var(--z-panel);
  width: var(--k-panel-w);
  display: flex; flex-direction: column;
  border-radius: var(--r-l); overflow: hidden;
  transform: translateX(calc(102% + var(--k-gap))); transition: transform 420ms var(--ease), width 420ms var(--ease);
}
.k-panel.is-open { transform: none; }
/* Panel bez zamućenja (budžet kadra: zamućenje najveće ploče košta ~1,5–3 ms po kadru nad
   živom scenom — izmereno u _qa/forged/konf); gušća ispuna --glass-fill-2 = L1 ploča. */
.k-panel { background: var(--glass-fill-2); -webkit-backdrop-filter: none; backdrop-filter: none; }
body.k-wide .k-panel { width: var(--k-panel-wide); }
.k-grip { display: none; }
.k-panel__head { display: flex; align-items: baseline; gap: 12px; padding: 24px 22px 15px 26px; border-bottom: 1px solid var(--line); }
.k-panel__no { font-size: var(--t-sm); color: var(--accent); }
.k-panel__head h2 { flex: 1; font-family: var(--ff-display); font-weight: 700; font-size: 1.3rem; line-height: 1.15; letter-spacing: -.01em; color: var(--fg-strong); }
.k-panel__x { align-self: center; width: 34px; height: 34px; display: grid; place-items: center; border-radius: 50%; color: var(--fg-muted); transition: background var(--dur-fast), color var(--dur-fast); }
.k-panel__x svg { width: 20px; height: 20px; }
.k-panel__x:hover { color: var(--accent); background: var(--k-hover); }
.k-panel__body { flex: 1; overflow-y: auto; padding: 18px 22px 30px; overscroll-behavior: contain; }

.k-h { margin: 22px 0 10px; font-family: var(--ff-mono); font-weight: 500; font-size: 11.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--fg-strong); }
.k-h span { color: var(--fg-faint); text-transform: none; letter-spacing: .02em; margin-left: 6px; }
.k-panel__body > .k-h:first-child { margin-top: 2px; }
.k-note { margin-top: 12px; font-size: var(--t-sm); line-height: 1.5; color: var(--fg-muted); }
.k-note--warn { padding: 10px 12px; border-left: 2px solid var(--brand); border-radius: 0 var(--r-s) var(--r-s) 0; background: var(--accent-soft); color: var(--fg); }
.k-note--bad { padding: 10px 12px; border-left: 2px solid var(--danger); border-radius: 0 var(--r-s) var(--r-s) 0; background: color-mix(in srgb, var(--danger) 9%, transparent); color: var(--fg); }
.k-note--muted { margin: 0 0 12px; font-family: var(--ff-mono); font-size: 11px; letter-spacing: .04em; text-transform: uppercase; color: var(--fg-faint); }
.k-hint { display: flex; align-items: flex-start; gap: 8px; margin: 10px 0 2px; font-size: var(--t-xs); line-height: 1.45; color: var(--fg-muted); }
.k-hint svg { flex: none; width: 16px; height: 16px; margin-top: 1px; color: var(--accent); }
.k-fam { margin: 12px 0 6px; font-size: var(--t-xs); color: var(--fg-faint); }
.k-linkb { font-size: var(--t-sm); font-weight: 500; color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.k-chip {
  display: inline-flex; align-items: center; min-height: 36px; padding: 0 14px;
  border: 1px solid var(--glass-stroke); border-radius: var(--r-pill);
  background: var(--k-well); box-shadow: inset 0 1px 0 var(--glass-highlight);
  font-size: var(--t-sm); font-weight: 500; color: var(--fg-strong);
  transition: border-color var(--dur-fast), color var(--dur-fast), background var(--dur-fast);
}
.k-chip:hover { border-color: var(--accent-line); background: var(--k-well-2); color: var(--accent); }

.k-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 12px; }
.k-grid--3 { grid-template-columns: repeat(3, 1fr); gap: 10px 8px; }
.k-grid--types { grid-template-columns: repeat(3, 1fr); gap: 10px 8px; }
.k-grid--types .k-opt__l small { display: none; }
.k-opt { position: relative; display: block; text-align: left; }
/* uzorci materijala / profila: staklene pločice sa zaobljenjem --r-s */
.k-opt__img { display: block; aspect-ratio: 9 / 7; border-radius: var(--r-s); background: var(--surface-3); border: 1px solid var(--glass-stroke); box-shadow: inset 0 1px 0 var(--glass-highlight); overflow: hidden; transition: border-color var(--dur-fast), box-shadow var(--dur-fast); }
.k-opt__img img, .k-opt__img svg { width: 100%; height: 100%; object-fit: cover; }
.k-opt__img--svg { display: grid; place-items: center; background: var(--k-well); color: var(--fg-muted); }
.k-opt__img--svg svg { width: 78%; height: auto; }
.k-opt__l { display: block; margin-top: 6px; font-size: var(--t-sm); line-height: 1.3; font-weight: 500; color: var(--fg-strong); }
.k-opt__l small { display: block; font-weight: 400; font-size: var(--t-xs); color: var(--fg-muted); margin-top: 1px; }
.k-opt:hover .k-opt__img { border-color: var(--accent-line); }
.k-opt.is-sel .k-opt__img { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent), 0 0 0 3px var(--accent-soft); }
.k-opt.is-sel .k-opt__img--svg { color: var(--accent); background: var(--accent-soft); }
.k-opt.is-warn .k-opt__l small { color: var(--danger); }
.k-opt[disabled] { cursor: not-allowed; }
.k-opt[disabled] .k-opt__img { opacity: .38; filter: grayscale(1); }
.k-opt[disabled] .k-opt__l { color: var(--fg-faint); }
.k-check {
  position: absolute; top: -7px; right: -7px; width: 22px; height: 22px; border-radius: 50%;
  display: grid; place-items: center; background: var(--brand); color: var(--brand-ink);
  box-shadow: 0 0 0 2px var(--glass-fill-solid);
}
.k-check svg { width: 13px; height: 13px; }

/* segmenti i pod-kartice: staklene pilule u staklu (ispuna --k-well, bez zamućenja) */
.k-seg { display: flex; flex-wrap: wrap; gap: 4px; }
.k-seg button {
  flex: 1 1 auto; min-height: 38px; padding: 6px 12px;
  border: 1px solid var(--glass-stroke); border-radius: var(--r-pill);
  background: var(--k-well); box-shadow: inset 0 1px 0 var(--glass-highlight);
  font-size: var(--t-sm); font-weight: 500; color: var(--fg-strong);
  transition: background var(--dur-fast), border-color var(--dur-fast), color var(--dur-fast);
}
.k-seg button:hover { border-color: var(--accent-line); background: var(--k-well-2); }
.k-seg button.is-sel { background: var(--fg-strong); border-color: var(--fg-strong); color: var(--bg); box-shadow: none; }
.k-seg button[disabled] { opacity: .4; cursor: not-allowed; }
.k-range + .k-seg { margin-top: 12px; }

.k-subtabs { display: flex; gap: 4px; padding: 4px; border: 1px solid var(--glass-stroke); border-radius: var(--r-pill); background: var(--k-well); box-shadow: inset 0 1px 0 var(--glass-highlight); margin-bottom: 6px; }
.k-subtabs button { flex: 1; min-height: 34px; border-radius: var(--r-pill); font-family: var(--ff-mono); font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--fg-muted); transition: background var(--dur-fast), color var(--dur-fast); }
.k-subtabs button:hover { color: var(--fg-strong); background: var(--k-hover); }
.k-subtabs button.is-sel { background: var(--fg-strong); color: var(--bg); }

.k-play {
  display: flex; align-items: center; gap: 10px; width: 100%; margin-top: 12px; padding: 11px 14px;
  border: 1px solid var(--glass-stroke); border-radius: var(--r-pill); background: var(--k-well); box-shadow: inset 0 1px 0 var(--glass-highlight); color: var(--fg-strong);
  transition: background var(--dur-fast), color var(--dur-fast), border-color var(--dur-fast);
}
.k-play svg { flex: none; width: 20px; height: 20px; }
.k-play span { font-family: var(--ff-display); font-weight: 600; font-size: var(--t-sm); }
.k-play small { margin-left: auto; font-family: var(--ff-mono); font-size: 10.5px; opacity: .8; }
.k-play:hover, .k-play.is-on { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); box-shadow: none; }

.k-cap { margin-top: 14px; padding: 11px 14px 12px; border: 1px solid var(--glass-stroke); border-left: 3px solid #2f9e6b; border-radius: 0 var(--r-s) var(--r-s) 0; background: var(--k-well); }
.k-cap b { display: block; font-family: var(--ff-mono); font-weight: 500; font-size: 12px; line-height: 1.45; color: var(--fg-strong); }
.k-cap small { display: block; margin: 3px 0 7px; font-size: var(--t-xs); line-height: 1.45; color: var(--fg-muted); }
.k-cap.is-bad { border-left-color: var(--danger); }
.k-cap.is-bad small { color: var(--danger); }

.k-rows { border-top: 1px solid var(--line); margin-top: 14px; }
.k-rows--det { margin-top: 10px; }
.k-sw { display: flex; align-items: flex-start; gap: 12px; width: 100%; padding: 12px 0; text-align: left; border-bottom: 1px solid var(--line); }
.k-sw__t { flex: none; position: relative; width: 38px; height: 22px; margin-top: 1px; border-radius: 999px; background: var(--steel-200); transition: background var(--dur-fast); }
html[data-theme="dark"] .k-sw__t { background: var(--surface-3); }
.k-sw__t i { position: absolute; top: 2px; left: 2px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .25); transition: transform var(--dur-fast) var(--ease); }
.k-sw.is-on .k-sw__t { background: var(--brand); }
.k-sw.is-on .k-sw__t i { transform: translateX(16px); }
.k-sw__l { font-size: var(--t-base); font-weight: 500; line-height: 1.35; color: var(--fg-strong); }
.k-sw__l small { display: block; font-weight: 400; font-size: var(--t-sm); line-height: 1.45; color: var(--fg-muted); margin-top: 2px; }
.k-sw[disabled] { opacity: .5; cursor: default; }
.k-det { display: flex; align-items: flex-start; gap: 8px; border-bottom: 1px solid var(--line); }
.k-det__m { flex: 1; min-width: 0; }
.k-det .k-sw { border-bottom: 0; }
.k-det__x { padding: 0 0 12px 50px; }
.k-det__x small { display: block; margin-top: 6px; font-family: var(--ff-mono); font-size: 10.5px; color: var(--fg-faint); }
.k-det__x .k-seg button { min-height: 32px; padding: 4px 10px; flex: 0 0 auto; }
.k-det__b {
  flex: none; display: inline-flex; align-items: center; gap: 5px; margin-top: 10px; height: 30px; padding: 0 10px;
  border: 1px solid var(--glass-stroke); border-radius: var(--r-pill); background: var(--k-well); box-shadow: inset 0 1px 0 var(--glass-highlight);
  font-family: var(--ff-mono); font-size: 10.5px; letter-spacing: .04em; text-transform: uppercase; color: var(--fg-strong);
  transition: background var(--dur-fast), border-color var(--dur-fast), color var(--dur-fast);
}
.k-det__b svg { width: 15px; height: 15px; }
.k-det__b:hover, .k-det.is-cur .k-det__b { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
.k-det.is-cur { background: var(--accent-soft); box-shadow: -22px 0 0 var(--accent-soft), 22px 0 0 var(--accent-soft); }

.k-zones { display: grid; gap: 2px; margin: 10px 0 4px; }
.k-zones button { display: flex; align-items: center; gap: 10px; padding: 7px 0; font-size: var(--t-base); text-align: left; color: var(--fg); }
.k-zones i { flex: none; width: 18px; height: 18px; border-radius: 50%; border: 1.5px solid var(--fg-faint); display: grid; place-items: center; }
.k-zones .is-sel { color: var(--fg-strong); font-weight: 500; }
.k-zones .is-sel i { border-color: var(--accent); }
.k-zones .is-sel i::after { content: ''; width: 10px; height: 10px; border-radius: 50%; background: var(--brand); }

/* RAL / boje stolarije / boje fasade: staklene pilule sa okruglim uzorkom 36 px,
   mono šifra i naziv u dva reda (uzorak zauzima oba reda mreže) */
.k-ral { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.k-ralb {
  position: relative; display: grid; grid-template-columns: 36px minmax(0, 1fr); column-gap: 10px; align-items: center; align-content: center;
  min-height: 50px; padding: 5px 12px 5px 6px; text-align: left;
  border: 1px solid var(--glass-stroke); border-radius: var(--r-pill); background: var(--k-well); box-shadow: inset 0 1px 0 var(--glass-highlight);
  transition: border-color var(--dur-fast), box-shadow var(--dur-fast), background var(--dur-fast);
}
.k-ralb i, .k-ralb__s { display: block; grid-row: 1 / span 2; width: 36px; height: 36px; border-radius: 50%; object-fit: cover; border: 1px solid var(--glass-stroke); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25); }
.k-ralb b { display: block; grid-column: 2; min-width: 0; font-family: var(--ff-mono); font-weight: 500; font-size: 10.5px; letter-spacing: .02em; line-height: 1.3; color: var(--fg-strong); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.k-ralb span { display: block; grid-column: 2; min-width: 0; font-size: 11px; line-height: 1.25; color: var(--fg-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.k-ralb:hover { border-color: var(--accent-line); background: var(--k-well-2); }
.k-ralb.is-sel { border-color: var(--accent); background: var(--k-well-2); box-shadow: inset 0 0 0 1px var(--accent), 0 0 0 3px var(--accent-soft); }
.k-ralb .k-check { top: -6px; right: -4px; }
.k-ral--frames { grid-template-columns: 1fr 1fr; gap: 10px 8px; }
.k-ralb--big { grid-template-columns: 44px minmax(0, 1fr); min-height: 58px; }
.k-ralb--big i { width: 44px; height: 44px; }
.k-ralb--big b { font-family: var(--ff-body); font-size: var(--t-sm); white-space: normal; }

.k-range label { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 12px; font-size: var(--t-sm); font-weight: 500; color: var(--fg-strong); }
.k-range output { font-family: var(--ff-mono); font-size: var(--t-sm); color: var(--accent); }
.k-range--time label { justify-content: flex-start; margin-top: 0; }
.k-range--time output { font-size: 1.25rem; }
.k-sun { width: 24px; height: 24px; color: var(--accent); }
.k-range input[type=range] { -webkit-appearance: none; appearance: none; width: 100%; height: 30px; background: transparent; cursor: pointer; }
.k-range input[type=range]::-webkit-slider-runnable-track { height: 3px; background: linear-gradient(90deg, var(--brand), var(--line-strong)); }
.k-range input[type=range]::-moz-range-track { height: 3px; background: var(--line-strong); }
.k-range input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; width: 20px; height: 20px; margin-top: -9px; border-radius: 50%; background: var(--surface); border: 2px solid var(--brand); }
.k-range input[type=range]::-moz-range-thumb { width: 16px; height: 16px; border-radius: 50%; background: var(--surface); border: 2px solid var(--brand); }
.k-range input[type=range]:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.k-range__s { display: flex; justify-content: space-between; font-family: var(--ff-mono); font-size: 10.5px; color: var(--fg-faint); }
.k-dim + .k-dim label { margin-top: 6px; }

.k-plate { padding: 14px 16px 10px; border-radius: var(--r-m); background: var(--k-well); border: 1px solid var(--glass-stroke); box-shadow: inset 0 1px 0 var(--glass-highlight); background-image: linear-gradient(var(--grid-line) 1px, transparent 1px), linear-gradient(90deg, var(--grid-line) 1px, transparent 1px); background-size: 20px 20px; }
.k-sec { width: 100%; height: auto; }
.k-sec__t text { font-family: var(--ff-mono); font-size: 11px; fill: var(--fg); }
.k-sec--big .k-sec__t text { font-size: 15px; }
.k-dims { display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--line); }
.k-dims dt { font-family: var(--ff-mono); font-size: 10px; letter-spacing: .06em; text-transform: uppercase; color: var(--fg-faint); }
.k-dims dd { font-family: var(--ff-mono); font-size: var(--t-sm); color: var(--fg-strong); }
.k-inset { border: 1px solid var(--glass-stroke); border-radius: var(--r-m); background: var(--surface-3); overflow: hidden; }
.k-inset canvas { display: block; width: 100%; height: auto; aspect-ratio: 8 / 5; }

/* ---- Korak 06: specifikacija i upit (sažetak u staklenoj kartici sa jezičkom
        „Ukupno m²“ — vrednost prepisana iz podnožja tabele krova; tabele u punim
        L1 pločama, jer su gust tekst) ----------------------------------------------- */
.k-spechead { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
.k-spechead .mono { font-size: var(--t-sm); color: var(--accent); }
.k-spechead__t { font-size: var(--t-xs); color: var(--fg-faint); font-family: var(--ff-mono); text-transform: uppercase; letter-spacing: .06em; }
.k-sum { display: grid; gap: 0; border-top: 1px solid var(--line); }
.k-sum div { display: grid; grid-template-columns: 130px 1fr; gap: 12px; padding: 7px 0; border-bottom: 1px solid var(--line); }
.k-sum div:last-child { border-bottom: 0; }
.k-sum dt { font-family: var(--ff-mono); font-size: 10.5px; letter-spacing: .06em; text-transform: uppercase; color: var(--fg-faint); padding-top: 2px; }
.k-sum dd { font-size: var(--t-sm); color: var(--fg-strong); }
.k-card .k-note { margin-bottom: 0; }
.k-tw { margin: 14px 0 0; padding: 12px 14px 6px; border-radius: var(--r-m); background: var(--surface); border: 1px solid var(--glass-stroke); box-shadow: inset 0 1px 0 var(--glass-highlight); overflow-x: auto; -webkit-overflow-scrolling: touch; }
.k-tw + .k-tw { margin-top: 12px; }
.k-tbl { width: 100%; min-width: 560px; border-collapse: collapse; font-size: 12.5px; font-variant-numeric: tabular-nums; }
.k-tbl caption { padding: 0 0 8px; text-align: left; font-family: var(--ff-mono); font-weight: 500; font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--fg-strong); }
.k-tbl th, .k-tbl td { padding: 7px 8px; border-bottom: 1px solid var(--line); vertical-align: top; text-align: left; }
.k-tbl thead th { font-family: var(--ff-mono); font-weight: 400; font-size: 10px; letter-spacing: .05em; text-transform: uppercase; color: var(--fg-faint); border-bottom-color: var(--line-strong); white-space: nowrap; }
.k-tbl tbody th, .k-tbl tfoot th { font-weight: 500; color: var(--fg-strong); }
.k-tbl th[scope="row"], .k-tbl thead th:first-child { position: sticky; left: 0; z-index: 1; background: var(--surface); padding-left: 0; min-width: 132px; }
.k-tbl .num { text-align: right; font-family: var(--ff-mono); font-size: 12px; white-space: nowrap; color: var(--fg-strong); }
.k-tbl thead .num { color: var(--fg-faint); }
.k-tbl tfoot th, .k-tbl tfoot td { border-top: 1px solid var(--line-strong); border-bottom: 0; font-weight: 600; }
.k-tbl .k-sub td { padding-top: 0; padding-left: 0; font-family: var(--ff-mono); font-size: 10.5px; color: var(--fg-muted); white-space: normal; }
.k-side { display: inline-block; margin-left: 4px; padding: 0 5px; border: 1px solid var(--line-strong); border-radius: 3px; font-family: var(--ff-mono); font-weight: 400; font-size: 9.5px; letter-spacing: .04em; color: var(--fg-muted); vertical-align: 1px; }
.k-fn { margin-top: 8px; font-size: var(--t-xs); line-height: 1.45; color: var(--fg-muted); }
.k-as { margin-top: 18px; border-top: 1px solid var(--line); }
.k-as summary { padding: 12px 0; cursor: pointer; font-family: var(--ff-mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--fg-strong); }
.k-as summary:hover { color: var(--accent); }
.k-as dl { display: grid; gap: 0; padding-bottom: 6px; }
.k-as dl div { display: grid; grid-template-columns: minmax(120px, 42%) 1fr; gap: 12px; padding: 6px 0; border-bottom: 1px solid var(--line); font-size: var(--t-xs); }
.k-as dt { color: var(--fg-muted); }
.k-as dd { font-family: var(--ff-mono); color: var(--fg-strong); }
.k-acts { display: grid; gap: 10px; margin-top: 18px; }
.k-acts__row { display: flex; flex-wrap: wrap; gap: 6px; }
.k-list { margin-top: 26px; padding-top: 4px; border-top: 1px solid var(--line-strong); }
.k-list__l { display: grid; gap: 0; margin: 4px 0 12px; }
.k-list__l li { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.k-list__n { flex: none; font-size: 11px; color: var(--fg-faint); }
.k-list__b { flex: 1; min-width: 0; }
.k-list__b b { display: block; font-size: var(--t-sm); font-weight: 500; color: var(--fg-strong); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.k-list__b small { display: block; font-size: 10.5px; color: var(--fg-faint); }
.k-list__x { flex: none; width: 30px; height: 30px; display: grid; place-items: center; color: var(--fg-muted); }
.k-list__x svg { width: 16px; height: 16px; }
.k-list__x:hover { color: var(--danger); }

/* ---- Inspektor detalja ------------------------------------------------------------- */
.k-ins {
  position: fixed; left: calc(var(--k-rail-w) + var(--k-gap)); top: calc(var(--k-top) + var(--k-gap)); z-index: calc(var(--z-panel) + 1);
  width: 340px; max-height: calc(100vh - var(--k-top) - 100px);
  display: flex; flex-direction: column;
  border-radius: var(--r-l); overflow: hidden;
  transform: translateX(calc(-100% - var(--k-rail-w) - 40px)); visibility: hidden; transition: transform 420ms var(--ease), visibility 0s 420ms;
}
.k-ins.is-open { transform: none; visibility: visible; transition: transform 420ms var(--ease), visibility 0s; }
.k-ins__head { display: flex; align-items: baseline; gap: 10px; padding: 16px 16px 11px 20px; border-bottom: 1px solid var(--line); }
.k-ins__head .mono { font-size: 10.5px; letter-spacing: .1em; color: var(--accent); }
.k-ins__head h3 { flex: 1; font-family: var(--ff-display); font-weight: 700; font-size: 1.08rem; color: var(--fg-strong); }
.k-ins__x { align-self: center; width: 30px; height: 30px; display: grid; place-items: center; border-radius: 50%; color: var(--fg-muted); transition: background var(--dur-fast), color var(--dur-fast); }
.k-ins__x svg { width: 18px; height: 18px; }
.k-ins__x:hover { color: var(--accent); background: var(--k-hover); }
.k-ins__body { overflow-y: auto; padding: 14px 16px 18px; overscroll-behavior: contain; }
.k-ins__mat { margin-top: 7px; font-family: var(--ff-mono); font-size: 10.5px; color: var(--fg-faint); }
.k-ins .k-h { margin: 16px 0 8px; }
.k-how { display: block; width: 100%; height: auto; border-radius: var(--r-s); background: var(--k-well); border: 1px solid var(--glass-stroke); }
.k-how path, .k-how circle { fill: none; stroke-linecap: round; stroke-linejoin: round; }
.k-how .w { fill: #eadfc8; stroke: #b79f73; stroke-width: 1.2; }
.k-how .m { fill: #dccbc0; stroke: #a88d7c; stroke-width: 1.2; }
.k-how .n { fill: #eef3f9; stroke: #b7c3d1; stroke-width: 1.2; }
.k-how .f { fill: #4b5563; stroke: none; }
.k-how .s { stroke: #5b6470; stroke-width: 3.2; }
.k-how .g { stroke: #5b6470; stroke-width: 3; }
.k-how .p { stroke: var(--k-ink); stroke-width: 3.4; }
.k-how .pf { fill: rgba(6, 80, 197, .14); }
.k-how .pw { fill: #fff; stroke-width: 2.4; }
.k-how .x { stroke: #7b8794; stroke-width: 1.4; }
.k-how .a { stroke: #3b82c4; stroke-width: 1.7; stroke-dasharray: 4 3; }
.k-how__l { opacity: 0; transition: opacity 420ms var(--ease); }
.k-how__l.is-on { opacity: 1; }
.k-steps { margin-top: 10px; display: grid; gap: 2px; }
.k-steps li { opacity: .42; transition: opacity 300ms; }
.k-steps li.is-on { opacity: 1; }
.k-steps button { display: flex; gap: 10px; width: 100%; padding: 7px 8px 7px 0; text-align: left; font-size: var(--t-sm); line-height: 1.45; color: var(--fg); border-radius: var(--r-s); box-shadow: inset 2px 0 0 transparent; }
.k-steps b { flex: none; display: grid; place-items: center; width: 22px; height: 22px; margin-left: 8px; border-radius: 50%; border: 1px solid var(--line-strong); font-family: var(--ff-mono); font-weight: 500; font-size: 11px; }
.k-steps li.is-cur button { box-shadow: inset 2px 0 0 var(--brand); background: var(--accent-soft); color: var(--fg-strong); }
.k-steps li.is-on b { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }

/* ---- Lupa, vodič, čekanje, poruka, greška (pune površine — van budžeta zamućenja) ---- */
.k-loupe { position: fixed; left: 0; top: 0; z-index: calc(var(--z-overlay) + 2); pointer-events: none; border: 1px solid var(--glass-stroke); border-radius: var(--r-s); background: var(--glass-fill-solid); box-shadow: inset 0 1px 0 var(--glass-highlight), var(--glass-shadow-sm); padding: 5px; }
.k-loupe[hidden] { display: none; }
.k-loupe canvas { display: block; width: 190px; height: 190px; border-radius: calc(var(--r-s) - 4px); }
.k-loupe span { position: absolute; right: 8px; bottom: 8px; padding: 1px 7px; border-radius: var(--r-pill); background: rgba(17, 21, 28, .78); color: #fff; font-size: 10.5px; }
.k-tour { position: fixed; inset: 0; z-index: calc(var(--z-overlay) + 5); }
.k-tour[hidden] { display: none; }
.k-tour__hole { position: absolute; border-radius: var(--r-s); box-shadow: 0 0 0 9999px rgba(10, 13, 18, .62), 0 0 0 2px var(--arc-200); transition: left 320ms var(--ease), top 320ms var(--ease), width 320ms var(--ease), height 320ms var(--ease); }
.k-tour__card { position: absolute; padding: 18px 20px 16px; border-radius: var(--r-m); background: var(--glass-fill-solid); border: 1px solid var(--glass-stroke); box-shadow: inset 0 1px 0 var(--glass-highlight), var(--glass-shadow); transition: left 320ms var(--ease), top 320ms var(--ease); }
.k-tour__n { font-size: 11px; letter-spacing: .08em; color: var(--accent); }
.k-tour__t { margin: 6px 0 14px; font-size: var(--t-base); line-height: 1.5; color: var(--fg-strong); max-width: none; }
.k-tour__b { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
/* Foto: tražilo. Veo preko scene isečen kapsulom (maska na velu — platno ostaje
   netaknuto), tanki obod kapsule i pilula sa napretkom ispod nje. */
.k-wait {
  --kw-w: min(72vw, 1180px); --kw-h: min(54vh, calc(var(--kw-w) * .62)); --kw-y: calc(50% - 5vh);
  position: fixed; inset: 0; z-index: var(--z-overlay); display: grid; place-items: end center; padding-bottom: 10vh; background: transparent;
}
.k-wait[hidden] { display: none; }
.k-wait::before {
  content: ''; position: absolute; inset: 0; background: color-mix(in srgb, var(--bg) 66%, transparent);
  -webkit-mask-image: linear-gradient(#000 0 0), linear-gradient(#000 0 0), radial-gradient(circle closest-side, #000 99%, transparent 100%), radial-gradient(circle closest-side, #000 99%, transparent 100%);
          mask-image: linear-gradient(#000 0 0), linear-gradient(#000 0 0), radial-gradient(circle closest-side, #000 99%, transparent 100%), radial-gradient(circle closest-side, #000 99%, transparent 100%);
  -webkit-mask-size: 100% 100%, calc(var(--kw-w) - var(--kw-h)) var(--kw-h), var(--kw-h) var(--kw-h), var(--kw-h) var(--kw-h);
          mask-size: 100% 100%, calc(var(--kw-w) - var(--kw-h)) var(--kw-h), var(--kw-h) var(--kw-h), var(--kw-h) var(--kw-h);
  -webkit-mask-position: 0 0, 50% var(--kw-y), calc(50% - (var(--kw-w) - var(--kw-h)) / 2) var(--kw-y), calc(50% + (var(--kw-w) - var(--kw-h)) / 2) var(--kw-y);
          mask-position: 0 0, 50% var(--kw-y), calc(50% - (var(--kw-w) - var(--kw-h)) / 2) var(--kw-y), calc(50% + (var(--kw-w) - var(--kw-h)) / 2) var(--kw-y);
  -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat;
  -webkit-mask-composite: xor, source-over, source-over, source-over;
          mask-composite: exclude, add, add, add;
}
.k-wait::after {
  content: ''; position: absolute; left: calc(50% - var(--kw-w) / 2); top: calc(var(--kw-y) - var(--kw-h) / 2); width: var(--kw-w); height: var(--kw-h);
  border-radius: var(--r-pill); box-shadow: inset 0 0 0 1px var(--glass-highlight), 0 0 0 1px var(--glass-stroke); pointer-events: none;
}
.k-wait > div { position: relative; z-index: 1; width: min(300px, 76vw); padding: 16px 20px 18px; border-radius: var(--r-m); background: var(--glass-fill-solid); border: 1px solid var(--glass-stroke); box-shadow: inset 0 1px 0 var(--glass-highlight), var(--glass-shadow); }
.k-wait p { margin-bottom: 10px; font-size: var(--t-xs); letter-spacing: .08em; text-transform: uppercase; color: var(--fg-strong); }
.k-wait .k-loader__bar { border-radius: 2px; }
.k-toast {
  position: fixed; left: 50%; bottom: 84px; z-index: var(--z-overlay);
  transform: translate(-50%, 16px); opacity: 0; pointer-events: none;
  padding: 11px 18px; border-radius: var(--r-pill); background: var(--glass-fill-solid); border: 1px solid var(--glass-stroke); box-shadow: inset 0 1px 0 var(--glass-highlight), var(--glass-shadow-sm); color: var(--fg-strong); font-size: var(--t-sm);
  transition: opacity var(--dur), transform var(--dur) var(--ease);
}
.k-toast.is-on { opacity: 1; transform: translate(-50%, 0); }
.k-fail { position: fixed; inset: 0; z-index: var(--z-overlay); display: grid; place-items: center; padding: 24px; background: var(--surface); }
.k-fail[hidden] { display: none; }
.k-fail > div { max-width: 520px; }
.k-fail h2 { font-family: var(--ff-display); font-size: var(--t-xl); margin-bottom: 12px; color: var(--fg-strong); }
.k-fail p { margin-bottom: 18px; color: var(--fg-muted); }

/* ---- Bez WebGL-a: slika tipa objekta, koraci i specifikacija rade ------------------- */
.k-still, .k-noglnote { display: none; }
body.k-nogl .k-stage canvas, body.k-nogl .k-hotspots, body.k-nogl .k-dock, body.k-nogl .k-help, body.k-nogl .k-kote { display: none; }
body.k-nogl .k-still:not([hidden]) {
  display: block; position: absolute; top: 50%; left: calc(var(--k-rail-w) + (100vw - var(--k-rail-w) - var(--k-right)) / 2);
  width: min(78%, calc(100vw - var(--k-rail-w) - var(--k-right) - 48px)); height: auto; max-height: 70%; object-fit: contain;
  transform: translate(-50%, -50%);
}
body.k-nogl .k-noglnote:not([hidden]) {
  display: block; position: absolute; left: calc(var(--k-rail-w) + 20px); bottom: 20px; max-width: 420px;
  padding: 12px 16px 12px 14px; border-radius: var(--r-s); background: var(--glass-fill-2); border: 1px solid var(--glass-stroke); border-left: 3px solid var(--brand); box-shadow: inset 0 1px 0 var(--glass-highlight), var(--glass-shadow-sm);
}
.k-noglnote .label { color: var(--accent); margin-bottom: 4px; }
.k-noglnote p:last-child { font-size: var(--t-sm); color: var(--fg-muted); }

.k-print { display: none; }
/* štampa ostaje crno na belom: staklene ploče tabela i zaobljenja napomena se ne prenose u list (print.css nosi mere) */
@media print {
  .k-tw { background: none; border: 0; border-radius: 0; box-shadow: none; }
  .k-note--warn, .k-note--bad, .k-cap, .k-plate, .k-opt__img { border-radius: 0; box-shadow: none; }
}

/* ---- Telefon: donja traka sa koracima, list koji se izvlači --------------------------- */
@media (max-width: 820px) {
  .k-body { --k-rail-h: 60px; --k-rail-w: 0px; }
  body.k-open, body.k-open.k-wide { --k-right: 0px; }
  .k-top { gap: 6px; padding-inline: 12px; }
  .k-top__brand { margin-right: 0; }
  .k-top__brand img { height: 34px; }
  .k-top__back, .k-top__list { height: 38px; padding: 0 10px; }
  .k-top .themesw { width: 36px; height: 36px; }
  .k-top .langsw { height: 36px; padding: 0 10px; gap: 6px; }
  .k-top__cta { padding: 0 12px; height: 38px; font-size: 12px; }
  .k-top__cta svg { display: none; }

  /* donja traka sa koracima: staklo sa gornjim zaobljenjem; indikator je kratka pilula iznad broja */
  .k-rail {
    top: auto; bottom: 0; left: 0; right: 0; width: auto;
    flex-direction: row; padding: 0 0 env(safe-area-inset-bottom, 0px);
    height: calc(var(--k-rail-h) + env(safe-area-inset-bottom, 0px));
    border: 0; border-top: 1px solid var(--glass-stroke); border-radius: var(--r-m) var(--r-m) 0 0; z-index: calc(var(--z-panel) + 1);
    box-shadow: inset 0 1px 0 var(--glass-highlight), 0 -12px 32px rgba(10, 14, 20, .10);
  }
  .k-rail__bar { top: 7px; left: calc((var(--i, 0) + .5) * 100% / 6 - 10px); width: 20px; height: 3px; transform: none; transition: left 380ms var(--ease-cine, var(--ease)), opacity 200ms; }
  .k-rail__b { flex: 1 1 0; height: var(--k-rail-h); margin: 0; grid-template-columns: 1fr; justify-items: center; align-content: center; gap: 3px; padding: 0 2px; border-radius: 0; text-align: center; }
  .k-rail__b.is-active { background: none; box-shadow: none; }
  .k-rail__b.is-secondary { border-top: 0; }
  .k-rail__n { font-size: 12.5px; }
  .k-rail__l { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .k-rail__s { display: block; font-family: var(--ff-display); font-weight: 600; font-size: 9.5px; line-height: 1.1; letter-spacing: -.01em; color: var(--fg-strong); white-space: nowrap; max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
  .k-rail__b.is-secondary .k-rail__s { color: var(--fg-muted); font-weight: 500; }

  /* list koji se izvlači: staklena ploča sa ručkom */
  .k-panel {
    top: auto; left: 0; right: 0; width: auto !important; height: 60%;
    bottom: calc(var(--k-rail-h) + env(safe-area-inset-bottom, 0px));
    border: 0; border-top: 1px solid var(--glass-stroke); border-radius: var(--r-l) var(--r-l) 0 0;
    transform: translateY(calc(100% + var(--k-rail-h) + 40px));
  }
  .k-panel.is-drag { transition: none; }
  .k-grip { display: grid; place-items: center; height: 26px; flex: none; touch-action: none; cursor: ns-resize; }
  .k-grip i { width: 48px; height: 5px; border-radius: 5px; background: var(--line-strong); box-shadow: inset 0 1px 0 var(--glass-highlight); }
  .k-panel__head { padding: 2px 16px 10px 18px; }
  .k-panel__head h2 { font-size: 1.1rem; }
  .k-panel__body { padding: 14px 16px 22px; }
  .k-tw { padding: 10px 12px 4px; }
  .k-tbl th[scope="row"], .k-tbl thead th:first-child { min-width: 118px; box-shadow: 1px 0 0 var(--line); }
  .k-det.is-cur { box-shadow: -16px 0 0 var(--accent-soft), 16px 0 0 var(--accent-soft); }
  .k-sum div { grid-template-columns: 104px 1fr; }
  .k-card { padding: 14px 14px 16px; }
  .k-card__tab { right: 14px; }

  /* bez zamućenja na telefonu: backdrop-filter bi traku učinio sadržavajućim blokom za fiksne
     iskačuće menije (.k-pop), pa bi ih overflow-x: auto odsekao; puna ispuna --glass-fill-2 */
  .k-dock {
    left: 10px; right: 10px; transform: none; bottom: calc(var(--k-rail-h) + 10px + env(safe-area-inset-bottom, 0px));
    overflow-x: auto; scrollbar-width: none; border-radius: var(--r-pill); justify-content: flex-start;
    background: var(--glass-fill-2); -webkit-backdrop-filter: none; backdrop-filter: none;
  }
  .k-dock::-webkit-scrollbar { display: none; }
  .k-dock__t { display: none; }
  .k-dock__i { position: static; }
  .k-tool { flex: none; height: 36px; padding: 0 10px; font-size: 10px; letter-spacing: .05em; }
  .k-tool svg { width: 17px; height: 17px; }
  .k-pop { position: fixed; left: 10px; right: 10px; transform: none; bottom: calc(var(--k-rail-h) + 64px + env(safe-area-inset-bottom, 0px)); min-width: 0; z-index: 6; }
  /* brojčanik kamere se na telefonu vraća u listu */
  .k-pop--dial { display: grid; width: auto; height: auto; padding: 8px; border-radius: var(--r-m); }
  .k-pop--dial[hidden] { display: none; }
  .k-pop--dial::before, .k-pop--dial::after { display: none; }
  .k-pop--dial button { position: static; width: 100%; height: auto; margin: 0; padding: 10px 12px; border-radius: var(--r-s); border: 0; background: none; box-shadow: inset 2px 0 0 transparent; transform: none; text-align: left; }
  .k-pop--dial button::before, .k-pop--dial button::after { display: none; }
  .k-pop--dial button b, .k-pop--dial button small { position: static; width: auto; margin: 0; opacity: 1; text-align: left; transform: none; pointer-events: auto; }
  .k-pop--dial button small { margin-top: 1px; font-size: var(--t-xs); }
  .k-pop--dial button:hover, .k-pop--dial button:focus-visible { background: var(--k-hover); border-color: transparent; box-shadow: inset 2px 0 0 transparent; }
  .k-dock__sep { display: none; }
  .k-present__x { right: 10px; top: 10px; height: 36px; }
  .k-help { left: auto; right: 10px; top: 10px; bottom: auto; width: 36px; height: 36px; }
  body.k-open .k-dock, body.k-open .k-help { display: none; }
  .k-hot { width: 38px; height: 38px; }
  .k-kota { font-size: 11px; padding: 2px 6px 1px; }
  .k-readout { left: 10px; right: 56px; top: 10px; max-width: none; padding: 8px 11px 9px; }
  .k-readout b { font-size: 11.5px; }
  body.k-cmp-on .k-readout { top: 54px; }
  .k-cmp__side { top: 10px; max-width: 44%; height: 32px; }
  .k-cmp__side b { width: 30px; height: 32px; }
  #kSwap { top: 50px; height: 28px; padding: 0 10px; font-size: 10.5px; }
  .k-toast { bottom: calc(var(--k-rail-h) + 64px); width: max-content; max-width: 88vw; }
  .k-listpop { right: 10px; left: 10px; width: auto; }
  .k-ins {
    left: 0; right: 0; top: auto; width: auto; max-height: none; height: 62%;
    bottom: calc(var(--k-rail-h) + env(safe-area-inset-bottom, 0px)); z-index: calc(var(--z-panel) + 2);
    border: 0; border-top: 1px solid var(--glass-stroke); border-radius: var(--r-l) var(--r-l) 0 0;
    transform: translateY(calc(100% + var(--k-rail-h) + 40px));
  }
  .k-wait { --kw-w: 86vw; --kw-h: min(38vh, calc(86vw * .66)); --kw-y: calc(50% - 8vh); padding-bottom: calc(var(--k-rail-h) + 76px); }
  body.k-nogl .k-still:not([hidden]) { left: 50%; top: 22%; width: 86%; max-height: 32%; }
  body.k-nogl .k-noglnote:not([hidden]) { left: 10px; right: 10px; top: 10px; bottom: auto; max-width: none; padding: 8px 11px; }
  body.k-nogl .k-noglnote p:last-child { display: none; }
}
@media (min-width: 560px) and (max-width: 820px) {
  .k-grid, .k-grid--3, .k-grid--types { grid-template-columns: repeat(4, 1fr); }
  .k-ral { grid-template-columns: repeat(3, 1fr); }
  .k-ral--frames { grid-template-columns: repeat(3, 1fr); }
  .k-plate, .k-inset { max-width: 520px; }
  .k-grid--types .k-opt__l small { display: none; }
}
@media (max-width: 420px) {
  .k-top { gap: 4px; padding-inline: 10px; }
  .k-top__brand img { height: 28px; }
  .k-top .themesw { width: 34px; height: 34px; }
  .k-top .langsw { height: 34px; padding: 0 8px; gap: 5px; }
  .k-top__back { display: none; }
  .k-top__cta { padding: 0 10px; font-size: 11.5px; }
  .k-grid--3, .k-grid--types { gap: 8px 6px; }
  .k-ral { gap: 6px; }
}

@media (prefers-reduced-motion: reduce) {
  .k-panel, .k-rail__bar, .k-loader, .k-toast, .k-ins, .k-how__l, .k-tour__hole, .k-tour__card, .k-steps li, .k-dock { transition: none; }
}
