html, body {
  overflow-x: hidden;  /* horizontal scroll বন্ধ */
  overflow-y: auto;    /* vertical scroll সবসময় চালু */
  height: auto;        /* height fix না, auto */
}
/* ===== Fixed header + hero space ===== */
:root { --knit-top-offset: 140px; }
@media (max-width: 768px){
  :root { --knit-top-offset: 160px; }
}

/* ===== Page background + base font ===== */
.knit-page {
  font-family: 'Poppins', system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  background-color: #ffffff;
  color: #FFA500;
}

/* ===== HERO ===== */
.knit-page .hero {
  margin-top: 10px;
  display: flex;
  justify-content: center;
  margin-bottom: 5px;
}
.knit-page .hero img {
  max-width: calc(100% - 120px);
  height: auto;
  object-fit: contain;
  display: block;
}
@media (max-width: 992px) {
  .knit-page .hero img { max-width: calc(100% - 60px); }
}
@media (max-width: 600px) {
  .knit-page .hero img { max-width: 100%; }
}

/* ===== Main container ===== */
.knit-page .main-container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 16px 16px 44px;
}
.knit-page .main-section {
  background: #ffffff;
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 14px 50px rgba(255, 165, 0, 0.9);
}

/* ===== Headings & text ===== */
.section-title {
  font-size: 26px;
  font-weight: 700;
  text-align: center;
  color: #FFA500;
  margin: 16px 0 20px 0;
}
.section-text {
  font-size: 16px;
  line-height: 1.7;
  color: #FFA500;
  margin: 0 0 20px 0;
}

/* ===== Knit Grid (5 boxes) ===== */
.knit-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin: 30px 0;
}
.knit-box {
  background: #ffffff;
  border-radius: 12px;
  padding: 20px;
  box-shadow: 0 8px 30px rgba(255, 165, 0, 0.6);
  color: #FFA500;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

/* শেষ বক্সের জন্য আলাদা ক্লাস */
.knit-box.last {
  grid-column: 1 / span 2;   /* পুরো প্রস্থে */
  text-align: left;          /* টেক্সট বামদিকে */
}
.knit-box.last .box-title {
  text-align: left;          /* শিরোনামও বামদিকে */
}

/* Responsive হলে */
@media (max-width: 768px) {
  .knit-box.last {
    grid-column: auto;
  }
}

.knit-box:hover {
  transform: scale(1.03);
  box-shadow: 0 12px 40px rgba(255,165,0,0.8);
}
.knit-box .box-title {
  text-align: center;
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 12px;
}
.knit-box p {
  font-size: 16px;
  line-height: 1.6;
}
.knit-box.center {
  grid-column: 1 / span 2;
  text-align: center;
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
  .knit-grid {
    grid-template-columns: 1fr;
  }
  .knit-box.center {
    grid-column: auto;
  }
}

/* ===== Tray Button ===== */
.tray-toggle-vertical {
  position: fixed;
  left: 0;
  top: 40%;
  transform: translateY(-50%) rotate(180deg);
  background: #FFA500;
  color: #ffffff;
  padding: 10px 5px;
  min-height: 140px;
  border-radius: 12px 0 0 12px;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  z-index: 1100;
  writing-mode: vertical-rl;
  text-orientation: mixed;
  border: 3px solid #FFA500;
  box-shadow: 0 0 22px 8px rgba(255,165,0,0.45);
}
.tray-toggle-vertical:hover {
  transform: translateY(-50%) rotate(180deg) scale(1.05);
}

/* ===== Product Gallery Overlay ===== */
#productGallery {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #ffffff;
  z-index: 12000;   /* overlay always on top */
  display: none;
  overflow-y: auto;
  padding: 60px 20px 40px;
  box-sizing: border-box;
  text-align: center;
}

/* Body lock */
body.no-scroll {
  overflow: hidden;
  position: fixed;
  width: 100%;
}

/* Close Button */
#closeGallery {
  position: absolute;
  top: 20px;
  right: 30px;
  background: #FFA500;
  border: none;
  font-size: 32px;
  font-weight: bold;
  color: #ffffff;
  cursor: pointer;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  line-height: 40px;
  text-align: center;
  z-index: 12001;
}

/* Gallery Grid */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 22px;
  max-width: 1200px;
  margin: 0 auto;
  padding-bottom: 40px;
}
.product-box {
  background: #ffffff;
  padding: 16px;
  border-radius: 10px;
  box-shadow: 0 6px 20px rgba(255,165,0,0.6);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.product-box img {
  width: 100%;
  height: 180px;
  object-fit: contain;
  border-radius: 8px;
  margin-bottom: 12px;
}
.details-btn {
  background: #FFA500;
  color: #ffffff;
  border: none;
  padding: 8px 12px;
  font-weight: bold;
  cursor: pointer;
  border-radius: 6px;
  transition: 0.25s;
  margin-top: auto; /* 🔼 button stays at bottom */
}
.details-btn:hover {
  background: #ffb733;
}
/* ===== Product Details Modal ===== */
.details-modal {
  display: none;
  position: fixed;
  z-index: 13000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0,0,0,0.6);
}

.details-content {
  background-color: #ffffff;
  margin: 10% auto;
  padding: 20px;
  border: 2px solid #FFA500;
  border-radius: 10px;
  width: 80%;
  max-width: 500px;
  color: #FFA500;
  box-shadow: 0 8px 25px rgba(0,0,0,0.6);
  text-align: center;
}

#closeDetails {
  color: #FFA500;
  float: right;
  font-size: 28px;
  font-weight: bold;
  cursor: pointer;
}

#closeDetails:hover {
  color: #ffb733;
}
