/* Kracks — прості сторінки: «Контакти» і юридичні документи (2026-10-30).

   Рішення Олександра (2026-10-30): фон кремовий або зовсім білий (у демо — ?bg=white),
   на «Контактах» форма, тема звернення — селектом; банер cookies — пізніше.
   Без карток і рамок: поля — лише лінія знизу, колонки розділені простором.

   Сторінки збирає tools/build_pages.py → contacts.html, legal.html. */

* { box-sizing: border-box; }

:root {
  --pg-bg: #fff8ec;
  --pg-fg: #1d0f10;
  --pg-muted: #6f5c54;   /* 5.96:1 на кремовому */
  --pg-line: #7d6a62;    /* лінія поля, 4.8:1 — видно як елемент керування */
  --pg-error: #b3121a;   /* 6.6:1 */
  --pg-yellow: #ffd23f;
  --pg-gutter: var(--kr-gutter, clamp(20px, 4.2vw, 80px)); /* як у хедера */
  --pg-top: 88px;        /* висота хедера */
  --pg-ease: cubic-bezier(0.22, 1, 0.36, 1);
}

html[data-bg='white'] { --pg-bg: #ffffff; }

html,
body {
  background: var(--pg-bg);
}

/* «Контакти» в меню хедера — поточна сторінка (хедер сам підкреслює лише якорі головної) */
.khd-link[aria-current='page'] { text-decoration-color: currentColor; }

body {
  margin: 0;
  font-family: var(--kr-font-text);
  color: var(--pg-fg);
}

.kpg {
  color: var(--pg-fg);
  background: var(--pg-bg);
}

.kpg-inner {
  max-width: 1440px;
  margin: 0 auto;
  padding: calc(var(--pg-top) + clamp(32px, 6vw, 96px)) var(--pg-gutter) clamp(72px, 9vw, 144px);
}

/* Великий заголовок сторінки — як H1 у hero: Display 900, капс */
.kpg-title {
  margin: 0;
  font: 900 clamp(64px, 9.5vw, 168px) / 0.86 var(--kr-font-display);
  letter-spacing: -0.005em;
  text-transform: uppercase;
  text-wrap: balance;
}

.kpg-link {
  color: inherit;
  text-decoration: underline;
  text-decoration-thickness: 1.5px;
  text-underline-offset: 0.2em;
  text-decoration-color: color-mix(in oklab, currentColor 40%, transparent);
  transition: text-decoration-color 200ms ease;
}

.kpg-link:hover { text-decoration-color: currentColor; }

.kpg-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

:where(.kpg) a:focus-visible,
:where(.kpg) button:focus-visible,
:where(.kpg) summary:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 4px;
  border-radius: 2px;
}

/* =====================================================================
   КОНТАКТИ
   ===================================================================== */

.kct-grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  column-gap: clamp(48px, 8vw, 160px);
  align-items: start;
}

.kct-intro {
  container-type: inline-size; /* під ширину колонки підганяється кегль заголовка */
}

/* заголовок із двох речень — по реченню на рядок; довший «МИ НА ЗВ’ЯЗКУ!» ≈ 5.45 em */
.kct-title {
  font-size: min(clamp(48px, 9.5vw, 168px), 18cqi);
  line-height: 0.92;
}

.kct-title span {
  display: block;
}

.kct-lead {
  max-width: 38ch;
  margin: clamp(24px, 2.4vw, 36px) 0 0;
  font: 400 clamp(18px, 1.4vw, 21px) / 1.45 var(--kr-font-text);
  text-wrap: pretty;
}

.kct-lead p {
  margin: 0;
}

.kct-lead p + p {
  margin-top: 0.6em;
}

/* Канали зв'язку — головне на сторінці, тому великим Display */
.kct-channels {
  display: grid;
  gap: clamp(24px, 2.6vw, 36px);
  margin: clamp(40px, 4.4vw, 64px) 0 0;
}

.kct-channels dt {
  margin-bottom: 6px;
  color: var(--pg-muted);
  font: 600 15px/1.2 var(--kr-font-text);
}

