/*
Theme Name: Ente Cultural de Tucumán 2026
Template: astra
Version: 1.0
Author: Emanuel Alderete & IDE Comunicación Digital
Description: Plantilla personalizada para el Ente Cultural de Tucumán, desarrollada casi en su totalidad desde el código para un mayor control sobre cada componente de la web.
*/

/* Reset básico */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Declaraciones generales */
:root {
    --light-color: #ffffff;
    --light-gray-color: #eaeaea;
    --gray-color: #999999;
    --dark-gray-color: #555555;
    --dark-color: #292929;
    --light-shadow: #00000038;
    --primary-color: #1563a7;
    --secondary-color: #7ec6e7;
    --terciary-color: #ffd02c;
    --transition-fast: 250ms;
    --transition-slow: 500ms;
    --bold-font: 800;
    --primary-font-family: 'Montserrat';
    --secondary-font-family: 'DM Sans';
    /* Si no hay una fuente secundaria, replicar la primaria. */
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: var(--primary-font-family);
    color: var(--dark-color);
    background-color: var(--light-color) !important;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 800;
}

h1 {
    font-size: 2.7em;
}

h2 {
    font-size: 2.2em;
}

h3 {
    font-size: 1.8em;
}

h4 {
    font-size: 1.5em;
}

h5 {
    font-size: 1.2em;
}

h6 {
    font-size: 1em;
}

p,
ul,
ol {
    margin: 0 0 1rem 0;
}

.home-main {
    section:not(:last-child) {
        margin-bottom: 7rem;
    }
}

.title {
    font-weight: var(--bold-font);
    color: var(--primary-color);
}

.home-title {
    font-size: 2.5em;
    text-transform: uppercase;
    font-weight: 900;
    color: var(--dark-color);
}

/* Módulos reutilizables */
.buttons-center,
.buttons-left,
.buttons-right {
    display: flex;
    align-items: center;
    margin: 1rem 0;
}

.buttons-left {
    justify-content: flex-start;
}

.buttons-right {
    justify-content: flex-end;
}

.buttons-center {
    justify-content: center;
}

.buttons,
.buttons-primary,
.buttons-light,
.buttons-secondary,
.buttons-terciary {
    padding: 0.5rem 2rem;
    border-radius: 99px;
    font-weight: var(--bold-font);
    transition: var(--transition-fast);
    text-decoration: none;
}

.buttons-primary {
    background-color: var(--primary-color);
    color: var(--light-color);
    border: 2px solid var(--primary-color);

    &:hover {
        background-color: var(--light-color);
        color: var(--primary-color);
        box-shadow: 0 0 10px var(--primary-color);
    }
}

.buttons-light {
    background-color: var(--light-color);
    color: var(--dark-color);
    border: 2px solid var(--light-color);

    &:hover {
        background-color: transparent;
        color: var(--light-color);
        box-shadow: 0 0 10px var(--light-color);
    }
}

.buttons-secondary {
    background-color: var(--secondary-color);
    color: var(--light-color);
    border: 2px solid var(--secondary-color);
    &:hover {
        background-color: transparent;
        color: var(--secondary-color);
        box-shadow: 0 0 10px var(--secondary-color);
    }
}

.buttons-terciary {
    background-color: var(--terciary-color);
    color: var(--dark-color);
    border: 2px solid var(--terciary-color);
    &:hover {
        background-color: transparent;
        color: var(--terciary-color);
        box-shadow: 0 0 10px var(--terciary-color);
    }
}

.light-separator,
.primary-separator,
.dark-separator {
    margin: 2rem auto;
    width: 100%;
    max-width: 1200px;
    height: 2px;
}

.light-separator {
    background-color: var(--light-color);
}

.dark-separator {
    background-color: var(--dark-color);
}

.primary-separator {
    background-color: var(--primary-color);
}

/* Efectos */
.uppercase {
    text-transform: uppercase;
}

.lowercase {
    text-transform: lowercase;
}

.capitalize {
    text-transform: capitalize;
}

.primary-text {
    color: var(--primary-color);
}

.secondary-text {
    color: var(--secondary-color);
}

.dark-gray-text {
    color: var(--dark-gray-color);
}

.light-gray-text {
    color: color-mix(in srgb, var(--light-gray-color) 70%, var(--dark-gray-color) 30%);
}

