/* WattCalc UI: industrial product console */

:root {
  --bg: #08090b;
  --bg-2: #0d1015;
  --panel: #11141a;
  --panel-2: #171b23;
  --panel-3: #1d232d;
  --field: #0d1118;
  --line: #2a303b;
  --line-soft: #202631;
  --txt: #f4f0e7;
  --txt-soft: #beb7a8;
  --txt-dim: #817b70;
  --amber: #ffc247;
  --amber-2: #ffe0a0;
  --amber-ink: #1b1405;
  --red: #ff3448;
  --red-2: #ff7552;
  --red-ink: #210407;
  --flame: linear-gradient(90deg, var(--amber), var(--red-2) 48%, var(--red));
  --flame-soft: linear-gradient(135deg, rgba(255,194,71,.16), rgba(255,52,72,.12));
  --cyan: #45d0b4;
  --blue: #6ca9ff;
  --ok: #62d28f;
  --warn: #ff9a3c;
  --danger: #ff5b5f;

  --display: 'Archivo', system-ui, sans-serif;
  --body: 'Hanken Grotesk', system-ui, sans-serif;
  --mono: 'Spline Sans Mono', ui-monospace, monospace;

  --r: 8px;
  --r-sm: 6px;
  --shadow: 0 26px 70px -46px rgba(0,0,0,.95);
  --shadow-sm: 0 18px 38px -30px rgba(0,0,0,.86);
  --dur: 160ms;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  min-height: 100vh;
  color: var(--txt);
  background: var(--bg);
  font-family: var(--body);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

::selection { color: var(--amber-ink); background: var(--amber); }

.grid-bg {
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background:
    linear-gradient(120deg, rgba(255,194,71,.14), transparent 20%, transparent 68%, rgba(255,52,72,.12)),
    linear-gradient(transparent 0, transparent calc(100% - 1px), rgba(255,255,255,.035) 100%),
    linear-gradient(90deg, transparent 0, transparent calc(100% - 1px), rgba(255,255,255,.03) 100%),
    linear-gradient(180deg, #0d090b, #07080a 70%);
  background-size: 100% 100%, 40px 40px, 40px 40px, 100% 100%;
}
.grid-bg::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    repeating-linear-gradient(135deg, transparent 0 14px, rgba(255,194,71,.045) 14px 15px, transparent 15px 28px),
    repeating-linear-gradient(45deg, transparent 0 32px, rgba(255,52,72,.035) 32px 33px, transparent 33px 66px);
  opacity: .62;
  mask-image: linear-gradient(90deg, transparent, #000 14%, #000 82%, transparent);
}
.grid-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,.08), rgba(0,0,0,.72));
}
body::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: .03;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* Header */
.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 13px clamp(16px, 4vw, 52px);
  border-bottom: 1px solid rgba(255,194,71,.20);
  background:
    linear-gradient(90deg, rgba(255,52,72,.08), transparent 38%, rgba(255,194,71,.06)),
    rgba(8,9,11,.88);
  backdrop-filter: blur(18px);
  box-shadow: 0 14px 34px -30px rgba(0,0,0,.95);
}
.topbar::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 1px;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(255,194,71,.92), rgba(255,52,72,.78), transparent);
  box-shadow: 0 0 18px rgba(255,52,72,.34), 0 0 18px rgba(255,194,71,.22);
}
.runtime-warning {
  position: sticky;
  top: 75px;
  z-index: 49;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px clamp(16px, 4vw, 52px);
  border-bottom: 1px solid rgba(255,91,95,.34);
  color: var(--txt);
  background: rgba(38,12,14,.92);
  box-shadow: 0 18px 34px -28px rgba(0,0,0,.95);
}
.runtime-warning strong {
  flex: none;
  color: #ffb3b5;
  font: 900 12px var(--display);
  text-transform: uppercase;
  letter-spacing: .04em;
}
.runtime-warning span {
  min-width: 0;
  color: rgba(244,240,231,.82);
  font: 700 12px var(--body);
}
.brand { display: flex; align-items: center; gap: 12px; min-width: 0; }
.brand-mark {
  display: grid;
  place-items: center;
  flex: none;
  width: 48px;
  height: 48px;
  border: 1px solid rgba(255,194,71,.32);
  border-radius: var(--r);
  background:
    linear-gradient(145deg, rgba(255,194,71,.18), rgba(255,52,72,.12)),
    rgba(17,20,26,.96);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.10), 0 18px 34px -24px rgba(255,52,72,.85), 0 0 24px rgba(255,194,71,.18);
  overflow: hidden;
}
.brand-mark img { display: block; width: 100%; height: 100%; object-fit: contain; }
.brand-text { display: flex; flex-direction: column; line-height: 1.08; min-width: 0; }
.brand-text strong {
  font-family: var(--display);
  font-size: 19px;
  font-weight: 900;
  letter-spacing: 0;
}
.brand-text small {
  margin-top: 4px;
  color: var(--txt-dim);
  font-size: 11px;
  letter-spacing: 0;
  white-space: nowrap;
}
.topbar-meta { display: flex; align-items: center; justify-content: flex-end; gap: 10px; }

.chip,
.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  padding: 5px 10px;
  border: 1px solid rgba(255,194,71,.30);
  border-radius: 999px;
  color: var(--amber);
  background: linear-gradient(90deg, rgba(255,194,71,.11), rgba(255,52,72,.06));
  font-family: var(--mono);
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0;
  white-space: nowrap;
}
.badge {
  min-height: 24px;
  padding: 4px 9px;
  color: var(--cyan);
  border-color: rgba(69,208,180,.32);
  background: rgba(69,208,180,.07);
}
.badge-link { align-self: flex-start; }

