/*
Theme Name: RAIN.LV Roleplay
Theme URI: https://rain.lv
Author: RAIN.LV
Description: Dark & red SA:MP roleplay landing theme with live server status, player count, player list and a clean news feed (no categories, no comments).
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 7.4
License: GPL-2.0-or-later
Text Domain: rainlv
*/

:root {
	--bg: #0a0a0c;
	--bg-2: #111114;
	--panel: #15151a;
	--panel-2: #1b1b21;
	--line: #2a2a31;
	--text: #e9e7ea;
	--muted: #8d8a93;
	--red: #e1182e;
	--red-2: #ff3348;
	--red-dark: #7a0b17;
	--green: #2fd36b;
	--radius: 10px;
	--shadow: 0 20px 60px rgba(0, 0, 0, .55);
	--display: "Bebas Neue", "Oswald", Impact, sans-serif;
	--body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
	--mono: "JetBrains Mono", ui-monospace, Consolas, monospace;
}

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

html { scroll-behavior: smooth; }

body {
	margin: 0;
	background: var(--bg);
	color: var(--text);
	font-family: var(--body);
	font-size: 16px;
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
	overflow-x: hidden;
}

/* ---------- Scrollbars ---------- */
/* Firefox + modern Chrome/Edge (inherited, so this covers inner scroll areas too). */
html { scrollbar-color: var(--red-dark) var(--bg); scrollbar-width: thin; }

