/* assets/css/responsive.css - Adaptaciones Tablet y Mobile para NOVA MARKET */

/* ==========================================================================
   TABLET (max-width: 1024px)
   ========================================================================== */
@media (max-width: 1024px) {
  .categories-grid {
    grid-template-columns: repeat(4, 1fr);
  }

  .products-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
  }



  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 28px;
  }
}

/* ==========================================================================
   MOBILE (max-width: 768px)
   ========================================================================== */
@media (max-width: 768px) {
  .container {
    padding: 0 14px;
  }

  /* Ocultar elementos desktop */
  .desktop-only {
    display: none !important;
  }

  /* Header Móvil */
  .site-header {
    position: sticky;
    top: 0;
  }

  .header-top {
    min-height: 68px;
    height: auto;
    padding: 8px 0;
    gap: 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
  }

  .mobile-menu-toggle {
    background: transparent;
    border: none;
    color: var(--white);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    flex-shrink: 0;
  }

  .mobile-menu-toggle i {
    width: 24px;
    height: 24px;
  }

  .header-logo {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0 6px;
    min-width: 0;
    line-height: 0;
  }

  .header-logo img,
  .site-header-logo-img {
    height: var(--logo-height-mob, 68px);
    max-height: var(--logo-height-mob, 68px);
    max-width: var(--logo-max-width-mob, 270px);
    width: auto;
    object-fit: contain;
    object-position: center;
    display: block;
  }

  .mobile-search-bar {
    padding: 8px 14px 12px;
    background: var(--navy);
    border-top: 1px solid rgba(255, 255, 255, 0.08);
  }

  .mobile-search-bar .search-form {
    padding: 2px 2px 2px 14px;
  }

  .mobile-search-bar input {
    font-size: 13px;
  }

  .mobile-search-bar .search-btn {
    width: 36px;
    height: 36px;
  }

  /* Hero Móvil (Proporción 600x280 idéntica a Mercado Libre) */
  .hero-section {
    padding: 10px 0 12px;
  }

  .hero-slider-wrapper {
    border-radius: 14px;
    background: transparent;
    box-shadow: 0 4px 16px rgba(7, 27, 49, 0.1);
  }

  .hero-slide {
    padding: 0 !important;
    min-height: auto !important;
    border-radius: 14px;
    background: transparent !important;
  }

  .hero-slide-link {
    display: block;
    width: 100%;
    border-radius: 14px;
    overflow: hidden;
  }

  .hero-slide-img {
    border-radius: 14px;
    aspect-ratio: 600 / 280;
    width: 100%;
    height: auto;
    object-fit: cover;
    display: block;
  }

  .hero-dots {
    bottom: 8px;
    padding: 3px 8px;
    background: rgba(4, 20, 38, 0.35);
  }

  .hero-dot {
    width: 6px;
    height: 6px;
  }

  .hero-dot.active {
    width: 16px;
  }

  /* Categorías en scroll horizontal */
  .quick-categories-section {
    padding: 10px 0 16px;
  }

  .categories-grid {
    display: flex;
    overflow-x: auto;
    gap: 10px;
    scrollbar-width: none;
    padding-bottom: 4px;
  }

  .categories-grid::-webkit-scrollbar {
    display: none;
  }

  .category-card {
    min-width: 82px;
    flex-shrink: 0;
    padding: 12px 6px;
    border-radius: 12px;
  }

  .category-icon-box {
    width: 38px;
    height: 38px;
  }

  .category-icon-box i {
    width: 18px;
    height: 18px;
  }

  .category-card-name {
    font-size: 11.5px;
    font-weight: 500;
  }

  /* Grilla de Ofertas Destacadas en Móvil: 2 Columnas */
  .products-section {
    padding: 12px 0 24px;
  }

  .section-title {
    font-size: 17px;
    font-weight: 600;
    color: #1E293B;
    letter-spacing: -0.2px;
  }

  .products-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }

  .product-card {
    padding: 12px;
    border-radius: 12px;
  }

  .product-card-image {
    height: 130px;
  }

  .product-card-name {
    font-size: 12.5px;
    font-weight: 400;
    color: #333333;
    line-height: 1.3;
    min-height: 34px;
    margin-bottom: 4px;
  }

  .product-rating {
    margin-bottom: 6px;
    font-size: 11px;
  }

  .star-icon {
    width: 11px;
    height: 11px;
  }

  .current-price {
    font-size: 17px;
    font-weight: 400;
    color: #333333;
    letter-spacing: -0.2px;
  }

  .old-price {
    font-size: 11px;
    font-weight: 400;
  }

  .installments-text {
    font-size: 11px;
    font-weight: 400;
    color: #00A650;
    margin-bottom: 6px;
  }

  .shipping-badge {
    font-size: 10.5px;
    font-weight: 500;
    padding: 2px 7px;
    margin-bottom: 10px;
  }

  .card-actions-row {
    flex-direction: column;
    gap: 6px;
  }

  .btn-buy-card {
    padding: 9px 12px;
    font-size: 12px;
    font-weight: 500;
    min-height: 38px;
  }

  .btn-add-cart-icon {
    display: none; /* En móvil dejamos comprar directo para maximizar conversión */
  }

  /* Carrusel Más Vendidos en Móvil */
  .bestsellers-slider .product-card {
    min-width: 160px;
    flex: 0 0 160px;
  }

  .carousel-nav-btn {
    display: none;
  }

  /* Banner Promocional */
  .promo-banner {
    flex-direction: column;
    text-align: center;
    padding: 20px 16px;
    gap: 14px;
  }

  .promo-banner-left {
    flex-direction: column;
    text-align: center;
    gap: 10px;
  }

  .promo-title {
    font-size: 18px;
    font-weight: 600;
  }

  .promo-center-visual {
    max-width: 180px;
  }

  /* Footer */
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 10px;
    text-align: center;
  }

  /* Cart Drawer en pantalla completa en móvil */
  .cart-drawer {
    max-width: 100%;
  }
}

