
/* =========================================
   PREPARATUENSAYO - RECURSOS
========================================= */

.resources-hero {
    padding: 85px 0 90px;
    background: linear-gradient(135deg, #F8FAFC, #EFF6FF);
    text-align: center;
}

.resources-hero-content {
    max-width: 760px;
    margin: auto;
}

.resources-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #1D4ED8;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1.5px;
}

.resources-eyebrow i {
    width: 16px;
}

.resources-hero h1 {
    margin: 20px 0 15px;
    color: #172033;
    font-size: clamp(38px, 5vw, 55px);
    line-height: 1.12;
    letter-spacing: -2px;
    font-weight: 900;
}

.resources-hero h1 span {
    color: #1D4ED8;
}

.resources-hero-content > p {
    max-width: 620px;
    margin: auto;
    color: #64748B;
    font-size: 14px;
    line-height: 1.9;
}

/* BUSCADOR */

.resources-search {
    max-width: 620px;
    height: 58px;
    display: flex;
    align-items: center;
    gap: 13px;
    margin: 32px auto 0;
    padding: 6px 7px 6px 17px;
    border: 1px solid #E2E8F0;
    border-radius: 12px;
    background: #FFFFFF;
    box-shadow: 0 8px 25px rgba(30, 64, 175, .06);
}

.resources-search > i {
    width: 20px;
    color: #94A3B8;
    flex-shrink: 0;
}

.resources-search input {
    width: 100%;
    min-width: 0;
    border: none;
    outline: none;
    color: #172033;
    font-family: Inter, sans-serif;
    font-size: 13px;
    background: transparent;
}

.resources-search input::placeholder {
    color: #94A3B8;
}

.resources-search button {
    height: 44px;
    padding: 0 21px;
    border: none;
    border-radius: 8px;
    background: #1D4ED8;
    color: #FFFFFF;
    font-family: Inter, sans-serif;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: .2s;
}

.resources-search button:hover {
    background: #12316B;
}

.search-suggestions {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 18px;
    color: #94A3B8;
    font-size: 11px;
}

.search-suggestions button {
    border: none;
    padding: 0;
    background: transparent;
    color: #475569;
    font-family: Inter, sans-serif;
    font-size: 11px;
    cursor: pointer;
}

.search-suggestions button:hover {
    color: #1D4ED8;
}

/* ENCABEZADOS */

.section-heading {
    max-width: 600px;
    margin: 0 auto 40px;
    text-align: center;
}

.section-label {
    color: #1D4ED8;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1.5px;
}

.section-heading h2 {
    margin: 13px 0 10px;
    color: #172033;
    font-size: 32px;
    letter-spacing: -1px;
    font-weight: 800;
}

.section-heading p {
    color: #64748B;
    font-size: 13px;
    line-height: 1.8;
}

/* CATEGORÍAS */

.resource-categories {
    padding: 85px 0;
    background: #FFFFFF;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.category-card {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: 22px;
    border: 1px solid #E2E8F0;
    border-radius: 13px;
    background: #FFFFFF;
    text-align: left;
    cursor: pointer;
    transition: .2s ease;
}

.category-card:hover {
    border-color: #93C5FD;
    background: #F8FBFF;
    transform: translateY(-4px);
    box-shadow: 0 12px 25px rgba(15, 23, 42, .05);
}

.category-icon {
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    margin-bottom: 18px;
    border-radius: 11px;
}

.category-icon i {
    width: 21px;
}

.category-math {
    background: #DBEAFE;
    color: #1D4ED8;
}

.category-reading {
    background: #F3E8FF;
    color: #9333EA;
}

.category-science {
    background: #DCFCE7;
    color: #16A34A;
}

.category-history {
    background: #FEF3C7;
    color: #D97706;
}

.category-card strong {
    color: #172033;
    font-size: 13px;
    font-weight: 800;
}

.category-card > span:not(.category-icon) {
    margin-top: 6px;
    color: #94A3B8;
    font-size: 10px;
}

