/* ===== SISTEMA DE NAVEGACIÓN ESTANDARIZADO ===== */

/* Variables CSS para consistencia */
:root {
    --primary-color: #1a2332;
    --secondary-color: #2c3e50;
    --accent-color: #c9a961;
    --accent-light: #f4e9d1;
    --text-dark: #2c3e50;
    --text-light: #7f8c8d;
    --white: #ffffff;
    --light-bg: #f8fafc;
    --border-color: #e1e8ed;
    --shadow-sm: 0 2px 4px rgba(0,0,0,0.08);
    --shadow-md: 0 4px 12px rgba(0,0,0,0.1);
    --shadow-lg: 0 8px 32px rgba(0,0,0,0.12);
    --border-radius: 12px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background: var(--white);
    min-height: 100vh;
    padding-top: 80px;
}

/* ===== NAVBAR PRINCIPAL ===== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: var(--primary-color);
    box-shadow: var(--shadow-md);
    border-bottom: 1px solid rgba(255,255,255,0.1);
    transition: var(--transition);
}

.navbar.scrolled {
    background: rgba(26, 35, 50, 0.95);
    backdrop-filter: blur(10px);
}

.navbar-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
    height: 80px;
}

.navbar-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: var(--white);
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: -0.5px;
    transition: var(--transition);
}

.navbar-logo:hover {
    color: var(--accent-color);
}

.navbar-logo-icon {
    width: 40px;
    height: 40px;
    background: var(--accent-color);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 1.2rem;
}

.navbar-logo-text {
    display: flex;
    flex-direction: column;
    line-height: 1;
}

.navbar-logo-name {
    font-size: 1.2rem;
    font-weight: 800;
}

.navbar-logo-title {
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--accent-color);
}

/* Menú de navegación */
.navbar-menu {
    display: flex;
    align-items: center;
    gap: 5px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.navbar-menu-item {
    position: relative;
}

.navbar-menu-link {
    display: block;
    padding: 12px 20px;
    color: var(--white);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    border-radius: 8px;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.navbar-menu-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, var(--accent-color), #d4af6a);
    transform: scaleX(0);
    transform-origin: left;
    transition: var(--transition);
    z-index: -1;
}

.navbar-menu-link:hover::before,
.navbar-menu-link.active::before {
    transform: scaleX(1);
}

.navbar-menu-link:hover,
.navbar-menu-link.active {
    color: var(--white);
}

/* Botón de menú móvil */
.navbar-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--white);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 8px;
    border-radius: 8px;
    transition: var(--transition);
}

.navbar-toggle:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--accent-color);
}

/* ===== MENÚ LATERAL MÓVIL ===== */
.mobile-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 320px;
    height: 100vh;
    background: var(--primary-color);
    z-index: 1100;
    transition: var(--transition);
    box-shadow: var(--shadow-lg);
    overflow-y: auto;
}

.mobile-menu.open {
    right: 0;
}

.mobile-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.mobile-menu-logo {
    color: var(--white);
    font-size: 1.3rem;
    font-weight: 800;
}

.mobile-menu-close {
    background: none;
    border: none;
    color: var(--white);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 8px;
    border-radius: 8px;
    transition: var(--transition);
}

.mobile-menu-close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--accent-color);
}

.mobile-menu-nav {
    padding: 20px 0;
}

.mobile-menu-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.mobile-menu-item {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.mobile-menu-link {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 20px 25px;
    color: var(--white);
    text-decoration: none;
    font-weight: 500;
    font-size: 1rem;
    transition: var(--transition);
    position: relative;
}

.mobile-menu-link::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: var(--accent-color);
    transform: scaleY(0);
    transition: var(--transition);
}

.mobile-menu-link:hover::before,
.mobile-menu-link.active::before {
    transform: scaleY(1);
}

.mobile-menu-link:hover,
.mobile-menu-link.active {
    background: rgba(255, 255, 255, 0.05);
    color: var(--accent-color);
}

