﻿/* =========================================
   VARIABLES
========================================= */
:root {
    --brown: #42322C;
    --brown-d: #2B201D;
    --gold: #C9A14A;
    --gold-l: #e8d4a8;
    --gold-light: #e0ba6f;
    --off-white: #F5F1F0;
    --bg-light: #F5F1F0;
    --text-dark: #1a1a1a;
    --text-mid: #444444;
    --text-muted: #666666;
    --border: rgba(0,0,0,0.08);
    --navbar-h: 62px;
}

/* =========================================
   RESET
========================================= */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    overflow-x: hidden;
    font-family: 'DM Sans', sans-serif;
    padding-top: var(--navbar-h);
    background: var(--bg-light);
}

/* =========================================
   NAVBAR — sin border-radius, corte recto
========================================= */
.main-navbar {
    background: var(--brown-d);
    padding: 0;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--navbar-h);
    z-index: 9999;
    /* Sombra asimétrica — más pronunciada abajo-derecha */
    box-shadow: 0 4px 0 0 var(--gold), 0 6px 28px rgba(43,32,29,0.45);
    display: flex;
    align-items: center;
}

    .main-navbar .navbar-nav {
        display: flex;
        align-items: center;
    }

    .main-navbar .nav-link {
        color: rgba(255,255,255,0.60) !important;
        padding: 0 24px !important;
        height: var(--navbar-h);
        line-height: var(--navbar-h);
        font-size: 0.68rem;
        letter-spacing: 3px;
        font-weight: 600;
        text-transform: uppercase;
        transition: color .2s, background .2s;
        border-right: 1px solid rgba(255,255,255,0.07);
        white-space: nowrap;
        position: relative;
    }

    .main-navbar .nav-item:first-child .nav-link {
        border-left: 1px solid rgba(255,255,255,0.07);
    }

    /* Acento dorado — bloque sólido en lugar de underline */
    .main-navbar .nav-link::before {
        content: '';
        position: absolute;
        left: 0;
        top: 0;
        width: 3px;
        height: 100%;
        background: var(--gold);
        transform: scaleY(0);
        transform-origin: bottom;
        transition: transform .2s cubic-bezier(.4,0,.2,1);
    }

    .main-navbar .nav-link:hover {
        color: #fff !important;
        background: rgba(255,255,255,0.04);
    }

        .main-navbar .nav-link:hover::before,
        .main-navbar .nav-link.active::before {
            transform: scaleY(1);
        }

    .main-navbar .nav-link.active {
        color: var(--gold) !important;
        background: rgba(201,161,74,0.06);
    }

/* Toggler */
.navbar-toggler {
    border: 1px solid rgba(255,255,255,0.2);
    padding: 7px 10px;
    border-radius: 2px; /* casi recto */
}

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(255,255,255,0.85)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* =========================================
   TOP HEADER
========================================= */
.top-header {
    background: var(--off-white);
    padding: 20px 0;
    border-bottom: 1px solid rgba(0,0,0,0.05);
    position: relative;
}

    /* Línea dorada — desplazada, no centrada */
    .top-header::after {
        content: '';
        position: absolute;
        bottom: 0;
        left: 0;
        right: 0;
        height: 1px;
        background: linear-gradient(90deg, var(--gold) 0%, var(--gold) 35%, transparent 70%, transparent 100%);
        opacity: 0.5;
    }

.top-left {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 8px;
    height: 100%;
}

/* Iconos sociales — cuadrados, sin radius */
.social-icons {
    display: flex;
    gap: 6px;
    align-items: center;
}

    .social-icons a {
        width: 30px;
        height: 30px;
        border-radius: 0; /* recto */
        border: 1px solid rgba(43,32,29,0.18);
        background: transparent;
        color: var(--brown-d);
        text-decoration: none;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: background .18s, color .18s;
        clip-path: polygon(0 0, 100% 0, 100% 75%, 90% 100%, 0 100%); /* corte diagonal */
    }

        .social-icons a svg {
            width: 12px;
            height: 12px;
            stroke: currentColor;
            fill: none;
            stroke-width: 2;
            stroke-linecap: round;
            stroke-linejoin: round;
        }

        .social-icons a:hover {
            background: var(--brown-d);
            color: #fff;
        }

.top-text {
    color: var(--text-muted);
    font-size: 0.65rem;
    letter-spacing: 2.5px;
    text-transform: uppercase;
    margin: 0;
}

.main-logo {
    max-width: 150px;
    height: auto;
    display: block;
    margin: 0 auto;
    transition: opacity .3s ease;
}

    .main-logo:hover {
        opacity: 0.75;
    }

/* Separadores verticales columna central */
.top-header .col-lg-4:nth-child(2) {
    position: relative;
}

    .top-header .col-lg-4:nth-child(2)::before,
    .top-header .col-lg-4:nth-child(2)::after {
        content: '';
        position: absolute;
        top: 10%;
        bottom: 10%;
        width: 1px;
        background: linear-gradient(to bottom, transparent, rgba(201,161,74,0.35), transparent);
    }

    .top-header .col-lg-4:nth-child(2)::before {
        left: 0;
    }

    .top-header .col-lg-4:nth-child(2)::after {
        right: 0;
    }

