/* Страницы ламп и рейтингов (make_pages.py, макет утверждён Max 26.10.2026): стиль сайта — тёмная тема, красный акцент канала,
   системный шрифт. Телефон в приоритете: карточки ламп в одну колонку, рейтинг карточками, цифры не мельче 12 px. */
:root {
  --bg: #0d0d0d; --panel: #161616; --line: #2c2b29;
  --fg: #f2f1ec; --muted: #a9a79e; --dim: #8a887f;
  --red: #ea0000; --redSoft: rgba(234,0,0,.14); --good: #6fcf8e; --bad: #ff8f80; --same: #a9a79e;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--fg); font: 15px/1.55 var(--sans); overflow-x: clip; }
a { color: var(--fg); }
a:focus-visible, button:focus-visible { outline: 2px solid var(--red); outline-offset: 2px; }
img { max-width: 100%; }
h1, h2, h3 { text-wrap: balance; margin: 0; }
.wrap { max-width: 1080px; margin: 0 auto; padding: 14px max(16px, env(safe-area-inset-right, 0px)) 56px max(16px, env(safe-area-inset-left, 0px)); }
.top { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 4px 0 14px; border-bottom: 1px solid var(--line); margin-bottom: 18px; }
.logo { display: inline-flex; align-items: center; gap: 8px; font-weight: 800; letter-spacing: .02em; text-decoration: none; font-size: 17px; }
.top nav { display: flex; gap: 16px; font-size: 14px; }
.top nav a { color: var(--muted); text-decoration: none; }
.top nav a:hover { color: var(--fg); }
.page { display: grid; grid-template-columns: minmax(0, 1fr); gap: 24px; }
.page > * { min-width: 0; }
.page h2 { font-size: 19px; margin-bottom: 8px; }
.sub { color: var(--dim); font-size: 13.5px; margin: -4px 0 10px; }
.crumbs { font-size: 13px; color: var(--dim); }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { text-decoration: underline; }
.page h1 { font-size: clamp(23px, 3.4vw, 32px); line-height: 1.15; }
.page h1 em { font-style: normal; color: var(--red); }
.lead { max-width: 70ch; color: #dedcd4; font-size: 16px; margin: 0; }
.small { font-size: 13px; color: var(--dim); max-width: 78ch; margin: 0; }
.small a { color: var(--muted); }

.hero { display: grid; grid-template-columns: 150px minmax(0, 1fr) 250px; gap: 16px; align-items: stretch; }
.hero .prod { background: #fff; border-radius: 10px; display: grid; place-items: center; padding: 8px; }
.hero .prod img { max-height: 190px; width: auto; height: auto; }
.hero figure { margin: 0; min-width: 0; }
.hero figure img { width: 100%; border-radius: 10px; display: block; background: #111; }
.hero figcaption { font-size: 12.5px; color: var(--dim); margin-top: 6px; }
.buy { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 14px; display: grid; gap: 8px; align-content: start; }
.buy .pr { font-size: 26px; font-weight: 800; font-variant-numeric: tabular-nums; }
.buy small { color: var(--dim); font-size: 12.5px; }
.buy small.promo { color: #ffb3b3; }
.btn { display: block; text-align: center; border-radius: 10px; padding: 11px 12px; font-weight: 700; text-decoration: none; min-height: 44px; }
.btn.red { background: var(--red); color: #fff; }
.btn.ghost { border: 1px solid var(--line); color: var(--fg); }
.btn.ghost:hover { border-color: var(--red); }

.facts { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.facts th, .facts td { text-align: left; padding: 9px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
.facts th { font-weight: 600; }
.facts th .n { display: block; font-weight: 400; color: var(--dim); font-size: 13px; }
.facts td.v { font-weight: 700; white-space: nowrap; font-size: 15.5px; }
.facts td.p { color: var(--muted); white-space: nowrap; font-size: 13.5px; text-align: right; }
.facts thead th.r { text-align: right; }
.facts thead th { font-size: 12px; color: var(--dim); font-weight: 600; text-transform: uppercase; letter-spacing: .06em; }
.facts + .small { margin-top: 8px; }

.two { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 16px; }
.box { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; display: grid; gap: 8px; align-content: start; }
.box h3 { font-size: 15px; }
.box p { margin: 0; color: #dedcd4; font-size: 14px; }
.same { margin: 0; color: var(--muted); font-size: 14px; }
.video { display: grid; grid-template-columns: 170px minmax(0, 1fr); gap: 12px; text-decoration: none; align-items: center; }
.video .th { position: relative; } .video .th img { width: 100%; border-radius: 8px; display: block; }
.video .th em { position: absolute; inset: 0; display: grid; place-items: center; font-style: normal; font-size: 26px; color: #fff; text-shadow: 0 1px 6px #000; }
.video .t { font-weight: 700; } .video .s { color: var(--dim); font-size: 13px; }

/* разница: «что — насколько», цвет по смыслу и знак, чтобы читалось и без цвета */
.dif, .pdiff { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.dif li, .pdiff li { display: grid; grid-template-columns: 9.5em minmax(0, 1fr); gap: 8px; font-size: 14px; align-items: baseline; }
.dl { color: var(--dim); }
.dv { font-weight: 600; }
.dv::before { display: inline-block; width: 1.1em; font-weight: 800; }
.good .dv { color: var(--good); } .good .dv::before { content: "+"; }
.bad .dv { color: var(--bad); } .bad .dv::before { content: "−"; }
.same .dv { color: var(--same); } .same .dv::before { content: "="; }

.peers { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.peer { display: grid; grid-template-rows: auto auto 1fr auto; gap: 10px; text-decoration: none; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 12px; min-width: 0; }
.peer:hover, .peer:focus-visible { border-color: var(--red); outline: none; }
.ptag { font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.phead { display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: 12px; align-items: center; }
.pimg { width: 72px; height: 72px; background: #fff; border-radius: 10px; display: grid; place-items: center; overflow: hidden; }
.pimg img { max-width: 64px; max-height: 64px; width: auto; height: auto; }
.pname { display: grid; gap: 2px; min-width: 0; }
.pname b { font-size: 15.5px; line-height: 1.25; }
.pkind { font-size: 13.5px; color: var(--muted); font-variant-numeric: tabular-nums; }
.pdiff { padding-top: 10px; border-top: 1px solid var(--line); }
.pdiff li { grid-template-columns: 8.4em minmax(0, 1fr); font-size: 13.5px; }
.pgo { font-size: 13.5px; font-weight: 700; text-decoration: underline; text-decoration-color: var(--red); text-underline-offset: 3px; }
.flag { display: inline-block; justify-self: start; font-size: 12px; font-weight: 600; color: var(--bad); border: 1px solid rgba(255,143,128,.4); border-radius: 6px; padding: 0 6px; margin-top: 2px; }
.faq h3 { font-size: 15px; margin-top: 10px; }
.faq p { margin: 4px 0 0; color: #dedcd4; max-width: 70ch; }

/* рейтинг: одна разметка — на ПК строки таблицы, на телефоне карточки */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { border: 1px solid var(--line); border-radius: 999px; padding: 8px 14px; font: inherit; font-size: 14px; color: var(--muted); background: none; cursor: pointer; min-height: 40px; }
.chip[aria-pressed="true"] { border-color: var(--red); color: var(--fg); background: var(--redSoft); }
.rk { list-style: none; margin: 0; padding: 0; font-variant-numeric: tabular-nums; }
.rr, .rhead { display: grid; grid-template-columns: 28px 56px minmax(0, 2.3fr) repeat(5, minmax(0, 1fr)); gap: 12px; align-items: center; padding: 8px 6px; border-bottom: 1px solid var(--line); }
.rhead { font-size: 12px; color: var(--dim); text-transform: uppercase; letter-spacing: .05em; font-weight: 600; padding-block: 6px; }
.rn { color: var(--dim); font-size: 14px; text-align: right; }
.ri { width: 56px; height: 56px; background: #fff; border-radius: 8px; display: grid; place-items: center; overflow: hidden; }
.ri img { max-width: 50px; max-height: 50px; width: auto; height: auto; }
.rname { display: grid; gap: 1px; min-width: 0; }
.rname a { font-weight: 700; text-decoration: none; font-size: 15px; line-height: 1.25; }
.rname a:hover { text-decoration: underline; }
.rname .k { font-size: 13px; color: var(--dim); }
.rname .kc { display: none; }
.rm { font-size: 14.5px; white-space: nowrap; }
.rm .ml { display: none; }
.rms { display: contents; }
.rr.nr .rname a { color: var(--muted); }

@media (max-width: 900px) { .peers { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 760px) {
  .top nav { gap: 12px; font-size: 13.5px; }
  .hero { grid-template-columns: 110px minmax(0, 1fr); }
  .hero .buy { grid-column: 1 / -1; }
  .hero .prod img { max-height: 130px; }
  .peers { grid-template-columns: minmax(0, 1fr); }
  .video { grid-template-columns: 130px minmax(0, 1fr); }
  .facts th, .facts td { padding: 9px 6px; }
  .facts td.v { white-space: normal; overflow-wrap: anywhere; min-width: 5.5em; }
  .facts td.p { font-size: 13px; }
  .rhead { display: none; }
  .rr { grid-template-columns: 22px 60px minmax(0, 1fr); gap: 10px; padding: 12px 6px; }
  .rn { align-self: start; padding-top: 2px; }
  .ri { width: 60px; height: 60px; } .ri img { max-width: 54px; max-height: 54px; }
  .rname .kc { display: inline; }
  .rms { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; align-items: end; padding: 8px 0 0; border-top: 1px dashed var(--line); }
  .rr .rm { display: grid; font-size: 14.5px; font-weight: 700; }
  .rr .rm .ml { display: block; font-size: 12px; font-weight: 400; color: var(--dim); white-space: normal; line-height: 1.2; margin-bottom: 2px; }
  .rr .rc { display: none; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