.category-arrow {
    position: absolute;
    top: 22px;
    right: 19px;
    width: 16px;
    color: #94A3B8;
}

/* BIBLIOTECA */

.resource-library {
    padding: 85px 0;
    background: #F8FAFC;
}

.library-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
}

.library-heading h2 {
    margin: 12px 0 8px;
    color: #172033;
    font-size: 32px;
    letter-spacing: -1px;
}

.library-heading p {
    color: #64748B;
    font-size: 13px;
}

.library-count {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 13px;
    border: 1px solid #E2E8F0;
    border-radius: 9px;
    background: #FFFFFF;
    color: #64748B;
    font-size: 11px;
    font-weight: 600;
    white-space: nowrap;
}

.library-count i {
    width: 16px;
    color: #1D4ED8;
}

/* FILTROS */

.resource-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    margin: 30px 0;
}

.filter-button {
    min-height: 37px;
    padding: 0 16px;
    border: 1px solid #E2E8F0;
    border-radius: 8px;
    background: #FFFFFF;
    color: #64748B;
    font-family: Inter, sans-serif;
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
    transition: .2s;
}

.filter-button:hover {
    border-color: #93C5FD;
    color: #1D4ED8;
}

.filter-button.active {
    border-color: #1D4ED8;
    background: #1D4ED8;
    color: #FFFFFF;
}

/* TARJETAS */

.resources-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.resource-card {
    overflow: hidden;
    border: 1px solid #E2E8F0;
    border-radius: 13px;
    background: #FFFFFF;
    transition: .25s ease;
}

.resource-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 14px 30px rgba(15, 23, 42, .07);
}

.resource-card[hidden] {
    display: none;
}

