/**
 * ==========================================================
 * COLEGIO SAN AGUSTÍN
 * Top Bar institucional
 * ==========================================================
 */

.topbar {
    background: #0b653f !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
    color: #ffffff;
}

.topbar .container {
    min-height: 58px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.topbar .widget {
    margin: 0 !important;
}

.topbar-left,
.topbar-right {
    display: flex;
    align-items: center;
}

/* Información institucional */
.csa-topbar-info {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0;
}

.csa-topbar-info a {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #ffffff !important;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.3;
    padding: 0 18px;
    white-space: nowrap;
    transition:
        opacity 0.2s ease,
        transform 0.2s ease;
}

.csa-topbar-info a:first-child {
    padding-left: 0;
}

.csa-topbar-info a:not(:last-child)::after {
    content: "";
    position: absolute;
    top: 50%;
    right: 0;
    width: 1px;
    height: 18px;
    background: rgba(255, 255, 255, 0.35);
    transform: translateY(-50%);
}

.csa-topbar-info a:hover {
    color: #ffffff !important;
    opacity: 0.82;
    transform: translateY(-1px);
}

.csa-topbar-info i {
    color: #ffffff;
    font-size: 14px;
    width: 15px;
    text-align: center;
}

/* Redes sociales */
.csa-topbar-social {
    display: flex;
    align-items: center;
    gap: 8px;
}

.csa-topbar-social a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 31px;
    height: 31px;
    border: 1px solid rgba(255, 255, 255, 0.28);
    border-radius: 50%;
    color: #ffffff !important;
    font-size: 13px;
    transition:
        background-color 0.2s ease,
        border-color 0.2s ease,
        transform 0.2s ease;
}

.csa-topbar-social a:hover {
    background: #ffffff;
    border-color: #ffffff;
    color: #0b653f !important;
    transform: translateY(-2px);
}

/* Tablet */
@media (max-width: 1024px) {
    .topbar .container {
        min-height: 54px;
    }

    .csa-topbar-info a {
        font-size: 12px;
        padding: 0 12px;
    }

    .csa-topbar-info a span {
        white-space: nowrap;
    }
}

/* Móvil */
@media (max-width: 767px) {
    .topbar .container {
        min-height: auto;
        padding-top: 10px;
        padding-bottom: 10px;
        flex-direction: column;
        justify-content: center;
        gap: 9px;
    }

    .topbar-left,
    .topbar-right {
        width: 100%;
        justify-content: center;
    }

    .csa-topbar-info {
        width: 100%;
        justify-content: center;
        row-gap: 8px;
    }

    .csa-topbar-info a {
        font-size: 11px;
        padding: 0 9px;
    }

    .csa-topbar-info a:first-child {
        padding-left: 9px;
    }

    .csa-topbar-info a:not(:last-child)::after {
        display: none;
    }

    .csa-topbar-social a {
        width: 29px;
        height: 29px;
        font-size: 12px;
    }
}

/* Teléfonos muy pequeños */
@media (max-width: 520px) {
    .csa-topbar-info a {
        width: 100%;
        justify-content: center;
        padding: 0;
    }

    .csa-topbar-info a:first-child {
        padding-left: 0;
    }
}
/* ==========================================================
   TOP BAR — ALINEACIÓN DEFINITIVA EN ESCRITORIO
   ========================================================== */

@media (min-width: 768px) {

    .topbar .container {
        display: flex !important;
        align-items: center !important;
        width: 100% !important;
    }

    .topbar .container > .row {
        display: flex !important;
        align-items: center !important;
        width: 100% !important;
        flex: 1 1 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
    }

    .topbar-left {
        display: flex !important;
        align-items: center !important;
        justify-content: flex-start !important;
        flex: 1 1 auto !important;
        width: auto !important;
        max-width: none !important;
    }

    .topbar-right {
        display: flex !important;
        align-items: center !important;
        justify-content: flex-end !important;
        flex: 0 0 auto !important;
        width: auto !important;
        max-width: none !important;
        margin-left: auto !important;
    }

    .topbar-right .widget,
    .topbar-right .csa-topbar-social {
        margin-left: auto !important;
    }
}
/* Separación visual Top Bar */
.topbar,
.header-top,
.talemy-top-bar {
    box-shadow: 0 2px 8px rgba(0,0,0,.08);
    position: relative;
    z-index: 1001;
}
/* Redes sociales */
.topbar .social-icons a,
.header-top .social-icons a,
.talemy-top-bar .social-icons a {
    border: 1px solid rgba(255,255,255,.45);
    transition: all .25s ease;
}

