/*
 * SpiceMC — стили сайта.
 * Композиция унаследована от старого магазина QuestCraft (светлая страница, цветной блок «Онлайн»,
 * тёмная лента Live-дропов, крупные кнопки разделов, белые карточки с ценником в углу),
 * цвета — палитра сервера (plugins/API/config.yml → palette): accent #8EC5E8, highlight #E3A857.
 * Вёрстка mobile-first: базовые правила для телефона, @media (min-width) — для широких экранов.
 */

/*
 * Шрифты (лицензия SIL OFL): Golos Text - вариативный, 400-700; Russo One - заголовки и цены.
 * Наборы символов как у Google Fonts: браузер скачивает только нужные (₽ - в latin-ext).
 */
@font-face {
  font-family: 'Golos Text';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('../fonts/GolosText-cyrillic.woff2') format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Golos Text';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('../fonts/GolosText-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Golos Text';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('../fonts/GolosText-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Russo One';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/RussoOne-cyrillic.woff2') format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Russo One';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/RussoOne-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Russo One';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/RussoOne-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  /* Палитра сервера */
  --accent: #8ec5e8;
  --highlight: #e3a857;
  --error: #e57a7a;
  --success: #9cd6a4;

  /* Оттенки для светлого фона (палитровые цвета слишком светлые для текста на белом) */
  --accent-ink: #2a6a94;
  --accent-deep: #13293a;
  --highlight-ink: #8a5a17;
  --highlight-dark: #b97f36;

  --ink: #17232c;
  --ink-2: #475965;
  --ink-3: #7b8d98;
  --page: #f2f6f9;
  --card: #ffffff;
  --line: #e1e8ed;
  --navy: #16232d;
  --navy-2: #213340;

  --font: 'Golos Text', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-head: 'Russo One', 'Golos Text', system-ui, sans-serif;
  --shadow: 0 14px 34px rgba(23, 46, 66, .09);

  /* Пиксельные фоны: квадраты 16px двух оттенков, как блоки в шапке QuestCraft */
  --px-light: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='96' height='96'%3E%3Cpath fill='%23edf2f6' d='M0 0h16v16H0zM48 16h16v16H48zM80 48h16v16H80zM16 64h16v16H16zM64 80h16v16H64z'/%3E%3Cpath fill='%23f3f7fa' d='M32 0h16v16H32zM16 32h16v16H16zM64 32h16v16H64zM48 64h16v16H48zM0 80h16v16H0z'/%3E%3C/svg%3E");
  --px-blue: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='96' height='96'%3E%3Cpath fill='%2380bbe2' d='M0 0h16v16H0zM48 16h16v16H48zM80 48h16v16H80zM16 64h16v16H16zM64 80h16v16H64z'/%3E%3Cpath fill='%239bcfef' d='M32 0h16v16H32zM16 32h16v16H16zM64 32h16v16H64zM48 64h16v16H48zM0 80h16v16H0z'/%3E%3C/svg%3E");
  --px-navy: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='96' height='96'%3E%3Cpath fill='%231b2a35' d='M0 0h16v16H0zM48 16h16v16H48zM80 48h16v16H80zM16 64h16v16H16zM64 80h16v16H64z'/%3E%3Cpath fill='%23131f28' d='M32 0h16v16H32zM16 32h16v16H16zM64 32h16v16H64zM48 64h16v16H48zM0 80h16v16H0z'/%3E%3C/svg%3E");
}

*, *::before, *::after { box-sizing: border-box; }

[hidden] { display: none !important; }

/*
 * Плавные переходы между страницами (View Transitions): шапка и лента дропов остаются на месте,
 * меняется только содержимое. Браузеры без поддержки просто открывают страницу как обычно.
 */
@view-transition { navigation: auto; }
.site-header { view-transition-name: site-header; }
.live { view-transition-name: live-drops; }
::view-transition-group(site-header),
::view-transition-group(live-drops) { animation: none; }
::view-transition-old(root) { animation: page-out .14s ease-in both; }
::view-transition-new(root) { animation: page-in .24s ease-out both; }
@keyframes page-out { to { opacity: 0; } }
@keyframes page-in { from { opacity: 0; transform: translateY(8px); } }


