:root {
  color-scheme: light;
  --bg: #cdc2ab; --bg-2: #c2b69c;
  --surface: #f8f3e9; --surface-2: #efe7d8; --surface-3: #e4dac6;
  --ink: #241c38; --ink-2: #443a60; --muted: #6d6486; --soft: #8d84a3;
  --line: #d3c4dd; --line-2: #bfacd0;
  --purple: #7b2fe0; --purple-2: #9a5cf0; --purple-3: #5f1fb5; --purple-soft: #f0e7fd;
  /* Fiolet uzywany jako KOLOR TEKSTU - w ciemnym motywie musi byc jasniejszy niz --purple-3. */
  --purple-ink: #5f1fb5;
  --gold: #e0a63a; --gold-soft: #fbf0d6;
  --green: #3f9e57; --green-soft: #e6f4e8;
  --red: #c8384f; --red-soft: #fbe9ec;
  --blue: #2f6fd0; --cyan: #2f8fa8; --orange: #d98328;
  --dark: #1d1633; --dark-2: #2a2047; --dark-3: #382c5c;
  --panel: var(--surface); --panel-2: var(--surface-2); --line-hot: var(--purple-2); --beige: #e8d8b0;
  --r-sm: 5px; --r-md: 8px; --r-lg: 12px; --radius: 8px;
  --s-1: 6px; --s-2: 10px; --s-3: 14px; --s-4: 18px; --s-5: 24px; --s-6: 34px; --s-7: 48px;
  --shadow: 0 10px 30px rgba(45,30,80,.12);
  --shadow-sm: 0 3px 10px rgba(45,30,80,.08);
  --ring: 0 0 0 3px rgba(123,47,224,.22);
  --font-body: Rajdhani, Inter, "Segoe UI", system-ui, sans-serif;
  --font-display: Rajdhani, "Segoe UI", system-ui, sans-serif;
  --font-numeric: Orbitron, Rajdhani, system-ui, sans-serif;
  font-family: var(--font-body);
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100vh; display: flex; flex-direction: column;
  background-color: var(--bg);
  color: var(--ink); font-size: 16px; line-height: 1.6;
}

