/* styles.css */
:root {
    --header-height: 120px;
    --primary-color: #333;
    --accent-color: #ff4081;
    --transition-time: 0.3s;
}

a {
    text-decoration: none; /* Quita el subrayado */
    color: inherit; /* Mantiene el color del texto sin cambiarlo */
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    padding-top: var(--header-height);
    overflow-x: hidden;
    background: white;
}



/* Header y Navegación */
.main-header {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgb(255, 255, 255);
    z-index: 1000;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.header-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.5rem 1rem;
    max-width: 1400px;
    margin: 0 auto;
    height: 60px;
    position: relative;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    z-index: 1002;
    width: 40px;
    height: 40px;
    position: relative;
}

.menu-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--primary-color);
    margin: 5px auto;
    transition: all 0.3s ease;
}

.menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

.logo-container {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1001;
}

.logo {
    height: 60px;
    width: auto;
    object-fit: contain;
}

.cart-container {
    margin-left: auto;
    z-index: 1002;
}

.main-nav {
    width: 100%;
    background: white;
    padding: 0.5rem 0;
    border-top: 1px solid #eee;
}

.main-nav ul {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 2rem;
    list-style: none;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0.5rem 1rem;
}

.main-nav a {
    color: var(--primary-color);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: color var(--transition-time);
}

.main-nav a:hover {
    color: var(--accent-color);
}

/* Hero Section */
.hero-section {
    width: 100%;
    margin-bottom: 1rem;
}

.hero-image {
    width: 100%;
    height: auto;
    display: block;
}

/* Categories Section */
.categories-section {
    padding: 0.25rem 0;
    max-width: 1500px;
    margin: 0 auto;
}

.categories-container {
    position: relative;
    overflow: hidden;
    padding: 0 0.1rem;
}

.categories-wrapper {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.5rem;
    transition: transform var(--transition-time) ease;
}

.category-card {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    background: #f5f5f5;
    aspect-ratio: 0.8;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    opacity: 0;
    transform: translateX(50px);
    transition: all var(--transition-time) ease;
}

.category-card.animate {
    opacity: 1;
    transform: translateX(0);
}

.category-card:hover .category-image img {
    transform: scale(1.1);
}

.category-content {
    position: relative;
    width: 100%;
    height: 100%;
}

.category-title {
    position: absolute;
    top: 1rem;
    left: 1rem;
    background: rgba(255, 255, 255, 0.9);
    padding: 0.5rem 1rem;
    border-radius: 15px;
    font-size: 1.2rem;
    z-index: 2;
    font-weight: 500;
}

.category-image {
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    overflow: hidden;
}

.category-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-time) ease;
}

.ver-mas {
    position: absolute;
    bottom: 1.5rem;
    left: 50%;
    transform: translateX(-50%);
    background: black;
    color: white;
    border: none;
    padding: 0.8rem 2rem;
    border-radius: 25px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    z-index: 2;
    transition: all var(--transition-time) ease;
    text-transform: uppercase;
}

.ver-mas:hover {
    background: var(--accent-color);
    transform: translateX(-50%) translateY(-2px);
}

.nav-button {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.9);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 1.5rem;
    cursor: pointer;
    z-index: 2;
    display: none;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

.nav-button.prev { left: 0.25rem; }
.nav-button.next { right: 0.25rem; }

