/* ============================================================
   ESAL — Transparencia institucional
   views/Transparencia/ESAL.html
   ============================================================ */

/* Variables — usar las de styles.css si ya existen globalmente */
.esal-hero,
.esal-vigencia,
.esal-historico,
.esal-normativa {
    --navy:   #162341;
    --blue:   #4A60D8;
    --green:  #43B02A;
    --text:   #1a1a2e;
    --muted:  #6b7280;
    --bg:     #f8fafc;
    --white:  #ffffff;
    --border: #e5e7eb;
}

.esal-container {
    max-width: 960px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* --- Hero --- */
.esal-hero {
    background: var(--navy);
    color: var(--white);
    padding: 4rem 0 3rem;
}

.esal-eyebrow {
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--green);
    margin-bottom: 1rem;
    display: block;
}

.esal-hero h1 {
    font-size: clamp(1.75rem, 4vw, 2.75rem);
    font-weight: 700;
    line-height: 1.15;
    margin-bottom: 1rem;
    color: var(--white);
}

.esal-lead {
    font-size: 1.05rem;
    line-height: 1.75;
    color: rgba(255, 255, 255, 0.8);
    max-width: 640px;
    margin-bottom: 2rem;
}

.esal-meta-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 1.25rem;
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.6);
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    padding-top: 1.25rem;
}

.esal-meta-bar strong {
    color: rgba(255, 255, 255, 0.9);
}

/* --- Vigencia actual --- */
.esal-vigencia {
    padding: 3.5rem 0;
    background: var(--bg);
}

.esal-vigencia-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2rem;
}

.esal-vigencia-header h2 {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--navy);
    margin: 0;
}

.esal-badge {
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    padding: 0.3rem 0.75rem;
    border-radius: 999px;
    background: #d1fae5;
    color: #065f46;
    white-space: nowrap;
}

/* --- Grid de tarjetas --- */
.esal-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

@media (min-width: 640px) {
    .esal-grid {
        grid-template-columns: 1fr 1fr;
    }
}

.esal-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.875rem;
    transition: box-shadow 0.2s ease, border-color 0.2s ease;
}

.esal-card:hover {
    box-shadow: 0 4px 20px rgba(22, 35, 65, 0.09);
    border-color: var(--blue);
}

.esal-card-icon {
    font-size: 1.5rem;
    color: var(--blue);
}

.esal-card-body {
    flex: 1;
}

.esal-card-ref {
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--muted);
    margin-bottom: 0.35rem;
}

.esal-card-body h3 {
    font-size: 0.975rem;
    font-weight: 600;
    color: var(--navy);
    margin-bottom: 0.5rem;
    line-height: 1.35;
}

.esal-card-desc {
    font-size: 0.85rem;
    color: var(--muted);
    line-height: 1.65;
    margin: 0;
}

.esal-download {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--blue);
    text-decoration: none;
    padding-top: 0.75rem;
    border-top: 1px solid var(--border);
    margin-top: auto;
    transition: color 0.15s ease;
}

.esal-download:hover {
    color: var(--navy);
}

/* --- Aviso temporal pagos directivos --- */
.esal-notice {
    display: flex;
    gap: 0.75rem;
    align-items: flex-start;
    margin-top: 1.5rem;
    background: #fffbeb;
    border: 1px solid #fde68a;
    border-left: 4px solid #f59e0b;
    border-radius: 6px;
    padding: 1rem 1.25rem;
    font-size: 0.875rem;
    color: #92400e;
    line-height: 1.6;
}

.esal-notice i {
    color: #f59e0b;
    font-size: 1rem;
    margin-top: 0.15rem;
    flex-shrink: 0;
}

.esal-notice strong {
    color: #78350f;
}

/* --- Vigencias anteriores --- */
.esal-historico {
    padding: 3rem 0;
    background: var(--white);
    border-top: 1px solid var(--border);
}

.esal-historico h2 {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--navy);
    margin-bottom: 0.4rem;
}

.esal-historico-intro {
    font-size: 0.9rem;
    color: var(--muted);
    margin-bottom: 1.5rem;
}

.esal-historico-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
}

.esal-historico-card {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 1.25rem;
}

.esal-historico-card h3 {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--navy);
    margin-bottom: 0.35rem;
}

.esal-historico-card p {
    font-size: 0.8rem;
    color: var(--muted);
    margin-bottom: 0.75rem;
}

.esal-historico-link {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--blue);
    text-decoration: none;
}

.esal-historico-link:hover {
    text-decoration: underline;
}

/* --- Marco normativo --- */
.esal-normativa {
    padding: 3rem 0 4rem;
    background: var(--bg);
    border-top: 1px solid var(--border);
}

.esal-normativa h2 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--navy);
    margin-bottom: 0.75rem;
}

.esal-normativa p {
    font-size: 0.875rem;
    color: var(--muted);
    line-height: 1.75;
    max-width: 640px;
    margin-bottom: 1rem;
}

.esal-external {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--blue);
    text-decoration: none;
}

.esal-external:hover {
    text-decoration: underline;
}