.kct-channels dd { margin: 0; }

.kct-big {
  display: inline-block;
  color: inherit;
  font: 700 clamp(32px, 3.3vw, 52px) / 1 var(--kr-font-display);
  letter-spacing: 0.005em;
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 0.16em;
  text-decoration-color: transparent;
  transition: text-decoration-color 200ms ease;
  overflow-wrap: anywhere;
}

.kct-big:hover { text-decoration-color: currentColor; }

.kct-note {
  display: block;
  margin-top: 8px;
  color: var(--pg-muted);
  font: 400 16px/1.4 var(--kr-font-text);
}

.kct-social {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 20px;
  margin: 0;
  padding: 0;
  list-style: none;
  font: 600 19px/1.4 var(--kr-font-text);
}

/* Співпраця і соцмережі — тексти клієнта: H2 на рівні «Написати нам», але менший, бо канали вище головніші */
.kct-block {
  max-width: 38ch;
  margin-top: clamp(48px, 5vw, 72px);
  font: 400 clamp(17px, 1.25vw, 19px) / 1.45 var(--kr-font-text);
  text-wrap: pretty;
}

.kct-block-title {
  margin: 0 0 12px;
  font: 900 clamp(28px, 2.4vw, 38px) / 0.95 var(--kr-font-display);
  text-transform: uppercase;
  text-wrap: balance;
}

.kct-block p { margin: 0 0 16px; }

.kct-block-link { font-weight: 600; }

/* фінальна фраза клієнта — як підпис під колонкою, «Kracks —» приглушено (як «Шукаєш, де купити?») */
.kct-signoff {
  margin: clamp(48px, 5vw, 72px) 0 0;
  font: 900 clamp(24px, 2vw, 32px) / 1 var(--kr-font-display);
  text-transform: uppercase;
  text-wrap: balance;
}

.kct-signoff span { color: var(--pg-muted); }

/* ---------- Форма ---------- */

.kct-form-wrap {
  /* верх форми — на рівні лід-абзацу, а не заголовка: заголовок лишається головним */
  padding-top: clamp(8px, 1.4vw, 24px);
  scroll-margin-top: calc(var(--pg-top) + 24px);
}

.kct-form-title {
  margin: 0 0 clamp(24px, 2.6vw, 40px);
  font: 900 clamp(36px, 3.4vw, 56px) / 0.95 var(--kr-font-display);
  text-transform: uppercase;
}

.kct-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(28px, 2.6vw, 40px) clamp(24px, 2.6vw, 40px);
}

.kct-field { display: grid; gap: 8px; min-width: 0; }
.kct-field--wide { grid-column: 1 / -1; }

.kct-label {
  font: 600 15px/1.2 var(--kr-font-text);
}

.kct-label small {
  color: var(--pg-muted);
  font-weight: 400;
  font-size: inherit;
}

.kct-input {
  width: 100%;
  margin: 0;
  padding: 8px 0 10px;
  color: inherit;
  font: 400 20px/1.4 var(--kr-font-text);
  background: transparent;
  border: 0;
  border-bottom: 1.5px solid var(--pg-line);
  border-radius: 0;
  outline: none;
  transition: border-color 200ms ease, box-shadow 200ms ease;
  appearance: none;
  scroll-margin-top: calc(var(--pg-top) + 56px); /* фокус на помилці: видно й підпис над полем */
}

.kct-input::placeholder { color: var(--pg-muted); opacity: 1; }

/* Фокус — лінія темніє й товщає (тінь, щоб текст не стрибав) */
.kct-input:focus,
.kct-input:focus-visible {
  border-color: var(--pg-fg);
  box-shadow: 0 1.5px 0 var(--pg-fg);
}

.kct-input[aria-invalid='true'] {
  border-color: var(--pg-error);
  box-shadow: 0 1.5px 0 var(--pg-error);
}

textarea.kct-input {
  min-height: 3lh;
  resize: vertical;
  field-sizing: content; /* росте з текстом там, де підтримується */
  max-height: 16lh;
}

