/*
Theme Name: Team Cockroach
Theme URI: https://teamcockroach.ch
Author: Team Cockroach
Description: Thème officiel de Team Cockroach (anciennement Team Solid), équipe esport de Neuchâtel. Pensé pour Elementor : les pages sont créées automatiquement à l'activation. Impossible à éliminer.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.8
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: team-cockroach
Tags: dark, esports, elementor, one-column, custom-logo, custom-menu
*/

:root {
	--tc-bg: #0d0906;
	--tc-panel: #1a120b;
	--tc-panel-2: #24180e;
	--tc-line: rgba(255, 179, 0, 0.18);
	--tc-brown: #6b3a1e;
	--tc-amber: #ffb300;
	--tc-amber-2: #ffd166;
	--tc-cream: #f4e9d8;
	--tc-text: #e3d5c2;
	--tc-muted: #a8957e;
	--tc-display: "Bebas Neue", Impact, "Arial Narrow", sans-serif;
	--tc-body: Inter, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

/* ---------- Base ---------- */

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

html { scroll-behavior: smooth; }

body.tc-theme {
	margin: 0;
	background: var(--tc-bg);
	color: var(--tc-text);
	font-family: var(--tc-body);
	font-size: 17px;
	line-height: 1.65;
	-webkit-font-smoothing: antialiased;
}

body.tc-theme h1, body.tc-theme h2, body.tc-theme h3, body.tc-theme h4,
body.tc-theme .elementor-heading-title,
body.tc-theme .elementor-image-box-title {
	font-family: var(--tc-display);
	font-weight: 400;
	letter-spacing: 0.02em;
	line-height: 1.02;
	color: var(--tc-cream);
	margin: 0 0 0.4em;
}

body.tc-theme a { color: var(--tc-amber); }
body.tc-theme a:hover { color: var(--tc-amber-2); }
body.tc-theme img { max-width: 100%; height: auto; }

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

.tc-skip {
	position: absolute;
	left: -9999px;
	top: 8px;
	z-index: 10001;
	background: var(--tc-amber);
	color: #1a0d05 !important;
	padding: 8px 14px;
	border-radius: 8px;
	font-weight: 800;
}
.tc-skip:focus { left: 12px; }

.tc-container {
	max-width: 1140px;
	margin: 0 auto;
	padding: 60px 20px;
}

/* ---------- Header ---------- */

.tc-header {
	position: sticky;
	top: 0;
	z-index: 1000;
	background: rgba(13, 9, 6, 0.86);
	backdrop-filter: blur(10px);
	-webkit-backdrop-filter: blur(10px);
	border-bottom: 1px solid var(--tc-line);
}
.admin-bar .tc-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .tc-header { top: 46px; } }

.tc-header__inner {
	max-width: 1240px;
	margin: 0 auto;
	padding: 12px 20px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 20px;
}

.tc-brand, .custom-logo-link {
	display: flex;
	align-items: center;
	gap: 12px;
	text-decoration: none;
}
.custom-logo { max-height: 52px; width: auto; }
.tc-brand img { width: 40px; height: auto; transition: transform .3s; }
.tc-brand:hover img { transform: rotate(-12deg) scale(1.08); }
.tc-brand__text {
	font-family: var(--tc-display);
	font-size: 30px;
	line-height: .85;
	color: var(--tc-cream);
	letter-spacing: .03em;
}
.tc-brand__text small {
	display: block;
	font-size: 13px;
	letter-spacing: .35em;
	color: var(--tc-amber);
}

.tc-menu {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	gap: 6px;
	align-items: center;
}
.tc-menu li { position: relative; }
.tc-menu a {
	display: block;
	padding: 8px 14px;
	border-radius: 999px;
	color: var(--tc-text) !important;
	text-decoration: none;
	font-weight: 600;
	font-size: 14px;
	text-transform: uppercase;
	letter-spacing: .08em;
	transition: background .2s, color .2s;
}
.tc-menu a:hover,
.tc-menu .current-menu-item > a,
.tc-menu .current_page_item > a {
	background: var(--tc-amber);
	color: #1a0d05 !important;
}
.tc-menu ul {
	display: none;
	position: absolute;
	top: 100%;
	left: 0;
	min-width: 200px;
	list-style: none;
	padding: 8px;
	margin: 0;
	background: var(--tc-panel);
	border: 1px solid var(--tc-line);
	border-radius: 12px;
}
.tc-menu li:hover > ul, .tc-menu li:focus-within > ul { display: block; }

.tc-burger {
	display: none;
	background: none;
	border: 1px solid var(--tc-line);
	border-radius: 10px;
	padding: 10px 9px;
	cursor: pointer;
}
.tc-burger > span:not(.screen-reader-text) {
	display: block;
	width: 22px;
	height: 2px;
	margin: 4px 0;
	background: var(--tc-cream);
	border-radius: 2px;
}

