/* Production UI polish layer. Loaded last to refine the legacy template safely. */
:root {
  --ui-ink: #243142;
  --ui-muted: #6d7480;
  --ui-line: #e7e9ed;
  --ui-soft: #f7f8fa;
  --ui-accent: #ffb300;
  --ui-danger: #e53935;
  --ui-shadow: 0 14px 34px rgba(36, 49, 66, .12);
}

html {
  scroll-behavior: smooth;
}

body {
  color: var(--ui-ink);
  background: #fff;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

a,
button,
.btn,
input,
textarea,
select {
  transition: color .2s ease, background-color .2s ease, border-color .2s ease, box-shadow .2s ease, transform .2s ease, opacity .2s ease;
}

a:focus,
button:focus,
.btn:focus,
input:focus,
textarea:focus,
select:focus {
  outline: 0;
  box-shadow: 0 0 0 3px rgba(255, 225, 21, .38);
}

.btn {
  border-radius: 4px;
  font-weight: 700;
  letter-spacing: 1px;
}

.btn:hover {
  transform: translateY(-1px);
}

header {
  background: #fff;
  box-shadow: 0 1px 0 rgba(36, 49, 66, .08);
}

header .sticky {
  background: rgba(255, 255, 255, .97);
  backdrop-filter: saturate(180%) blur(10px);
}

header .logo img {
  max-height: 48px;
  object-fit: contain;
}

header .navbar li a {
  color: var(--ui-ink);
  font-weight: 700;
}

header .navbar li.active > a,
header .navbar li a:hover {
  color: #111;
}

.nav-right i {
  color: var(--ui-ink);
}

.nav-right .navbar-right > li > a {
  min-width: 38px;
  height: 38px;
  line-height: 38px;
  text-align: center;
  border-radius: 50%;
}

.nav-right .navbar-right > li > a:hover {
  background: var(--ui-soft);
}

header .dropdown-menu {
  border: 1px solid var(--ui-line);
  border-radius: 6px;
  box-shadow: var(--ui-shadow);
}

.sub-bnr {
  position: relative;
  overflow: hidden;
}

.sub-bnr:before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(20, 28, 38, .72), rgba(20, 28, 38, .42));
}

.sub-bnr .position-center-center {
  z-index: 1;
}

.sub-bnr h4 {
  color: #fff;
  letter-spacing: 4px;
  text-shadow: 0 2px 14px rgba(0, 0, 0, .28);
}

.sub-bnr p {
  color: rgba(255, 255, 255, .92);
  font-weight: 500;
  text-shadow: 0 1px 10px rgba(0, 0, 0, .32);
}

.sub-bnr .breadcrumb li,
.sub-bnr .breadcrumb li a,
.sub-bnr .breadcrumb > .active {
  color: rgba(255, 255, 255, .88);
}

.sub-bnr .breadcrumb li a:hover {
  color: var(--ui-accent);
}

.heading h4 {
  color: var(--ui-ink);
}

.heading span,
.papular-block .item-name p,
footer p {
  color: var(--ui-muted);
  line-height: 1.75;
}

.papular-block {
  display: flex;
  flex-wrap: wrap;
}

.papular-block > [class*="col-"] {
  display: flex;
  margin-bottom: 34px;
}

.papular-block .item {
  position: relative;
  width: 100%;
  padding-bottom: 22px;
  background: #fff;
  border: 1px solid transparent;
  border-radius: 6px;
  overflow: hidden;
}

.papular-block .item:hover {
  border-color: var(--ui-line);
  box-shadow: 0 18px 42px rgba(36, 49, 66, .16);
  transform: translateY(-4px);
}

.papular-block .item-img {
  background: var(--ui-soft);
}

.papular-block .item-img img {
  display: block;
}

.papular-block .overlay {
  background: linear-gradient(180deg, rgba(24, 32, 43, .18), rgba(24, 32, 43, .84));
}

.papular-block .overlay .inn {
  display: inline-flex;
  gap: 10px;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 0 18px;
}

.product-action-form {
  display: inline-flex;
  margin: 0;
}

.papular-block .overlay .inn .product-action {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  padding: 0;
  border: 0;
  background: #fff;
  color: var(--ui-ink) !important;
  border-radius: 50%;
  box-shadow: 0 8px 20px rgba(0, 0, 0, .18);
  cursor: pointer;
}