/* Селект: рідний <select> (доступність, мобільні колеса), стрілка — своя */
.kct-select {
  position: relative;
}

.kct-select .kct-input {
  padding-right: 36px;
  cursor: pointer;
}

.kct-select .kct-input:invalid { color: var(--pg-muted); }
.kct-select option { color: var(--pg-fg); }

.kct-select::after {
  content: '';
  position: absolute;
  right: 6px;
  top: 50%;
  width: 10px;
  height: 10px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  translate: 0 -75%;
  rotate: 45deg;
  pointer-events: none;
}

.kct-error {
  min-height: 0;
  margin: 0;
  color: var(--pg-error);
  font: 600 15px/1.3 var(--kr-font-text);
}

.kct-error:empty { display: none; }

/* Згода */
.kct-consent {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 14px;
  align-items: start;
  font: 400 16px/1.45 var(--kr-font-text);
}

.kct-consent .kct-error { grid-column: 2; }

.kct-check {
  position: relative;
  width: 24px;
  height: 24px;
  margin: 0;
  border: 2px solid currentColor;
  border-radius: 4px;
  background: transparent;
  cursor: pointer;
  appearance: none;
  translate: 0 -1px; /* по середині першого рядка */
  scroll-margin-top: calc(var(--pg-top) + 56px);
}

.kct-check:checked { background: var(--pg-fg); }

.kct-check:checked::after {
  content: '';
  position: absolute;
  left: 6px;
  top: 1px;
  width: 7px;
  height: 13px;
  border-right: 2.5px solid var(--pg-yellow);
  border-bottom: 2.5px solid var(--pg-yellow);
  rotate: 45deg;
}

.kct-check[aria-invalid='true'] { border-color: var(--pg-error); }

.kct-check:focus-visible {
  outline: 2px solid var(--pg-fg);
  outline-offset: 3px;
}

/* Пастка для ботів: поле поза екраном, людина його не бачить і не заповнює */
.kct-trap {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.kct-actions {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 28px;
  margin-top: 8px;
}

/* Кнопка — як «Купити» в хедері над світлим фоном: темна з жовтим текстом */
.kct-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 60px;
  padding: 0 40px;
  border: 0;
  border-radius: 999px;
  color: var(--pg-yellow);
  background: var(--pg-fg);
  font: 700 19px/1 var(--kr-font-text);
  cursor: pointer;
  transition: background-color 200ms ease;
}

.kct-submit:hover { background: #3a2224; }

.kct-submit[aria-busy='true'] {
  cursor: progress;
  background: #3a2224;
}

.kct-submit[aria-busy='true']::after {
  content: '';
  width: 16px;
  height: 16px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: kct-spin 700ms linear infinite;
}

@keyframes kct-spin { to { rotate: 1turn; } }

.kct-status {
  margin: 0;
  font: 600 16px/1.4 var(--kr-font-text);
}

.kct-status--error { color: var(--pg-error); }

/* Надіслано — форма міняється на подяку на тому самому місці */
.kct-done {
  padding-top: clamp(8px, 1.4vw, 24px);
}

/* Ліва колонка (канали, співпраця, соцмережі) довша за форму — форма їде поруч.
   Лише коли вона (~600 px з помилками) вміщається під хедером, інакше низ був би недосяжний. */
@media (min-width: 1024px) and (min-height: 800px) {
  .kct-form-wrap,
  .kct-done {
    position: sticky;
    top: calc(var(--pg-top) + 24px);
  }
}

.kct-done h2 {
  margin: 0;
  font: 900 clamp(56px, 6.4vw, 112px) / 0.88 var(--kr-font-display);
  text-transform: uppercase;
  outline: none;
}

.kct-done p {
  max-width: 34ch;
  margin: 24px 0 32px;
  font: 400 clamp(19px, 1.5vw, 22px) / 1.45 var(--kr-font-text);
}

.kct-again {
  padding: 0;
  border: 0;
  color: inherit;
  background: none;
  font: 600 18px/1.4 var(--kr-font-text);
  cursor: pointer;
}

@media (prefers-reduced-motion: no-preference) {
  .kct-done:not([hidden]) { animation: kct-in 600ms var(--pg-ease) both; }
}

@keyframes kct-in {
  from { opacity: 0; translate: 0 16px; }
}

/* ---------- Низ: юрособа і «Де купити» ---------- */

.kct-foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: end;
  gap: 24px 48px;
  margin-top: clamp(80px, 9vw, 144px);
}

