/* --- RESET & VARIABLES --- */
:root {
  --primary: #0500be; /* Deep Global Blue */
  --accent: #4a47e0; /* Lighter Blue/Purple to compliment primary */
  --text: #000000; /* Dark */
  --light: #f0f4f8; /* Cool Off-White */
  --white: #ffffff;
  --light-gray: #ced4da; /* Soft Light Gray */
  --gold: #fbbf24; /* Warm Gold */
  --loud-red: #ef4444; /* Vivid Red */
}

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

/* Legacy Support for HTML5 Elements */
header, nav, section, article, aside, footer, main {
  display: block;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica,
    Arial, sans-serif;
  color: #000000; /* Fallback */
  color: var(--text);
  line-height: 1.6;
  background-color: #ffffff; /* Fallback */
  background-color: var(--white);
}

/* --- TYPOGRAPHY --- */
h1, h2, h3 {
  line-height: 1.2;
  margin-bottom: 1rem;
}
h1 {
  font-size: 3rem;
  font-weight: 800;
  text-transform: uppercase;
}
h2 {
  font-size: 2.2rem;
  color: #000000; /* Fallback */
  color: var(--text);
  display: inline-block;
  padding-bottom: 2px;
}

p {
  margin-bottom: 1rem;
  max-width: 75ch;
}

.lead-text {
    font-size: 1.35rem; /* Increased from 1.1rem */
    color: #444;
}

.text-center {
    text-align: center;
}

.text-center p {
    margin-left: auto;
    margin-right: auto;
}

/* --- NAVIGATION --- */
header {
  background: #0500be; /* Fallback */
  background: var(--primary);
  color: #ffffff; /* Fallback */
  color: var(--white);
  padding: 1rem 5%;
  position: relative; /* Fallback for sticky */
  position: sticky;
  top: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.logo-container {
    position: absolute;
    top: 100%;
    left: 5%;
    transform: translateY(-50%); /* Might need prefix for very old, but usually ok */
    -ms-transform: translateY(-50%);
    z-index: 1001;
    width: 10vw; /* Slightly smaller relative width */
    min-width: 100px;
    max-width: 150px; /* Cap size to prevent top cut-off on large screens */
}

.logo-img {
    width: 100%;
    height: auto;
    display: block;
    border: 0; /* IE fix */
}

/* Menu Toggle */
#menu-toggle { display: none; }
.menu-btn { display: none; cursor: pointer; font-size: 1.5rem; }

.nav-links { 
    display: block; /* Fallback */
    text-align: center; /* Fallback alignment */
    display: flex; 
    align-items: center; 
    width: 100%;
    justify-content: space-around;
    padding-left: 18vw; /* Offset for the absolute logo */
}

/* --- DEFAULT LINKS --- */
a {
  color: #0500be; /* Fallback */
  color: var(--primary);
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
  text-decoration-color: rgba(5, 0, 190, 0.35);
  transition: color 0.2s ease, text-decoration-color 0.2s ease;
}

a:hover,
a:focus-visible {
  color: #4a47e0; /* Fallback */
  color: var(--accent);
  text-decoration-color: rgba(74, 71, 224, 0.75);
}

a:active {
  color: #ef4444; /* Fallback */
  color: var(--loud-red);
}

.globe-footer a:not(#footer-cta-btn),
.main-footer a:not(#footer-cta-btn) {
  color: #fbbf24; /* Fallback */
  color: var(--gold);
  text-decoration-color: rgba(251, 191, 36, 0.6);
}

.globe-footer a:hover,
.main-footer a:hover {
  color: #ffffff; /* Fallback */
  color: var(--white);
  text-decoration-color: rgba(255, 255, 255, 0.8);
}

/* Exclusions: keep your existing “button-like” links untouched */
.btn,
.nav-links a,
.product-tag,
.light-link,
.footer-cta,
.back-to-top,
#footer-cta-btn {
  text-decoration: none;
}

/* Clearfix for float fallback if needed, though flex fallback to block usually stacks vertically which is weird for nav.
   Let's stick to inline-block fallback if flex fails? 
   Actually, 'display: block' for nav-links container and 'display: inline-block' for 'a's makes more sense for fallback.
*/

.nav-links a {
  display: inline-block; /* Layout Safety */
  color: #ffffff; /* Fallback */
  color: var(--white);
  font-weight: 600;
  text-transform: uppercase;
  text-decoration: none;
  font-size: 0.9rem;
  margin: 0 10px; /* Spacing for non-flex fallback */
}
.nav-links a:hover { 
    color: #fbbf24; /* Fallback */
    color: var(--gold); 
}
.cta-button-nav {
  background: transparent;
  color: #ffffff !important; /* Fallback */
  color: var(--white) !important;
  border: 1px solid #ffffff; /* Fallback */
  border: 1px solid var(--white);
  padding: 0.5rem 1.5rem;
  border-radius: 50px;
  transition: background 0.3s;
}
.cta-button-nav:hover {
    background: rgba(255,255,255,0.1);
}

/* --- HERO SECTION --- */
.hero {
  background-color: #333; /* Fallback */
  background: linear-gradient(rgba(44, 44, 44, 0.8), rgba(81, 80, 80, 0.1)), url("assets/hero/GB_Background_4.jpg");
  background-size: cover;
  background-position: center;
  color: #ffffff; /* Fallback */
  color: var(--white);
  padding: 8rem 5%;
  text-align: center;
}

.hero p {
  font-size: 1.4rem;
  margin: 0 auto 2.5rem auto;
  color: #e9ecef;
}

.btn {
  display: inline-block;
  background: #fbbf24; /* Fallback */
  background: var(--gold);
  color: #000000; /* Fallback */
  color: var(--text);
  padding: 1rem 2.5rem;
  border-radius: 50px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
  text-decoration: none;
  transition: transform 0.2s;
}
.btn:hover { 
    transform: scale(1.05);
    -ms-transform: scale(1.05); 
}

/* --- SECTIONS --- */
section { padding: 5rem 5%; }

#page {
  padding-top: 3rem;              /* slightly tighter than homepage sections */
  padding-bottom: 5rem;
  background: #f0f4f8;            /* Fallback */
  background: var(--light);
}