.papular-block .overlay .inn .product-action:hover {
  background: #e91e63 !important;
  color: #fff !important;
  transform: translateY(-3px);
}

.papular-block .overlay .inn .product-action:after {
  content: attr(data-tooltip);
  position: absolute;
  left: 50%;
  top: calc(100% + 9px);
  min-width: 82px;
  padding: 6px 8px;
  background: #111820;
  color: #fff;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: .6px;
  text-align: center;
  text-transform: uppercase;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transform: translateX(-50%) translateY(-3px);
}

.papular-block .overlay .inn .product-action:hover:after,
.papular-block .overlay .inn .product-action:focus:after {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.papular-block .item-name {
  min-height: 112px;
  padding: 24px 20px 0;
}

.papular-block .item-name a {
  display: block;
  color: var(--ui-ink);
  line-height: 1.4;
  margin-bottom: 8px;
}

.papular-block .item-name p {
  display: -webkit-box;
  min-height: 42px;
  margin-bottom: 0;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.papular-block .price {
  display: block;
  padding: 0 20px;
  color: #111;
  font-size: 16px;
  font-weight: 700;
}

.new-tag,
.best-tag,
.on-sale {
  pointer-events: none;
}

.shop-filter-panel,
.item-display,
.shopping-cart .cart-ship-info,
.payment-method,
.order-place {
  border-radius: 6px;
  box-shadow: 0 8px 24px rgba(36, 49, 66, .06);
}

.shop-page .item-display {
  padding: 18px 20px;
  margin-bottom: 30px;
  background: #fff;
  border: 1px solid var(--ui-line);
}

.shop-page .item-display .row {
  display: flex;
  align-items: center;
}

.shop-page .product-num {
  display: block;
  color: var(--ui-ink);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .8px;
  text-transform: uppercase;
}

.shop-filter-panel .filter-search,
.shopping-cart input,
.shopping-cart textarea,
.news-letter form input,
#contact_form input,
#contact_form textarea {
  border-color: var(--ui-line) !important;
  border-radius: 4px;
}

.shop-filter-panel .filter-search:focus,
.shopping-cart input:focus,
.shopping-cart textarea:focus,
.news-letter form input:focus,
#contact_form input:focus,
#contact_form textarea:focus {
  border-color: var(--ui-ink) !important;
}

.pagination li a {
  border-radius: 4px;
  margin: 0 3px;
}

.pagination li.active a,
.pagination li a:hover {
  background: var(--ui-ink);
  border-color: var(--ui-ink);
  color: #fff;
}

.shopping-cart .cart-details {
  background: #fff;
}

.qty-stepper {
  border-radius: 4px;
  overflow: hidden;
}

.news-letter {
  background: #202a36;
}

.news-letter form {
  display: flex;
  max-width: 640px;
  gap: 10px;
}

.news-letter form input {
  float: none;
  width: 100%;
  background: #fff;
}

.news-letter form button {
  flex: 0 0 150px;
  float: none;
  border-radius: 4px;
}

footer {
  background: #151b24;
}

footer h6 {
  color: #fff;
}

footer li a {
  color: #c8ced6;
}

footer li a:hover {
  color: var(--ui-accent);
  padding-left: 4px;
}

footer .rights {
  border-top: 1px solid rgba(255, 255, 255, .08);
  margin-top: 34px;
  padding-top: 24px;
}

footer .scroll a {
  border-radius: 50%;
  background: var(--ui-accent);
  color: var(--ui-ink);
}

@media (min-width: 992px) {
  .shop-page .papular-block .col-md-3 {
    width: 33.333333%;
  }
}

@media (max-width: 991px) {
  .padding-top-100 {
    padding-top: 72px !important;
  }

  .padding-bottom-100 {
    padding-bottom: 72px !important;
  }

  .papular-block .item-name {
    min-height: 94px;
  }
}