.ghost-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--txt-soft);
  background: rgba(17,20,26,.84);
  font: 700 13px var(--body);
  cursor: pointer;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.06);
  transition: transform var(--dur), background var(--dur), border-color var(--dur), color var(--dur);
}
.ghost-btn:hover {
  color: var(--red-ink);
  border-color: rgba(255,194,71,.78);
  background: var(--flame);
  box-shadow: 0 0 0 1px rgba(255,255,255,.08) inset, 0 16px 36px -22px rgba(255,52,72,.88);
}
#resetBtn::before,
#shopBtn::before {
  content: '';
  width: 16px;
  height: 16px;
  flex: none;
  background: center / contain no-repeat;
}
#resetBtn::before { background-image: url('../assets/brand/ui/icon-reset.svg'); }
#shopBtn::before { background-image: url('../assets/brand/ui/icon-market.svg'); }

/* Layout */
.layout {
  display: grid;
  grid-template-columns: minmax(0, 1.16fr) minmax(390px, .92fr);
  gap: clamp(22px, 2.4vw, 34px);
  align-items: start;
  max-width: 1480px;
  margin: 0 auto;
  padding: clamp(24px, 3vw, 44px) clamp(16px, 4vw, 52px) 70px;
}
.config,
.results-sticky {
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-width: 0;
}
.results-sticky {
  position: sticky;
  top: 88px;
  padding-left: 18px;
}
.results-sticky::before {
  content: '';
  position: absolute;
  left: 0;
  top: 2px;
  bottom: 2px;
  width: 1px;
  background: linear-gradient(180deg, transparent, rgba(255,194,71,.58), rgba(255,52,72,.42), transparent);
  box-shadow: 0 0 18px rgba(255,52,72,.28);
  pointer-events: none;
}

/* Hero */
.config-hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(360px, 1fr) minmax(220px, 260px);
  gap: 22px;
  align-items: stretch;
  min-height: 184px;
  padding: 12px 0 24px;
  border-bottom: 1px solid rgba(255,194,71,.18);
  overflow: hidden;
}
.config-hero::before {
  content: '';
  position: absolute;
  top: -34px;
  right: 10px;
  width: 330px;
  height: 238px;
  background: url('../assets/brand/logo/wattcalc-lockup.svg') right top / contain no-repeat;
  opacity: .045;
  pointer-events: none;
}
.config-hero::after {
  content: '';
  position: absolute;
  right: 0;
  bottom: 0;
  width: min(560px, 62%);
  height: 3px;
  border-radius: 999px 0 0 999px;
  background: var(--flame);
  box-shadow: 0 0 24px rgba(255,52,72,.34), 0 0 18px rgba(255,194,71,.22);
  pointer-events: none;
}
.hero-copy {
  position: relative;
  z-index: 1;
  align-self: center;
}
.hero-kicker,
.presets-label {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: var(--amber);
  font-family: var(--mono);
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}
.hero-kicker::before,
.presets-label::before {
  content: '';
  width: 28px;
  height: 1px;
  background: var(--flame);
  box-shadow: 0 0 12px rgba(255,52,72,.32);
}
.config-hero h1 {
  position: relative;
  z-index: 1;
  max-width: 780px;
  margin: 12px 0 14px;
  color: var(--txt);
  text-shadow: 0 0 34px rgba(255,52,72,.14);
  font-family: var(--display);
  font-size: 50px;
  font-weight: 900;
  line-height: .98;
  letter-spacing: 0;
}
.config-hero h1::after {
  content: '';
  display: block;
  width: 168px;
  height: 3px;
  margin-top: 17px;
  border-radius: 999px;
  background: var(--flame);
  box-shadow: 0 0 18px rgba(255,52,72,.34);
}
.config-hero p {
  position: relative;
  z-index: 1;
  max-width: 69ch;
  color: var(--txt-soft);
  font-size: 15.5px;
}
.hero-console {
  position: relative;
  z-index: 1;
  align-self: stretch;
  min-height: 174px;
  padding: 18px;
  border: 1px solid rgba(255,194,71,.26);
  border-radius: var(--r);
  background:
    linear-gradient(180deg, rgba(255,194,71,.10), rgba(255,52,72,.055) 58%, rgba(255,255,255,0)),
    repeating-linear-gradient(0deg, transparent 0 19px, rgba(255,255,255,.026) 19px 20px),
    var(--panel);
  box-shadow: var(--shadow-sm), inset 0 0 0 1px rgba(255,52,72,.08);
  overflow: hidden;
}
.hero-console::before {
  content: '';
  position: absolute;
  inset: 10px;
  border: 1px solid rgba(255,255,255,.045);
  border-right-color: rgba(255,52,72,.20);
  border-top-color: rgba(255,194,71,.16);
  border-radius: var(--r-sm);
  pointer-events: none;
}
.hero-console::after {
  content: '';
  position: absolute;
  right: -34px;
  bottom: -38px;
  width: 150px;
  height: 150px;
  background: url('../assets/brand/logo/wattcalc-mark.svg') center / contain no-repeat;
  opacity: .10;
}
.console-topline {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--txt-dim);
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}
.console-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--ok);
  box-shadow: 0 0 10px var(--ok);
}
.hero-console > strong {
  position: relative;
  z-index: 1;
  display: block;
  margin: 18px 0 16px;
  color: var(--amber);
  text-shadow: 0 0 24px rgba(255,194,71,.22), 0 0 16px rgba(255,52,72,.16);
  font: 900 38px/.95 var(--display);
  letter-spacing: 0;
}
.console-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.console-grid span {
  min-height: 42px;
  padding: 8px 9px;
  border: 1px solid var(--line-soft);
  border-radius: var(--r-sm);
  color: var(--txt-soft);
  background: rgba(8,9,11,.42);
  font-size: 11.5px;
}
.console-grid b {
  display: block;
  color: var(--txt);
  font: 800 15px var(--mono);
}