.topbar .social-icons a:hover,
.header-top .social-icons a:hover,
.talemy-top-bar .social-icons a:hover {
    background: rgba(255,255,255,.15);
    border-color: rgba(255,255,255,.9);
}
/* Logo institucional */
.site-branding img,
.custom-logo {
    max-height: 72px;
    width: auto;
}
/* =========================================
   CPSA - HEADER STYLE 1
========================================= */

@media (min-width: 1025px) {

    /* Altura general */
    .header-style-1 .navbar {
        min-height: 94px;
        background: #ffffff;
        box-shadow: 0 4px 18px rgba(0, 0, 0, .08);
    }

    .header-style-1 .navbar > .container {
        min-height: 94px;
        align-items: center;
    }

    /* Logo oficial */
    .header-style-1 .logo-wrapper {
        max-height: 94px;
        padding-right: 34px;
        flex: 0 0 auto;
    }

    .header-style-1 .logo-wrapper a {
        display: flex;
        align-items: center;
        max-height: 90px;
    }

    .header-style-1 .logo-wrapper img {
        display: block;
        width: auto;
        max-width: 105px;
        max-height: 90px;
    }

    /* Menú */
    .header-style-1 .nav-menu-wrapper {
        flex-grow: 1;
        min-width: 0;
    }

    .header-style-1 .nav-menu > li > a {
        padding: 35px 14px;
        color: #171717;
        font-size: 14px;
        font-weight: 600;
        letter-spacing: .15px;
        transition: color .2s ease;
    }

    .header-style-1 .nav-menu > li > a:hover,
    .header-style-1 .nav-menu > .current-menu-item > a,
    .header-style-1 .nav-menu > .current-menu-parent > a,
    .header-style-1 .nav-menu > .current-menu-ancestor > a {
        color: #0d6b43;
    }

    /* Carrito y buscador */
    .header-style-1 .nav-btns {
        flex: 0 0 auto;
        margin-left: auto;
        padding-left: 20px;
    }

    /* Sticky más compacto */
    .header-style-1 .navbar.nav-is-fixed {
        min-height: 76px;
        box-shadow: 0 5px 20px rgba(0, 0, 0, .12);
    }

    .header-style-1 .navbar.nav-is-fixed > .container {
        min-height: 76px;
    }

    .header-style-1 .navbar.nav-is-fixed .logo-wrapper {
        max-height: 76px;
    }

    .header-style-1 .navbar.nav-is-fixed .logo-wrapper img {
        max-height: 70px;
    }

    .header-style-1 .navbar.nav-is-fixed .nav-menu > li > a {
        padding-top: 26px;
        padding-bottom: 26px;
    }
}
@media (min-width: 1025px) {
    .header-style-1 .logo-wrapper {
        transform: translateY(4px);
    }
}
/* =========================================
   CPSA - IDENTIDAD + FONDO HEADER
========================================= */