/* Safari and older Chrome/Edge. */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb {
	background: linear-gradient(180deg, var(--red-dark), #5a0811);
	border: 2px solid var(--bg); border-radius: 99px;
}
::-webkit-scrollbar-thumb:hover { background: var(--red); }
::-webkit-scrollbar-thumb:active { background: var(--red-2); }
::-webkit-scrollbar-corner { background: var(--bg); }

/* Inner panels sit on a lighter background, so match their track to it. */
.player-list, .ucp-card, .entry pre { scrollbar-color: var(--red-dark) var(--panel); }
.player-list::-webkit-scrollbar-track, .ucp-card ::-webkit-scrollbar-track, .entry pre::-webkit-scrollbar-track { background: var(--panel); }
.player-list::-webkit-scrollbar-thumb, .ucp-card ::-webkit-scrollbar-thumb, .entry pre::-webkit-scrollbar-thumb { border-color: var(--panel); }

a { color: var(--red-2); text-decoration: none; transition: color .2s; }
a:hover { color: #fff; }
img { max-width: 100%; height: auto; display: block; }

.screen-reader-text {
	position: absolute !important; width: 1px; height: 1px;
	overflow: hidden; clip: rect(1px, 1px, 1px, 1px); white-space: nowrap;
}

.container { width: min(1200px, 100% - 32px); margin-inline: auto; }

/* ---------- Rain canvas & noise ---------- */
#rl-rain {
	position: fixed; inset: 0; z-index: 0; pointer-events: none; opacity: .55;
}
.site { position: relative; z-index: 1; }

/* ---------- Header ---------- */
.site-header {
	position: sticky; top: 0; z-index: 50;
	background: rgba(10, 10, 12, .82);
	backdrop-filter: blur(10px);
	border-bottom: 1px solid var(--line);
}
.site-header::after {
	content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 1px;
	background: linear-gradient(90deg, transparent, var(--red), transparent);
}
.header-inner {
	display: flex; align-items: center; justify-content: space-between;
	gap: 16px; min-height: 68px;
}
.brand {
	font-family: var(--display); font-size: 34px; letter-spacing: 2px;
	color: #fff; line-height: 1; display: flex; align-items: center;
}
.brand span { color: var(--red); }
.brand .custom-logo { max-height: 44px; width: auto; }

.main-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 4px; }
.main-nav a {
	display: block; padding: 8px 14px; color: var(--muted);
	font-family: var(--display); font-size: 20px; letter-spacing: 1.5px;
	border-radius: 6px;
}
.main-nav a:hover { color: #fff; background: var(--panel-2); }

.nav-toggle {
	display: none; background: none; border: 1px solid var(--line); color: #fff;
	width: 44px; height: 44px; border-radius: 8px; cursor: pointer;
}
.nav-toggle span, .nav-toggle span::before, .nav-toggle span::after {
	display: block; width: 20px; height: 2px; background: #fff; margin: auto; position: relative; content: "";
}
.nav-toggle span::before { position: absolute; top: -6px; }
.nav-toggle span::after { position: absolute; top: 6px; }

.header-status {
	display: flex; align-items: center; gap: 8px;
	font-family: var(--mono); font-size: 13px; color: var(--muted);
	padding: 6px 12px; border: 1px solid var(--line); border-radius: 999px; background: var(--bg-2);
}

/* ---------- Status dot ---------- */
.dot {
	width: 9px; height: 9px; border-radius: 50%; background: var(--muted); flex: none;
}
.is-online .dot { background: var(--green); box-shadow: 0 0 0 0 rgba(47, 211, 107, .7); animation: pulse 2s infinite; }
.is-offline .dot { background: var(--red); }
@keyframes pulse {
	0% { box-shadow: 0 0 0 0 rgba(47, 211, 107, .6); }
	70% { box-shadow: 0 0 0 10px rgba(47, 211, 107, 0); }
	100% { box-shadow: 0 0 0 0 rgba(47, 211, 107, 0); }
}

/* ---------- Buttons ---------- */
.btn {
	display: inline-flex; align-items: center; justify-content: center; gap: 10px;
	padding: 14px 26px; border-radius: 8px; border: 1px solid transparent;
	font-family: var(--display); font-size: 22px; letter-spacing: 1.5px; line-height: 1;
	cursor: pointer; transition: transform .15s, background .2s, border-color .2s, color .2s;
}
.btn:active { transform: translateY(1px); }
.btn-primary {
	background: linear-gradient(180deg, var(--red-2), var(--red));
	color: #fff; box-shadow: 0 10px 30px rgba(225, 24, 46, .35);
}
.btn-primary:hover { color: #fff; background: linear-gradient(180deg, #ff4b5e, var(--red-2)); }
.btn-ghost { background: transparent; color: #fff; border-color: var(--line); }
.btn-ghost:hover { border-color: var(--red); color: #fff; }

/* ---------- Hero ---------- */
.hero {
	position: relative; padding: 110px 0 90px; overflow: hidden;
	border-bottom: 1px solid var(--line);
}
.hero::before {
	content: ""; position: absolute; inset: 0; z-index: -1;
	background:
		radial-gradient(60% 70% at 70% 20%, rgba(225, 24, 46, .28), transparent 60%),
		radial-gradient(40% 50% at 10% 90%, rgba(122, 11, 23, .45), transparent 70%),
		linear-gradient(180deg, #0d0d10, var(--bg));
}
/* Optional background image (Customizer → SA:MP Server). Gradients stay on top. */
.hero.has-image::before {
	background:
		radial-gradient(60% 70% at 70% 20%, rgba(225, 24, 46, .28), transparent 60%),
		radial-gradient(40% 50% at 10% 90%, rgba(122, 11, 23, .45), transparent 70%),
		linear-gradient(90deg, rgba(10, 10, 12, .55), transparent 70%),
		linear-gradient(180deg,
			rgba(13, 13, 16, var(--hero-dim, .7)) 0%,
			rgba(10, 10, 12, var(--hero-dim, .7)) 65%,
			var(--bg) 100%),
		var(--hero-img) center / cover no-repeat,
		var(--bg);
}
.hero::after {
	content: ""; position: absolute; inset: 0; z-index: -1; opacity: .07;
	background-image: repeating-linear-gradient(0deg, #fff 0 1px, transparent 1px 4px);
}
.hero-grid { display: grid; grid-template-columns: 1.25fr 1fr; gap: 48px; align-items: center; }

.eyebrow {
	display: inline-flex; align-items: center; gap: 10px;
	font-family: var(--mono); font-size: 13px; letter-spacing: 2px; text-transform: uppercase;
	color: var(--red-2); margin-bottom: 18px;
}
.eyebrow::before { content: ""; width: 34px; height: 2px; background: var(--red); }

.hero-title {
	font-family: var(--display); font-weight: 400;
	font-size: clamp(64px, 11vw, 150px); line-height: .85; letter-spacing: 3px;
	margin: 0 0 18px; color: #fff;
	text-shadow: 0 0 40px rgba(225, 24, 46, .35);
}
.hero-title .accent { color: var(--red); display: inline-block; }
.hero-title .sub {
	display: block; font-size: .32em; letter-spacing: 10px; color: var(--muted); margin-top: 10px;
}
.hero-text { font-size: 18px; color: #c9c6cc; max-width: 560px; margin: 0 0 30px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 26px; }

.connect-box {
	display: inline-flex; align-items: stretch; border: 1px solid var(--line);
	border-radius: 8px; overflow: hidden; background: var(--bg-2); max-width: 100%;
}
.connect-box .label {
	padding: 12px 14px; font-family: var(--mono); font-size: 12px; color: var(--muted);
	text-transform: uppercase; letter-spacing: 1.5px; border-right: 1px solid var(--line);
	display: flex; align-items: center;
}
.connect-box code {
	padding: 12px 16px; font-family: var(--mono); font-size: 16px; color: #fff;
	display: flex; align-items: center; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.connect-box button {
	border: 0; border-left: 1px solid var(--line); background: var(--panel-2); color: #fff;
	padding: 0 18px; cursor: pointer; font-family: var(--display); font-size: 18px; letter-spacing: 1px;
}
.connect-box button:hover { background: var(--red); }

/* ---------- Status card ---------- */
.status-card {
	background: linear-gradient(180deg, var(--panel), var(--bg-2));
	border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow);
	position: relative; overflow: hidden;
}
.status-card::before {
	content: ""; position: absolute; top: 0; left: 0; right: 0; height: 3px;
	background: linear-gradient(90deg, var(--red-dark), var(--red), var(--red-dark));
}
.status-head {
	display: flex; align-items: center; justify-content: space-between; gap: 12px;
	padding: 20px 22px; border-bottom: 1px solid var(--line);
}
.status-head h2 { margin: 0; font-family: var(--display); font-weight: 400; font-size: 28px; letter-spacing: 2px; }
.status-pill {
	display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border-radius: 999px;
	font-family: var(--mono); font-size: 12px; text-transform: uppercase; letter-spacing: 1.5px;
	background: var(--bg); border: 1px solid var(--line);
}
.is-online .status-pill { color: var(--green); border-color: rgba(47, 211, 107, .35); }
.is-offline .status-pill { color: var(--red-2); border-color: rgba(225, 24, 46, .4); }

.status-body { padding: 22px; }
.players-big {
	display: flex; align-items: baseline; gap: 10px; margin-bottom: 12px;
	font-family: var(--display); letter-spacing: 2px;
}
.players-big .now { font-size: 72px; line-height: .9; color: #fff; }
.players-big .max { font-size: 30px; color: var(--muted); }
.players-big .lbl { margin-left: auto; font-family: var(--mono); font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: 1.5px; }

.bar { height: 8px; background: var(--bg); border-radius: 99px; overflow: hidden; border: 1px solid var(--line); margin-bottom: 22px; }
.bar > i {
	display: block; height: 100%; width: 0;
	background: linear-gradient(90deg, var(--red-dark), var(--red), var(--red-2));
	box-shadow: 0 0 18px rgba(225, 24, 46, .7); transition: width .8s ease;
}

.stat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.stat {
	background: var(--bg); border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px; min-width: 0;
}
.stat dt { font-family: var(--mono); font-size: 11px; text-transform: uppercase; letter-spacing: 1.5px; color: var(--muted); margin: 0 0 4px; }
.stat dd { margin: 0; font-weight: 600; color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.status-foot {
	display: flex; justify-content: space-between; align-items: center; gap: 10px;
	padding: 14px 22px; border-top: 1px solid var(--line);
	font-family: var(--mono); font-size: 12px; color: var(--muted);
}
.refresh-btn { background: none; border: 0; color: var(--muted); cursor: pointer; font: inherit; padding: 0; }
.refresh-btn:hover { color: var(--red-2); }
.refresh-btn.spin svg { animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Sections ---------- */
.section { padding: 90px 0; position: relative; }
.section + .section { padding-top: 0; }
.hero-grid.is-single { grid-template-columns: 1fr; max-width: 820px; }
.cta h2 span { color: var(--red); }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 36px; flex-wrap: wrap; }
.section-title {
	font-family: var(--display); font-weight: 400; font-size: clamp(42px, 6vw, 64px);
	letter-spacing: 2px; line-height: .95; margin: 0; color: #fff;
}
.section-title span { color: var(--red); }

/* ---------- Steps ---------- */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.step {
	background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
	padding: 28px; position: relative; overflow: hidden; transition: border-color .2s, transform .2s;
}
.step:hover { border-color: var(--red-dark); transform: translateY(-3px); }
.step .num {
	font-family: var(--display); font-size: 90px; line-height: .8; color: transparent;
	-webkit-text-stroke: 1px var(--red); position: absolute; right: 18px; top: 16px; opacity: .5;
}
.step h3 { font-family: var(--display); font-weight: 400; font-size: 28px; letter-spacing: 1.5px; margin: 0 0 8px; color: #fff; }
.step p { margin: 0; color: var(--muted); }

/* ---------- Player list ---------- */
.players-panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.players-toolbar { display: flex; gap: 12px; padding: 14px; border-bottom: 1px solid var(--line); }
.players-toolbar input {
	flex: 1; background: var(--bg); border: 1px solid var(--line); color: #fff;
	border-radius: 8px; padding: 10px 14px; font: inherit; min-width: 0;
}
.players-toolbar input:focus { outline: none; border-color: var(--red); }
.player-list {
	list-style: none; margin: 0; padding: 0; max-height: 420px; overflow: auto;
	display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
}
.player-list li {
	display: flex; justify-content: space-between; gap: 10px; padding: 11px 16px;
	border-bottom: 1px solid var(--line); border-right: 1px solid var(--line);
	font-family: var(--mono); font-size: 14px;
}
.player-list li .name { color: #fff; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.player-list li .score { color: var(--red-2); flex: none; }
.player-list .empty { color: var(--muted); grid-column: 1 / -1; justify-content: center; padding: 30px; border-right: 0; }

/* ---------- News ---------- */
.news-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.post-card {
	background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
	overflow: hidden; display: flex; flex-direction: column; transition: border-color .2s, transform .2s;
}
.post-card:hover { border-color: var(--red-dark); transform: translateY(-4px); }
.post-card .thumb {
	aspect-ratio: 16 / 9; background: linear-gradient(135deg, var(--red-dark), #1a0508 60%, var(--bg-2));
	position: relative; overflow: hidden;
}
.post-card .thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; filter: saturate(.9) contrast(1.05); }
.post-card:hover .thumb img { transform: scale(1.05); }
.post-card .thumb .placeholder {
	position: absolute; inset: 0; display: grid; place-items: center;
	font-family: var(--display); font-size: 46px; letter-spacing: 3px; color: rgba(255, 255, 255, .12);
}
.post-card .body { padding: 22px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.post-date { font-family: var(--mono); font-size: 12px; color: var(--red-2); text-transform: uppercase; letter-spacing: 1.5px; }
.post-card h3 { margin: 0; font-size: 21px; line-height: 1.3; }
.post-card h3 a { color: #fff; }
.post-card h3 a:hover { color: var(--red-2); }
.post-card p { margin: 0; color: var(--muted); font-size: 15px; }
.post-card .more { margin-top: auto; padding-top: 8px; font-family: var(--display); font-size: 18px; letter-spacing: 1.5px; }

.post-card.featured { grid-column: span 2; flex-direction: row; }
.post-card.featured .thumb { aspect-ratio: auto; flex: 1.2; min-height: 300px; }
.post-card.featured .body { flex: 1; padding: 30px; justify-content: center; }
.post-card.featured h3 { font-size: 30px; }

.no-posts { color: var(--muted); padding: 40px; border: 1px dashed var(--line); border-radius: var(--radius); text-align: center; }

/* ---------- Discord ---------- */
.header-discord {
	display: grid; place-items: center; width: 40px; height: 40px; flex: none;
	border: 1px solid var(--line); border-radius: 999px; background: var(--bg-2); color: var(--muted);
	transition: color .2s, border-color .2s, background .2s;
}
.header-discord:hover { color: #fff; background: #5865f2; border-color: #5865f2; }
.header-inner .main-nav { margin-inline: auto; }

.discord-band {
	display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 28px;
	padding: 34px 38px; border: 1px solid var(--line); border-radius: 14px; position: relative; overflow: hidden;
	background:
		radial-gradient(60% 140% at 0% 50%, rgba(225, 24, 46, .22), transparent 70%),
		radial-gradient(40% 120% at 100% 50%, rgba(88, 101, 242, .16), transparent 70%),
		var(--panel);
}
.discord-band::before {
	content: ""; position: absolute; top: 0; left: 0; right: 0; height: 3px;
	background: linear-gradient(90deg, var(--red-dark), var(--red), #5865f2);
}
.discord-logo {
	width: 86px; height: 86px; border-radius: 22px; display: grid; place-items: center; color: #fff;
	background: linear-gradient(135deg, var(--red), var(--red-dark)); box-shadow: 0 14px 34px rgba(225, 24, 46, .35);
}
.discord-logo svg { width: 46px; height: 46px; }
.discord-text h2 {
	font-family: var(--display); font-weight: 400; font-size: clamp(38px, 5vw, 56px);
	letter-spacing: 2px; line-height: .95; margin: 0 0 8px; color: #fff;
}
.discord-text h2 span { color: var(--red); }
.discord-text p { margin: 0; color: var(--muted); max-width: 560px; }
.discord-stats { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.discord-stats > span {
	display: inline-flex; align-items: center; gap: 8px; padding: 5px 12px; border-radius: 999px;
	border: 1px solid var(--line); background: var(--bg); font-family: var(--mono); font-size: 13px; color: #fff;
}
.btn-discord { background: #5865f2; color: #fff; box-shadow: 0 10px 30px rgba(88, 101, 242, .3); white-space: nowrap; }
.btn-discord:hover { background: #6d78f5; color: #fff; }

.footer-links { display: inline-flex; align-items: center; gap: 18px; }
.footer-links a { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); }
.footer-links a:hover { color: #fff; }
.footer-links svg { width: 18px; height: 18px; }

/* ---------- CTA ---------- */
.cta {
	border: 1px solid var(--line); border-radius: 14px; padding: 50px; text-align: center;
	background:
		radial-gradient(70% 120% at 50% 0%, rgba(225, 24, 46, .25), transparent 70%),
		var(--panel);
}
.cta h2 { font-family: var(--display); font-weight: 400; font-size: clamp(40px, 6vw, 70px); letter-spacing: 2px; margin: 0 0 10px; line-height: 1; }
.cta p { color: var(--muted); margin: 0 auto 26px; max-width: 560px; }
.cta .hero-actions { justify-content: center; margin: 0; }

/* ---------- Single / archive ---------- */
.page-hero { position: relative; padding: 80px 0 40px; border-bottom: 1px solid var(--line); }
/* Page header with a background image: picture under a dark + red overlay, like the homepage hero. */
.page-hero.has-bg {
	padding: 120px 0 56px;
	background:
		radial-gradient(ellipse 60% 90% at 0% 0%, rgba(225, 24, 46, .28), transparent 70%),
		linear-gradient(180deg, rgba(10, 10, 12, var(--page-hero-dim, .7)) 0%, rgba(10, 10, 12, calc(var(--page-hero-dim, .7) * .8 + .2)) 100%),
		var(--page-hero-img) center / cover no-repeat,
		var(--bg);
}
.page-hero.has-bg::after {
	content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 60px; pointer-events: none;
	background: linear-gradient(180deg, transparent, var(--bg));
}
.page-hero.has-bg .container { position: relative; z-index: 1; }
.page-hero.has-bg h1 { text-shadow: 0 6px 30px rgba(0, 0, 0, .6); }
/* Header switched off: keep a little space under the menu. */
.page-hero-gap { height: 36px; }
.page-hero h1 { font-family: var(--display); font-weight: 400; font-size: clamp(44px, 7vw, 84px); line-height: .95; letter-spacing: 2px; margin: 10px 0 0; color: #fff; }
.entry {
	max-width: 780px; margin: 0 auto; padding: 50px 0 90px; font-size: 18px; color: #d5d2d8;
}
.entry .featured-image { margin: 0 0 34px; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); }
.entry h2, .entry h3 { font-family: var(--display); font-weight: 400; letter-spacing: 1.5px; color: #fff; line-height: 1.1; }
.entry h2 { font-size: 40px; } .entry h3 { font-size: 30px; }
.entry blockquote { margin: 28px 0; padding: 14px 22px; border-left: 3px solid var(--red); background: var(--panel); border-radius: 0 8px 8px 0; color: #fff; }
.entry pre, .entry code { font-family: var(--mono); background: var(--panel); border-radius: 6px; }
.entry code { padding: 2px 6px; }
.entry pre { padding: 18px; overflow: auto; border: 1px solid var(--line); }
.entry img { border-radius: 8px; }
.entry table { width: 100%; border-collapse: collapse; }
.entry th, .entry td { border: 1px solid var(--line); padding: 10px; }
.back-link { display: inline-block; margin-top: 40px; font-family: var(--display); font-size: 20px; letter-spacing: 1.5px; }

.pagination { display: flex; justify-content: center; gap: 8px; margin-top: 40px; flex-wrap: wrap; }
.pagination .page-numbers {
	min-width: 44px; height: 44px; display: grid; place-items: center; padding: 0 12px;
	border: 1px solid var(--line); border-radius: 8px; color: #fff; background: var(--panel);
}
.pagination .page-numbers.current, .pagination .page-numbers:hover { background: var(--red); border-color: var(--red); color: #fff; }

/* ---------- Rules page (tabs) ---------- */
.rules { max-width: 920px; margin: 0 auto; padding: 50px 0 90px; font-size: 17px; color: #d5d2d8; }
.rules .featured-image { margin: 0 0 30px; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); }
.rules-content > p:first-child { font-size: 18px; color: #c9c6cc; }
.rules-content h2, .rules-content h3 { font-family: var(--display); font-weight: 400; letter-spacing: 1.5px; color: #fff; line-height: 1.05; }
.rules-content h2 { font-size: 40px; margin: 40px 0 16px; }
.rules-content h3 { font-size: 28px; margin: 28px 0 10px; color: var(--red-2); }
.rules-content a { text-decoration: underline; text-underline-offset: 3px; }
.rules-content blockquote { margin: 22px 0; padding: 14px 20px; border-left: 3px solid var(--red); background: var(--panel); border-radius: 0 8px 8px 0; color: #fff; }

/* Numbered rules with red number badges. */
.rules-content ol { list-style: none; counter-reset: rule; padding: 0; margin: 16px 0; display: grid; gap: 8px; }
.rules-content ol > li {
	counter-increment: rule; position: relative; padding: 12px 16px 12px 58px;
	background: var(--panel); border: 1px solid var(--line); border-radius: 8px;
}
.rules-content ol > li::before {
	content: counter(rule); position: absolute; left: 12px; top: 10px;
	width: 32px; height: 32px; display: grid; place-items: center; border-radius: 6px;
	background: var(--red-dark); color: #fff; font-family: var(--display); font-size: 20px; letter-spacing: 1px;
}
.rules-content ul { padding-left: 22px; }
.rules-content ul li::marker { color: var(--red); }
.rules-content li + li { margin-top: 4px; }
.rules-content ol > li + li { margin-top: 0; }

/* Tab buttons (built by main.js from the H2 headings). */
.rules-tabs {
	display: flex; flex-wrap: wrap; gap: 8px; margin: 26px 0 22px; padding: 8px;
	background: var(--bg-2); border: 1px solid var(--line); border-radius: 12px;
	position: sticky; top: 80px; z-index: 5;
}
.rules-tab {
	flex: 1 1 auto; padding: 12px 20px; border-radius: 8px; border: 1px solid transparent; background: transparent;
	color: var(--muted); cursor: pointer; font-family: var(--display); font-size: 22px; letter-spacing: 1.5px; line-height: 1;
	transition: color .2s, background .2s, border-color .2s;
}
.rules-tab:hover { color: #fff; background: var(--panel-2); }
.rules-tab.is-active {
	color: #fff; background: linear-gradient(180deg, var(--red-2), var(--red));
	box-shadow: 0 8px 24px rgba(225, 24, 46, .3);
}
.rules-tab:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.is-tabbed .rules-panel > h2:first-child { display: none; }  /* The tab button already shows the title. */
.rules-panel { animation: rules-in .25s ease; }
@keyframes rules-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.rules-updated { margin-top: 34px; color: var(--muted); font-family: var(--mono); font-size: 13px; }

/* ---------- Ban list ---------- */
.bans { padding: 46px 0 90px; }
.bans-intro { color: #c9c6cc; font-size: 17px; max-width: 760px; margin: 0 0 24px; }
.bans-toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 18px; }
.bans-tabs { display: flex; gap: 6px; padding: 6px; background: var(--bg-2); border: 1px solid var(--line); border-radius: 10px; }
.bans-tabs a {
	padding: 9px 18px; border-radius: 7px; color: var(--muted);
	font-family: var(--display); font-size: 20px; letter-spacing: 1.5px; line-height: 1;
}
.bans-tabs a:hover { color: #fff; background: var(--panel-2); }
.bans-tabs a.is-active { color: #fff; background: linear-gradient(180deg, var(--red-2), var(--red)); }
.bans-search { display: flex; gap: 8px; flex: 1 1 320px; max-width: 460px; min-width: 0; margin-left: auto; }
.bans-search input {
	flex: 1; width: 0; min-width: 0; background: var(--bg); border: 1px solid var(--line); color: #fff;
	border-radius: 8px; padding: 11px 14px; font: inherit;
}
.bans-search input:focus { outline: none; border-color: var(--red); }
.bans-search .btn { padding: 11px 20px; font-size: 19px; }
.bans-count { font-family: var(--mono); font-size: 12px; text-transform: uppercase; letter-spacing: 1.5px; color: var(--muted); margin: 0 0 10px; }

.bans-table-wrap { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); overflow-x: auto; }
.bans-table { width: 100%; border-collapse: collapse; font-size: 15px; }
.bans-table th {
	text-align: left; padding: 14px 18px; border-bottom: 1px solid var(--line); background: var(--bg-2);
	font-family: var(--mono); font-size: 11px; font-weight: 400; text-transform: uppercase; letter-spacing: 1.5px; color: var(--muted);
}
.bans-table td { padding: 13px 18px; border-bottom: 1px solid var(--line); color: #e3e0e6; vertical-align: top; }
.bans-table tbody tr:last-child td { border-bottom: 0; }
.bans-table tbody tr:hover td { background: rgba(255, 255, 255, .02); }
.bans-name { font-family: var(--mono); color: #fff; font-weight: 600; }
.bans-left { display: block; color: var(--red-2); font-family: var(--mono); font-size: 12px; margin-top: 2px; }
.bans-badge {
	display: inline-block; padding: 3px 10px; border-radius: 999px; font-family: var(--mono); font-size: 11px;
	text-transform: uppercase; letter-spacing: 1.2px; border: 1px solid var(--line);
}
.bans-badge.is-perm { color: var(--red-2); border-color: rgba(225, 24, 46, .45); background: rgba(225, 24, 46, .08); }
.pagination .page-numbers.dots { background: none; border-color: transparent; }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line); background: var(--bg-2); padding: 34px 0; }
.footer-inner { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; color: var(--muted); font-size: 14px; }
.footer-inner .brand { font-size: 26px; }

/* ---------- Toast ---------- */
.rl-toast {
	position: fixed; left: 50%; bottom: 26px; transform: translate(-50%, 20px); opacity: 0;
	background: var(--red); color: #fff; padding: 12px 20px; border-radius: 8px; z-index: 100;
	font-family: var(--display); font-size: 20px; letter-spacing: 1.5px; transition: .25s; pointer-events: none;
}
.rl-toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
	.hero-grid { grid-template-columns: 1fr; }
	.news-grid { grid-template-columns: 1fr 1fr; }
	.post-card.featured { grid-column: 1 / -1; }
	.steps { grid-template-columns: 1fr; }
	.header-status { display: none; }
	.discord-band { grid-template-columns: auto 1fr; }
	.discord-band .btn-discord { grid-column: 1 / -1; justify-self: start; }
}
@media (max-width: 760px) {
	.nav-toggle { display: grid; place-items: center; }
	.main-nav {
		position: absolute; top: 100%; left: 0; right: 0; background: var(--bg-2);
		border-bottom: 1px solid var(--line); display: none;
	}
	.main-nav.open { display: block; }
	.main-nav ul { flex-direction: column; padding: 10px 16px; }
	.news-grid { grid-template-columns: 1fr; }
	.post-card.featured { flex-direction: column; }
	.post-card.featured .thumb { min-height: 0; aspect-ratio: 16 / 9; }
	.hero { padding: 70px 0 60px; }
	.section { padding: 64px 0; }
	.cta { padding: 34px 20px; }
	.stat-grid { grid-template-columns: 1fr 1fr; }
	.players-big .now { font-size: 58px; }
	.rules-tabs { position: static; }
	.bans-search { max-width: none; margin-left: 0; flex: 1 1 100%; }
	.bans-search .btn { flex: none; padding: 11px 16px; }
	.bans-table-wrap { background: none; border: 0; overflow: visible; }
	.bans-table thead { display: none; }
	.bans-table, .bans-table tbody, .bans-table tr, .bans-table td { display: block; width: 100%; }
	.bans-table tr { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); margin-bottom: 10px; padding: 6px 0; }
	.bans-table td { display: flex; justify-content: space-between; gap: 16px; padding: 8px 16px; border: 0; text-align: right; }
	.bans-table td::before {
		content: attr(data-label); flex: none; text-align: left; color: var(--muted);
		font-family: var(--mono); font-size: 11px; text-transform: uppercase; letter-spacing: 1.2px; padding-top: 3px;
	}
	.bans-table tbody tr:hover td { background: none; }
	.rules-tab { font-size: 19px; padding: 10px 14px; }
	.rules-content ol > li { padding-left: 52px; }
	.discord-band { grid-template-columns: 1fr; padding: 28px 22px; gap: 18px; }
	.discord-logo { width: 64px; height: 64px; border-radius: 16px; }
	.discord-logo svg { width: 34px; height: 34px; }
	.discord-band .btn-discord { justify-self: stretch; }
	.header-discord { width: 44px; height: 44px; margin-left: auto; order: 2; }
	.nav-toggle { order: 3; }
	.header-inner { gap: 10px; }
}

@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after { animation: none !important; transition: none !important; }
	#rl-rain { display: none; }
}
