/*
 * FILE: assets/css/components/linea-de-accion.css
 * PAGE: Línea de acción — /linea-de-accion
 * Paleta: #003824 verde, #1758A0 azul, #E94E89 magenta, #ECE249 amarillo
 */

/* ============================================================
   HERO
   ============================================================ */
.lda-hero {
    position: relative;
    background: #021f14;
    color: #fff;
    padding: clamp(5rem, 9vw, 8rem) 0 clamp(4rem, 7vw, 7rem);
    overflow: hidden;
    border-bottom: 1px solid rgba(69,168,90,0.10);
}

.lda-hero__bg {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.lda-hero__bg-glow {
    position: absolute;
    border-radius: 50%;
    filter: blur(90px);
}

.lda-hero__bg-glow--green {
    width: 500px;
    height: 500px;
    background: #45A85A;
    top: -100px;
    left: -80px;
    opacity: 0.28;
}

.lda-hero__bg-glow--blue {
    width: 380px;
    height: 380px;
    background: #1758A0;
    top: 40px;
    right: 8%;
    opacity: 0.20;
}

.lda-hero__bg-glow--magenta {
    width: 260px;
    height: 260px;
    background: #E94E89;
    bottom: -40px;
    right: 28%;
    opacity: 0.14;
}

.lda-hero__inner {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(3rem, 6vw, 6rem);
    align-items: center;
}

/* ── Left ──────────────────────────────────────────────────── */
.lda-hero__left {
    display: flex;
    flex-direction: column;
    gap: var(--space-7);
}

.lda-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 5px 16px;
    border: 1px solid rgba(69,168,90,0.35);
    border-radius: 999px;
    background: rgba(69,168,90,0.07);
    color: #7dce8e;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    width: fit-content;
}

.lda-hero__title {
    font-family: var(--font-display);
    font-size: clamp(2.8rem, 5vw, 4.2rem);
    font-weight: 800;
    line-height: 1.04;
    letter-spacing: -0.04em;
    color: #fff;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.04em;
}

.lda-hero__title-accent {
    color: #45A85A;
}

.lda-hero__title-place {
    font-size: 0.52em;
    font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.32);
    margin-top: 0.3em;
}

.lda-hero__norms {
    display: flex;
    align-items: stretch;
    padding-top: var(--space-4);
    border-top: 1px solid rgba(255,255,255,0.06);
}

.lda-hero__norm {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 0 var(--space-4);
}

.lda-hero__norm:first-child { padding-left: 0; }

.lda-hero__norm-label {
    font-size: 0.88rem;
    font-weight: 700;
    line-height: 1.2;
}

.lda-hero__norm-label--green  { color: #7dce8e; }
.lda-hero__norm-label--blue   { color: #7aabdf; }
.lda-hero__norm-label--pink   { color: #f09bbf; }

.lda-hero__norm-desc {
    font-size: 0.68rem;
    color: rgba(255,255,255,0.35);
}

.lda-hero__norm-sep {
    width: 1px;
    background: rgba(255,255,255,0.08);
    align-self: stretch;
    flex-shrink: 0;
}

/* ── Right ─────────────────────────────────────────────────── */
.lda-hero__right {
    display: flex;
    flex-direction: column;
    gap: var(--space-6);
    padding-left: var(--space-8);
    border-left: 1px solid rgba(255,255,255,0.07);
}

.lda-hero__lead {
    font-size: clamp(1rem, 1.5vw, 1.1rem);
    line-height: 1.78;
    color: rgba(255,255,255,0.72);
    margin: 0;
}

.lda-hero__body {
    font-size: clamp(0.88rem, 1.2vw, 0.96rem);
    line-height: 1.82;
    color: rgba(255,255,255,0.46);
    margin: 0;
}

.lda-hero__lead strong,
.lda-hero__body strong {
    color: rgba(255,255,255,0.88);
    font-weight: 600;
}

/* ============================================================
   SECCIÓN GRID DE EJES
   ============================================================ */
.lda-ejes {
    background: #f6fbf7;
    padding: clamp(5rem, 8vw, 8rem) 0 clamp(5rem, 9vw, 9rem);
}

.lda-ejes__header {
    margin-bottom: clamp(2.5rem, 5vw, 4rem);
    max-width: 560px;
}

.lda-ejes__tag {
    display: inline-block;
    font-size: 0.66rem;
    font-weight: 700;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: #45A85A;
    margin-bottom: var(--space-3);
}

.lda-ejes__title {
    font-family: var(--font-display);
    font-size: clamp(1.8rem, 3vw, 2.4rem);
    font-weight: 800;
    color: #003824;
    line-height: 1.15;
    letter-spacing: -0.03em;
    margin: 0 0 var(--space-3);
}

.lda-ejes__lead {
    font-size: var(--text-base);
    color: rgba(0,56,36,0.58);
    line-height: 1.7;
    margin: 0;
}

/* Grid 4 columnas */
.lda-ejes__grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--space-5);
}

/* ── Card de eje ────────────────────────────────────────── */
.lda-eje {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
    padding: clamp(1.4rem, 2vw, 1.8rem);
    background: #fff;
    border: 1px solid rgba(0,56,36,0.08);
    border-radius: 16px;
    overflow: hidden;
    transition:
        transform        0.28s cubic-bezier(0.16,1,0.3,1),
        box-shadow       0.28s ease,
        border-color     0.28s ease;
}

.lda-eje:hover {
    transform: translateY(-5px);
    box-shadow: 0 16px 40px rgba(0,56,36,0.10);
    border-color: rgba(0,56,36,0.14);
}

/* Número grande de fondo */
.lda-eje__num {
    position: absolute;
    top: -8px;
    right: 12px;
    font-family: var(--font-display);
    font-size: 4.5rem;
    font-weight: 900;
    color: rgba(0,56,36,0.04);
    line-height: 1;
    pointer-events: none;
    user-select: none;
}

/* Ícono */
.lda-eje__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 12px;
    flex-shrink: 0;
    transition: background-color 0.25s ease;
}

