/* ======================================================
   Orbitrex Peptides — Shared Styles
   Header, Footer, Announcement Bar, Slide-out Cart,
   Mobile Menu, Utility Classes
   ====================================================== */

/* ---- Reset & Base ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Poppins', sans-serif;
  color: #333;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; display: block; }
ul, ol { list-style: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }

/* ---- Utility ---- */
.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
}

.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0,0,0,0); border: 0;
}

/* ---- Buttons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 32px;
  border-radius: 200px;
  font-size: 16px;
  font-weight: 500;
  transition: background 0.25s, transform 0.15s;
  white-space: nowrap;
}

.btn:hover { transform: translateY(-1px); }

.btn-primary {
  background: #209d50;
  color: #fff;
}
.btn-primary:hover { background: #1a8443; }

.btn-dark {
  background: #1a3c28;
  color: #fff;
}
.btn-dark:hover { background: #132e1e; }

.btn-outline {
  background: transparent;
  color: #209d50;
  border: 2px solid #209d50;
}
.btn-outline:hover { background: #209d50; color: #fff; }

.btn .arrow-icon {
  width: 18px;
  height: 18px;
  transition: transform 0.2s;
}
.btn:hover .arrow-icon { transform: translate(2px, -2px); }

/* ======================================================
   ANNOUNCEMENT BAR
   ====================================================== */
.announcement-bar {
  background: #1a3c28;
  color: #fff;
  text-align: center;
  padding: 10px 16px;
  font-size: 14px;
  font-weight: 400;
}

/* ======================================================
   HEADER
   ====================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: #fff;
  box-shadow: 0 1px 4px rgba(0,0,0,0.06);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  max-width: 1400px;
  margin: 0 auto;
}

/* Logo */
.header-logo img {
  height: 60px;
  width: auto;
}

/* Desktop Nav */
.header-nav {
  display: flex;
  align-items: center;
  gap: 36px;
}

.header-nav > .nav-item {
  position: relative;
}

.header-nav > .nav-item > a {
  font-size: 16px;
  font-weight: 500;
  color: #333;
  padding: 8px 0;
  border-bottom: 2px solid transparent;
  transition: color 0.2s, border-color 0.2s;
}

.header-nav > .nav-item > a:hover,
.header-nav > .nav-item > a.active {
  color: #209d50;
  border-bottom-color: #209d50;
}

/* Dropdown */
.nav-dropdown {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%) translateY(8px);
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 8px 30px rgba(0,0,0,0.12);
  padding: 12px 0;
  min-width: 200px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s, transform 0.2s, visibility 0.2s;
  z-index: 100;
}

.nav-item:hover .nav-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

.nav-dropdown a {
  display: block;
  padding: 10px 24px;
  font-size: 14px;
  font-weight: 400;
  color: #333;
  transition: background 0.15s, color 0.15s;
}

.nav-dropdown a:hover {
  background: #f0faf4;
  color: #209d50;
}

/* Header Icons */
.header-icons {
  display: flex;
  align-items: center;
  gap: 20px;
}

.header-icon-btn {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  color: #333;
  transition: color 0.2s;
}

.header-icon-btn:hover { color: #209d50; }

.header-icon-btn svg {
  width: 22px;
  height: 22px;
}

.cart-count {
  position: absolute;
  top: 2px;
  right: 0;
  background: #209d50;
  color: #fff;
  font-size: 10px;
  font-weight: 600;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Mobile menu toggle */
.mobile-menu-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
}

.mobile-menu-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: #333;
  border-radius: 2px;
  transition: transform 0.3s, opacity 0.3s;
}

/* ======================================================
   MOBILE MENU (off-canvas)
   ====================================================== */
.mobile-menu-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  z-index: 2000;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s, visibility 0.3s;
}

.mobile-menu-overlay.open { opacity: 1; visibility: visible; }

.mobile-menu {
  position: fixed;
  top: 0;
  right: 0;
  width: 320px;
  max-width: 85vw;
  height: 100%;
  background: #fff;
  z-index: 2001;
  transform: translateX(100%);
  transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  overflow-y: auto;
  padding: 24px;
}

.mobile-menu.open { transform: translateX(0); }

.mobile-menu-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  margin-left: auto;
  margin-bottom: 24px;
  font-size: 24px;
  color: #333;
}

.mobile-nav-list .mobile-nav-item > a {
  display: block;
  padding: 14px 0;
  font-size: 18px;
  font-weight: 500;
  color: #333;
  border-bottom: 1px solid #eee;
}