.kct-entity {
  margin: 0;
  color: var(--pg-muted);
  font: 400 15px/1.55 var(--kr-font-text);
  font-style: normal;
}

.kct-entity b { color: var(--pg-fg); font-weight: 600; }

/* звичайний рядок тексту, що переноситься (inline-flex розкладав його на три колонки на mobile) */
.kct-buy {
  color: inherit;
  font: 900 clamp(28px, 2.6vw, 40px) / 1 var(--kr-font-display);
  text-transform: uppercase;
  text-decoration: none;
  text-wrap: balance;
}

.kct-buy > span:first-child { color: var(--pg-muted); }

/* стрілка не відривається від останнього слова */
.kct-nowrap { white-space: nowrap; }

.kct-buy svg {
  display: inline-block;
  width: 0.8em;
  height: 0.8em;
  margin-left: 0.05em;
  vertical-align: -0.04em;
  transition: margin-left 250ms var(--pg-ease);
}

/* зсув стрілки без transform — див. футер (Safari стрибав на 1 px) */
.kct-buy:hover svg { margin-left: 0.25em; }

@media (max-width: 1023px) {
  .kct-grid { grid-template-columns: 1fr; }

  .kct-form-wrap,
  .kct-done {
    margin-top: 72px;
    padding-top: 0;
  }

  .kct-foot {
    flex-direction: column-reverse;
    align-items: start;
  }
}

@media (max-width: 599px) {
  .kct-form { grid-template-columns: 1fr; }
  .kct-submit { width: 100%; }
}

/* =====================================================================
   ЮРИДИЧНІ ДОКУМЕНТИ
   ===================================================================== */

.klg-docs {
  display: flex;
  flex-wrap: wrap;
  gap: 4px clamp(20px, 2.4vw, 36px);
  margin: 0 0 clamp(24px, 3vw, 40px);
  padding: 0;
  list-style: none;
  font: 600 16px/1.3 var(--kr-font-text);
}

.klg-docs a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--pg-muted);
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 8px;
  text-decoration-color: transparent;
  transition: color 200ms ease, text-decoration-color 200ms ease;
}

.klg-docs a:hover,
.klg-docs a[aria-current='page'] {
  color: var(--pg-fg);
  text-decoration-color: currentColor;
}

.klg-title {
  max-width: 14ch;
  font-size: clamp(56px, 7.4vw, 132px);
}

.klg-meta {
  margin: clamp(20px, 2vw, 28px) 0 0;
  color: var(--pg-muted);
  font: 400 16px/1.4 var(--kr-font-text);
}

.klg-grid {
  display: grid;
  grid-template-columns: minmax(220px, 3fr) minmax(0, 8fr);
  column-gap: clamp(48px, 7vw, 140px);
  align-items: start;
  margin-top: clamp(56px, 6vw, 96px);
}

/* ---------- Зміст ---------- */

.klg-toc {
  position: sticky;
  top: calc(var(--pg-top) + 24px);
  max-height: calc(100svh - var(--pg-top) - 48px);
  overflow-y: auto;
  overscroll-behavior: contain;
  /* overflow ріже все, що виходить за край: обвідку крапки поточного розділу й рамку фокусу.
     Запас усередині + від'ємне поле — текст лишається на своїй лінії */
  margin: 0 -8px;
  padding: 0 8px 8px;
}

.klg-toc summary {
  display: none;
  list-style: none;
}

.klg-toc summary::-webkit-details-marker { display: none; }

.klg-toc-label {
  margin: 0 0 12px;
  color: var(--pg-muted);
  font: 600 15px/1.2 var(--kr-font-text);
}

