/* layout.css — layout, header, hero, banner, products grid, story and responsive rules */

/* ===== Header ===== */
header {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding-top: 10px;
}

header img {
  height: 35px;
  display: block;
  margin-top: 20px;
}

/* ===== Hero ===== */
.hero {
  max-width: 1260px;
  margin: 0 auto;
  padding: 20px 16px 30px;
  text-align: center;
}

.hero-image {
  width: 100%;
  max-height: 420px;
  object-fit: cover;
  border-radius: 20px;
  margin-bottom: 20px;
}

.hero h1 {
  font-size: 32px;
  margin-bottom: 12px;
  font-weight: 500;
  color: #222222;
}

.hero-text {
  font-size: 16px;
  color: #666;
  margin-bottom: 20px;
}

/* ===== MARQUEE (side-to-side) ===== */
.banner {
  position: relative;
  width: 100vw;
  margin-left: calc(-50vw + 50%);
  background: #d7b98a;
  overflow: hidden;
  /* min-height: 70vh;        */
  padding-top: 10px;      
  padding-bottom: 10px;
}

.marquee {
  width: 100%;
  overflow: hidden;
}

.marquee-track {
  display: inline-flex;
  width: max-content;
  animation: marquee-loop 20s linear infinite;
  will-change: transform;
  animation-delay: 0s;
  backface-visibility: hidden;
  perspective: 1000px;
}

.marquee-group {
  display: flex;
  align-items: center;
  gap: 80px;
  padding: 16px 0;
  margin-inline-end: 80px;
}

.marquee-group span {
  white-space: nowrap;
  color: #fff;
  font-family: 'Newsreader', serif;
  font-style: italic;
  font-size: 18px;
  font-weight: 500;
  letter-spacing: 0.5px;
}

/* loop from 0 → -50% so the duplicated second half aligns seamlessly */
@keyframes marquee-loop {
  0% { transform: translateX(0%); }
  100% { transform: translateX(-50%); }
}

@media (prefers-reduced-motion: reduce) {
  .marquee-track { animation: none; }
}

/* ===== Products ===== */
.products {
  max-width: 1260px;
  margin: 0 auto;
  padding: 30px 16px;
}

.products h2 {
  font-size: 26px;
  margin-bottom: 30px;
  font-weight: 400;
  color: #222222;
}

/* Product card scroll animation */
@keyframes slideUp {
  0% {
    opacity: 0;
    transform: translateY(40px) scale(0.96);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.scroll-animate {
  opacity: 0;
  animation: slideUp 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  will-change: transform, opacity;
}

.scroll-animate:nth-child(1) { animation-delay: 0s; }
.scroll-animate:nth-child(2) { animation-delay: 0.2s; }
.scroll-animate:nth-child(3) { animation-delay: 0.4s; }
.scroll-animate:nth-child(4) { animation-delay: 0.6s; }
.scroll-animate:nth-child(5) { animation-delay: 0.8s; }
.scroll-animate:nth-child(6) { animation-delay: 1.0s; }
.scroll-animate:nth-child(7) { animation-delay: 1.2s; }
.scroll-animate:nth-child(8) { animation-delay: 1.4s; }
.scroll-animate:nth-child(9) { animation-delay: 1.6s; }
.scroll-animate:nth-child(10) { animation-delay: 1.8s; }
.scroll-animate:nth-child(11) { animation-delay: 2.0s; }
.scroll-animate:nth-child(12) { animation-delay: 2.2s; }
.scroll-animate:nth-child(13) { animation-delay: 2.4s; }
.scroll-animate:nth-child(14) { animation-delay: 2.6s; }
.scroll-animate:nth-child(15) { animation-delay: 2.8s; }
.scroll-animate:nth-child(16) { animation-delay: 3.0s; }

@media (prefers-reduced-motion: reduce) {
  .scroll-animate {
    animation: none;
    opacity: 1;
    transform: none;
  }
}

/* ===== Product Grid ===== */
.product-grid {
  display: grid;
  gap: 16px;
}

/* Mobile (default) → 2 items */
.product-grid {
  grid-template-columns: repeat(2, 1fr);
}

/* Tablet → 3 items */
@media (min-width: 768px) {
  .product-grid { grid-template-columns: repeat(3, 1fr); }

  /* Hero split at tablet and up: side-by-side like desktop */
  .hero {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 64px;
    text-align: left;
  }

  /* reset any fixed max-heights so the square frame controls size */
  .hero-image { margin-bottom: 0; max-height: none; }

  /* square frame via padding-bottom and absolutely-positioned image */
  .hero picture {
    width: 100%;
    position: relative;
    overflow: hidden;
    display: block;
    border-radius: 20px;
    height: 0;
    padding-bottom: 100%;
  }

  .hero picture img.hero-image {
    position: absolute;
    top: -10%;
    left: 0;
    width: 100%;
    height: 120%;
    object-fit: cover;
    object-position: center;
    display: block;
    border-radius: 20px;
    will-change: transform;
  }

  .hero-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
  }

  .primary-btn { width: fit-content; min-width: 160px; }

}

/* Desktop → 4 items */
@media (min-width: 1024px) {
  .product-grid { grid-template-columns: repeat(4, 1fr); }

  /* Desktop: give header image a small bottom gap */
  header img { margin-bottom: 10px; }

  /* Hero split */
  .hero {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 64px;
    text-align: left;
    /* padding: 64px 16px; */
  }

  /* let the square picture frame determine image height */
  .hero-image { margin-bottom: 0; max-height: none; }

  .hero h1 { font-size: 36px; font-weight: 400; color: #222222; }

  .hero-text { font-size: 16px; max-width: 420px; }

  .primary-btn { width: fit-content; min-width: 160px; }

  /* Story split */
  .story {
    display: grid;
    grid-template-columns: 1fr 1fr;
    /* gap: 24px; */
    column-gap: 24px;
    align-items: center;
  }

  .story h2 { grid-column: 1 / -1;}

  .story-image { height: 320px; }

  .story p { font-size: 16px; }

  .banner span { font-size: 16px; }


}

/* ===== Story ===== */
.story {
  max-width: 1260px;
  margin: 0 auto;
  padding: 30px 16px 48px 16px;
}

.story h2 {
      font-size: 26px;
    font-weight: 400;
  margin-bottom: 20px;
}

.story-image {
  height: 240px;
  border-radius: 18px;
  border: 1px solid #ddd;
  margin-bottom: 24px;
}

.story h3 { font-size: 20px; margin-bottom: 8px; font-weight: 500; color: #222222; }

.story p { font-size: 15px; color: #666; max-width: 800px; margin-bottom: 16px; }

/* ===== Footer ===== */
.footer {
  text-align: center;
  padding: 32px 0;
  font-size: 13px;
  color: #888;
}

/* Mobile Styles */
@media (max-width: 767px) {
  header {
    padding-top: 0;
  }
}