html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--page);
  color: var(--ink);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.5;
  overflow-x: hidden;
}

main { flex: 1; }
main:focus { outline: none; }

/* Полоса загрузки при переходе между страницами (появляется, только если загрузка затянулась) */
html.is-loading::before {
  content: '';
  position: fixed;
  top: 0; left: 0;
  z-index: 100;
  width: 100%;
  height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--highlight));
  transform-origin: left;
  animation: loading 1.2s ease-out .15s both;
}
@keyframes loading { from { transform: scaleX(0); } to { transform: scaleX(.85); } }
img { max-width: 100%; display: block; }
a { color: var(--accent-ink); text-decoration: none; }
a:hover { text-decoration: underline; }
button { font: inherit; color: inherit; }
h1, h2, h3 { font-family: var(--font-head); font-weight: 400; line-height: 1.15; margin: 0; }
:focus-visible { outline: 3px solid var(--highlight); outline-offset: 2px; }

.container { width: 100%; max-width: 1180px; margin: 0 auto; padding: 0 16px; }

.t-accent { color: var(--accent-ink); }
.t-highlight { color: var(--highlight-dark); }
.t-muted { color: var(--ink-3); }
.nowrap { white-space: nowrap; }

/* ---------- Кнопки ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 24px;
  border: 0;
  border-radius: 4px;
  font-family: var(--font-head);
  font-size: 17px;
  text-transform: uppercase;
  cursor: pointer;
  transition: background-color .15s, transform .1s;
}
.btn:active { transform: translateY(2px); }
.btn--primary { background: var(--highlight); color: #2b1b06; box-shadow: inset 0 -4px 0 var(--highlight-dark); }
.btn--primary:hover { background: #ebb569; }
.btn--block { width: 100%; }

/* ---------- Шапка ---------- */

.site-header {
  position: relative;
  z-index: 30;
  background: #f8fafc var(--px-light);
  border-bottom: 1px solid var(--line);
}
.site-header__inner { display: flex; flex-direction: column; }
.site-header__main { display: flex; align-items: center; gap: 16px; min-height: 76px; }