/* Presets */
.presets-block { display: flex; flex-direction: column; gap: 11px; }
.presets {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(156px, 1fr));
  gap: 10px;
}
.preset-chip {
  position: relative;
  min-height: 82px;
  padding: 13px 14px 12px;
  border: 1px solid var(--line);
  border-radius: var(--r);
  color: var(--txt);
  background: linear-gradient(180deg, rgba(255,255,255,.035), rgba(255,255,255,0)), var(--panel);
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  text-align: left;
  cursor: pointer;
  overflow: hidden;
  transition: transform var(--dur), border-color var(--dur), background var(--dur);
}
.preset-chip::before {
  content: '';
  position: absolute;
  left: 0;
  top: 12px;
  bottom: 12px;
  width: 2px;
  background: var(--flame);
  box-shadow: 0 0 18px rgba(255,52,72,.28);
}
.preset-chip:hover {
  transform: translateY(-2px);
  border-color: rgba(255,52,72,.42);
  background: linear-gradient(180deg, rgba(255,194,71,.08), rgba(255,52,72,.055)), var(--panel);
  box-shadow: 0 24px 46px -36px rgba(255,52,72,.72);
}
.preset-name {
  color: var(--txt);
  font-family: var(--display);
  font-size: 13.5px;
  font-weight: 800;
  line-height: 1.16;
}
.preset-desc {
  color: var(--txt-dim);
  font-size: 11px;
  line-height: 1.35;
}

/* Shared surfaces */
.card,
.gauge-card,
.advisor-card,
.psu-card,
.shop-card,
.tiers-card,
.energy-card,
.breakdown-card {
  border: 1px solid var(--line);
  border-radius: var(--r);
  background:
    linear-gradient(180deg, rgba(255,255,255,.04), rgba(255,255,255,0) 45%),
    linear-gradient(135deg, rgba(255,194,71,.035), rgba(255,52,72,.022)),
    var(--panel);
  box-shadow: var(--shadow-sm);
}
.card {
  position: relative;
  padding: 0 22px 22px;
  overflow: hidden;
  transition: transform var(--dur), border-color var(--dur), box-shadow var(--dur);
}
.card::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: linear-gradient(var(--amber), var(--red));
  opacity: .86;
  box-shadow: 0 0 18px rgba(255,52,72,.30);
}
.card:hover {
  transform: translateY(-1px);
  border-color: rgba(255,52,72,.38);
  box-shadow: 0 24px 54px -42px rgba(255,52,72,.82), 0 0 0 1px rgba(255,194,71,.08) inset;
}
.section-cpu { --section-art: url('../assets/brand/sections/section-cpu.svg'); }
.section-gpu { --section-art: url('../assets/brand/sections/section-gpu.svg'); }
.section-motherboard { --section-art: url('../assets/brand/sections/section-motherboard.svg'); }
.section-ram { --section-art: url('../assets/brand/sections/section-ram.svg'); }
.section-storage { --section-art: url('../assets/brand/sections/section-storage.svg'); }
.section-cooling { --section-art: url('../assets/brand/sections/section-cooling.svg'); }
.section-extras { --section-art: url('../assets/brand/sections/section-extras.svg'); }
.section-advanced { --section-art: url('../assets/brand/sections/section-advanced.svg'); }
.card > legend,
.card > .field,
.card > .row,
.card > .switch,
.card > .hint,
.card > .multi-rows {
  position: relative;
  z-index: 1;
}
.card > legend {
  display: flex;
  align-items: center;
  gap: 11px;
  width: calc(100% + 44px);
  min-height: 86px;
  margin: 0 -22px 18px;
  padding: 18px 22px 16px;
  border-bottom: 1px solid rgba(255,194,71,.16);
  background:
    linear-gradient(90deg, rgba(255,194,71,.11), rgba(255,52,72,.065), transparent 72%),
    linear-gradient(180deg, rgba(255,255,255,.035), transparent);
}
.card > legend::after {
  content: '';
  flex: 0 1 clamp(118px, 28%, 248px);
  height: 72px;
  margin-left: auto;
  background: var(--section-art) right center / contain no-repeat;
  opacity: .64;
  filter: saturate(1.18) drop-shadow(0 14px 20px rgba(255,52,72,.18)) drop-shadow(0 12px 18px rgba(0,0,0,.28));
  pointer-events: none;
}
.card > legend .ic {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 46px;
  height: 46px;
  border-radius: var(--r);
  border: 1px solid rgba(255,194,71,.20);
  overflow: hidden;
  background: linear-gradient(145deg, rgba(255,194,71,.12), rgba(255,52,72,.07)), rgba(8,9,11,.58);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.08), 0 12px 22px -18px rgba(255,52,72,.72);
}
.card > legend .ic img { display: block; width: 100%; height: 100%; object-fit: contain; }
.sec-idx {
  color: var(--amber);
  font-family: var(--mono);
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0;
}
.sec-title {
  color: var(--txt);
  font-family: var(--display);
  font-size: 17px;
  font-weight: 800;
  letter-spacing: 0;
}
.sec-title em {
  margin-left: 7px;
  color: var(--txt-dim);
  font: 700 10px var(--mono);
  font-style: normal;
  letter-spacing: 0;
  text-transform: uppercase;
}

/* Form controls */
.field { display: flex; flex-direction: column; gap: 7px; margin-bottom: 13px; }
.field:last-child { margin-bottom: 0; }
.field label,
.switch span:last-child,
.en-field {
  color: var(--txt-soft);
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}
.field label em,
.switch span em {
  margin-left: 6px;
  color: var(--txt-dim);
  font-family: var(--mono);
  font-style: normal;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: none;
}
.row { display: grid; grid-template-columns: 1fr auto; gap: 12px; align-items: end; }
.qty-field { min-width: 116px; }

