/* ==========================================================================
   Хроники Кракена 888 — Kraken Chronicles design system.

   Minimalist dark theme: one neutral surface scale, one accent, hairline
   borders, no gradients / glows / decorative shadows. Every class name of the
   previous ornate theme is kept, so all pages restyle without touching JS.
   ========================================================================== */

:root {
  /* surfaces */
  --bg:         #0c0d0e;
  --bg-2:       #101213;
  --surface:    #121415;
  --surface-2:  #171a1b;
  --surface-3:  #1d2122;

  /* lines */
  --line:       rgba(255,255,255,.08);
  --line-2:     rgba(255,255,255,.14);
  --line-3:     rgba(255,255,255,.22);

  /* text */
  --text:       #e9ebeb;
  --text-dim:   #b6bcbc;
  --muted:      #a0aaaa;
  --muted-2:    #959f9f;

  /* accent — the single colour the brand keeps */
  --accent:     #d8b45d;
  --accent-dim: #a98a3e;
  --accent-ink: #14100a;
  --accent-bg:  rgba(216,180,93,.10);

  /* status */
  --danger:     #e08a80;
  --success:    #79c79b;
  --warn:       #d9b25f;
  --info:       #7fb6c9;

  /* legacy aliases kept so older rules and inline styles still resolve */
  --ink: var(--bg); --ink-2: var(--bg-2); --ink-3: var(--surface);
  --gold: var(--accent); --gold-soft: var(--accent); --gold-bright: var(--text);
  --gold-dim: var(--muted); --teal: var(--info); --teal-soft: var(--info);
  --teal-dim: var(--muted); --panel: var(--surface); --panel-soft: var(--surface-2);
  --panel-flat: var(--surface-2); --line-strong: var(--line-2); --line-teal: var(--line);
  --shadow: none; --shadow-lg: none;

  --radius:     12px;
  --radius-sm:  9px;
  --radius-xs:  7px;
  --sans:       'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --serif:      var(--sans);
  --mono:       ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --header-h:   58px;
  --maxw:       1320px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font: 14px/1.55 var(--sans);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: var(--text); text-decoration: none; }
a:hover { color: var(--accent); }

h1, h2, h3, h4 {
  font-family: var(--sans); color: var(--text); margin: 0 0 .5em;
  line-height: 1.2; letter-spacing: -.01em; font-weight: 600;
}
h1 { font-size: clamp(26px, 3.2vw, 38px); letter-spacing: -.025em; font-weight: 600; }
h2 { font-size: 19px; }
h3 { font-size: 15px; }
h4 { font-size: 13px; }
p  { margin: 0 0 1em; }
small { font-size: 11.5px; }
code, kbd { font-family: var(--mono); font-size: .92em; }
hr { border: 0; border-top: 1px solid var(--line); margin: 20px 0; }

::selection { background: rgba(216,180,93,.24); }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: #262b2c; border-radius: 6px; border: 2px solid var(--bg); }
::-webkit-scrollbar-thumb:hover { background: #343a3b; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.kc-boot { display: flex; align-items: center; justify-content: center; min-height: 100vh; }
.kc-boot-mark { width: 56px; height: 56px; opacity: .5; animation: kc-pulse 1.4s ease-in-out infinite; }
@keyframes kc-pulse { 0%,100% { opacity: .15; } 50% { opacity: .45; } }
.kc-noscript { max-width: 760px; margin: 40px auto; padding: 0 20px; }

/* ------------------------------------------------------------------ layout */
.kc-shell { display: flex; flex-direction: column; min-height: 100vh; }
.kc-main  { flex: 1; width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 28px 24px 64px; }
.kc-main.is-flush { max-width: 100%; padding: 0; }

/* ------------------------------------------------------------------ header */
.kc-header {
  position: sticky; top: 0; z-index: 90;
  background: rgba(12,13,14,.86);
  border-bottom: 1px solid var(--line);
  backdrop-filter: saturate(140%) blur(12px);
}
.kc-header-inner {
  max-width: var(--maxw); margin: 0 auto; padding: 0 24px;
  height: var(--header-h); display: flex; align-items: center; gap: 14px;
}
.kc-brand { display: flex; align-items: center; gap: 9px; flex-shrink: 0; }
.kc-brand-mark {
  width: 26px; height: 26px; flex-shrink: 0; display: block;
  border-radius: 50%; object-fit: cover;
  /* Эмблема тёмная по краю, на тёмном фоне шапки сливается — держим ободок. */
  box-shadow: 0 0 0 1px var(--line-2);
}
.kc-brand-text { line-height: 1.15; }
.kc-brand-name { font-size: 14px; font-weight: 600; letter-spacing: -.01em; color: var(--text); white-space: nowrap; }
.kc-brand-sub  { font-size: 9px; letter-spacing: .16em; text-transform: uppercase; color: var(--muted-2); }

.kc-nav { display: flex; align-items: center; gap: 2px; margin-left: 10px; flex: 1; min-width: 0; }
.kc-cat { position: relative; }
.kc-cat-btn {
  height: 32px; padding: 0 10px; display: inline-flex; align-items: center; gap: 6px;
  border: 0; border-radius: var(--radius-xs);
  background: transparent; color: var(--muted); cursor: pointer;
  font: 500 13px/1 var(--sans); letter-spacing: 0; text-transform: none;
  transition: color .15s, background .15s; white-space: nowrap;
}
.kc-cat-btn:hover { color: var(--text); background: var(--surface-2); }
.kc-cat.is-active > .kc-cat-btn { color: var(--text); }
.kc-cat.is-open   > .kc-cat-btn { color: var(--text); background: var(--surface-2); }
.kc-cat.is-active > .kc-cat-btn::after {
  content: ""; position: absolute; left: 10px; right: 10px; bottom: -13px; height: 1px; background: var(--accent);
}
.kc-cat-btn .kc-caret { font-size: 7px; opacity: .5; }
/* Emoji category marks belong to the old ornate theme. */
.kc-cat-btn > span:first-child:not(.kc-caret) { display: none; }

.kc-menu {
  position: absolute; top: calc(100% + 9px); left: 0; z-index: 95; min-width: 234px;
  padding: 6px; display: none; flex-direction: column; gap: 1px;
  border: 1px solid var(--line-2); border-radius: var(--radius);
  background: var(--surface); box-shadow: 0 16px 40px rgba(0,0,0,.5);
}
.kc-cat.is-open .kc-menu { display: flex; }
.kc-menu a {
  padding: 8px 10px; border-radius: var(--radius-xs); color: var(--text-dim);
  font-size: 13px; font-weight: 400; display: flex; align-items: center; justify-content: space-between; gap: 10px;
  transition: background .12s, color .12s;
}
.kc-menu a:hover { background: var(--surface-2); color: var(--text); }
.kc-menu a.is-active { color: var(--accent); }
.kc-menu a .kc-menu-tag { font-size: 9px; letter-spacing: .07em; text-transform: uppercase; color: var(--muted-2); border: 1px solid var(--line); border-radius: 4px; padding: 2px 5px; }

.kc-header-right { display: flex; align-items: center; gap: 8px; margin-left: auto; flex-shrink: 0; }

.kc-lang { display: flex; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius-xs); }
.kc-lang button { width: 34px; height: 28px; border: 0; background: transparent; color: var(--muted); font: 600 11px var(--sans); cursor: pointer; transition: color .15s, background .15s; }
.kc-lang button:hover { color: var(--text); }
.kc-lang button.is-active { background: var(--surface-3); color: var(--text); }

.kc-userchip {
  display: inline-flex; align-items: center; gap: 7px; height: 30px; padding: 0 11px;
  border: 1px solid var(--line); border-radius: var(--radius-xs);
  background: transparent; color: var(--text-dim); font-size: 12.5px; font-weight: 500;
  cursor: pointer; white-space: nowrap; max-width: 190px; overflow: hidden; text-overflow: ellipsis;
  transition: border-color .15s, color .15s;
}
.kc-userchip:hover { border-color: var(--line-3); color: var(--text); }
.kc-userchip .kc-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--success); flex-shrink: 0; }
.kc-userchip .kc-badge-admin { font-size: 9px; letter-spacing: .05em; padding: 1px 4px; border-radius: 3px; background: var(--accent); color: var(--accent-ink); font-weight: 700; }

.kc-burger { display: none; width: 34px; height: 30px; border: 1px solid var(--line); border-radius: var(--radius-xs); background: transparent; color: var(--text-dim); font-size: 14px; cursor: pointer; }

/* ------------------------------------------------------------------ banner */
/* A page header, not an ornament: no frame, no glow, no lamps. */
.kc-banner { position: relative; margin: 0 0 26px; padding: 0 0 22px; border: 0; border-bottom: 1px solid var(--line); background: none; box-shadow: none; }
.kc-banner::before, .kc-banner::after { content: none; }
.kc-banner-inner { display: flex; flex-direction: column; align-items: flex-start; text-align: left; padding: 0; min-height: 0; }
.kc-banner-kicker { color: var(--muted-2); font: 500 11px var(--sans); letter-spacing: .18em; text-transform: uppercase; }
.kc-banner-title {
  margin: 12px 0 0; font-family: var(--sans); font-size: clamp(28px, 4.4vw, 46px);
  line-height: 1.08; font-weight: 600; letter-spacing: -.03em; color: var(--text); text-shadow: none;
}
.kc-banner-sub { margin-top: 12px; color: var(--muted); font-size: 14px; letter-spacing: 0; text-transform: none; max-width: 66ch; line-height: 1.6; }
.kc-banner-lights { display: none; }
.kc-banner.is-compact { min-height: 0; padding-bottom: 16px; margin-bottom: 20px; }
.kc-banner.is-compact .kc-banner-inner { min-height: 0; padding: 0; }

/* ------------------------------------------------------------------ panels */
.kc-panel {
  border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--surface); box-shadow: none;
  overflow: hidden; margin: 0 0 16px;
}
.kc-panel-head {
  display: flex; align-items: flex-end; justify-content: space-between; flex-wrap: wrap; gap: 12px;
  padding: 16px 18px; border-bottom: 1px solid var(--line); background: none;
}
.kc-panel-head h2, .kc-panel-head h3 { margin: 0; }
.kc-panel-head p { margin: 5px 0 0; color: var(--muted); font-size: 12.5px; }
.kc-panel-body { padding: 18px; }
.kc-panel-foot { padding: 13px 18px; border-top: 1px solid var(--line); color: var(--muted-2); font-size: 11.5px; line-height: 1.5; }
.kc-panel.is-plain { background: transparent; border-color: transparent; }

.kc-badge {
  display: inline-block; border: 1px solid var(--line-2); background: transparent; color: var(--muted);
  border-radius: 5px; padding: 3px 8px; font: 500 10.5px var(--sans); letter-spacing: .04em; text-transform: uppercase;
}
.kc-badge.is-gold { border-color: rgba(216,180,93,.4); background: var(--accent-bg); color: var(--accent); }
.kc-badge.is-danger { border-color: rgba(224,138,128,.4); color: var(--danger); }
.kc-badge.is-success { border-color: rgba(121,199,155,.4); color: var(--success); }

.kc-section-title { color: var(--muted); font: 500 11px var(--sans); text-transform: uppercase; letter-spacing: .13em; margin: 0 0 12px; }
.kc-section-title:not(:first-child) { margin-top: 22px; }

/* ------------------------------------------------------------------ grids */
.kc-grid { display: grid; gap: 12px; }
.kc-grid.c2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.kc-grid.c3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.kc-grid.c4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.kc-grid.c6 { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.kc-grid.auto { grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
.kc-grid.auto-lg { grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); }

/* ------------------------------------------------------------------- tiles */
.kc-tile {
  padding: 14px 15px; border: 1px solid var(--line); border-radius: var(--radius-sm);
  background: transparent; min-height: 0;
}
.kc-tile-label { display: flex; align-items: center; gap: 7px; color: var(--muted); font: 500 11px var(--sans); text-transform: uppercase; letter-spacing: .09em; }
.kc-tile-label img { width: 15px; height: 15px; opacity: .75; }
.kc-tile-value { margin-top: 8px; font: 600 24px/1.1 var(--sans); letter-spacing: -.02em; color: var(--text); word-break: break-word; font-variant-numeric: tabular-nums; }
.kc-tile-value.sm { font-size: 16px; }
.kc-tile-note { display: block; margin-top: 6px; color: var(--muted-2); font-size: 11.5px; line-height: 1.45; }

.kc-card {
  border: 1px solid var(--line); border-radius: var(--radius-sm); background: transparent;
  padding: 16px; transition: border-color .15s, background .15s;
}
.hof-card { display: flex; flex-direction: column; align-items: center; text-align: center; }
.hof-card-head { display: flex; flex-direction: column; align-items: center; gap: 10px; width: 100%; }
.hof-card-meta { min-width: 0; }
.hof-card-name { font-weight: 600; font-size: 15px; color: var(--text); overflow-wrap: anywhere; }
.hof-card-period { color: var(--muted); }
.hof-card-contribution { width: 100%; margin: 16px 0 0; text-align: left; }
.team-card { cursor: pointer; }
.team-card:hover, .team-card:focus-visible { border-color: var(--line-3); background: var(--surface-2); outline: none; }
.team-modal { width: min(620px, calc(100vw - 24px)); max-height: calc(100vh - 32px); padding: 0; border: 1px solid rgba(216,180,93,.4); border-radius: 14px; background: #0f1113; color: var(--text); }
.team-modal::backdrop { background: rgba(0,0,0,.68); }
.team-modal-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.team-modal-head h3 { margin: 0; font-size: 17px; }
.team-modal-x { width: 30px; height: 30px; border: 1px solid var(--line-2); border-radius: 8px; background: var(--surface-2); color: var(--text-dim); font-size: 17px; cursor: pointer; }
.team-modal-body { display: flex; flex-direction: column; gap: 14px; padding: 18px; overflow-y: auto; }
.team-profile { display: flex; align-items: center; gap: 18px; }
.team-profile-copy { min-width: 0; }
.team-profile-copy h4 { margin: 0 0 6px; font-size: 20px; }
.team-profile-copy p { margin: 4px 0 0; }
.team-comments-title { padding-top: 14px; border-top: 1px solid var(--line); font-size: 14px; font-weight: 600; }
.team-comments { display: flex; flex-direction: column; gap: 10px; max-height: 260px; overflow-y: auto; }
.team-comment { padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface-2); }
.team-comment-meta { display: flex; justify-content: space-between; gap: 12px; color: var(--text-dim); font-size: 12px; }
.team-comment-meta time { color: var(--muted-2); font-size: 11px; }
.team-comment p { margin: 7px 0 0; white-space: pre-wrap; overflow-wrap: anywhere; color: var(--text); font-size: 13px; line-height: 1.5; }
.team-comment-form { display: flex; flex-direction: column; gap: 8px; }
.team-comment-status { min-height: 18px; color: var(--muted); font-size: 12px; }
a.kc-card, .kc-card.is-link { cursor: pointer; display: block; color: inherit; }
a.kc-card:hover, .kc-card.is-link:hover { border-color: var(--line-3); background: var(--surface-2); transform: none; box-shadow: none; }
a.kc-card:hover h3 { color: var(--accent); }

/* ------------------------------------------------------- video & feed ui */
.kc-video { display: flex; flex-direction: column; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius-sm); background: transparent; transition: border-color .15s, background .15s; }
.kc-video:hover { border-color: var(--line-3); background: var(--surface-2); }
.kc-video:hover .kc-video-title a { color: var(--accent); }
.kc-video-media { position: relative; aspect-ratio: 16 / 9; background: var(--surface-2); }
.kc-video-media iframe { display: block; width: 100%; height: 100%; border: 0; }
.kc-video-thumb { display: block; width: 100%; height: 100%; padding: 0; border: 0; background: var(--surface-2); cursor: pointer; position: relative; }
.kc-video-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.kc-video-play {
  position: absolute; inset: 0; margin: auto; width: 46px; height: 46px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: rgba(12,13,14,.72); border: 1px solid var(--line-3); color: var(--text);
  font-size: 15px; transition: background .15s, border-color .15s, color .15s;
}
.kc-video-thumb:hover .kc-video-play { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.kc-video-dur, .kc-video-pin {
  position: absolute; bottom: 8px; right: 8px; padding: 2px 6px; border-radius: var(--radius-xs);
  background: rgba(12,13,14,.82); color: var(--text-dim);
  font: 500 10.5px var(--sans); font-variant-numeric: tabular-nums;
}
.kc-video-pin { left: 8px; right: auto; top: 8px; bottom: auto; color: var(--accent); }
.kc-video-body { padding: 13px 14px 15px; }
.kc-video-title { margin: 0 0 7px; font-size: 14px; font-weight: 500; line-height: 1.4; letter-spacing: 0; }
.kc-video-title a { color: var(--text); }
.kc-video-meta { display: flex; flex-wrap: wrap; gap: 12px; color: var(--muted-2); font-size: 11.5px; font-variant-numeric: tabular-nums; }
.kc-video-desc {
  margin: 9px 0 0; color: var(--muted); font-size: 12.5px; line-height: 1.55;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.kc-video.is-compact .kc-video-body { padding: 11px 12px 12px; }
.kc-video.is-compact .kc-video-title { font-size: 13px; }

/* Компактная лента-список: «все ссылки» на новости, видео и дни недели. */
.kc-feed { list-style: none; margin: 0; padding: 0; }
.kc-feed.is-scroll { max-height: 328px; overflow-y: auto; padding-right: 8px; }
.kc-feed li { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; padding: 11px 2px; border-bottom: 1px solid var(--line); }
.kc-feed li:last-child { border-bottom: 0; }
.kc-feed time { flex: 0 0 auto; min-width: 124px; color: var(--muted-2); font-size: 11.5px; font-variant-numeric: tabular-nums; }
.kc-feed a { flex: 1 1 220px; color: var(--text-dim); font-size: 13.5px; line-height: 1.5; }
.kc-feed a:hover { color: var(--accent); }
.kc-feed .kc-note { margin: 0; }
.kc-feed .kc-feed-name { flex: 1 1 200px; color: var(--text); font-size: 13.5px; font-weight: 500; }
.kc-feed li.is-now time, .kc-feed li.is-now .kc-feed-name, .kc-feed li.is-now > a { color: var(--accent); }
.kc-feed .kc-badge { flex: 0 0 auto; margin-left: auto; }

/* ------------------------------------------------------------------ forms */
.kc-field { margin: 0 0 14px; }
.kc-field > label { display: block; color: var(--text-dim); font: 500 12.5px var(--sans); margin: 0 0 6px; }
.kc-input, .kc-select, .kc-textarea {
  width: 100%; height: 36px; padding: 0 11px;
  border: 1px solid var(--line-2); border-radius: var(--radius-xs);
  background: var(--surface-2); color: var(--text); font: 400 13px var(--sans); outline: none;
  box-shadow: none; transition: border-color .15s, background .15s;
}
.kc-textarea { height: auto; min-height: 92px; padding: 9px 11px; resize: vertical; line-height: 1.5; }
.kc-input:hover, .kc-select:hover, .kc-textarea:hover { border-color: var(--line-3); }
.kc-input:focus, .kc-select:focus, .kc-textarea:focus { border-color: var(--accent); box-shadow: none; }
.kc-input::placeholder, .kc-textarea::placeholder { color: var(--muted-2); }
.kc-select {
  appearance: none; padding-right: 30px; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath fill='none' stroke='%23838d8d' stroke-width='1.4' stroke-linecap='round' stroke-linejoin='round' d='M1.5 2l4.5 4 4.5-4'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 11px center; background-size: 10px;
}
.kc-help { display: block; margin-top: 6px; color: var(--muted-2); font-size: 11px; line-height: 1.45; }

input[type="checkbox"].kc-check {
  appearance: none; width: 16px; height: 16px; min-width: 16px; margin: 0;
  border: 1px solid var(--line-3); border-radius: 4px; background: var(--surface-2);
  box-shadow: none; cursor: pointer; vertical-align: middle; transition: background .15s, border-color .15s;
}
input[type="checkbox"].kc-check:checked {
  border-color: var(--accent); background-color: var(--accent);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath fill='none' stroke='%2314100a' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round' d='M3.4 8.3l3 3 6.3-6.6'/%3E%3C/svg%3E");
  background-position: center; background-repeat: no-repeat; background-size: 12px;
}
input[type="range"] { accent-color: var(--accent); width: 100%; }

.kc-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  min-height: 36px; padding: 0 15px; border-radius: var(--radius-xs);
  border: 1px solid var(--line-2); background: transparent; color: var(--text-dim);
  font: 500 13px var(--sans); letter-spacing: 0; cursor: pointer;
  transition: border-color .15s, color .15s, background .15s;
}
.kc-btn:hover { color: var(--text); border-color: var(--line-3); background: var(--surface-2); filter: none; transform: none; }
.kc-btn:disabled { opacity: .45; cursor: not-allowed; }
.kc-btn.is-primary { border-color: var(--accent); background: var(--accent); color: var(--accent-ink); font-weight: 600; box-shadow: none; }
.kc-btn.is-primary:hover { background: #e6c472; border-color: #e6c472; color: var(--accent-ink); }
.kc-btn.is-teal { border-color: var(--line-2); background: transparent; color: var(--text-dim); box-shadow: none; }
.kc-btn.is-teal:hover { color: var(--text); border-color: var(--line-3); background: var(--surface-2); }
.kc-btn.is-danger { border-color: rgba(224,138,128,.35); color: var(--danger); }
.kc-btn.is-danger:hover { border-color: var(--danger); color: var(--danger); background: rgba(224,138,128,.08); }
.kc-btn.is-ghost { border-color: transparent; }
.kc-btn.is-ghost:hover { border-color: var(--line); }
.kc-btn.sm { min-height: 28px; padding: 0 10px; font-size: 12px; }
.kc-btn.block { width: 100%; }

.kc-toolbar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.kc-toolbar .kc-input, .kc-toolbar .kc-select { width: auto; min-width: 165px; flex: 0 1 auto; }
.kc-toolbar .grow { flex: 1 1 200px; min-width: 150px; }

.kc-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.kc-chip {
  min-height: 28px; padding: 0 11px; display: inline-flex; align-items: center;
  border: 1px solid var(--line); border-radius: 999px; background: transparent;
  color: var(--muted); font: 500 12px var(--sans); cursor: pointer; transition: .15s;
}
.kc-chip:hover { color: var(--text); border-color: var(--line-3); }
.kc-chip.is-active { color: var(--accent); border-color: rgba(216,180,93,.45); background: var(--accent-bg); box-shadow: none; }

/* ------------------------------------------------------------------ tables */
.kc-table-wrap { overflow: auto; max-width: 100%; }
.kc-table { width: 100%; border-collapse: collapse; }
.kc-table th {
  position: sticky; top: 0; z-index: 2; padding: 10px 12px; white-space: nowrap;
  border-bottom: 1px solid var(--line-2); background: var(--surface);
  color: var(--muted); text-align: left; font: 500 11px var(--sans); letter-spacing: .08em; text-transform: uppercase;
}
.kc-table th.sortable { cursor: pointer; user-select: none; }
.kc-table th.sortable:hover { color: var(--text); }
.kc-table td { padding: 10px 12px; border-bottom: 1px solid var(--line); font-size: 13px; vertical-align: middle; color: var(--text-dim); }
.kc-table tbody tr:hover td { background: var(--surface-2); }
.kc-table tbody tr:last-child td { border-bottom: 0; }
.kc-table td.num, .kc-table th.num { text-align: right; font-variant-numeric: tabular-nums; }
.kc-table .rank { color: var(--muted); font-weight: 500; font-variant-numeric: tabular-nums; }
.kc-table .best { color: var(--accent); font-weight: 600; }
.kc-table .high { color: var(--text); font-weight: 500; }
.kc-rowlink { cursor: pointer; }

.kc-petcell { display: flex; align-items: center; gap: 11px; min-width: 200px; }
.kc-petcell img { width: 34px; height: 34px; border: 1px solid var(--line); border-radius: 7px; background: var(--surface-2); object-fit: cover; flex-shrink: 0; }
.kc-iconcell { display: flex; align-items: center; gap: 8px; }
.kc-iconcell img { width: 22px; height: 22px; border-radius: 5px; flex-shrink: 0; }

/* ------------------------------------------------------------------- misc */
.kc-empty { padding: 34px 20px; text-align: center; color: var(--muted); }
.kc-empty .mark { display: none; }
.kc-empty strong, .kc-empty b { color: var(--text-dim); font-weight: 500; }
.kc-loading { padding: 34px; text-align: center; color: var(--muted-2); font-size: 13px; }
.kc-error { border: 1px solid rgba(224,138,128,.35); background: rgba(224,138,128,.07); color: var(--danger); padding: 11px 13px; border-radius: var(--radius-xs); font-size: 13px; margin: 0 0 12px; }
.kc-ok { border: 1px solid rgba(121,199,155,.35); background: rgba(121,199,155,.07); color: var(--success); padding: 11px 13px; border-radius: var(--radius-xs); font-size: 13px; margin: 0 0 12px; }
.kc-note { color: var(--muted); font-size: 12px; line-height: 1.6; }
.kc-note strong { color: var(--text-dim); font-weight: 500; }
.kc-kv { display: grid; grid-template-columns: max-content 1fr; gap: 8px 16px; font-size: 13px; }
.kc-kv dt { color: var(--muted); }
.kc-kv dd { margin: 0; color: var(--text); font-weight: 500; }
.kc-bar { height: 4px; border-radius: 2px; background: var(--surface-3); overflow: hidden; }
.kc-bar > span { display: block; height: 100%; background: var(--accent); }
.kc-prose { max-width: 72ch; color: var(--text-dim); }
.kc-prose h2 { margin-top: 1.5em; }
.kc-prose ul, .kc-prose ol { padding-left: 1.25em; color: var(--text-dim); }
.kc-prose li { margin: .4em 0; }
.kc-breadcrumb { font-size: 11px; color: var(--muted-2); margin: 0 0 16px; letter-spacing: .1em; text-transform: uppercase; }
.kc-breadcrumb a { color: var(--muted-2); }
.kc-breadcrumb a:hover { color: var(--text); }

/* ------------------------------------------------------------------- home */
.kc-hero { padding: 40px 0 34px; border-bottom: 1px solid var(--line); margin-bottom: 30px; }
.kc-hero-banner {
  display: block; width: 100%; height: auto; margin: 0 0 30px;
  border: 1px solid var(--line); border-radius: 12px; background: var(--surface);
}
.kc-hero-kicker { color: var(--muted-2); font: 500 11px var(--sans); letter-spacing: .2em; text-transform: uppercase; }
.kc-hero h1 { margin: 16px 0 0; max-width: 24ch; }
.kc-hero-lead { margin: 16px 0 0; max-width: 60ch; color: var(--muted); font-size: 15px; line-height: 1.65; }
.kc-hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 26px; }

.kc-statrow { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius-sm); overflow: hidden; }
.kc-statrow.is-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.kc-statrow.is-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
/* Плотный вариант для карточки каталога: там ряд живёт в колонке ~300px. */
.kc-statrow.is-compact > div { padding: 10px 11px 9px; }
.kc-statrow.is-compact .v { font-size: 16px; }
.kc-statrow.is-compact .k { margin-top: 4px; font-size: 10.5px; }
.kc-statrow > div { background: var(--bg); padding: 16px 16px 15px; }
.kc-statrow .v { font: 600 21px/1.1 var(--sans); letter-spacing: -.02em; color: var(--text); font-variant-numeric: tabular-nums; }
.kc-statrow .v.sm { font-size: 14px; }
.kc-statrow .k { margin-top: 7px; color: var(--muted-2); font-size: 11px; line-height: 1.35; }