@media (max-width: 900px) {
	.tc-burger { display: block; }
	.tc-nav {
		display: none;
		position: absolute;
		top: 100%;
		left: 0;
		right: 0;
		background: var(--tc-bg);
		border-bottom: 1px solid var(--tc-line);
		padding: 12px 20px 20px;
	}
	.tc-nav.is-open { display: block; }
	.tc-menu { flex-direction: column; align-items: stretch; }
	.tc-menu ul { position: static; display: block; border: 0; background: none; padding-left: 16px; }
}

/* ---------- Footer ---------- */

.tc-footer {
	border-top: 1px solid var(--tc-line);
	background: #080604;
	padding: 48px 20px 36px;
	text-align: center;
}
.tc-footer__inner { max-width: 900px; margin: 0 auto; }
.tc-footer__brand {
	display: inline-flex;
	align-items: center;
	gap: 14px;
	text-align: left;
	margin-bottom: 18px;
}
.tc-footer__brand strong {
	display: block;
	font-family: var(--tc-display);
	font-size: 26px;
	font-weight: 400;
	color: var(--tc-cream);
	letter-spacing: .04em;
}
.tc-footer__brand span { color: var(--tc-muted); font-size: 14px; }
.tc-footer__joke { color: var(--tc-muted); font-size: 14px; font-style: italic; }
.tc-footer__copy { color: #6f604f; font-size: 13px; margin: 0; }

/* ---------- Pages classiques & 404 ---------- */

.tc-entry__title { font-size: clamp(40px, 6vw, 72px); }
.tc-entry__content { max-width: 760px; }

.tc-404 { text-align: center; padding: 120px 20px; }
.tc-404 img { width: 120px; animation: tc-wiggle 1.2s ease-in-out infinite; }
.tc-404 h1 { font-size: clamp(48px, 8vw, 96px); }
.tc-404__btn {
	display: inline-block;
	margin-top: 10px;
	padding: 14px 28px;
	border-radius: 999px;
	background: var(--tc-amber);
	color: #1a0d05 !important;
	font-weight: 800;
	text-transform: uppercase;
	text-decoration: none;
}

/* ---------- Blocs Elementor ---------- */

body.tc-theme .elementor-widget-text-editor { color: var(--tc-text); }
body.tc-theme .elementor-widget-text-editor p:last-child { margin-bottom: 0; }

/* Héros */
.tc-hero {
	position: relative;
	overflow: hidden;
	background:
		radial-gradient(1000px 520px at 75% 40%, rgba(255, 179, 0, .16), transparent 60%),
		radial-gradient(700px 400px at 10% 90%, rgba(107, 58, 30, .45), transparent 60%),
		var(--tc-bg) !important;
}
.tc-hero::before {
	content: "";
	position: absolute;
	inset: 0;
	background-image: url("assets/img/pattern.svg");
	background-size: 220px;
	opacity: .03;
	pointer-events: none;
}
.tc-hero .elementor-container { position: relative; z-index: 1; }

.tc-hero-title .elementor-heading-title {
	font-size: clamp(64px, 11vw, 150px) !important;
	line-height: .86 !important;
}
.tc-hero-title .elementor-heading-title span { color: var(--tc-amber); }

.tc-kicker {
	display: inline-block;
	padding: 6px 14px;
	border: 1px solid var(--tc-line);
	border-radius: 999px;
	background: rgba(255, 179, 0, .08);
	color: var(--tc-amber) !important;
	font-size: 13px;
	font-weight: 600;
	letter-spacing: .12em;
	text-transform: uppercase;
}
.tc-kicker p { margin: 0; }
body.tc-theme .elementor-widget.tc-kicker { width: auto; max-width: 100%; margin-bottom: 18px; }
body.tc-theme .elementor-widget.tc-kicker.tc-center { margin-left: auto; margin-right: auto; }
body.tc-theme .elementor-widget.tc-kicker.tc-left { margin-right: auto; }

.tc-lead { font-size: 20px; color: var(--tc-cream) !important; max-width: 620px; }
body.tc-theme .elementor-widget.tc-lead.tc-center { margin-left: auto; margin-right: auto; }

.tc-hero-art img {
	animation: tc-float 6s ease-in-out infinite;
	filter: drop-shadow(0 30px 60px rgba(0, 0, 0, .6));
}

/* Titres de section */
.tc-h2 .elementor-heading-title { font-size: clamp(44px, 6vw, 76px) !important; }
.tc-h2 .elementor-heading-title span { color: var(--tc-amber); }

.tc-section-alt { background: var(--tc-panel) !important; }
.tc-section-line { border-top: 1px solid var(--tc-line); }

/* Boutons */
body.tc-theme .tc-btn .elementor-button {
	background: var(--tc-amber);
	color: #1a0d05;
	border: 2px solid var(--tc-amber);
	border-radius: 999px;
	padding: 16px 30px;
	font-family: var(--tc-body);
	font-weight: 800;
	font-size: 15px;
	text-transform: uppercase;
	letter-spacing: .08em;
	transition: transform .2s, background .2s, color .2s;
}
body.tc-theme .tc-btn .elementor-button:hover { transform: translateY(-2px) rotate(-1deg); background: var(--tc-amber-2); }
body.tc-theme .tc-btn--ghost .elementor-button {
	background: transparent;
	color: var(--tc-cream);
	border-color: rgba(244, 233, 216, .35);
}
body.tc-theme .tc-btn--ghost .elementor-button:hover { background: var(--tc-cream); color: #1a0d05; }

/* Patch notes */
.tc-patch {
	background: #0a0705;
	border: 1px solid var(--tc-line);
	border-radius: 18px;
	overflow: hidden;
	box-shadow: 0 30px 80px rgba(0, 0, 0, .45);
	font-family: ui-monospace, "SF Mono", Consolas, monospace;
	font-size: 14px;
}
.tc-patch__bar {
	display: flex;
	gap: 7px;
	align-items: center;
	padding: 12px 16px;
	background: var(--tc-panel-2);
	color: var(--tc-muted);
	font-size: 12px;
}
.tc-patch__bar i { width: 11px; height: 11px; border-radius: 50%; background: #5a3b22; display: inline-block; }
.tc-patch__bar i:first-child { background: var(--tc-amber); }
.tc-patch__bar b { margin-left: 8px; font-weight: 400; }
.tc-patch ul { list-style: none; margin: 0; padding: 18px 20px 22px; }
.tc-patch li { padding: 6px 0; border-bottom: 1px dashed rgba(255, 255, 255, .06); color: var(--tc-text); }
.tc-patch li:last-child { border: 0; }
.tc-patch .add { color: #9be36b; }
.tc-patch .fix { color: var(--tc-amber); }
.tc-patch .bug { color: #ff7a59; }

/* Compteurs */
.tc-counter .elementor-counter-number-wrapper {
	font-family: var(--tc-display);
	font-size: clamp(48px, 5vw, 72px) !important;
	color: var(--tc-amber) !important;
	line-height: 1;
}
.tc-counter .elementor-counter-title {
	color: var(--tc-muted) !important;
	font-family: var(--tc-body);
	font-size: 15px !important;
	line-height: 1.4;
	margin-top: 8px;
}

/* Cartes jeux / joueurs */
.tc-card .elementor-image-box-wrapper,
.tc-player .elementor-image-box-wrapper {
	background: var(--tc-panel);
	border: 1px solid var(--tc-line);
	border-radius: 22px;
	overflow: hidden;
	height: 100%;
	transition: transform .25s, border-color .25s, box-shadow .25s;
}
.tc-card .elementor-widget-container,
.tc-player .elementor-widget-container { height: 100%; }
.tc-card .elementor-image-box-wrapper:hover,
.tc-player .elementor-image-box-wrapper:hover {
	transform: translateY(-6px);
	border-color: var(--tc-amber);
	box-shadow: 0 24px 50px rgba(0, 0, 0, .45);
}
.tc-card .elementor-image-box-img { margin: 0 !important; width: 100% !important; }
.tc-card .elementor-image-box-img img { width: 100%; display: block; }
.tc-card .elementor-image-box-content { padding: 22px 24px 26px; }

.tc-player .elementor-image-box-wrapper { padding: 22px 20px 24px; }
.tc-player .elementor-image-box-img { width: 82% !important; max-width: 220px; margin: 0 auto 16px !important; }
.tc-player .elementor-image-box-img img {
	border-radius: 50%;
	border: 3px solid var(--tc-line);
	transition: transform .4s;
}
.tc-player .elementor-image-box-wrapper:hover img { transform: rotate(-6deg) scale(1.05); }

.tc-card .elementor-image-box-title,
.tc-player .elementor-image-box-title { font-size: 34px !important; margin-bottom: 6px !important; }
.tc-card .elementor-image-box-description,
.tc-player .elementor-image-box-description { color: var(--tc-muted); font-size: 15px; line-height: 1.55; }

/* Cartes simples (raisons, partenaires, format) */
.tc-box {
	background: var(--tc-panel);
	border: 1px solid var(--tc-line);
	border-radius: 20px;
	padding: 26px 24px;
	height: 100%;
}
.tc-section-alt .tc-box { background: var(--tc-bg); }
.tc-box h3 { font-size: 30px; margin-bottom: 8px; color: var(--tc-cream); }
.tc-box p { margin: 0; color: var(--tc-muted); font-size: 15px; }
.tc-box .tc-emoji { font-size: 34px; line-height: 1; display: block; margin-bottom: 12px; }
.tc-box--partner {
	text-align: center;
	border-style: dashed;
	min-height: 150px;
	display: flex;
	flex-direction: column;
	justify-content: center;
}

/* Citation */
.tc-quote .elementor-heading-title,
.tc-quote p {
	font-family: var(--tc-display);
	font-size: clamp(32px, 4.4vw, 58px);
	line-height: 1.05;
	color: var(--tc-cream);
}
.tc-quote-author { color: var(--tc-amber) !important; font-size: 14px; letter-spacing: .14em; text-transform: uppercase; }

/* Liste de critères */
.tc-checklist ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.tc-checklist li {
	padding: 14px 18px 14px 50px;
	background: var(--tc-panel);
	border: 1px solid var(--tc-line);
	border-radius: 14px;
	position: relative;
}
.tc-checklist li::before {
	content: "🪳";
	position: absolute;
	left: 16px;
	top: 13px;
}

/* Timeline */
.tc-timeline { position: relative; padding-left: 34px; }
.tc-timeline::before {
	content: "";
	position: absolute;
	left: 9px;
	top: 6px;
	bottom: 6px;
	width: 2px;
	background: linear-gradient(var(--tc-amber), var(--tc-brown));
}
.tc-timeline__item { position: relative; margin-bottom: 34px; }
.tc-timeline__item:last-child { margin-bottom: 0; }
.tc-timeline__item::before {
	content: "";
	position: absolute;
	left: -31px;
	top: 6px;
	width: 16px;
	height: 16px;
	border-radius: 50%;
	background: var(--tc-bg);
	border: 3px solid var(--tc-amber);
}
.tc-timeline__year { font-family: var(--tc-display); font-size: 22px; color: var(--tc-amber); letter-spacing: .1em; }
.tc-timeline__item h3 { font-size: 36px; margin: 2px 0 6px; }
.tc-timeline__item p { margin: 0; color: var(--tc-text); }

/* Accordéon FAQ */
body.tc-theme .tc-faq .elementor-accordion-item {
	border: 1px solid var(--tc-line) !important;
	border-radius: 14px;
	margin-bottom: 10px;
	overflow: hidden;
	background: var(--tc-panel);
}
body.tc-theme .tc-faq .elementor-tab-title {
	border: 0 !important;
	padding: 18px 22px !important;
}
body.tc-theme .tc-faq .elementor-tab-title a,
body.tc-theme .tc-faq .elementor-accordion-icon { color: var(--tc-cream) !important; font-weight: 600; }
body.tc-theme .tc-faq .elementor-tab-title.elementor-active a { color: var(--tc-amber) !important; }
body.tc-theme .tc-faq .elementor-tab-content {
	border: 0 !important;
	padding: 0 22px 20px !important;
	color: var(--tc-muted);
}

/* Bandeau défilant */
.tc-marquee {
	overflow: hidden;
	white-space: nowrap;
	border-top: 1px solid var(--tc-line);
	border-bottom: 1px solid var(--tc-line);
	background: var(--tc-amber);
	color: #1a0d05;
	font-family: var(--tc-display);
	font-size: 30px;
	letter-spacing: .06em;
	padding: 10px 0;
}
.tc-marquee__track { display: inline-block; animation: tc-marquee 40s linear infinite; }
.tc-marquee span { padding: 0 22px; }

/* ---------- Cafards baladeurs ---------- */

.tc-roach {
	position: fixed;
	left: 0;
	top: 0;
	width: 46px;
	height: auto;
	z-index: 9999;
	cursor: pointer;
	filter: drop-shadow(0 6px 6px rgba(0, 0, 0, .5));
	transition: opacity .2s, filter .2s;
}
.tc-roach.is-squished { opacity: .55; filter: grayscale(1) brightness(.6); }

.tc-toast {
	position: fixed;
	left: 50%;
	bottom: 28px;
	transform: translateX(-50%);
	z-index: 10000;
	background: var(--tc-amber);
	color: #1a0d05;
	font-weight: 800;
	padding: 12px 20px;
	border-radius: 999px;
	box-shadow: 0 14px 30px rgba(0, 0, 0, .4);
	transition: opacity .5s, transform .5s;
	max-width: calc(100% - 32px);
	text-align: center;
}
.tc-toast.is-out { opacity: 0; transform: translate(-50%, 12px); }

/* ---------- Animations ---------- */

@keyframes tc-float { 0%, 100% { transform: translateY(0) rotate(-2deg); } 50% { transform: translateY(-16px) rotate(2deg); } }
@keyframes tc-wiggle { 0%, 100% { transform: rotate(-8deg); } 50% { transform: rotate(8deg); } }
@keyframes tc-marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }

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