select,
input[type="number"],
.combo-input,
.mini-select,
.mini-qty,
.en-field input,
.en-field select {
  width: 100%;
  min-height: 50px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  color: var(--txt);
  background: linear-gradient(180deg, rgba(255,255,255,.035), transparent), var(--field);
  font-family: var(--body);
  font-size: 14.5px;
  outline: none;
  appearance: none;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.045);
  transition: border-color var(--dur), box-shadow var(--dur), background var(--dur);
}
select,
.mini-select,
.en-field select {
  padding-right: 38px;
  cursor: pointer;
  background-image:
    linear-gradient(180deg, rgba(255,255,255,.035), transparent),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%23ff7552' d='M6 8L0 0h12z'/%3E%3C/svg%3E");
  background-repeat: no-repeat, no-repeat;
  background-position: 0 0, right 14px center;
  background-size: auto, 12px 8px;
}
select:focus,
input[type="number"]:focus,
.combo-input:focus,
.mini-select:focus,
.mini-qty:focus,
.en-field input:focus,
.en-field select:focus {
  border-color: var(--amber);
  background-color: #111722;
  box-shadow: 0 0 0 3px rgba(255,194,71,.12), 0 0 0 5px rgba(255,52,72,.06), inset 0 1px 0 rgba(255,255,255,.08);
}
input[type="number"],
.mini-qty {
  text-align: center;
  font-family: var(--mono);
  font-weight: 800;
}
.hint { margin-top: 10px; color: var(--txt-dim); font-size: 12px; line-height: 1.5; }

/* Combobox */
.combo { position: relative; }
.combo-input { padding-right: 38px; cursor: text; }
.combo-caret {
  position: absolute;
  right: 15px;
  top: 50%;
  width: 9px;
  height: 9px;
  border-right: 2px solid var(--amber);
  border-bottom: 2px solid var(--amber);
  transform: translateY(-70%) rotate(45deg);
  pointer-events: none;
  transition: transform var(--dur);
}
.combo.open .combo-caret { transform: translateY(-30%) rotate(-135deg); }
.combo-pop {
  position: absolute;
  top: calc(100% + 7px);
  left: 0;
  right: 0;
  z-index: 40;
  display: none;
  max-height: 320px;
  overflow-y: auto;
  padding: 6px;
  border: 1px solid rgba(255,194,71,.32);
  border-radius: var(--r);
  background:
    linear-gradient(180deg, rgba(255,52,72,.055), transparent 42%),
    #0b0f15;
  box-shadow: 0 28px 70px -34px rgba(0,0,0,.98), 0 18px 40px -34px rgba(255,52,72,.82);
}
.combo.open .combo-pop { display: block; }
.combo-item {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 11px;
  border-radius: var(--r-sm);
  color: var(--txt-soft);
  cursor: pointer;
  font-size: 13.5px;
}
.combo-item:hover,
.combo-item.active { color: var(--txt); background: linear-gradient(90deg, rgba(255,194,71,.11), rgba(255,52,72,.07)); }
.combo-item .ci-meta {
  flex: none;
  color: var(--txt-dim);
  font-family: var(--mono);
  font-size: 10.5px;
  white-space: nowrap;
}
.combo-item mark { color: var(--amber); background: transparent; font-weight: 800; }
.combo-empty,
.combo-more { padding: 10px 11px; color: var(--txt-dim); font-size: 12px; }
.combo-more { margin-top: 5px; border-top: 1px solid var(--line-soft); font-family: var(--mono); }
.combo-pop::-webkit-scrollbar { width: 9px; }
.combo-pop::-webkit-scrollbar-thumb { background: #343b48; border: 2px solid #0b0f15; border-radius: 999px; }

/* Switch and repeated rows */
.switch { display: flex; align-items: center; gap: 11px; margin-top: 13px; cursor: pointer; user-select: none; }
.switch input { display: none; }
.slider {
  position: relative;
  flex: none;
  width: 48px;
  height: 28px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--field);
  transition: border-color var(--dur), background var(--dur);
}
.slider::after {
  content: '';
  position: absolute;
  top: 4px;
  left: 4px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--txt-dim);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.24);
  transition: transform var(--dur), background var(--dur), box-shadow var(--dur);
}
.switch input:checked + .slider {
  border-color: rgba(255,194,71,.70);
  background: linear-gradient(90deg, rgba(255,194,71,.18), rgba(255,52,72,.16));
}
.switch input:checked + .slider::after {
  transform: translateX(20px);
  background: var(--flame);
  box-shadow: 0 0 16px rgba(255,52,72,.56), 0 0 10px rgba(255,194,71,.36);
}
.multi-rows { display: flex; flex-direction: column; gap: 9px; }
.multi-row { display: grid; grid-template-columns: 1fr 72px 46px; gap: 9px; }
.mini-select,
.mini-qty { min-height: 46px; padding: 10px; font-size: 13px; }
.row-del {
  display: grid;
  place-items: center;
  min-width: 46px;
  min-height: 46px;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  color: transparent;
  background: var(--field);
  font-size: 0;
  cursor: pointer;
  transition: transform var(--dur), border-color var(--dur), background var(--dur);
}
.row-del::before {
  content: '';
  width: 22px;
  height: 22px;
  background: url('../assets/brand/ui/icon-remove.svg') center / contain no-repeat;
}
.row-del:hover { border-color: rgba(255,91,95,.7); background: rgba(255,91,95,.10); }
.add-row {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  align-self: flex-start;
  min-height: 46px;
  margin-top: 5px;
  padding: 8px 13px;
  border: 1px dashed rgba(255,194,71,.42);
  border-radius: var(--r-sm);
  color: var(--amber);
  background: rgba(255,194,71,.06);
  font-family: var(--mono);
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: 0;
  cursor: pointer;
}
.add-row::before {
  content: '';
  width: 17px;
  height: 17px;
  flex: none;
  background: url('../assets/brand/ui/icon-add.svg') center / contain no-repeat;
}
.add-row:hover { border-color: var(--red-2); background: linear-gradient(90deg, rgba(255,194,71,.12), rgba(255,52,72,.08)); }

