/* ============================================
   BuyBuyKart — Home Page Styles
   Only for: index.php (home / landing page)
   ============================================ */

/* ---------- Hero Section ---------- */
.hero {
  position: relative;
  overflow: hidden;
  min-height: 640px;
  display: flex;
  align-items: flex-end;
  padding: 80px 0 32px;
}

.hero-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 15%; /* Keep the top part (subject) visible */
  z-index: 0;
}

.hero-tint {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(260deg, rgba(20, 22, 46, 0.55) 0%, rgba(20, 22, 46, 0.28) 45%, rgba(20, 22, 46, 0.12) 70%);
}

.hero > .wrap {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 100%;
  display: flex;
  justify-content: flex-end;
  align-items: flex-end;
  padding-right: 12px;
}

/* ---------- Glassmorphism ---------- */
.glass {
  background: rgba(255, 255, 255, 0.55);
  backdrop-filter: blur(18px) saturate(160%);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  border: 1.5px solid rgba(255, 255, 255, 0.75);
  box-shadow: 0 20px 45px rgba(20, 22, 46, 0.14);
}

.hero-glass {
  max-width: 600px;
  padding: 44px;
  border-radius: 28px 0 0 28px;
}

.hero h1 {
  font-size: clamp(38px, 4.6vw, 62px);
  font-weight: 800;
  line-height: 1.05;
  margin: 18px 0 20px;
  background: linear-gradient(90deg, #14162E, #4A4C63);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero h1 em {
  font-style: normal;
  display: block;
  background: linear-gradient(135deg, var(--coral), #FF8A7C);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero p.lead {
  font-size: 17px;
  color: var(--ink-70);
  max-width: 440px;
  margin-bottom: 28px;
}

.cta-row {
  display: flex;
  gap: 12px;
  margin-top: 6px;
  flex-wrap: wrap;
}

@media (max-width: 700px) {
  .hero {
    min-height: 560px;
  }

  .hero-glass {
    padding: 28px;
    margin: 0 4px;
  }
}

/* ---------- Category Bento Grid ---------- */
.bento {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  grid-auto-rows: 150px;
  gap: 16px;
}

.cat-card {
  border-radius: var(--radius);
  padding: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  color: #fff;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0,0,0,0.06);
  border: 1px solid rgba(0,0,0,0.04);
}

.cat-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 15px 35px rgba(0,0,0,0.15);
}

.cat-card:hover .cat-img {
  transform: scale(1.08);
}

/* Product image inside category bento card */
.cat-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .4s ease;
}

/* Gradient overlay so text stays readable */
.cat-card > div:last-child {
  position: relative;
  z-index: 2;
  padding: 20px 24px;
  background: linear-gradient(to top, rgba(0,0,0,0.75) 0%, rgba(0,0,0,0.3) 60%, transparent 100%);
  width: 100%;
}

.cat-card .cname {
  font-weight: 700;
  font-size: 15px;
  color: #fff;
  text-shadow: 0 1px 3px rgba(0,0,0,0.3);
}

.cat-card .ccount {
  font-family: 'Space Mono', monospace;
  font-size: 11.5px;
  opacity: .8;
  color: #fff;
}

