@media(max-width:1024px){
.products-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
.hero-grid,.feature-grid,.contact-grid,.checkout-layout{grid-template-columns:1fr}
.footer-grid{grid-template-columns:1fr 1fr}
.order-summary{position:static}
.hero-card{margin-top:24px}
.product-modal{grid-template-columns:1fr;max-width:560px}
.modal-image{min-height:240px;border-radius:20px 20px 0 0}
}

@media(max-width:768px){
.mobile-toggle{display:flex !important}
.nav-links{position:fixed;top:0;left:0;right:0;bottom:0;background:#fff;flex-direction:column;align-items:center;justify-content:center;gap:4px;transform:translateY(-110%);opacity:0;transition:transform .35s cubic-bezier(.4,0,.2,1),opacity .3s ease;z-index:150;padding:80px 24px 40px}
.nav-links.show{transform:translateY(0);opacity:1}
.nav-links li{width:100%;max-width:280px;text-align:center}
.nav-links a{font-size:1.2rem;font-weight:700;color:#17181c;padding:16px 20px;border-radius:14px;display:block}
.nav-links a:hover,.nav-links a.active{background:rgba(108,92,231,.08);color:#6c5ce7}
.nav-links a.active::after{display:none}

/* BULLETPROOF MOBILE GRIDS - use calc to prevent ANY overflow */
.products-grid{grid-template-columns:repeat(2,calc(50% - 6px));gap:12px;width:100%;max-width:100%}
.category-grid{grid-template-columns:repeat(2,calc(50% - 6px));gap:12px;width:100%;max-width:100%}
.trust-grid{grid-template-columns:1fr 1fr}
.value-stack.two{grid-template-columns:1fr}
.form-row{grid-template-columns:1fr}

.hero-actions,.newsletter-form{flex-direction:column}
.hero-actions .btn,.newsletter-form input,.newsletter-form .btn{width:100%}
.footer-grid{grid-template-columns:1fr 1fr}
.footer-bottom{flex-direction:column;gap:8px;align-items:flex-start}
.shop-layout{grid-template-columns:1fr;width:100%;max-width:100%}
.shop-sidebar{order:2}
.shop-toolbar{flex-direction:column;gap:8px;align-items:flex-start}
.deals-hero h1{font-size:2rem}
.countdown-number{font-size:1.5rem;min-width:56px}
.product-modal{grid-template-columns:1fr;max-width:92vw}
.modal-image{min-height:200px;border-radius:20px 20px 0 0}
.modal-body{padding:20px}
.cart-sidebar{width:100%;max-width:100%}
.hero{padding:50px 0}
.section{padding:56px 0}
.page-header{padding:48px 0}
.page-header h1{font-size:1.8rem}
}

@media(max-width:480px){
.products-grid{grid-template-columns:repeat(2,calc(50% - 5px));gap:10px}
.category-grid{grid-template-columns:repeat(2,calc(50% - 5px));gap:10px}
.trust-grid{grid-template-columns:1fr}
.hero h1{font-size:2rem}
.hero-stats{flex-wrap:wrap;gap:16px}
.product-image{height:160px}
.product-info{padding:12px}
.product-name{font-size:.88rem}
.container{padding:0 12px}
.announcement-bar{font-size:.78rem;padding:8px 12px}
.nav-container{height:54px;padding:0 12px}
.countdown{flex-wrap:wrap;gap:10px}
}


@media(max-width:768px){.account-link{padding:9px 10px}.account-link span{display:none}.checkout-layout{gap:16px;padding:22px 0 34px}.checkout-account-banner{flex-direction:column;align-items:flex-start;padding:14px}.checkout-section,.order-summary,.auth-card,.card-lite{padding:18px}.payment-gateway-grid{grid-template-columns:1fr}.payment-gateway-btn{min-height:76px}.checkout-payment-copy{margin-bottom:12px}.auth-shell{grid-template-columns:1fr}.auth-tabs{gap:8px}.auth-tab{padding:11px 12px}.account-actions{grid-template-columns:1fr}.footer-grid{grid-template-columns:1fr}}
@media(max-width:480px){.checkout-section-head{flex-direction:column;align-items:flex-start}.checkout-account-banner .btn{width:100%}.form-group{margin-bottom:12px}.payment-buttons .btn,.payment-gateway-btn{padding:13px 14px}.order-item{grid-template-columns:40px 1fr auto}.auth-card,.card-lite,.order-summary{border-radius:18px}.page-header h1{font-size:1.7rem}}

@media(max-width:768px){.price-range{grid-template-columns:1fr}.price-range .btn{grid-column:auto;width:100%}.hero-media{min-height:260px;width:100%;padding:12px}.hero-visual-image{min-height:260px}.social-auth-grid{grid-template-columns:1fr}}
@media(max-width:480px){.hero-media{min-height:220px;border-radius:24px}.hero-visual-image{min-height:220px}}

@media(max-width:768px){.checkout-account-banner>*{max-width:100%}.account-link{max-width:44px;padding:0}.account-link span{display:none}}
/* NOVATVHUB HOMEPAGE MOBILE BESTSELLERS FIX */
@media (max-width: 768px) {
  #productsGrid.products-grid {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    grid-auto-flow: row !important;
    gap: 12px !important;
    width: 100% !important;
    max-width: 100% !important;
    overflow: visible !important;
  }

  #productsGrid.products-grid > .product-card {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    margin: 0 !important;
  }
}

@media (max-width: 480px) {
  #productsGrid.products-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 10px !important;
  }
}



/* NOVATVHUB HOMEPAGE MOBILE SECTION FIXES */
@media (max-width: 1024px) {
  body[data-page="home"] .hero-grid {
    grid-template-columns: 1fr !important;
    gap: 24px !important;
  }

  body[data-page="home"] .hero-card {
    margin-top: 24px !important;
  }

  body[data-page="home"] .hero-media {
    width: 100% !important;
    min-height: 260px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
  }

  body[data-page="home"] .phone-mockup {
    width: min(240px, 72vw) !important;
    height: min(480px, 140vw) !important;
    max-width: 100% !important;
  }

  body[data-page="home"] .category-grid {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 12px !important;
    width: 100% !important;
    max-width: 100% !important;
  }

  body[data-page="home"] .category-grid > .category-card {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    margin: 0 !important;
  }

  body[data-page="home"] .trust-grid {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 12px !important;
    width: 100% !important;
    max-width: 100% !important;
  }

  body[data-page="home"] .trust-grid > div {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    margin: 0 !important;
  }
}

@media (max-width: 480px) {
  body[data-page="home"] .trust-grid {
    grid-template-columns: 1fr !important;
  }

  body[data-page="home"] .category-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 10px !important;
  }

  body[data-page="home"] .phone-mockup {
    width: min(220px, 76vw) !important;
    height: min(420px, 148vw) !important;
    border-radius: 34px !important;
  }

  body[data-page="home"] .magsafe-ring {
    width: 96px !important;
    height: 96px !important;
  }
}
