.listado-senadores-main {
	min-width: 0;
	width: 100%;
	max-width: 100%;
	box-sizing: border-box;
}

.listado-senadores-main--full,
.listado-senadores-main--with-sidebar {
	grid-column: auto;
}

.listado-senadores-content {
	width: 100%;
	max-width: none;
	min-width: 0;
}

.listado-senadores-main > * {
	max-width: 100%;
	min-width: 0;
	box-sizing: border-box;
}

@media (min-width: 768px) {
	.listado-senadores-main--full {
		grid-column: span 12 / span 12;
	}

	.listado-senadores-main--with-sidebar {
		grid-column: span 8 / span 8;
	}
}

.congresista-app {
	position: relative;
}

.congresista-shell {
	backdrop-filter: blur(10px);
}

.congresista-panel {
	overflow: clip;
}

.congresista-field {
	display: flex;
	flex-direction: column;
	gap: 0.45rem;
	min-width: 0;
}

.congresista-filters .congresista-field--hidden {
	display: none;
}

.congresista-field__label {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	font-size: 0.78rem;
	font-weight: 700;
	color: #475569;
}

.congresista-field__label svg {
	width: 1rem;
	height: 1rem;
	fill: #cd1a1b;
	flex: 0 0 auto;
}

.congresista-field select,
.congresista-field input {
	width: 100%;
	min-height: 2.9rem;
	border: 1px solid #dbe4f0;
	border-radius: 0.85rem;
	background: #ffffff;
	box-shadow: 0 12px 35px -30px rgba(15, 23, 42, 0.55);
	color: #0f172a;
	font-size: 0.92rem;
	padding: 0.8rem 0.9rem;
	transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.congresista-field select {
	appearance: none;
	background-image: linear-gradient(45deg, transparent 50%, #64748b 50%), linear-gradient(135deg, #64748b 50%, transparent 50%);
	background-position: calc(100% - 22px) calc(50% - 3px), calc(100% - 16px) calc(50% - 3px);
	background-size: 6px 6px, 6px 6px;
	background-repeat: no-repeat;
	padding-right: 2.8rem;
}

.congresista-field .select2-container {
	width: 100% !important;
}

.congresista-field .select2-container--default .select2-selection--single {
	display: flex;
	align-items: center;
	min-height: 2.9rem;
	border: 1px solid #dbe4f0;
	border-radius: 0.85rem;
	background: #ffffff;
	box-shadow: 0 12px 35px -30px rgba(15, 23, 42, 0.55);
	padding: 0 2.5rem 0 0.9rem;
	transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.congresista-field .select2-container--default .select2-selection--single .select2-selection__rendered {
	padding: 0;
	color: #0f172a;
	font-size: 0.92rem;
	line-height: 1.2;
}

.congresista-field .select2-container--default .select2-selection--single .select2-selection__placeholder {
	color: #64748b;
}

.congresista-field .select2-container--default .select2-selection--single .select2-selection__arrow {
	height: 100%;
	right: 0.85rem;
	width: 1rem;
}

.congresista-field .select2-container--default .select2-selection--single .select2-selection__arrow b {
	border-color: #64748b transparent transparent transparent;
	border-width: 6px 5px 0 5px;
	margin-left: -5px;
	margin-top: -2px;
}

.congresista-field .select2-container--default.select2-container--open .select2-selection--single,
.congresista-field .select2-container--default.select2-container--focus .select2-selection--single {
	border-color: rgba(0, 77, 121, 0.45);
	box-shadow: 0 0 0 4px rgba(0, 77, 121, 0.1), 0 20px 45px -35px rgba(15, 23, 42, 0.65);
}

.select2-container--open .select2-dropdown.congresista-select2-dropdown {
	border-color: #dbe4f0;
	border-radius: 0.85rem;
	overflow: hidden;
	box-shadow: 0 24px 45px -30px rgba(15, 23, 42, 0.4);
}

.select2-container .select2-dropdown.congresista-select2-dropdown .select2-search--dropdown {
	padding: 0.65rem;
	border-bottom: 1px solid rgba(226, 232, 240, 0.9);
	background: #fff;
}

.select2-container .select2-dropdown.congresista-select2-dropdown .select2-search__field {
	min-height: 2.4rem;
	border: 1px solid #dbe4f0;
	border-radius: 0.7rem;
	padding: 0.55rem 0.75rem;
	font-size: 0.88rem;
}

.select2-container .select2-dropdown.congresista-select2-dropdown .select2-results__option {
	padding: 0.65rem 0.85rem;
	font-size: 0.88rem;
	line-height: 1.35;
}

.select2-container .select2-dropdown.congresista-select2-dropdown .select2-results__option--highlighted.select2-results__option--selectable {
	background: #4D1018;
	color: #fff;
}

.congresista-field select:focus,
.congresista-field input:focus {
	outline: none;
	border-color: rgba(0, 77, 121, 0.45);
	box-shadow: 0 0 0 4px rgba(0, 77, 121, 0.1), 0 20px 45px -35px rgba(15, 23, 42, 0.65);
}

.congresista-search {
	display: flex;
	align-items: flex-end;
	min-width: 0;
}

.congresista-search .congresista-field {
	width: 100%;
}

.congresista-clear-filters {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 0.45rem;
	min-height: 2.9rem;
	margin: 0 0 0.05rem 0.65rem;
	padding: 0 0.85rem;
	border: 1px solid #cbd5e1;
	border-radius: 0.85rem;
	background: #fff;
	color: #475569;
	font-size: 0.82rem;
	font-weight: 700;
	line-height: 1;
	white-space: nowrap;
	transition: border-color 0.2s ease, background-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.congresista-clear-filters svg {
	width: 1rem;
	height: 1rem;
	flex: 0 0 auto;
}

.congresista-clear-filters:hover:not(:disabled) {
	border-color: #4D1018;
	background: #f0f7fb;
	color: #4D1018;
	transform: translateY(-1px);
}

.congresista-clear-filters:focus-visible {
	outline: none;
	border-color: #4D1018;
	box-shadow: 0 0 0 4px rgba(0, 77, 121, 0.12);
}

.congresista-clear-filters:disabled {
	cursor: not-allowed;
	border-color: #e2e8f0;
	background: #f8fafc;
	color: #94a3b8;
}

.congresista-search__controls {
	display: grid;
	grid-template-columns: minmax(0, 1fr) auto;
	gap: 0.55rem;
	align-items: center;
}

.congresista-search__button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 2.9rem;
	min-height: 2.9rem;
	border: 0;
	border-radius: 0.85rem;
	background: linear-gradient(135deg, #cd1a1b 0%, #dc2626 100%);
	color: #fff;
	box-shadow: 0 20px 35px -20px rgba(220, 38, 38, 0.85);
	transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}

.congresista-search__button:hover,
.congresista-search__button:focus {
	outline: none;
	transform: translateY(-1px);
	box-shadow: 0 24px 42px -20px rgba(220, 38, 38, 0.9);
}

.congresista-search__button svg {
	width: 1.2rem;
	height: 1.2rem;
	fill: currentColor;
}

.congresista-results__head {
	display: none;
	align-items: center;
	grid-template-columns: var(--congresista-grid-columns, minmax(0, 2fr) 28px);
	gap: 0.85rem;
	padding: 0.9rem 1.25rem;
}

/* ── Filtro por inicial (A-Z) ───────────────────────── */
.congresista-filters--alpha {
	display: flex !important; /* override grid del breakpoint 1024 */
	grid-template-columns: none !important;
	padding: 0.75rem 1rem !important;
}

.congresista-alpha-filter {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 3px;
	width: 100%;
}

.alpha-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 2rem;
	height: 2rem;
	padding: 0 0.35rem;
	border: 1px solid transparent;
	border-radius: 0.45rem;
	background: transparent;
	color: #64748b;
	font-size: 0.8rem;
	font-weight: 600;
	cursor: pointer;
	line-height: 1;
	transition: background 0.15s, color 0.15s, border-color 0.15s;
}

/* Botón "TODOS" */
.alpha-btn:first-child {
	padding: 0 0.75rem;
	border-color: #e2e8f0;
	background: #f8fafc;
	color: #475569;
	border-radius: 2rem;
}

.alpha-btn:hover {
	background: #f1f5f9;
	color: #4D1018;
}

.alpha-btn.is-active {
	background: #cd1a1b;
	border-color: #cd1a1b;
	color: #ffffff;
}

.alpha-btn:first-child.is-active {
	border-radius: 2rem;
}

@media (min-width: 1024px) {
	.congresista-results__head {
		display: grid;
		background-color: #4D1018;
        color: #fff;
        border-radius: 10px;
	}

	.congresista-filters {
		display: grid;
		grid-template-columns: repeat(12, minmax(0, 1fr));
		gap: 0.8rem 0.9rem;
		padding: 1rem 1.1rem 1.05rem;
	}

	.congresista-field--period,
	.congresista-field--gender,
	.congresista-field--district,
	.congresista-field--condition,
	.congresista-field--group,
	.congresista-field--bancada {
		grid-column: span 4;
	}

	.congresista-search--wide {
		grid-column: span 12;
	}

	.congresista-field {
		gap: 0.38rem;
	}

	.congresista-field__label {
		font-size: 0.72rem;
		gap: 0.42rem;
	}

	.congresista-field__label svg {
		width: 0.9rem;
		height: 0.9rem;
	}

	.congresista-field select,
	.congresista-field input {
		min-height: 2.75rem;
		font-size: 0.88rem;
		padding: 0.7rem 0.85rem;
		border-radius: 0.8rem;
	}

	.congresista-field .select2-container--default .select2-selection--single {
		min-height: 2.75rem;
		border-radius: 0.8rem;
		padding: 0 2.35rem 0 0.85rem;
	}

	.congresista-field .select2-container--default .select2-selection--single .select2-selection__rendered {
		font-size: 0.88rem;
	}

	.congresista-field select {
		background-position: calc(100% - 18px) calc(50% - 2px), calc(100% - 12px) calc(50% - 2px);
		background-size: 5px 5px, 5px 5px;
		padding-right: 2.35rem;
	}

	.congresista-search__controls {
		gap: 0.5rem;
	}

	.congresista-clear-filters {
		min-height: 2.75rem;
		margin-bottom: 0;
		border-radius: 0.8rem;
	}

	.congresista-search__button {
		width: 2.75rem;
		min-height: 2.75rem;
		border-radius: 0.8rem;
	}

	.congresista-panel {
		border-radius: 1rem;
	}

	.congresista-results__footer {
		padding-top: 0.8rem;
		padding-bottom: 0.8rem;
	}

	.congresista-results .md\:grid {
		padding-top: 0.85rem;
		padding-bottom: 0.85rem;
	}
}

.congresista-results__body {
	display: flex;
	flex-direction: column;
}

.congresista-row {
	display: grid;
	grid-template-columns: var(--congresista-grid-columns, minmax(0, 2fr) 28px);
	gap: 0.85rem;
	align-items: center;
	padding: 0.9rem 1.25rem;
	color: inherit;
	text-decoration: none;
	border-bottom: 1px solid rgba(226, 232, 240, 0.85);
	transition: background-color 0.2s ease, transform 0.2s ease;
}

.congresista-row:last-child {
	border-bottom: 0;
}

.congresista-row:hover {
	background: rgba(248, 250, 252, 0.95);
}

.congresista-row__main {
	display: flex;
	align-items: center;
	gap: 0.85rem;
	min-width: 0;
}

.congresista-row__avatar {
	width: 6rem;
	height: 6rem;
	border-radius: 999px;
	overflow: hidden;
	border: 2px solid #fff;
	box-shadow: 0 10px 24px -16px rgba(15, 23, 42, 0.9);
	flex: 0 0 auto;
}

.congresista-row__avatar img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	margin: 0;
}

.congresista-row__identity {
	min-width: 0;
}

.congresista-row__identity h3 {
	margin: 0;
	color: #334155;
	font-size: 0.92rem;
	font-weight: 600;
	line-height: 1.35;
}

.congresista-row__identity p {
	display: none;
	margin: 0.25rem 0 0;
	font-size: 0.78rem;
	color: #64748b;
}

.congresista-row__identity .congresista-row__additional {
	display: block;
	font-weight: 500;
}

.congresista-chip {
	display: inline-flex;
	align-items: center;
	gap: 0.55rem;
	max-width: 100%;
	padding: 0.38rem 0.7rem;
	border-radius: 999px;
	background: #f8fafc;
	color: #475569;
	font-size: 0.69rem;
	font-weight: 700;
	text-transform: uppercase;
	line-height: 1.2;
}

.congresista-chip__dot {
	width: 0.45rem;
	height: 0.45rem;
	border-radius: 999px;
	flex: 0 0 auto;
}

.congresista-row__district {
	min-width: 0;
	color: #475569;
	font-size: 0.84rem;
	line-height: 1.35;
}

.congresista-row__email {
	display: flex;
	align-items: center;
	gap: 0.55rem;
	min-width: 0;
	color: #475569;
	font-size: 0.86rem;
}

.congresista-row__email span:last-child {
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.congresista-row__email-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 1rem;
	height: 1rem;
	color: #94a3b8;
	flex: 0 0 auto;
}

.congresista-row__email-icon svg,
.congresista-row__action svg {
	width: 1rem;
	height: 1rem;
	fill: none;
	stroke: currentColor;
	stroke-width: 1.9;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.congresista-row__action {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 2rem;
	height: 2rem;
	border-radius: 999px;
	color: #94a3b8;
	flex: 0 0 auto;
}

.congresista-pagination {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex-wrap: wrap;
	gap: 0.4rem;
}

.congresista-pagination__button,
.congresista-per-page select {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 2.15rem;
	height: 2.15rem;
	padding: 0 0.75rem;
	border: 1px solid #dbe4f0;
	border-radius: 0.7rem;
	background: #ffffff;
	color: #475569;
	font-size: 0.82rem;
	font-weight: 600;
	box-shadow: 0 10px 24px -20px rgba(15, 23, 42, 0.8);
	transition: border-color 0.2s ease, background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.congresista-pagination__button:hover,
.congresista-pagination__button:focus,
.congresista-per-page select:hover,
.congresista-per-page select:focus {
	outline: none;
	border-color: rgba(0, 77, 121, 0.32);
	transform: translateY(-1px);
}

.congresista-pagination__button.is-active {
	border-color: #cd1a1b;
	background: linear-gradient(135deg, #cd1a1b 0%, #dc2626 100%);
	color: #fff;
	box-shadow: 0 20px 30px -20px rgba(220, 38, 38, 0.9);
}

.congresista-pagination__button:disabled {
	opacity: 0.45;
	cursor: not-allowed;
	transform: none;
}

.congresista-pagination__button svg {
	width: 1rem;
	height: 1rem;
	fill: none;
	stroke: currentColor;
	stroke-width: 1.9;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.congresista-pagination__ellipsis {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 2rem;
	color: #94a3b8;
	font-weight: 700;
}

.congresista-per-page select {
	appearance: none;
	min-width: 8rem;
	background-image: linear-gradient(45deg, transparent 50%, #64748b 50%), linear-gradient(135deg, #64748b 50%, transparent 50%);
	background-position: calc(100% - 16px) calc(50% - 2px), calc(100% - 10px) calc(50% - 2px);
	background-size: 6px 6px, 6px 6px;
	background-repeat: no-repeat;
	padding-right: 2rem;
}

@media (max-width: 1023px) {
	.congresista-row {
		grid-template-columns: minmax(0, 1fr);
		gap: 0.7rem;
		padding: 0.9rem 0.95rem 1rem;
	}

	.congresista-row__group,
	.congresista-row__district,
	.congresista-row__email {
		padding-left: 3.6rem;
	}

	.congresista-row__email {
		font-size: 0.82rem;
	}

	.congresista-row__action {
		position: absolute;
		top: 0.9rem;
		right: 0.85rem;
		background: #f8fafc;
	}

	.congresista-row {
		position: relative;
	}

	.congresista-row__identity h3 {
		padding-right: 2.25rem;
	}

	.congresista-row__identity p {
		display: block;
	}
}

@media (max-width: 767px) {
	.listado-senadores-content {
		max-width: 100%;
	}

	.congresista-app {
		width: 100%;
		max-width: 100%;
		min-width: 0;
		overflow: hidden;
	}

	.congresista-shell {
		width: 100%;
		max-width: 100%;
		min-width: 0;
		padding: 0 0.5rem;
		border-radius: 1rem;
		box-sizing: border-box;
	}

	.congresista-panel,
	.congresista-results,
	.congresista-filters {
		width: 100%;
		max-width: 100%;
		min-width: 0;
		box-sizing: border-box;
	}

	.congresista-filters {
		border-radius: 1rem;
		gap: 0.75rem;
		padding: 0.75rem 0.7rem;
	}

	.congresista-field__label {
		font-size: 0.75rem;
	}

	.congresista-search__button {
		width: 2.75rem;
		min-height: 2.75rem;
	}

	.congresista-search__controls {
		grid-template-columns: minmax(0, 1fr);
		gap: 0.65rem;
	}

	.congresista-search__button {
		width: 100%;
	}

	.congresista-results {
		border-radius: 1rem;
	}

	.congresista-field select,
	.congresista-field input {
		min-height: 2.75rem;
		font-size: 0.9rem;
	}

	.congresista-field .select2-container--default .select2-selection--single {
		min-height: 2.75rem;
	}

	.congresista-field .select2-container--default .select2-selection--single .select2-selection__rendered {
		font-size: 0.9rem;
	}

	.congresista-row {
		padding: 0.75rem 0.7rem 0.85rem;
	}

	.congresista-row__avatar {
		width: 2.5rem;
		height: 2.5rem;
	}

	.congresista-row__main {
		gap: 0.75rem;
	}

	.congresista-row__identity h3 {
		font-size: 0.88rem;
	}

	.congresista-row__group {
		margin-top: 0.1rem;
	}

	.congresista-row__group,
	.congresista-row__district,
	.congresista-row__email {
		padding-left: 0;
	}

	.congresista-row__email {
		padding-right: 2.4rem;
	}

	.congresista-results__footer {
		align-items: stretch;
		gap: 0.75rem;
		padding-left: 0.7rem;
		padding-right: 0.7rem;
		padding-top: 0.85rem;
		padding-bottom: 0.85rem;
	}

	.congresista-pagination {
		justify-content: flex-start;
		gap: 0.35rem;
	}

	.congresista-per-page select {
		width: 100%;
	}
}