.disabled {
    color: color-mix(in srgb, var(--light-gray-color) 70%, var(--dark-gray-color) 30%) !important;
    pointer-events: none;
    cursor: not-allowed;
}

.ornament-wave {
    width: 100%;
}

/* Header */
.header {
    width: 100%;
    position: sticky;
    top: 0;
    left: 0;
    z-index: 10;
    background-color: var(--light-color);
    .header__content {
        width: 100%;
    }
}

.brand {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 1.5rem 0.5rem;
    img {
        width: 100%;
        height: 100%;
        object-fit: contain;
        max-width: 240px;
    }
}

.web-navigation {
    width: 100%;
    padding: 0.5rem 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.main-menu {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    list-style: none;
}

.main-menu__submenu {
    position: relative;
    list-style: none;
    .main-menu__submenu-content {
        position: absolute;
        list-style: inherit;
        opacity: 0;
        pointer-events: none;
        transition: var(--transition-fast);
        transform: translate(0, 15px);
        margin: 0;
        padding: 0;
        border: 1px solid var(--light-gray-color);
        background-color: var(--light-color);
        width: max-content;
    }
}

.main-menu__submenu:hover .main-menu__submenu-content {
    opacity: 1;
    pointer-events: all;
    transform: translate(0, 0);
}

.menu-item, .main-menu__submenu {
    button, a, .submenu-item {
        padding: 0.5rem;
        background-color: transparent;
        color: var(--dark-gray-color);
        font-weight: 600;
        border: none;
        box-shadow: none;
        text-decoration: none;
        transition: none;
        &:hover {
            background-color: var(--dark-gray-color);
            color: var(--light-color);
        }
    }
    a {
        color: inherit;
        display: block;
    }
}

.header__mobile-button {
    display: none;
    button {
        background-color: transparent;
        color: var(--dark-gray-color);
        font-size: 1.8em;
        border: none;
        padding: 1rem;
        box-shadow: none;
    }
}

/* Mobile menu */
.mobile-menu {
    font-family: var(--font-family-primary);

    .offcanvas-header {
        .mobile-menu__brand {
            width: 100%;
            max-width: 230px;

            .mobile-menu__logo {
                width: 100%;
                height: 100%;
                object-fit: contain;
            }
        }
    }

    .offcanvas-body {
        .mobile-nav {
            width: 100%;
            list-style: none;
            .mobile-menu__submenu {
                .accordion-item {
                    border: none;
                }
                .accordion-button {
                    font-family: var(--font-family-primary);
                    font-weight: 400;
                    font-size: 1.5em;
                    color: var(--dark-color);
                    background-color: transparent;
                    border: none;
                    box-shadow: none;
                }

                .accordion-button::before {
                    content: '';
                    display: inline-block;
                    width: 0;
                    height: 3px;
                    background-color: var(--primary-color);
                    transition: var(--transition-fast);
                }

                .accordion-button:hover::before {
                    width: 1.5rem;
                    margin: 0 0.7rem 0 0;
                }

                .accordion-button:not(.collapsed)::before {
                    width: 1.5rem;
                    margin: 0 0.7rem 0 0;
                }

                .accordion-button:not(.collapsed) {
                    background-color: transparent;
                    color: var(--dark-color);
                }

                .accordion-body {
                    display: flex;
                    align-items: flex-start;
                    justify-content: flex-start;
                    flex-wrap: wrap;

                    a {
                        text-decoration: none;
                        color: var(--dark-color);
                        font-size: 1em;
                        padding: 0.5rem 1rem;
                        display: inline-block;
                        width: 100%;
                        display: flex;
                        align-items: center;

                        &:hover {
                            background-color: var(--primary-color);
                            color: var(--light-color);
                        }
                    }

                    a::before {
                        content: '';
                        display: inline-block;
                        width: 1.5rem;
                        height: 3px;
                        background-color: var(--primary-color);
                        margin-right: 1rem;
                    }

                    a:hover::before {
                        background-color: var(--light-color);
                    }
                }
            }

            .mobile-menu__item {
                padding: 1rem 1.25rem;
                font-size: 1.5em;
                display: flex;
                align-items: center;

                a {
                    text-decoration: none;
                    color: var(--dark-color);
                }
            }

            .mobile-menu__item::before {
                content: '';
                display: inline-block;
                width: 0;
                height: 3px;
                background-color: var(--primary-color);
                transition: var(--transition-fast);
            }

            .mobile-menu__item:hover::before {
                width: 1.5rem;
                margin: 0 0.7rem 0 0;
            }
        }
    }
}

/* Eventos */
.events {
    width: 100%;
    .events__content {
        width: 100%;
        max-width: 1400px;
        margin: 0 auto;
        padding: 1rem;
    }
}

/* Noticias */
.news {
    width: 100%;

    .news__content {
        width: 100%;
        max-width: 1400px;
        margin: 0 auto;
        padding: 1rem;

        .news__loop {
            width: 100%;
            display: flex;
            align-items: stretch;
            flex-wrap: wrap;
            justify-content: space-between;
        }
    }
}

.news-item {
    width: 300px;
    margin: 0.5rem;
    perspective: 1000px;

    .news-item__content {
        border: 2px solid var(--primary-color);
        border-radius: 25px;
        transition: var(--transition-fast);
        width: 100%;
        overflow: hidden;

        &:hover {
            box-shadow: 15px 15px 10px var(--light-shadow);
        }

        .news-item__image {
            width: 100%;
            outline: 2px solid var(--primary-color);
            height: 16rem;
            border-radius: 25px;
            overflow: hidden;

            img {
                width: 100%;
                height: 100%;
                object-fit: cover;
            }
        }

        .news-item__date {
            p {
                margin: 0;
                color: var(--gray-color);
            }
        }

        .news-item__info {
            width: 100%;
            padding: 1rem;

            .news-item__title {
                display: -webkit-box;
                -webkit-line-clamp: 2;
                -webkit-box-orient: vertical;
                overflow: hidden;
                text-overflow: clip;
                height: 54px;
                line-clamp: 2;
            }

            p:not(.news-item__date p) {
                display: -webkit-box;
                -webkit-line-clamp: 3;
                -webkit-box-orient: vertical;
                overflow: hidden;
                text-overflow: clip;
                line-clamp: 3;
                height: 67px;
            }
        }

        .news-item__footer {
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 15px;

            .button-left {
                width: calc(60% - 7.5px);
            }

            .news-item__share {
                width: calc(40% - 7.5px);
                display: flex;
                align-items: center;
                justify-content: flex-end;

                .share-icon {
                    width: 35px;
                    height: 35px;
                    margin: 0 5px;
                    font-size: 1.2em;
                    display: flex;
                    align-items: center;
                    justify-content: center;
                    border-radius: 99px;
                    transition: var(--transition-fast);
                }

                .share-icon.facebook {
                    background-color: var(--primary-color);
                    color: var(--light-color);

                    &:hover {
                        background-color: #3b5998;
                        box-shadow: 0 0 10px #3b5998;
                    }
                }

                .share-icon.whatsapp {
                    background-color: var(--primary-color);
                    color: var(--light-color);

                    &:hover {
                        background-color: #25d366;
                        box-shadow: 0 0 10px #25d366;
                    }
                }
            }
        }
    }
}

/* Footer */
.footer{
    width: 100%;
    padding: 3rem 1.5rem;
    color: var(--dark-gray-color);
    background-color: color-mix(in srgb, var(--light-gray-color), #ffffff 70%);
    .footer__content {
        width: 100%;
        max-width: 992px;
        margin: 0 auto;
    }
}

.footer__brand {
    width: 100%;
    max-width: 350px;
    margin: 0 auto;
    img {
        width: 100%;
        height: 100%;
        object-fit: contain;
    }
}

.footer__data {
    font-weight: 600;
    font-size: 0.85em;
    span:not(:last-child) {
        margin-bottom: 0.4rem;
    }
    a {
        color: inherit;
    }
}

/* 
=====================================================
=    Páginas, entradas y categorías                 =
=====================================================
*/

/* Categorías */
.categories {
    width: 100%;
    padding: 2rem;
    min-height: calc(100svh - 140px - 292px);

    .categories__content {
        width: 100%;
        max-width: 1440px;
        margin: 0 auto;

        .categories__header {
            width: 100%;

            .categories__title {
                color: var(--primary-color);
                margin-bottom: 1rem;
            }

            .categories__description {
                color: var(--dark-gray-color);
                margin-bottom: 2rem;
                width: 100%;
            }
        }

        .categories__body {
            width: 100%;

            .categories__loop {
                width: 100%;
                display: flex;
                align-items: stretch;
                justify-content: space-evenly;
                flex-wrap: wrap;
            }
        }
    }
}

.entry {
    width: 100%;
    padding: 2rem;
    background-color: var(--light-gray-color);
    color: var(--dark-gray-color);
    min-height: calc(100svh - 140px - 292px);

    .entry__content {
        width: 100%;
        max-width: 1200px;
        margin: 0 auto;
        display: flex;
        align-items: stretch;
        justify-content: center;
        flex-wrap: wrap;
        background-color: var(--light-color);
        box-shadow: 10px 10px 10px var(--light-shadow);
        padding: 2rem;

        .entry__box:first-child {
            width: 65%;
            padding: 0 0.5rem;

            .entry__header {
                width: 100%;

                .entry__att-image {
                    width: 100%;
                    height: calc((1200px - (1200px * 0.4)) / 1.5);

                    img {
                        width: 100%;
                        height: 100%;
                        object-fit: cover;
                    }
                }

                .breadcrumbs {
                    font-weight: 700;
                    margin: 0;

                    a {
                        color: var(--primary-color);
                        text-decoration: none;
                    }

                    .breadcrumb_last {
                        color: var(--dark-gray-color);
                    }
                }

                .entry__date {
                    margin-bottom: 2rem;
                }

                .entry__title {
                    color: var(--primary-color);
                    margin-bottom: 0;
                    margin-top: 2rem;
                }
            }

            .entry__excerpt {
                p {
                    width: 100%;
                    padding: 1.5rem;
                    border: 3px dashed var(--primary-color);
                    font-size: 1.5em;
                    border-radius: 25px 25px 25px 5px;
                    margin: 2rem 0;
                }
            }

            .entry__body {

                h1,
                h2,
                h3,
                h4,
                h5,
                h6 {
                    color: var(--primary-color);
                    margin: 2rem 0 0.7rem 0;
                }
            }

            .entry-tags {
                width: 100%;
                display: flex;
                align-items: center;
                justify-content: flex-start;

                .entry-tags__title {
                    margin-right: 1rem;
                    color: var(--primary-color);
                }

                ul {
                    list-style: none;
                    margin: 0;
                    padding: 0;
                    display: flex;
                    align-items: center;
                    justify-content: flex-start;
                    flex-wrap: wrap;

                    li {
                        margin: 0.3rem;

                        a {
                            display: block;
                            color: var(--primary-color);
                            text-decoration: none;
                            border: 1px solid var(--primary-color);
                            background-color: transparent;
                            padding: 0.3rem 0.5rem;
                            border-radius: 99px;
                            font-size: 0.8em;

                            &:hover {
                                background-color: var(--primary-color);
                                color: var(--light-color);
                            }
                        }
                    }
                }
            }
        }

        .entry__box:last-child {
            width: 35%;
            padding: 0 0.5rem;

            .entry-box__content {
                .entry-search {
                    position: relative;
                    width: 100%;

                    .entry-search__form {
                        display: flex;
                        align-items: center;
                        justify-content: flex-start;

                        .entry-search__field {
                            padding: 0.5rem 1rem;
                            border: 1px solid var(--light-gray-color);
                            width: 100%;

                            &:focus {
                                outline: 4px solid rgb(from var(--primary-color) r g b / 30%);
                            }
                        }

                        .entry-search__submit {
                            width: 3rem;
                            height: 2.7rem;
                            font-size: 1.2em;
                            border: 2px solid var(--primary-color);
                            background-color: var(--primary-color);
                            color: var(--light-color);
                            padding: 0;
                        }
                    }
                }

                .entry-related {
                    width: 100%;
                    margin: 1rem 0;

                    .entry-related__title {
                        color: var(--primary-color);
                        margin-bottom: 1rem;
                    }

                    .entry-related__body {
                        li {
                            a {
                                color: var(--primary-color);
                                text-decoration: none;
                                display: block;
                                padding: 0.4rem;
                                border-bottom: 1px dashed var(--primary-color);

                                &:hover {
                                    background-color: var(--primary-color);
                                    color: var(--light-color);
                                }
                            }
                        }
                    }
                }
            }

            .entry-follow {
                width: 100%;

                .entry-follow__content {
                    width: 100%;

                    .entry-follow__title {
                        color: var(--primary-color);
                    }

                    .entry-follow__list {
                        display: flex;
                        align-items: center;
                        justify-content: flex-start;
                        list-style: none;
                        margin: 0;
                        padding: 0;

                        .entry-follow__item {
                            margin: 0 0.3rem;

                            a {
                                text-decoration: none;
                                color: var(--light-color);
                                display: flex;
                                background-color: var(--primary-color);
                                border-radius: 99px;
                                width: 3.5rem;
                                height: 3.5rem;
                                font-size: 1.6em;
                                justify-content: center;
                                align-items: center;
                                border: 2px solid var(--primary-color);
                                transition: var(--transition-fast);

                                &:hover {
                                    background-color: var(--light-color);
                                    color: var(--primary-color);
                                    box-shadow: 0 0 10px var(--primary-color);
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}

/* Pages */
.page {
    width: 100%;
    background-color: var(--light-gray-color);
    min-height: calc(100svh - 140px - 292px);

    .page__content {
        width: 100%;

        .page-header {
            width: 100%;
            background-position: center;
            background-repeat: no-repeat;
            background-size: cover;
            display: flex;
            align-items: flex-end;
            justify-content: flex-start;
            flex-wrap: wrap;
            width: 100%;
            height: 100%;
            position: relative;

            .page-header__overlay {
                position: absolute;
                z-index: 2;
                padding: 2rem;
                top: 0;
                height: 0;
                width: 100%;
                height: 100%;
                background: transparent;
                background: linear-gradient(180deg, rgba(255, 255, 255, 0) 11%, rgba(0, 0, 0, 0.6194852941176471) 77%);
            }

            .page-header__content {
                position: relative;
                z-index: 3;
                width: 100%;
                max-width: 1200px;
                padding: 2rem;
                margin: 0 auto;

                .page__title {
                    color: var(--dark-color);
                }

                #breadcrumbs {
                    font-weight: 700;

                    a {
                        color: var(--primary-color);
                        text-decoration: none;
                    }

                    .breadcrumb_last {
                        color: var(--light-color);
                    }
                }

                #breadcrumbs.primary-color-last .breadcrumb_last {
                    color: var(--dark-color);
                }
            }
        }

        .page__body {
            width: 100%;
            margin-bottom: 5rem;

            .page__content {
                background-color: var(--light-color);
                box-shadow: 2px 2px 5px var(--light-shadow);
                border: 1px solid var(--light-gray-color);
                border-radius: 25px;
                width: 100%;
                max-width: 1200px;
                margin: 0 auto;
                padding: 2rem;

                h1,
                h2,
                h3,
                h4,
                h5,
                h6 {
                    color: var(--primary-color);
                }
            }
        }
    }
}

.not-found {
    width: 100%;

    .not-found__content {
        width: 100%;
        max-width: 1200px;
        padding: 2rem;
        margin: 0 auto;
        color: var(--dark-gray-color);

        .not-found__inner {
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 20px;

            .not-found__box {
                width: calc(50% - 10px);
            }

            .not-found__box:first-child {
                img {
                    width: 100%;
                    height: 100%;
                    object-fit: contain;
                }
            }
        }
    }
}

.wp-pagenavi {
    margin: 2rem auto 0;
    width: max-content;
    transform: scale(1.02);

    .pages,
    .current,
    .page,
    .nextpostslink,
    .previouspostslink {
        border: 2px solid var(--primary-color);
        color: var(--primary-color);
    }

    .pages {
        border-radius: 10px 0 0 10px;
    }

    .current {
        background-color: var(--primary-color);
        color: var(--light-color);
        border-color: var(--primary-color) !important;
    }

    .page {
        background-color: transparent;
    }
}

.wp-pagenavi> :last-child {
    border-radius: 0 10px 10px 0;
}

/* 
=====================================================
=    Responsive Design                              =
=====================================================
*/

@media (width <= 883px){
    .header__mobile-button {
        display: block;
    }
    .main-menu {
        display: none;
    }
    .web-navigation {
        justify-content: flex-end;
    }
}

@media (width <= 680px){
    .news .news__content .news__loop {
        justify-content: center;
    }
}