/* Centered, readable content card */
.page-container {
  max-width: 1000px;
  margin: 0 auto;
  background: #ffffff;            /* Fallback */
  background: var(--white);
  border: 1px solid #ced4da;      /* Fallback */
  border: 1px solid var(--light-gray);
  border-radius: 12px;
  padding: 2.25rem 2rem;
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.06);
}

/* Good defaults for “document-like” pages */
#page h1 {
  font-size: 2.4rem;              /* smaller than hero’s 3rem */
  margin-bottom: 0.75rem;
  text-transform: uppercase;
}

#page h2 {
  margin-top: 2rem;
  margin-bottom: 0.75rem;
}

#page h3 {
  margin-top: 1.5rem;
  margin-bottom: 0.5rem;
}

/* Keep paragraph widths readable and spacing consistent */
#page p {
  max-width: 75ch;
  margin-bottom: 1rem;
}

/* Lists look nice on policies/terms pages */
#page ul,
#page ol {
  max-width: 75ch;
  margin: 0 0 1.25rem 1.25rem;
  padding: 0;
}

#page li {
  margin: 0.35rem 0;
}

/* Optional: “last updated” / small metadata line */
.page-meta {
  color: #6b7280;
  font-size: 0.95rem;
  margin-bottom: 1.5rem;
}

/* Optional: lightweight callout box for notes */
.page-callout {
  border-left: 6px solid #0500be; /* Fallback */
  border-left: 6px solid var(--primary);
  background: rgba(5, 0, 190, 0.05);
  padding: 1rem 1.25rem;
  border-radius: 10px;
  margin: 1.5rem 0;
}

/* Make links in the “content card” feel intentional */
.page-container a {
  word-break: break-word; /* long URLs won’t wreck layout */
}

/* Mobile tuning */
@media (max-width: 768px) {
  #page {
    padding-top: 2rem;
    padding-bottom: 4rem;
  }

  .page-container {
    padding: 1.5rem 1.25rem;
    border-radius: 10px;
  }

  #page h1 {
    font-size: 2rem;
  }
}

/* Large screens: keep it premium and centered */
@media (min-width: 1200px) {
  #page {
    padding-top: 4rem;
    padding-bottom: 6rem;
  }

  .page-container {
    padding: 2.75rem 2.5rem;
  }
}

.section-divider {
    border: 0;
    height: 4px;
    background: #ced4da; /* Fallback */
    background: var(--light-gray);
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    border-radius: 10px;
    opacity: 1;
}

