/* Barra de navegación */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid #E0DDD9;
    z-index: 1000;
    transition: all 0.3s ease;
}

.navbar-container {
    max-width: 1600px;
    margin: 0 auto;
    padding: 20px 60px;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
}

.navbar-logo {
    font-size: 2em;
    font-weight: 300;
    letter-spacing: 0.1em;
    color: #3a3a3a;
    font-family: 'Cormorant Garamond', serif;
    font-style: italic;
    text-decoration: none;
    transition: all 0.3s ease;
    justify-self: start;
}

.navbar-logo:hover {
    color: #000;
}

.navbar-menu {
    display: flex;
    align-items: center;
    gap: 40px;
    justify-self: center;
}

.navbar-link {
    color: #3a3a3a;
    text-decoration: none;
    font-size: 14px;
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-family: 'Helvetica Neue', sans-serif;
    padding: 8px 0;
    position: relative;
    transition: all 0.3s ease;
}

.navbar-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 1px;
    background: #3a3a3a;
    transition: width 0.3s ease;
}

.navbar-link:hover::after,
.navbar-link.active::after {
    width: 100%;
}

.navbar-link:hover {
    color: #000;
}

.navbar-link.active {
    color: #000;
    font-weight: 500;
}

/* Botón de carrito en la esquina */
.navbar-cart-btn {
    justify-self: end;
    display: flex;
    align-items: center;
    gap: 10px;
    background: transparent;
    border: 1px solid #3a3a3a;
    color: #3a3a3a;
    padding: 10px 20px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-family: 'Helvetica Neue', sans-serif;
    transition: all 0.3s ease;
}

.navbar-cart-btn:hover {
    background: #3a3a3a;
    color: #F5F1ED;
}

.navbar-cart-btn svg {
    flex-shrink: 0;
}

/* Toggle para móvil */
.navbar-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 8px;
    grid-column: 3;
    justify-self: end;
}

.navbar-toggle-icon {
    width: 25px;
    height: 2px;
    background: #3a3a3a;
    transition: all 0.3s ease;
}

.navbar-toggle.active .navbar-toggle-icon:nth-child(1) {
    transform: rotate(45deg) translate(7px, 7px);
}

.navbar-toggle.active .navbar-toggle-icon:nth-child(2) {
    opacity: 0;
}

.navbar-toggle.active .navbar-toggle-icon:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

/* Responsive */
@media (max-width: 768px) {
    .navbar-container {
        padding: 15px 30px;
        grid-template-columns: auto 1fr auto;
        gap: 15px;
    }

    .navbar-logo {
        font-size: 1.5em;
        grid-column: 1;
    }

    .navbar-toggle {
        display: flex;
        grid-column: 2;
    }

    .navbar-cart-btn {
        grid-column: 3;
        padding: 8px 15px;
    }

    .navbar-menu {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(10px);
        flex-direction: column;
        gap: 0;
        padding: 0;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease;
        border-bottom: 1px solid transparent;
        grid-column: 1 / -1;
    }

    .navbar-menu.active {
        max-height: 300px;
        border-bottom-color: #E0DDD9;
    }

    .navbar-link {
        width: 100%;
        padding: 20px 30px;
        border-bottom: 1px solid #E0DDD9;
    }

    .navbar-link:last-child {
        border-bottom: none;
    }

    .navbar-link::after {
        display: none;
    }

    .navbar-link.active {
        background: #FAFAF8;
    }
}

/* Ajuste de padding para el contenido cuando hay navbar fija */
body {
    padding-top: 80px;
}

@media (max-width: 768px) {
    body {
        padding-top: 65px;
    }
}