@media (min-width: 1025px) {

    /* Fondo institucional del header */
    .header-style-1 .navbar {
        background:
            radial-gradient(circle at 12% 50%, rgba(13, 107, 67, .08), transparent 24%),
            linear-gradient(180deg, #ffffff 0%, #f6faf8 100%);
        border-bottom: 1px solid rgba(13, 107, 67, .12);
        box-shadow: 0 5px 18px rgba(0, 0, 0, .08);
    }

    /* Bloque logo + nombre */
    .header-style-1 .logo-wrapper {
        display: flex;
        align-items: center;
        min-width: 265px;
        padding-right: 28px;
        transform: none;
    }

    /* Texto institucional al lado del logo */
    .header-style-1 .logo-wrapper::after {
        content: "COLEGIO PRIVADO\A SAN AGUSTÍN";
        white-space: pre-line;
        display: block;
        margin-left: 14px;
        color: #123d2b;
        font-family: "Poppins", sans-serif;
        font-size: 17px;
        font-weight: 700;
        line-height: 1.25;
        letter-spacing: .2px;
        text-align: left;
    }

    /* Logo */
    .header-style-1 .logo-wrapper img {
        flex: 0 0 auto;
        max-width: 92px;
        max-height: 88px;
    }

    /* Menú más elegante */
    .header-style-1 .nav-menu > li > a {
        position: relative;
    }

    .header-style-1 .nav-menu > li > a::after {
        content: "";
        position: absolute;
        left: 50%;
        bottom: 24px;
        width: 0;
        height: 2px;
        background: #0d6b43;
        transform: translateX(-50%);
        transition: width .25s ease;
    }

    .header-style-1 .nav-menu > li:hover > a::after,
    .header-style-1 .nav-menu > .current-menu-item > a::after,
    .header-style-1 .nav-menu > .current-menu-ancestor > a::after {
        width: 26px;
    }

    /* Sticky */
    .header-style-1 .navbar.nav-is-fixed .logo-wrapper::after {
        font-size: 14px;
    }
}
/* ==========================================
   MENÚ - IDENTIDAD CPSA
========================================== */

/* Hover */
.header-style-1 .nav-menu > li:hover > a,
.header-style-1 .nav-menu > .current-menu-item > a,
.header-style-1 .nav-menu > .current-menu-parent > a,
.header-style-1 .nav-menu > .current-menu-ancestor > a{
    color:#0d6b43 !important;
}

/* Línea inferior */
.header-style-1 .nav-menu > li > a:after{
    background:#0d6b43 !important;
}

/* Submenús */
.header-style-1 .nav-menu ul li:hover > a{
    color:#0d6b43 !important;
}
/* ==========================================
   CARRITO
========================================== */

.header-style-1 .cart-count,
.header-style-1 .woocommerce-mini-cart-count,
.header-style-1 .shopping-cart .count{
    background:#0d6b43 !important;
    color:#fff !important;
}
.header-style-1 .shopping-cart a,
.header-style-1 .shopping-cart i{
    color:#0d6b43;
}

.header-style-1 .shopping-cart:hover a,
.header-style-1 .shopping-cart:hover i{
    color:#0a5b38;
}
.header-style-1 .search-btn,
.header-style-1 .search-btn i{
    color:#0d6b43;
}

.header-style-1 .search-btn:hover,
.header-style-1 .search-btn:hover i{
    color:#0a5b38;
}
/* Contador del carrito - verde institucional */
.header-style-1 .nav-btn .item-count {
    background-color: #0d6b43 !important;
    color: #ffffff !important;
    box-shadow: 0 2px 6px rgba(13, 107, 67, .30);
}
/* ==========================================
   LOGO + TEXTO - MÓVIL
========================================== */

@media (max-width:1024px){

    .header-style-1 .logo-wrapper{
        display:flex;
        align-items:center;
    }

    .header-style-1 .logo-wrapper::after{
        content:"COLEGIO PRIVADO\A SAN AGUSTÍN";
        white-space:pre-line;
        display:block;
        margin-left:10px;

        color:#123d2b;

        font-family:"Poppins",sans-serif;
        font-size:14px;
        font-weight:700;
        line-height:1.2;
    }

    .header-style-1 .logo-wrapper img{
        max-height:62px;
        width:auto;
    }

}
/* ==========================================
   CPSA - STICKY HEADER PREMIUM
========================================== */

@media (min-width: 1025px) {

    .header-style-1 .navbar,
    .header-style-1 .logo-wrapper,
    .header-style-1 .logo-wrapper img,
    .header-style-1 .logo-wrapper::after,
    .header-style-1 .nav-menu > li > a,
    .header-style-1 .nav-btns {
        transition:
            min-height .25s ease,
            max-height .25s ease,
            padding .25s ease,
            font-size .25s ease,
            transform .25s ease,
            box-shadow .25s ease;
    }

    .header-style-1 .navbar.nav-is-fixed {
        min-height: 74px;
        background: rgba(255, 255, 255, .97);
        box-shadow: 0 8px 24px rgba(0, 0, 0, .13);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
    }

    .header-style-1 .navbar.nav-is-fixed > .container {
        min-height: 74px;
    }

    .header-style-1 .navbar.nav-is-fixed .logo-wrapper {
        max-height: 74px;
    }

    .header-style-1 .navbar.nav-is-fixed .logo-wrapper img {
        max-height: 64px;
        max-width: 78px;
    }

    .header-style-1 .navbar.nav-is-fixed .logo-wrapper::after {
        font-size: 14px;
        line-height: 1.15;
    }

    .header-style-1 .navbar.nav-is-fixed .nav-menu > li > a {
        padding-top: 25px;
        padding-bottom: 25px;
    }

    .header-style-1 .navbar.nav-is-fixed .nav-btns {
        transform: scale(.94);
    }
}
/* Ajuste línea activa/hover en sticky */
@media (min-width: 1025px) {
    .header-style-1 .navbar.nav-is-fixed .nav-menu > li > a::after {
        bottom: 14px;
    }
}
/* Logo Premium */

.header-style-1 .logo-wrapper img{
    transition:.30s ease;
}

.header-style-1 .logo-wrapper:hover img{
    transform:scale(1.03);
}
.header-style-1 .nav-btn{

    width:42px;
    height:42px;

    border-radius:50%;

    transition:.25s ease;
}

.header-style-1 .nav-btn:hover{

    background:#eef8f2;

    color:#0d6b43;

}
/* ==========================================
   CPSA - REFINAMIENTO PREMIUM DEL HEADER
========================================== */

@media (min-width: 1025px) {

    /* Iluminación suave detrás del branding */
    .header-style-1 .navbar {
        background:
            radial-gradient(
                circle at 14% 50%,
                rgba(13, 107, 67, .11) 0,
                rgba(13, 107, 67, .05) 18%,
                transparent 34%
            ),
            linear-gradient(
                180deg,
                #ffffff 0%,
                #f8fbf9 100%
            );
    }

    /* Separador entre branding y menú */
    .header-style-1 .logo-wrapper {
        position: relative;
        margin-right: 30px;
        padding-right: 30px;
    }

    .header-style-1 .logo-wrapper::before {
        content: "";
        position: absolute;
        top: 20%;
        right: 0;
        width: 1px;
        height: 60%;
        background: linear-gradient(
            180deg,
            transparent,
            rgba(13, 107, 67, .28),
            transparent
        );
    }

    /* Logo con microanimación */
    .header-style-1 .logo-wrapper img {
        transition: transform .28s ease, filter .28s ease;
    }

    .header-style-1 .logo-wrapper:hover img {
        transform: scale(1.035);
        filter: drop-shadow(0 5px 8px rgba(13, 107, 67, .18));
    }

    /* Menú con desplazamiento sutil */
    .header-style-1 .nav-menu > li > a {
        transition:
            color .22s ease,
            transform .22s ease;
    }

    .header-style-1 .nav-menu > li:hover > a {
        transform: translateY(-2px);
    }

    /* Carrito y buscador alineados */
.header-style-1 .nav-btns {
    display: flex;
    align-items: center;
    gap: 8px;
}

.header-style-1 .nav-btns .nav-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    transition:
        background-color .22s ease,
        transform .22s ease,
        color .22s ease;
}

.header-style-1 .nav-btns .nav-btn:hover {
    background-color: rgba(13, 107, 67, .08);
    transform: translateY(-1px);
}

    .header-style-1 .nav-btns .nav-btn:hover,
    .header-style-1 .nav-btns > *:hover {
        background-color: rgba(13, 107, 67, .08);
        transform: translateY(-1px);
    }

    /* Sticky: separador y fondo más limpios */
    .header-style-1 .navbar.nav-is-fixed .logo-wrapper {
        margin-right: 24px;
        padding-right: 24px;
    }

    .header-style-1 .navbar.nav-is-fixed .logo-wrapper::before {
        top: 18%;
        height: 64%;
    }
}