.mobile-menu-icon {
    width: 20px;
    text-align: center;
}

/* Overlay del menú móvil */
.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1050;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    backdrop-filter: blur(2px);
}

.mobile-menu-overlay.open {
    opacity: 1;
    visibility: visible;
}

/* ===== FOOTER ESTANDARIZADO ===== */
.footer {
    background: var(--primary-color);
    color: var(--white);
    margin-top: auto;
}

.footer-main {
    padding: 60px 0 40px;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-section h3 {
    color: var(--accent-color);
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 20px;
}

.footer-section p,
.footer-section a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    line-height: 1.8;
    transition: var(--transition);
}

.footer-section a:hover {
    color: var(--accent-color);
}

.footer-contact-item {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 15px;
}

.footer-contact-icon {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-color);
    font-size: 1rem;
    flex-shrink: 0;
}

.footer-social {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.footer-social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    background: rgba(255, 255, 255, 0.1);
    color: var(--white);
    border-radius: 12px;
    text-decoration: none;
    font-size: 1.2rem;
    transition: var(--transition);
}

.footer-social-link:hover {
    background: var(--accent-color);
    color: var(--white);
    transform: translateY(-2px);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding: 25px 0;
    text-align: center;
}

.footer-bottom p {
    color: rgba(255, 255, 255, 0.7);
    margin: 0;
    font-size: 0.9rem;
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 768px) {
    .navbar-menu {
        display: none;
    }
    
    .navbar-toggle {
        display: block;
    }
    
    .navbar-container {
        justify-content: space-between; /* Logo a la izquierda, hamburger a la derecha */
        padding: 0 20px;
    }
    
    .navbar-logo {
        font-size: 1.1rem; /* Reducir ligeramente el tamaño pero mantener visible */
        flex-shrink: 0; /* Prevenir que se achique */
        display: flex; /* Asegurar que se mantenga como flex */
        align-items: center;
        gap: 10px; /* Reducir el gap en móvil */
    }
    
    .navbar-logo-text {
        display: flex; /* Mantener visible en móvil */
        flex-direction: column;
        line-height: 1.1;
    }
    
    .navbar-logo-name {
        font-size: 1rem; /* Ajustar tamaño para móvil */
        font-weight: 700;
    }
    
    .navbar-logo-title {
        font-size: 0.75rem; /* Ajustar tamaño del subtítulo */
        opacity: 0.9;
    }
    
    .navbar-logo-icon {
        width: 35px; /* Reducir tamaño del ícono */
        height: 35px;
        font-size: 1rem;
        border-radius: 6px; /* Ajustar border-radius proporcionalmente */
    }
    
    .navbar-toggle {
        padding: 8px;
        font-size: 1.2rem;
    }
    
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .footer-social {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .navbar-container {
        padding: 0 15px;
        height: 70px; /* Reducir altura en pantallas muy pequeñas */
    }
    
    .navbar-logo {
        font-size: 1rem; /* Reducir más en pantallas muy pequeñas */
        gap: 8px; /* Reducir espacio entre ícono y texto */
    }
    
    .navbar-logo-name {
        font-size: 0.9rem;
    }
    
    .navbar-logo-title {
        font-size: 0.7rem;
    }
    
    .navbar-logo-icon {
        width: 30px;
        height: 30px;
        font-size: 0.9rem;
    }
    
    .mobile-menu {
        width: 100%;
        right: -100%;
    }
    
    .footer-container {
        padding: 0 15px;
    }
    
    /* Ajustar padding del body para la nueva altura del navbar */
    body {
        padding-top: 70px;
    }
}

/* ===== ANIMACIONES ===== */
@keyframes slideInRight {
    from {
        transform: translateX(100%);
    }
    to {
        transform: translateX(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.mobile-menu.open {
    animation: slideInRight 0.3s ease-out;
}

.mobile-menu-overlay.open {
    animation: fadeIn 0.3s ease-out;
}