.klg-toc ol {
  display: grid;
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: toc;
}

.klg-toc a {
  display: grid;
  grid-template-columns: 2.2ch 1fr;
  gap: 8px;
  padding: 7px 0;
  color: var(--pg-muted);
  font: 600 16px/1.3 var(--kr-font-text);
  text-decoration: none;
  transition: color 200ms ease;
}

.klg-toc a::before {
  counter-increment: toc;
  content: counter(toc);
  font-variant-numeric: tabular-nums;
}

.klg-toc a:hover { color: var(--pg-fg); }

/* поточний розділ — темний текст і жовта крапка замість номера */
.klg-toc a[aria-current='true'] { color: var(--pg-fg); }

.klg-toc a[aria-current='true']::before {
  content: '';
  width: 10px;
  height: 10px;
  margin-top: 0.36em;
  border-radius: 50%;
  background: var(--pg-yellow);
  box-shadow: 0 0 0 1.5px var(--pg-fg);
}

/* ---------- Текст ---------- */

.klg-body {
  max-width: 68ch;
  font: 400 clamp(17px, 1.25vw, 19px) / 1.65 var(--kr-font-text);
  counter-reset: sec;
}

.klg-body section + section { margin-top: clamp(48px, 4.4vw, 72px); }

.klg-body h2 {
  display: grid;
  grid-template-columns: 2.2ch 1fr;
  gap: 8px;
  margin: 0 0 20px;
  font: 700 clamp(24px, 1.9vw, 30px) / 1.2 var(--kr-font-text);
  scroll-margin-top: calc(var(--pg-top) + 24px);
}

.klg-body h2::before {
  counter-increment: sec;
  content: counter(sec);
  color: var(--pg-muted);
  font-variant-numeric: tabular-nums;
}

.klg-body h3 {
  margin: 28px 0 8px;
  font: 700 1em/1.4 var(--kr-font-text);
}

.klg-body p,
.klg-body ul,
.klg-body table { margin: 0 0 16px; }

.klg-body ul { padding-left: 1.2em; }
.klg-body li { padding-left: 0.3em; }
.klg-body li + li { margin-top: 6px; }
.klg-body li::marker { color: var(--pg-muted); }

.klg-body a {
  color: inherit;
  text-decoration-thickness: 1.5px;
  text-underline-offset: 0.2em;
}

/* Таблиця (cookies) — лише тонкі лінії між рядками, як харчова цінність на PDP */
.klg-table-wrap {
  overflow-x: auto;
  margin: 0 0 16px;
}

.klg-body table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92em;
  line-height: 1.45;
}

.klg-body th,
.klg-body td {
  padding: 12px 16px 12px 0;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid color-mix(in oklab, var(--pg-fg) 18%, transparent);
}

.klg-body th {
  color: var(--pg-muted);
  font-weight: 600;
  border-bottom-color: var(--pg-fg);
}

.klg-body td:first-child { font-weight: 600; white-space: nowrap; }

@media (max-width: 1023px) {
  .klg-grid {
    grid-template-columns: 1fr;
    row-gap: 40px;
    margin-top: 40px;
  }

  /* Зміст — згорнутий «Зміст ▾» над текстом, не липкий */
  .klg-toc {
    position: static;
    max-height: none;
    overflow: visible;
    margin: 0;
    padding: 0;
  }

  .klg-toc summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 52px;
    font: 700 18px/1 var(--kr-font-text);
    border-bottom: 1.5px solid var(--pg-line);
    cursor: pointer;
  }

  .klg-toc summary::after {
    content: '';
    width: 9px;
    height: 9px;
    margin-right: 6px;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    translate: 0 -30%;
    rotate: 45deg;
    transition: rotate 200ms ease, translate 200ms ease;
  }

  .klg-toc[open] summary::after { rotate: 225deg; translate: 0 20%; }
  .klg-toc[open] ol { padding-top: 12px; }
  .klg-toc-label { display: none; }
}