.c1 { grid-column: span 2; grid-row: span 2; background: #FFE3D3; }
.c2 { grid-column: span 2; grid-row: span 1; background: #DCF1EE; }
.c3 { grid-column: span 2; grid-row: span 1; background: #FFF1CE; }
.c4 { grid-column: span 2; grid-row: span 1; background: #E9E4FF; }
.c5 { grid-column: span 2; grid-row: span 2; background: #FFD9DD; }
.c6 { grid-column: span 2; grid-row: span 1; background: #D9EFFF; }
.c7 { grid-column: span 3; grid-row: span 1; background: #E4F3D4; }
.c8 { grid-column: span 3; grid-row: span 1; background: #F3E0F0; }

@media (max-width: 900px) {
  .bento {
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: 130px;
  }

  .c1, .c2, .c3, .c4, .c5, .c6, .c7, .c8 {
    grid-column: span 1;
    grid-row: span 1;
  }
}

/* ---------- Bestsellers Scroll Row ---------- */
.scroll-row {
  display: flex;
  gap: 20px;
  overflow-x: auto;
  padding-bottom: 20px; /* More space for shadow */
  scrollbar-width: none;
}

.scroll-row::-webkit-scrollbar {
  display: none;
}

@media (max-width: 700px) {
  .scroll-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    overflow-x: hidden;
  }
}

.prod-card {
  width: calc((100% - 80px) / 5);
  min-width: 220px;
  max-width: 280px;
  background: #fff;
  border: none;
  border-radius: var(--radius);
  box-shadow: 0 4px 15px rgba(0,0,0,0.04);
  overflow: hidden;
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

@media (max-width: 700px) {
  .prod-card {
    min-width: unset;
    max-width: none;
    width: 100%;
  }
}

.prod-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

.prod-thumb {
  height: 190px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

/* Product image inside bestseller card */
.prod-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .4s ease;
}

.prod-card:hover .prod-img {
  transform: scale(1.08);
}

.badge {
  position: absolute;
  top: 10px;
  left: 10px;
  background: var(--coral);
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  padding: 4px 10px;
  border-radius: 999px;
  font-family: 'Space Mono', monospace;
}

.prod-info {
  padding: 16px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.prod-info h4 {
  font-size: 14.5px;
  font-weight: 700;
  margin-bottom: 6px;
}

.price-row {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 12px;
}

.price-new {
  font-weight: 800;
  font-size: 16px;
}

.price-old {
  font-size: 12.5px;
  color: var(--ink-70);
  text-decoration: line-through;
}

.prod-info .btn {
  width: 100%;
  justify-content: center;
  padding: 11px;
  font-size: 13.5px;
  margin-top: auto;
}

/* ---------- Budget Stamps ---------- */
.budget-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.stamp {
  border: 2px dashed rgba(201, 194, 180, 0.8);
  border-radius: 28px;
  padding: 34px 20px;
  text-align: center;
  background: rgba(243, 238, 227, 0.4);
  backdrop-filter: blur(10px);
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.stamp:hover {
  transform: scale(1.05) rotate(-2deg);
  border-color: var(--coral);
  background: #fff;
  box-shadow: 0 15px 30px rgba(255, 99, 85, 0.15);
}

.stamp .under {
  font-family: 'Space Mono', monospace;
  font-size: 12px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-70);
}

.stamp .amt {
  font-family: 'Bricolage Grotesque', sans-serif;
  font-weight: 800;
  font-size: 32px;
  margin-top: 6px;
}

@media (max-width: 800px) {
  .budget-row {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ---------- How It Works Steps ---------- */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
  position: relative;
}

.step {
  padding: 40px 30px;
  position: relative;
  background: #fff;
  border-radius: 24px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.03);
  border: 1px solid rgba(0,0,0,0.02);
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  z-index: 1;
}

.step:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 40px rgba(20, 22, 46, 0.08);
  border-color: rgba(255, 99, 85, 0.2);
}

.step-num {
  font-family: 'Space Mono', monospace;
  font-weight: 700;
  font-size: 15px;
  color: #fff;
  background: linear-gradient(135deg, var(--coral), var(--coral-dark));
  border: none;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 24px;
  box-shadow: 0 8px 16px rgba(255, 99, 85, 0.3);
  transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.step:hover .step-num {
  transform: scale(1.15) rotate(10deg);
}

.step h3 {
  font-size: 20px;
  margin-bottom: 12px;
  transition: color 0.3s ease;
}

.step:hover h3 {
  color: var(--coral);
}

.step p {
  color: var(--ink-70);
  font-size: 14.5px;
  line-height: 1.6;
}

.steps::before {
  content: "";
  position: absolute;
  top: 62px;
  left: 15%;
  right: 15%;
  height: 3px;
  background: linear-gradient(90deg, transparent, rgba(255, 99, 85, 0.3), transparent);
  z-index: 0;
}

@media (max-width: 800px) {
  .steps {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .steps::before {
    display: none;
  }
}

/* ---------- Newsletter ---------- */
.newsletter {
  background: linear-gradient(135deg, var(--ink), #2A2D52);
  color: var(--paper);
  border-radius: 32px;
  padding: 56px 48px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 30px;
  flex-wrap: wrap;
  box-shadow: 0 20px 40px rgba(20, 22, 46, 0.2);
}

.newsletter h2 {
  font-size: 26px;
  margin-bottom: 6px;
}

.newsletter p {
  color: #B9BACB;
  font-size: 14.5px;
}

.newsletter form {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.newsletter input {
  padding: 13px 16px;
  border-radius: 999px;
  border: none;
  min-width: 240px;
  font-family: inherit;
}
