/* Расы и классы — [race_class] */
.rc {
	--fa: #4f8edc;
	--fh: #d9534f;
	--fah: var(--gold);
	margin: 28px 0;
	padding: 20px;
	border: 1px solid var(--border-2);
	border-radius: var(--radius);
	background: radial-gradient(120% 70% at 50% 0%, rgba(201, 162, 74, .08), transparent 60%), var(--surface);
	box-shadow: var(--shadow);
}
.entry-content .rc ul { margin: 0; padding: 0; list-style: none; }
.entry-content .rc li { margin: 0; }
.entry-content .rc p { margin: 0; }
.rc button { font-family: var(--font-body); }
.rc [disabled] { cursor: default; }
.rc button:focus-visible { outline: 2px solid var(--gold-2); outline-offset: 1px; }

/* Панель */
.rc-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 20px; margin-bottom: 14px; }
.rc-seg { display: flex; border: 1px solid var(--border-2); border-radius: var(--radius-sm); overflow: hidden; }
.rc-seg__btn { padding: 9px 16px; border: 0; background: var(--surface-2); color: var(--text-2); font-weight: 600; font-size: 14px; cursor: pointer; }
.rc-seg__btn + .rc-seg__btn { border-left: 1px solid var(--border-2); }
.rc-seg__btn[aria-pressed="true"] { background: var(--gold-dim); color: var(--gold-2); }
.rc-seg__btn--a[aria-pressed="true"] { background: color-mix(in srgb, var(--fa) 30%, var(--surface-2)); color: #fff; }
.rc-seg__btn--h[aria-pressed="true"] { background: color-mix(in srgb, var(--fh) 30%, var(--surface-2)); color: #fff; }
.rc-legend { display: flex; flex-wrap: wrap; gap: 6px 14px; color: var(--muted); font-size: 13px; }
.rc-m { display: inline-grid; place-items: center; min-width: 20px; height: 20px; padding: 0 3px; border-radius: 4px; font-size: 12px; }
.rc-m--y { background: rgba(255, 255, 255, .06); color: var(--text-2); }
.rc-m--n { background: rgba(79, 209, 122, .16); color: var(--heal); }

/* Таблица */
.rc-scroll { position: relative; /* иначе скрытые подписи клеток (position: absolute) вылезают за прокрутку и растягивают страницу */ overflow-x: auto; margin: 0 -4px; padding: 0 4px; -webkit-overflow-scrolling: touch; }
.entry-content .rc-table { width: 100%; margin: 0; border-collapse: separate; border-spacing: 0; font-size: 14px; display: table; overflow: visible; }
.entry-content .rc-table th, .entry-content .rc-table td { padding: 0; border: 0; border-bottom: 1px solid var(--border); background: none; vertical-align: middle; text-align: center; }
.rc-table thead th { vertical-align: bottom !important; }
.rc-corner { text-align: left !important; padding: 0 8px 8px 0 !important; color: var(--muted) !important; font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; }
.rc-race { width: 48px; height: 132px; border-bottom: 2px solid var(--c) !important; }
.rc-race--a { --c: var(--fa); }
.rc-race--h { --c: var(--fh); }
.rc-race--ah { --c: var(--fah); }
.rc-race__btn {
	writing-mode: vertical-rl;
	transform: rotate(180deg);
	padding: 8px 0;
	border: 0; background: none;
	color: var(--text);
	font-size: 14px; font-weight: 600;
	white-space: nowrap;
	cursor: pointer;
}
.rc-race__btn:hover, .rc-race.is-sel .rc-race__btn { color: var(--gold-2); }
.rc-best-h { padding: 0 0 8px 12px !important; text-align: left !important; color: var(--muted) !important; font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; line-height: 1.3; }
.rc-best-h span { display: block; text-transform: none; letter-spacing: 0; font-weight: 400; }

.rc-class { position: sticky; left: 0; z-index: 1; padding-right: 12px !important; background: var(--surface) !important; text-align: left !important; white-space: nowrap; } /* отступ — чтобы длинное название класса не касалось первой клетки на любом шрифте */
.rc-class__btn { display: flex; width: max-content; align-items: center; gap: 8px; padding: 7px 10px 7px 0; border: 0; background: none; color: var(--cc); font-size: 14px; font-weight: 700; text-align: left; white-space: nowrap; cursor: pointer; }
.rc-class__btn img { width: 24px; height: 24px; border-radius: 5px; border: 1px solid var(--cc); }
.rc-class__btn:hover span, tr.is-sel .rc-class__btn span { text-decoration: underline; text-underline-offset: 3px; }

.rc-cell__btn {
	display: inline-grid; place-items: center;
	width: 34px; height: 30px;
	border: 1px solid transparent; border-radius: 6px;
	background: rgba(255, 255, 255, .05);
	color: var(--text-2);
	font-size: 15px; font-weight: 700;
	cursor: pointer;
	transition: background .12s, border-color .12s;
}
.rc-cell--n .rc-cell__btn { background: rgba(79, 209, 122, .16); color: var(--heal); }
.rc-cell__btn:hover { border-color: var(--gold); }
.rc-cell__btn.is-sel { border-color: var(--gold-2); background: var(--gold); color: #17120a; box-shadow: 0 0 10px rgba(233, 201, 119, .45); }
.rc-no { color: var(--border-2); }
.rc-table tbody tr:hover td, .rc-table tbody tr:hover .rc-class { background: rgba(255, 255, 255, .02) !important; }
.rc-table tbody tr:hover .rc-class { background: color-mix(in srgb, #fff 2%, var(--surface)) !important; }

.rc-best { padding-left: 12px !important; text-align: left !important; white-space: nowrap; }
.rc-best__i { display: inline-block; margin: 2px 4px 2px 0; padding: 2px 8px; border-radius: 99px; font-size: 12px; font-weight: 600; white-space: nowrap; }
.rc-best__i--a { background: color-mix(in srgb, var(--fa) 22%, transparent); color: #a9c8f2; }
.rc-best__i--h { background: color-mix(in srgb, var(--fh) 22%, transparent); color: #f0aaa8; }
.rc-best__i--ah { background: var(--gold-dim); color: var(--gold-2); }
.rc-best__none { color: var(--muted); font-size: 13px; }

.rc-swipe { display: none; margin: 8px 0 0 !important; color: var(--muted); font-size: 13px; }

/* Фильтр фракции */
.rc[data-faction="a"] .rc-table [data-f="h"], .rc[data-faction="h"] .rc-table [data-f="a"] { display: none; } /* только в таблице — не кнопки фильтра */

/* Карточка */
.rc-detail { margin-top: 18px; padding-top: 18px; border-top: 1px solid var(--border); }
.rc-hint { color: var(--muted); font-size: 15px; }
.rc-card__head { display: flex; align-items: center; gap: 12px; }
.rc-card__icon { width: 44px; height: 44px; border-radius: 8px; border: 2px solid var(--cc, var(--gold)); flex-shrink: 0; }
.rc-card__title { font: 400 clamp(22px, 3.6vw, 28px)/1.15 var(--font-head); color: var(--gold-2); }
.rc-card__meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; margin-top: 4px; color: var(--muted); font-size: 14px; }
.rc-badge { display: inline-block; padding: 1px 8px; border-radius: 99px; font-size: 12px; font-weight: 700; }
.rc-badge--new { background: rgba(79, 209, 122, .16); color: var(--heal); }
.rc-badge--a { background: color-mix(in srgb, var(--fa) 25%, transparent); color: #a9c8f2; }
.rc-badge--h { background: color-mix(in srgb, var(--fh) 25%, transparent); color: #f0aaa8; }
.rc-badge--ah { background: var(--gold-dim); color: var(--gold-2); }
.rc-badge--no { background: rgba(255, 255, 255, .06); color: var(--muted); }
.rc-card__note { margin-top: 10px !important; color: var(--text-2); line-height: 1.55; }
.rc-sec { margin-top: 16px; }
.rc-sec__title { margin-bottom: 8px; color: var(--muted); font-size: 13px; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; }
.rc-racials { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 8px; }
.rc-racials li { padding: 10px 12px; border-radius: var(--radius-sm); background: var(--surface-2); font-size: 14px; line-height: 1.45; color: var(--text-2); }
.rc-racials li a { display: inline-block; margin-bottom: 2px; font-weight: 700; }
.rc-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.rc-chip { display: inline-flex; align-items: center; gap: 6px; padding: 5px 10px; border: 1px solid var(--border-2); border-radius: 99px; background: var(--surface-2); color: var(--text); font-size: 14px; font-weight: 600; cursor: pointer; }
.rc-chip:hover { border-color: var(--gold); }
.rc-chip img { width: 18px; height: 18px; border-radius: 4px; }
.rc-chip--new { border-color: rgba(79, 209, 122, .45); }
.rc-chip i { font-style: normal; color: var(--heal); font-size: 12px; }
.rc-verdicts { display: grid; gap: 8px; }
.rc-verdict { padding: 12px 14px; border-radius: var(--radius-sm); background: var(--surface-2); }
.rc-verdict__head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 12px; }
.rc-verdict__title { font-weight: 700; color: var(--text); }
.rc-verdict__place { color: var(--gold-2); font-size: 13px; font-weight: 700; }
.rc-verdict__text { margin-top: 6px !important; color: var(--text-2); font-size: 14px; line-height: 1.5; }
.rc-verdict a.rc-verdict__more { display: inline-block; margin-top: 6px; color: var(--gold-2); font-size: 14px; font-weight: 600; text-decoration: none; }
.rc-rank { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.rc-rank button { padding: 3px 9px; border: 1px solid var(--border-2); border-radius: 99px; background: var(--surface); color: var(--text-2); font-size: 13px; cursor: pointer; }
.rc-rank button:hover { border-color: var(--gold); color: #fff; }
.rc-rank b { color: var(--muted); font-weight: 600; margin-right: 3px; }
.rc-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.rc-actions .btn { padding: 8px 14px; font-size: 14px; }
.entry-content .rc a.btn { color: #17120a; text-decoration: none; }
.entry-content .rc a.btn--ghost { color: var(--gold-2); }

@media (max-width: 720px) {
	.rc { padding: 16px 12px; }
	.rc-race { width: 40px; height: 120px; }
	.rc-cell__btn { width: 30px; }
	.rc-class__btn { font-size: 13px; padding-right: 0; }
	.rc-class__btn img { width: 20px; height: 20px; }
	.rc-class { padding-right: 8px !important; box-shadow: 6px 0 8px -6px rgba(0, 0, 0, .7); }
	.rc-swipe { display: block; }
}
