/* ===================================
   GAZHAL JURISPRUDENCIAS
   =================================== */
html {
	overflow-x: hidden;
}

body{
	overflow-x: hidden;
    background:#f4f7fb;
    font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
}
/* contenedor principal */

.gzl-juris-container{
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    background:white;
    border-radius:12px;
    padding:20px;
    box-shadow:0 4px 15px rgba(0,0,0,0.05);
}

*{
	box-sizing:border-box;
}



.juris-titulo{
    font-size:15px;
    font-weight:600;
    line-height:1.5;
    text-transform:none; /* ðŸ”¥ QUITA MAYÃšSCULAS */
}

.juris-meta{
    font-size:13px;
    opacity:.85;
}

.filtros-container {
	display: flex;
	gap: 10px;
	flex-wrap: wrap;
}

/* BADGES */
.badge-fuente{
    padding:4px 8px;
    border-radius:6px;
    font-size:11px;
    font-weight:600;
	margin-bottom:10px;
    display:inline-block;
}

.badge-scjn{
    background:#0f2f76;
    color:white;
}

.badge-tfja{
    background:#0093C9;
    color:white;
}

/* TEXTO */
.dof-link{
    color:#0f2f76;
    text-decoration:none;
}

.dof-link:hover{
    color:#0093C9;
    text-decoration:underline;
}
.juris-texto{
    white-space:pre-line;
    line-height:1.5;
    font-size:14px;
    color:#2c3e50;
	margin-top:15px;
	text-align: justify;
}

.juris-seccion{
    margin-top:20px;
}

.gzl-card-title{
    font-size:16px;
    font-weight:600;
    margin-bottom:10px;
}
.gzl-card{
    background:white;
    margin-top:15px;
    padding:22px;
    border-radius:12px;
    box-shadow:0 4px 15px rgba(0,0,0,0.05);
}
.tc-table td:first-child{
    width:220px;
    color:#555;
}
.juris-texto h3{
    margin-top:25px;
    color:#0f2f76;
    font-size:16px;
    border-left:4px solid #0093C9;
    padding-left:10px;
}

.juris-texto p{
    margin-bottom:14px;
    line-height:1.8;
    color:#2c3e50;
    text-align:justify;
}

.juris-publicacion p{
line-height:1.75;
font-size:15px;
color: #C00;
text-align:justify;        /* ? JUSTIFICADO */
}

.juris-texto br{
    display:block;
    margin-bottom:10px;
}
.juris-texto p:first-child{
    margin-top:10px;
}
.juris-rubro{
    font-weight:600;
    font-size:14px;
    margin:20px 0;
    border-bottom:1px solid #ddd;
    padding-bottom:10px;
}
.juris-ficha{
    display:grid;
    grid-template-columns:repeat(3,1fr);
    gap:10px 30px;
    font-size:13px;
    margin-top:10px;
}

@media (max-width: 768px) {

    .filtros-container {
        flex-direction: column;
    }

    .filtros-container input,
    .filtros-container select,
    .filtros-container button {
        width: 100%;
    }

    .filtros-container button {
        font-weight: bold;
        padding: 12px;
    }

}

@media print{
    .btn-gzl{
        display:none;
    }
}
.juris-nav{
    display:flex;
    justify-content:space-between;
    margin:15px 0;
}
.juris-item{
    padding:18px 0;
    border-bottom:1px solid #e5e7eb;
}

.juris-item-head{
    display:flex;
    justify-content:space-between;
    align-items:center;
    margin-bottom:6px;
}

.juris-link{
    display:block;
    font-size:15px;
    font-weight:600;
    color:#0f2f76;
    text-decoration:none;
    line-height:1.4;
}

.juris-link:hover{
    color:#0093C9;
    text-decoration:underline;
}

.juris-meta{
    font-size:12px;
    color:#6b7280;
    margin-top:6px;
}