/* Primary instrument */
.gauge-card {
  position: relative;
  overflow: hidden;
  padding: 24px 22px 26px;
  text-align: center;
  border-color: rgba(255,194,71,.30);
  background:
    linear-gradient(180deg, rgba(255,194,71,.12), rgba(255,255,255,0) 40%),
    linear-gradient(135deg, rgba(255,52,72,.13), rgba(255,255,255,0) 48%),
    var(--panel);
  box-shadow: var(--shadow), 0 0 44px -34px rgba(255,52,72,.92);
}
.gauge-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    repeating-linear-gradient(0deg, transparent 0 17px, rgba(255,255,255,.025) 17px 18px),
    linear-gradient(90deg, transparent, rgba(255,194,71,.12), rgba(255,52,72,.10), transparent);
  opacity: .72;
  pointer-events: none;
}
.gauge-card::after {
  content: '';
  position: absolute;
  top: -38px;
  right: -34px;
  width: 172px;
  height: 172px;
  background: url('../assets/brand/logo/wattcalc-mark.svg') center / contain no-repeat;
  opacity: .075;
  filter: drop-shadow(0 0 20px rgba(255,52,72,.24));
  pointer-events: none;
}
.panel-tag {
  position: absolute;
  top: 14px;
  left: 16px;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--txt-dim);
  font-family: var(--mono);
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}
.panel-tag::before {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--ok);
  box-shadow: 0 0 10px var(--ok);
}
.gauge { position: relative; z-index: 1; width: 100%; max-width: 306px; margin: 13px auto 4px; }
.gauge-svg { width: 100%; display: block; overflow: visible; }
.gauge-track { stroke: rgba(255,255,255,.10); stroke-width: 13; stroke-linecap: round; }
.gauge-fill {
  stroke: var(--ok);
  stroke-width: 13;
  stroke-linecap: round;
  stroke-dasharray: 0 257.6;
  filter: drop-shadow(0 0 9px rgba(98,210,143,.42));
  transition: stroke-dasharray .65s cubic-bezier(.22,1,.36,1), stroke var(--dur);
}
.gauge-fill.lvl-low { stroke: var(--ok); }
.gauge-fill.lvl-mid { stroke: var(--amber); filter: drop-shadow(0 0 9px rgba(255,194,71,.48)); }
.gauge-fill.lvl-high { stroke: var(--amber); filter: drop-shadow(0 0 9px rgba(255,194,71,.50)); }
.gauge-fill.lvl-extreme { stroke: var(--danger); filter: drop-shadow(0 0 10px rgba(255,91,95,.52)); }
.gauge-center {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 3px;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.gauge-value { color: var(--txt); font: 800 54px/.96 var(--mono); letter-spacing: 0; }
.gauge-unit { margin-top: 4px; color: var(--txt-dim); font: 700 10.5px var(--mono); letter-spacing: 0; }
.recommend-headline {
  position: relative;
  z-index: 1;
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid var(--line-soft);
}
.recommend-label {
  display: block;
  color: var(--txt-dim);
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}
.recommend-watt {
  display: block;
  margin: 4px 0 2px;
  color: var(--amber);
  font: 900 60px/.94 var(--display);
  letter-spacing: 0;
  text-shadow: 0 0 24px rgba(255,194,71,.26), 0 0 18px rgba(255,52,72,.20);
}
.recommend-sub { color: var(--txt-soft); font-size: 13px; }

.quickstats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.qs {
  position: relative;
  min-height: 84px;
  padding: 14px 10px;
  border: 1px solid var(--line);
  border-radius: var(--r);
  text-align: center;
  background: var(--panel);
  overflow: hidden;
}
.qs::before {
  content: '';
  position: absolute;
  top: 0;
  left: 12px;
  right: 12px;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--amber), var(--red), transparent);
  box-shadow: 0 0 14px rgba(255,52,72,.28);
}
.qs-label {
  display: block;
  color: var(--txt-dim);
  font-size: 9.5px;
  font-weight: 800;
  line-height: 1.25;
  letter-spacing: 0;
  text-transform: uppercase;
}
.qs-value {
  display: block;
  margin-top: 8px;
  color: var(--txt);
  font: 800 20px var(--mono);
}

/* Result sections */
.advisor-card,
.psu-card,
.shop-card,
.tiers-card,
.energy-card { padding: 19px 20px; }
.advisor-card h3,
.psu-card h3,
.tiers-card h3,
.energy-card h3 {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 12px;
  color: var(--txt);
  font-family: var(--display);
  font-size: 15.5px;
  font-weight: 800;
  letter-spacing: 0;
  line-height: 1.2;
}
.dot-led {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--ok);
  box-shadow: 0 0 10px var(--ok);
  animation: pulse 2.2s ease-in-out infinite;
}
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: .42; } }

.compat-list { list-style: none; display: flex; flex-direction: column; gap: 9px; }
.compat {
  display: grid;
  grid-template-columns: 10px 1fr;
  gap: 11px;
  align-items: start;
  color: var(--txt-soft);
  font-size: 12.5px;
  line-height: 1.45;
}
.compat-dot { width: 8px; height: 8px; margin-top: 5px; border-radius: 50%; background: var(--txt-dim); }
.compat-ok .compat-dot { background: var(--ok); box-shadow: 0 0 8px rgba(98,210,143,.62); }
.compat-warn .compat-dot { background: var(--warn); box-shadow: 0 0 8px rgba(255,154,60,.62); }
.compat-muted .compat-dot { background: var(--txt-dim); }