.globe-top {
  position: relative;
  background: #0500be; /* Fallback */
  background: var(--primary);
  color: #ffffff; /* Fallback */
  color: var(--white);
  border-top-left-radius: 50% 40px;
  border-top-right-radius: 50% 40px;
  margin-top: -40px;
  padding-top: 4rem;
  padding-bottom: 3rem;
  z-index: 10;
  text-align: center;
}

.globe-top h2 {
    color: #ffffff; /* Fallback */
    color: var(--white);
}

.globe-top .lead-text {
    color: #ffffff; /* Fallback */
    color: var(--white);
}

.globe-top p {
    margin-left: auto;
    margin-right: auto;
}

.container-narrow {
    max-width: 1000px; /* Increased from 800px */
    margin: 0 auto;
}

#brands {
    padding-top: .8rem;
    padding-bottom: 2rem;
}
#products {
    padding-top: 3rem;
    padding-bottom: 5rem;
}

/* --- FEATURES GRID --- */
.features {
  display: -webkit-flex; /* Safari */
  display: flex; /* Fallback for Grid */
  flex-wrap: wrap; /* Fallback for Grid */
  justify-content: center; /* Fallback for Grid */
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 3rem;
  margin-top: 3rem;
}
.feature-col {
  text-align: center;
  padding: 1rem;
  flex: 1 1 300px; /* Fallback for non-grid layout */
  max-width: 400px; /* Limit width in flex mode */
}
.feature-icon {
    height: 60px;
    width: auto;
    margin-bottom: 1.5rem;
    display: inline-block;
    border: 0;
}
.feature-col h3 { 
    color: #0500be; /* Fallback */
    color: var(--primary); 
    margin-bottom: 1rem;
    font-size: 1.5rem;
    border: none; 
    padding-bottom: 0;
}

/* --- PRODUCT GRID --- */
.product-grid {
  display: -webkit-flex; 
  display: flex; /* Fallback */
  flex-wrap: wrap; /* Fallback */
  justify-content: center; /* Fallback */
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
  max-width: 1400px;
  margin-left: auto;
  margin-right: auto;
}
.product-item {
  background: #ffffff; /* Fallback */
  background: var(--white);
  border: 1px solid #dee2e6;
  border-radius: 6px;
  overflow: hidden;
  text-align: center;
  transition: box-shadow 0.3s;
  flex: 1 1 250px; /* Fallback flex sizing */
  max-width: 400px; /* Max width for flex */
}
.product-item:hover { box-shadow: 0 5px 15px rgba(0,0,0,0.1); }

.product-placeholder {
  background: #f1f3f5;
  height: 270px; /* Taller image section */
  display: flex; /* Flex is safe enough usually, or degrade to block */
  align-items: center;
  justify-content: center;
  font-size: 3.5rem;
  overflow: hidden;
  position: relative; /* Identify context for absolute fallback */
}

/* Fallback for object-fit: cover (IE11 and older) - centers and crops */
.product-placeholder img {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    -ms-transform: translate(-50%, -50%);
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
}

/* Modern browsers */
@supports (object-fit: cover) {
    .product-placeholder img {
        position: static;
        transform: none;
        width: 100%;
        height: 100%;
        object-fit: cover;
    }
}

.product-info { 
    padding: 1rem; 
    background-color: #0500be; /* Fallback */
    background-color: var(--primary); 
    color: #ffffff; /* Fallback */
    color: var(--white); 
}
.product-info h4 { 
    margin-bottom: 0; 
    font-size: 1.5rem;
    font-weight: 800;
}

.product-tag {
  display: inline-block;
  background: #0500be; /* Fallback */
  background: var(--primary);
  color: white;
  padding: 0.5rem 1.5rem; /* Pill shape similar to other buttons */
  font-size: 0.85rem;
  border-radius: 50px;
  text-transform: uppercase;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none; /* Ensure no underline for links */
  transition: all 0.2s ease-in-out;
}

.product-tag:hover {
    transform: translateY(-2px);
    -ms-transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
    opacity: 0.9;
    color: white;
}