/* =====================================================================
   404 — «404» з чіпсів на червоному (рендер blender/kracks-404.blend)
   ===================================================================== */

.k404 {
  position: relative;
  display: grid;
  align-content: end;
  justify-items: center;
  min-height: max(640px, 100svh);
  overflow: hidden;
  color: #ffffff;
  background: #d81f26; /* --kbr-bg: той самий червоний, що в маніфесті */
}

/* Рендер на весь екран. Фон у ньому прозорий, тож край кадру не видно — лише чіпси, що
   виходять за екран. Кадр 2.4:1 — ширший за будь-який настільний екран, тож cover вписує його
   за висотою: цифри завжди ≈ 21–61 % висоти, нижня третина по центру порожня, обрізаються лише боки. */
.k404-art {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 50%;
  pointer-events: none;
  user-select: none;
}

.k404-text {
  position: relative;
  padding: 0 var(--pg-gutter) clamp(48px, 8svh, 104px);
  text-align: center;
}

.k404-title {
  margin: 0;
  white-space: nowrap; /* один рядок: два налазили б на цифри */
  font: 900 clamp(40px, 4.2vw, 64px) / 0.92 var(--kr-font-display);
  text-transform: uppercase;
  text-wrap: balance;
}

.k404-lead {
  max-width: 38ch;
  margin: 16px auto 0;
  font: 400 clamp(18px, 1.35vw, 20px) / 1.45 var(--kr-font-text);
}

.k404-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 16px 32px;
  margin-top: 28px;
}

/* Жовта кнопка — як «Купити» над червоним */
.k404-home {
  display: inline-flex;
  align-items: center;
  min-height: 56px;
  padding: 0 36px;
  border-radius: 999px;
  color: #1d0f10;
  background: #ffd23f;
  font: 700 18px/1 var(--kr-font-text);
  text-decoration: none;
  transition: background-color 200ms ease;
}

.k404-home:hover { background: #ffe07a; }

.k404-more {
  color: inherit;
  font: 600 18px/1.4 var(--kr-font-text);
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 6px;
  text-decoration-color: rgb(255 255 255 / 0.5);
  transition: text-decoration-color 200ms ease;
}

.k404-more:hover { text-decoration-color: currentColor; }

.k404 a:focus-visible {
  outline: 2px solid #ffffff;
  outline-offset: 4px;
}

/* Портретні екрани: на весь екран цифри обрізалися б з боків — сцена окремим блоком 4:3
   (видно всю висоту кадру, боки обрізає край екрана), текст під нею */
@media (max-aspect-ratio: 1/1) {
  .k404 {
    align-content: center;
    padding-top: var(--pg-top);
  }

  .k404-art {
    position: relative;
    inset: auto;
    height: auto;
    aspect-ratio: 4 / 3;
  }

  .k404-text { padding-top: 8px; }
  .k404-title { white-space: normal; }
}

/* ---------- Демо-перемикачі (як на PDP) ---------- */

.demo-tweaks {
  position: fixed;
  right: 12px;
  bottom: 12px;
  z-index: 90;
  display: grid;
  gap: 4px;
  max-width: min(340px, calc(100vw - 24px));
  padding: 6px;
  font: 600 13px/1 var(--kr-font-text);
  background: #1d0f10;
  border-radius: 8px;
  box-shadow: 0 0 0 1px rgb(255 248 236 / 0.2);
}

.demo-tweaks summary { padding: 6px 8px; color: #fff8ec; cursor: pointer; }
.demo-tweaks div { display: flex; flex-wrap: wrap; gap: 2px; }
.demo-tweaks a { padding: 8px 9px; color: #fff8ec; text-decoration: none; border-radius: 4px; white-space: nowrap; }
.demo-tweaks a[aria-current] { color: #1d0f10; background: #fff8ec; }
.demo-tweaks p { margin: 4px 8px 6px; color: #b0a08f; font-weight: 400; line-height: 1.4; }

@media (max-width: 1023px) {
  .demo-tweaks { left: 8px; right: 8px; bottom: 8px; max-width: none; }
}
