/* Reset and base styles */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: Arial, sans-serif;
  background-color: white;
}

/* Menu Bar */
.menu-bar {
  position: sticky;
  top: 0;
  height: 50px;
  background-color: blue;
  width: 100%;
  z-index: 1000;
}

/* Hero Section */
.hero {
  background-image: url('images/home-toppic.jpg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  height: 400px;
  color: white;
  display: flex;
  justify-content: center;
  padding: 0 20px;
}

/* Inner container stays max 1000px wide */
.hero-inner {
  width: 100%;
  max-width: 1000px;
  padding: 20px 0;
}

.hero-text-left {
  max-width: 50%;
  display: flex;
  flex-direction: column;
  height: 90%; /* full height of hero-inner */
}

.hero h1 {
  font-size: 2rem;
}

.hero p {
  padding-top:15px;
  line-height:25px;
  font-size: 1rem;
  text-align:justify;
}

.hero-quote {
  font-size: 1.2rem;
  text-align: left;
  margin-top: auto;        /* pushes quote to bottom of hero-text-left */
  padding-bottom: 10px;    /* small space from bottom */
}

/* Main container */
.main-container {
  max-width: 1000px;
  margin: auto;
  padding: 20px;
}

/* Section Titles */
.section h2 {
  margin-bottom: 10px;
  font-size: 1.5rem;
  text-align: left;
}

/* Container: center all boxes, allow wrapping */
.featured-items {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 20px;
}

.featured-box {
  display: flex;
  flex-direction: row;
  border: 1px solid #ccc;
  width: 100%;
  max-width: 469px;
  text-decoration: none;
  color: black;
  align-items: center;
  transition: background-color 0.3s ease, opacity 0.3s ease;
  background-color: white;
}

/* Image wrapper controls horizontal centering */
.featured-img {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 50%; /* take up half the box width */
}

/* Actual image */
.featured-img img {
  width: 200px;
  height: 200px;
  object-fit: none;
  display: block;
}

/* Text */
.featured-box p {
  flex: 1;
  padding: 20px;
  text-align: justify;
  font-size:12px;
}

/* Hover effect: opacity + light orange background */
.featured-box:hover {
  opacity: 0.75;
  background-color: #ffe5b4; /* light orange */
}


/* Divider */
hr {
  margin: 30px 0;
  border: 0.5px solid #ccc;
}

/* Grid Boxes */
.grid-boxes {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 20px;
}

/* Limit to max 4 columns on large screens */
@media (min-width: 1000px) {
  .grid-boxes {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* Product & Deal Box */
.product-box {
  border: 1px solid #ccc;
  padding: 10px;
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  height: 100%;
}

/* Product box image */
.product-box img {
  width: 200px;
  height: 200px;
  object-fit: none;
  object-position: top left;
  display: block;
  margin: 0 auto;
}

.product-box p {
  margin: 5px 0;
  text-align: left;
  text-align: justify;
  font-size:12px;
  flex-grow: 1;
}

.product-button {
  display: block;
  width: 100%;
  background-color: #333;  /* dark gray */
  color: #fff;             /* white text */
  text-align: center;
  padding: 12px 0;
  margin-top: 10px;
  text-decoration: none;
  font-weight: bold;
  border: none;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.product-button:hover {
  background-color: #555; /* slightly lighter on hover */
}

/* Reviews */
.reviews {
  height: 200px;
  background-color: gray;
  text-align: center;
  padding: 80px 0;
  color: white;
}


/* Responsive */

@media (max-width: 960px) {
  .featured-items {
    flex-direction: column;
    align-items: center;
  }

  .featured-box {
    flex-direction: row; /* still side-by-side unless under 469px */
  }
}


@media (max-width: 768px) {
  .hero-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .hero-text-left,
  .hero-quote {
    max-width: 100%;
    text-align: left;
  }


/* On screens = 469px: stack image on top */
@media (max-width: 469px) {
  .featured-box {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

 .featured-img {
    width: 100%;
    justify-content: center;
    margin-bottom: 10px;
  }

  .featured-box p {
    padding: 20px;
    text-align: justify;
    text-align-last: left;
    margin: 0 auto;
  }
  
  .featured-box img {
    margin: 0 auto;
  }

}