/* Slogan — serif, alineado derecha, sin italic forzado */
.header-slogan {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 0.98rem;
    font-weight: 300;
    font-style: italic;
    line-height: 1.6;
    margin: 0;
    text-align: right;
    color: var(--brown);
    letter-spacing: 0.5px;
    opacity: 0.75;
}

/* =========================================
   EYEBROW LINE
========================================= */
.eyebrow-line {
    display: inline-block;
    width: 24px;
    height: 1px;
    background: var(--gold);
    opacity: 0.5;
}

/* =========================================
   FOOTER
========================================= */
.footer-main {
    background: var(--brown-d);
    padding: 52px 0 0;
    position: relative;
    overflow: hidden;
    /* Corte diagonal en el borde superior */
    clip-path: polygon(0 12px, 60px 0, 100% 0, 100% 100%, 0 100%);
}

    .footer-main::before {
        content: '';
        position: absolute;
        bottom: -60px;
        left: -60px;
        width: 260px;
        height: 260px;
        border-radius: 50%;
        background: rgba(201,161,74,0.04);
        pointer-events: none;
    }

    /* Línea dorada superior — asimétrica */
    .footer-main::after {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        height: 1px;
        background: linear-gradient(90deg, var(--gold) 0%, var(--gold) 40%, transparent 80%);
        opacity: 0.4;
    }

.footer-top {
    display: flex;
    justify-content: center;
    padding-bottom: 32px;
    border-bottom: 1px solid rgba(255,255,255,0.06);
}

.footer-logo {
    max-width: 110px;
    height: auto;
    opacity: 0.85;
    filter: brightness(0) invert(1);
}

/* ── ALIADOS ──────────────────────────── */
.footer-allies-block {
    padding: 36px 0 32px;
    border-bottom: 1px solid rgba(255,255,255,0.06);
}

.footer-allies-label {
    display: flex;
    align-items: center;
    gap: 14px;
    font-size: 0.62rem;
    font-weight: 700;
    letter-spacing: 3.5px;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 24px;
}

    .footer-allies-label::before,
    .footer-allies-label::after {
        content: '';
        flex: 1;
        height: 1px;
        background: rgba(201,161,74,0.18);
    }

.footer-allies-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 10px;
    align-items: center;
}

.footer-ally-item {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 56px;
    border-radius: 0; /* recto */
    border: 1px solid rgba(255,255,255,0.06);
    background: rgba(255,255,255,0.02);
    transition: background .2s, border-color .2s;
    overflow: hidden;
    padding: 8px 12px;
}

    .footer-ally-item:hover {
        background: rgba(255,255,255,0.06);
        border-color: rgba(201,161,74,0.2);
    }

    .footer-ally-item img {
        max-width: 100%;
        max-height: 36px;
        object-fit: contain;
        opacity: 0.5;
        filter: brightness(0) invert(1);
        transition: opacity .2s;
    }

    .footer-ally-item:hover img {
        opacity: 0.85;
    }

.footer-ally-placeholder {
    font-size: 0.65rem;
    font-weight: 500;
    letter-spacing: 1px;
    color: rgba(255,255,255,0.18);
    text-align: center;
    user-select: none;
}

/* ── COPYRIGHT ────────────────────────── */
.footer-bottom {
    padding: 16px 0;
    text-align: center;
}

.footer-copyright {
    font-size: 0.72rem;
    letter-spacing: 1px;
    color: rgba(255,255,255,0.2);
    margin: 0;
}