@media (max-width: 768px) {
    :root {
        --header-height: 60px;
    }

    body {
        padding-top: var(--header-height);
    }

    .menu-toggle {
        display: block;
    }

    .main-header {
        height: var(--header-height);
    }

    .header-container {
        height: var(--header-height);
    }

    .logo {
        height: 50px;
    }

    .main-nav {
        display: none;
        position: fixed;
        top: var(--header-height);
        left: 0;
        width: 100%;
        height: calc(100vh - var(--header-height));
        background: white;
        padding: 0;
        transform: translateX(-100%);
        transition: transform var(--transition-time) ease;
    }

    .main-nav.active {
        display: block;
        transform: translateX(0);
    }

    .main-nav ul {
        flex-direction: column;
        gap: 0;
        height: 100%;
        padding: 2rem;
    }

    .main-nav li {
        width: 100%;
        opacity: 0;
        transform: translateX(-20px);
        transition: all var(--transition-time) ease;
        border-bottom: 1px solid #eee;
    }

    .main-nav.active li {
        opacity: 1;
        transform: translateX(0);
    }

    .main-nav a {
        display: block;
        padding: 1rem;
        text-align: center;
        font-size: 1.2rem;
    }

    .hero-section {
        width: 100%;
        height: 70vh;
        overflow: hidden;
    }

    .hero-image {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

    .categories-wrapper {
        grid-template-columns: repeat(4, calc(50% - 0.25rem));
        gap: 0.5rem;
    }

    .category-card {
        aspect-ratio: 0.9;
    }

    .nav-button {
        display: flex;
    }

    /* Animación para los elementos del menú */
    .main-nav li:nth-child(1) { transition-delay: 0.1s; }
    .main-nav li:nth-child(2) { transition-delay: 0.2s; }
    .main-nav li:nth-child(3) { transition-delay: 0.3s; }
    .main-nav li:nth-child(4) { transition-delay: 0.4s; }
    .main-nav li:nth-child(5) { transition-delay: 0.5s; }
    .main-nav li:nth-child(6) { transition-delay: 0.6s; }
    .main-nav li:nth-child(7) { transition-delay: 0.7s; }

    .category-title {
        font-size: 1rem;
        padding: 0.4rem 0.8rem;
    }

    .ver-mas {
        padding: 0.6rem 1.5rem;
        font-size: 0.8rem;
        bottom: 1rem;
    }

    .nav-button {
        width: 35px;
        height: 35px;
        font-size: 1.2rem;
    }
}

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

@keyframes slideIn {
    from { transform: translateX(-100%); }
    to { transform: translateX(0); }
}

.grabbing {
    cursor: grabbing;
    cursor: -webkit-grabbing;
}







/* Categories Section - Responsive Design */
.categories-section {
    padding: 0.25rem 0;
    max-width: 1500px;
    margin: 0 auto;
}

.categories-container {
    position: relative;
    overflow: hidden;
    padding: 0 0.1rem;
}

.categories-wrapper {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.5rem;
    transition: transform var(--transition-time) ease;
}

/* Ajustes para diferentes números de categorías */
.categories-wrapper:has(.category-card:nth-child(1):last-child) {
    grid-template-columns: 1fr; /* 1 categoría ocupa todo el ancho */
}

.categories-wrapper:has(.category-card:nth-child(2):last-child) {
    grid-template-columns: repeat(2, 1fr); /* 2 categorías se dividen */
}

.categories-wrapper:has(.category-card:nth-child(3):last-child) {
    grid-template-columns: repeat(3, 1fr); /* 3 categorías */
}

.category-card {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    background: #f5f5f5;
    height: 400px; /* Altura fija */
    width: 100%;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    opacity: 0;
    transform: translateX(50px);
    transition: all var(--transition-time) ease;
}

.category-card.animate {
    opacity: 1;
    transform: translateX(0);
}

.category-card:hover .category-image img {
    transform: scale(1.1);
}

.category-content {
    position: relative;
    width: 100%;
    height: 100%;
}

.category-title {
    position: absolute;
    top: 1rem;
    left: 1rem;
    background: rgba(255, 255, 255, 0.9);
    padding: 0.5rem 1rem;
    border-radius: 15px;
    font-size: 1.2rem;
    z-index: 2;
    font-weight: 500;
}

.category-image {
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
}

.category-image img {
    max-width: 100%;
    max-height: 100%;
    object-fit: cover;
    transition: transform var(--transition-time) ease;
}

.ver-mas {
    position: absolute;
    bottom: 1.5rem;
    left: 50%;
    transform: translateX(-50%);
    background: black;
    color: white;
    border: none;
    padding: 0.8rem 2rem;
    border-radius: 25px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    z-index: 2;
    transition: all var(--transition-time) ease;
    text-transform: uppercase;
}

.ver-mas:hover {
    background: var(--accent-color);
    transform: translateX(-50%) translateY(-2px);
}

/* Responsive Adjustments */
@media (max-width: 1200px) {
    .categories-wrapper {
        grid-template-columns: repeat(3, 1fr);
    }

    .categories-wrapper:has(.category-card:nth-child(1):last-child) {
        grid-template-columns: 1fr;
    }

    .categories-wrapper:has(.category-card:nth-child(2):last-child) {
        grid-template-columns: repeat(2, 1fr);
    }

    .category-card {
        height: 350px; /* Ajuste de altura para pantallas más pequeñas */
    }
}

@media (max-width: 768px) {
    .categories-wrapper {
        grid-template-columns: repeat(2, 1fr);
    }

    .categories-wrapper:has(.category-card:nth-child(1):last-child) {
        grid-template-columns: 1fr;
    }

    .category-card {
        height: 300px; /* Ajuste de altura para tablets */
    }

    .category-title {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .categories-wrapper {
        grid-template-columns: 1fr;
    }

    .category-card {
        height: 250px; /* Ajuste de altura para móviles */
    }
}



.site-footer {
    background-color: #1a1a1a;
    color: white;
    padding: 4rem 2rem;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr;
    gap: 3rem;
}

.footer-signup h3 {
    font-size: 2rem;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.footer-signup p {
    margin-bottom: 1.5rem;
    color: #999;
}

.signup-form .input-group {
    position: relative;
    margin-bottom: 1rem;
}

.signup-form input {
    width: 100%;
    padding: 0.5rem 0;
    background: transparent;
    border: none;
    border-bottom: 1px solid #444;
    color: white;
    font-size: 1rem;
}

.signup-form input::placeholder {
    color: #777;
}

.signup-form button {
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #777;
    cursor: pointer;
    font-size: 1.2rem;
}

.footer-links {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 2rem;
}

.footer-column h4 {
    margin-bottom: 1rem;
    font-size: 1rem;
}

.footer-column ul {
    list-style: none;
    padding: 0;
}

.footer-column li {
    margin-bottom: 0.5rem;
}

.footer-column a {
    color: #999;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-column a:hover {
    color: white;
}

@media (min-width: 768px) {
    .footer-container {
        grid-template-columns: 1fr 2fr;
    }
    
    .footer-links {
        grid-template-columns: repeat(4, 1fr);
    }
}









/* Mega Menu Styles */
.shop-menu {
    position: static;
}

.mega-menu {
    position: fixed;
    left: 0;
    right: 0;
    top: calc(var(--header-height) + 45px);
    bottom: 0;
    background: white;
    visibility: hidden;
    opacity: 0;
    transition: all 0.3s ease;
    z-index: 999;
    border-top: 1px solid #eee;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);

}

.shop-menu:hover .mega-menu,
.mega-menu.show {
    visibility: visible;
    opacity: 1;
}

.mega-menu .menu-content {
    display: grid;
    grid-template-columns: 400px 1fr;
    height: calc(100vh - var(--header-height) - 45px);
    width: 100%;
    margin: 0;
}

.mega-menu .categories-list {
    padding: 2rem;
    background: #f8f8f8;
    display: flex;
    align-items: flex-start;
    justify-content: center;
}

.mega-menu .categories-wrapper {
    width: 100%;
    display: flex;
    flex-direction: column;
    padding-top: 2rem;
}

.mega-menu .categories-wrapper a {
    display: block;
    padding: 1.5rem;
    margin: 0.5rem 0;
    color: #333;
    text-decoration: none;
    transition: all 0.3s ease;
    font-weight: bold;
    font-size: 1.8rem;
    text-transform: uppercase;
    position: relative;
}

.mega-menu .categories-wrapper a:hover,
.mega-menu .categories-wrapper a.active {
    color: black;
    transform: translateX(20px);
}

.mega-menu .category-preview {
    position: relative;
    overflow: hidden;
    height: 100%;
}

.mega-menu .preview-content {
    height: 100%;
    opacity: 0;
    transform: translateX(20px);
    transition: all 0.5s ease;
}

.mega-menu .preview-content.active {
    opacity: 1;
    transform: translateX(0);
}

.mega-menu .preview-image {
    width: 100%;
    height: 100%;
}

.mega-menu .preview-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Corrección del menú móvil */
@media (max-width: 768px) {
    .main-nav {
        top: var(--header-height);
        margin-top: 0;
        border-top: 1px solid #eee;
    }

    .mega-menu {
        position: static;
        visibility: visible;
        opacity: 1;
        height: 0;
        overflow: hidden;
        transition: height 0.3s ease;
        border-top: none;
    }

    .mega-menu.active {
        height: auto;
    }

    .mega-menu .menu-content {
        grid-template-columns: 1fr;
        height: auto;
    }

    .mega-menu .category-preview {
        display: none;
    }

    .mega-menu .categories-list {
        padding: 1rem;
    }

    .mega-menu .categories-wrapper {
        padding-top: 1rem;
    }

    .mega-menu .categories-wrapper a {
        font-size: 1.2rem;
        padding: 1rem;
        margin: 0.25rem 0;
    }
}


.mobile-categories {
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.back-button {
    padding: 0.5rem;
    background: none;
    border: none;
    font-size: 1rem;
    color: inherit;
    text-align: left;
    cursor: pointer;
}

.mobile-category-link {
    padding: 0.5rem;
    text-decoration: none;
    color: inherit;
}

#splash-screen {
    position: fixed;
    width: 100%;
    height: 100vh;
    background: white;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s ease, visibility 0.5s;
}

.splash-logo {
    width: 150px; /* Ajusta el tamaño */
    animation: fadeIn 1.5s ease-in-out infinite alternate;
}

@keyframes fadeIn {
    from { opacity: 0.5; }
    to { opacity: 1; }
}
/* Estilos para el contenedor de carrito y búsqueda */
.cart-container {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-left: auto;
    z-index: 1002;
}

.search-button {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    transition: color 0.3s ease;
}

.search-button:hover {
    color: var(--accent-color);
}

/* Modal de búsqueda */
.search-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.98);
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    -webkit-overflow-scrolling: touch; /* Para scroll suave en iOS */

}

.search-modal.active {
    opacity: 1;
    visibility: visible;
}

.search-container {
    max-width: 800px;
    width: 100%;
    margin: 2rem auto;
    padding: 1rem;
}

.search-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2rem;
}

