/* ==========================================================================
   MUN Delegate Hub - pagina de comites
   Reproduce las tarjetas y las etiquetas (Badge) de src/pages/Committees.tsx.
   ========================================================================== */

/* ---- Etiqueta (badge.tsx) ---- */

.mun-badge {
	display: inline-flex;
	align-items: center;
	padding: 0.125rem 0.625rem;
	border: 1px solid hsl(var(--border));
	border-radius: 9999px;
	font-size: 0.75rem;
	line-height: 1rem;
	font-weight: 600;
	transition-property: color, background-color, border-color, text-decoration-color, fill, stroke;
	transition-duration: 150ms;
	transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

.mun-badge--secondary {
	border-color: transparent;
}

/* igual que el original: al pasar el raton el fondo pasa a secondary/80 y el texto conserva su color */
.mun-badge--secondary:hover {
	background-color: hsl(var(--secondary) / 0.8);
}

.mun-badge--outline {
	color: hsl(var(--foreground));
	text-transform: capitalize;
}

/* colores por dificultad (green/yellow/red 100 y 800 de Tailwind) */
.mun-badge--beginner     { background-color: rgb(220 252 231); color: rgb(22 101 52); }
.mun-badge--intermediate { background-color: rgb(254 249 195); color: rgb(133 77 14); }
.mun-badge--advanced     { background-color: rgb(254 226 226); color: rgb(153 27 27); }
.mun-badge--other        { background-color: hsl(var(--muted)); color: hsl(var(--muted-foreground)); }

/* ---- Rejilla de tarjetas (md:grid-cols-2 lg:grid-cols-3 gap-4 sm:gap-6) ---- */

.committees-grid {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: 1rem;
}

@media (min-width: 640px)  { .committees-grid { gap: 1.5rem; } }
@media (min-width: 768px)  { .committees-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1024px) { .committees-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* ---- Tarjeta de comite ---- */

.committee-card {
	transition-property: all;
	transition-duration: 300ms;
	transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

.committee-card:hover {
	box-shadow: var(--shadow-lg);
	transform: translateY(-0.25rem);
}

.committee-card__header {
	padding: 1.5rem 1.5rem 0.75rem;
}

.committee-card__head-row {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 0.5rem;
}

.committee-card__title {
	font-size: 1.125rem;
	line-height: 1.25;
	font-weight: 600;
	letter-spacing: -0.025em;
}

.committee-card__abbr {
	margin-right: 0.5rem;
	font-weight: 700;
	color: hsl(var(--primary));
}

.committee-card__badges {
	display: flex;
	flex-direction: column;
	align-items: flex-end;
	flex-shrink: 0;
	gap: 0.375rem;
}

.committee-card__body {
	padding: 0 1.5rem 1.5rem;
}

.committee-card__body > * + * {
	margin-top: 1rem;
}

/* tema */
.committee-topic {
	display: flex;
	align-items: flex-start;
	gap: 0.5rem;
	padding: 0.75rem;
	border: 1px solid hsl(var(--primary) / 0.2);
	border-radius: calc(var(--radius) - 2px);
	background-color: hsl(var(--primary) / 0.05);
}

.committee-topic .icon {
	width: 1rem;
	height: 1rem;
	margin-top: 0.125rem;
	flex-shrink: 0;
	color: hsl(var(--primary));
}

.committee-topic__body {
	min-width: 0;
}

.committee-topic__label {
	margin-bottom: 0.25rem;
	font-size: 0.75rem;
	line-height: 1rem;
	font-weight: 600;
	text-transform: uppercase;
	color: hsl(var(--primary));
}

.committee-topic__text {
	white-space: pre-line;
	font-size: 0.875rem;
	line-height: 1.625;
	font-weight: 600;
	color: hsl(var(--foreground));
}

/* descripcion */
.committee-desc {
	white-space: pre-line;
	font-size: 0.875rem;
	line-height: 1.625;
	color: hsl(var(--muted-foreground));
}

/* presidente */
.committee-chair {
	display: flex;
	align-items: center;
	gap: 0.5rem;
}

.committee-chair .icon {
	width: 1rem;
	height: 1rem;
	flex-shrink: 0;
	color: hsl(var(--muted-foreground));
}

.committee-chair__text {
	font-size: 0.875rem;
	line-height: 1.25rem;
	color: hsl(var(--muted-foreground));
}

.committee-chair__name {
	font-weight: 500;
	color: hsl(var(--foreground));
}

/* delegaciones (capacidad) */
.committee-capacity {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding-top: 0.75rem;
	border-top: 1px solid hsl(var(--border));
}

.committee-capacity__label {
	display: flex;
	align-items: center;
	gap: 0.5rem;
}

.committee-capacity__label .icon {
	width: 1rem;
	height: 1rem;
	color: hsl(var(--muted-foreground));
}

.committee-capacity__label span {
	font-size: 0.875rem;
	line-height: 1.25rem;
	color: hsl(var(--muted-foreground));
}

.committee-capacity__value {
	font-size: 0.875rem;
	line-height: 1.25rem;
	font-weight: 600;
	color: hsl(var(--foreground));
}

/* sin comites (Card text-center py-12 + CardContent) */
.committees-empty {
	padding-top: 3rem;
	padding-bottom: 3rem;
	text-align: center;
}

.committees-empty__body {
	padding: 0 1.5rem 1.5rem;
}

.committees-empty .icon {
	width: 3rem;
	height: 3rem;
	margin: 0 auto 1rem;
	color: hsl(var(--muted-foreground));
}

.committees-empty p {
	color: hsl(var(--muted-foreground));
}