.resource-cover {
    position: relative;
    height: 165px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.resource-cover::before,
.resource-cover::after {
    position: absolute;
    content: "";
    border: 1px solid rgba(255,255,255,.18);
    border-radius: 50%;
}

.resource-cover::before {
    width: 190px;
    height: 190px;
}

.resource-cover::after {
    width: 125px;
    height: 125px;
}

.resource-cover > i {
    position: relative;
    z-index: 1;
    width: 57px;
    height: 57px;
    color: rgba(255,255,255,.95);
    stroke-width: 1.5;
}

.resource-type {
    position: absolute;
    top: 13px;
    left: 14px;
    z-index: 2;
    padding: 6px 9px;
    border-radius: 5px;
    background: rgba(255,255,255,.16);
    color: #FFFFFF;
    font-size: 8px;
    font-weight: 800;
    letter-spacing: 1px;
}

.cover-caption {
    position: absolute;
    right: 14px;
    bottom: 12px;
    z-index: 2;
    color: rgba(255,255,255,.65);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 2px;
}

.cover-math {
    background: linear-gradient(135deg, #1D4ED8, #12316B);
}

.cover-math-light {
    background: linear-gradient(135deg, #3B82F6, #2563EB);
}

.cover-purple {
    background: linear-gradient(135deg, #8B5CF6, #5B21B6);
}

.cover-reading {
    background: linear-gradient(135deg, #A855F7, #6B21A8);
}

.cover-science {
    background: linear-gradient(135deg, #16A34A, #166534);
}

.cover-physics {
    background: linear-gradient(135deg, #0F766E, #134E4A);
}

.cover-history {
    background: linear-gradient(135deg, #D97706, #92400E);
}

.cover-general {
    background: linear-gradient(135deg, #475569, #172033);
}

/* INFORMACIÓN */

.resource-info {
    padding: 19px;
}

.resource-meta {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    color: #1D4ED8;
    font-size: 9px;
    font-weight: 700;
}

.resource-meta span:last-child {
    color: #94A3B8;
    font-weight: 500;
}

.resource-info h3 {
    min-height: 40px;
    margin: 14px 0 8px;
    color: #172033;
    font-size: 14px;
    line-height: 1.4;
    font-weight: 800;
}

.resource-info p {
    min-height: 65px;
    margin: 0;
    color: #64748B;
    font-size: 11px;
    line-height: 1.8;
}

.resource-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 17px;
    padding-top: 14px;
    border-top: 1px solid #F1F5F9;
    color: #1D4ED8;
    font-size: 11px;
    font-weight: 800;
    text-decoration: none;
}

.resource-link i {
    width: 15px;
    transition: transform .2s;
}

.resource-link:hover i {
    transform: translateX(4px);
}

/* SIN RESULTADOS */

.resources-empty {
    padding: 55px 20px;
    text-align: center;
}

.resources-empty[hidden] {
    display: none;
}

.resources-empty > i {
    width: 42px;
    height: 42px;
    color: #94A3B8;
}

.resources-empty h3 {
    margin: 15px 0 8px;
    color: #172033;
    font-size: 18px;
}

.resources-empty p {
    color: #64748B;
    font-size: 12px;
}

.resources-empty button {
    margin-top: 13px;
    padding: 10px 17px;
    border: none;
    border-radius: 8px;
    background: #1D4ED8;
    color: #FFFFFF;
    font-weight: 700;
    cursor: pointer;
}

/* CTA */

.resources-cta {
    padding: 80px 0;
    background: #FFFFFF;
}

.resources-cta-card {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    overflow: hidden;
    padding: 48px 55px;
    border-radius: 17px;
    background: #12316B;
    color: #FFFFFF;
}

.resources-cta-card > div {
    max-width: 620px;
}

.resources-cta-card > div > span {
    color: #93C5FD;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1.4px;
}

.resources-cta-card h2 {
    margin: 15px 0 10px;
    font-size: 29px;
    line-height: 1.25;
}

.resources-cta-card p {
    color: #CBD5E1;
    font-size: 12px;
    line-height: 1.8;
}

.resources-cta-card a {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    margin-top: 13px;
    padding: 13px 18px;
    border-radius: 8px;
    background: #FFFFFF;
    color: #12316B;
    font-size: 11px;
    font-weight: 800;
    text-decoration: none;
}

.resources-cta-card a i {
    width: 15px;
}

.resources-cta-icon {
    width: 105px;
    height: 105px;
    margin-right: 35px;
    color: rgba(255,255,255,.17);
}

/* RESPONSIVE */

@media (max-width: 1100px) {
    .resources-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .category-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .resources-hero {
        padding: 65px 0;
    }

    .resources-hero h1 {
        font-size: 39px;
        letter-spacing: -1.5px;
    }

    .resource-categories,
    .resource-library {
        padding: 65px 0;
    }

    .resources-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 13px;
    }

    .library-heading {
        align-items: flex-start;
        flex-direction: column;
    }

    .resources-cta-card {
        padding: 35px 28px;
    }

    .resources-cta-icon {
        display: none;
    }
}

@media (max-width: 520px) {
    .resources-hero h1 {
        font-size: 33px;
    }

    .resources-search {
        height: 53px;
        gap: 8px;
        padding-left: 12px;
    }

    .resources-search input {
        font-size: 11px;
    }

    .resources-search button {
        height: 39px;
        padding: 0 13px;
        font-size: 10px;
    }

    .category-grid {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }

    .category-card {
        padding: 15px;
    }

    .category-card strong {
        font-size: 11px;
    }

    .category-card > span:not(.category-icon) {
        font-size: 9px;
    }

    .resources-grid {
        grid-template-columns: 1fr;
    }

    .resource-cover {
        height: 155px;
    }

    .resource-info h3,
    .resource-info p {
        min-height: auto;
    }

    .resource-filters {
        gap: 7px;
    }

    .filter-button {
        padding: 0 12px;
        font-size: 10px;
    }

    .resources-cta-card {
        padding: 30px 22px;
    }

    .resources-cta-card h2 {
        font-size: 24px;
    }
}