/* ==========================================================================
   BARRA DE NAVEGACIÓN INFERIOR MÓVIL (Bottom Navigation)
   ========================================================================== */
.mobile-bottom-nav {
  display: none;
}

@media (max-width: 768px) {
  .mobile-bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 64px;
    background: var(--white);
    box-shadow: 0 -4px 20px rgba(7, 27, 49, 0.12);
    display: flex;
    align-items: center;
    justify-content: space-around;
    z-index: 950;
    border-top: 1px solid var(--border);
  }

  .bottom-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    color: var(--text-secondary);
    font-size: 10.5px;
    font-weight: 500;
    text-decoration: none;
    position: relative;
    width: 20%;
    height: 100%;
    transition: color 0.15s ease;
  }

  .bottom-nav-item.active {
    color: var(--blue);
    font-weight: 700;
  }

  .bottom-nav-item i {
    width: 20px;
    height: 20px;
  }

  .bottom-nav-badge {
    position: absolute;
    top: 6px;
    right: calc(50% - 16px);
    background: var(--blue);
    color: var(--white);
    font-size: 10px;
    font-weight: 700;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  /* Botón Destacado de WhatsApp Integrado en Barra Móvil */
  .bottom-nav-item.bottom-nav-wa {
    color: #15803D;
    text-decoration: none;
  }

  .bottom-nav-wa-circle {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: linear-gradient(135deg, #25D366 0%, #128C7E 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 3px 10px rgba(37, 211, 102, 0.45);
    position: relative;
    transition: transform 0.15s ease;
  }

  .bottom-nav-item.bottom-nav-wa:active .bottom-nav-wa-circle {
    transform: scale(0.92);
  }

  .bottom-nav-wa-svg {
    width: 18px;
    height: 18px;
  }

  .bottom-nav-wa-badge {
    position: absolute;
    top: -3px;
    right: -3px;
    background: #DC2626;
    color: #FFFFFF;
    font-size: 9px;
    font-weight: 800;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    border: 1.5px solid #FFFFFF;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
  }

  .bottom-nav-item.bottom-nav-wa span {
    color: #15803D;
    font-weight: 600;
    font-size: 10px;
  }
}

/* ==========================================================================
   RESEÑAS & QUIÉNES SOMOS - ADAPTACIONES RESPONSIVAS
   ========================================================================== */
@media (max-width: 1024px) {
  .reels-track .reel-card {
    flex: 0 0 calc((100% - 20px) / 2) !important;
    max-width: calc((100% - 20px) / 2) !important;
  }
  .reviews-track .review-card {
    flex: 0 0 calc((100% - 16px) / 2) !important;
    max-width: calc((100% - 16px) / 2) !important;
  }
  .about-grid {
    grid-template-columns: 1fr !important;
    gap: 32px !important;
  }
  .reviews-trust-banner {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 14px !important;
  }
}

@media (max-width: 768px) {
  .reels-section {
    padding: 24px 0 16px !important;
  }
  .reels-title {
    font-size: 20px !important;
  }
  .reels-carousel-wrapper {
    position: relative;
  }
  .reels-track {
    gap: 14px !important;
    padding: 6px 0 16px !important;
  }
  .reels-track .reel-card {
    flex: 0 0 100% !important;
    min-width: 100% !important;
    max-width: 100% !important;
    scroll-snap-align: start !important;
  }
  .reels-nav-btn {
    width: 38px !important;
    height: 38px !important;
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(4px) !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.18) !important;
  }
  .reels-nav-btn.prev {
    left: 4px !important;
  }
  .reels-nav-btn.next {
    right: 4px !important;
  }
  .reviews-section {
    padding: 24px 0 16px !important;
  }
  .reviews-title {
    font-size: 20px !important;
  }
  .reviews-carousel-wrapper {
    position: relative;
    width: 100%;
  }
  .reviews-track {
    gap: 14px !important;
    padding: 6px 0 14px !important;
  }
  .reviews-track .review-card {
    flex: 0 0 100% !important;
    min-width: 100% !important;
    max-width: 100% !important;
    scroll-snap-align: center !important;
    padding: 16px 14px 14px !important;
  }
  .reviews-nav-btn {
    width: 36px !important;
    height: 36px !important;
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(4px) !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.16) !important;
  }
  .reviews-nav-btn.prev {
    left: 4px !important;
  }
  .reviews-nav-btn.next {
    right: 4px !important;
  }
  .reviews-dots {
    margin-top: 12px !important;
    margin-bottom: 20px !important;
  }
  .about-section {
    padding: 20px 0 40px !important;
  }
  .about-card-container {
    padding: 22px 16px !important;
    border-radius: 14px !important;
  }
  .about-title {
    font-size: 20px !important;
  }
  .about-lead-p {
    font-size: 13.5px !important;
  }
  .about-stats-grid {
    grid-template-columns: 1fr 1fr !important;
    gap: 10px !important;
  }
  .about-stat-card {
    padding: 14px 10px !important;
  }
  .about-stat-number {
    font-size: 24px !important;
  }
  .about-actions-row {
    flex-direction: column !important;
    align-items: stretch !important;
  }
  .about-actions-row a {
    text-align: center !important;
    justify-content: center !important;
  }
  .reviews-trust-banner {
    grid-template-columns: 1fr !important;
    text-align: left !important;
    padding: 14px !important;
  }
  .trust-item {
    justify-content: flex-start !important;
  }
}

