:root {
  --main-color: #2C3E50;     /* charcoal-blue */
  --hover-color: #663399;    /* purple for hover states */
  --bg-color: #FFFFFF;       /* pure white */
  --text-color: #333333;     /* dark gray */
  --container-width: 1000px;
  --header-height: 120px;    /* adjust this if your header grows/shrinks */
}

html {
  scroll-behavior: smooth;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: system-ui, sans-serif;
  background: var(--bg-color);
  color: var(--text-color);
  line-height: 1.6;
  overflow-x: hidden;
}

/* Hide off-screen via transform, reveal on focus */
.skip-link {
  position: absolute;
  top: 0;
  left: 0;
  transform: translateY(-100%);
  background: var(--main-color);
  color: #ffffff;         /* white text */
  padding: 8px 16px;
  z-index: 1001;
  transition: transform 0.3s ease;
}
.skip-link:focus {
  transform: translateY(0);
}

/***** HEADER & NAV *****/
header {
  background: #FFFFFF;
  border-bottom: 1px solid #E0E0E0;
  position: sticky;
  top: 0;
  z-index: 1000;
}

.nav-container {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 2px 20px;         /* top/bottom padding around header */
  display: flex;
  align-items: center;       /* vertically center logo + menu items */
  justify-content: space-between;
}

.logo img {
  height: 50px;              /* adjust as needed */
  display: block;
}

/* Hide the checkbox and hamburger icon by default (desktop) */
.menu-toggle,
.menu-icon {
  display: none;
}

nav ul {
  list-style: none;
  display: flex;
  align-items: center;       /* vertically center links */
  gap: 25px;
  margin-top: 30px;          /* push the menu down slightly on desktop */
}

nav a {
  text-decoration: none;
  color: var(--text-color);
  font-weight: 500;
  padding: 8px 0;            /* vertical padding for tap targets */
  transition: color 0.2s ease;
  font-size: 1rem;
}

nav a:hover {
  color: var(--hover-color);
}

/***** ENSURE LINKS DON’T GET HIDDEN BEHIND HEADER *****/
section {
  scroll-margin-top: var(--header-height);
}

/***** MAIN CONTENT *****/
main {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 50px 20px;
}

h1.section-title {
  font-size: 2rem;
  margin-bottom: 25px;
  color: var(--main-color);
  text-align: center;
}

h2 {
  margin-top: 60px;
  border-bottom: 2px solid #E0E0E0;
  padding-bottom: 8px;
  font-size: 1.6rem;
  color: var(--main-color);
}

h3 {
  margin-top: 30px;
  font-size: 1.2rem;
  color: var(--main-color);
}

p, ul {
  margin-top: 12px;
  margin-bottom: 20px;
  font-size: 1rem;
  line-height: 1.7;
}

ul {
  padding-left: 25px;
}

ul li {
  margin-bottom: 10px;
}

/***** FLOAT-BASED IMAGES *****/
.side-image-right {
  float: right;
  width: 30%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  margin-left: 20px;
  border-radius: 6px;
}

.side-image-left {
  float: left;
  width: 30%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  margin-right: 20px;
  border-radius: 6px;
}

/* Clearfix helper so floats don’t overlap following sections */
.clearfix::after {
  content: "";
  display: table;
  clear: both;
}

/* SHARE SECTION */
#share {
  text-align: center;
}

/* SHARE BUTTONS CONTAINER */
.share-buttons {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;   /* center buttons horizontally */
  gap: 12px;
  margin: 16px auto;         /* auto left/right for centering */
}

/* BASE BUTTON STYLES */
.share-button {
  display: inline-block;
  padding: 10px 16px;
  font-size: 0.95rem;
  font-weight: 500;
  color: #ffffff;              /* ← now white */
  text-decoration: none;
  border-radius: 4px;
  transition: opacity 0.2s ease;
}

/* HOVER STATE */
.share-button:hover {
  opacity: 0.85;
}