.juris-fecha{
    font-size:12px;
    color:#9ca3af;
}
.juris-link{
    display:-webkit-box;
    -webkit-line-clamp:2;
    -webkit-box-orient:vertical;
    overflow:hidden;
}


.btn-limpiar {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 8px 14px;
    height: 36px;

    border-radius: 8px;
    border: 1px solid #d1d5db;

    background: #ffffff;
    color: #374151;

    font-size: 14px;
    font-weight: 500;
    text-decoration: none;

    transition: all 0.2s ease;
    cursor: pointer;
}

/* HOVER */
.btn-limpiar:hover {
    background: #f9fafb;
    border-color: #9ca3af;
}

/* ACTIVO (click) */
.btn-limpiar:active {
    transform: scale(0.97);
}

.btn-gzl:hover{
    background:#42a5f5;
}

.btn-gzl-secundario{
    background:#eef2ff;
}

.hl{
    background:#fff3a3;
    padding:2px 4px;
    border-radius:3px;
}


.toolbar-col{
    flex: 1;
    display: flex;
    align-items: center;
}

.toolbar-col.left{
    justify-content: flex-start;
    gap: 8px;
}

.toolbar-col.center{
    justify-content: center;
    text-align: center;
    font-weight: 600;
}

.toolbar-col.right{
    justify-content: flex-end;
    gap: 10px;
}
/* grupo flechas + contador */
.juris-nav-group{
    display:flex;
    align-items:center;
    gap:8px;
}
.juris-index-group{
    margin-left:10px;
}
.juris-indicador{
    font-size:12px;
    color:#6b7280;
    padding:0 10px;
}
.btn-secundario{
    background:#e5e7eb;
    color:#374151;
}

.btn-secundario:hover{
    background:#d1d5db;
}

.btn-icon{
    padding:8px 10px;
    font-size:16px;
}

/* ===================================
   GAZHAL JURISPRUDENCIAS
   =================================== */
body{
	overflow-x: hidden;
    background:#f4f7fb;
    font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
}
/* contenedor principal */



/* HEADER */
.juris-header{
    background:#f1f5f9;
    color:#0f2f76;
    padding:15px 18px;
    border-radius:10px;
    margin-bottom:15px;
    border-left:4px solid #0093C9;
}

.juris-titulo{
    font-size:15px;
    font-weight:600;
    line-height:1.5;
    text-transform:none; /* ðŸ”¥ QUITA MAYÃšSCULAS */
}

.juris-meta{
    font-size:13px;
    opacity:.85;
}

/* BADGES */
.badge-fuente{
    padding:4px 8px;
    border-radius:6px;
    font-size:11px;
    font-weight:600;
	margin-bottom:10px;
    display:inline-block;
}

.badge-scjn{
    background:#0f2f76;
    color:white;
}

.badge-tfja{
    background:#0093C9;
    color:white;
}

/* TEXTO */
.dof-link{
    color:#0f2f76;
    text-decoration:none;
}

.dof-link:hover{
    color:#0093C9;
    text-decoration:underline;
}
.juris-texto{
    white-space:pre-line;
    line-height:1.7;
    font-size:14px;
    color:#2c3e50;
	margin-top:15px;
}

.juris-seccion{
    margin-top:20px;
}

.paginacion {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin: 30px 0;
    flex-wrap: wrap;
}

/* BOTONES */
.pag-num, .pag-btn {
	box-shadow: 0 1px 2px rgba(0,0,0,0.05);
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-width: 36px;
    height: 36px;

    padding: 0 12px;
    border-radius: 8px;

    text-decoration: none;
    font-size: 14px;
    font-weight: 500;

    color: #374151;
    background: #f3f4f6;

    border: 1px solid #e5e7eb;

    transition: all .2s ease;
}

/* HOVER */
.pag-num:hover, .pag-btn:hover {
    background: #e5e7eb;
    transform: translateY(-2px);
}