.kc-linkgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 34px; }
.kc-linkrow { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 15px 2px; border-bottom: 1px solid var(--line); color: inherit; transition: padding-left .15s; }
.kc-linkrow:last-child { border-bottom: 0; }
.kc-linkrow:hover { padding-left: 6px; }
.kc-linkrow:hover .kc-linkrow-title { color: var(--accent); }
.kc-linkrow-title { font-size: 14px; font-weight: 500; color: var(--text); }
.kc-linkrow-desc { margin-top: 4px; color: var(--muted); font-size: 12.5px; line-height: 1.5; }
.kc-linkrow-arrow { color: var(--muted-2); font-size: 15px; flex-shrink: 0; }

.kc-pending { display: flex; align-items: center; gap: 10px; padding: 14px 0; color: var(--muted-2); font-size: 12.5px; border-bottom: 1px solid var(--line); }
.kc-pending:last-child { border-bottom: 0; }
.kc-pending .n { color: var(--text-dim); font-weight: 500; }
.kc-pending .s { margin-left: auto; font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted-2); white-space: nowrap; }

/* full-bleed frame for the original War Pet Builder */
.kc-frame-wrap { position: relative; width: 100%; height: calc(100vh - var(--header-h)); border: 0; }
.kc-frame-wrap iframe { display: block; width: 100%; height: 100%; border: 0; background: var(--bg); }

/* --------------------------------------------------------- support widget */
.kc-support-launcher {
  position: fixed; right: 20px; bottom: 20px; z-index: 120;
  display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 15px;
  border: 1px solid var(--line-2); border-radius: 999px;
  background: var(--surface); color: var(--text-dim);
  font: 500 12.5px var(--sans); cursor: pointer;
  box-shadow: 0 8px 26px rgba(0,0,0,.45);
  transition: border-color .15s, color .15s;
}
.kc-support-launcher:hover { transform: none; filter: none; border-color: var(--line-3); color: var(--text); }
.kc-support-launcher .mark { font-size: 14px; opacity: .8; }
.kc-support-launcher .kc-unread {
  min-width: 17px; height: 17px; padding: 0 5px; border-radius: 9px;
  background: var(--accent); color: var(--accent-ink); font: 700 10px/17px var(--sans); text-align: center;
}
.kc-support-launcher[hidden] { display: none; }

.kc-support-panel {
  position: fixed; right: 20px; bottom: 20px; z-index: 121;
  width: min(370px, calc(100vw - 32px)); max-height: min(620px, calc(100vh - 40px));
  display: flex; flex-direction: column; overflow: hidden;
  border: 1px solid var(--line-2); border-radius: var(--radius);
  background: var(--surface);
  box-shadow: 0 20px 60px rgba(0,0,0,.6);
  animation: kc-slide-up .18s ease;
}
@keyframes kc-slide-up { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.kc-support-head { padding: 14px 15px; border-bottom: 1px solid var(--line); background: none; display: flex; align-items: flex-start; gap: 10px; }
.kc-support-head h3 { margin: 0; font-size: 14px; }
.kc-support-head p { margin: 4px 0 0; color: var(--muted-2); font-size: 11.5px; line-height: 1.45; }
.kc-support-close { margin-left: auto; width: 26px; height: 26px; border: 1px solid var(--line); border-radius: 6px; background: transparent; color: var(--muted); cursor: pointer; font-size: 13px; line-height: 1; flex-shrink: 0; }
.kc-support-close:hover { color: var(--text); border-color: var(--line-3); }
.kc-support-body { flex: 1; overflow-y: auto; padding: 14px 15px; display: flex; flex-direction: column; gap: 9px; min-height: 130px; }
.kc-msg { max-width: 88%; padding: 9px 12px; border-radius: 10px; font-size: 13px; line-height: 1.5; white-space: pre-wrap; word-break: break-word; }
.kc-msg.from-user { align-self: flex-end; background: var(--surface-3); color: var(--text); border-bottom-right-radius: 4px; }
.kc-msg.from-admin { align-self: flex-start; background: transparent; border: 1px solid var(--line-2); color: var(--text-dim); border-bottom-left-radius: 4px; }
.kc-msg.from-system { align-self: center; background: transparent; color: var(--muted-2); font-size: 11.5px; text-align: center; max-width: 100%; }
.kc-msg-time { display: block; margin-top: 4px; font-size: 9.5px; opacity: .55; }
.kc-support-foot { padding: 11px 15px 13px; border-top: 1px solid var(--line); display: flex; flex-direction: column; gap: 8px; }
.kc-support-foot .kc-textarea { min-height: 60px; font-size: 13px; }
.kc-support-row { display: flex; gap: 8px; }
.kc-support-row .kc-input, .kc-support-row .kc-select { height: 32px; font-size: 12px; }

/* --------------------------------------------------------------- admin ui */
.kc-admin-layout { display: grid; grid-template-columns: minmax(280px, 370px) 1fr; gap: 14px; align-items: start; }
.kc-thread-list { max-height: 620px; overflow-y: auto; }
.kc-thread-item { width: 100%; text-align: left; padding: 12px 14px; border: 0; border-bottom: 1px solid var(--line); background: transparent; color: inherit; cursor: pointer; display: block; }
.kc-thread-item:hover { background: var(--surface-2); }
.kc-thread-item.is-active { background: var(--surface-2); box-shadow: inset 2px 0 0 var(--accent); }
.kc-thread-item .who { display: flex; align-items: center; gap: 7px; font-weight: 500; font-size: 13px; color: var(--text); }
.kc-thread-item .snippet { margin-top: 4px; color: var(--muted); font-size: 12px; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.kc-thread-item .meta { margin-top: 6px; display: flex; gap: 7px; align-items: center; font-size: 10.5px; color: var(--muted-2); }
.kc-unread-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); flex-shrink: 0; }
.kc-chat-log { max-height: 420px; overflow-y: auto; display: flex; flex-direction: column; gap: 9px; padding: 14px 16px; }
.kc-sparkline { display: flex; align-items: flex-end; gap: 3px; height: 58px; }
.kc-sparkline > div { flex: 1; min-width: 3px; background: var(--surface-3); border-radius: 2px 2px 0 0; position: relative; transition: background .15s; }
.kc-sparkline > div:hover { background: var(--accent); }
.kc-sparkline > div:hover::after { content: attr(data-label); position: absolute; bottom: 100%; left: 50%; transform: translateX(-50%); white-space: nowrap; background: var(--surface); border: 1px solid var(--line-2); border-radius: 6px; padding: 3px 7px; font-size: 10.5px; color: var(--text); z-index: 3; }

/* ----------------------------------------------------------------- footer */
.kc-footer { border-top: 1px solid var(--line); padding: 34px 24px 42px; margin-top: 24px; }
.kc-footer-inner { max-width: var(--maxw); margin: 0 auto; display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 26px; }
.kc-footer h4 { font: 500 11px var(--sans); letter-spacing: .13em; text-transform: uppercase; color: var(--muted-2); margin: 0 0 12px; }
.kc-footer ul { list-style: none; margin: 0; padding: 0; }
.kc-footer li { margin: 0 0 7px; }
.kc-footer a { color: var(--muted); font-size: 12.5px; }
.kc-footer a:hover { color: var(--text); }
.kc-footer-note { max-width: var(--maxw); margin: 30px auto 0; padding-top: 20px; border-top: 1px solid var(--line); color: var(--muted-2); font-size: 11.5px; line-height: 1.7; }