@media (max-width: 767px) {
  header {
    padding: 0;
  }

  header .logo {
    min-height: 62px;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .nav-right {
    top: 12px;
  }

  .navbar-toggle {
    top: 12px;
  }

  header .navbar .nav {
    max-height: calc(100vh - 120px);
    margin-top: 8px;
    background: #fff;
    border-top: 1px solid var(--ui-line);
    overflow-y: auto;
  }

  header .navbar .nav li a {
    padding: 14px 0;
  }

  .sub-bnr {
    min-height: 280px;
  }

  .sub-bnr h4 {
    font-size: 28px;
    letter-spacing: 2px;
  }

  .sub-bnr p {
    width: 100%;
    padding: 0 18px;
  }

  .news-letter {
    padding-top: 80px !important;
    padding-bottom: 80px !important;
  }

  .news-letter form {
    display: block;
  }

  .news-letter form button {
    width: 100%;
    margin-top: 10px;
  }

  footer .col-md-3 {
    margin-bottom: 24px;
  }
}

@media (max-width: 480px) {
  .papular-block > [class*="col-"] {
    padding-left: 8px;
    padding-right: 8px;
  }

  .papular-block .overlay .inn a,
  .papular-block .overlay .inn button {
    width: 38px;
    height: 38px;
  }

  .btn,
  .btn-small {
    white-space: normal;
  }
}

/* Fixes for Shop Details Readability */
.shop-detail .item-owner li span {
  color: var(--ui-ink) !important;
  font-weight: 600;
}


/* Responsive fixes */
img { max-width: 100%; height: auto; }

/* =========================================
   Mobile Responsiveness & App-Like UI Polish
========================================= */

/* 1. Cart & Wishlist Responsive Table Fix */
@media (max-width: 767px) {
  /* Hide the desktop headers */
  .cart-head {
    display: none !important;
  }
  
  /* Make each row a mobile card */
  .cart-details {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    background: #fff;
    border: 1px solid #eaeaec;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 15px;
    position: relative;
    box-shadow: 0 2px 10px rgba(0,0,0,0.02);
  }
  
  /* Reset col stacking */
  .cart-details li {
    width: 100% !important;
    padding: 5px 0 !important;
    border: none !important;
    text-align: left !important;
  }
  
  .cart-details li .media {
    display: flex;
    align-items: center;
    gap: 15px;
  }
  
  .cart-details li .media-left {
    padding-right: 0;
  }
  
  .cart-details li .item-img {
    width: 80px;
    height: 80px;
    border-radius: 8px;
    overflow: hidden;
  }
  
  /* Price, Qty, Total inline layout */
  .cart-details li.col-sm-2, 
  .cart-details li.col-sm-1 {
    display: flex;
    align-items: center;
    justify-content: space-between;
  }
  
  /* Add labels before values */
  .cart-details li:nth-child(2):before { content: "Price: "; font-weight: bold; font-size: 13px; color: #888; }
  
  
  
  .cart-details li .position-center-center {
    position: relative !important;
    top: auto !important;
    left: auto !important;
    transform: none !important;
    width: auto !important;
    text-align: right;
  }
  
  /* Delete Button - Absolute top right */
  .cart-details li:last-child {
    position: absolute !important;
    top: 15px;
    right: 15px;
    width: auto !important;
    padding: 0 !important;
  }
  
  .cart-details li:last-child button,
  .cart-details li:last-child form button {
    font-size: 20px !important;
    color: #e91e63 !important;
    background: #ffebee !important;
    border-radius: 50%;
    padding: 5px;
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
  }
}

/* 2. Mobile App Bottom Navigation Bar */
.mobile-bottom-nav {
  display: none;
}

@media (max-width: 767px) {
  /* Ensure body doesn't get covered by nav */
  body {
    padding-bottom: 70px;
  }

  .mobile-bottom-nav {
    display: flex;
    justify-content: space-around;
    align-items: center;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 65px;
    background: #ffffff;
    box-shadow: 0 -4px 12px rgba(0,0,0,0.08);
    z-index: 9999;
    border-top-left-radius: 15px;
    border-top-right-radius: 15px;
  }

  .mobile-bottom-nav a {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--ui-ink);
    text-decoration: none;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    transition: all 0.3s ease;
  }

  .mobile-bottom-nav a i {
    font-size: 22px;
    margin-bottom: 4px;
    transition: all 0.3s ease;
  }

  .mobile-bottom-nav a:hover,
  .mobile-bottom-nav a.active {
    color: var(--ui-accent);
  }
  
  .mobile-bottom-nav a.active i {
    transform: translateY(-2px);
  }
  
  /* Highlight the cart icon */
  .mobile-bottom-nav a.nav-cart-btn {
    position: relative;
    top: -15px;
    background: var(--ui-accent);
    color: #fff;
    width: 55px;
    height: 55px;
    border-radius: 50%;
    border: 4px solid #fff;
    box-shadow: 0 4px 10px rgba(255, 179, 0, 0.4);
    font-size: 0; /* hide text */
    justify-content: center;
  }
  .mobile-bottom-nav a.nav-cart-btn i {
    font-size: 24px;
    margin: 0;
  }
  .mobile-bottom-nav a.nav-cart-btn:hover {
    color: #fff;
    transform: scale(1.05);
  }
}

@media (max-width: 767px) { .cart-details[data-cart-row] li:nth-child(3):before { content: 'Qty: '; font-weight: bold; font-size: 13px; color: #888; }
.cart-details[data-cart-row] li:nth-child(4):before { content: 'Total: '; font-weight: bold; font-size: 13px; color: #888; }

.cart-details:not([data-cart-row]) li:nth-child(3):before { content: 'Stock: '; font-weight: bold; font-size: 13px; color: #888; } }


/* Fix dark button text contrast */
.btn-dark { color: #ffffff !important; }
.shopping-cart .btn-dark { color: #ffffff !important; }









@media (max-width: 767px) {
  /* Final Perfect Mobile Header Layout using Flexbox */
  header .container {
    display: flex !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    justify-content: space-between !important;
    padding: 10px 15px !important;
    height: auto !important; /* Allow expanding for menu */
    position: relative !important;
  }

  header .logo {
    position: static !important;
    transform: none !important;
    margin: 0 !important;
    padding: 0 !important;
    flex: 0 0 auto !important;
    z-index: 10;
  }
  
  header .logo img {
    max-height: 30px !important;
    width: auto !important;
  }

  header .navbar.ownmenu {
    position: static !important;
    margin: 0 !important;
    padding: 0 !important;
    flex: 1 1 auto !important;
    display: flex !important;
    flex-wrap: wrap !important;
    justify-content: flex-end !important;
    align-items: center !important;
  }

  /* Icons: User, Cart, Search */
  .nav-right {
    position: static !important;
    transform: none !important;
    margin: 0 15px 0 0 !important;
    order: 1 !important; /* Place before hamburger */
    display: flex !important;
    align-items: center !important;
    z-index: 20;
  }

  .nav-right .navbar-right {
    display: flex !important;
    align-items: center !important;
    gap: 15px;
    margin: 0 !important;
    padding: 0 !important;
  }

  .nav-right .navbar-right > li {
    float: none !important;
    margin: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
  }

  .nav-right .navbar-right > li > a {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    line-height: 1 !important;
    padding: 0 !important;
    margin: 0 !important;
  }

  .nav-right .navbar-right > li > a i {
    line-height: 1 !important;
    margin: 0 !important;
    padding: 0 !important;
    font-size: 18px !important;
  }

  .nav-right {
    position: static !important;
  }
  .nav-right .navbar-right > li {
    position: static !important; /* Allow dropdown to be absolute to container */
  }
  .nav-right .dropdown-menu {
    position: absolute !important;
    left: 15px !important;
    right: 15px !important;
    width: auto !important;
    top: 60px !important;
    min-width: 0 !important;
    margin: 0 !important;
    z-index: 1000 !important;
  }

  /* Hamburger Menu */
  .navbar-header {
    position: static !important;
    transform: none !important;
    margin: 0 !important;
    order: 2 !important; /* Place after icons */
    z-index: 20;
    display: flex !important;
    align-items: center;
  }

  .navbar-toggle {
    margin: 0 !important;
    padding: 8px 10px !important;
    position: static !important;
    float: none !important;
    display: block !important;
  }

  /* The actual Dropdown Menu that opens when clicking Hamburger */
  .collapse.navbar-collapse,
  .navbar-collapse.collapse.in {
    order: 3 !important; /* Place below everything */
    flex: 0 0 100% !important;
    width: 100% !important;
    margin-top: 15px !important; /* Space between header and menu */
    background: #fff;
    z-index: 15;
    position: static !important;
  }
}