img { max-width: 100%; height: auto; }
a { color: var(--purple); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 800; line-height: 1.15; margin: 0 0 var(--s-2); color: var(--ink); letter-spacing: .2px; }
h1 { font-size: clamp(23px, 3vw, 31px); text-transform: uppercase; }
h2 { font-size: clamp(19px, 2.4vw, 25px); text-transform: uppercase; }
h3 { font-size: 17px; text-transform: uppercase; }
p { margin: 0 0 var(--s-2); }
.muted { color: var(--muted); }
.soft-sep { height: 1px; background: var(--line); border: 0; margin: var(--s-4) 0; }
.ic { flex: 0 0 auto; display: inline-block; vertical-align: -.16em; }
main { width: min(1260px, calc(100% - 28px)); margin: 0 auto; flex: 1 0 auto; padding-bottom: var(--s-6); }
.site-header { position: sticky; top: 0; z-index: 60; background: var(--dark); border-bottom: 3px solid var(--purple-3); }
.header-inner { width: min(1260px, calc(100% - 28px)); margin: 0 auto; display: flex; align-items: center; gap: var(--s-3); min-height: 68px; }
.brand { display: flex; align-items: center; flex: 0 0 auto; margin-right: auto; }
.brand img { max-height: 42px; width: auto; }
.site-header nav { display: flex; align-items: center; gap: 2px; flex-wrap: wrap; }
.site-header nav a { display: inline-flex; align-items: center; gap: 7px; padding: 8px 12px; border-radius: var(--r-sm); color: #cfc4e6; font: 700 12px/1 var(--font-display); text-transform: uppercase; letter-spacing: .5px; white-space: nowrap; }
.site-header nav a:hover { background: rgba(255,255,255,.08); color: #fff; text-decoration: none; }
.site-header nav a.active, .site-header nav a.is-active { background: var(--purple); color: #fff; }
.header-actions { display: flex; align-items: center; gap: 10px; flex: 0 0 auto; }
.nav-toggle { display: none; width: 42px; min-height: 42px; flex-direction: column; justify-content: center; gap: 5px; background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.18); border-radius: var(--r-sm); cursor: pointer; padding: 0; box-shadow: none; }
.nav-toggle span { display: block; width: 20px; height: 2px; background: #fff; margin: 0 auto; transition: transform .18s ease, opacity .18s ease; }
.site-header.nav-open .nav-toggle span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.site-header.nav-open .nav-toggle span:nth-child(2) { opacity: 0; }
.site-header.nav-open .nav-toggle span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
.nav-count { display: inline-flex; align-items: center; justify-content: center; min-width: 19px; height: 19px; padding: 0 5px; margin-left: 5px; border-radius: 3px; background: var(--red); color: #fff; font: 800 11px/1 var(--font-numeric); }
.discord-link, .btn, button, input[type=submit] {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 11px 20px; border: 0; border-radius: var(--r-sm);
  background: var(--purple); color: #fff;
  font: 800 13px/1 var(--font-display); letter-spacing: .5px; text-transform: uppercase;
  cursor: pointer; text-align: center;
  box-shadow: inset 0 2px 0 rgba(255,255,255,.28), inset 0 -4px 0 rgba(0,0,0,.22), 0 3px 0 var(--purple-3);
  transition: transform .1s ease, filter .15s ease, box-shadow .1s ease;
}
.discord-link:hover, .btn:hover, button:hover { filter: brightness(1.07); text-decoration: none; color: #fff; }
.discord-link:active, .btn:active, button:active:not(:disabled) { transform: translateY(3px); box-shadow: inset 0 2px 0 rgba(255,255,255,.2), inset 0 -1px 0 rgba(0,0,0,.2); }
button:disabled, input[type=submit]:disabled, button[disabled] { cursor: not-allowed; opacity: .5; filter: grayscale(.4); transform: none; }
button:focus-visible, .btn:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible { outline: none; box-shadow: var(--ring); }
.btn.secondary, button.secondary { background: var(--surface); color: var(--ink); box-shadow: inset 0 0 0 1px var(--line-2), inset 0 2px 0 rgba(255,255,255,.7), inset 0 -3px 0 rgba(0,0,0,.06), 0 3px 0 var(--line-2); }
.btn.secondary:hover, button.secondary:hover { background: var(--surface-2); color: var(--ink); }
.btn.gold, button.gold { background: var(--gold); color: #3a2708; box-shadow: inset 0 2px 0 rgba(255,255,255,.5), inset 0 -4px 0 rgba(0,0,0,.14), 0 3px 0 #a9761f; }
.btn.red, button.red { background: var(--red); box-shadow: inset 0 2px 0 rgba(255,255,255,.25), inset 0 -4px 0 rgba(0,0,0,.2), 0 3px 0 #8d2436; }
.cart-btn { min-width: 92px; }
.btn-more { width: auto; justify-self: center; grid-column: 1 / -1; margin-top: var(--s-2); }
.link-more { display: inline-flex; align-items: center; gap: 6px; color: var(--purple); font: 700 12px/1 var(--font-display); text-transform: uppercase; letter-spacing: .4px; }
.side-logout-form { margin-top: var(--s-2); }
.side-logout { width: 100%; background: var(--red); box-shadow: inset 0 2px 0 rgba(255,255,255,.22), inset 0 -4px 0 rgba(0,0,0,.2), 0 3px 0 #8d2436; }
label { display: grid; gap: 6px; color: var(--ink-2); font: 700 12px/1.2 var(--font-display); text-transform: uppercase; letter-spacing: .3px; }
input, select, textarea { width: 100%; min-height: 42px; padding: 10px 12px; border: 1px solid var(--line-2); border-radius: var(--r-sm); background: #fff; color: var(--ink); font: 600 14px/1.3 var(--font-body); }
input::placeholder, textarea::placeholder { color: var(--soft); }
input:focus, select:focus, textarea:focus { border-color: var(--purple); box-shadow: var(--ring); outline: none; }
textarea { min-height: 96px; resize: vertical; }
input[type=checkbox] { width: auto; min-height: 0; height: 17px; accent-color: var(--purple); }
input[type=range] { padding: 0; height: 34px; border: 0; background: transparent; accent-color: var(--purple); }
.field-hint { display: block; margin-top: 4px; color: var(--muted); font: 600 12px/1.45 var(--font-body); text-transform: none; letter-spacing: 0; }
label.checkbox-field { display: flex; flex-direction: row; align-items: center; gap: 10px; min-height: 44px; padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--surface); text-transform: none; letter-spacing: 0; font-weight: 600; }
label.checkbox-field span { min-width: 0; overflow-wrap: anywhere; color: var(--ink-2); font-size: 13px; }
.grid { display: grid; gap: var(--s-3); grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
.grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid .wide, .form-grid .wide, .grid.two .wide { grid-column: 1 / -1; }
form.grid { margin-bottom: var(--s-4); }
.row, .hero-actions { display: flex; flex-wrap: wrap; gap: var(--s-2); align-items: center; }
.inline-form { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.stack-form { display: flex; flex-direction: column; gap: 6px; align-items: stretch; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s-3); }
.period-form { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.period-label { color: var(--muted); font: 700 12px/1 var(--font-display); text-transform: uppercase; }
.card, .panel, .widget, .shop-card, .stat, .panel-card, .side, .earn-stat, .vote-card, .news-card, .apply-card, .legal-item, .server-widget { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-sm); }
.card, .panel, .widget, .panel-card, .apply-card, .server-widget { padding: var(--s-4); }
.section { padding: var(--s-5) 0; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: var(--s-3); flex-wrap: wrap; margin-bottom: var(--s-3); padding-bottom: var(--s-2); border-bottom: 2px solid var(--line); }
.section-head h1, .section-head h2, .section-head h3 { margin: 0; }
.section-more { display: flex; justify-content: center; margin-top: var(--s-3); }
.layout-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(300px, 340px); gap: var(--s-4); align-items: start; }
.widget { margin-bottom: var(--s-3); }
.widget h3 { margin-bottom: var(--s-2); }
.hero-shell { display: grid; grid-template-columns: minmax(0, 1fr) minmax(300px, 340px); gap: var(--s-4); padding: var(--s-4) 0 0; align-items: stretch; }
.hero { position: relative; overflow: hidden; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: var(--s-7) var(--s-5); border: 1px solid var(--purple-3); border-radius: var(--r-lg); background: linear-gradient(165deg, #4a2a92, #2a1b58 58%, #201542); box-shadow: var(--shadow); text-align: center; }

.hero-content { position: relative; z-index: 2; width: 100%; max-width: 620px; display: flex; flex-direction: column; align-items: center; gap: var(--s-4); }
.hero-logo { width: min(430px, 88%); }
.tagline { margin: 0; color: #d8ccf2; font: 700 13px/1.5 var(--font-display); letter-spacing: 3px; text-transform: uppercase; }
.hero-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s-2); width: 100%; }
.mini-stat { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; padding: var(--s-3) var(--s-2); min-height: 86px; background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.14); border-radius: var(--radius); box-shadow: none; text-align: center; }
.mini-stat strong { color: #fff; font: 800 19px/1 var(--font-numeric); }
.mini-stat span { color: #bdb0d8; font: 700 10px/1.35 var(--font-display); text-transform: uppercase; letter-spacing: .4px; overflow-wrap: anywhere; }
.hero-actions { justify-content: center; }
.ip-box { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; justify-content: center; padding: 10px 12px; border: 1px solid rgba(255,255,255,.16); border-radius: var(--r-sm); background: rgba(0,0,0,.24); }
.ip-box span { color: #bdb0d8; font: 700 11px/1 var(--font-display); text-transform: uppercase; letter-spacing: .5px; }
.ip-box strong { color: #fff; font: 800 17px/1 var(--font-numeric); letter-spacing: 1px; }
.hero-side { display: flex; flex-direction: column; }
.status-pill { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 3px; background: var(--green-soft); color: var(--green); font: 800 10px/1.6 var(--font-display); text-transform: uppercase; letter-spacing: .5px; border: 1px solid rgba(63,158,87,.3); }
.status-pill.is-offline { background: var(--red-soft); color: var(--red); border-color: rgba(200,56,79,.3); }
.server-players { display: flex; align-items: center; gap: 12px; margin: var(--s-2) 0; }
.server-count { font: 800 34px/1 var(--font-numeric); color: var(--purple); }
.server-players-label { color: var(--muted); font: 700 11px/1.25 var(--font-display); text-transform: uppercase; }
.capacity-bar { height: 9px; border-radius: 3px; background: var(--surface-3); border: 1px solid var(--line); overflow: hidden; }
.capacity-bar span { display: block; height: 100%; background: var(--purple); transition: width .4s ease; }
.capacity-text { margin-top: 6px; font-size: 13px; }
.shop-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: var(--s-3); }
.cat-btn { min-height: 38px; padding: 8px 14px; background: var(--surface); color: var(--ink-2); box-shadow: inset 0 0 0 1px var(--line-2), inset 0 2px 0 rgba(255,255,255,.6), 0 2px 0 var(--line-2); font-size: 12px; }
.cat-btn.active { background: var(--purple); color: #fff; box-shadow: inset 0 2px 0 rgba(255,255,255,.25), 0 2px 0 var(--purple-3); }
.shop-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--s-3); align-items: stretch; }
.shop-card { display: flex; flex-direction: column; justify-content: space-between; gap: var(--s-2); padding: var(--s-3); transition: transform .14s ease, box-shadow .14s ease; }
.shop-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.product-type { color: var(--purple); font: 800 10px/1.4 var(--font-display); text-transform: uppercase; letter-spacing: .6px; margin-bottom: 8px; }
.product-art { display: grid; place-items: center; height: 92px; margin-bottom: var(--s-2); border-radius: var(--r-sm); background: var(--purple-soft); border: 1px solid #e2d5f7; color: var(--purple); }
.product-art img { max-height: 72px; width: auto; }
.shop-card h3 { font-size: 15px; margin-bottom: 4px; }
.card-desc { color: var(--muted); font-size: 13px; margin: 0 0 var(--s-2); }
.duration-chip, .promo-chip, .creator-code-chip, .creator-flag { display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px; border-radius: 3px; background: var(--surface-3); color: var(--ink-2); font: 800 10px/1.6 var(--font-display); text-transform: uppercase; letter-spacing: .4px; border: 1px solid var(--line); }
.promo-chip { background: var(--gold-soft); color: #8a6413; border-color: rgba(224,166,58,.4); }
.creator-code-chip { background: var(--purple-soft); color: var(--purple-ink); border-color: #e2d5f7; }
.price-box { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; margin: var(--s-2) 0; }
.price, .price-now { color: var(--ink); font: 800 20px/1 var(--font-numeric); }
.price-old, .price-was { color: var(--soft); font-size: 13px; text-decoration: line-through; }
.promo-banner { padding: 12px 14px; margin-bottom: var(--s-3); border-radius: var(--r-sm); border: 1px solid rgba(224,166,58,.45); background: var(--gold-soft); color: #7d5a10; font-weight: 700; }
.shop-disabled-banner { border-color: rgba(200,56,79,.4); background: var(--red-soft); color: #8f2739; }
.buyer { display: grid; grid-template-columns: auto minmax(0,1fr) auto; align-items: center; gap: var(--s-2); padding: 9px 0; border-bottom: 1px solid var(--line); }
.buyer:last-child { border-bottom: 0; }
.buyer span { display: inline-flex; align-items: center; gap: 8px; min-width: 0; }
.rank, .rank-num { display: inline-flex; align-items: center; justify-content: center; min-width: 24px; height: 24px; padding: 0 5px; border-radius: 3px; background: var(--purple-soft); color: var(--purple-ink); font: 800 12px/1 var(--font-numeric); }
.head, .thumb { width: 34px; height: 34px; border-radius: 3px; image-rendering: pixelated; border: 1px solid var(--line); background: var(--surface-3); }
.creator-rank { display: grid; grid-template-columns: auto auto minmax(0,1fr); align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.creator-rank:last-child { border-bottom: 0; }
.creator-rank.is-first .rank-num { background: var(--gold); color: #3a2708; }
.gold-badge { background: var(--gold-soft); color: #8a6413; border-color: rgba(224,166,58,.45); }
.live-head { align-items: center; }
.live-badge { display: inline-flex; align-items: center; gap: 6px; padding: 3px 9px; border-radius: 3px; background: var(--red-soft); color: var(--red); font: 800 10px/1.6 var(--font-display); text-transform: uppercase; border: 1px solid rgba(200,56,79,.3); }
.live-row { display: grid; grid-template-columns: auto minmax(0,1fr) auto; align-items: center; gap: var(--s-2); padding: 10px 0; border-bottom: 1px solid var(--line); }
.live-row:last-child { border-bottom: 0; }
.live-info { min-width: 0; }
.live-info strong { display: block; }
.live-meta { display: inline-flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 3px; }
.viewers { color: var(--muted); font-size: 12px; display: inline-flex; align-items: center; gap: 4px; }
.platform-tag { display: inline-flex; align-items: center; padding: 2px 7px; border-radius: 3px; font: 800 10px/1.6 var(--font-display); text-transform: uppercase; letter-spacing: .4px; color: #fff; background: var(--purple); }
.platform-twitch { background: #7b3ff2; }
.platform-youtube { background: #cc2b2b; }
.platform-tiktok { background: #1f1f28; }
.platform-kick { background: #3f9e57; }
.live-empty { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 14px; padding: var(--s-2) 0; }
.live-empty-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--soft); flex: 0 0 auto; }
.is-live .live-empty-dot { background: var(--red); }
.live-watch { flex: 0 0 auto; }
.creators-section { padding: var(--s-5) 0; }
.creators-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: var(--s-3); }
.creator-feature { display: grid; grid-template-columns: 76px minmax(0,1fr); gap: var(--s-3); align-items: center; }
.news-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: var(--s-3); }
.news-card { overflow: hidden; display: flex; flex-direction: column; }
.news-card img { width: 100%; height: 160px; object-fit: cover; border-bottom: 1px solid var(--line); }
.news-card > div { padding: var(--s-3); }
.news-list { display: flex; flex-direction: column; gap: var(--s-2); }
.news-item { display: grid; grid-template-columns: 130px minmax(0, 1fr) auto; gap: var(--s-3); align-items: center; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-sm); }
.news-item-thumb { width: 100%; height: 88px; object-fit: cover; }
.news-item-body { padding: var(--s-3) 0; min-width: 0; }
.news-item-body h3 { margin-bottom: 4px; }
.news-item-meta { color: var(--muted); font-size: 12px; }
.news-item-actions { display: flex; gap: 6px; padding-right: var(--s-3); flex-wrap: wrap; }
.modal-backdrop { position: fixed; inset: 0; z-index: 200; display: none; align-items: center; justify-content: center; padding: 18px; background: rgba(29,22,51,.62); }
.modal-backdrop.open { display: flex; }
.purchase-modal, .article-modal, .login-modal { width: min(720px, 100%); max-height: 90vh; overflow-y: auto; background: var(--surface); border: 1px solid var(--line-2); border-radius: var(--r-lg); box-shadow: var(--shadow); padding: var(--s-5); }
.login-modal { width: min(440px, 100%); }
.login-modal .form-grid { grid-template-columns: minmax(0, 1fr); }
.modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: var(--s-3); margin-bottom: var(--s-3); }
.modal-head h1, .modal-head h2 { margin: 0; }
.modal-close { min-width: 42px; padding: 0; background: var(--surface-3); color: var(--ink); box-shadow: inset 0 0 0 1px var(--line-2); }
.modal-close:hover { background: var(--line); color: var(--ink); }
.modal-product { display: grid; grid-template-columns: 92px minmax(0,1fr); gap: var(--s-3); align-items: center; margin-bottom: var(--s-3); }
.modal-art { display: grid; place-items: center; height: 92px; border-radius: var(--r-sm); background: var(--purple-soft); border: 1px solid #e2d5f7; color: var(--purple); }
.modal-total { display: flex; justify-content: space-between; align-items: center; margin-top: var(--s-3); padding-top: var(--s-3); border-top: 1px solid var(--line); }
.article-modal-thumb { width: 100%; max-height: 300px; object-fit: cover; border-radius: var(--r-sm); margin-bottom: var(--s-3); }
.article-modal-body { line-height: 1.7; }
table { width: 100%; border-collapse: collapse; margin: 0 0 var(--s-3); background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
th, td { padding: 10px 12px; text-align: left; border-bottom: 1px solid var(--line); font-size: 14px; vertical-align: middle; }
th { background: var(--surface-2); color: var(--ink-2); font: 800 11px/1.3 var(--font-display); text-transform: uppercase; letter-spacing: .4px; }
tr:last-child td { border-bottom: 0; }
table form { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; margin: 0 0 6px; }
table input, table select { min-height: 36px; font-size: 13px; }
table button, table .btn { min-height: 36px; padding: 8px 12px; font-size: 11px; }
.badge { display: inline-flex; align-items: center; gap: 5px; padding: 4px 9px; border-radius: 3px; font: 800 10px/1.6 var(--font-display); text-transform: uppercase; letter-spacing: .4px; border: 1px solid var(--line); background: var(--surface-3); color: var(--ink-2); }
.badge.paid, .badge.accepted, .badge.approved, .badge.available, .badge.active, .badge.delivered, .badge.granted, .badge.completed { background: var(--green-soft); color: var(--green); border-color: rgba(63,158,87,.3); }
.badge.rejected, .badge.red, .badge.failed, .badge.cancelled, .badge.declined, .badge.refunded { background: var(--red-soft); color: var(--red); border-color: rgba(200,56,79,.3); }
.badge.requested, .badge.pending, .badge.reviewed, .badge.new, .badge.processing { background: var(--gold-soft); color: #8a6413; border-color: rgba(224,166,58,.4); }
.notice, .danger, .alert-payout { display: block; padding: 12px 14px; margin: 0 0 var(--s-3); border-radius: var(--r-sm); font-weight: 600; }
.notice { background: var(--green-soft); border: 1px solid rgba(63,158,87,.3); color: #23653a; }
.danger { background: var(--red-soft); border: 1px solid rgba(200,56,79,.3); color: #8f2739; }
.alert-payout { background: var(--gold-soft); border: 1px solid rgba(224,166,58,.45); color: #7d5a10; }
.notice .ic, .danger .ic, .alert-payout .ic { margin-right: 4px; }
code { font-family: ui-monospace, Consolas, monospace; background: var(--surface-3); border: 1px solid var(--line); padding: 1px 6px; border-radius: 3px; color: var(--purple-ink); font-size: 13px; }
.dashboard { display: grid; grid-template-columns: 236px minmax(0, 1fr); gap: var(--s-4); padding: var(--s-5) 0; align-items: start; }
.side { display: flex; flex-direction: column; gap: 2px; padding: var(--s-3); position: sticky; top: 84px; }
.side > strong { display: block; padding: 4px 8px var(--s-2); font: 800 12px/1.2 var(--font-display); text-transform: uppercase; letter-spacing: .5px; color: var(--ink); border-bottom: 1px solid var(--line); margin-bottom: 6px; }
.side > span { padding: 3px 8px; color: var(--muted); font-size: 12px; }
.side a { padding: 8px 10px; border-radius: var(--r-sm); color: var(--ink-2); font: 700 13px/1.2 var(--font-display); display: flex; align-items: center; }
.side a:hover { background: var(--surface-2); text-decoration: none; }
.side a.is-active { background: var(--purple); color: #fff; }
.side .btn { margin-top: 6px; }
.side-group { margin-top: var(--s-2); padding: 5px 8px 2px; color: var(--soft); font: 800 10px/1 var(--font-display); text-transform: uppercase; letter-spacing: .6px; }
.panel { min-width: 0; }
.panel-card { margin-bottom: var(--s-3); }
.stat, .earn-stat { display: flex; flex-direction: column; gap: 4px; padding: var(--s-3); }
.stat .label, .earn-stat .label { color: var(--muted); font: 700 11px/1.2 var(--font-display); text-transform: uppercase; letter-spacing: .4px; }
.stat .value, .earn-stat .value { color: var(--ink); font: 800 22px/1.1 var(--font-numeric); }
.earn-stat.available .value { color: var(--green); }
.earn-stat.pending .value { color: var(--gold); }
.earnings-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: var(--s-2); margin-bottom: var(--s-4); }
.admin-image-preview { max-width: 120px; border: 1px solid var(--line); border-radius: var(--r-sm); }
.admin-image-preview.wide-preview { max-width: 260px; }
.day-group { margin: 0 0 10px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); overflow: hidden; }
.day-group > summary { cursor: pointer; padding: 11px 14px; font: 700 13px/1.3 var(--font-display); color: var(--ink); list-style: none; }
.day-group > summary::-webkit-details-marker { display: none; }
.day-group > summary::before { content: "\25B8"; display: inline-block; margin-right: 8px; color: var(--purple); transition: transform .15s ease; }
.day-group[open] > summary::before { transform: rotate(90deg); }
.day-group > summary:hover { background: var(--surface-2); }
.day-group[open] > summary { border-bottom: 1px solid var(--line); }
.day-group table { border: 0; border-radius: 0; margin: 0; }
.perm-title { display: block; margin-bottom: 8px; color: var(--ink-2); font: 700 12px/1.2 var(--font-display); text-transform: uppercase; }
.perm-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(185px, 1fr)); gap: 12px; }
.perm-group { padding: 12px; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--surface-2); }
.perm-group-label { display: block; margin-bottom: 8px; color: var(--ink); font: 800 11px/1.2 var(--font-display); text-transform: uppercase; letter-spacing: .4px; }
.perm-item { display: flex; flex-direction: row; align-items: center; gap: 8px; padding: 5px 0; cursor: pointer; text-transform: none; letter-spacing: 0; font-weight: 600; }
.perm-item input[type=checkbox] { flex: 0 0 auto; margin: 0; }
.perm-item span { color: var(--ink-2); font-size: 13px; }
.totp-box { display: flex; flex-wrap: wrap; gap: var(--s-4); align-items: center; margin: var(--s-3) 0; padding: var(--s-4); border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface-2); }
.totp-qr { width: 168px; height: 168px; background: #fff; padding: 8px; border: 1px solid var(--line); border-radius: var(--r-sm); }
.totp-info { min-width: 220px; flex: 1; }
.totp-key { font-family: ui-monospace, Consolas, monospace; font-size: 15px; letter-spacing: 2px; word-break: break-all; color: var(--purple-ink); }
.auth-card { max-width: 520px; margin: 60px auto; }
.code-info { margin-top: 6px; font-size: 13px; }
.legal-page { line-height: 1.75; }
.legal-page h2 { margin-top: var(--s-5); }
.legal-item { padding: var(--s-3); margin-bottom: var(--s-2); }
.guardian-block { grid-column: 1 / -1; margin: 4px 0; padding: 16px 18px; border: 1px solid #e2d5f7; border-radius: var(--r-sm); background: var(--purple-soft); }
.guardian-block > h3 { margin: 0 0 4px; font-size: 13px; }
.guardian-block > .grid { margin-bottom: 12px; }
.recruit-app { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); margin-bottom: var(--s-2); overflow: hidden; box-shadow: var(--shadow-sm); }
.recruit-app > summary { cursor: pointer; padding: 12px 14px; font-weight: 700; }
.recruit-app-body { padding: 0 14px 14px; }
.recruit-closed { padding: var(--s-4); text-align: center; }
.recruit-fields { display: grid; gap: var(--s-2); }
.vote-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: var(--s-3); }
.vote-card { display: flex; flex-direction: column; gap: var(--s-2); padding: var(--s-3); }
.vote-embed-wrap, .vote-embed { max-width: 100%; overflow: hidden; }
.vote-embed iframe { max-width: 100%; border: 0; }
.apply-card { margin-top: var(--s-4); }
.foot { margin-top: auto; background: var(--dark); color: #cfc4e6; border-top: 3px solid var(--purple-3); }
.footer-inner { width: min(1260px, calc(100% - 28px)); margin: 0 auto; display: grid; grid-template-columns: minmax(220px, 1.2fr) repeat(auto-fit, minmax(150px, 1fr)); gap: var(--s-4); padding: var(--s-6) 0 var(--s-4); }
.footer-brand p { color: #a99cc4; font-size: 14px; }
.footer-logo { max-height: 40px; margin-bottom: var(--s-2); }
.footer-col h4 { color: #fff; font: 800 12px/1.2 var(--font-display); text-transform: uppercase; letter-spacing: .5px; margin-bottom: var(--s-2); }
.footer-col a { display: block; padding: 4px 0; color: #cfc4e6; font-size: 14px; }
.footer-col a:hover { color: #fff; }
.footer-bottom { width: min(1260px, calc(100% - 28px)); margin: 0 auto; padding: var(--s-3) 0; border-top: 1px solid rgba(255,255,255,.1); color: #a99cc4; font-size: 13px; text-align: center; }
.chat-widget { padding: 0; overflow: hidden; }
.chat-head { display: flex; align-items: center; gap: 8px; padding: 12px 14px; border-bottom: 1px solid var(--line); background: var(--surface-2); }
.chat-head h3 { margin: 0; font-size: 14px; flex: 1 1 auto; }
.chat-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); flex: 0 0 auto; }
.chat-dot.off { background: var(--soft); }
.chat-list { display: flex; flex-direction: column; gap: 2px; max-height: 320px; overflow-y: auto; padding: 8px; }
.chat-msg { display: grid; grid-template-columns: 22px minmax(0, 1fr); gap: 8px; align-items: start; padding: 5px 6px; border-radius: var(--r-sm); }
.chat-msg:nth-child(odd) { background: var(--surface-2); }
.chat-msg img { width: 22px; height: 22px; border-radius: 3px; image-rendering: pixelated; }
.chat-nick { color: var(--purple-ink); font: 800 12px/1.35 var(--font-display); }
.chat-text { color: var(--ink-2); font-size: 13px; line-height: 1.45; overflow-wrap: anywhere; }
.chat-empty { padding: var(--s-4); text-align: center; color: var(--muted); font-size: 13px; }
.chat-foot { padding: 8px 14px; border-top: 1px solid var(--line); color: var(--muted); font-size: 12px; text-align: center; }
.reveal { opacity: 1; }
@media (prefers-reduced-motion: no-preference) { .reveal { animation: fadeUp .4s ease both; } }
@keyframes fadeUp { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@media (max-width: 1080px) {
  .hero-shell, .layout-grid { grid-template-columns: minmax(0, 1fr); }
  .hero-side { flex-direction: row; flex-wrap: wrap; gap: var(--s-3); }
  .hero-side .widget { flex: 1 1 260px; margin-bottom: 0; }
  .shop-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .dashboard { grid-template-columns: minmax(0, 1fr); }
  .side { position: static; }
}
@media (max-width: 860px) {
  .site-header nav { display: none; position: absolute; top: 68px; left: 0; right: 0; flex-direction: column; align-items: stretch; gap: 0; padding: 8px; background: var(--dark-2); border-bottom: 3px solid var(--purple-3); }
  .site-header.nav-open nav { display: flex; }
  .nav-toggle { display: flex; }
  .shop-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .news-item { grid-template-columns: minmax(0, 1fr); }
  .news-item-thumb { height: 150px; }
  .news-item-body { padding: var(--s-3); }
  .news-item-actions { padding: 0 var(--s-3) var(--s-3); }
  .grid.two, .form-grid { grid-template-columns: minmax(0, 1fr); }
  .modal-product { grid-template-columns: minmax(0, 1fr); }
  .buyer, .live-row { grid-template-columns: auto minmax(0, 1fr); }
  .buyer > :last-child, .live-row > :last-child { grid-column: 1 / -1; }
}
@media (max-width: 560px) {
  .hero { padding: var(--s-5) var(--s-3); }
  .hero-stats { grid-template-columns: minmax(0, 1fr); }
  .mini-stat { flex-direction: row; justify-content: space-between; min-height: 0; text-align: left; }
  .shop-grid, .creators-grid, .news-grid, .vote-grid { grid-template-columns: minmax(0, 1fr); }
  .hero-actions { flex-direction: column; align-items: stretch; }
  .hero-actions .btn, .hero-actions button { width: 100%; }
  .footer-inner { grid-template-columns: minmax(0, 1fr); }
  .creator-feature { grid-template-columns: 56px minmax(0, 1fr); }
}
.nav-recruit { color: var(--gold) !important; }
.sub { color: var(--muted); font-size: 14px; margin: 0 0 var(--s-3); }

#particles { position: fixed; inset: 0; width: 100vw; height: 100vh; z-index: -2; pointer-events: none; opacity: .55; }
.ambient {
  display: block; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(680px 480px at 12% 8%, rgba(123,47,224,.16), transparent 62%),
    radial-gradient(560px 420px at 88% 22%, rgba(47,143,168,.13), transparent 60%),
    radial-gradient(760px 520px at 70% 92%, rgba(224,166,58,.12), transparent 62%);
}



@media (prefers-reduced-motion: no-preference) {
  
  
}
@keyframes driftA { from { transform: translate3d(0,0,0) scale(1); } to { transform: translate3d(-38px, 26px, 0) scale(1.06); } }
@keyframes driftB { from { transform: translate3d(0,0,0) scale(1); } to { transform: translate3d(30px, -22px, 0) scale(1.08); } }

.footer, .foot { position: relative; z-index: 1; }
main { position: relative; }
.site-header { position: sticky; top: 0; z-index: 200; }
.site-header {
  background: linear-gradient(180deg, #2f2452, #1f1739);
  border-bottom: 3px solid var(--gold);
  box-shadow: 0 6px 22px rgba(45,30,80,.18);
}
.site-header nav a { color: #d5cae9; }
.site-header nav a.active, .site-header nav a.is-active {
  background: var(--purple); color: #fff;
  box-shadow: inset 0 -3px 0 rgba(0,0,0,.25), inset 0 2px 0 rgba(255,255,255,.2);
}

.footer {
  margin-top: auto; background: linear-gradient(180deg, #241b42, #17112c);
  color: #cfc4e6; border-top: 3px solid var(--gold);
}
.footer .footer-brand p { color: #a99cc4; font-size: 14px; }
.footer .footer-col h4 { color: #fff; font: 800 12px/1.2 var(--font-display); text-transform: uppercase; letter-spacing: .5px; margin-bottom: var(--s-2); }
.footer .footer-col a, .footer .footer-col p { display: block; padding: 3px 0; color: #cfc4e6; font-size: 14px; }
.footer .footer-col a:hover { color: #fff; }
.footer .footer-bottom { color: #a99cc4; }

.chat-widget { border: 2px solid var(--purple); box-shadow: 0 6px 20px rgba(123,47,224,.18); }
.chat-head { background: linear-gradient(180deg, #7b2fe0, #5f1fb5); border-bottom: 0; color: #fff; }
.chat-head h3 { color: #fff; }
.chat-head .ic { color: #fff; }
.chat-dot { background: #7bff9e; box-shadow: 0 0 0 3px rgba(255,255,255,.22); }
.chat-dot.off { background: #cbbde6; box-shadow: none; }
.chat-list { max-height: 340px; }
.chat-msg { padding: 6px 8px; }
.chat-msg:nth-child(odd) { background: var(--purple-soft); }
.chat-nick { color: var(--purple-ink); }
.chat-text { color: var(--ink); }
.chat-foot { background: var(--surface-2); }

.creator-card { position: relative; display: flex; flex-direction: column; align-items: flex-start; gap: 8px; padding: var(--s-4); }
.creator-card .head { width: 46px; height: 46px; }
.creator-card h3 { margin: 0; }
.creator-card p { margin: 0; }
.creator-card.is-featured { border-color: var(--gold); box-shadow: 0 6px 18px rgba(224,166,58,.22); }
.creator-flag { order: -1; align-self: flex-start; background: var(--gold-soft); color: #8a6413; border-color: rgba(224,166,58,.5); }
.creator-card .creator-code-chip { margin-top: auto; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
[id] { scroll-margin-top: 88px; }
#shop, #top { scroll-margin-top: 92px; }

.card, .panel, .widget, .shop-card, .stat, .panel-card, .side, .earn-stat,
.vote-card, .news-card, .apply-card, .legal-item, .server-widget, .news-item,
.recruit-app, .day-group, .totp-box, .perm-group, .purchase-modal, .article-modal, .login-modal {
  border-width: 2px;
  border-color: var(--line-2);
}
.shop-card:hover, .vote-card:hover, .news-card:hover { border-color: var(--purple-2); }
label.checkbox-field, .guardian-block { border-width: 2px; }
input, select, textarea { border-width: 2px; }
table { border-width: 2px; }
.chat-widget { border-color: var(--purple); }





.rank-card { padding: var(--s-4); }
.rank-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.rank-row {
  display: grid; grid-template-columns: 52px 34px minmax(0, 1fr) auto;
  align-items: center; gap: var(--s-2);
  padding: 9px 12px; border: 2px solid var(--line); border-radius: var(--r-sm);
  background: var(--surface-2);
}
.rank-pos { font: 800 15px/1 var(--font-numeric); color: var(--purple-ink); }
.rank-nick { font: 700 15px/1.2 var(--font-display); color: var(--ink); overflow-wrap: anywhere; }
.rank-value { font: 800 15px/1 var(--font-numeric); color: var(--ink); white-space: nowrap; }
.rank-row.is-podium { background: var(--surface); }
.rank-row.rank-1 { border-color: var(--gold); box-shadow: inset 0 0 0 1px rgba(224,166,58,.35); }
.rank-row.rank-1 .rank-pos, .rank-row.rank-1 .rank-value { color: #8a6413; }
.rank-row.rank-2 { border-color: #b9b3c9; }
.rank-row.rank-3 { border-color: #cba07a; }
a.cat-btn { text-decoration: none; }
a.cat-btn:hover { text-decoration: none; }

.ambient {
  display: block; position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: -1; pointer-events: none; overflow: hidden;
  background:
    radial-gradient(760px 540px at 10% 6%, rgba(123,47,224,.16), transparent 62%),
    radial-gradient(640px 480px at 90% 22%, rgba(47,143,168,.12), transparent 60%),
    radial-gradient(820px 560px at 66% 94%, rgba(224,166,58,.11), transparent 62%);
}

.planet-1 { width: 230px; top: 8%; right: 5%; opacity: .85; }
.planet-2 { width: 140px; bottom: 12%; left: 4%; opacity: .8; }
.planet-3 { width: 88px; top: 46%; left: 12%; opacity: .7; }

.section-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: var(--s-3); flex-wrap: wrap;
  margin: 0 0 var(--s-3); padding: 11px 16px;
  border: 2px solid var(--purple-3); border-radius: var(--r-sm);
  background: linear-gradient(180deg, #7b2fe0, #5f1fb5);
  box-shadow: inset 0 2px 0 rgba(255,255,255,.18), inset 0 -3px 0 rgba(0,0,0,.18);
}
.section-head h1, .section-head h2, .section-head h3 { margin: 0; color: #fff; }
.section-head .muted { color: #e2d6f7; font-size: 13px; }
.section-head .ic { color: #fff; }
.section-head .link-more { color: #fff; }
.section-head .link-more:hover { color: #ffe9a8; text-decoration: none; }
.section-head .live-badge { background: rgba(255,255,255,.16); color: #fff; border-color: rgba(255,255,255,.3); }

.widget > h3, .card > h2:first-child, .card > h3:first-child, .panel-card > h3:first-child {
  margin: calc(var(--s-4) * -1) calc(var(--s-4) * -1) var(--s-3);
  padding: 11px 16px;
  background: linear-gradient(180deg, #7b2fe0, #5f1fb5);
  color: #fff;
  border-bottom: 2px solid var(--purple-3);
  box-shadow: inset 0 2px 0 rgba(255,255,255,.18);
}
.widget > h3 .ic, .card > h2:first-child .ic, .card > h3:first-child .ic { color: #fff; }
.chat-widget > .chat-head { margin: 0; }
.rank-card > .section-head { margin-top: 0; }
.day-group > summary, .recruit-app > summary { background: var(--surface-2); }
.auth-card > h1:first-child { margin: calc(var(--s-4) * -1) calc(var(--s-4) * -1) var(--s-3); padding: 12px 16px; background: linear-gradient(180deg, #7b2fe0, #5f1fb5); color: #fff; border-bottom: 2px solid var(--purple-3); }
@media (max-width: 560px) {
  .section-head { padding: 10px 12px; }
  .widget > h3, .card > h2:first-child, .card > h3:first-child { padding: 10px 12px; }
}

.nice-select { position: relative; width: 100%; }
.nice-select > select { position: absolute; opacity: 0; pointer-events: none; width: 100%; height: 100%; }
.nice-select-toggle {
  width: 100%; min-height: 42px; padding: 10px 34px 10px 12px;
  display: flex; align-items: center; justify-content: flex-start; text-align: left;
  border-radius: var(--r-sm); background: #fff; color: var(--ink);
  font: 600 14px/1.3 var(--font-body); text-transform: none; letter-spacing: 0;
  box-shadow: inset 0 0 0 2px var(--line-2); cursor: pointer;
}
.nice-select-toggle:hover { filter: none; background: #fff; color: var(--ink); }
.nice-select-toggle::after {
  content: ""; position: absolute; right: 13px; top: 50%; width: 8px; height: 8px;
  border-right: 2px solid var(--purple); border-bottom: 2px solid var(--purple);
  transform: translateY(-70%) rotate(45deg); transition: transform .15s ease;
}
.nice-select.open .nice-select-toggle { box-shadow: inset 0 0 0 2px var(--purple), var(--ring); }
.nice-select.open .nice-select-toggle::after { transform: translateY(-30%) rotate(-135deg); }
.nice-select-toggle.is-placeholder span { color: var(--soft); }
.nice-select-menu {
  display: none; position: absolute; z-index: 40; top: calc(100% + 4px); left: 0; right: 0;
  max-height: 260px; overflow-y: auto; padding: 4px;
  background: var(--surface); border: 2px solid var(--purple-3); border-radius: var(--r-sm);
  box-shadow: var(--shadow);
}
.nice-select.open .nice-select-menu { display: block; }
.nice-select-option {
  padding: 9px 11px; border-radius: 4px; cursor: pointer;
  color: var(--ink-2); font: 600 14px/1.3 var(--font-body);
}
.nice-select-option:hover { background: var(--purple-soft); color: var(--purple-ink); }
.nice-select-option.is-selected { background: var(--purple); color: #fff; }

.nav-indicator { display: none; }
.status-pill.offline, .offline { background: var(--red-soft); color: var(--red); border-color: rgba(200,56,79,.3); }
.is-over-limit { display: none; }
.is-expanded .is-over-limit { display: flex; }
.is-expanded.shop-grid .is-over-limit, .is-expanded.creators-grid .is-over-limit, .is-expanded.news-grid .is-over-limit { display: flex; }
.is-good { color: var(--green); font-weight: 700; }

.modal-total { flex-wrap: wrap; gap: var(--s-2); margin-bottom: var(--s-4); padding: var(--s-3); background: var(--surface-2); border: 2px solid var(--line-2); border-radius: var(--r-sm); }
.modal-total .promo-chip { margin-left: 6px; font-size: 12px; padding: 5px 11px; }
.purchase-modal form > p:last-child, .purchase-modal .modal-actions { margin-top: var(--s-4); }
.purchase-modal .cart-btn, .purchase-modal button[type=submit] { width: 100%; margin-top: var(--s-2); }

.shop-card { padding: 0; overflow: hidden; }
.shop-card > div:first-child { padding: var(--s-3); }
.shop-card .product-type {
  margin: 0 0 var(--s-3); padding: 8px 12px;
  background: linear-gradient(180deg, #7b2fe0, #5f1fb5); color: #fff;
  border-bottom: 2px solid var(--purple-3);
}
.shop-card > div:first-child { padding-top: 0; }
.shop-card > *:not(:first-child) { padding: 0 var(--s-3) var(--s-3); }
.shop-card:hover { border-color: var(--gold); box-shadow: 0 8px 22px rgba(224,166,58,.25); }
.shop-card:hover .product-type { background: linear-gradient(180deg, #e8b44a, #c08a1f); border-bottom-color: #a9761f; color: #33230a; }
.vote-card:hover, .news-card:hover, .rank-row:hover { border-color: var(--gold); }


.hero { border-color: var(--purple); }
.layout-grid { padding-top: var(--s-4); }
.hero-side .widget:last-child { margin-bottom: 0; }

@media (max-width: 860px) {
  .site-header nav {
    position: fixed; top: 68px; left: 0; right: 0; bottom: 0;
    z-index: 90; overflow-y: auto; padding: 10px;
    background: var(--dark-2); border-bottom: 0;
    box-shadow: 0 12px 30px rgba(0,0,0,.35);
  }
  .site-header nav a { padding: 12px 14px; font-size: 13px; }
  body.nav-locked { overflow: hidden; }
  .creator-rank, .buyer, .live-row { grid-template-columns: auto 34px minmax(0, 1fr); align-items: center; }
  .creator-rank > div, .buyer > span:nth-child(2) { min-width: 0; overflow-wrap: anywhere; }
}

.news-item { grid-template-columns: 150px minmax(0, 1fr) auto; }
.news-item-thumb { height: 100%; min-height: 96px; border-right: 2px solid var(--line); }
.news-item-body h3 { color: var(--ink); }
.news-item-meta { display: inline-flex; align-items: center; gap: 6px; padding: 3px 9px; border-radius: 3px; background: var(--purple-soft); color: var(--purple-ink); font: 800 10px/1.6 var(--font-display); text-transform: uppercase; letter-spacing: .4px; }
.news-card .thumb { width: 100%; height: 160px; border: 0; border-radius: 0; border-bottom: 2px solid var(--line); background: var(--surface-3); display: block; }
.news-card .thumb img { width: 100%; height: 100%; object-fit: cover; }
.news-card > div:last-child { padding: var(--s-3); }
.news-card h3 { margin-bottom: 6px; }
.news-card:hover { transform: translateY(-3px); }

.legal-page { max-width: 900px; }
.legal-page h2 { margin-top: var(--s-5); padding: 9px 14px; background: linear-gradient(180deg, #7b2fe0, #5f1fb5); color: #fff; border-radius: var(--r-sm); font-size: 16px; }
.legal-page h3 { margin-top: var(--s-4); color: var(--purple-ink); font-size: 15px; }
.legal-page p, .legal-page li { color: var(--ink-2); }
.legal-page ul, .legal-page ol { padding-left: 22px; }
.legal-page li { margin-bottom: 5px; }
.legal-page strong { color: var(--ink); }
.legal-page hr { border: 0; border-top: 2px solid var(--line); margin: var(--s-4) 0; }
.legal-item { display: flex; align-items: center; justify-content: space-between; gap: var(--s-3); flex-wrap: wrap; }
.legal-item:hover { border-color: var(--purple-2); }

.planet {
  position: absolute; display: block; pointer-events: none;
  image-rendering: pixelated;
  filter: drop-shadow(0 14px 30px rgba(45,30,80,.30));
}


 @media (prefers-reduced-motion: reduce) {  }
@media (max-width: 860px) {
      .planet-3, .planet-4 { display: none; }
}

.widget > h3 { display: flex; align-items: center; gap: 8px; }
.widget > h3 .status-pill { margin-left: auto; background: rgba(255,255,255,.18); color: #fff; border-color: rgba(255,255,255,.32); }
.widget > h3 .status-pill.is-offline, .widget > h3 .status-pill.offline { background: rgba(0,0,0,.28); color: #ffd3da; border-color: rgba(255,255,255,.25); }
.server-widget .server-players { margin-top: 0; }

.shop-card { display: flex; flex-direction: column; }
.shop-card > div:first-child { display: flex; flex-direction: column; flex: 1 1 auto; padding: 0; }
.shop-card .product-type {
  order: -1; margin: 0; padding: 9px 12px;
  background: linear-gradient(180deg, #7b2fe0, #5f1fb5); color: #fff;
  border-bottom: 2px solid var(--purple-3);
  font: 800 11px/1.4 var(--font-display); letter-spacing: .6px;
}
.shop-card .product-art { margin: var(--s-3) var(--s-3) var(--s-2); height: 78px; }
.shop-card h3 { padding: 0 var(--s-3); font-size: 15px; }
.shop-card .card-desc { padding: 0 var(--s-3); min-height: 38px; }
.shop-card .duration-chip, .shop-card .promo-chip { margin: 0 var(--s-3); }
.shop-card .price-box { padding: 0 var(--s-3); margin: var(--s-2) 0; }
.shop-card > *:not(:first-child) { padding: 0 var(--s-3) var(--s-3); }
.shop-card .cart-btn, .shop-card button { width: 100%; }
.shop-card:hover .product-type { background: linear-gradient(180deg, #e8b44a, #c08a1f); border-bottom-color: #a9761f; color: #33230a; }

body { position: relative; }
.hero { height: 100%; }
.hero-side { height: 100%; }

.planet { animation-name: wobble; animation-timing-function: ease-in-out; animation-iteration-count: infinite; animation-direction: alternate; }
@keyframes wobble {
  0%   { transform: translate(0, 0) rotate(0deg); }
  25%  { transform: translate(7px, -9px) rotate(2.5deg); }
  50%  { transform: translate(0, -14px) rotate(0deg); }
  75%  { transform: translate(-7px, -7px) rotate(-2.5deg); }
  100% { transform: translate(0, 0) rotate(0deg); }
}
@media (prefers-reduced-motion: reduce) { .planet { animation: none; } }

.planet-1 { width: 240px; height: 240px; top: 340px;  right: 3%;  opacity: .92; animation-duration: 17s; }
.planet-2 { width: 120px; height: 120px; top: 1150px; left: 2%;   opacity: .85; animation-duration: 21s; }
.planet-3 { width: 176px; height: 176px; top: 1950px; right: 4%;  opacity: .82; animation-duration: 25s; }
.planet-4 { width: 88px;  height: 88px;  top: 2750px; left: 6%;   opacity: .78; animation-duration: 19s; }
.planet-5 { width: 208px; height: 208px; top: 3550px; right: 2%;  opacity: .8;  animation-duration: 23s; }
.planet-6 { width: 104px; height: 104px; top: 4400px; left: 3%;   opacity: .75; animation-duration: 27s; }

@media (max-width: 1100px) {
  .planet-1 { width: 150px; height: 150px; top: 300px; right: -30px; }
  .planet-2 { width: 90px;  height: 90px;  top: 1100px; left: -24px; }
  .planet-3 { width: 116px; height: 116px; top: 1900px; right: -30px; }
  .planet-4, .planet-5, .planet-6 { display: none; }
}

.rank-card { transition: opacity .18s ease; }
.rank-list { animation: rankIn .32s ease both; }
.rank-row { animation: rankRow .34s ease both; }
.rank-row:nth-child(1) { animation-delay: .02s; }
.rank-row:nth-child(2) { animation-delay: .05s; }
.rank-row:nth-child(3) { animation-delay: .08s; }
.rank-row:nth-child(4) { animation-delay: .11s; }
.rank-row:nth-child(5) { animation-delay: .14s; }
.rank-row:nth-child(6) { animation-delay: .17s; }
.rank-row:nth-child(7) { animation-delay: .20s; }
.rank-row:nth-child(8) { animation-delay: .23s; }
.rank-row:nth-child(9) { animation-delay: .26s; }
.rank-row:nth-child(10) { animation-delay: .29s; }
@keyframes rankIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes rankRow { from { opacity: 0; transform: translateX(-14px); } to { opacity: 1; transform: none; } }
.cat-btn { transition: background .16s ease, color .16s ease, box-shadow .16s ease; }
@media (prefers-reduced-motion: reduce) {
  .rank-list, .rank-row { animation: none; }
}

[hidden] { display: none !important; }

.thumb { width: auto; height: auto; border-radius: 0; border: 0; background: transparent; }
.creator-rank .head, .buyer .head, .live-row .head, .rank-row .head, .chat-msg img {
  width: 34px; height: 34px; border-radius: 3px; image-rendering: pixelated;
  border: 1px solid var(--line); background: var(--surface-3);
}
.rank-row .head { width: 34px; height: 34px; }

.news-item { align-items: stretch; }
.news-item-thumb {
  width: 100%; height: 100%; min-height: 110px;
  border-right: 2px solid var(--line); background: var(--surface-3);
  overflow: hidden; display: block;
}
.news-item-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.news-card .thumb { width: 100%; height: 170px; overflow: hidden; background: var(--surface-3); border-bottom: 2px solid var(--line); display: block; }
.news-card .thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.article-modal-thumb { width: 100%; overflow: hidden; border-radius: var(--r-sm); margin-bottom: var(--s-3); background: var(--surface-3); }
.article-modal-thumb img { width: 100%; height: auto; max-height: 340px; object-fit: cover; display: block; }

.shop-card .card-desc { min-height: 52px; }
.shop-card .price-box { margin-top: auto; }
@media (max-width: 860px) {
  .news-item-thumb { min-height: 160px; border-right: 0; border-bottom: 2px solid var(--line); }
}

.news-item.no-thumb { grid-template-columns: minmax(0, 1fr) auto; }
.news-item.no-thumb .news-item-body { padding: var(--s-3); }
@media (max-width: 860px) { .news-item.no-thumb { grid-template-columns: minmax(0, 1fr); } }

.modal-backdrop { z-index: 3000; }
.purchase-modal, .article-modal, .login-modal { max-height: min(90vh, 900px); }
.article-modal { display: flex; flex-direction: column; }
.article-modal-body { overflow-wrap: anywhere; }

.chat-msg { grid-template-columns: 26px minmax(0, 1fr); align-items: start; }
.chat-msg img {
  width: 26px; height: 26px; min-width: 26px; aspect-ratio: 1 / 1;
  object-fit: contain; border-radius: 3px; image-rendering: pixelated;
  border: 1px solid var(--line); background: var(--surface-3);
}
.creator-rank .head, .buyer .head, .live-row .head, .rank-row .head {
  aspect-ratio: 1 / 1; object-fit: contain; min-width: 34px;
}

/* ---- Spójne wyrównanie na wąskich ekranach ---- */

.rank-row {
  grid-template-columns: 46px 34px minmax(0, 1fr) auto;
  column-gap: var(--s-2); row-gap: 0;
}
.rank-pos { text-align: left; font-variant-numeric: tabular-nums; }
.rank-nick { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rank-value { white-space: nowrap; font-variant-numeric: tabular-nums; }

.shop-tabs { align-items: stretch; }
.shop-tabs .cat-btn { flex: 0 0 auto; white-space: nowrap; min-height: 38px; }

.vote-row {
  display: grid; grid-template-columns: 24px minmax(0, 1fr) auto;
  align-items: center; gap: var(--s-2);
  padding: 9px 0; border-bottom: 1px solid var(--line);
}
.vote-row:last-child { border-bottom: 0; }
.vote-row .rank { min-width: 24px; width: 24px; height: 24px; }
.vote-row-name {
  min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  color: var(--ink); font: 700 14px/1.3 var(--font-display);
}
.vote-row-btn { min-height: 36px; padding: 8px 16px; font-size: 11px; white-space: nowrap; }

.modal-art { overflow: hidden; }
.modal-art img {
  max-width: 100%; max-height: 100%; width: auto; height: auto;
  object-fit: contain; display: block;
}
.modal-product { align-items: center; }

.chat-list .chat-msg:nth-child(odd) { background: transparent; }
.chat-msg { border-bottom: 1px solid var(--line); border-radius: 0; }
/* Kolor zamiast szerokosci - wszystkie wiersze maja identyczna wysokosc. */
.chat-list .chat-msg:last-child { border-bottom-color: transparent; }
.chat-body { min-width: 0; }
/* Wejscie bez fill-mode: po animacji styl wraca pod kontrole klas is-fading/is-leaving. */
.chat-msg { animation: chatIn .34s ease; transition: opacity .34s ease, transform .34s ease; }
@keyframes chatIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.chat-msg.is-fading { opacity: .42; }
.chat-msg.is-leaving { opacity: 0; transform: translateY(-4px); }
@media (prefers-reduced-motion: reduce) {
  .chat-msg { animation: none; transition: none; }
  .chat-msg.is-leaving { opacity: 1; transform: none; }
}

.planet { max-width: 42vw; }

@media (max-width: 860px) {
  .shop-tabs {
    flex-wrap: nowrap; overflow-x: auto; overflow-y: hidden;
    scroll-snap-type: x proximity; -webkit-overflow-scrolling: touch;
    padding-bottom: 7px; scrollbar-width: thin;
    scrollbar-color: var(--line-2) transparent;
  }
  .shop-tabs::-webkit-scrollbar { height: 4px; }
  .shop-tabs::-webkit-scrollbar-track { background: transparent; }
  .shop-tabs::-webkit-scrollbar-thumb { background: var(--line-2); border-radius: 3px; }
  .shop-tabs .cat-btn { scroll-snap-align: start; }
  .modal-product { grid-template-columns: 84px minmax(0, 1fr); gap: var(--s-3); }
  .modal-art { height: 84px; }
}

@media (max-width: 560px) {
  .rank-row {
    grid-template-columns: 38px 28px minmax(0, 1fr) auto;
    column-gap: 8px; padding: 8px 10px;
  }
  .rank-row .head { width: 28px; height: 28px; min-width: 28px; }
  .rank-pos { font-size: 13px; }
  .rank-nick { font-size: 14px; }
  .rank-value { font-size: 13px; }
  .purchase-modal, .article-modal, .login-modal { padding: var(--s-4); }
  .modal-backdrop { padding: 12px; }
  .section { padding: var(--s-4) 0; }
}

@media (max-width: 360px) {
  .vote-row { grid-template-columns: 24px minmax(0, 1fr); row-gap: 8px; }
  .vote-row-btn { grid-column: 1 / -1; width: 100%; }
}

/* ---- Grafiki produktów wychodzące poza kafelek ikony ---- */

.shop-card .product-art {
  position: relative;
  overflow: visible;
  margin: var(--s-5) var(--s-3) var(--s-2);
  height: 78px;
}
/* Pozycjonowanie absolutne + wysokosc w px: proporcje zawsze zachowane,
   a wielkosc nie zalezy od tego, jak przegladarka rozwiaze procent w gridzie. */
.shop-card .product-art img {
  position: absolute;
  left: 50%; top: 50%;
  width: auto; height: 96px;
  max-width: 86%; max-height: none;
  object-fit: contain; display: block;
  transform: translate(-50%, -56%);
  filter: drop-shadow(0 10px 14px rgba(45, 30, 80, .28));
  transition: filter .2s ease;
}

/* Ruch tylko na transformacie - pozycja spoczynkowa jest identyczna z klatka 0%,
   wiec grafika wyglada poprawnie takze gdy animacje sa wylaczone. */
@keyframes artFloat {
  0%, 100% { transform: translate(-50%, -56%); }
  50%      { transform: translate(-50%, -64%); }
}
.shop-card .product-art img { animation: artFloat 4.6s ease-in-out infinite; }
.shop-grid > .shop-card:nth-child(4n+2) .product-art img { animation-delay: -1.1s; animation-duration: 5.2s; }
.shop-grid > .shop-card:nth-child(4n+3) .product-art img { animation-delay: -2.3s; animation-duration: 4.2s; }
.shop-grid > .shop-card:nth-child(4n+4) .product-art img { animation-delay: -3.4s; animation-duration: 5.6s; }

.shop-card:hover .product-art img {
  filter: drop-shadow(0 14px 20px rgba(224, 166, 58, .45));
}

.shop-card .product-art > svg {
  width: auto; height: 108%;
  filter: drop-shadow(0 8px 12px rgba(45, 30, 80, .22));
}

@media (prefers-reduced-motion: reduce) {
  .shop-card .product-art img { animation: none; }
}

/* ================= MOTYW CIEMNY ================= */

:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #120d20; --bg-2: #0d0918;
  --surface: #1c1630; --surface-2: #241c3c; --surface-3: #2e2449;
  --ink: #ece7f7; --ink-2: #c9c0e0; --muted: #9a90b6; --soft: #7d7397;
  --line: #342a52; --line-2: #453765;
  --purple: #8b48e8; --purple-2: #a877f2; --purple-3: #6c28c4; --purple-soft: #2a1f47;
  --purple-ink: #c19bf7;
  --gold: #e0a63a; --gold-soft: #3a2c12;
  --green: #56c274; --green-soft: #16301f;
  --red: #e4667c; --red-soft: #35161d;
  --blue: #6ea3e8; --cyan: #5ab6cf; --orange: #e8a05a;
  --dark: #0d0918; --dark-2: #171029; --dark-3: #241a3f;
  --panel: var(--surface); --panel-2: var(--surface-2); --beige: #3a3050;
  --shadow: 0 12px 34px rgba(0, 0, 0, .5);
  --shadow-sm: 0 3px 12px rgba(0, 0, 0, .38);
  --ring: 0 0 0 3px rgba(168, 119, 242, .38);
}

/* Kolory, ktore w jasnym motywie byly wpisane na sztywno, a leza na tokenizowanym tle. */
:root[data-theme="dark"] .badge.requested,
:root[data-theme="dark"] .badge.pending,
:root[data-theme="dark"] .badge.reviewed,
:root[data-theme="dark"] .badge.new,
:root[data-theme="dark"] .badge.processing,
:root[data-theme="dark"] .promo-chip,
:root[data-theme="dark"] .gold-badge,
:root[data-theme="dark"] .creator-flag { color: #f0c469; border-color: rgba(224, 166, 58, .45); }
:root[data-theme="dark"] .promo-banner { color: #f0c469; border-color: rgba(224, 166, 58, .4); }
:root[data-theme="dark"] .alert-payout { color: #f0c469; border-color: rgba(224, 166, 58, .4); }
:root[data-theme="dark"] .notice { color: #86dba0; border-color: rgba(86, 194, 116, .35); }
:root[data-theme="dark"] .danger, :root[data-theme="dark"] .shop-disabled-banner { color: #f2909f; border-color: rgba(228, 102, 124, .35); }
:root[data-theme="dark"] .rank-row.rank-1 .rank-pos,
:root[data-theme="dark"] .rank-row.rank-1 .rank-value { color: #f0c469; }
:root[data-theme="dark"] .product-art, :root[data-theme="dark"] .modal-art { border-color: var(--line-2); }
:root[data-theme="dark"] .creator-code-chip { border-color: var(--line-2); color: var(--purple-2); }
:root[data-theme="dark"] .btn.gold, :root[data-theme="dark"] button.gold { color: #2a1c04; }
:root[data-theme="dark"] input, :root[data-theme="dark"] select, :root[data-theme="dark"] textarea,
:root[data-theme="dark"] .nice-select-toggle { background: var(--surface-2); color: var(--ink); }
:root[data-theme="dark"] .totp-qr { background: #fff; }
:root[data-theme="dark"] code { color: var(--purple-2); }

/* Naglowek i stopka sa ciemne takze w jasnym motywie - w ciemnym trzeba je odroznic od tla. */
:root[data-theme="dark"] .site-header {
  background: linear-gradient(180deg, #241a3f, #171029);
  border-bottom-color: var(--purple-3);
}
:root[data-theme="dark"] .footer {
  background: linear-gradient(180deg, #171029, #0d0918);
  border-top-color: var(--purple-3);
}
:root[data-theme="dark"] .ambient {
  background:
    radial-gradient(760px 540px at 10% 6%, rgba(139, 72, 232, .20), transparent 62%),
    radial-gradient(640px 480px at 90% 22%, rgba(90, 182, 207, .13), transparent 60%),
    radial-gradient(820px 560px at 66% 94%, rgba(224, 166, 58, .10), transparent 62%);
}
:root[data-theme="dark"] .planet { filter: drop-shadow(0 14px 30px rgba(0, 0, 0, .55)); }
:root[data-theme="dark"] #particles { opacity: .75; }
:root[data-theme="dark"] .shop-card .product-art img { filter: drop-shadow(0 10px 16px rgba(0, 0, 0, .55)); }
:root[data-theme="dark"] .shop-card:hover .product-art img { filter: drop-shadow(0 14px 22px rgba(224, 166, 58, .5)); }

/* ---- Przelacznik motywu ---- */

.theme-toggle {
  position: relative;
  width: 42px; min-width: 42px; height: 42px; min-height: 42px;
  padding: 0; flex: 0 0 auto;
  display: inline-flex; align-items: center; justify-content: center;
  background: rgba(255, 255, 255, .1);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, .18);
  border-radius: var(--r-sm);
  box-shadow: none;
}
.theme-toggle:hover { background: rgba(255, 255, 255, .18); filter: none; color: #fff; }
.theme-toggle:active { transform: none; box-shadow: none; }
.theme-icon {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  transition: opacity .22s ease, transform .22s ease;
}
.theme-icon-moon { opacity: 0; transform: rotate(-45deg) scale(.7); }
:root[data-theme="dark"] .theme-icon-sun { opacity: 0; transform: rotate(45deg) scale(.7); }
:root[data-theme="dark"] .theme-icon-moon { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .theme-icon { transition: none; } }

/* ---- Klikalne karty aktualności ---- */

[data-article-card] { cursor: pointer; }
[data-article-card]:focus-visible { outline: none; box-shadow: var(--ring); border-color: var(--purple-2); }
[data-article-card] h3 { transition: color .16s ease; }
[data-article-card]:hover h3 { color: var(--purple-ink); }

/* Ostatnim dzieckiem karty jest teraz CTA, wiec padding tresci ustawiamy wprost. */
.news-card > div:not(.thumb) { padding: var(--s-3); }
.news-card > div:not(.thumb) + .news-card-cta { padding-top: 0; }
.news-card-cta { margin: auto 0 0; padding: 0 var(--s-3) var(--s-3); }
.news-card-cta .link-more { pointer-events: none; }
.news-card:hover .link-more { color: var(--gold); }

/* ---- Aktualności na wąskich ekranach ----
   Reguła musi stać PO .news-item z linii bez media query, inaczej tamta wygrywa
   i na telefonie zostaje układ 150px | 1fr | auto. */
@media (max-width: 860px) {
  .news-item, .news-item.no-thumb { grid-template-columns: minmax(0, 1fr); }
  .news-item-thumb {
    height: auto; min-height: 0; aspect-ratio: 16 / 9;
    border-right: 0; border-bottom: 2px solid var(--line);
  }
  .news-item-thumb img { height: 100%; }
  .news-item-body { padding: var(--s-3); }
  .news-item-actions .btn { width: 100%; }
}

/* .news-item-actions siedzi WEWNATRZ .news-item-body, ktory ma juz swoj padding.
   Wlasny padding poziomy przesuwalby przycisk o 14px wzgledem tekstu. */
.news-item-actions { padding-left: 0; padding-right: 0; margin-bottom: 0; }

/* ---- Cena, promocja i wartość zestawu ---- */

/* Stała struktura: górna linia (stara cena + rabat) zawsze nad ceną,
   nigdy obok. Dzięki temu znacznik -20% jest w tym samym miejscu na każdej karcie. */
.price-box {
  display: flex; flex-direction: column; align-items: flex-start; gap: 4px;
  margin: var(--s-2) 0;
}
.price-top { display: flex; align-items: center; gap: 8px; min-height: 0; }
.price-box.has-promo .price-top { min-height: 26px; }
.price-box .price-was, .price-box .price-old {
  color: var(--soft); font: 700 13px/1 var(--font-numeric);
  text-decoration: line-through; text-decoration-thickness: 2px;
}
.price-box .price-now {
  color: var(--ink); font: 800 24px/1 var(--font-numeric); letter-spacing: .5px;
}
.price-box.has-promo .price-now { color: var(--purple-ink); }

/* Rabat: wyraźnie większy i kontrastowy - wcześniej gubił się przy cenie. */
.promo-chip {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 5px 11px; border-radius: 4px;
  background: linear-gradient(180deg, #f0b64a, #c8871f);
  color: #34240a; border: 1px solid #a9761f;
  font: 900 13px/1 var(--font-numeric); letter-spacing: .4px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.45), 0 2px 0 rgba(0,0,0,.16);
  text-shadow: none;
}

/* Znacznik wartości zestawu - "ile to normalnie kosztuje". */
.value-badge {
  display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap;
  padding: 4px 10px; border-radius: 4px;
  background: var(--surface-3); border: 1px solid var(--line-2);
  color: var(--muted); font: 800 10px/1.5 var(--font-display);
  text-transform: uppercase; letter-spacing: .5px;
}
.value-badge strong {
  color: var(--soft); font: 800 12px/1.5 var(--font-numeric);
  text-decoration: line-through; text-decoration-thickness: 2px; letter-spacing: 0;
}
.modal-product .value-badge { margin-bottom: 8px; }

/* Karta sklepu: cały blok ceny na dole, jednakowo w każdej karcie. */
.shop-card .price-box { padding: 0 var(--s-3); margin-top: auto; }
.shop-card .value-badge { margin-bottom: 2px; }

@media (max-width: 560px) {
  .price-box .price-now { font-size: 22px; }
  .promo-chip { padding: 4px 9px; font-size: 12px; }
}

:root[data-theme="dark"] .value-badge { background: var(--surface-2); border-color: var(--line-2); color: var(--muted); }
:root[data-theme="dark"] .value-badge strong { color: var(--soft); }
:root[data-theme="dark"] .promo-chip { color: #2a1c04; border-color: #8a6413; }
:root[data-theme="dark"] .price-box.has-promo .price-now { color: var(--purple-ink); }

/* Slot na znacznik wartości rezerwuje miejsce także tam, gdzie znacznika nie ma -
   inaczej karta z pakietem byłaby wyższa i rząd kart by się rozjechał. */
.value-slot { display: flex; align-items: center; min-height: 27px; }

/* Rabat przypięty do prawej krawędzi ceny - ta sama pozycja na każdej karcie,
   niezależnie od długości przekreślonej ceny. */
.price-top { width: 100%; justify-content: space-between; }

/* Znacznik w jednej linii - łamanie robiło kartę wyższą od pozostałych. */
.value-badge {
  white-space: nowrap; max-width: 100%;
  padding: 3px 9px; font-size: 9px; letter-spacing: .4px; gap: 5px;
}
.value-badge strong { font-size: 11px; }

/* Bez flexa - flex-wrap łamał etykietę i kwotę na dwie linie mimo nowrap. */
.value-badge {
  display: inline-block; white-space: nowrap; flex-wrap: nowrap;
  line-height: 1.6; vertical-align: middle;
}
.value-badge strong { display: inline; margin-left: 4px; vertical-align: baseline; }

/* Czytelniejszy znacznik wartości - poprzednie odcienie miały za niski kontrast. */
.value-badge { color: var(--ink-2); }
.value-badge strong { color: var(--muted); }
:root[data-theme="dark"] .value-badge { color: var(--ink-2); }
:root[data-theme="dark"] .value-badge strong { color: var(--muted); }

/* ---- Top kupujących: nick pod głową, długie nicki przycinane ----
   Reguła z kolumną 34px pasuje wyłącznie do .creator-rank, gdzie głowa jest
   osobnym dzieckiem. W .buyer głowa siedzi w środkowym spanie, a w .live-row
   pierwszym dzieckiem - przez to nick dostawał 34px i łamał się po literze. */
.buyer-who { display: inline-flex; align-items: center; gap: 8px; min-width: 0; }
.buyer .head { flex: 0 0 auto; }
.buyer-nick {
  min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  font-weight: 700;
}
.buyer-sum { white-space: nowrap; font-variant-numeric: tabular-nums; }

@media (max-width: 860px) {
  .buyer { grid-template-columns: auto minmax(0, 1fr) auto; }
  .buyer > :last-child { grid-column: auto; }
  .live-row { grid-template-columns: auto minmax(0, 1fr); }
  .live-row > :last-child { grid-column: 1 / -1; }
  .live-info { min-width: 0; }
  .live-info strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
}

/* Stała szerokość numeru pozycji - inaczej "#1" jest węższe niż "#4"
   i nick każdego wiersza zaczyna się w innym miejscu. */
.buyer .rank { width: 30px; min-width: 30px; justify-content: center; font-variant-numeric: tabular-nums; }

/* ================= PANEL CENY W KARCIE SKLEPU ================= */

.buy-panel {
  position: relative;
  margin: var(--s-3) var(--s-3) var(--s-3);
  border: 2px solid var(--line-2);
  border-radius: var(--r-md);
  background: var(--surface-2);
  display: flex; flex-direction: column;
}
.buy-panel.has-promo { border-color: var(--gold); }

/* Plakietka rabatu wpięta w górną ramkę - ta sama barwa ramki daje efekt połączenia. */
.promo-tab {
  position: absolute; top: 0; left: 50%; z-index: 2;
  transform: translate(-50%, -50%);
  padding: 4px 12px; border-radius: 4px;
  background: linear-gradient(180deg, #f0b64a, #c8871f);
  border: 2px solid var(--gold);
  color: #34240a; font: 900 13px/1 var(--font-numeric); letter-spacing: .4px;
  white-space: nowrap;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.45), 0 2px 6px rgba(45,30,80,.25);
}

/* Pasek wartości zestawu - przez całą szerokość panelu. */
.value-strip {
  display: block; width: 100%;
  padding: 7px 10px;
  border-bottom: 2px solid var(--line-2);
  border-radius: 6px 6px 0 0;
  background: var(--surface-3);
  color: var(--ink-2);
  font: 800 9px/1.5 var(--font-display);
  text-transform: uppercase; letter-spacing: .5px; text-align: center;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.value-strip strong {
  color: var(--muted); font: 800 11px/1.5 var(--font-numeric);
  text-decoration: line-through; text-decoration-thickness: 2px;
  letter-spacing: 0; margin-left: 4px;
}
.buy-panel.has-promo .value-strip { border-bottom-color: var(--gold); }

.buy-panel-body {
  display: flex; flex-direction: column; align-items: center;
  gap: 2px; padding: 12px 12px 12px;
}
/* Gdy plakietka rabatu wisi na ramce, robimy jej miejsce. */
.buy-panel.has-promo:not(.has-value) .buy-panel-body { padding-top: 20px; }
.buy-panel.has-promo.has-value .value-strip { padding-top: 15px; }

.price-old-small {
  font: 700 12px/1.2 var(--font-numeric); color: var(--soft);
  text-decoration: line-through; text-decoration-thickness: 2px;
}
.price-final {
  font: 800 26px/1.15 var(--font-numeric); color: var(--ink);
  letter-spacing: .5px; white-space: nowrap;
}
.buy-panel.has-promo .price-final { color: var(--purple-ink); }
.buy-panel .cart-btn { width: 100%; margin-top: 10px; }

/* Panel siedzi na dole karty, przyklejony do jej spodu. */
.shop-card .buy-panel { margin-top: auto; }
.shop-card > *:not(:first-child) { padding: 0; }

/* Pusty pasek trzyma wysokość, ale nic nie pokazuje - dzięki temu karta z pakietem
   i karta bez pakietu mają identyczną wysokość. */
.value-strip.is-empty { visibility: hidden; }
/* Placeholder z metrykami kwoty - inaczej pusty pasek jest o 3px nizszy niz wypelniony. */
.value-strip.is-empty::before { content: "\00a0"; font: 800 11px/1.5 var(--font-numeric); }

/* Plakietka dokładnie na linii ramki - top:0 liczy się od krawędzi wewnętrznej,
   więc cofamy ją o grubość obramowania. */
.promo-tab { top: -2px; }

/* Rabat wisi nad paskiem, więc pasek zawsze robi mu miejsce - także gdy jest pusty. */
.buy-panel.has-promo .value-strip { padding-top: 15px; }
.buy-panel.has-promo:not(.has-value) .buy-panel-body { padding-top: 12px; }

/* Przycisk szerszy - bliżej krawędzi panelu. */
.buy-panel-body { padding-left: 8px; padding-right: 8px; }

/* Przekreślona cena ma być czytelna, mimo że drugoplanowa. */
.price-old-small { color: var(--muted); }

/* TostSMP: ciepła, tostowa paleta oraz maskotka w hero. */
:root {
  --bg: #fff1ce; --bg-2: #f6d998;
  --surface: #fffaf0; --surface-2: #fff0d4; --surface-3: #f5ddb0;
  --ink: #48250c; --ink-2: #6f3d12; --muted: #8b5f32; --soft: #a57b4d;
  --line: #e7bd77; --line-2: #d79945;
  --purple: #dc7a10; --purple-2: #f0a027; --purple-3: #a94d09; --purple-soft: #fff0d4;
  --purple-ink: #9b4708; --gold: #f2af22; --gold-soft: #fff1c2;
  --dark: #47220b; --dark-2: #63310f; --dark-3: #7b4015;
  --panel: var(--surface); --panel-2: var(--surface-2); --line-hot: var(--purple-2);
  --shadow: 0 10px 30px rgba(99,49,15,.16); --shadow-sm: 0 3px 10px rgba(99,49,15,.10);
  --ring: 0 0 0 3px rgba(220,122,16,.24);
}
.site-header { border-bottom-color: #f2af22; }
.hero { background: linear-gradient(155deg, #7d3a10, #51240a 60%, #371705); border-color: #d78016; }
.hero::before { background: radial-gradient(circle, rgba(255,217,116,.32) 0 3px, transparent 4px); background-size: 42px 42px; }
.hero-toast { position: absolute; width: 240px; right: -38px; bottom: -48px; opacity: .26; transform: rotate(-11deg); pointer-events: none; }
.hero-logo { filter: drop-shadow(0 8px 0 rgba(72,37,12,.32)); }
.tagline { color: #ffe5a4; }
@media (max-width: 720px) { .hero-toast { width: 170px; right: -46px; bottom: -35px; } }

/* --------------------------------------------------------------------------
   TostSMP publiczny layout — celowo zastępuje odziedziczoną stylistykę V4.
   -------------------------------------------------------------------------- */
html[data-theme="tost"] {
  --bg: #fff5df; --bg-2: #f7dfa9; --surface: #fffdf7; --surface-2: #fff3dc;
  --surface-3: #f7e2bd; --ink: #45210a; --ink-2: #704019; --muted: #93683b;
  --soft: #b08355; --line: #edcea0; --line-2: #dfaf6b; --purple: #db760e;
  --purple-2: #ef9d23; --purple-3: #a94d09; --purple-ink: #a24b09;
  --gold: #f1aa20; --gold-soft: #fff0c7; --dark: #48220c; --dark-2: #62300e;
  --dark-3: #7a4015; --shadow: 0 16px 34px rgba(89,42,10,.14);
  --shadow-sm: 0 5px 16px rgba(89,42,10,.10); --ring: 0 0 0 3px rgba(230,126,18,.22);
}
html[data-theme="tost"] body { background: linear-gradient(180deg, #fff8e9 0, #fff0d2 100%); color: var(--ink); }
html[data-theme="tost"] .site-header { min-height: 78px; background: #48220c; border-bottom: 3px solid #f1aa20; box-shadow: 0 3px 0 rgba(115,53,10,.18); }
html[data-theme="tost"] .header-inner { min-height: 76px; }
html[data-theme="tost"] .brand img { width: 108px; max-height: 54px; object-fit: contain; }
html[data-theme="tost"] .site-header nav a { color: #ffe8b5; font-size: 11px; padding: 9px 10px; }
html[data-theme="tost"] .site-header nav a:hover, html[data-theme="tost"] .site-header nav a.active { background: #e47c12; color: #fff; }
html[data-theme="tost"] .header-actions .btn { background: #ef9f25; color: #422009; box-shadow: inset 0 2px 0 rgba(255,255,255,.4), 0 3px 0 #a54d0a; }
html[data-theme="tost"] .hero-shell { grid-template-columns: minmax(0, 1fr) 320px; gap: 22px; padding-top: 30px; }
html[data-theme="tost"] .hero {
  min-height: 500px; padding: 58px 62px; align-items: flex-start; justify-content: center;
  text-align: left; border: 1px solid #c76613; border-radius: 18px;
  background: radial-gradient(circle at 75% 12%, rgba(255,212,103,.28), transparent 28%), linear-gradient(135deg, #9c470d, #6a2d09 57%, #482008);
}
html[data-theme="tost"] .hero::before { content: ''; position: absolute; inset: 0; opacity: .17; background-image: radial-gradient(#ffe392 1px, transparent 1.5px); background-size: 30px 30px; }
html[data-theme="tost"] .hero-content { max-width: 570px; align-items: flex-start; gap: 17px; }
html[data-theme="tost"] .hero-logo { width: min(290px, 68%); filter: drop-shadow(0 7px 0 rgba(54,20,2,.35)); }
html[data-theme="tost"] .hero-toast { width: 300px; right: 22px; bottom: -26px; opacity: .95; transform: rotate(-8deg); filter: drop-shadow(0 18px 17px rgba(42,16,3,.42)); }
html[data-theme="tost"] .tagline { color: #ffe2a0; font-size: 13px; letter-spacing: 2.4px; text-align: left; }
html[data-theme="tost"] .hero-stats { width: min(500px, 100%); gap: 9px; }
html[data-theme="tost"] .mini-stat { min-height: 78px; background: rgba(68,29,7,.36); border-color: rgba(255,219,143,.26); }
html[data-theme="tost"] .mini-stat strong { color: #fff2cb; }
html[data-theme="tost"] .mini-stat span { color: #ffdca0; font-size: 10px; }
html[data-theme="tost"] .hero-actions { justify-content: flex-start; }
html[data-theme="tost"] .hero-actions button, html[data-theme="tost"] .hero-actions .btn { background: #f1a526; color: #452009; box-shadow: 0 3px 0 #ad540c; }
html[data-theme="tost"] .ip-box { align-self: flex-start; background: rgba(61,25,5,.56); border: 1px solid rgba(255,219,148,.3); color: #fff0c8; }
html[data-theme="tost"] .ip-box span { color: #ffd57f; }
html[data-theme="tost"] .ip-box button { background: #f1a526; color: #452009; }
html[data-theme="tost"] .hero-side .widget, html[data-theme="tost"] .hero-side .server-widget { background: #fffdf7; border-color: #e9c997; box-shadow: var(--shadow-sm); }
html[data-theme="tost"] .hero-side h3, html[data-theme="tost"] .hero-side .section-head { color: #55270d; border-color: #eed9b6; }
html[data-theme="tost"] .status-pill, html[data-theme="tost"] .live-badge { background: #3f9e57; color: #fff; }
html[data-theme="tost"] .server-count { color: #c3600b; }
html[data-theme="tost"] .capacity-bar { background: #f5e4c5; }
html[data-theme="tost"] .capacity-bar span { background: #e98a19; }
html[data-theme="tost"] .section { padding-top: 62px; }
html[data-theme="tost"] .section-head { border-color: #ebd1aa; }
html[data-theme="tost"] .section-head h2, html[data-theme="tost"] .section-head h3 { color: #51270e; }
html[data-theme="tost"] .shop-tabs .cat-btn { background: #fff0d4; border-color: #ebc58e; color: #8b4a12; }
html[data-theme="tost"] .shop-tabs .cat-btn.active { background: #6e310a; border-color: #6e310a; color: #fff; }
html[data-theme="tost"] .shop-card, html[data-theme="tost"] .card, html[data-theme="tost"] .widget, html[data-theme="tost"] .news-card { background: #fffdf7; border-color: #ead0a9; }
html[data-theme="tost"] .shop-card:hover { border-color: #e78815; transform: translateY(-5px); }
html[data-theme="tost"] .product-type { color: #a25c18; }
html[data-theme="tost"] .product-art { background: #fff0d1; border-color: #f0d2a0; }
html[data-theme="tost"] .buy-panel { border-color: #ebc895; background: #fff8e9; }
html[data-theme="tost"] .cart-btn, html[data-theme="tost"] .btn { background: #e88214; color: #fff; box-shadow: inset 0 2px 0 rgba(255,255,255,.22), 0 3px 0 #a84f0c; }
html[data-theme="tost"] .footer { background: #48220c; color: #e9c488; }
html[data-theme="tost"] .footer h4, html[data-theme="tost"] .footer a { color: #fff0c8; }
html[data-theme="tost"] .footer-bottom { border-color: rgba(255,223,161,.18); }
html[data-theme="tost"] .ambient, html[data-theme="tost"] #particles { display: none !important; }
@media (max-width: 900px) {
  html[data-theme="tost"] .hero-shell { grid-template-columns: 1fr; }
  html[data-theme="tost"] .hero { min-height: 510px; padding: 48px 38px; }
}
@media (max-width: 640px) {
  html[data-theme="tost"] .hero { padding: 42px 25px; min-height: 545px; }
  html[data-theme="tost"] .hero-toast { width: 215px; right: -34px; bottom: -26px; opacity: .46; }
  html[data-theme="tost"] .hero-content { max-width: 100%; }
  html[data-theme="tost"] .hero-logo { width: 240px; }
  html[data-theme="tost"] .site-header nav a { font-size: 12px; }
}