/* ------------------------------------------------------------ responsive */
@media (max-width: 1180px) {
  .kc-grid.c6 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .kc-statrow { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .kc-admin-layout { grid-template-columns: 1fr; }
}
@media (max-width: 1024px) {
  .kc-nav { display: none; }
  .kc-burger { display: block; }
  .kc-nav.is-mobile-open {
    display: flex; flex-direction: column; align-items: stretch; gap: 2px;
    position: fixed; inset: var(--header-h) 0 auto 0; z-index: 94; margin: 0;
    padding: 12px 16px 20px; max-height: calc(100vh - var(--header-h)); overflow-y: auto;
    background: var(--bg); border-bottom: 1px solid var(--line);
    box-shadow: 0 24px 60px rgba(0,0,0,.6);
  }
  .kc-nav.is-mobile-open::after {
    content: ""; position: fixed; inset: 0 0 0 0; top: 100%; z-index: -1;
    background: rgba(0,0,0,.6);
  }
  .kc-nav.is-mobile-open .kc-cat { position: static; }
  .kc-nav.is-mobile-open .kc-cat-btn { width: 100%; justify-content: space-between; height: 42px; font-size: 14px; }
  .kc-nav.is-mobile-open .kc-cat.is-active > .kc-cat-btn::after { content: none; }
  .kc-nav.is-mobile-open .kc-menu { position: static; display: none; margin: 2px 0 8px; box-shadow: none; background: transparent; border: 0; border-left: 1px solid var(--line); border-radius: 0; padding: 0 0 0 12px; }
  .kc-nav.is-mobile-open .kc-cat.is-open .kc-menu { display: flex; }
}
@media (max-width: 900px) {
  .kc-linkgrid { grid-template-columns: 1fr; column-gap: 0; }
  .kc-grid.c4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kc-grid.c3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kc-main { padding: 20px 16px 80px; }
  .kc-header-inner { padding: 0 16px; }
  .kc-hero { padding: 28px 0 26px; margin-bottom: 24px; }
  .kc-hero-banner { margin-bottom: 22px; border-radius: 9px; }
  .kc-footer { padding: 28px 16px 40px; }
}
@media (max-width: 640px) {
  .kc-feed time { min-width: 100%; }
  .kc-feed .kc-badge { margin-left: 0; }
  .kc-grid.c2, .kc-grid.c3, .kc-grid.c4, .kc-grid.c6 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kc-statrow { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kc-brand-sub { display: none; }
  .kc-support-launcher { right: 12px; bottom: 12px; }
  .kc-support-panel { right: 8px; bottom: 8px; width: calc(100vw - 16px); max-height: calc(100vh - 16px); }
  .kc-toolbar .kc-input, .kc-toolbar .kc-select { min-width: 0; flex: 1 1 130px; }
  .kc-panel-body, .kc-panel-head { padding: 14px; }
  .kc-pending { flex-wrap: wrap; gap: 4px 10px; }
  .kc-pending > span:nth-child(2) { order: 3; width: 100%; }
}
@media (max-width: 460px) {
  .kc-grid.c2, .kc-grid.c3, .kc-grid.c4, .kc-grid.c6 { grid-template-columns: 1fr; }
  .kc-userchip { max-width: 96px; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: .001ms !important; transition-duration: .001ms !important; }
  html { scroll-behavior: auto; }
}

@media print {
  .kc-header, .kc-support-launcher, .kc-support-panel, .kc-footer { display: none !important; }
  body { background: #fff; color: #000; }
}

/* --------------------------------------------------- RankDumper actions */
.kc-inline-action { display: inline-flex; align-items: center; flex-wrap: wrap; gap: 7px; }
.kc-action-status { font: 700 10px var(--sans); color: var(--muted); max-width: 260px; }
.kc-action-status.is-success { color: var(--success); }
.kc-action-status.is-danger { color: var(--danger); }
.kc-action-status.is-warn { color: var(--gold-soft); }

/* ------------------------------------------------- player achievements */
.kc-ach-main { min-width: 280px; max-width: 520px; }
.kc-ach-name { color: var(--text); font-weight: 800; font-size: 13px; line-height: 1.35; }
.kc-ach-description { margin-top: 4px; color: var(--text-dim); font-size: 11.5px; line-height: 1.45; white-space: normal; }
.kc-ach-id { margin-top: 6px; color: var(--muted-2); font: 700 9.5px var(--sans); letter-spacing: .04em; }
.kc-ach-meta, .kc-ach-state { display: flex; min-width: 150px; flex-direction: column; gap: 6px; align-items: flex-start; }
.kc-ach-tags { display: flex; flex-wrap: wrap; gap: 5px; }
.kc-ach-meta-line { display: flex; flex-wrap: wrap; gap: 5px 7px; align-items: center; color: var(--text-dim); font-size: 10.5px; line-height: 1.35; }
.kc-ach-meta-label { color: var(--muted-2); }
.kc-ach-meta-value { color: var(--text-dim); font-weight: 700; }
.kc-ach-progress { min-width: 180px; }
.kc-ach-progress-value { color: var(--text); font-weight: 800; font-variant-numeric: tabular-nums; }
.kc-ach-progress-note { margin-top: 3px; color: var(--muted-2); font-size: 10px; }
.kc-ach-progress-row { display: flex; gap: 8px; align-items: center; margin-top: 7px; }
.kc-ach-progress-bar { width: 120px; flex: 1 1 auto; min-width: 70px; }
.kc-ach-percent { min-width: 38px; color: var(--gold-soft); font: 800 10px var(--sans); text-align: right; font-variant-numeric: tabular-nums; }

@media (max-width: 640px) {
  .kc-ach-main { min-width: 240px; }
}

/* Detailed PlayerMoreInfoAck statistics */
.kc-more-panel .kc-panel-head { align-items: stretch; }
.kc-more-head { display: block; padding: 16px 18px 13px; }
.kc-more-head-main {
  display: flex; align-items: center; justify-content: space-between; gap: 18px;
}
.kc-more-title { min-width: 0; }
.kc-more-title h2 { line-height: 1.15; }
.kc-more-title p { max-width: 700px; line-height: 1.45; }
.kc-more-controls {
  display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap;
  gap: 8px; flex: 0 0 auto;
}
.kc-more-controls .kc-action-status { max-width: 220px; }
.kc-more-meta {
  display: flex; flex-wrap: wrap; align-items: center; gap: 7px 14px;
  margin-top: 12px; padding-top: 10px;
  border-top: 1px solid rgba(216,180,93,.10);
  color: var(--muted); font-size: 10.5px;
}
.kc-more-meta > span:not(.kc-badge) { white-space: nowrap; }
.kc-more-warning {
  margin-bottom: 14px; padding: 10px 12px;
  border: 1px solid rgba(226,87,74,.32); border-radius: 9px;
  background: rgba(226,87,74,.08); color: #f2b1aa;
  font-size: 11px; line-height: 1.45; word-break: break-word;
}

/* Six virtual columns allow a balanced 3 + 2 composition on wide screens:
   power / combat / resources, then events / sunset. */
.kc-more-grid {
  display: grid; grid-template-columns: repeat(6, minmax(0, 1fr));
  grid-auto-flow: dense; gap: 14px; align-items: stretch;
}
.kc-more-card {
  grid-column: span 2; min-width: 0; height: 100%;
  border: 1px solid var(--line); border-radius: 11px;
  background: var(--surface-2);
  overflow: hidden;
}
.kc-more-card-events, .kc-more-card-sunset { grid-column: span 3; }
.kc-more-card-other { grid-column: 1 / -1; }
.kc-more-card h3 {
  margin: 0; padding: 11px 13px;
  border-bottom: 1px solid rgba(216,180,93,.12);
  background: rgba(9,45,49,.18);
  color: var(--gold-soft); font: 800 11px var(--sans);
  letter-spacing: .045em; text-transform: uppercase;
}
.kc-more-list { display: flex; flex-direction: column; }
.kc-more-row {
  display: grid; grid-template-columns: minmax(135px, 1fr) minmax(105px, auto);
  gap: 12px; align-items: start; padding: 8px 12px;
  border-bottom: 1px solid rgba(255,255,255,.045);
}
.kc-more-row:last-child { border-bottom: 0; }
.kc-more-label { min-width: 0; color: var(--muted); font-size: 10.5px; line-height: 1.4; }
.kc-more-data {
  min-width: 0; color: var(--text); text-align: right;
  font-size: 11px; line-height: 1.4; font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}
.kc-more-value { font-weight: 800; }
.kc-more-tags { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 4px; }
.kc-more-stack { display: flex; flex-direction: column; gap: 4px; }
.kc-more-nested { color: var(--text-dim); font-size: 10px; line-height: 1.35; }
.kc-more-json {
  display: inline-block; max-width: 320px; white-space: normal;
  word-break: break-word; color: var(--text-dim); font-size: 9.5px;
}

@media (max-width: 1080px) {
  .kc-more-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kc-more-card, .kc-more-card-events, .kc-more-card-sunset { grid-column: auto; }
  .kc-more-card-other { grid-column: 1 / -1; }
  .kc-more-card:last-child:nth-child(odd):not(.kc-more-card-other) { grid-column: 1 / -1; }
}

@media (max-width: 760px) {
  .kc-more-head-main { align-items: flex-start; flex-direction: column; gap: 12px; }
  .kc-more-controls { width: 100%; justify-content: flex-start; }
  .kc-more-meta { gap: 6px 10px; }
  .kc-more-meta > span:not(.kc-badge) { white-space: normal; }
  .kc-more-grid { grid-template-columns: 1fr; }
  .kc-more-card, .kc-more-card-events, .kc-more-card-sunset, .kc-more-card-other,
  .kc-more-card:last-child:nth-child(odd):not(.kc-more-card-other) { grid-column: 1; }
}

@media (max-width: 640px) {
  .kc-more-head { padding: 14px 14px 12px; }
  .kc-more-panel .kc-panel-body { padding: 13px 14px 15px; }
  .kc-more-row { grid-template-columns: 1fr; gap: 3px; padding: 8px 11px; }
  .kc-more-data { text-align: left; }
  .kc-more-tags { justify-content: flex-start; }
}

/* ------------------------------------------------ global PlayerMore TOP-100 */
.kc-tops-controls { display: flex; flex-direction: column; gap: 12px; }
.kc-tops-metric { min-width: min(100%, 330px); }
.kc-tops-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 7px 14px; color: var(--muted); font-size: 10.5px; }
.kc-tops-note { padding: 10px 12px; border: 1px solid rgba(216,180,93,.14); border-radius: 9px; background: rgba(9,45,49,.16); color: var(--text-dim); font-size: 11px; line-height: 1.5; }
.kc-tops-value { white-space: nowrap; font-variant-numeric: tabular-nums; }
.kc-tops-updated { display: flex; flex-direction: column; align-items: flex-start; gap: 5px; min-width: 138px; }
.kc-tops-auto { display: flex; align-items: center; justify-content: flex-end; }
@media (max-width: 760px) {
  .kc-tops-panel .kc-panel-head { align-items: flex-start; flex-direction: column; gap: 10px; }
  .kc-tops-auto { justify-content: flex-start; }
  .kc-tops-metric { width: 100%; min-width: 0; }
}

/* ------------------------------------------------------ streamed lists */
html { scroll-behavior: smooth; }
.kc-stream-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}
.kc-stream-sentinel {
  min-height: 46px;
  padding: 10px 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: var(--muted);
  font-size: 12px;
  text-align: center;
  border-radius: 12px;
  transition: opacity .22s ease, background-color .22s ease, border-color .22s ease;
}
.kc-panel-body > .kc-stream-sentinel { margin-top: 16px; }
.kc-stream-sentinel.is-loading {
  color: var(--text-dim);
  background: rgba(7, 35, 39, .34);
}
.kc-stream-sentinel.is-done { opacity: .65; }
.kc-stream-dots { display: inline-flex; gap: 4px; min-width: 30px; justify-content: center; }
.kc-stream-dots i {
  width: 5px; height: 5px; border-radius: 50%;
  background: var(--accent);
  opacity: .28;
  transform: translateY(0);
}
.kc-stream-sentinel.is-loading .kc-stream-dots i { animation: kcStreamDot 1s ease-in-out infinite; }
.kc-stream-sentinel.is-loading .kc-stream-dots i:nth-child(2) { animation-delay: .13s; }
.kc-stream-sentinel.is-loading .kc-stream-dots i:nth-child(3) { animation-delay: .26s; }
.kc-stream-sentinel.is-done .kc-stream-dots { display: none; }
.kc-stream-item {
  animation: kcStreamReveal .34s cubic-bezier(.2,.72,.28,1) both;
  animation-delay: var(--kc-stream-delay, 0ms);
}
@keyframes kcStreamReveal {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes kcStreamDot {
  0%, 60%, 100% { opacity: .28; transform: translateY(0); }
  30% { opacity: 1; transform: translateY(-4px); }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .kc-stream-item, .kc-stream-sentinel.is-loading .kc-stream-dots i { animation: none !important; }
}

/* Quality update: readable controls, keyboard navigation and reduced motion. */
body { font-size: 1rem; }
.kc-page { min-width: 0; }
.kc-main.is-flush > .kc-page { height: 100%; }
.kc-panel-head p, .kc-note, .kc-menu a, .kc-table td,
.kc-btn.sm, .kc-field label, .kc-input, .kc-select, .kc-textarea { font-size: .875rem; }
.kc-help, .kc-panel-foot, .kc-tile-note, .kc-video-meta { font-size: .8125rem; }
.kc-sort-btn { border: 0; background: transparent; color: inherit; font: inherit; cursor: pointer; padding: 4px 0; text-align: inherit; }
.kc-skip { position: fixed; top: 8px; left: 12px; z-index: 10000; padding: 12px 18px; background: var(--accent); color: var(--accent-ink); border-radius: 8px; transform: translateY(-180%); }
.kc-skip:focus { transform: none; }
.kc-main:focus { outline: none; }
.kc-kv { grid-template-columns: minmax(0, max-content) minmax(0, 1fr); overflow-wrap: anywhere; }
@media (max-width: 640px) {
  .kc-main { padding-inline: 16px; }
  .kc-btn, .kc-input, .kc-select, .kc-burger, .kc-cat-btn, .kc-menu a { min-height: 44px; }
  .kc-input, .kc-select, .kc-textarea { font-size: 1rem; max-width: 100%; }
  .kc-toolbar { min-width: 0; flex-wrap: wrap; }
  .kc-panel-head { flex-wrap: wrap; }
  .kc-frame-wrap { height: calc(100dvh - var(--header-h) - 100px) !important; min-height: 420px; }
  .kc-brand-text { min-width: 0; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}
@media (max-width: 640px) {
  .kc-header-inner { gap: 8px; padding-inline: 12px; }
  .kc-brand { flex: 1 1 auto; min-width: 0; }
  .kc-brand-name { overflow: hidden; text-overflow: ellipsis; }
  .kc-burger { flex: 0 0 36px; width: 36px; }
  .kc-header-right { gap: 6px; }
}


/* World statistics and responsive page layout. */
.kc-brand .kc-brand-mark { width: 42px; height: 42px; object-fit: contain; }
.kc-main:has(.kc-hero) { max-width: none; padding: 0 0 64px; --home-gutter: 24px; }
.kc-main:has(.kc-hero) > .kc-page { max-width: none; }
.kc-main:has(.kc-hero) > .kc-page > :not(.kc-hero) { width: calc(100% - 2 * var(--home-gutter)); max-width: 1272px; margin-inline: auto; }
.kc-hero > :not(.kc-hero-banner) { margin-left: max(var(--home-gutter), calc((100% - 1272px) / 2)); margin-right: var(--home-gutter); }
.kc-hero { padding-top: 0; }
.kc-hero-banner { width: 100%; max-width: none; margin-left: 0; height: clamp(240px, 33vw, 680px); object-fit: cover; object-position: center; border: 0; border-radius: 0; background: transparent; }
.kc-page, .kc-panel, .kc-panel-body, .kc-grid > *, .kc-toolbar > *, .kc-compare-picker { min-width: 0; }
.kc-page img:not(.kc-hero-banner), .kc-page video { max-width: 100%; }
.kc-page iframe { max-width: 100%; }
.kc-panel-head { flex-wrap: wrap; gap: 16px; }
.kc-panel-head > div { min-width: 0; }
.kc-page h1 { font-size: clamp(24px, 3vw, 36px); overflow-wrap: anywhere; }
.kc-page h2, .kc-page h3, .kc-page p, .kc-page pre { overflow-wrap: anywhere; }
.kc-page pre { max-width: 100%; overflow: auto; }
.kc-stats-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.kc-stats-note { color: var(--muted); font-size: 12px; line-height: 1.7; }
.kc-stats-disclosure { margin-top: 16px; border-top: 1px solid var(--line); padding-top: 12px; }
.kc-stats-disclosure summary { cursor: pointer; padding: 8px 0; font-weight: 600; }
.kc-stats-filters { display: grid; grid-template-columns: repeat(auto-fit,minmax(220px,1fr)); gap: 16px; padding: 16px 0; }
.kc-range-field > span { display: block; font-size: 12px; color: var(--muted); margin-bottom: 7px; }
.kc-range-field > div { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.kc-range-field input { min-width: 0; width: 100%; }
.kc-stats-columns { display: grid; grid-template-columns: repeat(auto-fit,minmax(210px,1fr)); gap: 12px; padding: 16px 0; }
.kc-stats-columns label { display: flex; align-items: center; gap: 8px; font-size: 12px; }
.kc-world-sub { display: block; color: var(--muted); font-size: 11px; margin-top: 4px; }
.kc-world-table .kc-table-wrap { max-height: 70vh; overscroll-behavior: contain; scrollbar-gutter: stable; }
.kc-world-table th { position: sticky; top: 0; z-index: 2; background: var(--surface); }
.kc-world-table td.num { white-space: nowrap; }
.kc-world-pagination { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.kc-compare-pickers { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 24px; }
.kc-compare-picker { border: 1px solid var(--line); border-radius: 10px; padding: 16px; background: var(--surface); }
.kc-compare-picker h3 { margin-top: 0; }
.kc-compare-selected { padding: 12px 0; color: var(--accent); }
.kc-compare-results { max-height: 280px; overflow-y: auto; }
.kc-compare-result { display: block; text-align: left; width: 100%; background: transparent; color: var(--text); border: 0; border-bottom: 1px solid var(--line); padding: 12px 8px; cursor: pointer; overflow-wrap: anywhere; }
.kc-compare-result:hover, .kc-compare-result:focus-visible { background: var(--surface-2); }
.kc-compare-result small { display: block; color: var(--muted); margin-top: 5px; }
.kc-compare-heading, .kc-compare-row { display: grid; grid-template-columns: minmax(0,1fr) minmax(120px,1.1fr) minmax(0,1fr); gap: 16px; text-align: center; align-items: center; overflow-wrap: anywhere; }
.kc-compare-heading { padding: 20px 0; color: var(--accent); }
.kc-compare-row { padding: 16px 0; border-top: 1px solid var(--line); font-size: 13px; }
.kc-compare-value { font-variant-numeric: tabular-nums; }
.kc-compare-label { color: var(--muted); font-size: 12px; }
.kc-compare-label small { display: block; margin-top: 6px; color: var(--accent); }
@media (max-width: 760px) {
 .kc-compare-pickers { grid-template-columns: 1fr; }
 .kc-toolbar { width: 100%; }
 .kc-panel-head .kc-toolbar { flex: 1 1 100%; }
 .kc-grid.auto, .kc-grid.auto-lg { grid-template-columns: repeat(auto-fit,minmax(min(240px,100%),1fr)); }
 .kc-main:has(.kc-hero) { --home-gutter: 16px; }
 .kc-hero-banner { height: auto; aspect-ratio: 2048 / 675; }
 .kc-hero-actions .kc-btn { flex: 1 1 180px; justify-content: center; }
}
@media (max-width: 460px) {
 .kc-main { padding-inline: 12px; }
 .kc-header-inner { padding-inline: 12px; gap: 8px; }
 .kc-stats-filters, .kc-stats-columns { grid-template-columns: 1fr; }
 .kc-compare-row { grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: 10px; }
 .kc-compare-label { grid-column: 1 / -1; grid-row: 1; }
 .kc-compare-heading { grid-template-columns: minmax(0,1fr) 30px minmax(0,1fr); gap: 8px; }
 .kc-compare-value { font-size: 12px; }
 .kc-toolbar .kc-input, .kc-toolbar .kc-select { max-width: 100%; }
 .kc-hero-banner { height: auto; object-fit: contain; }
 .kc-compare-picker { padding: 12px; }
}
@media (pointer: coarse) { .kc-btn, .kc-chip, .kc-input, .kc-select { min-height: 44px; } }

.kc-panel-head h1 { margin: 0; }
@media (max-width: 640px) {
 .kc-main.is-flush .kc-frame-wrap { height: calc(100dvh - var(--header-h) - 110px) !important; min-height: 360px; }
 .kc-form .kc-grid.c2, .kc-form .kc-grid.c3 { grid-template-columns: 1fr; }
 .kc-kv { grid-template-columns: minmax(0, 1fr); gap: 4px; }
 .kc-inline-action { flex-wrap: wrap; max-width: 100%; }
 .kc-footer-inner { flex-wrap: wrap; }
 .kc-table-wrap { -webkit-overflow-scrolling: touch; }
}

.kc-main:has(.pb-builder) { max-width:1538px; }
/* Warpet builder: compact command bar, attributes/skills and statistics. */
.pb-builder { --pb-panel:#141619; --pb-line:#27292d; --pb-gold:#caa451; display:grid; grid-template-columns:minmax(330px, .515fr) minmax(0,1fr); grid-template-areas:"heading heading" "command command" "scan scan" "attributes summary" "skills summary" "status status"; gap:14px; max-width:1490px; margin:12px auto 0; align-items:start; }
.pb-heading { grid-area:heading; display:flex; justify-content:space-between; align-items:center; margin-bottom:0; min-height:48px; }
.pb-heading h1 { font-size:19px; font-weight:500; margin:0; }
.pb-header-actions { display:flex; gap:8px; }
.pb-builder .kc-btn { min-height:40px; font-size:12px; border-radius:8px; }
.pb-builder .pb-primary { color:#101114; background:var(--pb-gold); border-color:var(--pb-gold); font-weight:600; }
.pb-builder .pb-primary:hover { background:#dbb86a; }
.pb-share { border-color:#554625; }
.pb-command-bar { grid-area:command; display:flex; align-items:center; gap:16px; padding:12px; min-height:106px; border:1px solid var(--pb-line); border-radius:14px; background:var(--pb-panel); }
.pb-pet-picker { position:relative; flex:0 0 290px; min-width:0; }
.pb-pet-trigger { display:flex; gap:16px; align-items:center; color:var(--text); background:transparent; border:0; text-align:left; padding:0; cursor:pointer; width:100%; }
.pb-pet-portrait { display:block; width:80px; height:80px; object-fit:cover; border:2px solid #67512c; border-radius:16px; flex-shrink:0; }
.pb-pet-caption { min-width:0; }
.pb-pet-caption > strong { font-size:14px; }
.pb-pet-tags { display:flex; flex-wrap:wrap; gap:7px; margin-top:11px; }
.pb-pet-tags span { padding:3px 10px; border:1px solid #635049; background:#302323; border-radius:16px; font-size:11px; }
.pb-pet-tags span+span { background:#1e2a30; border-color:#405c67; }
.pb-picker { position:absolute; top:calc(100% + 12px); left:0; z-index:80; width:320px; max-width:calc(100vw - 48px); background:#0e1012; border:1px solid #584828; border-radius:8px; box-shadow:0 14px 40px #0009; overflow:hidden; }
.pb-picker[hidden],.pb-builder [hidden] { display:none !important; }
.pb-picker > .kc-input { border-radius:0; border:0; border-bottom:1px solid #584828; height:38px; }
.pb-picker-list { max-height:320px; overflow-y:auto; padding:6px; scrollbar-width:thin; }
.pb-picker-list h3 { font-size:12px; color:var(--text-dim); margin:7px 4px; }
.pb-picker-option { display:flex; align-items:center; gap:12px; width:100%; min-height:45px; padding:6px; background:transparent; color:var(--text); border:0; border-radius:6px; cursor:pointer; text-align:left; font:13px var(--sans); }
.pb-picker-option img { width:32px; height:32px; object-fit:cover; border-radius:50%; }
.pb-picker-option:hover,.pb-picker-option:focus-visible,.pb-picker-option[aria-pressed="true"] { background:#202328; }
.pb-picker-check { color:var(--pb-gold); margin-left:auto; }
.pb-command-controls { border-left:1px solid var(--pb-line); padding-left:16px; min-width:0; flex:1; }
.pb-command-line { display:flex; align-items:center; flex-wrap:wrap; gap:8px; }
.pb-command-line > span { color:var(--muted); font-size:12px; }
.pb-builder .kc-select,.pb-builder .kc-input { height:30px; font-size:12px; background:#141619; border-color:var(--pb-line); }
.pb-command-line .kc-select { width:auto; max-width:180px; }
.pb-command-line .kc-select:nth-child(2),.pb-command-line .kc-select:nth-child(4) { color:var(--pb-gold); border-color:#5e4c28; background:#24221c; }
.pb-builder .pb-conditions-button { min-height:29px; margin-top:8px; width:192px; justify-content:space-between; background:#141619; border-color:var(--pb-line); font-size:11px; }
.pb-calculate-actions { display:flex; flex-direction:column; gap:5px; }
.pb-calculate-actions .pb-primary { min-width:135px; }
.pb-panel { min-width:0; border:1px solid var(--pb-line); border-radius:14px; background:var(--pb-panel); overflow:hidden; }
.pb-panel-heading { display:flex; align-items:center; gap:10px; min-height:54px; padding:12px 16px; border-bottom:1px solid var(--pb-line); }
.pb-panel-heading h2 { font-size:14px; font-weight:500; letter-spacing:.025em; margin:0; }
.pb-heading-icon { display:grid; place-items:center; width:28px; height:28px; border-radius:50%; background:#29251c; color:var(--pb-gold); font-size:17px; flex-shrink:0; }
.pb-attribute-panel { grid-area:attributes; }
.pb-attributes { display:grid; gap:12px; padding:16px; }
.pb-attributes .kc-field { display:grid; grid-template-columns:132px minmax(0,1fr); align-items:center; margin:0; gap:12px; }
.pb-attributes .kc-field > label { font-size:13px; margin:0; }
.pb-attribute-label { display:flex; align-items:center; gap:12px; color:var(--muted); }
.pb-attribute-label img { width:24px; height:24px; object-fit:contain; border-radius:50%; background:#302b1f; }
.pb-attribute-control { display:flex; gap:14px; align-items:center; }
.pb-attribute-control .kc-input { width:88px; flex-shrink:0; height:25px; border-color:#5a4826; border-radius:8px; color:var(--text); text-align:right; }
.pb-attribute-control input[type="range"] { appearance:none; min-width:0; height:6px; background:linear-gradient(to right,var(--pb-gold) var(--fill),#202227 var(--fill)); border-radius:8px; margin:0; cursor:pointer; }
.pb-attribute-control input[type="range"]::-webkit-slider-thumb { appearance:none; width:16px; height:16px; border:2px solid var(--pb-gold); border-radius:50%; background:#101114; }
.pb-attribute-control input[type="range"]::-moz-range-thumb { width:12px; height:12px; border:2px solid var(--pb-gold); border-radius:50%; background:#101114; }
.pb-skill-panel { grid-area:skills; }
.pb-skills { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:18px 20px; padding:18px 16px; }
.pb-slot { display:flex; justify-content:flex-start; min-width:0; }
.pb-skill-card { position:relative; width:80px; height:80px; background:#15171b; border:2px solid #5e4d2b; border-radius:16px; padding:3px; cursor:pointer; }
.pb-skill-card.is-empty { border:2px dashed var(--pb-line); }
.pb-skill-card:hover { border-color:var(--pb-gold); }
.pb-skill-icon { display:block; width:100%; height:100%; object-fit:contain; border-radius:12px; }
.pb-empty-icon { color:#5e6269; font-size:30px; font-weight:300; }
.pb-skill-level { position:absolute; bottom:-9px; left:50%; transform:translateX(-50%); white-space:nowrap; border:1px solid #584725; border-radius:8px; background:#15171b; color:var(--pb-gold); font-size:10px; line-height:14px; padding:1px 5px; }
.pb-lock { position:absolute; top:1px; left:4px; font-size:13px; color:var(--pb-gold); }
.pb-summary { grid-area:summary; }
.pb-summary-tab { border:1px solid #554727; padding:5px 11px; border-radius:7px; color:var(--pb-gold); background:#252119; font-size:12px; }
.pb-dps { margin-left:auto; color:var(--muted); font-size:12px; white-space:nowrap; }
.pb-dps strong { color:var(--pb-gold); margin-left:5px; font-size:14px; }
.pb-results { padding:24px; min-height:248px; }
.pb-modifiers { display:flex; flex-wrap:wrap; align-items:center; gap:14px; border:1px solid var(--pb-line); border-radius:12px; padding:8px 12px; font-size:12px; color:var(--muted); margin-bottom:16px; }
.pb-modifiers strong { color:var(--pb-gold); font-size:11px; }
.pb-modifiers span:first-child strong { color:#cd7261; }
.pb-damage-box { padding:10px 12px; border:1px solid var(--pb-line); border-radius:12px; margin-bottom:16px; }
.pb-damage-heading { display:flex; justify-content:space-between; padding-bottom:10px; border-bottom:1px solid #202227; }
.pb-damage-heading h3 { margin:0; color:var(--muted); font-size:12px; font-weight:500; }
.pb-damage-heading > strong,.pb-damage-value { color:var(--pb-gold); font-size:14px; }
.pb-damage-row { display:flex; align-items:center; justify-content:space-between; gap:12px; padding:12px 0 6px; }
.pb-damage-name { display:flex; align-items:center; gap:10px; font-size:13px; }
.pb-damage-name img { width:25px; height:25px; object-fit:contain; border-radius:4px; }
.pb-breakdown { color:var(--muted); font-size:11px; margin:5px 0; }
.pb-breakdown summary { cursor:pointer; }
.pb-breakdown > div { display:flex; justify-content:space-between; gap:10px; margin:6px 0 6px 15px; }
.pb-costs { display:flex; gap:8px; align-items:center; color:var(--pb-gold); font-size:12px; margin:12px 0; }
.pb-costs img { width:20px; height:20px; object-fit:contain; }
.pb-result-note { margin:0; padding-top:14px; border-top:1px solid var(--pb-line); color:var(--muted); font-size:12px; }
.pb-status { grid-area:status; color:var(--muted); margin:0; font-size:12px; }
.pb-status:empty { display:none; }
.pb-skill-dialog { width:min(540px,calc(100vw - 32px)); padding:24px; color:var(--text); background:var(--pb-panel); border:1px solid #5e4c28; border-radius:14px; }
.pb-skill-dialog::backdrop { background:#000b; }
.pb-dialog-heading { display:flex; justify-content:space-between; align-items:center; margin-bottom:18px; }
.pb-dialog-heading h3 { margin:0; }
.pb-skill-dialog .kc-field { margin-bottom:14px; }
.pb-skill-dialog h4 { margin-top:16px; }
.pb-skill-note,.pb-note { font-size:12px; color:var(--muted); }
.pb-builder button:focus-visible { outline:2px solid var(--pb-gold); outline-offset:3px; }
@media(max-width:1150px) {
 .pb-pet-picker { flex-basis:250px; }
 .pb-command-bar { flex-wrap:wrap; }
 .pb-command-controls { min-width:300px; }
 .pb-calculate-actions { margin-left:auto; }
 .pb-attributes .kc-field { grid-template-columns:110px minmax(0,1fr); gap:8px; }
 .pb-attribute-control { gap:8px; }
 .pb-attribute-control .kc-input { width:65px; }
 .pb-skills { gap:18px 10px; }
 .pb-skill-card { width:68px; height:68px; }
}
@media(max-width:800px) {
 .pb-builder { grid-template-columns:minmax(0,1fr); grid-template-areas:"heading" "command" "scan" "attributes" "skills" "summary" "status"; }
 .pb-command-controls { border-left:0; padding-left:0; min-width:0; flex-basis:100%; }
 .pb-pet-picker { flex-basis:100%; }
 .pb-calculate-actions { margin-left:0; flex:1; }
 .pb-calculate-actions .kc-btn { width:100%; }
 .pb-heading { flex-wrap:wrap; gap:10px; }
 .pb-heading h1 { font-size:17px; }
 .pb-header-actions .kc-btn { font-size:10px; padding:0 10px; }
 .pb-skills { gap:20px 10px; }
 .pb-skill-card { width:70px; height:70px; }
 .pb-results { padding:16px; }
 .pb-panel-heading { gap:8px; padding-inline:12px; }
 .pb-panel-heading h2 { font-size:12px; }
 .pb-summary-tab { font-size:10px; padding:4px 7px; }
}

/* Imported catalogs retain full descriptions and progression data. */
.kc-import-details { margin-top:10px; color:var(--text-dim); font-size:12px; line-height:1.6; }
.kc-import-details summary { cursor:pointer; color:var(--accent); }
.kc-import-details p { margin-top:10px; white-space:pre-wrap; max-width:560px; }
.kc-import-fields { display:grid; gap:8px; margin:10px 0; overflow-wrap:anywhere; }
.kc-import-fields > div { border-left:1px solid var(--line-2); padding-left:10px; }
.kc-import-fields dt { font-weight:600; color:var(--text); }
.kc-import-fields dd { margin:4px 0 0; }

.pb-legion-controls { display:flex; gap:8px; flex-wrap:wrap; }
.pb-hero-chip { display:flex; align-items:center; gap:5px; min-width:0; border:1px solid var(--pb-line); border-radius:6px; padding-left:6px; background:var(--pb-panel); }
.pb-hero-chip img { width:23px; height:27px; object-fit:cover; border-radius:4px; }
.pb-command-line .pb-hero-chip .kc-select { max-width:145px; border:0; padding-left:3px; font-size:11px; }
.pb-secondary-controls { display:flex; align-items:center; gap:12px; flex-wrap:wrap; }
.pb-auto-control { display:flex; align-items:center; gap:6px; color:var(--text-dim); font-size:11px; padding-top:7px; cursor:pointer; }
.pb-auto-control input { accent-color:var(--pb-gold); }
.pb-buff-row { display:flex; justify-content:space-between; gap:12px; font-size:12px; padding:8px 0; border-top:1px solid var(--pb-line); }
.pb-buff-row span { color:var(--pb-gold); text-align:right; }

/* Illustrated hero selector, matching the warpet picker. */
.pb-hero-chip { position:relative; padding:0; border:0; background:none; }
.pb-hero-trigger { display:flex; align-items:center; gap:7px; min-height:34px; padding:3px 8px 3px 4px; border:1px solid #584828; border-radius:6px; background:#25231c; color:var(--pb-gold); font:12px var(--sans); cursor:pointer; }
.pb-hero-trigger > img { width:26px; height:28px; object-fit:cover; border:1px solid #766038; border-radius:5px; background:#141619; }
.pb-hero-trigger:hover,.pb-hero-trigger[aria-expanded="true"] { border-color:var(--pb-gold); background:#302b20; }
.pb-hero-trigger:focus-visible { outline:2px solid var(--pb-gold); outline-offset:3px; }
.pb-hero-chevron { margin-left:5px; color:#b2aa97; }
.pb-hero-menu { top:calc(100% + 8px); width:280px; }
.pb-hero-chip:last-child .pb-hero-menu { left:auto; right:0; }
.pb-hero-menu .pb-picker-option { gap:12px; min-height:50px; }
.pb-hero-menu .pb-picker-option img { width:38px; height:38px; border:1px solid #766038; border-radius:10px; background:radial-gradient(circle at top,#574629,#17191d); }
.pb-hero-menu .pb-picker-option[aria-pressed="true"] { background:#30291c; color:var(--pb-gold); }
.pb-hero-menu .pb-picker-option:disabled { opacity:.4; cursor:not-allowed; }
@media(max-width:600px) {
 .pb-legion-controls { position:relative; flex-basis:100%; }
 .pb-hero-chip { position:static; }
 .pb-hero-chip .pb-hero-menu,.pb-hero-chip:last-child .pb-hero-menu { left:0; right:auto; }
}

/* Consistent page polish: encyclopedia, account, stats and community views. */
.kc-panel,.kc-card { border-radius: 14px; }
.kc-panel { overflow: hidden; }
.kc-panel-head { gap: 16px; }
.kc-panel-body { min-width: 0; overflow-wrap: anywhere; }
.kc-panel-body p { line-height: 1.65; }
.kc-panel-body > *:last-child { margin-bottom: 0; }
.kc-grid > *, .kc-linkgrid > *, .kc-toolbar > * { min-width: 0; }
.kc-linkrow { transition: border-color .16s ease, background-color .16s ease, transform .16s ease; }
.kc-linkrow:hover { border-color: var(--line-2); background: var(--surface-2); transform: translateY(-1px); }
.kc-panel details { border-top: 1px solid var(--line); padding-top: 6px; }
.kc-panel details:first-child { border-top: 0; }
.kc-panel summary { cursor: pointer; }
.kc-panel summary:hover { color: var(--accent); }
.kc-panel table { max-width: 100%; }
.kc-panel img { max-width: 100%; }
.kc-about-lead { margin: 0; font-size: clamp(17px, 2.2vw, 22px); font-weight: 600; line-height: 1.4; letter-spacing: -.02em; }
.kc-input:focus-visible,.kc-select:focus-visible,.kc-btn:focus-visible,
.kc-chip:focus-visible,a:focus-visible,summary:focus-visible {
  outline: 2px solid var(--accent); outline-offset: 2px;
}
@media (max-width: 760px) {
 .kc-panel-head { flex-wrap: wrap; }
 .kc-panel-body { overflow-wrap: anywhere; }
 .kc-toolbar { flex-wrap: wrap; }
 .kc-linkrow:hover { transform: none; }
 .kc-about-lead { font-size: 18px; }
}
@media (prefers-reduced-motion: reduce) {
 .kc-linkrow { transition: none; }
 .kc-linkrow:hover { transform: none; }
}


/* Kraken 888: transparent wide artwork, fully visible on every viewport. */
.kc-main:has(.kc-hero) { background: #090b0e; }
.kc-hero {
  overflow: hidden;
  padding: clamp(10px, 2.2vw, 34px) 0 clamp(24px, 3vw, 44px);
  background: radial-gradient(ellipse 66% 78% at 50% 36%, rgba(16, 62, 93, .30), transparent 77%), #090b0e;
  border-bottom: 1px solid var(--line);
}
.kc-hero > .kc-hero-visual {
  display: block;
  width: min(100%, 2048px);
  max-width: 100%;
  margin: 0 auto clamp(18px, 2.3vw, 34px);
  padding: 0;
}
.kc-hero-visual > .kc-hero-banner {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  max-height: none;
  aspect-ratio: 2048 / 682;
  object-fit: contain;
  object-position: center center;
  border: 0;
  border-radius: 0;
  background: transparent;
  margin: 0;
  box-shadow: none;
}
.kc-hero h1 { max-width: 32ch; text-wrap: balance; }
.kc-hero-lead { max-width: 68ch; }
@media (max-width: 900px) {
  .kc-hero { padding-top: 14px; padding-bottom: 30px; }
  .kc-hero > .kc-hero-visual { margin-bottom: 22px; }
}
@media (max-width: 640px) {
  .kc-hero { padding-top: 10px; padding-bottom: 24px; }
  .kc-hero > .kc-hero-visual { width: 100%; margin-bottom: 18px; }
  .kc-hero-visual > .kc-hero-banner {
    height: auto;
    aspect-ratio: auto;
    object-fit: contain;
  }
  .kc-hero h1 { font-size: clamp(24px, 6.6vw, 32px); max-width: none; }
  .kc-hero-lead { font-size: 14px; line-height: 1.6; }
  .kc-hero-actions { gap: 8px; margin-top: 20px; }
}
@media (max-width: 420px) {
  .kc-hero { padding-top: 6px; }
  .kc-hero > .kc-hero-visual { margin-bottom: 14px; }
  .kc-hero-actions .kc-btn { flex: 1 1 100%; }
}

/* Strongest pets */
.kc-strongest-skills { margin: 8px 0; padding-left: 20px; display: grid; gap: 3px; font-size: 13px; }

/* ================================================================ adaptive
 * Сквозная доводка под ноутбуки, планшеты и телефоны. Блок стоит в конце
 * файла, чтобы перекрывать правила страниц без !important там, где можно.
 * Брейкпоинты: 1366/1280 — ноутбуки, 1024 — планшет альбомный,
 * 768 — планшет книжный, 640 — телефон, 400 — узкий телефон.
 */

/* Таблицы: минимальная ширина задаётся из dataTable через переменную. */
.kc-table { min-width: var(--kc-table-min, 0); }

/* Ноутбуки: чуть плотнее поля, чтобы широкие таблицы и сетки помещались. */
@media (min-width: 901px) and (max-width: 1366px) {
  .kc-main { padding-left: 20px; padding-right: 20px; }
}

/* Планшеты */
@media (max-width: 1024px) {
  .kc-statrow.is-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kc-grid.auto-lg { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
}
@media (max-width: 768px) {
  .kc-panel-head { flex-wrap: wrap; gap: 10px 14px; }
  .kc-panel-head > .kc-btn, .kc-panel-head > a.kc-btn { flex-shrink: 0; }
  .kc-footer-inner { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px 16px; }
}

/* Телефоны */
@media (max-width: 640px) {
  /* Подписи показателей не рвём посреди слова. */
  .kc-statrow .k, .kc-statrow .v { overflow-wrap: normal; word-break: normal; hyphens: auto; }
  .kc-statrow.is-4, .kc-statrow.is-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kc-statrow .v { font-size: 18px; }

  /* Поля фильтров: поиск — на всю строку, остальное делит ряд. */
  .kc-toolbar > input[type="search"], .kc-toolbar > .kc-input.grow, .kc-toolbar > input.kc-input:first-child { flex: 1 1 100%; }
  .kc-toolbar .kc-select { flex: 1 1 140px; min-width: 0; text-overflow: ellipsis; }

  /* Футер — две колонки вместо одной длинной ленты. */
  .kc-footer-inner { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px 14px; }
  .kc-footer h4 { margin-bottom: 9px; }
  .kc-footer li { margin-bottom: 6px; }

  /* Кнопка поддержки — круглая иконка, чтобы не закрывать контент. */
  .kc-support-launcher { width: 46px; height: 46px; padding: 0; justify-content: center; }
  .kc-support-launcher .label { display: none; }
  .kc-support-launcher .mark svg { width: 18px; height: 18px; }
  .kc-support-launcher .kc-unread { position: absolute; top: -4px; right: -4px; }

  /* Конструктор питомцев: подпись характеристики над ползунком. */
  .pb-attributes .kc-field { grid-template-columns: minmax(0, 1fr); gap: 6px; }
  .pb-attribute-control .kc-input { width: 76px; }

  /* Таблицы → карточки. Сортировка остаётся чипами над списком. */
  .kc-table-wrap.is-stack { overflow-x: hidden; }
  .kc-table-wrap.is-stack .kc-table { min-width: 0; display: block; }
  .kc-table-wrap.is-stack thead { display: none; }
  .kc-table-wrap.is-stack.has-sort thead { display: block; margin-bottom: 10px; }
  .kc-table-wrap.is-stack.has-sort thead tr { display: flex; flex-wrap: wrap; gap: 6px; }
  .kc-table-wrap.is-stack.has-sort thead th { display: block; padding: 0; border: 0; background: none; width: auto !important; }
  .kc-table-wrap.is-stack.has-sort thead th:not(.sortable) { display: none; }
  .kc-table-wrap.is-stack.has-sort thead .kc-sort-btn { min-height: 30px; padding: 0 10px; border: 1px solid var(--line-2); border-radius: 999px; background: var(--surface-2); color: var(--text-dim); font-size: 11.5px; letter-spacing: 0; text-transform: none; }
  .kc-table-wrap.is-stack.has-sort thead th[aria-sort="ascending"] .kc-sort-btn,
  .kc-table-wrap.is-stack.has-sort thead th[aria-sort="descending"] .kc-sort-btn { border-color: rgba(216,180,93,.45); color: var(--accent); background: var(--accent-bg); }
  .kc-table-wrap.is-stack tbody { display: flex; flex-direction: column; gap: 8px; }
  .kc-table-wrap.is-stack tbody tr { position: relative; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px 12px; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2); }
  .kc-table-wrap.is-stack tbody tr:hover td { background: none; }
  .kc-table-wrap.is-stack td { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; min-width: 0; padding: 0; border: 0; text-align: left !important; white-space: normal; overflow-wrap: anywhere; }
  .kc-table-wrap.is-stack td::before { content: attr(data-label); color: var(--muted-2); font: 600 9.5px var(--sans); letter-spacing: .1em; text-transform: uppercase; }
  .kc-table-wrap.is-stack td[data-label=""]::before { content: none; }
  .kc-table-wrap.is-stack td.kc-td-head { grid-column: 1 / -1; padding-right: 44px; font-size: 14px; color: var(--text); }
  .kc-table-wrap.is-stack td.kc-td-head::before { content: none; }
  .kc-table-wrap.is-stack td.kc-td-rank { position: absolute; top: 10px; right: 12px; min-width: 30px; align-items: flex-end; font: 600 13px var(--mono); color: var(--accent); }
  .kc-table-wrap.is-stack td.kc-td-rank::before { content: '#'; display: inline; font: inherit; letter-spacing: 0; color: var(--muted-2); }
  .kc-table-wrap.is-stack td.kc-td-rank { flex-direction: row; gap: 0; }
  .kc-table-wrap.is-stack td:empty { display: none; }
  /* Внутренние min-width (полоски, ячейки с картинкой) не распирают карточку. */
  .kc-table-wrap.is-stack td > * { min-width: 0 !important; max-width: 100%; }
  .kc-table-wrap.is-stack td > div { width: 100%; }
  .kc-table-wrap.is-stack .kc-petcell { min-width: 0; }
  .kc-table-wrap.is-stack details { grid-column: 1 / -1; }
  .kc-table-wrap.is-stack td:has(> details) { grid-column: 1 / -1; }
  .kc-world-table .kc-table-wrap.is-stack { max-height: none; }
}

@media (max-width: 400px) {
  .kc-main { padding-left: 12px; padding-right: 12px; }
  .kc-panel-body, .kc-panel-head { padding: 12px; }
  .kc-toolbar .kc-select { flex-basis: 100%; }
  .kc-table-wrap.is-stack tbody tr { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kc-footer-inner { gap: 18px 10px; }
}

/* ================================================= выбор навыка картинками */
.pb-skill-dialog.is-picker { width: min(720px, calc(100vw - 24px)); max-height: calc(100vh - 32px); padding: 20px; }
.kc-skillpick { display: flex; flex-direction: column; gap: 10px; margin-bottom: 14px; }
.kc-skillpick > .kc-input { height: 36px; }
.kc-skillpick-attrs { display: flex; flex-wrap: wrap; gap: 6px; }
.kc-skillpick-attrs .kc-chip { min-height: 28px; padding: 0 10px; font-size: 11.5px; }
.kc-skillpick-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(86px, 1fr)); gap: 8px; max-height: min(46vh, 420px); overflow-y: auto; padding: 2px 2px 4px; scrollbar-width: thin; }
.kc-skillpick-tile { display: flex; flex-direction: column; align-items: center; gap: 5px; padding: 8px 4px; border: 1px solid transparent; border-radius: 10px; background: #15171b; color: var(--text-dim); font: 11px/1.25 var(--sans); text-align: center; cursor: pointer; transition: border-color .15s, background .15s; }
.kc-skillpick-tile:hover:not(:disabled), .kc-skillpick-tile:focus-visible { border-color: #caa451; background: #1d1f24; color: var(--text); }
.kc-skillpick-tile.is-current { border-color: #caa451; background: rgba(202,164,81,.12); color: var(--text); }
.kc-skillpick-tile:disabled { opacity: .35; cursor: not-allowed; }
.kc-skillpick-img { position: relative; display: grid; place-items: center; width: 52px; height: 52px; border: 2px solid #5e4d2b; border-radius: 12px; background: #101114; overflow: hidden; }
.kc-skillpick-img img { width: 100%; height: 100%; object-fit: contain; }
.kc-skillpick-img b { font-size: 13px; color: var(--muted); }
.kc-skillpick-tile.is-amber .kc-skillpick-img { border-color: #d4a020; box-shadow: 0 0 8px rgba(212,160,32,.35); }
.kc-skillpick-name { overflow-wrap: normal; hyphens: auto; }
.kc-skillpick-dep { font-size: 9.5px; color: var(--muted-2); }
.kc-skillpick-info { min-height: 64px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: #101114; font-size: 12.5px; line-height: 1.5; color: var(--text-dim); }
.kc-skillpick-info p { margin: 8px 0 0; white-space: pre-line; }
.kc-skillpick-infohead { display: flex; align-items: center; gap: 10px; }
.kc-skillpick-infohead img { width: 38px; height: 38px; border-radius: 9px; border: 1px solid #5e4d2b; object-fit: contain; }
.kc-skillpick-infohead strong { color: var(--text); font-size: 13.5px; }
.kc-skillpick-tags { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 4px; }
.kc-skillpick-tags span { padding: 1px 7px; border: 1px solid var(--line-2); border-radius: 99px; font-size: 10.5px; color: var(--muted); }
.kc-skillpick-tags .is-amber { border-color: #d4a020; color: #e0b44a; }
.kc-skillpick-hint { margin: 0; color: var(--muted-2); font-size: 12px; }
.pb-skill-remove { margin-top: 10px; }
@media (max-width: 640px) {
  .pb-skill-dialog.is-picker { width: calc(100vw - 16px); padding: 14px; }
  .kc-skillpick-grid { grid-template-columns: repeat(auto-fill, minmax(72px, 1fr)); max-height: 42vh; }
  .kc-skillpick-img { width: 46px; height: 46px; }
}

/* ======================================= энциклопедия: навыки героев */
.kc-skillrow { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; margin: -2px 0 12px; }
.kc-skillbtn { display: grid; place-items: center; width: 40px; height: 40px; padding: 0; border: 1px solid var(--line-2); border-radius: 9px; background: var(--surface-2); color: var(--muted); font: 600 12px var(--sans); cursor: pointer; overflow: hidden; transition: transform .12s, border-color .15s; }
.kc-skillbtn img { width: 100%; height: 100%; object-fit: cover; }
.kc-skillbtn:hover, .kc-skillbtn:focus-visible { border-color: var(--accent); transform: translateY(-2px); }
.kc-skillbtn.is-ult { border-color: rgba(216,180,93,.6); box-shadow: 0 0 8px rgba(216,180,93,.25); }
.kc-skilltip { position: fixed; z-index: 140; width: min(360px, calc(100vw - 16px)); padding: 14px; border: 1px solid rgba(216,180,93,.4); border-radius: 12px; background: #0f1113; box-shadow: 0 18px 50px rgba(0,0,0,.6); pointer-events: none; }
.kc-skilltip[hidden] { display: none; }
.kc-skillcard-head { display: flex; align-items: center; gap: 12px; }
.kc-skillcard-head img { width: 44px; height: 44px; border-radius: 10px; border: 1px solid var(--line-2); object-fit: cover; flex-shrink: 0; }
.kc-skillcard-head strong { display: block; color: var(--text); font-size: 14px; line-height: 1.3; }
.kc-skillcard-meta { display: flex; flex-wrap: wrap; gap: 4px 10px; margin-top: 3px; font-size: 11px; color: var(--muted); }
.kc-skillcard-ult { color: var(--accent); font-weight: 600; }
.kc-skillcard-text { margin: 10px 0 0; font-size: 12.5px; line-height: 1.55; color: var(--text-dim); white-space: pre-line; }
.kc-skillcard-up { margin-top: 10px; font-size: 12px; color: var(--muted); }
.kc-skillcard-up b { color: var(--text-dim); font-weight: 600; }
.kc-skillcard-up p { margin: 4px 0 0; white-space: pre-line; line-height: 1.5; }
.kc-skill-modal { width: min(460px, calc(100vw - 24px)); max-height: calc(100vh - 32px); padding: 20px; border: 1px solid rgba(216,180,93,.4); border-radius: 14px; background: #0f1113; color: var(--text); }
.kc-skill-modal::backdrop { background: rgba(0,0,0,.65); }
.kc-skill-modal-x { float: right; width: 32px; height: 32px; margin: -6px -6px 0 8px; border: 1px solid var(--line-2); border-radius: 8px; background: var(--surface-2); color: var(--text-dim); font-size: 18px; cursor: pointer; }

/* Открытое модальное окно блокирует прокрутку страницы; место под полосу
   прокрутки зарезервировано, чтобы контент не сдвигался. */
html { scrollbar-gutter: stable; }
html:has(dialog[open]) { overflow: hidden; }
/* Окно выбора навыка не меняет размер: сетка и описание фиксированной высоты. */
.kc-skillpick-grid { height: min(46vh, 420px); max-height: none; align-content: start; }
.kc-skillpick-info { height: 132px; min-height: 0; overflow-y: auto; scrollbar-width: thin; }
@media (max-width: 640px) { .kc-skillpick-grid { height: 40vh; } .kc-skillpick-info { height: 120px; } }

/* ================================================================ calendar */
.cal-panel { overflow: visible; }
.cal-bar-top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 14px; margin: 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface-2); }
.cal-left, .cal-right, .cal-nav { display: flex; align-items: center; gap: 8px; }
.cal-clock { padding: 5px 10px; border: 1px solid var(--line-2); border-radius: 8px; font: 600 12px var(--mono); color: var(--text); }
.cal-season { padding: 4px 9px; border: 1px solid rgba(216,180,93,.5); border-radius: 7px; background: rgba(216,180,93,.1); font: 600 12px var(--mono); color: var(--accent); }
.cal-title { min-width: 190px; margin: 0; text-align: center; font: 500 20px var(--sans); letter-spacing: .08em; text-transform: uppercase; color: var(--text); }
.cal-arrow { width: 34px; height: 34px; border: 0; border-radius: 8px; background: transparent; color: var(--text-dim); font-size: 22px; cursor: pointer; }
.cal-arrow:hover { background: var(--surface-3); color: var(--text); }
.cal-klabel { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); }
.cal-kingdom { width: 76px; height: 32px; min-height: 0; text-align: center; font: 600 13px var(--mono); }
.cal-filterwrap { position: relative; }
.cal-filters { position: absolute; right: 0; top: calc(100% + 6px); z-index: 30; display: flex; flex-direction: column; gap: 4px; width: 220px; padding: 8px; border: 1px solid var(--line-2); border-radius: 10px; background: #0f1113; box-shadow: 0 14px 40px rgba(0,0,0,.6); }
.cal-filters[hidden] { display: none; }
.cal-filter { display: flex; align-items: center; gap: 8px; padding: 6px 8px; border-radius: 7px; font-size: 13px; color: var(--text-dim); cursor: pointer; }
.cal-filter:hover { background: var(--surface-2); }
.cal-filter input { accent-color: var(--accent); }

.cal-grid { margin: 0 12px 12px; overflow: hidden; border: 1px solid var(--line); border-radius: 12px; }
.cal-head { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); border-bottom: 1px solid var(--line); background: var(--surface-2); }
.cal-head span { padding: 8px; text-align: center; font: 600 10.5px var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--muted-2); }
.cal-week { position: relative; display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); row-gap: 3px; min-height: 120px; padding-bottom: 8px; border-bottom: 1px solid var(--line);
  background: linear-gradient(90deg, transparent calc(100% - 1px), var(--line) 0) 0 0 / calc(100% / 7) 100%; }
.cal-week:last-child { border-bottom: 0; }
.cal-date { grid-row: 1; display: flex; align-items: center; gap: 8px; min-height: 34px; padding: 6px 8px; }
.cal-num { font: 600 12px var(--mono); color: var(--text); }
.cal-date.is-out .cal-num { color: var(--muted-2); opacity: .5; }
.cal-date.is-today .cal-num { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: #e3c27a; color: #14100a; box-shadow: 0 0 12px rgba(227,194,122,.5); }
.cal-kvk { display: inline-flex; align-items: center; gap: 6px; padding: 0; border: 0; background: none; color: #ff4d6d; font: 700 10.5px var(--sans); letter-spacing: .08em; text-transform: uppercase; cursor: pointer; }
.cal-kvk::before { content: '!'; display: grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; background: #ff2d55; color: #fff; font-size: 11px; }

.cal-bar { display: flex; align-items: center; gap: 6px; min-width: 0; height: 24px; margin: 0 2px; padding: 0 8px; border: 1px solid rgba(255,255,255,.12); border-radius: 5px; background: #23262b; color: #c8ccd0; font: 500 11.5px var(--sans); text-align: left; white-space: nowrap; overflow: hidden; cursor: pointer; transition: filter .12s; }
.cal-bar span:last-child { overflow: hidden; text-overflow: ellipsis; }
.cal-bar:hover { filter: brightness(1.25); }
.cal-bar.cont-l { border-top-left-radius: 0; border-bottom-left-radius: 0; margin-left: 0; }
.cal-bar.cont-r { border-top-right-radius: 0; border-bottom-right-radius: 0; margin-right: 0; }
.cal-bar.is-now { box-shadow: 0 0 0 1px rgba(255,255,255,.35) inset; }
.cal-ico { display: inline-flex; flex-shrink: 0; opacity: .8; }
.cal-bar.c-red { background: #4a1d20; border-color: #7a2b2f; color: #f1c6c4; }
.cal-bar.c-purple { background: #34204d; border-color: #5a3a86; color: #dccbf3; }
.cal-bar.c-amber { background: #4a2f15; border-color: #7d5124; color: #f0d2a8; }
.cal-bar.c-sky { background: #16343f; border-color: #275b6c; color: #c4e3ee; }
.cal-bar.c-yellow { background: #3d3613; border-color: #6c5f1f; color: #ece0a6; }
.cal-bar.is-stage { background: #1e2125; border-color: #3a3e44; color: #c9cdd2; }
.cal-bar.is-pass { background: #1d2740; border-color: #34477a; color: #c7d3f1; }
.cal-bar.is-statue { background: #3a2a1c; border-color: #6a4b2e; color: #ebd0b3; }
.cal-bar.is-behemoth { background: #1a3322; border-color: #2f5d3b; color: #c3e8cd; }

.cal-agenda { display: none; flex-direction: column; gap: 10px; margin: 0 12px 12px; }
.cal-aday { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 10px; padding: 10px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface-2); }
.cal-aday.is-today { border-color: rgba(227,194,122,.6); }
.cal-adate { display: flex; flex-direction: column; align-items: center; }
.cal-adate b { font: 600 18px var(--mono); color: var(--text); }
.cal-adate span { font-size: 11px; color: var(--muted-2); }
.cal-aday.is-today .cal-adate b { color: #e3c27a; }
.cal-alist { display: flex; flex-direction: column; gap: 4px; }
.cal-alist .cal-bar { margin: 0; height: auto; min-height: 28px; white-space: normal; }
.cal-alist .cal-bar span:last-child { overflow: visible; }

.cal-modal { width: min(440px, calc(100vw - 24px)); padding: 0; border: 1px solid rgba(216,180,93,.4); border-radius: 14px; background: #0f1113; color: var(--text); }
.cal-modal::backdrop { background: rgba(0,0,0,.65); }
.cal-modal .lp-modal-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.cal-modal .lp-modal-head h3 { display: flex; align-items: center; gap: 6px; margin: 0; font-size: 16px; }
.cal-modal .lp-modal-x { width: 30px; height: 30px; border: 1px solid var(--line-2); border-radius: 8px; background: var(--surface-2); color: var(--text-dim); font-size: 17px; cursor: pointer; }
.cal-modal .lp-modal-body { padding: 14px 18px 18px; }
.cal-modal .lp-ok { color: var(--success); font-weight: 600; margin: 10px 0 0; }
.cal-dl { display: grid; grid-template-columns: 90px minmax(0, 1fr); gap: 8px 12px; margin: 0; font-size: 13px; }
.cal-dl dt { color: var(--muted-2); }
.cal-dl dd { margin: 0; color: var(--text); }

@media (max-width: 900px) {
  .cal-title { min-width: 0; font-size: 16px; }
  .cal-bar-top { justify-content: center; }
}
@media (max-width: 640px) {
  .cal-grid { display: none; }
  .cal-agenda { display: flex; }
  .cal-right { flex-wrap: wrap; justify-content: center; }
}

/* ====================================== аккаунты: витрина, продажа, сделки */
.kc-lordbadges { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); }
.kc-lordline { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; font-size: 12.5px; }
.kc-lordline b { color: #e3c27a; font-weight: 500; }
.kc-lordcap { min-width: 92px; font: 600 9.5px var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--muted-2); }
.kc-decos { display: inline-flex; flex-wrap: wrap; gap: 6px; }
.kc-deco { position: relative; display: inline-block; width: 34px; height: 34px; }
.kc-deco img { width: 100%; height: 100%; border-radius: 7px; border: 1px solid rgba(227,194,122,.45); object-fit: cover; }
.kc-deco i { position: absolute; right: -4px; bottom: -4px; min-width: 15px; padding: 0 3px; border-radius: 99px; background: #0c0d0e; border: 1px solid var(--line-2); font: 700 9px/13px var(--mono); font-style: normal; text-align: center; color: var(--text); }

.kc-flexstatus { margin: 4px 0 6px; padding: 8px 10px; border: 1px solid var(--line-2); border-radius: 8px; font-size: 12.5px; }
.kc-flexstatus.is-approved { border-color: rgba(121,199,155,.45); color: var(--success); background: rgba(121,199,155,.07); }
.kc-flexstatus.is-pending { border-color: rgba(216,180,93,.45); color: var(--accent); background: var(--accent-bg); }
.kc-flexstatus.is-rejected { border-color: rgba(224,138,128,.45); color: var(--danger); background: rgba(224,138,128,.07); }

.mk-card { display: flex; flex-direction: column; gap: 10px; }
.mk-top { display: flex; align-items: center; gap: 12px; }
.mk-who { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.mk-who b { color: var(--text); overflow-wrap: anywhere; }
.mk-price { flex-shrink: 0; padding: 6px 12px; border: 1px solid rgba(216,180,93,.5); border-radius: 10px; background: var(--accent-bg); font: 700 16px var(--mono); color: var(--accent); white-space: nowrap; }
.mk-price.is-big { display: inline-block; margin-bottom: 8px; font-size: 22px; }
.mk-title { margin: 2px 0 0; font-size: 15.5px; line-height: 1.35; color: var(--text); }
.mk-counts { margin: 0; }
.mk-desc { margin: 0; font-size: 13px; line-height: 1.55; color: var(--text-dim); white-space: pre-wrap; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.mk-desc.is-full { display: block; -webkit-line-clamp: unset; overflow: visible; }
.mk-actions { margin-top: auto; padding-top: 6px; }
.mk-note:empty { display: none; }
.mk-modal { width: min(560px, calc(100vw - 24px)); max-height: calc(100vh - 32px); padding: 0; border: 1px solid rgba(216,180,93,.4); border-radius: 14px; background: #0f1113; color: var(--text); }
.mk-modal::backdrop { background: rgba(0,0,0,.65); }
.mk-modal-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.mk-modal-head h3 { margin: 0; font-size: 17px; }
.mk-x { width: 30px; height: 30px; border: 1px solid var(--line-2); border-radius: 8px; background: var(--surface-2); color: var(--text-dim); font-size: 17px; cursor: pointer; }
.mk-modal-body { display: flex; flex-direction: column; gap: 10px; padding: 16px 18px 20px; }
.mk-priceinput { font: 600 16px var(--mono); }
.mk-info { min-height: 18px; margin-top: 10px; font-size: 13px; }
.mk-info.is-ok { color: var(--success); }
.mk-info.is-err { color: var(--danger); }

.dl-layout { display: grid; grid-template-columns: 300px minmax(0, 1fr); min-height: 520px; border-top: 1px solid var(--line); }
.dl-list { display: flex; flex-direction: column; gap: 4px; max-height: 70vh; padding: 10px; overflow-y: auto; border-right: 1px solid var(--line); }
.dl-item { display: flex; flex-direction: column; gap: 4px; padding: 10px 12px; border: 1px solid transparent; border-radius: 10px; background: none; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.dl-item:hover { background: var(--surface-2); }
.dl-item.is-active { border-color: rgba(216,180,93,.45); background: var(--accent-bg); }
.dl-item-top { display: flex; justify-content: space-between; gap: 8px; }
.dl-item-top b { font-size: 13px; color: var(--text); overflow-wrap: anywhere; }
.dl-item-meta { display: flex; justify-content: space-between; gap: 8px; font-size: 11.5px; color: var(--muted); }
.dl-item-last { font-size: 12px; color: var(--muted-2); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.dl-unread { min-width: 18px; height: 18px; padding: 0 5px; border-radius: 99px; background: var(--accent); color: var(--accent-ink); font: 700 10px/18px var(--sans); text-align: center; }
.dl-chat { display: flex; flex-direction: column; min-width: 0; }
.dl-head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; padding: 14px 16px; border-bottom: 1px solid var(--line); }
.dl-head b { color: var(--text); font-size: 15px; }
.dl-head-r { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.dl-log { display: flex; flex-direction: column; gap: 10px; flex: 1; min-height: 280px; max-height: 56vh; padding: 16px; overflow-y: auto; }
.dl-msg { display: flex; flex-direction: column; gap: 3px; max-width: 78%; padding: 9px 12px; border-radius: 12px; font-size: 13.5px; line-height: 1.5; }
.dl-msg-body { white-space: pre-wrap; overflow-wrap: anywhere; }
.dl-msg.from-buyer { align-self: flex-end; background: rgba(216,180,93,.14); border: 1px solid rgba(216,180,93,.3); border-bottom-right-radius: 4px; }
.dl-msg.from-admin { align-self: flex-start; background: var(--surface-3); border: 1px solid var(--line-2); border-bottom-left-radius: 4px; }
.dl-msg.from-system { align-self: center; max-width: 92%; background: none; border: 1px dashed var(--line-2); color: var(--muted); font-size: 12.5px; text-align: center; }
.dl-msg-who { font: 600 10.5px var(--sans); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.dl-msg-time { align-self: flex-end; font-size: 10.5px; color: var(--muted-2); }
.dl-compose { display: flex; flex-direction: column; gap: 8px; padding: 12px 16px; border-top: 1px solid var(--line); }
.dl-compose-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.dl-warn { margin: 0; padding: 0 16px 14px; }
.dl-empty { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; min-height: 200px; padding: 20px; color: var(--muted); text-align: center; }
@media (max-width: 760px) {
  .dl-layout { grid-template-columns: minmax(0, 1fr); }
  .dl-list { max-height: 220px; border-right: 0; border-bottom: 1px solid var(--line); }
  .dl-msg { max-width: 92%; }
  .mk-top { flex-wrap: wrap; }
}

/* =========================================================== серверы */
.sv-card { display: flex; flex-direction: column; gap: 12px; }
.sv-head { display: flex; align-items: center; gap: 12px; }
.sv-num { display: grid; place-items: center; width: 44px; height: 44px; flex-shrink: 0; border: 1px solid rgba(216,180,93,.4); border-radius: 11px; background: var(--accent-bg); font: 600 16px var(--mono); color: var(--accent); }
.sv-title { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.sv-title b { font-size: 15.5px; font-weight: 600; color: var(--text); }
.sv-title small { font-size: 11.5px; color: var(--muted-2); }
.sv-stats { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
.sv-stats > div { background: var(--surface); }
.sv-leaders { display: flex; flex-direction: column; gap: 6px; margin: 0; padding-top: 2px; }
.sv-leaders > div { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; font-size: 12.5px; }
.sv-leaders dt { color: var(--muted-2); }
.sv-leaders dd { margin: 0; min-width: 0; color: var(--text); font-weight: 500; text-align: right; overflow-wrap: anywhere; }
.sv-leaders dd.is-gold { color: var(--accent); }
.sv-actions { margin-top: auto; padding-top: 10px; border-top: 1px solid var(--line); }

/* --- питомец по скриншоту (pet-scan.js): профиль и конструктор */
.kc-scan { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.kc-scan-status { padding: 9px 12px; border-radius: 9px; border: 1px solid var(--line-2); background: var(--surface-2); font-size: 12.5px; color: var(--text-dim); display: grid; gap: 3px; }
.kc-scan-status:empty { display: none; }
.kc-scan-status.is-busy { color: var(--muted); grid-template-columns: auto 1fr; align-items: center; column-gap: 8px; }
.kc-scan-status.is-busy::before { content: ''; width: 12px; height: 12px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: kc-scan-spin .8s linear infinite; }
.kc-scan-status.is-done { border-color: rgba(121,199,155,.4); background: rgba(121,199,155,.07); }
.kc-scan-status.is-done > div:first-child { color: var(--success); font-weight: 600; }
.kc-scan-status.is-error { border-color: rgba(224,138,128,.4); background: rgba(224,138,128,.08); color: var(--danger); }
.pb-skill-card.is-unsure { outline: 2px solid #e8b84a; outline-offset: 2px; }
.pb-scan-bar { grid-area: scan; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; padding: 10px 12px; border: 1px solid var(--pb-line); border-radius: 12px; background: var(--pb-panel); }
.pb-scan-bar .kc-scan-status { flex: 1 1 320px; }
.pb-scan-hint { color: var(--muted-2); font-size: 12px; }
@keyframes kc-scan-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .kc-scan-status.is-busy::before { animation: none; } }

/* --- уровень навыка питомца: 0–3 звезды, как в игре */
.kc-stars { display: inline-flex; align-items: center; gap: 2px; }
.kc-star { background: none; border: 0; padding: 0 2px; font-size: 20px; line-height: 1; color: var(--pb-gold, #caa451); cursor: pointer; opacity: .5; transition: transform .12s ease, opacity .12s ease; }
.kc-star.is-on { opacity: 1; text-shadow: 0 0 6px rgba(227,194,122,.35); }
.kc-star:hover:not(:disabled) { transform: scale(1.15); opacity: 1; }
.kc-star:focus-visible { outline: 2px solid var(--pb-gold, #caa451); outline-offset: 1px; border-radius: 4px; }
.kc-stars.is-locked .kc-star { cursor: default; }
.pb-skill-wrap { position: relative; display: inline-flex; }
.pb-card-stars { position: absolute; bottom: -10px; left: 50%; transform: translateX(-50%); border: 1px solid #584725; border-radius: 8px; background: #15171b; padding: 0 3px; gap: 0; white-space: nowrap; }
.pb-card-stars .kc-star { font-size: 13px; padding: 1px 2px; }
@media (prefers-reduced-motion: reduce) { .kc-star { transition: none; } }

/* --- скрытый раздел «Патчи сайта» */
.pt-intro { margin-bottom: 14px; }
.pt-toggle { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; color: var(--text-dim); cursor: pointer; }
.pt-days { display: grid; gap: 12px; }
.pt-day-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 6px 12px; }
.pt-day-head h2 { margin: 0; font-size: 18px; }
.pt-day-meta { color: var(--muted); font-size: 12.5px; }
.pt-items { list-style: none; margin: 0; padding: 4px 16px 14px; display: grid; gap: 6px; }
.pt-item { display: grid; grid-template-columns: 112px 1fr auto; align-items: baseline; gap: 10px; padding: 6px 0; border-bottom: 1px solid var(--line-2); font-size: 14px; }
.pt-item:last-child { border-bottom: 0; }
.pt-kind { font-size: 11.5px; text-transform: uppercase; letter-spacing: .04em; font-weight: 700; }
.pt-item.is-feature .pt-kind { color: var(--success); }
.pt-item.is-fix .pt-kind { color: #e8b84a; }
.pt-item.is-tech .pt-kind, .pt-item.is-minor .pt-kind { color: var(--muted); }
.pt-item.is-minor .pt-title { color: var(--muted); }
.pt-count { color: var(--muted); font-size: 12px; }
.pt-hash { color: var(--muted-2); font-size: 11.5px; }
@media (max-width: 640px) {
  .pt-item { grid-template-columns: 1fr auto; }
  .pt-kind { grid-column: 1 / -1; }
}

/* ---------- мировая таблица: карточка игрока (player-cards.js) ---------- */
.kc-ws { margin-top: 18px; padding: 16px; border: 1px solid var(--line-2); border-radius: var(--radius);
  background: radial-gradient(120% 90% at 0% 0%, rgba(216,180,93,.10), transparent 55%), var(--surface-2); }
.kc-ws.is-compact { padding: 14px; margin-top: 14px; }
.kc-ws-loading { color: var(--muted); font-size: 13px; }
.kc-ws-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px 18px; flex-wrap: wrap; }
.kc-ws-who { min-width: 0; }
.kc-ws-eyebrow { color: var(--accent); font: 800 10.5px var(--sans); letter-spacing: .12em; text-transform: uppercase; }
.kc-ws-name { margin-top: 4px; color: var(--text); font-size: 20px; font-weight: 800; line-height: 1.2; overflow-wrap: anywhere; }
.kc-ws.is-compact .kc-ws-name { font-size: 16px; }
.kc-ws-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.kc-ws-chip { padding: 3px 9px; border: 1px solid var(--line-2); border-radius: 999px; background: var(--surface-3); color: var(--text-dim); font-size: 11.5px; font-weight: 600; }
.kc-ws-chip.is-rank { color: var(--text); }
.kc-ws-chip.is-top { border-color: rgba(216,180,93,.55); background: var(--accent-bg); color: var(--accent); }
.kc-ws-side { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; }
.kc-ws-updated { color: var(--muted-2); font-size: 11px; }
.kc-ws-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; margin-top: 14px; }
.kc-ws-tile { position: relative; padding: 12px 12px 11px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); overflow: hidden; }
.kc-ws-tile::before { content: ''; position: absolute; inset: 0 0 auto 0; height: 2px; background: var(--line-3); }
.kc-ws-tile.is-gold::before { background: var(--accent); }
.kc-ws-tile.is-teal::before { background: var(--info); }
.kc-ws-tile.is-red::before { background: var(--danger); }
.kc-ws-k { color: var(--muted); font: 700 10.5px var(--sans); letter-spacing: .06em; text-transform: uppercase; }
.kc-ws-v { margin-top: 5px; color: var(--text); font-size: 20px; font-weight: 800; font-variant-numeric: tabular-nums; line-height: 1.15; }
.kc-ws-sub { margin-top: 3px; color: var(--muted-2); font-size: 11px; }
.kc-ws.is-compact .kc-ws-v { font-size: 17px; }
@media (max-width: 640px) {
  .kc-ws-side { align-items: flex-start; }
  .kc-ws-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ---------- достижения: медали и карточки (player-cards.js) ---------- */
.kc-medal { --m1: #5d6466; --m2: #3a3f41; position: relative; display: inline-grid; place-items: center; flex-shrink: 0; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, var(--m1), var(--m2)); box-shadow: inset 0 0 0 1.5px rgba(255,255,255,.22), 0 1px 2px rgba(0,0,0,.5); }
.kc-medal-core { width: 42%; height: 42%; border-radius: 50%; background: rgba(255,255,255,.28); box-shadow: inset 0 1px 1px rgba(0,0,0,.25); }
.kc-medal.is-bronze { --m1: #e3a36f; --m2: #8a5531; }
.kc-medal.is-silver { --m1: #eef2f4; --m2: #8c979d; }
.kc-medal.is-gold { --m1: #ffe08a; --m2: #b0832c; }
.kc-medal.is-diamond { --m1: #c9f3ff; --m2: #3f9cc0; }
.kc-medal.is-off { filter: grayscale(1) brightness(.55); opacity: .55; }
.kc-medal-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 8px; }
.kc-medal-stat { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); }
.kc-medal-stat b { display: block; color: var(--text); font-size: 17px; font-variant-numeric: tabular-nums; line-height: 1.1; }
.kc-medal-stat span { display: block; color: var(--muted); font-size: 11px; margin-top: 2px; }
.kc-medal-stat.is-empty b { color: var(--muted); }
.kc-medal-stat.is-total { border-color: rgba(216,180,93,.35); background: var(--accent-bg); }
.kc-medal-stat.is-total b { color: var(--accent); }
.kc-ach-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 10px; margin-top: 12px; }
.kc-ach-card { display: flex; flex-direction: column; gap: 8px; padding: 12px 13px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); }
.kc-ach-card.is-complete { border-color: rgba(216,180,93,.35); background: linear-gradient(180deg, rgba(216,180,93,.07), transparent 70%), var(--surface); }
.kc-ach-card.is-complete.is-diamond { border-color: rgba(143,211,232,.45); background: linear-gradient(180deg, rgba(143,211,232,.09), transparent 70%), var(--surface); }
.kc-ach-card-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.kc-ach-card-name { min-width: 0; color: var(--text); font-weight: 800; font-size: 13.5px; line-height: 1.3; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kc-ach-ladder { display: flex; gap: 4px; flex-shrink: 0; }
.kc-ach-card-desc { margin: 0; color: var(--text-dim); font-size: 12px; line-height: 1.45; }
.kc-ach-card-foot { display: flex; align-items: center; gap: 10px; margin-top: auto; }
.kc-ach-card-foot.is-done { justify-content: space-between; color: var(--success); font-size: 12px; font-weight: 700; }
.kc-ach-card-date { color: var(--muted-2); font-weight: 500; font-size: 11px; }
.kc-ach-card-bar { flex: 1 1 auto; height: 6px; border-radius: 3px; }
.kc-ach-card-bar > span { background: linear-gradient(90deg, var(--accent-dim), var(--accent)); border-radius: 3px; }
.kc-ach-card-num { color: var(--text-dim); font: 700 11.5px var(--sans); font-variant-numeric: tabular-nums; white-space: nowrap; }
.kc-ach-more { margin-top: 12px; text-align: center; }
.kc-ach-unknown { margin-top: 14px; color: var(--muted); font-size: 12.5px; }
.kc-ach-unknown summary { cursor: pointer; }
.kc-ach-unknown-list { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }

/* ---------- фильтр мировой таблицы (stats-world-filters.js) ---------- */
.kc-wf { display: flex; flex-direction: column; gap: 12px; margin-top: 4px; }
.kc-wf-bar { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px; padding: 12px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface-2); }
.kc-wf-box { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.kc-wf-box.is-search { flex: 3 1 260px; }
.kc-wf-box.is-server { flex: 0 1 110px; }
.kc-wf-box.is-alliance { flex: 2 1 200px; }
.kc-wf-box .kc-input { width: 100%; }
.kc-wf-box.is-search .kc-input { padding-left: 34px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' stroke='%23959f9f' stroke-width='2' stroke-linecap='round' viewBox='0 0 24 24'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m20 20-3.5-3.5'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: 11px 50%; }
.kc-wf-cap { color: var(--muted); font: 700 10.5px var(--sans); letter-spacing: .08em; text-transform: uppercase; }
.kc-wf-presets { display: flex; flex-wrap: wrap; gap: 6px; }
.kc-wf-presets:empty { display: none; }
.kc-wf-active { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.kc-wf-pill { display: inline-flex; align-items: stretch; border: 1px solid rgba(216,180,93,.45); border-radius: 999px; background: var(--accent-bg); overflow: hidden; }
.kc-wf-pill-main { display: inline-flex; align-items: baseline; gap: 6px; padding: 6px 4px 6px 12px; border: 0; background: none; color: var(--text-dim); font: 600 12px var(--sans); cursor: pointer; }
.kc-wf-pill-main b { color: var(--accent); font-variant-numeric: tabular-nums; }
.kc-wf-pill-x { padding: 0 11px 0 7px; border: 0; background: none; color: var(--muted); font-size: 16px; line-height: 1; cursor: pointer; }
.kc-wf-pill-x:hover, .kc-wf-pill-main:hover { color: var(--text); }
.kc-wf-add { padding: 6px 13px; border: 1px dashed var(--line-3); border-radius: 999px; background: none; color: var(--text-dim); font: 600 12px var(--sans); cursor: pointer; }
.kc-wf-add:hover { border-color: var(--accent); color: var(--accent); }
.kc-wf-editor { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; width: 100%; padding: 10px; border: 1px solid var(--line-2); border-radius: var(--radius-sm); background: var(--surface-2); }
.kc-wf-editor[hidden] { display: none; }
.kc-wf-editor .kc-select { flex: 2 1 220px; }
.kc-wf-editor .kc-input { flex: 1 1 110px; min-width: 0; }
.kc-wf-dash { color: var(--muted-2); }
.kc-wf-hint { flex-basis: 100%; color: var(--danger); font-size: 12px; }
.kc-wf-hint:empty { display: none; }
.kc-wf-colbox { margin-top: 12px; }
.kc-wf-columns { display: flex; flex-direction: column; gap: 12px; padding: 12px 0 4px; }
.kc-wf-colgroup .kc-wf-cap { display: block; margin-bottom: 6px; }
@media (max-width: 640px) {
  .kc-wf-box.is-search, .kc-wf-box.is-alliance { flex-basis: 100%; }
  .kc-wf-box.is-server { flex: 1 1 90px; }
}

/* War pet calculator (cod-tracker style): three columns, power, fruits, contribution. */
.pb-builder { grid-template-columns:minmax(330px,.95fr) minmax(360px,1fr) minmax(380px,1.1fr); grid-template-areas:"heading heading heading" "command command command" "scan scan scan" "left mid right" "status status status"; }
.pb-col { display:grid; gap:14px; min-width:0; align-content:start; }
.pb-col-left { grid-area:left; } .pb-col-mid { grid-area:mid; } .pb-col-right { grid-area:right; }
.pb-subtitle { margin:4px 0 0; color:var(--muted); font-size:12px; }
.pb-super { display:flex; align-items:center; gap:6px; margin-left:auto; font-size:11px; color:var(--muted); cursor:pointer; white-space:nowrap; }
.pb-super input { accent-color:var(--pb-gold); }
.pb-builder .pb-max { min-height:28px; padding:0 10px; font-size:11px; }
.pb-cap { color:var(--muted); font-size:11px; min-width:32px; }
.pb-attr-note { margin:0; padding:0 16px 14px; }
.pb-power { padding:14px 16px; display:grid; gap:12px; }
.pb-power-value { font-size:30px; color:var(--pb-gold); font-weight:600; letter-spacing:.01em; }
.pb-power-controls { display:grid; grid-template-columns:1fr 1fr; gap:10px; }
.pb-power-controls .kc-field { margin:0; }
.pb-power-controls label { font-size:11px; color:var(--muted); }
.pb-power-rows { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:8px; }
.pb-power-rows > div { border:1px solid var(--pb-line); border-radius:10px; padding:8px 10px; display:grid; gap:3px; }
.pb-power-rows span { color:var(--muted); font-size:11px; }
.pb-power-rows strong { font-size:14px; }
.pb-power .pb-note { margin:0; }
.pb-contrib-row { display:grid; grid-template-columns:minmax(0,1fr) auto; gap:4px 12px; padding:10px 0 4px; }
.pb-contrib-row small { display:block; color:var(--muted); font-size:10px; }
.pb-contrib-value { text-align:right; } .pb-contrib-value strong { color:var(--pb-gold); font-size:13px; }
.pb-contrib-bar { grid-column:1 / -1; height:4px; border-radius:4px; background:#202227; overflow:hidden; }
.pb-contrib-bar span { display:block; height:100%; background:var(--pb-gold); border-radius:4px; }
.pb-contrib .pb-note { margin:10px 0 0; }
.pb-fruits { padding:14px 16px; display:grid; gap:12px; }
.pb-fruit-rules { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:8px; }
.pb-fruit-step { border:1px solid var(--pb-line); border-radius:10px; padding:8px; display:grid; gap:2px; font-size:11px; }
.pb-fruit-step strong { font-size:12px; } .pb-fruit-step span { color:var(--text-dim); } .pb-fruit-step small { color:var(--pb-gold); font-size:10px; }
.pb-fruit-dots { display:flex; gap:3px; margin-bottom:3px; }
.pb-fruit-dot { display:inline-block; width:10px; height:10px; border-radius:50%; flex-shrink:0; box-shadow:inset 0 -2px 0 #0004; }
.pb-fruit-dot.is-super { background:conic-gradient(#e0745f,#d9a441,#62c48c,#5fb6d9,#8c7ad9,#e0745f); }
.pb-fruit-table { display:grid; gap:6px; }
.pb-fruit-head,.pb-fruit-row { display:grid; grid-template-columns:minmax(110px,1fr) 70px 58px minmax(0,1.6fr); gap:8px; align-items:center; }
.pb-fruit-head { color:var(--muted); font-size:11px; }
.pb-fruit-row .kc-input { height:26px; text-align:right; }
.pb-fruit-row .pb-attribute-label { font-size:12px; gap:8px; } .pb-fruit-row .pb-attribute-label img { width:20px; height:20px; }
.pb-fruit-to { color:var(--muted); font-size:12px; }
.pb-fruit-need { display:flex; flex-wrap:wrap; gap:4px; }
.pb-fruit-chip { display:inline-flex; align-items:center; gap:5px; border:1px solid var(--pb-line); border-radius:999px; padding:2px 8px; font-size:11px; }
.pb-fruit-chip b { color:var(--pb-gold); }
.pb-fruit-ok { color:#7fbf8a; font-size:11px; }
.pb-fruit-total { display:flex; flex-wrap:wrap; gap:6px; align-items:center; padding-top:10px; border-top:1px solid var(--pb-line); }
.pb-fruit-total-label { color:var(--muted); font-size:12px; margin-right:4px; }
.pb-fruit-warning { margin:0; color:#d9a441; } .pb-fruit-warning:empty { display:none; }
.pb-fruits .pb-note { margin:0; }
@media(max-width:1300px) {
 .pb-builder { grid-template-columns:minmax(330px,.9fr) minmax(0,1fr); grid-template-areas:"heading heading" "command command" "scan scan" "left right" "mid right" "status status"; }
}
@media(max-width:800px) {
 .pb-builder { grid-template-columns:minmax(0,1fr); grid-template-areas:"heading" "command" "scan" "left" "mid" "right" "status"; }
 .pb-fruit-rules { grid-template-columns:repeat(2,minmax(0,1fr)); }
 .pb-fruit-head,.pb-fruit-row { grid-template-columns:minmax(90px,1fr) 62px 50px; }
 .pb-fruit-head span:last-child { display:none; }
 .pb-fruit-need { grid-column:1 / -1; }
 .pb-power-rows { grid-template-columns:1fr; }
}
.pb-col > .pb-panel { grid-area:auto; }
.pb-attribute-panel .pb-panel-heading { flex-wrap:wrap; }
.pb-panel-heading h2 { white-space:nowrap; }
.pb-fruit-rules { grid-template-columns:repeat(2,minmax(0,1fr)); }
.pb-power-controls .kc-select { width:100%; }

/* ===== Справочник и инструменты (перенос с cod-tracker) ===== */
.hb-page,.tal-page,.tr-page,.tl-page,.dc-page,.kvk-page,.sx-page,.row-page,.sr-page { max-width:1400px; margin:12px auto 0; }
.hb-page h1,.tal-page h1,.tr-page h1,.tl-page h1,.dc-page h1,.kvk-page h1,.sx-page h1,.row-page h1,.sr-page h1 { font-size:22px; margin:0 0 6px; }
.hb-toolbar,.tal-toolbar,.tl-toolbar { display:flex; flex-wrap:wrap; gap:8px; align-items:center; margin-bottom:12px; }
.hb-search { flex:1; min-width:220px; }
.hb-count { color:var(--muted); font-size:12px; margin-left:8px; font-weight:400; }
.hb-label { color:var(--muted); font-size:12px; display:block; margin:10px 0 4px; }
.hb-chips { display:flex; flex-wrap:wrap; gap:6px; }
.hb-chip { border:1px solid var(--line); background:transparent; color:var(--text); padding:6px 11px; border-radius:999px; cursor:pointer; font-size:12px; }
.hb-chip:hover { border-color:var(--accent,#caa451); }
.hb-chip.is-active { background:#2a2519; border-color:#caa451; color:#caa451; }
.hb-qa-list { display:grid; gap:6px; }
.hb-qa { display:grid; grid-template-columns:42px 1fr; gap:10px; padding:10px 12px; border:1px solid var(--line); border-radius:10px; }
.hb-qa-n { color:var(--muted); font-size:12px; text-align:right; padding-top:2px; }
.hb-qa-q { font-size:14px; }
.hb-qa-a { color:#7fbf8a; font-weight:600; margin-top:4px; font-size:14px; }
.hb-qa mark { background:#5a4a1a; color:inherit; border-radius:3px; padding:0 2px; }
.hb-mob-controls { margin-bottom:10px; }
.hb-mob-cat { margin-top:18px; }
.hb-mob-cat h3 { font-size:15px; margin:0 0 8px; }
.hb-mob-grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(230px,1fr)); gap:8px; }
.hb-task { display:grid; gap:6px; text-align:left; padding:10px 12px; border:1px solid var(--line); border-left:4px solid var(--c,#888); border-radius:10px; background:transparent; color:var(--text); font:inherit; }
button.hb-task { cursor:pointer; }
.hb-task.is-orange { --c:#f0883e; } .hb-task.is-purple { --c:#b083f0; } .hb-task.is-blue { --c:#539bf5; }
.hb-task.is-picked { background:#1d2a1f; border-color:#57ab5a; }
.hb-task-top { display:flex; justify-content:space-between; font-size:11px; } .hb-rarity { color:var(--c); font-weight:600; text-transform:uppercase; } .hb-task-top b { color:#caa451; }
.hb-task-text { font-size:13px; } .hb-task-time { display:flex; justify-content:space-between; color:var(--muted); font-size:12px; }
.hb-check { color:#57ab5a; font-weight:700; }
.hb-mob-total { display:flex; flex-wrap:wrap; gap:14px; align-items:center; padding:10px 12px; border:1px solid #3d5a3f; border-radius:10px; background:#162019; }
.hb-mob-total b { color:#caa451; }
/* таланты */
.tal-status { color:#e5534b; font-size:13px; min-height:18px; margin:0 0 8px; }
.tal-points { color:#caa451; font-size:16px; }
.tal-core { border:1px dashed #caa451; background:transparent; color:#caa451; border-radius:10px; padding:7px 12px; cursor:pointer; }
.tal-core.is-on { background:#2a2519; border-style:solid; }
.tal-layout { display:grid; grid-template-columns:minmax(0,1fr) 300px; gap:16px; align-items:start; }
.tal-trees { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:10px; }
.tal-tree { border:1px solid var(--line); border-radius:12px; padding:10px; min-width:0; }
.tal-tree.is-foundation { border-color:#4a4127; }
.tal-tree h3 { display:flex; justify-content:space-between; font-size:13px; margin:0 0 8px; } .tal-tree h3 span { color:#caa451; }
.tal-row { display:flex; gap:6px; margin-bottom:6px; }
.tal-node { flex:1; min-width:0; display:grid; gap:2px; padding:6px; border:1px solid var(--line); border-radius:8px; background:#15171b; color:var(--text); cursor:pointer; font:inherit; text-align:center; }
.tal-node:hover { border-color:#caa451; }
.tal-node.is-on { border-color:#8a7337; background:#221f17; } .tal-node.is-max { border-color:#caa451; }
.tal-node.is-elite { border-style:double; border-width:3px; }
.tal-node.is-locked { opacity:.45; }
.tal-name { font-size:11px; line-height:1.2; overflow:hidden; text-overflow:ellipsis; display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; }
.tal-lv { font-size:11px; color:#caa451; }
.tal-effects { border:1px solid var(--line); border-radius:12px; padding:12px; position:sticky; top:76px; }
.tal-effects h3 { margin:0 0 8px; font-size:14px; }
.tal-sums div { display:flex; justify-content:space-between; font-size:13px; padding:3px 0; border-bottom:1px solid #202227; }
.tal-sums b { color:#7fbf8a; } .tal-sums b.is-neg { color:#e5534b; }
.tal-special { padding-left:16px; font-size:12px; color:var(--text-dim); } .tal-special li { margin:6px 0; }
/* тренировка, украшения, общие поля */
.tr-row { display:flex; flex-wrap:wrap; gap:8px; align-items:end; margin:8px 0; }
.tr-field { display:grid; gap:3px; font-size:12px; color:var(--muted); } .tr-field .kc-input,.tr-field .kc-select { min-width:90px; }
.tr-group td { color:#caa451; font-weight:600; background:#1a1c20; }
.tr-list { display:grid; gap:6px; margin:8px 0; }
.tr-item { display:flex; flex-wrap:wrap; gap:12px; align-items:center; padding:8px 10px; border:1px solid var(--line); border-radius:10px; font-size:13px; }
.tr-item.is-auto { border-style:dashed; }
.tr-cost { color:var(--muted); font-size:12px; flex:1; }
.tr-auto { display:flex; gap:8px; align-items:center; font-size:13px; margin:8px 0; flex-wrap:wrap; }
.tr-summary { display:grid; grid-template-columns:repeat(auto-fill,minmax(150px,1fr)); gap:8px; margin:10px 0; }
.tr-summary > div { border:1px solid var(--line); border-radius:10px; padding:8px 10px; display:grid; gap:2px; }
.tr-summary span { color:var(--muted); font-size:11px; } .tr-summary b { color:#caa451; font-size:15px; } .tr-summary b.is-neg { color:#e5534b; }
.dc-head { display:flex; gap:12px; align-items:center; }
.dc-pic { width:44px; height:44px; object-fit:cover; border-radius:8px; display:inline-grid; place-items:center; background:#202227; } .dc-pic.big { width:72px; height:72px; }
.dc-q { font-size:12px; font-weight:600; }
.dc-buffs div { display:flex; justify-content:space-between; font-size:13px; padding:4px 0; border-bottom:1px solid #202227; }
.dc-buffs .is-pos { color:#7fbf8a; } .dc-buffs .is-neg { color:#e5534b; } .dc-inv { color:#d9a441; }
.dc-skill { border:1px solid #4a4127; border-radius:10px; padding:8px 10px; margin-top:10px; } .dc-skill.is-locked { opacity:.6; }
.dc-skill-head { display:flex; justify-content:space-between; gap:8px; font-size:13px; } .dc-skill-head span { color:var(--muted); font-size:12px; } .dc-skill p { margin:6px 0 0; font-size:13px; }
.dc-slots { display:grid; gap:8px; } .dc-slot { display:flex; gap:8px; align-items:center; flex-wrap:wrap; } .dc-slot .kc-select { min-width:0; }
tr.is-active td { background:#221f17; }
/* тир-лист */
.tl-title { flex:1; min-width:200px; font-size:15px; }
.tl-board { display:grid; gap:6px; margin-bottom:14px; }
.tl-tier { display:grid; grid-template-columns:80px 1fr auto; border:1px solid var(--line); border-radius:10px; overflow:hidden; min-height:70px; }
.tl-label { display:grid; place-items:center; font-size:22px; font-weight:800; color:#111; padding:6px; outline:none; word-break:break-word; text-align:center; }
.tl-items { display:flex; flex-wrap:wrap; gap:6px; padding:6px; align-content:flex-start; min-height:60px; }
.tl-items.is-over,.tl-pool.is-over { background:#1f2a21; }
.tl-tools { display:flex; flex-direction:column; gap:4px; padding:6px; } .tl-tools input[type=color] { width:32px; height:24px; border:0; background:none; }
.tl-hero { position:relative; width:64px; display:grid; justify-items:center; gap:2px; background:transparent; border:2px solid transparent; border-radius:10px; padding:2px; color:var(--text); cursor:grab; font:inherit; }
.tl-hero img,.tl-initial { width:56px; height:56px; border-radius:8px; object-fit:cover; display:grid; place-items:center; background:#202227; font-weight:700; }
.tl-hero.is-legend img { box-shadow:0 0 0 2px #caa451; }
.tl-hero.is-picked { border-color:#57ab5a; }
.tl-name { font-size:10px; line-height:1.1; text-align:center; max-width:60px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.tl-filters { display:flex; gap:8px; margin:8px 0; }
.tl-pool { border:1px dashed var(--line); border-radius:10px; padding:8px; } .tl-pool h3 { font-size:14px; margin:0 0 6px; }
.tl-hint { color:#7fbf8a; font-size:13px; margin:0 0 6px; }
/* календарь KvK */
.kvk-controls { display:flex; flex-wrap:wrap; gap:10px; align-items:end; margin-bottom:12px; }
.kvk-top { display:grid; grid-template-columns:1fr 1fr; gap:10px; margin-bottom:12px; }
.kvk-card { border:1px solid var(--line); border-radius:12px; padding:10px 12px; } .kvk-card h3 { margin:0 0 8px; font-size:14px; }
.kvk-evs { display:grid; gap:4px; }
.kc-ev { display:flex; gap:6px; align-items:center; font-size:12px; border-left:3px solid var(--c); background:color-mix(in srgb,var(--c) 18%,transparent); padding:3px 6px; border-radius:4px; min-width:0; }
.kc-ev span { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; } .kc-ev b { font-weight:600; color:var(--text-dim); }
.kvk-next small { color:var(--muted); font-size:11px; display:block; margin:2px 0 6px 9px; }
.kvk-legend { display:flex; flex-wrap:wrap; gap:6px; align-items:center; margin-bottom:10px; }
.kvk-cat { border:1px solid var(--c); background:color-mix(in srgb,var(--c) 22%,transparent); color:var(--text); border-radius:999px; padding:3px 9px; font-size:11px; cursor:pointer; }
.kvk-cat.is-off { opacity:.35; background:transparent; }
.kvk-view-head { display:flex; flex-wrap:wrap; gap:8px; justify-content:space-between; margin-bottom:8px; }
.kvk-grid-wrap { overflow-x:auto; }
.kvk-grid { display:grid; grid-template-columns:repeat(7,minmax(120px,1fr)); gap:4px; min-width:860px; }
.kvk-wd { text-align:center; color:var(--muted); font-size:12px; padding:4px; }
.kvk-day { border:1px solid var(--line); border-radius:8px; padding:5px; min-height:84px; display:grid; gap:3px; align-content:start; }
.kvk-day.is-today { border-color:#caa451; background:#1f1c14; } .kvk-day.is-empty { opacity:.55; }
.kvk-date { font-size:11px; color:var(--muted); display:flex; gap:4px; align-items:center; flex-wrap:wrap; } .kvk-date b { color:var(--text); font-size:13px; }
.kvk-week { margin-left:auto; color:#caa451; } .kvk-today { color:#caa451; font-weight:600; }
.kvk-more summary { font-size:11px; color:var(--muted); cursor:pointer; }
.kvk-list { display:grid; gap:8px; } .kvk-list-day h4 { margin:0 0 4px; font-size:13px; } .kvk-list-day.is-today h4 { color:#caa451; }
/* сезоны */
.sx-tabs { margin-bottom:12px; }
.sx-timeline { display:grid; gap:6px; }
.sx-step { display:grid; grid-template-columns:34px 1fr; gap:10px; padding:8px 10px; border:1px solid var(--line); border-radius:10px; position:relative; overflow:hidden; }
.sx-step.has-behe { border-color:#2b5d34; } .sx-step.has-pass { border-color:#6b5520; }
.sx-step-n { display:grid; place-items:center; width:30px; height:30px; border-radius:50%; background:#202227; color:#caa451; font-weight:700; font-size:13px; }
.sx-step-head { display:flex; flex-wrap:wrap; gap:8px; justify-content:space-between; } .sx-days { color:var(--muted); font-size:12px; }
.sx-tags { display:flex; flex-wrap:wrap; gap:6px; margin-top:4px; }
.sx-tag { font-size:11px; border-radius:999px; padding:2px 8px; border:1px solid var(--line); }
.sx-tag.is-behe { border-color:#2b7d3a; color:#7fbf8a; } .sx-tag.is-pass { border-color:#d4a82a; color:#d4a82a; } .sx-tag.is-statue { border-color:#1e7d8a; color:#6fc5d1; } .sx-tag.is-feature { border-color:#a85a8a; color:#e09ac4; }
.sx-bar { position:absolute; left:0; bottom:0; height:3px; background:#caa451; opacity:.6; }
.sx-behe { display:flex; flex-wrap:wrap; gap:6px; }
.sx-groups { display:grid; gap:8px; } .sx-group { border:1px solid var(--line); border-radius:10px; padding:8px 10px; }
.sx-kingdoms { display:flex; flex-wrap:wrap; gap:4px; margin-top:6px; } .sx-kingdoms span { font-size:12px; padding:1px 6px; border-radius:6px; background:#202227; } .sx-kingdoms .is-me { background:#caa451; color:#111; font-weight:700; }
/* планировщик ROW */
.row-tools { align-items:center; } .row-zoom { display:flex; gap:4px; align-items:center; }
.row-map-wrap { overflow:auto; border:1px solid var(--line); border-radius:12px; background:#0c1d1d; max-height:72vh; }
.row-stage { position:relative; margin:0 auto; touch-action:none; }
.row-map { width:100%; height:100%; display:block; user-select:none; pointer-events:none; }
.row-point { position:absolute; transform:translate(-50%,-140%); display:flex; gap:2px; pointer-events:none; }
.row-badge { display:grid; place-items:center; width:18px; height:18px; border-radius:50%; color:#fff; font-size:11px; font-weight:700; box-shadow:0 0 0 2px #0008; }
.row-marker { position:absolute; transform:translate(-50%,-50%); display:grid; justify-items:center; cursor:grab; user-select:none; touch-action:none; }
.row-ico { display:grid; place-items:center; width:26px; height:26px; border-radius:50%; background:var(--c); box-shadow:0 0 0 2px #000a; font-size:14px; }
.row-label { margin-top:2px; font-size:11px; font-weight:700; background:#000a; color:#fff; padding:1px 5px; border-radius:4px; white-space:nowrap; }
.row-marker.is-text .row-label { margin:0; font-size:13px; }
.row-del { position:absolute; top:-8px; right:-10px; display:none; width:16px; height:16px; border-radius:50%; border:0; background:#e5534b; color:#fff; font-size:11px; line-height:16px; padding:0; cursor:pointer; }
.row-marker:hover .row-del { display:block; }
.row-panel { margin-top:10px; display:grid; gap:10px; }
.row-team { border:1px solid var(--line); border-left:4px solid var(--c,#768390); border-radius:10px; padding:8px 10px; } .row-team h4 { margin:0 0 6px; font-size:14px; }
.row-members { display:flex; flex-wrap:wrap; gap:6px; align-items:center; } .row-members .kc-input { width:160px; }
.row-chip { display:inline-flex; gap:4px; align-items:center; border:1px solid var(--line); border-radius:999px; padding:2px 4px 2px 9px; font-size:12px; } .row-chip button { border:0; background:none; color:var(--muted); cursor:pointer; }
.row-assign { grid-template-columns:200px 1fr; align-items:center; display:grid; }
.row-json { width:100%; font-family:monospace; font-size:12px; }
/* рейтинг серверов */
.sr-table th { cursor:pointer; white-space:nowrap; } .sr-table th.is-sorted { color:#caa451; } .sr-table td.num,.sr-table th.num { text-align:right; }
.sr-status { font-size:11px; padding:2px 7px; border-radius:999px; border:1px solid var(--line); white-space:nowrap; }
.sr-status.is-active { border-color:#e5534b; color:#e5534b; } .sr-status.is-soon { border-color:#d4a72c; color:#d4a72c; } .sr-status.is-ended { color:var(--muted); }
.sr-cols { position:relative; } .sr-cols summary { list-style:none; } .sr-cols-list { position:absolute; z-index:30; background:#0e1012; border:1px solid var(--line); border-radius:10px; padding:10px; display:grid; grid-template-columns:repeat(2,minmax(160px,1fr)); gap:4px 12px; font-size:12px; margin-top:4px; }
.sr-pager { justify-content:center; }
@media(max-width:1100px) { .tal-layout { grid-template-columns:1fr; } .tal-effects { position:static; } .tal-trees { grid-template-columns:repeat(2,minmax(0,1fr)); } }
@media(max-width:700px) { .tal-trees { grid-template-columns:1fr; } .kvk-top { grid-template-columns:1fr; } .tl-tier { grid-template-columns:56px 1fr; } .tl-tools { grid-column:1 / -1; flex-direction:row; } .row-assign { grid-template-columns:1fr; } .hb-qa { grid-template-columns:30px 1fr; } }
.kc-ev b { white-space:nowrap; flex-shrink:0; }
.tal-toolbar .kc-select { width:auto; max-width:440px; }
.tal-name { hyphens:auto; overflow-wrap:break-word; word-break:normal; }

/* ===== Pet calculator v2 — cod-tracker layout (2 columns) ===== */
.pb-builder.pc2 { display:block; max-width:1400px; }
.pc2 > .pb-heading { display:flex; align-items:flex-end; justify-content:space-between; gap:16px; margin-bottom:10px; }
.pc2 .pb-header-actions { display:flex; gap:8px; flex-wrap:wrap; }
.pc-scan { display:flex; align-items:center; gap:10px; color:var(--muted); font-size:12px; margin:0 0 14px; }
.pc-scan:not(:has(.pb-scan-status:not(:empty))) .pb-scan-hint { opacity:.75; }
.pc-grid { display:grid; grid-template-columns:minmax(320px,400px) minmax(0,1fr); gap:16px; align-items:start; }
.pc-left,.pc-right { display:grid; gap:14px; min-width:0; align-content:start; }
.pc-left { position:sticky; top:72px; }
.pc2 .pb-panel { grid-area:auto !important; background:linear-gradient(180deg,#17191d,#121316); border:1px solid var(--pb-line); border-radius:14px; }
.pc-pet { position:relative; padding:14px; display:flex; align-items:center; gap:12px; overflow:hidden; background:radial-gradient(120% 140% at 0 0,#3a2d12 0,#17191d 55%) !important; }
.pc-pet > *:first-child { flex:1; min-width:0; }
.pc-pet .pb-pet-portrait { width:84px; height:84px; border-radius:14px; object-fit:cover; border:1px solid #caa45166; box-shadow:0 6px 22px #0007; }
.pc-pet .pb-pet-caption strong { font-size:18px; }
.pc-change { position:absolute; right:14px; top:12px; font-size:11px; color:var(--pb-gold); pointer-events:none; }
/* attribute sliders coloured like the game */
.pc2 input[type=range] { accent-color:var(--col,#caa451); }
.pc2 .pb-attribute-label img { width:24px; height:24px; }
/* skills grid 4×2 */
.pc-head-gap { flex:1; }
.pc-mini { min-height:26px; padding:0 10px; font-size:11px; }
.pc2 .pb-skills { grid-template-columns:repeat(4,minmax(0,1fr)); gap:12px; padding:14px; }
.pc-slot { position:relative; display:flex; flex-direction:column; align-items:center; gap:6px; padding:10px 6px 8px; border:1px solid var(--pb-line); border-radius:12px; background:#0f1013; cursor:pointer; transition:border-color .15s,transform .15s,background .15s; min-width:0; }
.pc-slot:hover { border-color:#caa45199; transform:translateY(-1px); }
.pc-slot.is-filled { background:radial-gradient(100% 80% at 50% 0,#2b2416,#0f1013 70%); }
.pc-slot.is-innate { border-color:#caa45166; }
.pc-slot.is-amber { background:radial-gradient(100% 80% at 50% 0,#3a2410,#0f1013 70%); }
.pc-slot-label { align-self:flex-start; font-size:10px; letter-spacing:.06em; text-transform:uppercase; color:var(--muted); }
.pc-slot.is-innate .pc-slot-label { color:var(--pb-gold); }
.pc-slot .pb-skill-card { width:64px; height:64px; margin:0; border-radius:12px; }
.pc-slot .pb-skill-icon { width:100%; height:100%; object-fit:contain; }
.pc-slot-name { font-size:11px; line-height:1.25; text-align:center; min-height:28px; display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; }
.pc-slot:not(.is-filled) .pc-slot-name { color:var(--muted); }
.pc-slot .pb-card-stars { position:static; transform:none; }
.pc-slot-stars-empty { height:14px; }
/* heroes & battle */
.pc-battle { padding:14px; display:grid; gap:12px; }
.pc-heroes { display:flex; gap:10px; flex-wrap:wrap; }
.pc-battle-row { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:10px; }
.pc-battle-row .kc-field { margin:0; } .pc-battle-row select { width:100%; }
.pc-battle-actions { display:flex; align-items:center; gap:10px; flex-wrap:wrap; }
/* KPI cards */
.pc-kpis { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:12px; }
.pc-kpis:empty { display:none; }
.pc-kpi { border:1px solid var(--pb-line); border-radius:14px; padding:14px 16px; display:grid; gap:4px; background:#121316; position:relative; overflow:hidden; }
.pc-kpi::before { content:''; position:absolute; inset:0 auto 0 0; width:3px; background:var(--k,#caa451); }
.pc-kpi.is-dps { --k:#e7b649; } .pc-kpi.is-heal { --k:#5fd18a; } .pc-kpi.is-shield { --k:#5bc0de; }
.pc-kpi span { font-size:11px; color:var(--muted); text-transform:uppercase; letter-spacing:.05em; }
.pc-kpi strong { font-size:26px; color:var(--k); font-weight:600; }
.pc-kpi small { font-size:11px; color:var(--muted); }
/* contribution stacked bar */
.pc-stack { display:flex; height:12px; border-radius:6px; overflow:hidden; background:#202227; margin:8px 0 4px; }
.pc-stack span { display:block; height:100%; }
.pc2 .pb-contrib-bar span { background:var(--seg,var(--pb-gold)); }
/* fruits with real icons */
.pb-fruit-img { width:26px; height:26px; object-fit:contain; flex-shrink:0; filter:drop-shadow(0 2px 3px #0008); }
.pb-fruit-chip .pb-fruit-img { width:18px; height:18px; }
.pb-fruit-dots { gap:2px; }
@media(max-width:1100px) { .pc-grid { grid-template-columns:minmax(0,1fr); } .pc-left { position:static; } }
@media(max-width:700px) { .pc2 .pb-skills { grid-template-columns:repeat(2,minmax(0,1fr)); } .pc-battle-row,.pc-kpis { grid-template-columns:1fr 1fr; } }

/* ===== Talents v2: hero picker with portraits, node icons ===== */
.tal-toolbar { align-items:center; }
.tal-hero-btn { display:flex; align-items:center; gap:12px; padding:6px 14px 6px 6px; border:1px solid var(--line); border-radius:14px; background:linear-gradient(90deg,#221d12,#15171b); color:var(--text); cursor:pointer; font:inherit; min-width:260px; text-align:left; }
.tal-hero-btn:hover { border-color:#caa451; }
.tal-hero-img { width:52px; height:52px; border-radius:10px; object-fit:cover; object-position:top; border:2px solid var(--rc,#caa451); }
.tal-hero-text { display:grid; gap:2px; flex:1; } .tal-hero-text strong { font-size:16px; } .tal-hero-text small { color:var(--muted); font-size:11px; }
.tal-hero-change { font-size:11px; color:#caa451; }
.is-legend { --rc:#e6a93a; } .is-epic { --rc:#a66be0; } .is-rare { --rc:#4f9be0; }
.tal-dialog { width:min(920px,94vw); max-height:86vh; padding:0; border:1px solid var(--line); border-radius:16px; background:#121316; color:var(--text); }
.tal-dialog::backdrop { background:#000a; backdrop-filter:blur(3px); }
.tal-dialog-head { display:flex; align-items:center; gap:12px; padding:14px 16px; border-bottom:1px solid var(--line); position:sticky; top:0; background:#121316; z-index:1; }
.tal-dialog-head h3 { margin:0; font-size:16px; white-space:nowrap; } .tal-dialog-head input { flex:1; }
.tal-seasons { display:flex; gap:6px; padding:12px 16px 0; flex-wrap:wrap; }
.tal-season { border:1px solid var(--line); background:#17191d; color:var(--text); border-radius:999px; padding:4px 14px; cursor:pointer; font:inherit; font-size:12px; }
.tal-season.is-on { background:#caa451; color:#16130b; border-color:#caa451; font-weight:600; }
.tal-pick-grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(104px,1fr)); gap:10px; padding:14px 16px 18px; }
.tal-pick { position:relative; display:grid; justify-items:center; gap:4px; padding:6px 6px 8px; border:1px solid var(--line); border-radius:12px; background:#17191d; color:var(--text); cursor:pointer; font:inherit; }
.tal-pick:hover,.tal-pick.is-on { border-color:var(--rc,#caa451); box-shadow:0 0 0 1px var(--rc,#caa451) inset; }
.tal-pick-img { width:100%; aspect-ratio:1; object-fit:cover; object-position:top; border-radius:9px; border-bottom:3px solid var(--rc,#caa451); }
.tal-pick-name { font-size:12px; line-height:1.2; text-align:center; }
.tal-pick small { position:absolute; top:10px; left:10px; background:#000b; border-radius:6px; padding:1px 6px; font-size:10px; color:#ddd; }
.tal-node { justify-items:center; padding:8px 4px 6px; }
.tal-icon { width:44px; height:44px; object-fit:contain; border-radius:50%; filter:grayscale(1) brightness(.55); transition:filter .15s; }
.tal-node.is-on .tal-icon { filter:none; } .tal-node.is-max .tal-icon { filter:drop-shadow(0 0 6px #caa451aa); }
.tal-node.is-elite .tal-icon { width:52px; height:52px; }
.tal-node.is-locked { opacity:.45; }
.tal-name { font-size:10.5px; line-height:1.2; }
.tal-lv { font-size:10px; color:#caa451; }

/* ===== Training v2: icon pickers ===== */
.tr-add { display:grid; gap:12px; padding:14px; border:1px solid var(--line); border-radius:14px; background:#121316; margin-bottom:12px; }
.tr-step { display:grid; gap:6px; } .tr-step > span { font-size:11px; text-transform:uppercase; letter-spacing:.06em; color:var(--muted); }
.tr-types { display:flex; gap:8px; flex-wrap:wrap; }
.tr-type { display:grid; justify-items:center; gap:4px; width:92px; padding:10px 6px 8px; border:1px solid var(--line); border-radius:12px; background:#17191d; color:var(--text); cursor:pointer; font:inherit; font-size:12px; transition:border-color .15s,background .15s; }
.tr-type:hover { border-color:#caa45199; }
.tr-type.is-on { border-color:#caa451; background:radial-gradient(100% 90% at 50% 0,#3a2f15,#17191d 75%); }
.tr-type-img { width:40px; height:40px; object-fit:contain; }
.tr-tiers { display:flex; gap:6px; flex-wrap:wrap; }
.tr-tier { min-width:54px; padding:6px 10px; border:1px solid var(--line); border-radius:9px; background:#17191d; color:var(--text); cursor:pointer; font:inherit; font-size:12px; font-weight:600; }
.tr-tier.is-up { font-weight:500; color:var(--text-dim,#bbb); }
.tr-tier.is-on { background:#caa451; border-color:#caa451; color:#16130b; }
.tr-tier:disabled { opacity:.3; cursor:not-allowed; }
.tr-step-qty .tr-row { margin:0; } .tr-step-qty input { max-width:200px; }
.tr-ico { width:18px; height:18px; object-fit:contain; vertical-align:-4px; margin-right:4px; }
.tr-item-name { display:inline-flex; align-items:center; gap:8px; } .tr-item-img { width:28px; height:28px; object-fit:contain; }
.tr-cost { display:inline-flex; flex-wrap:wrap; gap:10px; } .tr-res { display:inline-flex; align-items:center; white-space:nowrap; }
.tr-sum-res span { display:inline-flex; align-items:center; }

/* ===== Tierlist v2: board + sticky hero pool ===== */
.tl-layout { display:grid; grid-template-columns:minmax(0,1fr) minmax(300px,380px); gap:16px; align-items:start; margin-top:12px; }
.tl-side { position:sticky; top:72px; display:grid; gap:10px; max-height:calc(100vh - 90px); overflow:auto; padding:12px; border:1px solid var(--line); border-radius:14px; background:#121316; }
.tl-side .tl-filters { display:grid; gap:8px; margin:0; }
.tl-chiprow { display:flex; flex-wrap:wrap; gap:6px; }
.tl-chip { display:inline-flex; align-items:center; gap:5px; border:1px solid var(--line); background:#17191d; color:var(--text); border-radius:999px; padding:3px 11px; font:inherit; font-size:12px; cursor:pointer; }
.tl-chip img { width:16px; height:16px; object-fit:contain; }
.tl-chip.is-on { background:#caa451; border-color:#caa451; color:#16130b; font-weight:600; }
.tl-side .tl-pool { margin:0; padding:0; border:0; background:none; }
.tl-side .tl-pool h3 { margin:2px 0 8px; font-size:14px; }
.tl-pool-items { display:grid !important; grid-template-columns:repeat(auto-fill,minmax(72px,1fr)); gap:8px; min-height:80px; }
.tl-board { display:grid; gap:8px; }
.tl-tier { display:grid; grid-template-columns:84px minmax(0,1fr) auto; min-height:104px; border:1px solid var(--line); border-radius:12px; overflow:hidden; background:#121316; }
.tl-label { display:grid; place-items:center; font-size:26px; font-weight:800; color:#111; text-shadow:0 1px 0 #fff5; }
.tl-items { display:flex; flex-wrap:wrap; gap:8px; padding:8px; align-content:flex-start; position:relative; }
.tl-items.is-empty::before { content:attr(data-empty); position:absolute; inset:0; display:grid; place-items:center; color:var(--muted); font-size:12px; border:1px dashed #ffffff1a; margin:8px; border-radius:10px; pointer-events:none; }
.tl-items.is-over { background:#caa4511a; }
.tl-hero { width:76px; display:grid; gap:3px; padding:3px 3px 5px; border:1px solid var(--line); border-radius:10px; background:#17191d; color:var(--text); cursor:grab; font:inherit; }
.tl-hero img { width:100%; aspect-ratio:1; object-fit:cover; object-position:top; border-radius:7px; border-bottom:3px solid #a66be0; }
.tl-hero.is-legend img { border-bottom-color:#e6a93a; }
.tl-hero.is-picked { border-color:#caa451; box-shadow:0 0 0 2px #caa451; }
.tl-name { font-size:10.5px; line-height:1.15; text-align:center; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.tl-pool-items .tl-hero { width:auto; }
.tl-tools { display:flex; flex-direction:column; gap:4px; padding:6px; justify-content:center; }
.tl-tools input[type=color] { width:30px; height:24px; border:0; background:none; padding:0; }
@media(max-width:980px) { .tl-layout { grid-template-columns:1fr; } .tl-side { position:static; max-height:none; order:-1; } .tl-tier { grid-template-columns:60px minmax(0,1fr) auto; } }

/* ===== Seasons v2 ===== */
.sx-tabs { display:grid !important; grid-template-columns:repeat(auto-fill,minmax(130px,1fr)); gap:10px; margin-bottom:16px; }
.sx-card { position:relative; display:grid; align-content:end; gap:2px; min-height:120px; padding:10px; border:1px solid var(--line); border-radius:14px; background:#15171b; color:var(--text); cursor:pointer; font:inherit; text-align:left; overflow:hidden; }
.sx-card img { position:absolute; inset:0; width:100%; height:100%; object-fit:cover; object-position:center 25%; opacity:.45; transition:opacity .2s,transform .3s; }
.sx-card::after { content:''; position:absolute; inset:0; background:linear-gradient(0deg,#0d0e10ee 15%,transparent 70%); }
.sx-card > span,.sx-card > small { position:relative; z-index:1; }
.sx-card-id { font-size:16px; font-weight:700; } .sx-card small { font-size:11px; color:var(--muted); }
.sx-card:hover img { opacity:.7; transform:scale(1.04); }
.sx-card.is-active { border-color:#caa451; box-shadow:0 0 0 1px #caa451 inset; } .sx-card.is-active img { opacity:.8; }
.sx-behe-grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(150px,1fr)); gap:12px; margin-bottom:18px; }
.sx-behe-card { position:relative; margin:0; border:1px solid var(--line); border-radius:14px; overflow:hidden; background:radial-gradient(100% 80% at 50% 20%,#2a2416,#121316 75%); }
.sx-behe-card img { width:100%; aspect-ratio:1; object-fit:contain; display:block; }
.sx-behe-card figcaption { display:grid; gap:2px; padding:8px 10px 10px; } .sx-behe-card small { color:var(--muted); font-size:11px; }
.sx-behe-n { position:absolute; top:8px; left:8px; width:24px; height:24px; display:grid; place-items:center; border-radius:50%; background:#caa451; color:#16130b; font-weight:700; font-size:12px; }
.sx-tag.is-behe { display:inline-flex; align-items:center; gap:6px; padding-left:3px; } .sx-tag.is-behe img { width:22px; height:22px; border-radius:50%; object-fit:cover; }
.tl-page .tl-hero { justify-items:stretch; }
.tl-page .tl-hero img { width:100%; height:auto; aspect-ratio:1; display:block; box-shadow:none; }
.tl-page .tl-hero.is-legend img { box-shadow:none; }
.tl-page .tl-hero.is-picked { border-color:#caa451; }
.tl-page .tl-pool-items .tl-hero { width:auto; }
.tl-page .tl-hero { display:grid !important; grid-template-columns:minmax(0,1fr); align-content:start; }
.tr-auto { display:flex; align-items:center; gap:8px; flex-wrap:wrap; margin:10px 0; } .tr-auto select { width:auto; min-width:160px; }
.tl-page .tl-hero { padding:3px 3px 5px; gap:3px; margin:0; align-items:stretch; border-radius:10px; background:#17191d; border:1px solid var(--line); }
.tl-page .tl-tier .tl-hero { width:80px; }
.tl-side .tl-pool, .tl-side .tl-pool-items, .tl-side .tl-filters { margin:0; padding:0; }
/* ===== v3: unified page header for ported tools ===== */
.ph { position:relative; display:flex; align-items:center; justify-content:space-between; gap:24px; min-height:150px; margin:4px 0 18px; padding:26px 30px; border:1px solid #caa45133; border-radius:20px; overflow:hidden;
  background:radial-gradient(120% 160% at 100% 0,#3b2d10 0,#1a160d 35%,#111215 70%), #111215; box-shadow:0 10px 40px #0006, inset 0 1px 0 #ffffff0d; }
.ph::before { content:''; position:absolute; inset:0; background:radial-gradient(60% 90% at 85% 50%,#caa45126,transparent 70%); pointer-events:none; }
.ph::after { content:''; position:absolute; left:0; right:0; bottom:0; height:2px; background:linear-gradient(90deg,transparent,#caa451aa,transparent); }
.ph-text { position:relative; z-index:1; max-width:760px; display:grid; gap:8px; }
.ph-kicker { justify-self:start; font-size:11px; font-weight:600; letter-spacing:.14em; text-transform:uppercase; color:#e3c278; padding:3px 10px; border:1px solid #caa45155; border-radius:999px; background:#caa45114; }
.ph h1 { margin:0; font-size:clamp(26px,3vw,36px); line-height:1.1; letter-spacing:-.01em; background:linear-gradient(180deg,#fff 30%,#e9d2a0); -webkit-background-clip:text; background-clip:text; color:transparent; }
.ph p { margin:0; color:#b9b4a6; font-size:14px; line-height:1.55; }
.ph-art { position:relative; z-index:1; display:flex; align-items:center; flex-shrink:0; padding-right:6px; }
.ph-art img { width:116px; height:116px; object-fit:cover; object-position:top; border-radius:18px; border:2px solid #caa45166; background:#1b1c20; box-shadow:0 12px 30px #000a; margin-left:-26px; transform:rotate(calc((var(--i) - 1) * 5deg)) translateY(calc(var(--i) * 3px)); transition:transform .25s; }
.ph-art img:first-child { margin-left:0; }
.ph:hover .ph-art img { transform:rotate(0) translateY(-2px); }
.ph-art-1 img { width:150px; height:150px; border-radius:22px; transform:none; }
.ph-row .ph-art img, .ph-decor .ph-art img { object-fit:cover; object-position:center; width:220px; height:130px; }
.ph-events .ph-art img,.ph-calendar .ph-art img,.ph-seasons .ph-art img { object-fit:contain; background:transparent; border:0; box-shadow:none; filter:drop-shadow(0 12px 24px #000c); }
.ph-training .ph-art img { width:76px; height:76px; object-fit:contain; background:#17191d; padding:10px; margin-left:-10px; }
.ph-mobilize .ph-art img,.ph-rankings .ph-art img { width:96px; height:96px; object-fit:contain; background:#17191d; padding:6px; }
@media(max-width:760px) { .ph { padding:20px; min-height:0; } .ph-art { display:none; } }

/* Quiz / events: two-column Q&A cards */
.hb-page .hb-toolbar { position:sticky; top:62px; z-index:5; padding:10px; margin:-10px -10px 12px; border-radius:12px; background:#141518ee; backdrop-filter:blur(6px); }
.hb-qa-list { grid-template-columns:repeat(auto-fill,minmax(440px,1fr)); gap:10px; }
.hb-qa { grid-template-columns:34px 1fr; padding:14px 16px; background:linear-gradient(180deg,#17191d,#131417); transition:border-color .15s,transform .15s; }
.hb-qa:hover { border-color:#caa45166; transform:translateY(-1px); }
.hb-qa-n { width:28px; height:28px; display:grid; place-items:center; padding:0; border-radius:50%; background:#caa4511f; color:#e3c278; font-size:11px; font-weight:700; text-align:center; }
.hb-qa-q { font-size:14px; line-height:1.45; }
.hb-qa-a { display:inline-flex; gap:6px; margin-top:8px; padding:4px 10px; border-radius:8px; background:#1d2b20; border:1px solid #2f4a35; color:#8fd19d; }
@media(max-width:560px) { .hb-qa-list { grid-template-columns:1fr; } }

/* Decor: picture column + results */
.dc-calc { display:grid; grid-template-columns:260px minmax(0,1fr); column-gap:24px; align-items:start; }
.dc-calc > * { grid-column:2; }
.dc-calc > .dc-head { grid-column:1; grid-row:1 / span 30; position:sticky; top:76px; flex-direction:column; align-items:stretch; gap:10px; padding:14px; border:1px solid var(--line); border-radius:16px; background:radial-gradient(100% 80% at 50% 0,#2c2414,#131417 75%); text-align:center; }
.dc-calc > .dc-head .dc-pic.big { width:100%; height:auto; aspect-ratio:1; object-fit:cover; border-radius:12px; }
.dc-calc > .dc-head h3 { margin:4px 0 0; font-size:18px; }
.dc-calc h4 { margin:18px 0 8px; font-size:14px; text-transform:uppercase; letter-spacing:.06em; color:#e3c278; }
@media(max-width:860px) { .dc-calc { grid-template-columns:1fr; } .dc-calc > *,.dc-calc > .dc-head { grid-column:1; grid-row:auto; position:static; } .dc-calc > .dc-head .dc-pic.big { max-width:200px; margin:auto; } }

/* Server rankings filters in one row */
.sr-filters { display:grid !important; grid-template-columns:minmax(220px,2fr) repeat(2,minmax(160px,1fr)) minmax(170px,1fr); gap:10px; align-items:end; }
.sr-filters .kc-select,.sr-filters .kc-input { width:100%; }
@media(max-width:900px) { .sr-filters { grid-template-columns:1fr 1fr; } }

/* Shared polish for ported tools */
.tal-page .kc-panel,.tr-page .kc-panel,.tl-page .kc-panel,.sx-page .kc-panel,.hb-page .kc-panel,.dc-page .kc-panel,.row-page .kc-panel,.kvk-page .kc-panel,.sr-page .kc-panel { border-radius:18px; background:linear-gradient(180deg,#141518,#111214); }
.tr-summary > div { background:linear-gradient(180deg,#17191d,#131417); }
.hb-chip.is-active,.tl-chip.is-on { box-shadow:0 0 0 1px #caa451 inset, 0 4px 14px #caa45133; }
/* v3 fixes */
.hb-page .hb-toolbar { position:static; margin:0 0 12px; padding:0; background:none; backdrop-filter:none; }
.hb-task { background:linear-gradient(180deg,#17191d,#131417); transition:border-color .15s,transform .15s; }
.hb-task:hover { transform:translateY(-1px); }
.hb-task-body { display:flex; gap:10px; align-items:flex-start; }
.hb-task-ico { width:34px; height:34px; object-fit:contain; flex-shrink:0; border-radius:8px; background:#0e0f11; padding:3px; }
.hb-mob-controls { padding:14px 16px; border:1px solid var(--line); border-radius:14px; background:#121316; margin-bottom:14px; }
.hb-mob-controls .hb-label:first-of-type { margin-top:4px; }
.tr-inputs { display:grid; gap:12px; padding:16px; border:1px solid var(--line); border-radius:14px; background:#121316; margin:12px 0 16px; }
.tr-inputs .tr-row { margin:0; gap:12px; align-items:flex-end; }
.tr-inputs .hb-label { width:100%; margin:0 0 -4px; font-size:11px; text-transform:uppercase; letter-spacing:.06em; }
.tr-inputs .tr-field .kc-input { width:120px; }
.tr-inputs .tr-field:has(select) .kc-select { min-width:240px; }
.tl-side { grid-template-columns:minmax(0,1fr) !important; }
.tl-side > * { grid-column:1 !important; grid-row:auto !important; width:auto; }
.tl-side .tl-filters { display:grid !important; gap:8px; }

/* =====================================================================
   Apple pass (v4) — ported tools. One system: true black canvas, quiet
   tiles, SF typography, pill controls, a single gold accent.
   ===================================================================== */
:is(.pb-builder,.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) {
  --ap-tile:#161617; --ap-tile-2:#1d1d1f; --ap-tile-3:#2c2c2e; --ap-fill:rgba(118,118,128,.20); --ap-fill-2:rgba(118,118,128,.32);
  --ap-sep:rgba(255,255,255,.08); --ap-text:#f5f5f7; --ap-text-2:#a1a1a6; --ap-text-3:#6e6e73; --ap-gold:#e2b55b; --ap-gold-ink:#1a1306;
  --ap-green:#30d158; --ap-red:#ff6961; --ap-r-xl:28px; --ap-r-l:20px; --ap-r-m:14px; --ap-r-s:10px;
  font-family:-apple-system,BlinkMacSystemFont,"SF Pro Text","SF Pro Display","Inter","Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;
  color:var(--ap-text); -webkit-font-smoothing:antialiased; letter-spacing:-.003em; max-width:1240px; margin-inline:auto;
}
:is(.pb-builder,.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) :is(h1,h2,h3,h4) { font-family:-apple-system,BlinkMacSystemFont,"SF Pro Display","Inter","Segoe UI",Roboto,sans-serif; color:var(--ap-text); }

/* Header: centered, type does the work */
.ph { display:flex; flex-direction:column; align-items:center; text-align:center; gap:22px; min-height:0; margin:28px auto 40px; padding:0; border:0; border-radius:0; background:none; box-shadow:none; overflow:visible; }
.ph::before,.ph::after { display:none; }
.ph-text { max-width:720px; justify-items:center; gap:14px; }
.ph-kicker { display:none; }
.ph h1 { font-size:clamp(34px,5vw,56px); font-weight:700; line-height:1.05; letter-spacing:-.028em; background:none; color:var(--ap-text); -webkit-text-fill-color:currentColor; }
.ph p { font-size:clamp(16px,1.6vw,19px); line-height:1.45; color:var(--ap-text-2); max-width:640px; }
.ph-art { padding:0; gap:10px; }
.ph-art img,.ph-art-1 img { width:64px; height:64px; margin:0; border:0; border-radius:16px; transform:none; box-shadow:none; background:var(--ap-tile-2); }
.ph:hover .ph-art img { transform:none; }
.ph-row .ph-art img,.ph-decor .ph-art img { width:132px; height:76px; }
.ph-events .ph-art img,.ph-calendar .ph-art img,.ph-seasons .ph-art img { width:84px; height:84px; background:none; filter:none; }
.ph-training .ph-art img,.ph-mobilize .ph-art img,.ph-rankings .ph-art img { width:56px; height:56px; padding:8px; margin:0; background:var(--ap-tile-2); }
@media(max-width:760px) { .ph { margin:12px auto 24px; } .ph-art { display:flex; } .ph-art img { width:48px; height:48px; border-radius:12px; } }

/* Tiles */
:is(.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) .kc-panel { background:var(--ap-tile); border:0; border-radius:var(--ap-r-xl); box-shadow:none; margin-bottom:20px; }
:is(.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) .kc-panel-body { padding:28px; }
@media(max-width:700px) { :is(.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) .kc-panel-body { padding:18px; } }
:is(.pb-builder,.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) :is(h2) { font-size:28px; font-weight:700; letter-spacing:-.02em; margin:8px 0 14px; }
:is(.pb-builder,.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) .kc-panel-body h3 { font-size:21px; font-weight:600; letter-spacing:-.015em; margin:26px 0 12px; }
:is(.pb-builder,.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) .kc-note { color:var(--ap-text-2); font-size:14px; line-height:1.5; }

/* Buttons: pills */
:is(.pb-builder,.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) .kc-btn { min-height:36px; padding:0 16px; border:0; border-radius:980px; background:var(--ap-fill); color:var(--ap-text); font:500 14px/1 inherit; letter-spacing:-.01em; text-transform:none; box-shadow:none; transition:background .15s; }
:is(.pb-builder,.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) .kc-btn:hover { background:var(--ap-fill-2); color:var(--ap-text); }
:is(.pb-builder,.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) .kc-btn.is-primary { background:var(--ap-gold); color:var(--ap-gold-ink); font-weight:600; }
:is(.pb-builder,.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) .kc-btn.is-primary:hover { background:#ecc373; }
:is(.pb-builder,.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) :is(.kc-btn,.hb-chip,.tl-chip,.tal-season,.tr-tier,.tr-type,.pc-slot,.tal-pick,.sx-card,.tal-hero-btn):focus-visible { outline:2px solid var(--ap-gold); outline-offset:2px; }

/* Fields */
:is(.pb-builder,.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) :is(.kc-input,.kc-select) { min-height:40px; border:1px solid transparent; border-radius:var(--ap-r-m); background-color:var(--ap-tile-2); color:var(--ap-text); font-size:15px; transition:box-shadow .15s,border-color .15s; }
:is(.pb-builder,.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) :is(.kc-input,.kc-select):hover { border-color:var(--ap-sep); }
:is(.pb-builder,.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) :is(.kc-input,.kc-select):focus { border-color:var(--ap-gold); box-shadow:0 0 0 4px rgba(226,181,91,.22); outline:0; }
:is(.pb-builder,.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) :is(.tr-field,.kc-field) > span,
:is(.pb-builder,.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) .kc-field > label { font-size:13px; color:var(--ap-text-2); text-transform:none; letter-spacing:0; }

/* Filter pills (Apple Store style): fill when off, white when on */
:is(.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) :is(.hb-chip,.tl-chip,.tal-season) { min-height:32px; padding:0 14px; border:0; border-radius:980px; background:var(--ap-fill); color:var(--ap-text); font-size:13px; font-weight:500; box-shadow:none; }
:is(.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) :is(.hb-chip,.tl-chip,.tal-season):hover { background:var(--ap-fill-2); }
:is(.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) :is(.hb-chip.is-active,.tl-chip.is-on,.tal-season.is-on) { background:var(--ap-text); color:#000; box-shadow:none; }
:is(.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) .hb-chips { gap:8px; }
:is(.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) .hb-label { font-size:13px; color:var(--ap-text-2); margin:18px 0 8px; text-transform:none; letter-spacing:0; }

/* Stat tiles: white numbers, quiet labels */
:is(.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) .tr-summary { gap:10px; }
:is(.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) .tr-summary > div { padding:14px 16px; border:0; border-radius:var(--ap-r-l); background:var(--ap-tile-2); }
:is(.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) .tr-summary span { font-size:12px; color:var(--ap-text-2); }
:is(.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) .tr-summary b { font-size:24px; font-weight:600; letter-spacing:-.02em; color:var(--ap-text); }
:is(.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) .tr-summary b.is-neg,.tr-summary b.is-neg { color:var(--ap-red); }

/* Tables */
:is(.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) .kc-table th { font-size:12px; font-weight:500; color:var(--ap-text-2); text-transform:none; letter-spacing:0; background:none; border-bottom:1px solid var(--ap-sep); }
:is(.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) .kc-table td { border-bottom:1px solid var(--ap-sep); font-size:14px; font-variant-numeric:tabular-nums; background:none; }
:is(.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) .kc-table tr.is-active td { background:rgba(226,181,91,.08); }
:is(.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) .tr-group td { color:var(--ap-text); font-weight:600; font-size:15px; background:none; padding-top:22px; }
:is(.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) .kc-table-wrap { border:0; border-radius:var(--ap-r-l); background:none; }

/* ---------- Pet calculator ---------- */
.pb-builder.pc2 > .pb-heading { flex-direction:column; align-items:center; text-align:center; margin:28px 0 30px; }
.pc2 .pb-heading h1 { font-size:clamp(34px,5vw,56px); font-weight:700; letter-spacing:-.028em; line-height:1.05; margin:0; }
.pc2 .pb-subtitle { font-size:clamp(16px,1.6vw,19px); color:var(--ap-text-2); margin-top:12px; }
.pc2 .pb-header-actions { margin-top:20px; justify-content:center; }
.pc-scan { justify-content:center; color:var(--ap-text-3); }
.pc2 .pb-panel,.pc2 .pc-pet { background:var(--ap-tile) !important; border:0; border-radius:var(--ap-r-xl); box-shadow:none; }
.pc2 .pb-panel-heading { border-bottom:0; padding:20px 22px 6px; min-height:0; }
.pc2 .pb-panel-heading h2 { font-size:19px; font-weight:600; letter-spacing:-.015em; text-transform:none; margin:0; }
.pc2 .pb-panel-heading > span:first-child,.pc2 .pb-panel-icon { display:none; }
.pc-pet { padding:18px; }
.pc-pet .pb-pet-portrait { width:88px; height:88px; border-radius:22px; border:0; box-shadow:none; }
.pc-pet .pb-pet-caption strong { font-size:22px; font-weight:700; letter-spacing:-.02em; }
.pc-change { color:var(--ap-gold); font-size:13px; }
.pc-slot { background:var(--ap-tile-2); border:0; border-radius:var(--ap-r-l); padding:12px 8px 10px; }
.pc-slot:hover { transform:none; background:var(--ap-tile-3); }
.pc-slot.is-filled,.pc-slot.is-amber { background:var(--ap-tile-2); }
.pc-slot.is-innate { box-shadow:inset 0 0 0 1.5px rgba(226,181,91,.55); }
.pc-slot-label { font-size:11px; letter-spacing:0; text-transform:none; color:var(--ap-text-3); }
.pc-slot.is-innate .pc-slot-label { color:var(--ap-gold); }
.pc-slot .pb-skill-card { background:transparent; border:0; box-shadow:none; }
.pc-slot:not(.is-filled) .pb-skill-card { border:1.5px dashed rgba(255,255,255,.14); }
.pc-kpi { background:var(--ap-tile); border:0; border-radius:var(--ap-r-xl); padding:20px 22px; }
.pc-kpi::before { display:none; }
.pc-kpi span { text-transform:none; letter-spacing:0; font-size:13px; color:var(--ap-text-2); }
.pc-kpi strong { font-size:34px; font-weight:700; letter-spacing:-.03em; color:var(--ap-text); }
.pc-kpi.is-dps strong { color:var(--ap-gold); }
.pc-kpi small { color:var(--ap-text-3); }
.pc2 .pb-damage-box,.pc2 .pb-modifiers,.pc2 .pb-power-rows > div,.pc2 .pb-fruit-step,.pc2 .pb-fruit-chip { border:0; background:var(--ap-tile-2); border-radius:var(--ap-r-m); }
.pc2 .pb-power-value { color:var(--ap-text); font-size:40px; font-weight:700; letter-spacing:-.03em; }
.pc2 .pb-summary-tab { border:0; background:var(--ap-fill); color:var(--ap-text); border-radius:980px; }
.pc-stack { height:10px; border-radius:980px; }
.pc2 input[type=range] { height:4px; }

/* ---------- Talents ---------- */
.tal-hero-btn { background:var(--ap-tile-2); border:0; border-radius:var(--ap-r-l); padding:8px 16px 8px 8px; }
.tal-hero-btn:hover { background:var(--ap-tile-3); }
.tal-hero-img { border-radius:14px; border:0; }
.tal-hero-change { color:var(--ap-gold); }
.tal-core { border-radius:980px !important; }
.tal-tree { background:var(--ap-tile-2); border:0; border-radius:var(--ap-r-l); }
.tal-tree h3 { font-size:15px !important; margin:0 0 10px !important; }
.tal-node { background:transparent; border:0; border-radius:var(--ap-r-m); }
.tal-node:hover { background:var(--ap-tile-3); }
.tal-node.is-on { background:rgba(226,181,91,.10); }
.tal-node.is-max { background:rgba(226,181,91,.18); }
.tal-effects { background:var(--ap-tile-2); border:0; border-radius:var(--ap-r-l); }
.tal-dialog { background:var(--ap-tile,#161617); border:0; border-radius:var(--ap-r-xl,28px); }
.tal-dialog-head { background:inherit; border-bottom:1px solid rgba(255,255,255,.08); }
.tal-pick { background:#1d1d1f; border:0; border-radius:18px; }
.tal-pick:hover,.tal-pick.is-on { box-shadow:inset 0 0 0 2px var(--rc,#e2b55b); }
.tal-pick-img { border:0; border-radius:14px; }
.tal-season.is-on { background:#f5f5f7; color:#000; }

/* ---------- Training ---------- */
.tr-inputs,.tr-add { background:var(--ap-tile-2); border:0; border-radius:var(--ap-r-l); padding:20px; }
.tr-inputs .hb-label,.tr-step > span { text-transform:none; letter-spacing:0; font-size:13px; color:var(--ap-text-2); }
.tr-type { background:var(--ap-tile-3); border:0; border-radius:var(--ap-r-l); width:100px; }
.tr-type:hover { background:#3a3a3c; }
.tr-type.is-on { background:var(--ap-text); color:#000; }
.tr-tier { background:var(--ap-tile-3); border:0; border-radius:980px; min-width:58px; }
.tr-tier.is-on { background:var(--ap-text); color:#000; }
.tr-item { background:var(--ap-tile-2); border:0; border-radius:var(--ap-r-m); }

/* ---------- Tierlist ---------- */
.tl-tier { background:var(--ap-tile-2); border:0; border-radius:var(--ap-r-l); }
.tl-label { font-size:30px; font-weight:800; color:#000; text-shadow:none; }
.tl-items.is-empty::before { border:1.5px dashed rgba(255,255,255,.1); border-radius:14px; color:var(--ap-text-3); }
.tl-side { background:var(--ap-tile-2); border:0; border-radius:var(--ap-r-l); padding:16px; }
.tl-page .tl-hero { border:0; background:var(--ap-tile-3); border-radius:14px; }
.tl-page .tl-hero img { border-radius:11px; }
.tl-page .tl-hero.is-picked { box-shadow:0 0 0 2px var(--ap-gold); }
.tl-tools .kc-btn { min-height:30px; padding:0 10px; }

/* ---------- Seasons ---------- */
.sx-card { background:var(--ap-tile-2); border:0; border-radius:var(--ap-r-l); }
.sx-card.is-active { box-shadow:0 0 0 2px var(--ap-gold); }
.sx-behe-card { border:0; border-radius:var(--ap-r-l); background:var(--ap-tile-2); }
.sx-behe-n { background:var(--ap-text); color:#000; }
.sx-step { background:var(--ap-tile-2); border:0; border-radius:var(--ap-r-m); }
.sx-tag { border:0; background:var(--ap-fill); border-radius:980px; }

/* ---------- Handbook ---------- */
.hb-qa { background:var(--ap-tile-2); border:0; border-radius:var(--ap-r-l); padding:18px 20px; }
.hb-qa:hover { transform:none; background:var(--ap-tile-3); }
.hb-qa-n { background:var(--ap-fill); color:var(--ap-text-2); }
.hb-qa-q { font-size:15px; }
.hb-qa-a { background:rgba(48,209,88,.12); border:0; color:#5fe08a; border-radius:980px; padding:4px 12px; font-weight:600; }
.hb-qa mark { background:rgba(226,181,91,.35); }
.hb-mob-controls { background:var(--ap-tile-2); border:0; border-radius:var(--ap-r-l); padding:18px 20px; }
.hb-task { background:var(--ap-tile-2); border:0; border-radius:var(--ap-r-l); padding:14px 16px; box-shadow:inset 3px 0 0 var(--c); }
.hb-task:hover { transform:none; }
.hb-task-ico { background:var(--ap-tile-3); border-radius:10px; }
.hb-task-top b { color:var(--ap-text); }
.hb-mob-cat h3 { font-size:21px; }

/* ---------- Decor, ROW, calendar, rankings ---------- */
.dc-calc > .dc-head { background:var(--ap-tile-2); border:0; border-radius:var(--ap-r-l); }
.dc-calc h4 { text-transform:none; letter-spacing:-.01em; font-size:17px; color:var(--ap-text); }
.dc-buffs > div,.dc-skill,.dc-slot { border-color:var(--ap-sep); }
.row-page .row-map,.row-page [class*="row-map"] { border:0; border-radius:var(--ap-r-l); }
.kvk-page :is(.kvk-day,.kvk-cell,.kvk-today,.kvk-next) { border:0; border-radius:var(--ap-r-m); background:var(--ap-tile-2); }
.sr-status { border:0; background:var(--ap-fill); border-radius:980px; }
@media (prefers-reduced-motion:reduce) { :is(.pb-builder,.tal-page,.tr-page,.tl-page,.sx-page,.hb-page,.dc-page,.row-page,.kvk-page,.sr-page) * { transition:none !important; } }
.pc2 .pb-heading-icon { display:none; }
.kvk-page .kvk-card { background:var(--ap-tile-2); border:0; border-radius:var(--ap-r-l); padding:16px 18px; }
.kvk-page .kvk-card h3 { font-size:17px !important; margin:0 0 10px !important; }
.kvk-page .kvk-cat { border:0; border-radius:980px; padding:5px 12px; font-size:12px; }
.kvk-page .kvk-day { border:0; background:var(--ap-tile-2); border-radius:var(--ap-r-m); }
.kvk-page .kvk-today { box-shadow:inset 0 0 0 1.5px var(--ap-gold); }
.row-page .row-map-wrap { border:0; border-radius:var(--ap-r-l); background:var(--ap-tile-2); }
/* v4 fixes */
:is(.tr-inputs,.tr-add,.hb-mob-controls,.tal-dialog,.tl-side,.dc-head) :is(.kc-input,.kc-select) { background-color:#2c2c2e; }
.tal-node.is-elite { border:0; box-shadow:inset 0 0 0 1px rgba(255,255,255,.10); }
.tal-node.is-elite.is-on { box-shadow:inset 0 0 0 1.5px rgba(226,181,91,.7); }
.tal-core { border:0 !important; background:rgba(118,118,128,.20); color:#f5f5f7; min-height:36px; padding:0 16px; font-weight:500; }
.tal-core.is-on { background:#e2b55b; color:#1a1306; }
.tal-points-wrap { color:#a1a1a6; font-size:14px; } .tal-points { color:#f5f5f7; font-size:17px; }
.tal-page .tal-toolbar { gap:10px; }
.tal-effects h3 { font-size:19px !important; margin-top:0 !important; }
.tal-sums > div { border-color:rgba(255,255,255,.08); }
.hb-rarity { text-transform:none !important; letter-spacing:0; }
.pc2 .pb-primary { background:var(--ap-gold); color:var(--ap-gold-ink); }
.pc2 .pb-share { border:0; }

/* =====================================================================
   Home (v5) — about-first, Apple-style. Same tokens as the tools pass.
   ===================================================================== */
.hm { --ap-tile:#161617; --ap-tile-2:#1d1d1f; --ap-tile-3:#2c2c2e; --ap-fill:rgba(118,118,128,.20); --ap-fill-2:rgba(118,118,128,.32); --ap-sep:rgba(255,255,255,.08);
  --ap-text:#f5f5f7; --ap-text-2:#a1a1a6; --ap-text-3:#6e6e73; --ap-gold:#e2b55b; --ap-gold-ink:#1a1306;
  font-family:-apple-system,BlinkMacSystemFont,"SF Pro Text","SF Pro Display","Inter","Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;
  color:var(--ap-text); -webkit-font-smoothing:antialiased; max-width:1180px; margin:0 auto; padding-bottom:40px; }
.hm :is(h1,h2,h3) { font-family:-apple-system,BlinkMacSystemFont,"SF Pro Display","Inter","Segoe UI",Roboto,sans-serif; color:var(--ap-text); margin:0; }
.hm .kc-btn { min-height:40px; padding:0 20px; border:0; border-radius:980px; background:var(--ap-fill); color:var(--ap-text); font-size:15px; font-weight:500; display:inline-flex; align-items:center; text-decoration:none; }
.hm .kc-btn:hover { background:var(--ap-fill-2); }
.hm .kc-btn.is-primary { background:var(--ap-gold); color:var(--ap-gold-ink); font-weight:600; }
.hm .kc-btn.is-primary:hover { background:#ecc373; }
.hm .hm-btn-lg { min-height:48px; padding:0 26px; font-size:17px; }
.hm :is(a,button,summary):focus-visible { outline:2px solid var(--ap-gold); outline-offset:3px; border-radius:12px; }
.hm-actions { display:flex; flex-wrap:wrap; gap:12px; }
.hm-center { justify-content:center; margin-top:28px; }

/* Hero */
.hm-hero { display:grid; justify-items:center; text-align:center; gap:34px; padding:18px 0 76px; }
.hm-hero-art { display:block; width:100%; }
.hm-hero-art img { display:block; width:100%; height:auto; aspect-ratio:2048/682; object-fit:cover; border-radius:28px; }
.hm-hero-text { display:grid; justify-items:center; gap:16px; max-width:780px; }
.hm-hero-place { margin:0; color:var(--ap-gold); font-size:17px; font-weight:600; }
.hm-hero h1 { font-size:clamp(44px,8vw,96px); font-weight:700; letter-spacing:-.035em; line-height:1; }
.hm-hero-lead { margin:0; font-size:clamp(18px,2.2vw,24px); line-height:1.4; color:var(--ap-text-2); letter-spacing:-.01em; }
.hm-hero .hm-actions { justify-content:center; margin-top:10px; }

/* Sections */
.hm-section { padding:72px 0 0; scroll-margin-top:80px; }
.hm-head { display:grid; justify-items:center; text-align:center; gap:14px; margin:0 auto 36px; max-width:720px; }
.hm-head h2 { font-size:clamp(32px,4.6vw,56px); font-weight:700; letter-spacing:-.03em; line-height:1.05; }
.hm-head p { margin:0; font-size:clamp(17px,1.8vw,21px); line-height:1.45; color:var(--ap-text-2); }

/* About pillars */
.hm-pillars { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:20px; }
.hm-pillar { display:grid; align-content:start; gap:12px; padding:30px; border-radius:28px; background:var(--ap-tile); }
.hm-pillar-img { width:72px; height:72px; border-radius:20px; object-fit:cover; background:var(--ap-tile-2); }
.hm-pillar h3 { font-size:24px; font-weight:700; letter-spacing:-.02em; margin-top:6px; }
.hm-pillar p { margin:0; color:var(--ap-text-2); font-size:16px; line-height:1.5; }
.hm-link { color:var(--ap-gold); font-size:16px; font-weight:500; text-decoration:none; margin-top:4px; justify-self:start; }
.hm-link:hover { text-decoration:underline; }
.hm-link::after { content:' ›'; }

/* Numbers — the one bold moment after the hero */
.hm-stats { display:grid; grid-template-columns:repeat(5,minmax(0,1fr)); gap:1px; margin-top:72px; border-radius:28px; overflow:hidden; background:var(--ap-sep); }
.hm-stats > div { display:grid; gap:6px; padding:30px 22px; background:var(--ap-tile); text-align:center; }
.hm-stats strong { font-size:clamp(28px,3.4vw,44px); font-weight:700; letter-spacing:-.03em; font-variant-numeric:tabular-nums; }
.hm-stats span { font-size:14px; color:var(--ap-text-2); }

/* Channel */
.hm-videos { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:20px; }
.hm-video { display:grid; gap:8px; color:var(--ap-text); text-decoration:none; }
.hm-video img { width:100%; aspect-ratio:16/9; object-fit:cover; border-radius:18px; background:var(--ap-tile-2); }
.hm-video-title { font-size:16px; font-weight:600; line-height:1.3; display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; }
.hm-video-meta { font-size:13px; color:var(--ap-text-2); }
.hm-video:hover .hm-video-title { color:var(--ap-gold); }
.hm-channel-card { display:flex; align-items:center; gap:18px; max-width:520px; margin:0 auto; padding:20px 24px; border-radius:24px; background:var(--ap-tile); color:var(--ap-text); text-decoration:none; }
.hm-channel-card img { width:64px; height:64px; border-radius:50%; }
.hm-channel-card span { display:grid; gap:4px; } .hm-channel-card strong { font-size:17px; } .hm-channel-card small { color:var(--ap-text-2); font-size:14px; }
.hm-invite { display:grid; grid-template-columns:minmax(0,1fr) auto; align-items:center; gap:24px; margin-top:28px; padding:30px 34px; border-radius:28px; background:var(--ap-tile); }
.hm-invite h3 { font-size:24px; font-weight:700; letter-spacing:-.02em; }
.hm-invite p { margin:8px 0 0; color:var(--ap-text-2); font-size:16px; line-height:1.5; max-width:620px; }

/* People */
.hm-legends { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:20px; margin-bottom:36px; }
.hm-legend { display:grid; grid-template-columns:72px minmax(0,1fr); gap:16px; align-items:start; padding:24px; border-radius:24px; background:var(--ap-tile); }
.hm-legend-img { width:72px; height:72px; border-radius:50%; object-fit:cover; background:var(--ap-tile-2); }
.hm-legend h3 { font-size:19px; font-weight:700; letter-spacing:-.015em; }
.hm-legend p { margin:6px 0 0; color:var(--ap-text-2); font-size:14px; line-height:1.5; }
.hm-group { margin-top:28px; }
.hm-group > h3 { font-size:21px; font-weight:600; letter-spacing:-.015em; text-align:center; margin-bottom:18px; }
.hm-people { display:flex; flex-wrap:wrap; justify-content:center; gap:22px 18px; }
.hm-person { display:grid; justify-items:center; gap:8px; width:104px; margin:0; text-align:center; }
.hm-person-img { width:80px; height:80px; border-radius:50%; object-fit:cover; background:var(--ap-tile-2); }
.hm-person strong { font-size:14px; font-weight:600; overflow-wrap:anywhere; }
.hm-person span { display:block; font-size:12px; color:var(--ap-text-2); line-height:1.3; }

/* Tools */
.hm-tools { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:16px; }
.hm-tool { display:grid; align-content:start; gap:6px; padding:22px; border-radius:24px; background:var(--ap-tile); color:var(--ap-text); text-decoration:none; transition:background .2s; }
.hm-tool:hover { background:var(--ap-tile-2); }
.hm-tool img { width:56px; height:56px; border-radius:16px; object-fit:cover; object-position:top; background:var(--ap-tile-2); margin-bottom:10px; }
.hm-tool.is-icon img { object-fit:contain; padding:6px; }
.hm-tool strong { font-size:17px; font-weight:600; letter-spacing:-.01em; }
.hm-tool span { font-size:14px; color:var(--ap-text-2); line-height:1.4; }

/* Week */
.hm-week { list-style:none; margin:0; padding:0; display:grid; grid-template-columns:repeat(7,minmax(0,1fr)); gap:10px; }
.hm-week li { display:grid; align-content:start; gap:6px; padding:18px 16px; border-radius:20px; background:var(--ap-tile); }
.hm-week li.is-today { box-shadow:inset 0 0 0 2px var(--ap-gold); }
.hm-week-day { font-size:13px; color:var(--ap-text-2); }
.hm-week li.is-today .hm-week-day { color:var(--ap-gold); font-weight:600; }
.hm-week strong { font-size:15px; font-weight:600; line-height:1.3; }
.hm-week li > span:last-child { font-size:13px; color:var(--ap-text-2); line-height:1.4; }

/* FAQ */
.hm-faq { max-width:820px; margin:0 auto; border-top:1px solid var(--ap-sep); }
.hm-faq details { border-bottom:1px solid var(--ap-sep); }
.hm-faq summary { list-style:none; cursor:pointer; padding:22px 40px 22px 0; font-size:19px; font-weight:600; letter-spacing:-.01em; position:relative; }
.hm-faq summary::-webkit-details-marker { display:none; }
.hm-faq summary::after { content:'+'; position:absolute; right:4px; top:50%; transform:translateY(-50%); font-size:26px; font-weight:300; color:var(--ap-text-2); transition:transform .2s; }
.hm-faq details[open] summary::after { transform:translateY(-50%) rotate(45deg); }
.hm-faq p { margin:0 0 22px; color:var(--ap-text-2); font-size:16px; line-height:1.55; max-width:680px; }

@media(max-width:1000px) { .hm-tools { grid-template-columns:repeat(2,minmax(0,1fr)); } .hm-week { grid-template-columns:repeat(2,minmax(0,1fr)); } .hm-stats { grid-template-columns:repeat(3,minmax(0,1fr)); } }
@media(max-width:820px) { .hm-pillars,.hm-legends,.hm-videos { grid-template-columns:1fr; } .hm-invite { grid-template-columns:1fr; padding:24px; } }
@media(max-width:560px) { .hm-hero { padding-bottom:48px; gap:24px; } .hm-hero-art img { border-radius:18px; aspect-ratio:auto; } .hm-section { padding-top:56px; } .hm-stats { grid-template-columns:repeat(2,minmax(0,1fr)); margin-top:56px; } .hm-stats > div:last-child { grid-column:1 / -1; } .hm-pillar { padding:24px; } .hm-tools { gap:12px; } .hm-tool { padding:18px; } .hm-person { width:88px; } .hm-person-img { width:68px; height:68px; } }
@media (prefers-reduced-motion:reduce) { .hm * { transition:none !important; } }
.hm-stats { grid-template-columns:repeat(var(--n,5),minmax(0,1fr)); }
.hm-stats:empty { display:none; }
.hm-people { gap:22px 14px; }
.hm-person { width:100px; align-content:start; }
@media(max-width:1000px) { .hm-stats { grid-template-columns:repeat(min(var(--n,5),3),minmax(0,1fr)); } }
@media(max-width:560px) { .hm-stats { grid-template-columns:repeat(2,minmax(0,1fr)); } .hm-person { width:84px; } }
/* v6: pet switcher popover */
.pc2 .pc-pet { overflow:visible; z-index:20; }
.pc-pet .pb-pet-trigger { cursor:pointer; border-radius:20px; transition:background .15s; }
.pc-pet .pb-pet-trigger:hover { background:rgba(255,255,255,.04); }
.pc-change { position:absolute; right:16px; top:14px; pointer-events:auto; border:0; background:rgba(118,118,128,.2); color:#f5f5f7; font:500 13px/1 inherit; padding:8px 12px; border-radius:980px; cursor:pointer; }
.pc-change:hover { background:rgba(118,118,128,.32); }
.pc-pet .pb-picker { top:calc(100% + 10px); width:min(440px,calc(100vw - 32px)); background:#1d1d1f; border:0; border-radius:22px; box-shadow:0 30px 80px rgba(0,0,0,.65); }
.pc-pet .pb-picker > .kc-input { height:48px; padding:0 18px; background:#2c2c2e; border:0; border-radius:0; font-size:15px; }
.pc-pet .pb-picker-list { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:6px; max-height:min(460px,60vh); padding:10px; }
.pc-pet .pb-picker-list h3 { grid-column:1 / -1; font-size:13px; font-weight:600; color:#a1a1a6; margin:10px 6px 2px; }
.pc-pet .pb-picker-option { flex-direction:column; justify-content:flex-start; gap:6px; min-height:0; padding:10px 6px; border-radius:14px; text-align:center; font-size:12px; line-height:1.25; position:relative; }
.pc-pet .pb-picker-option img { width:58px; height:58px; border-radius:16px; }
.pc-pet .pb-picker-option[aria-pressed="true"] { background:#2c2c2e; box-shadow:inset 0 0 0 1.5px #e2b55b; }
.pc-pet .pb-picker-check { position:absolute; top:6px; right:8px; margin:0; }
.pc-change { top:auto; bottom:16px; }
.pc2 .pc-pet { padding-bottom:58px; }

/* =====================================================================
   v6: talent TREE — grows from the root at the bottom; a trunk runs up
   the middle and each layer branches out to its talents.
   ===================================================================== */
.tal-page .tal-tree { --tl:rgba(255,255,255,.10); --tg:#e2b55b; padding:14px 10px 18px; display:flex; flex-direction:column; }
.tal-page .tal-tree h3 { display:flex; justify-content:space-between; align-items:baseline; padding:0 6px; }
.tal-page .tal-tree h3 span { color:var(--tg); font-variant-numeric:tabular-nums; }
.tal-tree-body { display:flex; flex-direction:column-reverse; flex:1; justify-content:flex-start; padding-bottom:10px; position:relative; }
.tal-tree-body::after { content:''; display:block; order:-1; width:18px; height:18px; margin:2px auto 0; border-radius:50%; background:var(--tg); box-shadow:0 0 0 5px rgba(226,181,91,.18); }
.tal-page .tal-row { --orb:50px; --pad:12px; position:relative; display:flex; justify-content:space-around; align-items:flex-start; gap:0; padding:var(--pad) 0; margin:0; }
.tal-page .tal-row::before { content:''; position:absolute; top:calc(var(--pad) + var(--orb) / 2 - 1px); left:calc(50% / var(--n,1)); right:calc(50% / var(--n,1)); height:2px; background:var(--tl); border-radius:2px; }
.tal-page .tal-row::after { content:''; position:absolute; left:calc(50% - 1px); width:2px; top:calc(var(--pad) + var(--orb) / 2); bottom:-1px; background:var(--tl); }
.tal-page .tal-row:first-child::after { bottom:calc(-1 * var(--pad) - 2px); }
.tal-page .tal-row:last-child::after { display:none; }
.tal-page .tal-row.is-lit::before { background:var(--tg); }
.tal-page .tal-row.is-open + .tal-row.is-open::after,.tal-page .tal-row.is-lit::after { background:linear-gradient(var(--tg),var(--tg)); }
.tal-page .tal-row:not(.is-open)::before,.tal-page .tal-row:not(.is-open)::after { opacity:.5; }

.tal-page .tal-node { position:relative; z-index:1; display:grid; justify-items:center; gap:6px; flex:1 1 0; min-width:0; padding:0 2px; background:none; border:0; box-shadow:none !important; }
.tal-page .tal-node:hover { background:none; }
.tal-orb { position:relative; width:var(--orb); height:var(--orb); padding:0; border:0; border-radius:50%; background:#2c2c2e; display:grid; place-items:center; cursor:pointer; box-shadow:0 0 0 2px #1d1d1f, 0 0 0 3px rgba(255,255,255,.12); transition:box-shadow .15s, transform .15s; }
.tal-orb:hover { transform:scale(1.06); }
.tal-orb:focus-visible { outline:2px solid #e2b55b; outline-offset:3px; }
.tal-page .tal-orb .tal-icon { width:78%; height:78%; border-radius:50%; object-fit:contain; filter:grayscale(1) brightness(.55); }
.tal-page .tal-node.is-on .tal-orb { box-shadow:0 0 0 2px #1d1d1f, 0 0 0 4px rgba(226,181,91,.75); }
.tal-page .tal-node.is-on .tal-icon { filter:none; }
.tal-page .tal-node.is-max .tal-orb { background:#3a2f17; box-shadow:0 0 0 2px #1d1d1f, 0 0 0 4px #e2b55b, 0 0 18px rgba(226,181,91,.45); }
.tal-page .tal-node.is-elite .tal-orb { --orb:58px; width:58px; height:58px; border-radius:16px; }
.tal-page .tal-node.is-elite .tal-icon { border-radius:12px; width:82%; height:82%; }
.tal-page .tal-node.is-locked .tal-orb { opacity:.45; cursor:not-allowed; }
.tal-page .tal-node.is-locked .tal-orb:hover { transform:none; }
.tal-page .tal-lv { position:absolute; bottom:-7px; left:50%; transform:translateX(-50%); padding:1px 6px; border-radius:980px; background:#1d1d1f; color:#a1a1a6; font-size:10px; font-weight:600; line-height:1.4; font-variant-numeric:tabular-nums; white-space:nowrap; }
.tal-page .tal-node.is-on .tal-lv { color:#1a1306; background:#e2b55b; }
.tal-minus { position:absolute; top:-4px; right:calc(50% - var(--orb) / 2 - 8px); z-index:2; width:20px; height:20px; padding:0; border:0; border-radius:50%; background:#3a3a3c; color:#f5f5f7; font-size:14px; line-height:20px; cursor:pointer; }
.tal-minus:hover { background:#ff6961; }
.tal-page .tal-name { margin-top:4px; font-size:10.5px; line-height:1.2; color:#a1a1a6; text-align:center; display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; }
.tal-page .tal-node.is-on .tal-name { color:#f5f5f7; }
@media(max-width:700px) { .tal-page .tal-row { --orb:44px; } .tal-page .tal-node.is-elite .tal-orb { width:50px; height:50px; } }

/* v6: team page */
.team-page .team-block { margin-top:26px; }
.team-page .team-block:first-child { margin-top:0; }
.team-roster { margin-top:36px; padding-top:28px; border-top:1px solid rgba(255,255,255,.08); }
.team-roster-title { margin:0 0 4px; font-size:28px; font-weight:700; letter-spacing:-.02em; }
.team-row.is-lead { display:flex; }
.team-row.is-lead .team-card { min-width:min(420px,100%); border-color:rgba(226,181,91,.45); }
.tal-page .tal-name { position:relative; z-index:1; padding:0 3px; background:#1d1d1f; border-radius:4px; }
.tal-page .tal-node.is-locked .tal-orb { opacity:.6; }

/* =====================================================================
   v7: in-game talent tree — core in the centre, foundation down to the
   root, three branches fanning left / up / right. Hex nodes.
   ===================================================================== */
.tal-page .tal-layout { display:grid; grid-template-columns:minmax(0,1fr); gap:20px; }
.tal-page .tal-trees { display:block; }
.tal-board { position:relative; border-radius:24px; overflow:hidden; overflow-x:auto; overscroll-behavior-x:contain;
  background:radial-gradient(60% 70% at 50% 64%, #1f4d68 0%, #12303f 42%, #0b1a24 78%, #08131a 100%); box-shadow:inset 0 0 0 1px rgba(255,255,255,.06); }
.tal-board::before { content:''; position:absolute; inset:0; pointer-events:none; background:radial-gradient(circle at 50% 65%, rgba(185,242,63,.06), transparent 40%), radial-gradient(1px 1px at 20% 30%, #ffffff55, transparent), radial-gradient(1px 1px at 70% 20%, #ffffff44, transparent), radial-gradient(1px 1px at 85% 70%, #ffffff33, transparent), radial-gradient(1px 1px at 35% 80%, #ffffff33, transparent); }
.tal-stage { position:relative; width:100%; min-width:900px; aspect-ratio:1700/980; container-type:inline-size; }
.tal-hex,.tal-core-hex { --hb:#3f7d9c; --hf:rgba(31,74,99,.78); --hs:2.75cqw; position:absolute; width:var(--hs); aspect-ratio:.88; transform:translate(-50%,-50%); padding:0; border:0; background:none; cursor:pointer; z-index:1; transition:transform .15s, filter .15s; }
.tal-hex::before,.tal-core-hex::before,.tal-hex-in { content:''; position:absolute; clip-path:polygon(50% 0,100% 25%,100% 75%,50% 100%,0 75%,0 25%); }
.tal-hex::before,.tal-core-hex::before { inset:0; background:var(--hb); }
.tal-hex-in { inset:7%; display:grid; place-items:center; background:var(--hf); }
.tal-hex-in img { width:76%; height:76%; object-fit:contain; filter:grayscale(1) sepia(.5) hue-rotate(160deg) saturate(1.6) brightness(.8); opacity:.75; pointer-events:none; }
.tal-hex:hover,.tal-hex:focus-visible { transform:translate(-50%,-50%) scale(1.12); z-index:3; outline:0; }
.tal-hex.is-elite { --hs:3.7cqw; --hb:#c9963f; --hf:rgba(31,74,99,.85); }
.tal-hex.is-on { --hb:#b9f23f; --hf:#17330f; filter:drop-shadow(0 0 .55cqw rgba(185,242,63,.55)); }
.tal-hex.is-on .tal-hex-in img { filter:none; opacity:1; }
.tal-hex.is-max { --hf:#2b5212; filter:drop-shadow(0 0 .9cqw rgba(185,242,63,.8)); }
.tal-hex.is-elite.is-on { --hb:#e2b55b; --hf:#2a3c12; }
.tal-hex.is-locked { opacity:.42; cursor:not-allowed; }
.tal-hex.is-locked:hover { transform:translate(-50%,-50%); }
.tal-hex.is-focus::after { content:''; position:absolute; inset:-12%; border:1px dashed rgba(255,255,255,.5); border-radius:50%; pointer-events:none; }
.tal-hex-lv { position:absolute; left:50%; bottom:-.55cqw; transform:translateX(-50%); z-index:2; padding:.05cqw .45cqw; border-radius:980px; background:#0b1a24; color:#d8f7a0; font-size:max(9px,.72cqw); font-weight:700; line-height:1.35; white-space:nowrap; box-shadow:0 0 0 1px rgba(185,242,63,.5); }
.tal-hex[data-tip]:hover::after { content:attr(data-tip); position:absolute; left:50%; bottom:calc(100% + .6cqw); transform:translateX(-50%); padding:4px 10px; border-radius:8px; background:rgba(0,0,0,.85); color:#fff; font-size:12px; font-weight:500; white-space:nowrap; pointer-events:none; z-index:5; }
.tal-core-hex { --hs:5.8cqw; --hb:#7aa3b8; --hf:#16384b; z-index:2; }
.tal-core-hex .tal-hex-in img { width:100%; height:100%; object-fit:cover; object-position:top; filter:grayscale(.7) brightness(.75); opacity:1; }
.tal-core-hex.is-on { --hb:#b9f23f; filter:drop-shadow(0 0 1.1cqw rgba(185,242,63,.7)); }
.tal-core-hex.is-on .tal-hex-in img { filter:none; }
.tal-core-hex:hover { transform:translate(-50%,-50%) scale(1.05); }
.tal-branch-label { position:absolute; transform:translate(-50%,-50%); display:inline-flex; align-items:center; gap:.4cqw; padding:.25cqw .7cqw .25cqw .3cqw; border-radius:980px; background:rgba(8,19,26,.7); color:#dfe9ee; font-size:max(10px,.8cqw); font-weight:600; white-space:nowrap; pointer-events:none; z-index:2; }
.tal-branch-label img { width:max(16px,1.3cqw); height:max(16px,1.3cqw); border-radius:50%; background:#e9eef0; padding:2px; object-fit:contain; }
.tal-branch-label.is-on { color:#d8f7a0; box-shadow:0 0 0 1px rgba(185,242,63,.45); }
.tal-info { display:grid; grid-template-columns:56px minmax(0,1fr) auto; gap:16px; align-items:center; margin-top:14px; padding:16px 18px; border-radius:20px; background:#1d1d1f; min-height:88px; }
.tal-info > .kc-note { grid-column:1 / -1; margin:0; }
.tal-info-ico { width:56px; height:56px; object-fit:contain; border-radius:14px; background:#17330f; padding:6px; }
.tal-info-text { display:grid; gap:4px; } .tal-info-text strong { font-size:17px; } .tal-info-text small { color:#a1a1a6; font-size:13px; }
.tal-info-text p { margin:0; color:#d6d6db; font-size:14px; line-height:1.45; } .tal-info .tal-info-next { color:#a1a1a6; }
.tal-info-btns { display:flex; gap:8px; } .tal-info-btns .kc-btn { width:44px; padding:0; justify-content:center; font-size:20px; }
@media(max-width:700px) { .tal-info { grid-template-columns:44px minmax(0,1fr); } .tal-info-btns { grid-column:1 / -1; justify-content:flex-end; } .tal-info-ico { width:44px; height:44px; } }
.tal-core-hex { --hs:4.7cqw; }
.tal-branch-label img { background:#0b1a24; box-shadow:0 0 0 1px rgba(255,255,255,.25); filter:brightness(1.4); }
@media(max-width:700px) { .tal-board { border-radius:18px; } .tal-board::after { content:'← листайте →'; position:sticky; left:0; display:block; width:100%; margin-top:-26px; padding-bottom:8px; text-align:center; font-size:11px; color:rgba(255,255,255,.45); pointer-events:none; } }

/* v8: new transparent hero banner + people fixes */
.hm-hero-art { max-width:1120px; margin:0 auto; }
.hm-hero-art img { aspect-ratio:1672/812; object-fit:contain; border-radius:0; filter:drop-shadow(0 30px 60px rgba(0,0,0,.55)); }
.hm-hero { gap:20px; padding-top:4px; }
@media(max-width:560px) { .hm-hero-art img { aspect-ratio:1672/812; } }
.hm-person { width:104px; }
.hm-person strong { font-size:13px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; max-width:100%; }
.hm-creators { display:grid; grid-template-columns:repeat(auto-fill,minmax(250px,1fr)); gap:12px; }
.hm-creator { display:grid; grid-template-columns:56px minmax(0,1fr); gap:14px; align-items:center; padding:14px 16px; border-radius:20px; background:var(--ap-tile); }
.hm-creator-img { width:56px; height:56px; border-radius:50%; object-fit:cover; background:var(--ap-tile-2); }
.hm-creator strong { display:block; font-size:16px; font-weight:600; letter-spacing:-.01em; }
.hm-creator span { display:-webkit-box; -webkit-line-clamp:3; -webkit-box-orient:vertical; overflow:hidden; margin-top:3px; font-size:13px; line-height:1.35; color:var(--ap-text-2); }
.hm-creator.is-lead { grid-column:span 2; grid-template-columns:72px minmax(0,1fr); padding:18px 20px; box-shadow:inset 0 0 0 1.5px rgba(226,181,91,.5); }
.hm-creator.is-lead .hm-creator-img { width:72px; height:72px; }
.hm-creator.is-lead strong { font-size:19px; }
@media(max-width:620px) { .hm-creator.is-lead { grid-column:auto; } .hm-creators { grid-template-columns:1fr; } }
.hm-creators { grid-template-columns:repeat(auto-fill,minmax(300px,1fr)); }
.hm-creators.is-leads { grid-template-columns:repeat(2,minmax(0,1fr)); margin-bottom:12px; }
.hm-creator.is-lead { grid-column:auto; }
@media(max-width:620px) { .hm-creators.is-leads { grid-template-columns:1fr; } }
.hm-hero-art img { -webkit-mask-image:linear-gradient(90deg,transparent 0,#000 7%,#000 93%,transparent 100%); mask-image:linear-gradient(90deg,transparent 0,#000 7%,#000 93%,transparent 100%); }
.hm-hero h1 { font-size:clamp(40px,6vw,72px); }

/* v10: new hero badge */
.kc-new-badge{display:inline-block;margin-left:8px;padding:2px 8px;border-radius:999px;background:#e2b55b;color:#1d1d1f;font-size:11px;font-weight:700;line-height:1.5;vertical-align:middle;letter-spacing:.01em}

/* v11: full-bleed painted banner */
.hm-hero-art { max-width:1200px; margin:0 auto; }
.hm-hero-art img { aspect-ratio:1672/941; object-fit:cover; border-radius:28px; filter:none; -webkit-mask-image:none; mask-image:none; box-shadow:0 30px 80px rgba(0,0,0,.55), 0 0 0 1px rgba(255,255,255,.06); }
@media(max-width:560px) { .hm-hero-art img { aspect-ratio:1672/941; border-radius:18px; } }

/* v12: wide YouTube-style channel banner */
.hm-hero-art { max-width:1280px; margin:0 auto; }
.hm-hero-art img { aspect-ratio:1707/282; object-fit:cover; border-radius:16px; box-shadow:0 20px 60px rgba(0,0,0,.5), 0 0 0 1px rgba(255,255,255,.06); }
@media(max-width:760px) { .hm-hero-art img { aspect-ratio:900/282; border-radius:12px; } }

/* v13: edge-to-edge banner */
html, body { overflow-x:clip; }
.hm, .kc-main, main { overflow:visible; }
.hm-hero { padding-top:0 !important; }
.hm-hero-art { position:relative; max-width:none; width:100vw; margin-left:calc(50% - 50vw); margin-right:calc(50% - 50vw); margin-top:calc(-1 * var(--hm-top, 0px)); }
.hm-hero-art img { width:100%; height:auto; aspect-ratio:1707/282; min-height:220px; object-fit:cover; object-position:center; border-radius:0; box-shadow:none; -webkit-mask-image:linear-gradient(180deg,#000 0,#000 72%,transparent 100%); mask-image:linear-gradient(180deg,#000 0,#000 72%,transparent 100%); }
@media(max-width:760px) { .hm-hero-art img { aspect-ratio:900/282; min-height:0; border-radius:0; } }

.kc-main:has(.hm-hero) { padding-top:0 !important; }

/* v14: pet calc hero picker */
.pb-panel.pc-battle-panel { overflow:visible; position:relative; z-index:5; }
.pb-hero-chip { position:relative; }
.pb-hero-menu, .pb-hero-chip:last-child .pb-hero-menu { left:0; right:auto; top:calc(100% + 8px); z-index:120; width:300px; max-width:calc(100vw - 32px); background:#1d1d1f; border:0; border-radius:18px; box-shadow:0 24px 70px rgba(0,0,0,.7), 0 0 0 1px rgba(255,255,255,.08); overflow:hidden; }
.pb-hero-menu > .kc-input { display:block; width:100%; height:46px; margin:0; padding:0 16px; background:#2c2c2e; color:#f5f5f7; border:0; border-radius:0; box-shadow:none; outline:none; font-size:15px; box-sizing:border-box; }
.pb-hero-menu > .kc-input:focus { box-shadow:inset 0 -2px 0 #e2b55b; }
.pb-hero-menu .pb-picker-list { max-height:min(360px,55vh); padding:6px; background:#1d1d1f; scrollbar-width:thin; scrollbar-color:#48484a transparent; }
.pb-hero-menu .pb-picker-list::-webkit-scrollbar { width:8px; }
.pb-hero-menu .pb-picker-list::-webkit-scrollbar-track { background:transparent; }
.pb-hero-menu .pb-picker-list::-webkit-scrollbar-thumb { background:#48484a; border-radius:8px; }
.pb-hero-menu .pb-picker-option { border-radius:12px; color:#f5f5f7; font-size:14px; }
.pb-hero-menu .pb-picker-option:hover, .pb-hero-menu .pb-picker-option:focus-visible { background:#2c2c2e; }
.pb-hero-menu .pb-picker-option[aria-pressed="true"] { background:#2c2c2e; color:#e2b55b; box-shadow:inset 0 0 0 1.5px rgba(226,181,91,.6); }
@media(max-width:620px) { .pb-hero-chip { position:static; } .pb-hero-menu, .pb-hero-chip:last-child .pb-hero-menu { left:12px; right:12px; width:auto; } }

/* v15: dark native scrollbars everywhere + bigger pet picker */
:root, html { color-scheme:dark; }
* { scrollbar-color:#48484a transparent; }
::-webkit-scrollbar { width:10px; height:10px; }
::-webkit-scrollbar-track { background:transparent; }
::-webkit-scrollbar-thumb { background:#3a3a3c; border-radius:10px; border:2px solid transparent; background-clip:padding-box; }
::-webkit-scrollbar-thumb:hover { background:#545456; background-clip:padding-box; }
.pb-picker-list { scrollbar-width:thin; }
.pc-pet .pb-picker { width:min(640px,calc(100vw - 32px)); border-radius:24px; z-index:130; }
.pc-pet .pb-picker > .kc-input { height:54px; font-size:16px; padding:0 20px; }
.pc-pet .pb-picker-list { grid-template-columns:repeat(4,minmax(0,1fr)); gap:8px; max-height:min(620px,72vh); padding:12px; background:#1d1d1f; }
.pc-pet .pb-picker-option { padding:12px 6px; font-size:13px; }
.pc-pet .pb-picker-option img { width:72px; height:72px; border-radius:18px; }
@media(max-width:620px) { .pc-pet .pb-picker-list { grid-template-columns:repeat(3,minmax(0,1fr)); } .pc-pet .pb-picker-option img { width:58px; height:58px; } }

.pc-left { z-index:20; }
@media(max-width:1100px) { .pc-left { position:relative; top:auto; } }
.pc-right { position:relative; z-index:1; }
.pc-left:has(.pb-picker:not([hidden])) .pc-pet { z-index:30; position:relative; }
