/*
 * CLRD · Mauricio Colorado
 * category-archive.css — Páginas de taxonomía de portafolio
 * @package MansokaTheme
 */

/* ══════════════════════════════════════════════════════════════
 * 0. RESET DEL WRAPPER DEL TEMA
 * ══════════════════════════════════════════════════════════════ */
.tax-portfolio_category .site-content,
.tax-portfolio_category .content-area,
.tax-portfolio_category #page {
    max-width: 100%;
    padding: 0;
    margin: 0;
}

/* ══════════════════════════════════════════════════════════════
 * 1. BANNER — 450px, fondo blanco, ícono negro + nombre
 * ══════════════════════════════════════════════════════════════ */
.clrd-cat-banner {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 2.5rem;
    height: auto;
    min-height: 260px;
    background: #fff;
    width: 100%;
    padding: calc(var(--header-height, 80px) + 2.5rem) 10vw 6rem;
    box-sizing: border-box;
}

.clrd-cat-banner__icon {
    display: block;
    width: auto;
    height: 140px;
    flex-shrink: 0;
    /* Forzar negro independientemente del color original del icono */
    filter: brightness(0) saturate(100%);
    object-fit: contain;
}

.clrd-cat-banner__title {
    margin: 0;
    font-family: var(--font-primary, 'Inter', sans-serif);
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 400;
    letter-spacing: 0.02em;
    text-transform: lowercase;
    color: var(--clrd-black, #000);
    line-height: 1;
}

/* ══════════════════════════════════════════════════════════════
 * 2. PROYECTOS — full width, 600px alto, imagen de fondo
 * ══════════════════════════════════════════════════════════════ */
.clrd-cat-projects {
    display: block;
    width: 100%;
}

.clrd-cat-project {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    width: 100%;
    height: 600px;
    overflow: hidden;
    background-color: var(--clrd-black, #000);
    text-decoration: none;
    color: inherit;
    /* Separa los proyectos mínimamente */
    margin-bottom: 2px;
}

/* Imagen de fondo: zoom sutil en hover */
.clrd-cat-project__bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    z-index: 0;
    transition: transform 0.7s ease;
}

.clrd-cat-project:hover .clrd-cat-project__bg {
    transform: scale(1.06);
}

/* Overlay: oculto por defecto, aparece en hover — z-index sobre la imagen */
.clrd-cat-project__overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0);
    opacity: 0;
    z-index: 1;
    transition: background 0.45s ease, opacity 0.45s ease;
}

.clrd-cat-project:hover .clrd-cat-project__overlay {
    background: rgba(0, 0, 0, 0.55);
    opacity: 1;
}

/* Nombre del proyecto */
.clrd-cat-project__name {
    color: #fff;
    font-family: var(--font-primary, 'Inter', sans-serif);
    font-size: clamp(1.25rem, 3vw, 2.25rem);
    font-weight: 400;
    letter-spacing: 0.12em;
    text-transform: lowercase;
    text-align: center;
    padding: 0 2rem;
    transform: translateY(12px);
    transition: transform 0.45s ease;
}

.clrd-cat-project:hover .clrd-cat-project__name {
    transform: translateY(0);
}

/* Sin proyectos */
.clrd-cat-empty {
    text-align: center;
    padding: 80px 20px;
    font-size: 1rem;
    color: #888;
}

/* ══════════════════════════════════════════════════════════════
 * 3. FOOTER "THANKS" — imagen + heading + sub + botón ←
 * ══════════════════════════════════════════════════════════════ */
.clrd-cat-thanks {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 400px;
    padding: 80px 2rem;
    background: #fff;
    width: 100%;
    box-sizing: border-box;
}

.clrd-cat-thanks__inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    text-align: center;
    max-width: 480px;
}

.clrd-cat-thanks__img {
    display: block;
    max-width: 220px;
    width: 100%;
    height: auto;
    object-fit: contain;
}

.clrd-cat-thanks__heading {
    margin: 0;
    font-family: var(--font-primary, 'Inter', sans-serif);
    font-size: clamp(2.5rem, 6vw, 4rem);
    font-weight: 700;
    letter-spacing: -0.01em;
    color: var(--clrd-black, #000);
    line-height: 1;
}

.clrd-cat-thanks__sub {
    margin: 0;
    font-size: 0.9375rem;
    color: var(--clrd-black, #000);
    line-height: 1.5;
}

/* Botón ← círculo accent */
.clrd-cat-thanks__back {
    position: absolute;
    right: 2rem;
    bottom: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--clrd-accent, #3C06FF);
    color: #fff;
    font-size: 1.375rem;
    font-weight: 600;
    text-decoration: none;
    line-height: 1;
    transition: transform 0.25s ease, opacity 0.25s ease;
    box-shadow: 0 4px 16px rgba(60, 6, 255, 0.25);
}

.clrd-cat-thanks__back:hover {
    transform: scale(1.08);
    opacity: 0.88;
}

/* ══════════════════════════════════════════════════════════════
 * 4. RESPONSIVE
 * ══════════════════════════════════════════════════════════════ */
/* ====================================================
   RESPONSIVE CATEGORY ARCHIVE
   ==================================================== */
@media (max-width: 1024px) {
    .clrd-cat-banner {
        padding: calc(var(--header-height, 90px) + 2rem) 6vw 4rem;
        gap: 2rem;
    }
    .clrd-cat-banner__icon { height: 110px; }
    .clrd-cat-project { height: 480px; }
}

@media (max-width: 768px) {
    .clrd-cat-banner {
        flex-direction: column;
        gap: 1rem;
        min-height: 200px;
        padding: calc(var(--header-height, 72px) + 1.5rem) 1.5rem 2.5rem;
        text-align: center;
    }
    .clrd-cat-banner__icon { height: 80px; }
    .clrd-cat-banner__title { font-size: clamp(1.6rem, 6vw, 2.5rem); }
    .clrd-cat-project { height: 340px; }
    .clrd-cat-thanks {
        min-height: 320px;
        padding: 60px 1.5rem;
    }
    .clrd-cat-thanks__img { max-width: 160px; }
    .clrd-cat-thanks__heading { font-size: clamp(2rem, 8vw, 3rem); }
    .clrd-cat-thanks__back {
        right: 1rem;
        bottom: 1.5rem;
        width: 48px;
        height: 48px;
        font-size: 1.125rem;
    }
}

@media (max-width: 480px) {
    .clrd-cat-banner {
        padding: calc(var(--header-height, 64px) + 1rem) 1rem 2rem;
    }
    .clrd-cat-banner__icon { height: 64px; }
    .clrd-cat-project { height: 260px; }
    .clrd-cat-project__name { font-size: 1.1rem; letter-spacing: 0.06em; }
    .clrd-cat-thanks { padding: 48px 1rem; }
    .clrd-cat-thanks__back {
        right: 0.75rem;
        bottom: 1rem;
        width: 44px;
        height: 44px;
        font-size: 1rem;
    }
}