.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); }
.brand:hover { text-decoration: none; }
.brand__logo { width: 46px; height: auto; }
.brand__name { font-family: var(--font-head); font-size: 26px; line-height: 1; letter-spacing: -.01em; }
.brand__spice { color: #3d8fc4; }
.brand__mc { color: var(--highlight-dark); }

.nav {
  position: absolute;
  top: 76px;
  left: 0;
  right: 0;
  z-index: 30;
  display: none;
  flex-direction: column;
  padding: 6px 16px 14px;
  background: #fff;
  border-bottom: 1px solid var(--line);
  box-shadow: var(--shadow);
}
.nav.is-open { display: flex; }
.nav__link {
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
  font-family: var(--font-head);
  font-size: 15px;
  text-transform: uppercase;
  color: var(--ink);
}
.nav__link:last-child { border-bottom: 0; }
.nav__link:hover { text-decoration: none; color: var(--accent-ink); }
.nav__link[aria-current="page"] { color: var(--highlight-dark); }

.burger {
  margin-left: auto;
  width: 44px; height: 44px;
  display: inline-flex; flex-direction: column; align-items: center; justify-content: center; gap: 5px;
  border: 1px solid var(--line); border-radius: 4px;
  background: #fff;
  cursor: pointer;
}
.burger span { width: 20px; height: 2px; background: var(--ink); transition: transform .2s, opacity .2s; }
.burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Блок «Онлайн» — на телефоне полоса во всю ширину, на десктопе цветной блок справа до края экрана */
.status {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 8px 14px;
  margin: 0 -16px;
  padding: 12px 16px 14px;
  background: var(--accent) var(--px-blue);
  color: var(--accent-deep);
}
.status__row { display: flex; align-items: baseline; gap: 10px; }
.status__label {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-family: var(--font-head);
  font-size: 14px;
  text-transform: uppercase;
}
.status__dot { width: 9px; height: 9px; background: var(--accent-deep); opacity: .45; }
.status.is-up .status__dot { background: #2f8a45; opacity: 1; box-shadow: 0 0 0 3px rgba(255, 255, 255, .55); }
.status__value { font-family: var(--font-head); font-size: 22px; color: #fff; text-shadow: 0 2px 0 rgba(19, 41, 58, .35); }
.status__bar { grid-column: 1 / -1; height: 8px; background: rgba(19, 41, 58, .18); }
.status__bar span { display: block; width: 0; height: 100%; background: var(--highlight); box-shadow: inset 0 -2px 0 var(--highlight-dark); transition: width .6s; }
.status.no-anim .status__bar span { transition: none; }
.status__ip {
  grid-column: 1 / -1;
  justify-self: start;
  display: inline-flex;
  align-items: baseline;
  gap: 8px;
  padding: 0;
  border: 0;
  background: none;
  font-family: var(--font-head);
  font-size: 15px;
  color: var(--accent-deep);
  cursor: pointer;
  text-align: left;
}
.status__hint { font-family: var(--font); font-size: 12px; opacity: .75; text-decoration: underline; }
.status__ip.is-copied .status__hint { opacity: 1; text-decoration: none; color: #1f6a32; }
.status__social { grid-row: 1; grid-column: 2; display: flex; gap: 6px; justify-content: flex-end; }
.status__social a {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #fff;
  color: #2f78b2;
  box-shadow: 0 6px 14px rgba(19, 41, 58, .18);
}
.status__social a:hover { color: var(--highlight-dark); text-decoration: none; }

@media (min-width: 1040px) { /* шапка в строку: логотип, меню и блок «Онлайн» помещаются с этой ширины */
  .site-header { overflow: hidden; }
  .site-header__inner { flex-direction: row; align-items: stretch; }
  .site-header__main { flex: 1; min-height: 120px; gap: 40px; }
  .brand__logo { width: 56px; }
  .brand__name { font-size: 30px; }
  .nav {
    position: static;
    display: flex;
    flex-direction: row;
    gap: 30px;
    padding: 0;
    background: none;
    border: 0;
    box-shadow: none;
  }
  .nav__link { position: relative; padding: 6px 0; border: 0; font-size: 14px; color: var(--ink-2); }
  .nav__link[aria-current="page"] { color: var(--ink); }
  .nav__link[aria-current="page"]::after {
    content: '';
    position: absolute;
    left: 0; right: 0; bottom: -4px;
    height: 3px;
    background: var(--highlight);
  }
  .burger { display: none; }

  .status {
    position: relative;
    width: 360px;
    margin: 0;
    padding: 22px 0 18px 28px;
    align-content: center;
  }
  /* Продолжение блока до правого края окна */
  .status::after {
    content: '';
    position: absolute;
    top: 0; bottom: 0; left: 100%;
    width: 50vw;
    background: inherit;
  }
  .status__value { font-size: 26px; }
}

/* ---------- Live дропы ---------- */

.live { background: var(--navy) var(--px-navy); color: #cfdde5; }
.live__inner { display: flex; align-items: center; gap: 18px; min-height: 92px; padding-left: 0; }
.live__label {
  flex: none;
  position: relative;
  display: flex;
  align-items: center;
  height: 44px;
  padding: 0 16px 0 16px;
  margin-right: 8px;
  background: var(--highlight);
  color: #2b1b06;
  font-family: var(--font-head);
  font-size: 14px;
  text-transform: uppercase;
  clip-path: polygon(0 0, calc(100% - 12px) 0, 100% 50%, calc(100% - 12px) 100%, 0 100%);
  padding-right: 24px;
}
.live__label span { font-family: var(--font); font-weight: 600; margin-left: 5px; text-transform: none; font-size: 15px; }
.live__track {
  display: flex;
  gap: 0;
  overflow-x: auto;
  scrollbar-width: none;
  -webkit-mask-image: linear-gradient(90deg, #000 88%, transparent);
  mask-image: linear-gradient(90deg, #000 88%, transparent);
}
.live__track::-webkit-scrollbar { display: none; }
.drop {
  flex: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  width: 92px;
  padding: 8px 0;
  border-right: 2px solid rgba(255, 255, 255, .05);
}
.drop img { width: 44px; height: 44px; object-fit: contain; image-rendering: pixelated; }
.drop__price {
  min-width: 52px;
  padding: 1px 6px;
  background: var(--navy-2);
  font-family: var(--font-head);
  font-size: 12px;
  text-align: center;
  color: #fff;
}
.drop__nick { max-width: 84px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11px; color: #8a9ba8; }

@media (max-width: 599px) {
  .live__inner { min-height: 82px; padding-right: 0; }
  .live__label { height: 36px; font-size: 12px; padding-left: 12px; }
  .live__label span { display: none; }
  .drop { width: 78px; }
}

/* ---------- Разделы магазина ---------- */

.shop { padding-top: 24px; }

.modes { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.mode {
  display: flex;
  flex-direction: column-reverse;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 76px;
  padding: 10px 6px 12px;
  border-radius: 4px;
  background: #fff;
  box-shadow: inset 0 -4px 0 var(--line), var(--shadow);
  font-family: var(--font-head);
  font-size: 13px;
  line-height: 1.15;
  text-align: center;
  text-transform: uppercase;
  color: var(--ink);
  transition: background-color .15s, transform .1s;
}
.mode img { width: 28px; height: 28px; object-fit: contain; image-rendering: pixelated; }
.mode:hover { text-decoration: none; background: #f7fbfe; }
.mode:active { transform: translateY(2px); }
.mode[aria-current="page"] { background: var(--highlight); color: #2b1b06; box-shadow: inset 0 -4px 0 var(--highlight-dark), 0 10px 24px rgba(227, 168, 87, .35); }
.mode--cases:not([aria-current="page"]) { background: var(--accent); color: var(--accent-deep); box-shadow: inset 0 -4px 0 #6aa9d2, var(--shadow); }

@media (min-width: 640px) {
  .modes { display: flex; flex-wrap: wrap; gap: 12px; }
  .mode {
    flex-direction: row;
    gap: 14px;
    min-height: 66px;
    padding: 0 26px;
    font-size: 16px;
  }
  .mode img { width: 32px; height: 32px; }
}

.sale { margin: 16px 0 0; font-size: 15px; color: var(--ink-2); }
.sale b { color: var(--highlight-dark); }

/* ---------- Карточки ---------- */

.products {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 20px;
}
@media (min-width: 620px) { .products { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; } }
@media (min-width: 900px) { .products { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (min-width: 1140px) { .products { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 16px; } }

.product {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 16px 14px 12px;
  border: 2px solid transparent;
  border-radius: 4px;
  background: var(--card);
  box-shadow: var(--shadow);
  text-align: left;
  cursor: pointer;
  transition: border-color .15s, transform .15s, box-shadow .15s;
}
.product:hover { border-color: var(--highlight); transform: translateY(-3px); box-shadow: 0 20px 40px rgba(23, 46, 66, .13); }
/* Цвета префикса привилегии из игры - полоса сверху карточки */
.product--rank::before {
  content: '';
  position: absolute;
  top: -2px; left: -2px; right: -2px;
  height: 5px;
  border-radius: 4px 4px 0 0;
  background: linear-gradient(90deg, var(--rank-a), var(--rank-b));
}
.product__head { display: flex; flex-direction: column; padding-right: 74px; min-height: 40px; }
.product__title { font-family: var(--font-head); font-size: 15px; line-height: 1.15; text-transform: uppercase; color: var(--ink); overflow-wrap: break-word; }
.product__desc { margin-top: 3px; font-size: 11px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--ink-3); }
/* Ценник в углу, как у QuestCraft */
.product__tag {
  position: absolute;
  top: 14px;
  right: -2px;
  padding: 5px 10px 6px;
  background: var(--highlight);
  box-shadow: inset 0 -3px 0 var(--highlight-dark);
  font-family: var(--font-head);
  font-size: 15px;
  line-height: 1;
  color: #2b1b06;
  white-space: nowrap;
}
.product__media { display: flex; align-items: center; justify-content: center; aspect-ratio: 9 / 8; margin: 6px 0 4px; }
.product__media img { width: 86%; height: 86%; object-fit: contain; image-rendering: pixelated; transition: transform .2s; }
.product:hover .product__media img { transform: scale(1.06); }
.product__footer { display: flex; align-items: center; justify-content: space-between; gap: 6px; margin-top: auto; padding-top: 8px; border-top: 1px solid var(--line); }
.product__old { font-size: 12px; color: var(--ink-3); white-space: nowrap; }
.product__old s { color: var(--ink-3); }
.product__buy { font-family: var(--font-head); font-size: 13px; text-transform: uppercase; color: var(--accent-ink); }
.product:hover .product__buy { color: var(--highlight-dark); }

@media (max-width: 520px) {
  .product { padding: 12px 10px 10px; }
  .product__head { padding-right: 0; padding-top: 30px; }
  .product__tag { top: 10px; font-size: 14px; }
  .product__title { font-size: 14px; }
  .product__buy { display: none; }
}

/* ---------- Окна ---------- */

.modal {
  width: min(430px, calc(100vw - 24px));
  max-height: calc(100dvh - 24px);
  padding: 0;
  border: 0;
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
  box-shadow: 0 30px 90px rgba(10, 22, 32, .45);
}
.modal::backdrop { background: rgba(14, 26, 36, .6); }
.modal[open] { animation: modal-in .2s ease; }
@keyframes modal-in { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

.modal__body { position: relative; display: flex; flex-direction: column; gap: 16px; margin: 0; padding: 0 22px 22px; }
.modal__close {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 4px;
  background: var(--page);
  color: var(--ink-2);
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
}
.modal__close:hover { color: var(--ink); }
/* Товар в оранжевом квадрате, выступающем над окном — как иконка в окнах QuestCraft */
.modal__product { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 4px; }
.modal__product img {
  width: 80px;
  height: 80px;
  margin-bottom: 6px;
  padding: 8px;
  object-fit: contain;
  background: var(--highlight);
  box-shadow: inset 0 -4px 0 var(--highlight-dark), 0 12px 24px rgba(227, 168, 87, .45);
  image-rendering: pixelated;
}
.modal__title { font-size: 22px; text-transform: uppercase; }
.modal__price { margin: 0; font-family: var(--font-head); font-size: 18px; color: var(--highlight-dark); }
.modal__price s { margin-right: 6px; font-family: var(--font); font-size: 15px; color: var(--ink-3); }
.modal--pay .modal__body { padding-top: 24px; }
.pay-options { display: flex; flex-direction: column; gap: 10px; }
.pay-option {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  font: inherit;
  text-align: left;
  color: var(--ink);
  cursor: pointer;
  transition: border-color .15s, box-shadow .15s, transform .15s;
}
.pay-option:hover, .pay-option:focus-visible { border-color: var(--accent-ink); box-shadow: 0 6px 16px rgba(23, 46, 66, .1); transform: translateY(-1px); outline: none; }
.pay-option:disabled { cursor: progress; opacity: .6; transform: none; }
.pay-option.is-loading { opacity: 1; border-color: var(--accent-ink); }
.pay-option__logo { flex: 0 0 96px; height: 40px; display: grid; place-items: center; }
.pay-option__logo img { max-width: 96px; max-height: 40px; object-fit: contain; }
.pay-option__text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.pay-option__title { font-weight: 700; font-size: 15px; }
.pay-option__desc { font-size: 13px; color: var(--ink-3); }
.pay-option__arrow { font-size: 26px; line-height: 1; color: var(--ink-3); }
.pay-back { margin-top: 2px; background: transparent; color: var(--ink-2); box-shadow: none; }
.modal__hint { margin: 2px 0 0; font-size: 13px; color: var(--ink-3); }
.modal__hint.is-error { color: var(--error); }
.modal__note a { color: var(--accent-ink); text-decoration: underline; }
.modal__note { margin: 0; font-size: 13px; color: var(--ink-3); }
.modal__legal { margin: -4px 0 0; font-size: 13px; line-height: 1.6; text-align: center; color: var(--accent-ink); }
.modal__legal a { color: var(--accent-ink); text-decoration: underline dotted; text-underline-offset: 3px; }
.modal__legal a:hover { text-decoration-style: solid; }
.modal__text { margin: 0; color: var(--ink-2); }

.modal--result .modal__body { align-items: center; text-align: center; }
.result-icon {
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  font-family: var(--font-head);
  font-size: 32px;
  color: #fff;
}
.result-icon--success { background: #4f9e5d; box-shadow: inset 0 -4px 0 #3a7b46, 0 12px 24px rgba(79, 158, 93, .4); }
.result-icon--error { background: #d76565; box-shadow: inset 0 -4px 0 #b24d4d, 0 12px 24px rgba(215, 101, 101, .4); }

.field { display: flex; flex-direction: column; gap: 6px; }
.field__label { font-size: 13px; font-weight: 600; color: var(--ink-2); }
.field__input {
  height: 54px;
  padding: 0 14px;
  border: 2px solid transparent;
  border-radius: 4px;
  background: #eef2f5;
  color: var(--ink);
  font: inherit;
  font-size: 17px;
  font-weight: 600;
  text-align: center;
}
.field__input::placeholder { color: #95a5af; font-weight: 500; }
.field__input:focus { outline: none; border-color: var(--accent); background: #fff; }
.field__error { display: none; font-size: 13px; color: #c24f4f; text-align: center; }
.field.is-invalid .field__input { border-color: var(--error); }
.field.is-invalid .field__error { display: block; }
.field__input[type="email"] { font-size: 16px; }
.promo { display: flex; gap: 8px; }
.promo .field__input { flex: 1; min-width: 0; height: 48px; text-transform: uppercase; letter-spacing: .04em; }
.promo .field__input::placeholder { text-transform: none; letter-spacing: 0; }
.promo__apply {
  flex: none;
  padding: 0 16px;
  border: 0;
  border-radius: 4px;
  background: var(--accent);
  box-shadow: inset 0 -3px 0 #6aa9d2;
  color: var(--accent-deep);
  font-family: var(--font-head);
  font-size: 14px;
  text-transform: uppercase;
  cursor: pointer;
}
.promo__apply:hover { background: #9dcfee; }
.promo__status { min-height: 18px; font-size: 13px; text-align: center; color: var(--ink-3); }
.promo__status.is-ok { color: #2f7d40; font-weight: 600; }
.promo__status.is-error { color: #c24f4f; }
.modal__body { gap: 14px; }
.modal { overflow-y: auto; overscroll-behavior: contain; }
.modal__body { padding-top: 24px; }

/* ---------- Текстовые страницы ---------- */

.page-head { padding: 32px 0 4px; }
.page-head h1 { font-size: 30px; text-transform: uppercase; }
.page-head p { margin: 10px 0 0; color: var(--ink-2); max-width: 680px; }
@media (min-width: 700px) { .page-head h1 { font-size: 38px; } }

.rules { display: grid; grid-template-columns: minmax(0, 1fr); gap: 18px; padding-top: 22px; }
.rules__section { padding: 20px; border-radius: 4px; background: #fff; box-shadow: var(--shadow); }
.rules__section h2 { font-size: 19px; text-transform: uppercase; padding-bottom: 10px; border-bottom: 3px solid var(--highlight); display: inline-block; }
.rules__lead { margin: 14px 0 0; color: var(--highlight-ink); font-weight: 600; }
.rules__list { list-style: none; margin: 8px 0 0; padding: 0; }
.rules__list li {
  display: grid;
  grid-template-columns: 50px minmax(0, 1fr);
  gap: 8px;
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
  overflow-wrap: anywhere;
}
.rules__list li:last-child { border-bottom: 0; }
.rules__num { font-family: var(--font-head); font-size: 14px; color: var(--accent-ink); }
.rules__penalty {
  display: inline-block;
  margin-left: 4px;
  padding: 0 6px;
  border-radius: 3px;
  background: #fbeaea;
  color: #b54646;
  font-size: 13px;
  font-weight: 600;
}
.rules__note { color: var(--ink-3); font-size: 14px; }

.gallery { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; padding-top: 22px; }
@media (min-width: 760px) { .gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.gallery__item { margin: 0; overflow: hidden; border-radius: 4px; background: #fff; box-shadow: var(--shadow); }
.gallery__item img { width: 100%; height: auto; background: #120e1a; image-rendering: pixelated; }
.gallery__item figcaption { padding: 12px 16px; font-family: var(--font-head); text-transform: uppercase; }

/* ---------- Подвал ---------- */

.site-footer { margin-top: 64px; background: #e8eef2 var(--px-light); border-top: 1px solid var(--line); }
.site-footer__inner { display: grid; gap: 20px; padding-top: 32px; padding-bottom: 22px; }
.site-footer .brand__logo { width: 40px; filter: grayscale(.2); }
.site-footer .brand__name { font-size: 22px; }
.site-footer__note { margin: 12px 0 0; max-width: 440px; font-size: 14px; color: var(--ink-2); }
.site-footer__links { display: flex; flex-wrap: wrap; gap: 8px 24px; align-content: flex-start; }
.site-footer__links a { font-family: var(--font-head); font-size: 14px; text-transform: uppercase; color: var(--ink-2); }
.site-footer__links a:hover { color: var(--accent-ink); text-decoration: none; }
.site-footer__seller { margin: 12px 0 0; font-size: 13px; line-height: 1.6; color: var(--ink-2); }
.site-footer__legal {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 22px;
  padding-top: 14px;
  padding-bottom: 14px;
  border-top: 1px solid #d5dee4;
  font-size: 13px;
}
.site-footer__legal a { color: var(--ink-2); }
.site-footer__legal a:hover { color: var(--accent-ink); }
.site-footer__bottom {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding-top: 14px;
  padding-bottom: 24px;
  border-top: 1px solid #d5dee4;
  font-size: 14px;
  color: var(--ink-3);
}
@media (min-width: 760px) {
  .site-footer__inner { grid-template-columns: 1fr auto; align-items: start; }
  .site-footer__links { justify-content: flex-end; max-width: 460px; }
}

/* ---------- Документы ---------- */

.doc { max-width: 820px; padding: 22px 24px 8px; margin-top: 22px; border-radius: 4px; background: #fff; box-shadow: var(--shadow); }
.doc section { margin-bottom: 22px; }
.doc h2 { font-size: 18px; text-transform: uppercase; margin-bottom: 10px; }
.doc p, .doc li { color: var(--ink-2); }
.doc p { margin: 0 0 10px; }
.doc ul, .doc ol { margin: 0 0 10px; padding-left: 22px; }
.doc li { margin-bottom: 4px; }
.doc a { text-decoration: underline; }
mark.todo { padding: 0 4px; border-radius: 3px; background: #fde7c4; color: #8a5a17; font-weight: 600; }
@media (max-width: 599px) { .doc { padding: 18px 16px 4px; } }

/* ---------- Привилегии ---------- */

.perks-info { display: flex; flex-wrap: wrap; gap: 8px 22px; margin: 18px 0 0; padding: 0; list-style: none; color: var(--ink-2); font-size: 15px; }
.perks-info li { display: flex; align-items: center; gap: 8px; }
.perks-info li::before { content: ''; width: 10px; height: 10px; background: var(--highlight); box-shadow: inset 0 -2px 0 var(--highlight-dark); }

.goods { max-width: none; }
.goods h3 { margin: 0 0 10px; font-size: 18px; text-transform: uppercase; }
.goods__table { width: 100%; border-collapse: collapse; }
.goods__table th, .goods__table td { padding: 8px 10px 8px 0; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); color: var(--ink-2); }
.goods__table th { font-size: 13px; color: var(--ink-3); }
.goods__table tr:last-child td { border-bottom: 0; }
.goods__table td:first-child { color: var(--ink); font-weight: 600; white-space: nowrap; }
.goods__price { text-align: right !important; white-space: nowrap; }
.ranks { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; margin-top: 24px; align-items: start; }
@media (min-width: 700px) { .ranks { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1080px) { .ranks { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

.rank { display: flex; flex-direction: column; overflow: hidden; border-radius: 4px; background: #fff; box-shadow: var(--shadow); }
.rank__head {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px;
  background: var(--navy) var(--px-navy);
}
.rank__head::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--rank-a), var(--rank-b));
}
.rank__name { font-size: 22px; letter-spacing: .02em; }
.rank__name span { color: #55636d; }
.rank__name b {
  font-weight: 400;
  background: linear-gradient(90deg, var(--rank-a), var(--rank-b));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.rank__price { flex: none; padding: 4px 10px 5px; background: var(--highlight); box-shadow: inset 0 -3px 0 var(--highlight-dark); font-family: var(--font-head); color: #2b1b06; }
.rank__body { padding: 14px 18px 4px; }
.rank__perks { margin: 0; padding: 0; list-style: none; }
.rank__perks li {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  padding: 7px 0;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
  color: var(--ink-2);
}
.rank__perks code {
  flex: none;
  max-width: 50%;
  padding: 1px 6px;
  border-radius: 3px;
  background: #edf4f9;
  color: var(--accent-ink);
  font-family: ui-monospace, 'Cascadia Mono', Consolas, monospace;
  font-size: 13px;
  overflow-wrap: anywhere;
  text-align: right;
}
.rank__more summary {
  padding: 8px 0;
  font-family: var(--font-head);
  font-size: 13px;
  text-transform: uppercase;
  color: var(--accent-ink);
  cursor: pointer;
  list-style: none;
}
.rank__more summary::-webkit-details-marker { display: none; }
.rank__more summary::after { content: ' ▾'; }
.rank__more[open] summary::after { content: ' ▴'; }
.rank__extras { margin: 10px 0 12px; padding: 0; list-style: none; font-size: 14px; color: var(--ink); }
.rank__extras li { display: flex; gap: 8px; padding: 3px 0; }
.rank__extras li::before { content: '✓'; color: #3f9a52; font-weight: 700; }
.rank__buy { margin-top: auto; border-radius: 0; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  @view-transition { navigation: none; }
  ::view-transition-group(*), ::view-transition-old(*), ::view-transition-new(*) { animation: none !important; }
}

/* ---------- Согласия в форме заказа ---------- */

.check { display: flex; align-items: flex-start; gap: 10px; font-size: 13px; line-height: 1.5; color: var(--ink-2); text-align: left; cursor: pointer; }
.check input { flex: none; width: 18px; height: 18px; margin: 1px 0 0; accent-color: var(--accent-ink); }
.check a { color: var(--accent-ink); text-decoration: underline; }
.check__error { margin: -4px 0 0; font-size: 13px; color: #c24f4f; text-align: center; }

/* ---------- Способы оплаты ---------- */

.pay-logos { display: inline-flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 12px; }
.pay-logo {
  display: inline-grid;
  place-items: center;
  min-width: 64px;
  height: 30px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #fff;
  font-family: var(--font);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .02em;
}
.pay-logo--mir { color: #0f754e; }
.pay-logo--visa { color: #1a1f71; font-style: italic; }
.pay-logo--mc { color: #eb001b; }
.pay-logo--sbp { color: #5b2d90; }
.site-footer__pay {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 18px;
  padding-top: 12px;
  border-top: 1px solid #d5dee4;
  font-size: 13px;
  color: var(--ink-3);
}
.site-footer__pay .pay-logos { margin: 0; }
.pay-logo--img { height: 30px; width: auto; padding: 4px 8px; background: #fff; object-fit: contain; box-sizing: border-box; }
.pay-logo--tbank { color: #333; background: #ffdd2d; border-color: #ffdd2d; }
.pay-logo--tpay { color: #333; }
.pay-logos__bank { display: inline-flex; gap: 8px; text-decoration: none; }

/* ---------- Уведомление о cookie ---------- */

.cookie {
  position: fixed;
  left: 16px;
  right: 16px;
  bottom: 16px;
  z-index: 50;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 18px;
  max-width: 720px;
  margin: 0 auto;
  padding: 14px 18px;
  border-radius: 4px;
  background: #fff;
  box-shadow: var(--shadow), 0 0 0 1px var(--line);
  font-size: 14px;
  color: var(--ink-2);
}
.cookie[hidden] { display: none; }
.cookie p { flex: 1 1 320px; margin: 0; }
.cookie a { color: var(--accent-ink); text-decoration: underline; }