/* ACTIVO */
.pag-num.activo {
    background: #0f2f76;
    color: white;
    border-color: #0f2f76;
    font-weight: 600;
}

/* FLECHAS */
.pag-btn {
    font-weight: bold;
}


.gzl-card-title{
    font-size:16px;
    font-weight:600;
    margin-bottom:10px;
}
.gzl-card{
    background:white;
    margin-top:15px;
    padding:22px;
    border-radius:12px;
    box-shadow:0 4px 15px rgba(0,0,0,0.05);
}
.tc-table td:first-child{
    width:220px;
    color:#555;
}
.juris-texto h3{
    margin-top:25px;
    color:#0f2f76;
    font-size:16px;
    border-left:4px solid #0093C9;
    padding-left:10px;
}

.juris-texto p{
    margin-bottom:14px;
    line-height:1.8;
    color:#2c3e50;
    text-align:justify;
}

.juris-publicacion p{
line-height:1.75;
font-size:15px;
color: #C00;
text-align:justify;        /* ? JUSTIFICADO */
}

.juris-texto br{
    display:block;
    margin-bottom:10px;
}
.juris-texto p:first-child{
    margin-top:10px;
}
.juris-rubro{
    font-weight:600;
    font-size:14px;
    margin:20px 0;
    border-bottom:1px solid #ddd;
    padding-bottom:10px;
}
.juris-ficha{
    display:grid;
    grid-template-columns:repeat(3,1fr);
    gap:10px 30px;
    font-size:13px;
    margin-top:10px;
}

/* botón base */
.btn-gzl{
    background:#0f2f76;
    color:white;
    border:none;
    padding:10px 16px;
    border-radius:8px;
    font-size:13px;
    cursor:pointer;
    transition:.2s;
    font-weight:500;
    display:inline-block;
    text-decoration:none;
}

/* ocultar en impresión */
@media print{
    .btn-gzl{
        display:none !important;
    }
}
}
.juris-nav{
    display:flex;
    justify-content:space-between;
    margin:15px 0;
}
.juris-item{
    padding:18px 0;
    border-bottom:1px solid #e5e7eb;
}

.juris-item-head{
    display:flex;
    justify-content:space-between;
    align-items:center;
    margin-bottom:6px;
}

.juris-link{
    display:block;
    font-size:15px;
    font-weight:600;
    color:#0f2f76;
    text-decoration:none;
    line-height:1.4;
}

.juris-link:hover{
    color:#0093C9;
    text-decoration:underline;
}

.juris-meta{
    font-size:12px;
    color:#6b7280;
    margin-top:6px;
}

.juris-fecha{
    font-size:12px;
    color:#9ca3af;
}
.juris-link{
    display:-webkit-box;
    -webkit-line-clamp:2;
    -webkit-box-orient:vertical;
    overflow:hidden;
}
.btn-gzl{
    background:#0f2f76;
    color:white;
    border:none;
    padding:10px 16px;
    border-radius:8px;
    font-size:13px;
    cursor:pointer;
    transition:.2s;
    font-weight:500;
    display:inline-block;
    text-decoration:none;
}

.btn-gzl:hover{
    background:#42a5f5;
}

.btn-gzl-secundario{
    background:#eef2ff;
}

.hl{
    background:#fff3a3;
    padding:2px 4px;
    border-radius:3px;
}
.juris-toolbar{
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
}

@media (max-width: 768px) {

    .juris-toolbar {
        gap: 6px;
    }

    .toolbar-col.center {
        font-size: 13px;
    }

}

.toolbar-col{
    flex: 1;
    display: flex;
    align-items: center;
}

.toolbar-col.left{
    justify-content: flex-start;
    gap: 8px;
}

.toolbar-col.center{
    justify-content: center;
    text-align: center;
    font-weight: 600;
}

.toolbar-col.right{
    justify-content: flex-end;
    gap: 10px;
}

@media (max-width: 768px) {

    .toolbar-col.right {
        width: 100%;
        justify-content: space-between;
    }

}