.psu-head {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 14px;
  margin-bottom: 15px;
}
.psu-head h3 { margin-bottom: 4px; }
.psu-head p { color: var(--txt-dim); font-size: 12.5px; line-height: 1.4; }
.psu-models { display: flex; flex-direction: column; gap: 14px; }
.psu-model {
  padding: 18px;
  border: 1px solid var(--line);
  border-left: 3px solid rgba(255,52,72,.50);
  border-radius: var(--r);
  background: linear-gradient(180deg, rgba(255,194,71,.035), rgba(255,52,72,.025)), var(--panel-2);
  transition: transform var(--dur), border-color var(--dur), background var(--dur);
}
.psu-model:hover { transform: translateX(2px); border-color: rgba(255,52,72,.48); box-shadow: 0 18px 42px -36px rgba(255,52,72,.82); }
.psu-model-best {
  border-left-color: var(--amber);
  background: linear-gradient(180deg, rgba(255,194,71,.10), rgba(255,52,72,.05) 46%, transparent), var(--panel-2);
}
.psu-model-main { display: flex; justify-content: space-between; align-items: start; gap: 12px; }
.psu-rank {
  display: inline-flex;
  margin-bottom: 4px;
  color: var(--cyan);
  font: 800 9.5px var(--mono);
  letter-spacing: 0;
  text-transform: uppercase;
}
.psu-model-best .psu-rank { color: var(--amber); text-shadow: 0 0 12px rgba(255,52,72,.24); }
.psu-model-best .psu-rank::before { content: '★ '; }
.psu-model strong { display: block; color: var(--txt); font: 800 15.5px/1.25 var(--display); }
.psu-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  min-height: 44px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--txt-soft);
  text-decoration: none;
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}
.psu-link:hover { color: var(--red-ink); background: var(--flame); border-color: var(--amber); }
.psu-specs,
.psu-reasons { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.psu-specs span,
.psu-reasons span {
  padding: 4px 9px;
  border: 1px solid var(--line-soft);
  border-radius: 999px;
  color: var(--txt-soft);
  background: rgba(255,255,255,.025);
  font-size: 10.5px;
}
.psu-specs span { color: var(--txt); background: linear-gradient(90deg, rgba(255,194,71,.07), rgba(255,52,72,.04)); font-family: var(--mono); font-weight: 700; }
.psu-note { margin-top: 10px; color: var(--txt-dim); font-size: 11.5px; line-height: 1.45; }

.market-status {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 18px;
  border: 1px dashed rgba(255,194,71,.36);
  border-radius: var(--r);
  background: rgba(255,194,71,.05);
}
.market-status strong { color: var(--txt); font: 800 13.5px var(--display); }
.market-status span { color: var(--txt-dim); font-size: 12px; line-height: 1.45; }
.market-status.is-loading strong { display: flex; align-items: center; gap: 9px; }
.market-status.is-loading strong::before {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--amber);
  box-shadow: 0 0 10px var(--amber);
  animation: pulse 1.1s ease-in-out infinite;
}
.market-error { border-color: rgba(255,154,60,.48); background: rgba(255,154,60,.06); }
.market-error strong { color: var(--warn); }
.market-model { padding: 17px; }