.lda-eje__icon--green {
    background: rgba(69,168,90,0.10);
    color: #45A85A;
}
.lda-eje__icon--green:hover,
.lda-eje:hover .lda-eje__icon--green {
    background: rgba(69,168,90,0.18);
}

.lda-eje__icon--blue {
    background: rgba(23,88,160,0.10);
    color: #1758A0;
}
.lda-eje:hover .lda-eje__icon--blue {
    background: rgba(23,88,160,0.18);
}

.lda-eje__icon--pink {
    background: rgba(233,78,137,0.09);
    color: #E94E89;
}
.lda-eje:hover .lda-eje__icon--pink {
    background: rgba(233,78,137,0.16);
}

.lda-eje__icon--yellow {
    background: rgba(236,226,73,0.14);
    color: #a89a00;
}
.lda-eje:hover .lda-eje__icon--yellow {
    background: rgba(236,226,73,0.24);
}

/* Barra superior de color en hover */
.lda-eje::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 2px;
    transform: scaleX(0);
    transition: transform 0.30s cubic-bezier(0.16,1,0.3,1);
}

.lda-eje:has(.lda-eje__icon--green)::before  { background: #45A85A; }
.lda-eje:has(.lda-eje__icon--blue)::before   { background: #1758A0; }
.lda-eje:has(.lda-eje__icon--pink)::before   { background: #E94E89; }
.lda-eje:has(.lda-eje__icon--yellow)::before { background: #ECE249; }

.lda-eje:hover::before { transform: scaleX(1); }

.lda-eje__title {
    font-family: var(--font-display);
    font-size: 0.92rem;
    font-weight: 700;
    color: #003824;
    line-height: 1.3;
    margin: 0;
}

.lda-eje__desc {
    font-size: 0.80rem;
    line-height: 1.68;
    color: rgba(0,56,36,0.58);
    margin: 0;
    flex: 1;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1200px) {
    .lda-ejes__grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 900px) {
    .lda-hero__inner {
        grid-template-columns: 1fr;
        gap: var(--space-10);
    }
    .lda-hero__right {
        padding-left: 0;
        border-left: none;
        border-top: 1px solid rgba(255,255,255,0.07);
        padding-top: var(--space-8);
    }
    .lda-hero__bg-glow--blue,
    .lda-hero__bg-glow--magenta { display: none; }
    .lda-ejes__grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 560px) {
    .lda-ejes__grid { grid-template-columns: 1fr; }
    .lda-hero__norms { flex-direction: column; gap: var(--space-4); }
    .lda-hero__norm { padding: 0; }
    .lda-hero__norm-sep { display: none; }
}

/* ============================================================
   INTERACTIVIDAD DE CARD
   ============================================================ */
.lda-eje {
    cursor: pointer;
}

/* Focus visible para navegación por teclado — box-shadow en lugar de
   outline porque el card tiene overflow:hidden que recorta el outline */
.lda-eje:focus-visible {
    outline: none;
    box-shadow:
        0 0 0 3px rgba(69,168,90,0.55),
        0 16px 40px rgba(0,56,36,0.10);
    transform: translateY(-5px);
}

/* ============================================================
   MODAL — <dialog> nativo
   El <dialog> ES la caja visual: position:fixed + inset:0 + margin:auto
   la centra en el viewport sin depender de flexbox en el top-layer.
   dialog[open].lda-modal anula el display:block del UA stylesheet.
   ============================================================ */
.lda-modal {
    position: fixed;
    inset: 0;
    margin: auto;
    padding: 0;
    border: none;
    background: #fff;
    border-radius: 24px;
    width: min(720px, 90vw);
    max-height: min(86vh, calc(100dvh - 3rem));
    overflow: hidden;
    box-shadow:
        0 8px 16px rgba(0,0,0,0.06),
        0 32px 80px rgba(0,0,0,0.20),
        0 0 0 1px rgba(0,56,36,0.07);
}

dialog[open].lda-modal {
    display: flex;
    flex-direction: column;
}

.lda-modal::backdrop {
    background: rgba(0,0,0,0.58);
    backdrop-filter: blur(5px);
}

/* ── Wrap interno: scroll cuando el contenido es largo ───── */
.lda-modal__wrap {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
}

/* ── Topbar: badge + botón cerrar ────────────────────────── */
.lda-modal__topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.1rem 1.5rem;
    border-bottom: 1px solid rgba(0,56,36,0.07);
    flex-shrink: 0;
}

/* Acento de color en la parte superior del topbar */
.lda-modal[data-color="green"]  .lda-modal__topbar { border-top: 4px solid #45A85A; }
.lda-modal[data-color="blue"]   .lda-modal__topbar { border-top: 4px solid #1758A0; }
.lda-modal[data-color="pink"]   .lda-modal__topbar { border-top: 4px solid #E94E89; }
.lda-modal[data-color="yellow"] .lda-modal__topbar { border-top: 4px solid #ECE249; }

.lda-modal__badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 12px;
    border-radius: 999px;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.lda-modal[data-color="green"]  .lda-modal__badge { background: rgba(69,168,90,0.12);  color: #205F3E; }
.lda-modal[data-color="blue"]   .lda-modal__badge { background: rgba(23,88,160,0.12);  color: #1758A0; }
.lda-modal[data-color="pink"]   .lda-modal__badge { background: rgba(233,78,137,0.10); color: #b5185a; }
.lda-modal[data-color="yellow"] .lda-modal__badge { background: rgba(236,226,73,0.22); color: #7a6e00; }

.lda-modal__close {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: none;
    background: rgba(0,56,36,0.05);
    color: rgba(0,56,36,0.50);
    cursor: pointer;
    flex-shrink: 0;
    transition: background 0.18s ease, color 0.18s ease;
}
.lda-modal__close:hover         { background: rgba(0,56,36,0.10); color: #003824; }
.lda-modal__close:focus-visible { outline: 2px solid #45A85A; outline-offset: 2px; }

/* ── Hero: icono + título ────────────────────────────────── */
.lda-modal__hero {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 1.25rem;
    padding: 2.5rem 2.5rem 2rem;
    background: rgba(0,56,36,0.015);
}

.lda-modal__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 76px;
    height: 76px;
    border-radius: 22px;
    flex-shrink: 0;
}
.lda-modal[data-color="green"]  .lda-modal__icon { background: rgba(69,168,90,0.13);  color: #45A85A; }
.lda-modal[data-color="blue"]   .lda-modal__icon { background: rgba(23,88,160,0.12);  color: #1758A0; }
.lda-modal[data-color="pink"]   .lda-modal__icon { background: rgba(233,78,137,0.11); color: #E94E89; }
.lda-modal[data-color="yellow"] .lda-modal__icon { background: rgba(236,226,73,0.20); color: #a89a00; }

.lda-modal__title {
    font-family: var(--font-display);
    font-size: clamp(1.4rem, 3vw, 1.85rem);
    font-weight: 800;
    color: #003824;
    line-height: 1.2;
    letter-spacing: -0.03em;
    margin: 0;
}

/* ── Separador ───────────────────────────────────────────── */
.lda-modal__sep {
    height: 1px;
    background: rgba(0,56,36,0.09);
    flex-shrink: 0;
}

/* ── Cuerpo: descripción ─────────────────────────────────── */
.lda-modal__body {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    padding: 2rem 2.5rem;
    flex: 1;
}

.lda-modal__body-label {
    font-size: 0.63rem;
    font-weight: 700;
    letter-spacing: 0.20em;
    text-transform: uppercase;
    color: rgba(0,56,36,0.35);
}

.lda-modal__desc {
    font-size: 0.97rem;
    line-height: 1.84;
    color: rgba(0,56,36,0.72);
    margin: 0;
}

/* ── Footer: botón cerrar ────────────────────────────────── */
.lda-modal__footer {
    display: flex;
    justify-content: center;
    padding: 1.25rem 2.5rem 1.75rem;
    border-top: 1px solid rgba(0,56,36,0.07);
    flex-shrink: 0;
}

.lda-modal__btn-cerrar {
    padding: 11px 40px;
    border-radius: 999px;
    border: none;
    background: #45A85A;
    color: #fff;
    font-family: var(--font-display);
    font-size: 0.88rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    cursor: pointer;
    transition: background 0.20s ease, transform 0.15s ease;
}
.lda-modal__btn-cerrar:hover         { background: #3a9450; transform: translateY(-1px); }
.lda-modal__btn-cerrar:focus-visible { outline: 2px solid #45A85A; outline-offset: 3px; }

@media (max-width: 560px) {
    .lda-modal {
        width: calc(100vw - 2rem);
        max-height: calc(100dvh - 3rem);
        border-radius: 20px;
    }
    .lda-modal__hero   { padding: 2rem 1.5rem 1.5rem; }
    .lda-modal__body   { padding: 1.5rem; }
    .lda-modal__footer { padding: 1rem 1.5rem 1.5rem; }
}