.mobile-nav-item > a:hover { color: #209d50; }

.mobile-sub-menu {
  padding-left: 20px;
}

.mobile-sub-menu a {
  display: block;
  padding: 10px 0;
  font-size: 15px;
  color: #555;
  border-bottom: 1px solid #f5f5f5;
}

.mobile-sub-menu a:hover { color: #209d50; }

.mobile-menu-announcement {
  background: #1a3c28;
  color: #fff;
  font-size: 13px;
  padding: 12px 16px;
  border-radius: 8px;
  margin-bottom: 24px;
  text-align: center;
  line-height: 1.4;
}

/* ======================================================
   SEARCH OVERLAY
   ====================================================== */
.search-overlay {
  position: fixed;
  inset: 0;
  background: rgba(255,255,255,0.97);
  z-index: 3000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s, visibility 0.3s;
}

.search-overlay.open { opacity: 1; visibility: visible; }

.search-overlay-inner {
  width: 100%;
  max-width: 600px;
  padding: 0 24px;
  text-align: center;
}

.search-overlay input {
  width: 100%;
  padding: 16px 0;
  font-size: 28px;
  font-family: 'Poppins', sans-serif;
  border: none;
  border-bottom: 2px solid #209d50;
  outline: none;
  text-align: center;
  color: #333;
}

.search-overlay-hint {
  margin-top: 12px;
  font-size: 13px;
  color: #999;
}

.search-overlay-close {
  position: absolute;
  top: 30px;
  right: 30px;
  font-size: 32px;
  color: #333;
}

/* ======================================================
   SLIDE-OUT CART
   ====================================================== */
.cart-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  z-index: 2000;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s, visibility 0.3s;
}

.cart-overlay.open { opacity: 1; visibility: visible; }

.cart-drawer {
  position: fixed;
  top: 0;
  right: 0;
  width: 400px;
  max-width: 90vw;
  height: 100%;
  background: #fff;
  z-index: 2001;
  transform: translateX(100%);
  transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  flex-direction: column;
}

.cart-drawer.open { transform: translateX(0); }

.cart-drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid #eee;
}

.cart-drawer-header h3 {
  font-size: 18px;
  font-weight: 600;
}

.cart-drawer-close {
  font-size: 24px;
  color: #333;
}

.cart-drawer-items {
  flex: 1;
  overflow-y: auto;
  padding: 16px 24px;
}

.cart-drawer-footer {
  padding: 20px 24px;
  border-top: 1px solid #eee;
}

.cart-subtotal {
  display: flex;
  justify-content: space-between;
  margin-bottom: 16px;
  font-size: 16px;
  font-weight: 600;
}

.cart-drawer-footer .btn {
  width: 100%;
  justify-content: center;
  margin-bottom: 10px;
}

/* ======================================================
   FOOTER
   ====================================================== */
.site-footer {
  background: #1a3c28;
  color: #fff;
}

/* FDA Disclaimer */
.fda-disclaimer {
  max-width: 1200px;
  margin: 0 auto;
  padding: 60px 24px 40px;
}

.fda-disclaimer-box {
  border: 1px solid rgba(255,255,255,0.3);
  border-radius: 12px;
  padding: 28px 32px;
  font-size: 13px;
  line-height: 1.7;
  color: rgba(255,255,255,0.85);
}

.fda-disclaimer-box strong {
  color: #fff;
}

/* Footer columns */
.footer-columns {
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 24px 40px;
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr 1fr;
  gap: 40px;
}

.footer-brand .footer-logo {
  height: 80px;
  width: auto;
  margin-bottom: 20px;
  filter: brightness(0) invert(1);
}

.footer-brand .footer-tagline {
  font-size: 14px;
  color: rgba(255,255,255,0.75);
  line-height: 1.5;
}

.footer-col h4 {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 20px;
  color: #fff;
}

.footer-col ul li {
  margin-bottom: 10px;
}

.footer-col ul a {
  font-size: 14px;
  color: rgba(255,255,255,0.75);
  transition: color 0.2s;
}

.footer-col ul a:hover {
  color: #fff;
}

.footer-contact-item {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
  font-size: 14px;
  color: rgba(255,255,255,0.85);
}

.footer-contact-item svg {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  color: rgba(255,255,255,0.6);
}

.footer-contact-item a {
  color: rgba(255,255,255,0.85);
  transition: color 0.2s;
}

.footer-contact-item a:hover { color: #fff; }

.footer-route-logo {
  height: 28px;
  width: auto;
  margin-top: 8px;
  filter: brightness(0) invert(1);
}

/* Copyright bar */
.footer-copyright {
  border-top: 1px solid rgba(255,255,255,0.15);
  max-width: 1200px;
  margin: 0 auto;
  padding: 24px;
  text-align: center;
  font-size: 13px;
  color: rgba(255,255,255,0.6);
}

/* ---- Back to top ---- */
.back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #209d50;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s, visibility 0.3s, transform 0.2s;
  z-index: 500;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

.back-to-top.visible { opacity: 1; visibility: visible; }
.back-to-top:hover { transform: translateY(-2px); }

/* ======================================================
   RESPONSIVE
   ====================================================== */
@media (max-width: 1024px) {
  .header-nav { display: none; }
  .mobile-menu-toggle { display: flex; }

  .footer-columns {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }
}

@media (max-width: 600px) {
  .header-inner { padding: 12px 16px; }
  .header-logo img { height: 48px; }
  .announcement-bar { font-size: 12px; padding: 8px 12px; }

  .footer-columns {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .fda-disclaimer-box { padding: 20px; font-size: 12px; }
}