.search-input-wrapper {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 1rem;
    border-bottom: 2px solid #ddd;
    padding: 0.5rem;
}

.search-input {
    width: 100%;
    border: none;
    background: none;
    font-size: 1.2rem;
    padding: 0.5rem;
    outline: none;
}

.close-search {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
}

.search-results {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
    padding: 1rem;
    overflow-y: auto;
    max-height: calc(100vh - 200px);
    padding-bottom: 400px; /* Espacio extra al final */

}

.search-result-item {
    display: flex;
    flex-direction: column;
    padding: 1rem;
    border: 1px solid #eee;
    border-radius: 8px;
    transition: all 0.3s ease;
    cursor: pointer;
    background: white;
}

.search-result-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.search-result-image {
    width: 100%;
    aspect-ratio: 1;
    object-fit: cover;
    border-radius: 4px;
    margin-bottom: 1rem;
}

.search-result-name {
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.search-result-price {
    color: var(--accent-color);
    font-weight: bold;
}

/* Responsive */
@media (max-width: 768px) {
    .search-container {
        margin: 1rem auto;
        padding: 0.5rem;
    }

    .search-results {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 0.5rem;
        padding: 0.5rem;
        max-height: calc(100vh - 150px);
    }

    .search-result-name {
        font-size: 0.9rem;
    }

    .search-input {
        font-size: 1rem;
    }
}

/* Estilos para el botón de búsqueda */
.search-button {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    transition: color 0.3s ease;
}

.search-button:hover {
    color: var(--accent-color);
}

/* Modal de búsqueda */
.search-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--window-height, 100%); /* Usaremos una variable CSS */
    background: rgba(255, 255, 255, 0.98);
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.search-modal.active {
    opacity: 1;
    visibility: visible;
}