.tag-loud-mouth { 
    background-color: #ef4444; /* Fallback */
    background-color: var(--loud-red); 
}
.tag-global { 
    background-color: #0500be; /* Fallback */
    background-color: var(--primary); 
}
.tag-household { background-color: #6c757d; } /* Grey for household */


/* --- CONTACT --- */
.globe-footer {
  position: relative;
  background: #0500be; /* Fallback */
  background: var(--primary);
  color: #ffffff; /* Fallback */
  color: var(--white);
  border-top-left-radius: 50% 40px;
  border-top-right-radius: 50% 40px;
  padding-top: 4rem;
  z-index: 10;
}

.footer-logo-center {
    position: absolute;
    top: -50px; /* Pull up to sit on the curve */
    left: 50%;
    transform: translateX(-50%);
    width: 10vw;
    min-width: 100px;
    max-width: 150px;
    height: auto;
    z-index: 20;
    background: transparent; /* Ensure no white box */
}

/* --- CONTACT --- */
.contact-container {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: center; /* Center contact info */
  margin-top: 3rem;
}
.contact-info {
    text-align: left; /* Keep individual items left aligned for readability */
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 2rem;
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
}

.footer-icon-img {
    width: 40px; height: 40px; /* Reduced from 60px */
    object-fit: contain;
    margin-right: 1rem;
    flex-shrink: 0;
}
.contact-item {
    display: flex;
    align-items: center;
    width: 100%;
    max-width: 300px;
    margin: 0 auto;
}
.light-link {
    color: #fbbf24; /* Fallback */
    color: var(--gold);
    text-decoration: none;
}

/* --- FOOTER --- */
.main-footer {
  background: #0500be; /* Fallback */
  background: var(--primary);
  color: #ccc;
  padding: 2rem 5%;
  border-top: 1px solid rgba(255,255,255,0.1);
  display: flex; /* Fallback logic similar to nav */
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.footer-left, .footer-right {
    flex: 1;
}

.footer-center {
    flex: 2;
    text-align: center;
}

.footer-right {
    text-align: right;
}

.footer-cta {
    background: #fbbf24; /* Fallback */
    background: var(--gold);
    color: #0500be; /* Fallback */
    color: var(--primary);
    padding: 0.5rem 1.5rem;
    border-radius: 50px;
    font-weight: 700;
    text-decoration: none;
    font-size: 0.9rem;
    display: inline-block;
    transition: transform 0.2s;
}

.back-to-top {
    color: #ccc;
    font-size: 0.9rem;
    text-decoration: none;
    transition: color 0.2s;
}

.back-to-top:hover {
    color: #fbbf24; /* Fallback */
    color: var(--gold);
}

/* --- MOBILE RESPONSIVE --- */
@media (max-width: 768px) {
  .menu-btn { 
      display: block; 
      margin-left: auto; /* Move hamburger to the right */
  }
  .logo-container {
      left: 50%;
      transform: translate(-50%, -50%);
      -ms-transform: translate(-50%, -50%);
  }
  .nav-links {
    position: absolute;
    top: 100%; left: 0; right: 0;
    background: #0500be; /* Fallback */
    background: var(--primary);
    flex-direction: column;
    padding: 0; /* Changed from padding: 5rem 0 2rem 0 to 0 for transition */
    gap: 2rem; /* Space out links */
    
    /* Animation Fallbacks */
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    clip-path: polygon(0 0, 100% 0, 100% 0, 0 0);
    transition: all 0.4s ease-in-out;
  }
  
  #menu-toggle:checked ~ .nav-links {
    padding: 5rem 0 2rem 0; /* Restore padding on open */
    max-height: 100vh; /* Allow expansion */
    opacity: 1;
    visibility: visible;
    clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
  }
  
  .hero h1 { font-size: 2rem; }
  .contact-container { flex-direction: column; }
  
  .main-footer {
      flex-direction: column;
      text-align: center;
  }
  .footer-right {
      text-align: center;
  }

  .product-placeholder {
    height: 350px; /* Taller image section */
  }
}
/* --- LARGE SCREENS --- */
@media (min-width: 1200px) {
    section {
        padding: 6rem 10%; /* More vertical space and constrained width */
    }

    .hero {
        padding: 9rem 5%; /* Taller hero */
        min-height: 60vh; /* Ensure it takes up significant screen height */
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center; /* Prevent button from stretching full width */
    }

    .features {
        max-width: 1400px;
        margin-left: auto;
        margin-right: auto;
        gap: 5rem; /* More breathing room between columns */
    }

    .product-grid {
        gap: 3rem; /* More space between products */
    }
}