/* Recommended Products Grid */
#recommended {
  margin-top: 60px;
}
#recommended h2 {
  border-bottom: 2px solid #E0E0E0;
  padding-bottom: 8px;
  color: var(--main-color);
  font-size: 1.6rem;
  margin-bottom: 20px;
}
.product-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}
.product {
  flex: 1 1 calc(20% - 20px);
  box-sizing: border-box;
  text-align: center;
}
.product img {
  width: 100%;               /* fill the product column */
  aspect-ratio: 1 / 1;       /* enforce a square container */
  object-fit: contain;       /* letterbox the image inside */
  background-color: #fff;    /* white “padding” around */
  border-radius: 6px;        /* keep your rounded corners */
}
.product h3 {
  margin-top: 10px;
  font-size: 1rem;
  color: var(--text-color);
}
.product a {
  text-decoration: none;
  color: inherit;
  transition: transform 0.2s ease;
}

/* Amazon button styling (inline, compact) */
.product .amazon-button {
  display: inline-block;
  margin: 8px 0;
  padding: 6px 10px;
  font-size: 0.85rem;
  font-weight: 600;
  background: #FF9900;      /* Amazon orange */
  color: var(--text-color);
  text-decoration: none;
  border-radius: 4px;
  transition: opacity 0.2s ease, transform 0.2s ease;
}
.product .amazon-button:hover {
  opacity: 0.9;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.15);
  transform: none;  /* ensure it doesn’t shift */
}

/* INDIVIDUAL NETWORK COLORS */
.share-button.facebook {
  background-color: #1877f2;
}

.share-button.x {
  background-color: #000000;
}

.share-button.instagram {
  background-color: #E4405F; /* Instagram pink/red */
}

.share-button.pinterest {
  background-color: #bd081c;
}

.share-button.whatsapp {
  background-color: #25d366;
}

/* RESPONSIVE: STACK ON VERY SMALL SCREENS */
@media (max-width: 480px) {
  .share-buttons {
    flex-direction: column;
    gap: 10px;
  }
  .share-button {
    width: 100%;
    text-align: center;
  }
}

/***** FOOTER *****/
footer {
  text-align: center;
  font-size: 0.9rem;
  color: #888888;
  padding: 30px 10px;
}

/***** RESPONSIVE BREAKPOINTS *****/
@media (max-width: 768px) {
  /* Keep .nav-container as a ROW so logo + hamburger are side by side */
  .nav-container {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding: 10px 20px;
  }

  /* Show hamburger icon on mobile */
  .menu-icon {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 22px;
    cursor: pointer;
  }
  .menu-icon span {
    display: block;
    height: 3px;
    background: var(--text-color);
    border-radius: 2px;
  }

  /* Hide navigation by default on mobile */
  nav {
    display: none;
    position: absolute;      /* pull it out of normal flow to prevent distortion */
    top: 100%;               /* right below header */
    left: 0;
    right: 0;
    background: var(--bg-color);
    z-index: 999;
  }

  /* When checkbox is checked, display the nav */
  #menu-toggle:checked + .menu-icon + nav {
    display: block;
  }

  /* Mobile nav links appear in a vertical list */
  nav ul {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 15px;
    margin: 0;               /* remove desktop margin */
    padding: 10px 20px;      /* add some breathing room */
  }
  nav a {
    font-size: 1.1rem;
    padding: 10px 0;
    width: 100%;
    box-sizing: border-box;
  }

  /* Cancel floats on images; they become full-width above paragraphs */
  .side-image-right,
  .side-image-left {
    float: none;
    width: 100%;
    margin: 0 0 20px 0;
    aspect-ratio: auto;      /* natural ratio on narrow screens */
  }
}

@media (max-width: 480px) {
  /* Tighter padding and slightly smaller typography on very small phones */
  main {
    padding: 30px 15px;
  }
  h1.section-title {
    font-size: 1.75rem;
  }
  h2 {
    font-size: 1.4rem;
  }
  h3 {
    font-size: 1.1rem;
  }
  nav a {
    font-size: 1rem;
  }
  p, ul {
    font-size: 0.95rem;
  }
}

/* Mobile: stack one under the other */
@media (max-width: 768px) {
  #recommended .product-grid {
    display: flex;            /* back to flex */
    flex-direction: column;   /* one per row */
    gap: 16px;                /* some breathing room */
  }
  /* ensure each product spans full width */
  #recommended .product {
    flex: none;
    width: 100%;
  }
}