.search-container {
    max-width: 800px;
    margin: 2rem auto;
    padding: 1rem;
}

.search-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2rem;
}

.search-input-wrapper {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 1rem;
    border-bottom: 2px solid #ddd;
    padding: 0.5rem;
}

.search-input {
    width: 100%;
    border: none;
    background: none;
    font-size: 1.2rem;
    padding: 0.5rem;
    outline: none;
}

.close-search {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    color: var(--primary-color);
}

.search-results {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
    padding: 1rem;
    overflow-y: auto;
    max-height: calc(100vh - 200px);
    padding-bottom: 300px; /* Espacio extra al final */

}

@media (max-width: 768px) {
    .search-container {
        margin: 1rem auto;
        padding: 0.5rem;
    }

    .search-results {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
        gap: 1rem;
    }

    .search-input {
        font-size: 1rem;
    }
}

/* Estilos del Splash Screen */
@font-face {
    font-family: 'AZONIX';
    src: url('assets/fonts/AZONIX.otf') format('opentype');
}

#splash-screen {
    position: fixed;
    width: 100%;
    height: 100vh;
    background: white;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s ease, visibility 0.5s;
}

.splash-logo {
    width: 150px;
    animation: fadeIn 1.5s ease-in-out infinite alternate;
}

.splash-credits {
    margin-top: 20px;
    font-size: 16px;
    opacity: 0.8;
    animation: fadeIn 1.5s ease-in-out infinite alternate;
}

.splash-credits span {
    font-family: 'AZONIX', sans-serif;
}

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