/* Plugin WordPress - Participants 6JDF - Style moderne et responsive */

/* Variables CSS inspirées du site 6JDF */
:root {
	--primary-color: rgba(26, 66, 142, 0.584);
	--secondary-color: rgba(26, 66, 142, 0.584);
	--accent-color: #f59e0b;
	--success-color: #10b981;
	--warning-color: #f59e0b;
	--danger-color: #ef4444;
	--text-primary: #1f2937;
	--text-secondary: #6b7280;
	--bg-primary: #ffffff;
	--bg-secondary: #f8fafc;
	--bg-accent: #f1f5f9;
	--border-color: #e5e7eb;
	--shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
	--shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
	--border-radius: 20px;
	--transition: all 0.3s ease;
}

/* Container principal */
.participants-6jdf-container {
	max-width: 1400px;
	margin: 0 auto;
	padding: 20px;
	font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
	color: var(--text-primary);
	line-height: 1.6;
}

/* Header */
.participants-header {
	background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
	color: white;
	padding: 2rem;
	border-radius: var(--border-radius);
	margin-bottom: 2rem;
	box-shadow: var(--shadow-lg);
	text-align: center;
}

.header-content {
	max-width: 600px;
	margin: 0 auto;
}

.participants-title {
	font-size: 2.5rem;
	font-weight: 700;
	margin-bottom: 0.5rem;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 1rem;
}

.participants-title i {
	color: var(--accent-color);
}

.participants-subtitle {
	font-size: 1.2rem;
	opacity: 0.9;
	font-weight: 300;
	margin: 0;
}

/* Filtres et recherche */
.filters-section {
	background: var(--bg-primary);
	padding: 1.5rem;
	border-radius: var(--border-radius);
	margin-bottom: 2rem;
	box-shadow: var(--shadow);
	display: flex;
	flex-direction: column;
	gap: 1rem;
}

.search-container {
	position: relative;
	max-width: 400px;
	margin: 0 auto;
}

.search-icon {
	position: absolute;
	left: 1rem;
	top: 50%;
	transform: translateY(-50%);
	color: var(--text-secondary);
}

.search-input {
	width: 100%;
	padding: 0.75rem 1rem 0.75rem 2.5rem;
	border: 2px solid var(--border-color);
	border-radius: var(--border-radius);
	font-size: 1rem;
	transition: var(--transition);
}

.search-input:focus {
	outline: none;
	border-color: var(--primary-color);
	box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.1);
}

.filter-buttons {
	display: flex;
	justify-content: center;
	gap: 0.5rem;
	flex-wrap: wrap;
}

.filter-btn {
	padding: 0.75rem 1.5rem;
	border: 2px solid var(--border-color);
	background: var(--bg-primary);
	color: var(--text-primary);
	border-radius: var(--border-radius);
	cursor: pointer;
	transition: var(--transition);
	display: flex;
	align-items: center;
	gap: 0.5rem;
	font-weight: 500;
}

.filter-btn:hover {
	border-color: var(--primary-color);
	background: var(--bg-accent);
}

.filter-btn.active {
	background: var(--primary-color);
	color: white;
	border-color: var(--primary-color);
}

/* Statistiques */
.stats-container {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
	gap: 1rem;
	margin-bottom: 2rem;
}

.stat-card {
	background: var(--bg-primary);
	padding: 1.5rem;
	border-radius: var(--border-radius);
	text-align: center;
	box-shadow: var(--shadow);
	border-left: 4px solid var(--primary-color);
	transition: var(--transition);
}

.stat-card:hover {
	transform: translateY(-2px);
	box-shadow: var(--shadow-lg);
}

.stat-card.validated {
	border-left-color: var(--success-color);
}

.stat-card.processing {
	border-left-color: var(--warning-color);
}

.stat-number {
	font-size: 2rem;
	font-weight: 700;
	color: var(--primary-color);
	margin-bottom: 0.5rem;
}

.stat-card.validated .stat-number {
	color: var(--success-color);
}

.stat-card.processing .stat-number {
	color: var(--warning-color);
}

.stat-label {
	color: var(--text-secondary);
	font-weight: 500;
	text-transform: uppercase;
	font-size: 0.875rem;
	letter-spacing: 0.05em;
	margin: 0;
}

/* Table */
.table-container {
	background: var(--bg-primary);
	border-radius: var(--border-radius);
	box-shadow: var(--shadow);
	overflow: hidden;
}

.table-wrapper {
	overflow-x: auto;
}

.participants-table {
	width: 100%;
	border-collapse: collapse;
	font-size: 0.9rem;
}

.participants-table th {
	background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
	color: white;
	padding: 1rem 0.75rem;
	text-align: left;
	font-weight: 600;
	text-transform: uppercase;
	font-size: 0.8rem;
	letter-spacing: 0.05em;
	position: sticky;
	top: 0;
	z-index: 10;
}

.participants-table th.sortable {
	cursor: pointer;
	user-select: none;
	transition: var(--transition);
}

.participants-table th.sortable:hover {
	background: var(--secondary-color);
}

.participants-table th i {
	margin-left: 0.5rem;
	opacity: 0.7;
}