.best-offer-card {
  display: grid;
  grid-template-columns: 168px 1fr;
  gap: 20px;
  align-items: center;
  margin-top: 14px;
  padding: 18px;
  border: 1px solid rgba(255,194,71,.46);
  border-radius: var(--r);
  color: var(--txt);
  text-decoration: none;
  background:
    linear-gradient(135deg, rgba(255,194,71,.16), rgba(255,52,72,.10)),
    var(--field);
  transition: transform var(--dur), border-color var(--dur), background var(--dur);
}
.best-offer-card:hover {
  transform: translateY(-2px);
  border-color: var(--amber);
  background:
    linear-gradient(135deg, rgba(255,194,71,.22), rgba(255,52,72,.14)),
    var(--field);
  box-shadow: 0 22px 48px -36px rgba(255,52,72,.88);
}
.best-offer-card img {
  width: 168px;
  height: 168px;
  object-fit: contain;
  padding: 10px;
  border: 1px solid rgba(255,255,255,.16);
  border-radius: var(--r);
  background: #f7f5ee;
}
.best-offer-copy { display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.best-offer-store { color: var(--red-2); font: 800 10.5px var(--mono); letter-spacing: 0; text-transform: uppercase; }
.best-offer-price { color: var(--amber); font: 800 50px/.96 var(--mono); }
.best-offer-title {
  color: var(--txt-soft);
  font-size: 12.5px;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.best-offer-meta { display: flex; align-items: center; gap: 6px; color: var(--txt-dim); font-size: 11.5px; }
.best-offer-meta::after { content: '↗'; color: var(--amber); }

.shop-embed {
  margin: 8px 0 16px;
  grid-template-columns: 118px 1fr;
  padding: 13px;
  border-color: rgba(255,52,72,.34);
  background: linear-gradient(135deg, rgba(255,52,72,.09), rgba(255,194,71,.07)), var(--field);
}
.shop-embed img {
  width: 118px;
  height: 118px;
}
.shop-embed-empty {
  display: grid;
  place-items: center;
  width: 118px;
  height: 118px;
  border: 1px solid rgba(255,255,255,.16);
  border-radius: var(--r);
  color: var(--amber);
  background: rgba(255,194,71,.08);
  font: 900 24px var(--display);
}
.shop-embed .best-offer-price { font-size: 30px; }
.shop-embed-fallback { border-style: dashed; }

/* Build sheet */
.ghost-sm { min-height: 46px; padding: 10px 12px; font-size: 12px; }
.shop-list { display: block; }
.sheet {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: var(--r);
  background:
    repeating-linear-gradient(180deg, transparent 0 34px, rgba(255,194,71,.025) 34px 35px),
    linear-gradient(135deg, rgba(255,52,72,.055), transparent 42%),
    var(--field);
}
.sheet-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 10px;
  padding-bottom: 12px;
  margin-bottom: 5px;
  border-bottom: 1px solid rgba(255,194,71,.22);
}
.sheet-title { color: var(--txt-soft); font: 900 12.5px var(--display); letter-spacing: 0; text-transform: uppercase; }
.sheet-id { color: var(--amber); font: 800 10px var(--mono); }
.sheet-line { display: flex; align-items: baseline; gap: 9px; padding: 9px 0; }
.sheet-slot {
  width: 78px;
  flex: none;
  color: var(--amber);
  font: 800 9.5px var(--mono);
  letter-spacing: 0;
  text-transform: uppercase;
}
.sheet-name { min-width: 0; flex: 0 1 auto; display: flex; flex-direction: column; gap: 1px; text-decoration: none; }
.sheet-prod { color: var(--txt); font-size: 13px; font-weight: 700; line-height: 1.2; }
.sheet-store { color: var(--txt-dim); font: 400 9.5px var(--mono); }
.sheet-name:hover .sheet-prod { color: var(--amber); }
.sheet-dots { flex: 1 1 auto; min-width: 12px; border-bottom: 1px dotted rgba(129,123,112,.62); transform: translateY(-3px); }
.sheet-price { flex: none; color: var(--txt); font: 800 14px var(--mono); white-space: nowrap; }
.sheet-price-miss { color: var(--txt-dim); font-size: 11.5px; font-weight: 600; }
.sheet-line-miss { opacity: .72; }
.sheet-total {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 10px;
  margin-top: 9px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}
.sheet-total-label { color: var(--txt-soft); font: 700 10.5px var(--mono); }
.sheet-total-value { color: var(--amber); font: 800 26px var(--mono); text-shadow: 0 0 20px rgba(255,194,71,.24), 0 0 16px rgba(255,52,72,.18); }

/* Tiers and energy */
.tiers-card h3 { margin-bottom: 7px; }
.tiers-intro { margin-bottom: 14px; color: var(--txt-dim); font-size: 12px; line-height: 1.45; }
.tiers { display: flex; flex-direction: column; gap: 9px; }
.tier {
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-areas: "head watt" "desc desc" "wall wall";
  gap: 4px 12px;
  align-items: center;
  padding: 13px 14px;
  border: 1px solid var(--line);
  border-left-width: 3px;
  border-radius: var(--r);
  background: var(--panel-2);
  transition: transform var(--dur), border-color var(--dur);
}
.tier:hover { transform: translateX(3px); border-color: rgba(255,52,72,.42); }
.tier-head { grid-area: head; display: flex; flex-direction: column; }
.tier-name { color: var(--txt); font: 800 13.5px var(--display); }
.tier-eff { color: var(--txt-dim); font: 400 10.5px var(--mono); }
.tier-watt { grid-area: watt; display: flex; flex-direction: column; align-items: flex-end; text-align: right; }
.tier-watt strong { color: var(--txt); font: 800 21px var(--mono); }
.tier-load { color: var(--txt-dim); font: 400 10px var(--mono); }
.tier-desc { grid-area: desc; margin-top: 4px; color: var(--txt-soft); font-size: 11.5px; line-height: 1.4; }
.tier-wall { grid-area: wall; margin-top: 2px; color: var(--txt-dim); font: 400 10px var(--mono); }
.tier-white { border-left-color: #b8c3d1; }
.tier-bronze { border-left-color: #cd7f32; }
.tier-silver { border-left-color: #d7dde7; }
.tier-gold { border-left-color: var(--amber); background: linear-gradient(180deg, rgba(255,194,71,.08), rgba(255,52,72,.035)), var(--panel-2); }
.tier-platinum { border-left-color: #7fdcff; }
.tier-titanium { border-left-color: #b79aff; }
.empty { padding: 14px 0; color: var(--txt-dim); font-size: 13px; text-align: center; }
.tier-floor-note {
  margin: 0 0 2px; padding: 8px 11px;
  border-left: 2px solid var(--amber);
  background: linear-gradient(180deg, rgba(255,194,71,.07), rgba(255,52,72,.03));
  color: var(--txt-soft); font-size: 11.5px; line-height: 1.45;
}

.energy-card h3 { margin-bottom: 14px; }
.energy-controls { display: grid; grid-template-columns: 1fr 1.45fr 1fr; gap: 10px; margin-bottom: 16px; }
.en-field { display: flex; flex-direction: column; gap: 6px; }
.en-field input,
.en-field select { min-height: 46px; padding: 10px; font-size: 13px; }
.energy-out { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.en-stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 13px;
  border: 1px solid var(--line-soft);
  border-radius: var(--r);
  background: var(--field);
}
.en-stat-main { grid-column: 1 / -1; border-color: rgba(255,194,71,.28); background: linear-gradient(180deg, rgba(255,194,71,.08), rgba(255,52,72,.035)), var(--field); }
.en-label { color: var(--txt-dim); font-size: 9.5px; font-weight: 800; letter-spacing: 0; text-transform: uppercase; }
.en-value { color: var(--txt); font: 800 22px var(--mono); }
.en-stat-main .en-value { color: var(--amber); font-size: 30px; }
.en-sub { color: var(--txt-soft); font-size: 11px; }
.en-note { grid-column: 1 / -1; margin-top: 2px; color: var(--txt-dim); font-size: 11px; line-height: 1.45; }
.en-note strong { color: var(--ok); font-family: var(--mono); }

/* Breakdown and footer */
.breakdown-card { padding: 2px 20px; background: rgba(17,20,26,.88); }
.breakdown-card summary {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 15px 0;
  color: var(--txt-soft);
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
  list-style: none;
}
.breakdown-card summary::-webkit-details-marker { display: none; }
.breakdown-card summary::before { content: '+'; color: var(--amber); font: 700 16px var(--mono); transition: transform var(--dur); }
.breakdown-card[open] summary::before { transform: rotate(45deg); }
.breakdown { list-style: none; display: flex; flex-direction: column; gap: 2px; padding: 0 0 16px; }
.breakdown li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: baseline;
  padding: 8px 0;
  border-bottom: 1px solid var(--line-soft);
  font-size: 12.5px;
}
.bd-label { color: var(--txt-soft); }
.bd-watt { color: var(--txt); font: 800 1em var(--mono); white-space: nowrap; }
.bd-total { margin-top: 6px; padding-top: 12px; border-top: 1px solid var(--line); border-bottom: 0; }
.bd-total .bd-label { color: var(--txt); font-weight: 800; }
.bd-total .bd-watt { color: var(--amber); font-size: 15px; }
.disclaimer { padding: 0 4px; color: var(--txt-dim); font-size: 11px; line-height: 1.55; }

.sitefoot {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 28px;
  padding: 22px clamp(16px, 4vw, 52px);
  border-top: 1px solid rgba(255,194,71,.18);
  color: var(--txt-dim);
  background: linear-gradient(90deg, rgba(255,52,72,.055), transparent 42%, rgba(255,194,71,.045)), rgba(8,9,11,.76);
  font-size: 11.5px;
}
.sitefoot strong { color: var(--txt-soft); font-family: var(--display); }

/* Motion and focus */
@keyframes riseIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes popIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@keyframes gridDrift {
  from { background-position: 0 0, 0 0, 0 0, 0 0; }
  to { background-position: 0 0, 0 40px, 40px 0, 0 0; }
}
@media (prefers-reduced-motion: no-preference) {
  .grid-bg { animation: gridDrift 12s linear infinite; }
  .config > *,
  .results-sticky > * { animation: riseIn .42s both; }
  .config > *:nth-child(2) { animation-delay: .04s; }
  .config > *:nth-child(3) { animation-delay: .08s; }
  .config > *:nth-child(4) { animation-delay: .12s; }
  .config > *:nth-child(5) { animation-delay: .16s; }
  .config > *:nth-child(6) { animation-delay: .20s; }
  .config > *:nth-child(7) { animation-delay: .24s; }
  .config > *:nth-child(8) { animation-delay: .28s; }
  .config > *:nth-child(9) { animation-delay: .32s; }
  .config > *:nth-child(10) { animation-delay: .36s; }
  .pop-in { animation: popIn .36s cubic-bezier(.22,1,.36,1) both; }
}
button,
.ghost-btn,
.preset-chip,
.psu-link,
.best-offer-card,
.add-row,
.row-del { transition: transform var(--dur), background var(--dur), border-color var(--dur), color var(--dur), box-shadow var(--dur); }
button:active,
.ghost-btn:active,
.preset-chip:active,
.add-row:active,
.row-del:active { transform: scale(.98); }
.gauge-value,
.recommend-watt { transition: color .3s, text-shadow .3s; }
:focus-visible { outline: 2px solid var(--amber); outline-offset: 3px; border-radius: var(--r-sm); box-shadow: 0 0 0 5px rgba(255,52,72,.14); }
@media (prefers-reduced-motion: reduce) {
  .grid-bg,
  .dot-led,
  .market-status.is-loading strong::before,
  .config > *,
  .results-sticky > *,
  .pop-in { animation: none; }
}

/* Responsive */
@media (max-width: 1180px) {
  .layout { grid-template-columns: minmax(0, 1fr) minmax(360px, .86fr); gap: 22px; }
  .config-hero h1 { font-size: 48px; }
}
@media (max-width: 940px) {
  .layout { grid-template-columns: 1fr; }
  .results-sticky { position: static; padding-left: 0; }
  .results-sticky::before { display: none; }
  .config-hero { grid-template-columns: 1fr; }
  .hero-console { min-height: 150px; }
  .config-hero { min-height: 156px; }
}
@media (max-width: 680px) {
  .topbar { flex-direction: column; align-items: flex-start; }
  .runtime-warning { position: static; flex-direction: column; align-items: flex-start; gap: 2px; }
  .topbar-meta { width: 100%; flex-wrap: wrap; justify-content: flex-start; }
  .layout { padding-inline: 14px; }
  .config-hero h1 { font-size: 39px; }
  .config-hero::before { width: 230px; height: 168px; right: -26px; opacity: .04; }
  .console-grid { grid-template-columns: 1fr 1fr; }
  .presets { grid-template-columns: 1fr; }
  .energy-controls,
  .energy-out { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
  .brand-text small { white-space: normal; }
  .card { padding: 0 16px 18px; }
  .card > legend { gap: 8px; }
  .card > legend { width: calc(100% + 32px); min-height: 72px; margin: 0 -16px 16px; padding: 15px 16px 13px; }
  .card > legend::after { flex-basis: 60px; height: 36px; opacity: .40; }
  .card > legend .ic { width: 38px; height: 38px; }
  .sec-title { font-size: 13.5px; }
  .sec-title em { display: none; }
  .quickstats { grid-template-columns: 1fr; }
  .row { grid-template-columns: 1fr; }
  .multi-row { grid-template-columns: 1fr 68px 46px; }
  .psu-head,
  .psu-model-main { flex-direction: column; align-items: stretch; }
  .psu-link { text-align: center; }
  .best-offer-card { grid-template-columns: 1fr; }
  .best-offer-card img { width: 100%; height: 154px; }
  .shop-embed-empty { width: 100%; height: 154px; }
  .best-offer-price { font-size: 36px; }
  .gauge-value { font-size: 48px; }
  .recommend-watt { font-size: 50px; }
  .sheet-line { display: grid; grid-template-columns: 70px 1fr auto; gap: 7px; }
  .sheet-dots { display: none; }
  .sheet-total { flex-direction: column; align-items: flex-start; }
}

/* === UI fix: dropdown do combobox era cortado pelo overflow:hidden do .card
   e ficava atrás dos cards seguintes (contexto de empilhamento dos .field).
   Eleva o card com combo aberto e libera o overflow. === */
.card:has(.combo.open){ overflow: visible; z-index: 30; }
.combo-pop{ z-index: 50; }
/* eleva o campo do combo aberto acima dos irmãos (.switch/.hint z-index:1) do mesmo card */
.field:has(.combo.open){ z-index: 40; }