/* grupo flechas + contador */
.juris-nav-group{
    display:flex;
    align-items:center;
    gap:8px;
}
.juris-index-group{
    margin-left:10px;
}
.juris-indicador{
    font-size:12px;
    color:#6b7280;
    padding:0 10px;
}
.btn-secundario{
    background:#e5e7eb;
    color:#374151;
}

.btn-secundario:hover{
    background:#d1d5db;
}

.btn-icon{
    padding:8px 10px;
    font-size:16px;
}

.tesis-detalle {
	display:flex;
	gap: 20px;
	flex-wrap: wrap;
	font-size:13px;
}

@media (max-width: 768px) {

    .tesis-detalle {
        flex-direction: column;
    }

    .tesis-detalle div {
        width: 100%;
    }

}

@media (max-width: 768px) {

    .nav-tesis {
        display: flex;
        justify-content: space-between;
        gap: 10px;
    }

    .nav-tesis a {
        flex: 1;
        text-align: center;
        padding: 10px;
    }

}

@media (max-width: 768px) {

    .pagination {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 6px;
    }

}

@media (max-width: 768px) {

    .filtros-container {
        position: sticky;
        top: 0;
        background: white;
        z-index: 10;
        padding: 10px;
    }

}

.tesis-container {
	width: 100%;
	max-width: 100%;
	overflow-x: hidden;
}

.tesis-item,
.tesis-item * {
    overflow-wrap: break-word;
    word-break: break-word;
}

.tesis-item {
    background: white;
    border-radius: 10px;
    padding: 14px;
    margin-bottom: 12px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
	overflow: hidden;
}

@media (max-width: 768px) {

    .tesis-item {
        padding: 12px;
    }

}

.tesis-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

@media (max-width: 768px) {

    .tesis-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }

}

@media (max-width: 768px) {

    .tesis-detalle {
        display: grid !important;
		grid-template-columns: 1fr !important;
        gap: 10px;
    }

    .tesis-detalle strong {
        display: block;
        font-size: 13px;
        color: #6b7280;
    }

}

.btn-home {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: #e5e7eb;
    border-radius: 8px;
    text-decoration: none;
    font-size: 18px;
}

.btn-home:hover {
    background: #d1d5db;
}

@media (max-width: 768px) {

    .tesis-toolbar {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }

    /* ?? centro */
    .resultado-info {
        text-align: center;
        font-size: 14px;
        font-weight: 600;
    }

    /* ?? navegación */
    .nav-botones {
        display: flex;
        justify-content: space-between;
        gap: 10px;
    }

}

.btn-icon {
    width: 38px;
    height: 38px;
    background: #e5e7eb;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    font-size: 16px;
}

.btn-nav {
    flex: 1;
    text-align: center;
    padding: 10px;
    background: #1e3a8a;
    color: white;
    border-radius: 10px;
    text-decoration: none;
	display: inline-flex !important;
}

@media (max-width: 768px) {

    .juris-index-group a,
    .btn-gzl-secundario {
        font-size: 12px !important;
        padding: 6px 10px !important;
        white-space: nowrap;
    }

}

.gzl-card,
.juris-texto,
.juris-ficha {
	max-width: 100%;
	overflow-x: hidden;
}

.juris-texto
.juris-ficha,
.juris-texto * {
	word-break: break-word;
	overflow-wrap: break-word;
}

@media (max-width: 768px) {

    .resultado-info {
        text-align: center;
        font-size: 13px;
    }

    .nav-botones {
        display: flex;
        justify-content: space-between;
        width: 100%;
    }

}

.btn-texto {
	padding: 8px 12px;
	font-size: 13px;
	white-space:nowrap;
}

@media (max-width: 768px) {

    .btn-texto {
        font-size: 12px;
        padding: 6px 10px;
    }

}



/* CENTRO */
.resultado-info {
    flex: 1;
    text-align: center;
    font-weight: 600;
	min-width: 150px;
}

