body{font-family:"Ruposhi Bangla","Noto Sans Bengali","Segoe UI",Tahoma,Arial,sans-serif}
.topbar, .site-header, footer{flex:0 0 auto}
html,body{height:100%}
body{min-height:100vh;display:flex;flex-direction:column}
.container.my-4{flex:1 0 auto}
main{flex:1 0 auto}
.section-title{border-left:4px solid #0d6efd;padding-left:8px}
header .navbar-brand{font-size:1.25rem}
.admin-layout{display:flex;min-height:100vh}
.admin-layout.right-sidebar{flex-direction:row-reverse}
.admin-sidebar{width:260px;background:#111827;color:#fff;transition:width .2s}
.admin-sidebar.compact{width:72px}
.admin-sidebar nav a{color:#e5e7eb;text-decoration:none;display:flex;align-items:center;gap:10px;padding:10px 12px;border-radius:6px}
.admin-sidebar nav a:hover{background:#374151;color:#fff}
.admin-sidebar nav a.active{background:#374151;color:#fff}
.admin-sidebar nav a .icon svg{width:20px;height:20px}
.admin-sidebar nav a .label{flex:none}
.admin-sidebar nav a .badge{margin-left:auto;background:#4b5563;color:#fff;border-radius:999px;padding:2px 8px;font-size:.75rem}
.admin-sidebar.compact nav a{justify-content:center}
.admin-sidebar.compact nav a .label,.admin-sidebar.compact nav a .badge{display:none}
.admin-topbar{background:#1f2937;color:#fff;padding:10px 14px;display:flex;justify-content:space-between;align-items:center}
.admin-content{flex:1;padding:16px}
.toggle-btn{cursor:pointer}
.card{position:relative}
.badge-ribbon{position:absolute;top:8px;left:8px}
.badge-stockout{position:absolute;top:8px;right:8px}
.badge-lowstock{position:absolute;bottom:8px;left:8px}
.minw-200{min-width:200px}
.banner-grid img{object-fit:cover}
.category-card{background:#f8fafc;transition:transform .15s ease, box-shadow .15s ease}
.category-card:hover{transform:translateY(-2px);box-shadow:0 4px 10px rgba(0,0,0,.08)}
.hero{min-height:380px;background-size:cover;background-position:center;position:relative}
.hero::after{content:"";position:absolute;inset:0;background:linear-gradient(180deg,rgba(0,0,0,.25),rgba(0,0,0,.35))}
.hero .hero-inner{position:relative;z-index:1;color:#fff}
.hero-title{font-size:2rem;font-weight:700}
.subcategory-card{position:relative;overflow:hidden;border-radius:.5rem}
.subcategory-card img{width:100%;height:160px;object-fit:cover;display:block}
.subcategory-card .overlay{position:absolute;inset:0;background:linear-gradient(180deg,rgba(0,0,0,.0),rgba(0,0,0,.45));display:flex;align-items:end;padding:.5rem;color:#fff;font-weight:600}
.section-head{display:flex;justify-content:space-between;align-items:center;margin-bottom:12px}
.section-head .view-all{font-size:.875rem}
.product-card img{height:220px;object-fit:cover}
.product-card{transition:transform .2s ease, box-shadow .2s ease}
.product-card:hover{transform:translateY(-3px);box-shadow:0 8px 24px rgba(0,0,0,.12)}
.product-meta{line-height:1.6}
.product-meta .label{color:#e31b23;font-weight:600}
.product-meta a{color:#e31b23;text-decoration:none}
.scroll-btn{position:absolute;top:40%;transform:translateY(-50%);z-index:2;border:none;background:#fff;border-radius:50%;width:36px;height:36px;box-shadow:0 2px 8px rgba(0,0,0,.15)}
.scroll-btn{transition:transform .2s ease}
.scroll-btn:hover{transform:translateY(-50%) scale(1.06)}
.scroll-btn.left{left:-10px}
.scroll-btn.right{right:-10px}
.price-row{display:flex;gap:.5rem;align-items:center}
.price-old{color:#d32; text-decoration:line-through}
.price-new{font-weight:700}
.btn-cart{border-color:#d32;color:#d32}
.btn-cart:hover{background:#d32;color:#fff}
.btn-cart{transition:transform .15s ease}
.btn-cart:hover{transform:translateY(-1px)}
.btn-buy{background:#e31b23;color:#fff;border-color:#e31b23}
.btn-buy:hover{background:#c71a20;color:#fff}
.badge-percent{position:absolute;top:8px;left:8px;font-size:.95rem;padding:.25rem .5rem;border-radius:.375rem}
.boxed-section{border:0;padding:0;background:transparent}
.boxed-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:12px;border:1px solid #dee2e6;border-radius:.5rem;padding:8px 12px;background:#fff}
.boxed-header{transition:box-shadow .2s ease}
.boxed-header:hover{box-shadow:0 6px 18px rgba(0,0,0,.08)}
.boxed-header .title{font-weight:600}
.boxed-header .more{font-size:.9rem;text-decoration:none}
.topbar{background:#f5f5f5;color:#333;font-size:.9rem}
.topbar .container{display:flex;gap:10px;justify-content:space-between;align-items:center}
.topbar .left, .topbar .right{display:flex;gap:16px;align-items:center}
.site-header{background:#fff;color:#222;border-bottom:1px solid #eee}
.site-header .container{display:flex;gap:12px;align-items:center;padding:.75rem 0}
.mobile-menu-toggle{display:none;border:1px solid #e6e6e6;background:#fff;border-radius:.375rem;padding:6px 10px}
.brand-logo{height:64px}
.navbar-brand{transition:opacity .2s ease}
.navbar-brand:hover{opacity:.9}
.search-box{flex:1;display:flex;align-items:center;border:2px solid #e31b23;border-radius:.5rem;overflow:hidden}
.search-box input{flex:1;border:0;outline:none;padding:.5rem .75rem}
.search-box .btn-search{background:#e31b23;color:#fff;border:0;padding:.5rem .9rem}
.header-icons{display:flex;gap:12px;align-items:center}
.header-icons a{color:#222;text-decoration:none;display:inline-flex;align-items:center;gap:6px}
.site-header{background:#fff;color:#222}
.site-header a{color:#222}
.nav-cats{display:flex;gap:12px;flex-wrap:wrap}
.nav-cat-item{position:relative}
.nav-cat-item>.link{display:inline-block;padding:6px 10px;border-radius:.375rem;background:rgba(255,255,255,.1)}
.nav-cat-item:hover>.link{background:rgba(255,255,255,.2)}
.nav-cat-item .dropdown{display:none;position:absolute;top:100%;left:0;background:#fff;color:#222;border:1px solid #dee2e6;border-radius:.5rem;min-width:220px;box-shadow:0 6px 24px rgba(0,0,0,.12);padding:6px}
.nav-cat-item:hover .dropdown{display:block}
.nav-cat-item .dropdown{z-index:2000}
.site-header{position:relative;z-index:1500}
.topbar{position:relative;z-index:1600}
.nav-cat-item .dropdown a{display:block;padding:6px 10px;border-radius:.375rem;text-decoration:none;color:#222}
.nav-cat-item .dropdown a:hover{background:#f5f7fb}
.header-links{display:flex;gap:10px;flex-wrap:wrap}
.header-links a{display:inline-flex;align-items:center;justify-content:center;padding:6px 12px;min-height:32px;min-width:120px;border-radius:.375rem;background:#fff;border:1px solid #e6e6e6;text-decoration:none;color:#222}
.header-links a{transition:transform .2s ease, box-shadow .2s ease}
.header-links a:hover{transform:translateY(-2px);box-shadow:0 6px 18px rgba(0,0,0,.12)}
.link-circle{display:flex;flex-direction:column;align-items:center;gap:6px;text-decoration:none;color:#222}
.link-circle{transition:transform .2s ease}
.link-circle:hover{transform:translateY(-2px)}
.link-circle .circle{width:64px;height:64px;border-radius:50%;border:1px solid #e6e6e6;background:#fff;background-size:cover;background-position:center}
.link-circle .label{font-size:.9rem}
.circle-grid{display:flex;flex-wrap:wrap;gap:16px}
.circle-lg{width:120px;height:120px;border-radius:50%;border:1px solid #e6e6e6;background:#fff;background-size:cover;background-position:center}
.nav-cat-item>.link{display:inline-flex;align-items:center;justify-content:center;padding:6px 12px;min-height:32px;min-width:120px;border-radius:.375rem;background:#fff;border:1px solid #e6e6e6;text-decoration:none;color:#222}
/* icons */
.btn-search svg{width:20px;height:20px}
.header-icons a svg{width:26px;height:26px}
.header-icons .cart-count{font-weight:600}
.btn-cart svg{width:16px;height:16px;margin-right:6px}
@media (max-width: 768px){
  .admin-layout{flex-direction:column}
  .admin-sidebar{width:100%}
  .admin-content{padding:12px}
.hero{min-height:auto}
.hero::after{display:none}
.hero-img{width:100%;height:auto;object-fit:contain}
  .benefits .container{justify-content:center !important}
  .benefits .flex-fill{justify-content:center}
  .hero-title{font-size:1.4rem}
  .product-card img{height:170px}
  .subcategory-card img{height:120px}
  .boxed-header{flex-direction:row;align-items:center;gap:6px}
  .mobile-menu-toggle{display:inline-flex;align-items:center;justify-content:center}
  .site-header .container{flex-wrap:wrap}
  .navbar-brand{order:1}
  .mobile-menu-toggle{order:2; margin-left:auto}
  .header-icons{order:3; width:100%; justify-content:flex-start}
  .search-box{order:4; width:100%; flex:0 0 100%}
  .header-links{display:flex;max-height:0;overflow:hidden;opacity:0;transition:max-height .25s ease, opacity .25s ease}
  .header-links.open{max-height:600px;opacity:1}
  .product-view-img{max-height:360px;object-fit:contain}
  .product-actions{flex-wrap:wrap}
  .product-actions .badge{margin-bottom:4px}
  .product-actions input[name=qty]{width:100% !important}
  .product-actions .btn{width:100%}
}
 
@media (min-width: 992px){
  .hero{min-height:460px}
  .hero-img{height:auto}
  .hero-title{font-size:2.4rem}
  .product-card img{height:240px}
}

/* horizontal scroll across devices */
.row.flex-nowrap.overflow-auto{scroll-snap-type:x proximity;overscroll-behavior-x:contain;-webkit-overflow-scrolling:touch}
.product-card{scroll-snap-align:start}