/* ── RESPONSIVE FOOTER ─────────────────── */
@media (max-width: 991.98px) {
    .footer-allies-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 575.98px) {
    .footer-allies-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* =========================================
   WHATSAPP WIDGET
========================================= */
.wa-widget {
    position: fixed;
    bottom: 28px;
    right: 28px;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 12px;
    z-index: 9999;
}

.wa-popup {
    background: #fff;
    border-radius: 0 16px 0 16px; /* asimétrico — solo dos esquinas */
    box-shadow: 6px 6px 0 rgba(43,32,29,0.12), 0 16px 40px rgba(0,0,0,0.12);
    width: 260px;
    overflow: hidden;
    opacity: 0;
    transform: translateY(12px) scale(0.96);
    transform-origin: bottom right;
    pointer-events: none;
    transition: opacity .25s, transform .25s;
}

    .wa-popup.visible {
        opacity: 1;
        transform: translateY(0) scale(1);
        pointer-events: all;
    }

.wa-popup-header {
    background: #128C7E;
    padding: 14px 16px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.wa-popup-avatar {
    width: 36px;
    height: 36px;
    border-radius: 0; /* recto */
    background: rgba(255,255,255,0.18);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

    .wa-popup-avatar svg {
        width: 18px;
        height: 18px;
    }

.wa-popup-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
    flex: 1;
}

.wa-popup-name {
    font-size: 0.8rem;
    font-weight: 600;
    color: #fff;
    line-height: 1;
}

.wa-popup-status {
    font-size: 0.66rem;
    color: rgba(255,255,255,0.65);
    display: flex;
    align-items: center;
    gap: 5px;
}

.wa-status-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #25D366;
    display: inline-block;
    animation: wa-pulse 2s infinite;
}

@keyframes wa-pulse {
    0%,100% {
        opacity: 1;
    }

    50% {
        opacity: 0.35;
    }
}

.wa-popup-close {
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 2px;
    flex-shrink: 0;
}

    .wa-popup-close svg {
        width: 13px;
        height: 13px;
    }

.wa-popup-body {
    background: #e5ddd5;
    padding: 14px 12px;
}

.wa-message-bubble {
    background: #fff;
    border-radius: 0 10px 10px 10px;
    padding: 10px 14px 22px;
    position: relative;
    box-shadow: 2px 2px 0 rgba(0,0,0,0.06);
    display: inline-block;
    max-width: 100%;
}

    .wa-message-bubble::before {
        content: '';
        position: absolute;
        top: 0;
        left: -7px;
        border-width: 0 7px 7px 0;
        border-style: solid;
        border-color: transparent #fff transparent transparent;
    }

.wa-message-text {
    font-size: 0.83rem;
    color: #111;
    line-height: 1.5;
    margin: 0;
}

.wa-message-time {
    position: absolute;
    bottom: 6px;
    right: 10px;
    font-size: 0.58rem;
    color: #aaa;
}

.wa-popup-footer {
    padding: 10px 12px;
    background: #fff;
}

.wa-action-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 10px 16px;
    background: #25D366;
    color: #fff !important;
    text-decoration: none;
    border-radius: 0; /* recto */
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 1px;
    transition: background .2s;
}

    .wa-action-btn:hover {
        background: #128C7E;
        color: #fff !important;
    }

    .wa-action-btn svg {
        width: 15px;
        height: 15px;
        flex-shrink: 0;
    }

.wa-btn {
    width: 54px;
    height: 54px;
    border-radius: 0 50% 50% 50%; /* gota — esquina sup-izq recta */
    background: #25D366;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 4px 4px 0 rgba(37,211,102,0.3), 0 8px 24px rgba(37,211,102,0.35);
    transition: transform .2s, box-shadow .2s;
    position: relative;
    flex-shrink: 0;
}

    .wa-btn:hover {
        transform: scale(1.06) rotate(-4deg);
        box-shadow: 6px 6px 0 rgba(37,211,102,0.3), 0 12px 28px rgba(37,211,102,0.4);
    }

.icon-wa, .icon-close {
    position: absolute;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity .2s, transform .28s;
}

    .icon-wa svg, .icon-close svg {
        width: 26px;
        height: 26px;
    }

.icon-close {
    opacity: 0;
    transform: rotate(-90deg);
}

.wa-btn.open .icon-wa {
    opacity: 0;
    transform: rotate(90deg) scale(0.7);
}

.wa-btn.open .icon-close {
    opacity: 1;
    transform: rotate(0deg);
}

.wa-badge {
    position: absolute;
    top: -2px;
    right: -2px;
    width: 16px;
    height: 16px;
    background: var(--brown-d);
    color: #fff;
    border-radius: 50%;
    font-size: 0.58rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #fff;
    animation: wa-badge-pop .35s cubic-bezier(.2,.8,.2,1) both;
}

@keyframes wa-badge-pop {
    from {
        transform: scale(0);
    }

    to {
        transform: scale(1);
    }
}

.wa-badge.hidden {
    display: none;
}

/* =========================================
   RESPONSIVE
========================================= */
@media (max-width: 991.98px) {
    .top-header {
        padding: 16px 0;
    }

    .top-left {
        align-items: center;
        margin-bottom: 10px;
    }

    .header-slogan {
        text-align: center;
        margin-top: 8px;
        font-size: 0.88rem;
    }

    .top-header .col-lg-4:nth-child(2)::before,
    .top-header .col-lg-4:nth-child(2)::after {
        display: none;
    }

    .main-navbar {
        height: auto;
        min-height: var(--navbar-h);
    }

        .main-navbar .nav-link {
            height: auto;
            line-height: 1;
            padding: 13px 20px !important;
            border: none !important;
            border-bottom: 1px solid rgba(255,255,255,0.07) !important;
            text-align: center;
        }

            .main-navbar .nav-link::before {
                display: none;
            }

        .main-navbar .nav-item:first-child .nav-link {
            border-left: none !important;
        }

    .footer-main {
        clip-path: none;
    }
}

@media (max-width: 480px) {
    .wa-widget {
        bottom: 16px;
        right: 16px;
    }

    .wa-popup {
        width: 220px;
    }
}