/* DERECHA */
.nav-botones {
    display: flex;
    gap: 8px;
}

@media (min-width: 769px) {

    .juris-toolbar {
		position:relative;
        display: flex;
		flex-direction: column;
        gap: 10px;
    }
}

@media (min-width: 769px) {

    .acciones {
        display: flex;
        justify-content: space-between;
		align-items: center;
        width: 100%;
    }
   .grupo-der,
   .grupo-izq {
        display: flex;
        gap: 6px;
    }

}

@media (min-width: 769px) {

    .resultado-info {
        text-align: center;
        font-weight: 600;
		font-size: 14px;
        width: 100%;
    }

}

@media (min-width: 769px) {

    .nav-botones {
		position:absolute;
		top: 85%;
		left: 50%;
		transform: translate(-50%,-50%);
        display: flex;
        justify-content: flex-end;
        gap: 250px;
		pointer-events: none;
    }

    .nav-botones a {
		pointer-events: auto;
		width: 34px !important;
		height: 32px;
		display: flex;
		align-items: center;
		justify-content: center;
      
    }

}

@media (max-width: 768px){

    .acciones{
        display: flex !important;
        flex-direction: row !important;
        flex-wrap: nowrap !important;

        gap: 8px;
        overflow-x: auto;
    }

    /* ?? ESTE ES EL FIX CLAVE */
    .acciones > div{
        display: contents !important;
    }

    .acciones a{
        flex: 0 0 auto !important;

        display: flex;
        align-items: center;
        justify-content: center;

        height: 42px;
        min-width: 42px;
        padding: 0 10px;

        border-radius: 10px;
        white-space: nowrap;
    }

}

/* ====================================
   FIX NAVEGACIÓN — agregar al final
   de gazhal-juris.css
   ==================================== */

/* Placeholder invisible que ocupa el lugar
   del botón cuando no existe, manteniendo
   el layout simétrico */
.btn-nav-placeholder {
    width: 38px;
    height: 38px;
    display: inline-block;
    visibility: hidden;
    flex-shrink: 0;
}

/* Asegura que nav-botones siempre tenga
   sus dos slots alineados en extremos */
.nav-botones {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-width: 90px; /* espacio fijo para 2 botones */
}

.toolbar-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    min-height: 42px;   /* ? reserva espacio aunque el slot esté vacío */
}
/* =========================
   UNIFICACIÓN FILTROS GAZHAL
========================= */

.filtro-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-width: 160px;
}

.filtro-label {
    font-size: 11px;
    color: #64748b;
    font-weight: 700;
    text-transform: uppercase;
}

.filtro-input {
    padding: 10px 12px;
    border-radius: 6px;
    border: 1px solid #cbd5e1;
    background: white;
    font-size: 14px;
}
/* Tom Select estilo Gazhal */
.ts-control {
    border-radius: 6px !important;
    border: 1px solid #cbd5e1 !important;
    padding: 6px 10px !important;
    font-size: 14px;
}

.ts-dropdown {
    border-radius: 8px !important;
    border: 1px solid #e2e8f0 !important;
    box-shadow: 0 10px 25px rgba(0,0,0,0.08);
}

.ts-dropdown .option {
    padding: 10px;
    font-size: 14px;
}

.ts-dropdown .option.active {
    background: #0f2f76 !important;
    color: white;
}
/* quitar estilo duplicado */
.ts-wrapper .ts-control {
    border: 1px solid #cbd5e1 !important;
    box-shadow: none !important;
}

/* elimina borde del select original oculto */
.ts-wrapper select {
    border: none !important;
}
/* días con datos */
.flatpickr-day.has-data {
    background: #0f2f76 !important;
    color: #ffffff !important;
    border-radius: 6px;
    font-weight: 700;
}


/* días sin datos */
.flatpickr-day.no-data {
    opacity: 0.25;
    pointer-events: none;
}