.participants-table td {
	padding: 1rem 0.75rem;
	border-bottom: 1px solid var(--border-color);
	vertical-align: middle;
}

.participants-table tbody tr {
	transition: var(--transition);
}

.participants-table tbody tr:hover {
	background: var(--bg-accent);
}

/* Statuts des participants */
.participant-validated {
	background: rgba(16, 185, 129, 0.1);
	border-left: 4px solid var(--success-color);
}

.participant-processing {
	background: rgba(245, 158, 11, 0.1);
	border-left: 4px solid var(--warning-color);
}

/* Badges de statut */
.status-badge {
	padding: 0.25rem 0.75rem;
	border-radius: 9999px;
	font-size: 0.75rem;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.05em;
}

.status-validated {
	background: rgba(16, 185, 129, 0.1);
	color: var(--success-color);
}

.status-processing {
	background: rgba(245, 158, 11, 0.1);
	color: var(--warning-color);
}

/* Drapeaux et épreuves */
.country-flag {
	width: 24px;
	height: 18px;
	border-radius: 2px;
	margin-right: 0.5rem;
	vertical-align: middle;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.discipline-icon {
	margin-right: 0.5rem;
	font-size: 1.1em;
}

.category-badge {
	background: var(--primary-color);
	color: white;
	padding: 0.25rem 0.5rem;
	border-radius: 4px;
	font-weight: 600;
	font-size: 0.8rem;
}

/* Loading et états vides */
.loading {
	text-align: center;
	padding: 3rem;
	color: var(--text-secondary);
}

.spinner {
	width: 40px;
	height: 40px;
	border: 4px solid var(--border-color);
	border-top: 4px solid var(--primary-color);
	border-radius: 50%;
	animation: spin 1s linear infinite;
	margin: 0 auto 1rem;
}

@keyframes spin {
	0% { transform: rotate(0deg); }
	100% { transform: rotate(360deg); }
}

.no-results {
	text-align: center;
	padding: 3rem;
	color: var(--text-secondary);
}

.no-results i {
	font-size: 3rem;
	margin-bottom: 1rem;
	opacity: 0.5;
}

/* Cartes mobiles */
.mobile-cards {
	display: none;
}

.participant-card {
	background: var(--bg-primary);
	border-radius: var(--border-radius);
	padding: 1rem;
	margin-bottom: 1rem;
	box-shadow: var(--shadow);
	border-left: 4px solid var(--primary-color);
}

.participant-card.validated {
	border-left-color: var(--success-color);
}

.participant-card.processing {
	border-left-color: var(--warning-color);
}

.card-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 0.75rem;
}

.card-name {
	font-weight: 600;
	font-size: 1.1rem;
	color: var(--text-primary);
}

.card-dossard {
	background: var(--primary-color);
	color: white;
	padding: 0.25rem 0.5rem;
	border-radius: 4px;
	font-weight: 600;
	font-size: 0.9rem;
}

.card-details {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 0.5rem;
	font-size: 0.9rem;
}

.card-detail {
	display: flex;
	align-items: center;
	gap: 0.5rem;
}

.card-detail strong {
	color: var(--text-secondary);
	font-size: 0.8rem;
	text-transform: uppercase;
	letter-spacing: 0.05em;
}

/* Animations */
@keyframes fadeIn {
	from {
		opacity: 0;
		transform: translateY(20px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

.fade-in {
	animation: fadeIn 0.5s ease-out;
}

/* Responsive Design */
@media (max-width: 768px) {
	.participants-6jdf-container {
		padding: 10px;
	}

	.participants-title {
		font-size: 1.8rem;
		flex-direction: column;
		gap: 0.5rem;
	}

	.participants-subtitle {
		font-size: 1rem;
	}

	.filters-section {
		padding: 1rem;
	}

	.search-container {
		max-width: 100%;
	}

	.filter-buttons {
		justify-content: stretch;
	}

	.filter-btn {
		flex: 1;
		justify-content: center;
		padding: 0.5rem 1rem;
		font-size: 0.9rem;
	}

	.stats-container {
		grid-template-columns: repeat(3, 1fr);
		gap: 0.5rem;
	}

	.stat-card {
		padding: 1rem;
	}

	.stat-number {
		font-size: 1.5rem;
	}

	.participants-table {
		font-size: 0.8rem;
	}

	.participants-table th,
	.participants-table td {
		padding: 0.5rem 0.25rem;
	}

	.mobile-hidden {
		display: none;
	}

	/* Affichage en cartes sur mobile */
	.table-wrapper {
		display: none;
	}

	.mobile-cards {
		display: block;
	}
}

@media (min-width: 769px) {
	.mobile-cards {
		display: none;
	}
}

/* Améliorations d'accessibilité */
@media (prefers-reduced-motion: reduce) {
	* {
		animation-duration: 0.01ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.01ms !important;
	}
}

/* Focus visible pour l'accessibilité */
button:focus-visible,
input:focus-visible {
	outline: 2px solid var(--primary-color);
	outline-offset: 2px;
}

/* Impression */
@media print {
	.filters-section,
	.stats-container {
		display: none;
	}
	
	.participants-table {
		font-size: 0.7rem;
	}
	
	.participants-table th,
	.participants-table td {
		padding: 0.25rem;
	}
}