:root {
  --primary: #2540b8;        /* royal blue (matches banner headline) */
  --primary-dark: #1a2e85;
  --accent: #fcb71b;         /* bright gold/yellow promo */
  --accent-dark: #e0a000;
  --ink: #16235a;            /* deep navy ink */
  --muted: #6b7280;
  --bg: #ffffff;
  --bg-soft: #f5f7ff;
  --border: #e7e9ee;
  --sale: #e23744;
  --radius: 14px;
  --shadow: 0 6px 24px rgba(20, 35, 90, 0.08);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: "Poppins", system-ui, sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.55;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 1rem; }
.muted { color: var(--muted); }

/* ---------------- Buttons ---------------- */
.btn {
  display: inline-block;
  border: none;
  cursor: pointer;
  border-radius: 999px;
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  font-size: 0.95rem;
  font-family: inherit;
  transition: transform 0.15s, background 0.2s, box-shadow 0.2s;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); }
.btn-outline { background: transparent; border: 2px solid var(--primary); color: var(--primary); }
.btn-light { background: #fff; color: var(--primary); }
.btn-add {
  background: var(--ink); color: #fff; width: 100%; border-radius: 10px; padding: 0.65rem;
}
.btn-add:hover { background: var(--primary); }
.btn.full { width: 100%; margin-top: 0.75rem; }

/* ---------------- Announcement bar ---------------- */
.announcement-bar {
  background: var(--ink);
  color: #fff;
  overflow: hidden;
  font-size: 0.85rem;
  padding: 0.5rem 0;
}
.announcement-track {
  white-space: nowrap;
  text-align: center;
  font-weight: 500;
}

/* ---------------- Header ---------------- */
.header {
  position: sticky; top: 0; z-index: 50;
  background: #fff;
  border-bottom: 1px solid var(--border);
}
.header-inner {
  display: flex; align-items: center; gap: 1rem;
  padding: 0.85rem 1rem;
}
.logo { font-size: 1.5rem; font-weight: 800; letter-spacing: -0.5px; }
.logo span { color: var(--primary); }
.logo small { font-size: 0.7rem; color: var(--muted); font-weight: 600; }
.brand-logo { display: inline-flex; align-items: center; gap: 0.55rem; }
.brand-logo svg { flex-shrink: 0; }
.brand-text { font-size: 1.4rem; font-weight: 800; letter-spacing: -0.5px; line-height: 1; }
.brand-text small { font-size: 0.62rem; color: var(--muted); font-weight: 700; margin-left: 4px; vertical-align: super; }
.search { flex: 1; display: flex; max-width: 480px; margin: 0 auto; }
.search input {
  flex: 1; border: 1px solid var(--border); border-right: none;
  border-radius: 999px 0 0 999px; padding: 0.6rem 1.1rem; font-family: inherit; outline: none;
}
.search input:focus { border-color: var(--primary); }
.search button {
  border: 1px solid var(--border); border-left: none; background: var(--bg-soft);
  border-radius: 0 999px 999px 0; padding: 0 1.1rem; cursor: pointer;
}
.header-actions { display: flex; align-items: center; gap: 0.85rem; }
.currency {
  border: 1px solid var(--border); border-radius: 8px; padding: 0.4rem 0.5rem;
  font-family: inherit; cursor: pointer; background: #fff;
}
.icon-link { font-size: 1.3rem; position: relative; }
.cart-badge {
  position: absolute; top: -8px; right: -10px; background: var(--sale); color: #fff;
  font-size: 0.7rem; font-weight: 700; min-width: 18px; height: 18px; border-radius: 999px;
  display: grid; place-items: center; padding: 0 4px;
}
.hamburger { display: none; font-size: 1.4rem; background: none; border: none; cursor: pointer; }

/* ---------------- Nav ---------------- */
.nav { border-top: 1px solid var(--border); background: #fff; }
.nav-inner { display: flex; gap: 1.75rem; padding: 0.7rem 1rem; align-items: center; }
.nav-inner > a, .dropdown > span {
  font-weight: 600; font-size: 0.92rem; cursor: pointer; color: var(--ink);
  padding: 0.25rem 0; transition: color 0.2s;
}
.nav-inner > a:hover, .dropdown:hover > span { color: var(--primary); }
.dropdown { position: relative; }
.dropdown-menu {
  position: absolute; top: 100%; left: 0; background: #fff;
  border: 1px solid var(--border); border-radius: 10px; box-shadow: var(--shadow);
  min-width: 200px; padding: 0.4rem; display: none; flex-direction: column; z-index: 60;
}
.dropdown:hover .dropdown-menu { display: flex; }
.dropdown-menu a { padding: 0.55rem 0.75rem; border-radius: 8px; font-size: 0.9rem; }
.dropdown-menu a:hover { background: var(--bg-soft); color: var(--primary); }

/* ---------------- Hero (banner image) ---------------- */
.hero {
  background:
    radial-gradient(1100px 380px at 15% -10%, #e8ecff 0%, transparent 60%),
    radial-gradient(900px 360px at 95% 110%, #fff4d6 0%, transparent 55%),
    linear-gradient(135deg, #f5f7ff 0%, #ffffff 100%);
  padding: 2.4rem 0 1rem;
}
.hero-banner {
  position: relative; display: block; border-radius: 22px; overflow: hidden;
  box-shadow: 0 18px 50px rgba(20, 35, 90, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.7);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.hero-banner:hover { transform: translateY(-4px); box-shadow: 0 26px 60px rgba(20, 35, 90, 0.22); }
.hero-banner img { width: 100%; height: auto; display: block; }
.hero-banner-cta {
  position: absolute; bottom: 18px; right: 18px;
  background: var(--accent); color: var(--ink); font-weight: 800;
  font-size: 0.9rem; padding: 0.6rem 1.2rem; border-radius: 999px;
  box-shadow: 0 6px 18px rgba(224, 160, 0, 0.45);
  transition: transform 0.2s ease, background 0.2s ease;
}
.hero-banner:hover .hero-banner-cta { transform: scale(1.06); background: var(--accent-dark); color: #fff; }

/* Category chip row under the banner */
.hero-cats {
  display: grid; grid-template-columns: repeat(5, 1fr); gap: 1rem; margin-top: 1.6rem;
}
.hero-cat {
  display: flex; flex-direction: column; align-items: center; gap: 0.55rem;
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 1.1rem 0.75rem; text-align: center; font-weight: 600; font-size: 0.9rem;
  color: var(--ink); transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.hero-cat:hover {
  transform: translateY(-4px); box-shadow: var(--shadow);
  border-color: color-mix(in srgb, var(--c) 45%, var(--border));
}
.hero-cat-icon {
  width: 52px; height: 52px; display: grid; place-items: center; font-size: 1.55rem;
  border-radius: 50%;
  background: color-mix(in srgb, var(--c) 15%, #fff);
  border: 2px solid color-mix(in srgb, var(--c) 35%, #fff);
}
.hero-cat-label { line-height: 1.2; }

/* ---------------- Trust ---------------- */
.trust { padding: 2.5rem 0; }
.trust-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.2rem; }
.trust-card {
  background: var(--bg-soft); border-radius: var(--radius); padding: 1.5rem; text-align: center;
}
.trust-icon { font-size: 2rem; }
.trust-card h4 { margin: 0.6rem 0 0.3rem; }
.trust-card p { font-size: 0.85rem; color: var(--muted); }

/* ---------------- Sections / product grid ---------------- */
.section-title { font-size: 1.8rem; font-weight: 800; }
.section-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.4rem; }
.view-all { color: var(--primary); font-weight: 600; }
.product-section { padding: 2.5rem 1rem; }
.product-grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.3rem;
}

/* ---------------- Product card ---------------- */
.product-card {
  border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden;
  background: #fff; transition: box-shadow 0.2s, transform 0.2s; display: flex; flex-direction: column;
}
.product-card:hover { box-shadow: var(--shadow); transform: translateY(-4px); }
.product-card-img { position: relative; aspect-ratio: 1; background: var(--bg-soft); }
.product-card-img img { width: 100%; height: 100%; object-fit: cover; }
.badge-sale {
  position: absolute; top: 10px; left: 10px; background: var(--sale); color: #fff;
  font-size: 0.75rem; font-weight: 700; padding: 0.25rem 0.55rem; border-radius: 6px; z-index: 2;
}
.badge-best {
  position: absolute; top: 10px; right: 10px; background: var(--accent); color: #1a1a1a;
  font-size: 0.7rem; font-weight: 700; padding: 0.25rem 0.55rem; border-radius: 6px; z-index: 2;
}
.product-card-body { padding: 0.9rem; display: flex; flex-direction: column; gap: 0.4rem; flex: 1; }
.stars { color: var(--accent); font-size: 0.85rem; }
.stars span { color: var(--muted); }
.product-title {
  font-weight: 600; font-size: 0.92rem; line-height: 1.35; color: var(--ink);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  min-height: 2.5em;
}
.product-title:hover { color: var(--primary); }
.price-row { display: flex; align-items: baseline; gap: 0.5rem; margin-top: auto; }
.price { font-weight: 800; font-size: 1.1rem; color: var(--primary); }
.compare-price { color: var(--muted); text-decoration: line-through; font-size: 0.9rem; }
.price-row.big .price { font-size: 1.8rem; }

/* ---------------- Promo banner ---------------- */
.promo-banner {
  margin: 2rem auto; background: linear-gradient(120deg, var(--primary), var(--primary-dark));
  border-radius: 20px; color: #fff; padding: 3rem 2rem; text-align: center;
}
.promo-content h2 { font-size: 2rem; }
.promo-content p { max-width: 520px; margin: 0.6rem auto 1.4rem; opacity: 0.9; }

/* ---------------- Gallery ---------------- */
.gallery { padding: 2.5rem 1rem; }
.gallery-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 0.8rem; margin-top: 1.2rem; }
.gallery-grid img { border-radius: 12px; aspect-ratio: 1; object-fit: cover; }

/* ---------------- FAQ ---------------- */
.faq { padding: 2.5rem 1rem; max-width: 800px; }
.faq .section-title { text-align: center; margin-bottom: 1.5rem; }
.faq-list { display: flex; flex-direction: column; gap: 0.7rem; }
.faq-item { border: 1px solid var(--border); border-radius: 12px; overflow: hidden; }
.faq-item button {
  width: 100%; text-align: left; background: #fff; border: none; padding: 1rem 1.2rem;
  font-weight: 600; font-family: inherit; font-size: 0.98rem; cursor: pointer;
  display: flex; justify-content: space-between; align-items: center;
}
.faq-item p { padding: 0 1.2rem 1rem; color: var(--muted); }
.faq-item.open { border-color: var(--primary); }

/* ---------------- Newsletter ---------------- */
.newsletter { background: var(--bg-soft); padding: 3rem 0; margin-top: 2rem; }
.newsletter-inner { text-align: center; max-width: 560px; }
.newsletter h2 { font-size: 1.8rem; }
.newsletter p { color: var(--muted); margin: 0.5rem 0 1.3rem; }
.newsletter form { display: flex; gap: 0.5rem; max-width: 440px; margin: 0 auto; }
.newsletter input {
  flex: 1; border: 1px solid var(--border); border-radius: 999px; padding: 0.75rem 1.2rem;
  font-family: inherit; outline: none;
}
.newsletter input:focus { border-color: var(--primary); }
.success-text { color: var(--primary); font-weight: 600; margin-top: 0.8rem; }
.error-text { color: var(--sale); font-weight: 600; margin-top: 0.8rem; }

/* ---------------- Footer ---------------- */
.footer { background: var(--ink); color: #cfd3da; margin-top: 3rem; padding-top: 3rem; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1.3fr; gap: 2rem; padding-bottom: 2rem; }
.footer .logo { color: #fff; }
.footer h4 { color: #fff; margin-bottom: 0.9rem; }
.footer-grid a, .footer-grid p { display: block; color: #aab1bd; font-size: 0.9rem; margin-bottom: 0.5rem; }
.footer-grid a:hover { color: #fff; }
.social { display: flex; gap: 0.6rem; margin-top: 1rem; }
.social a {
  width: 36px; height: 36px; border-radius: 50%; background: #2a2d34; display: grid;
  place-items: center; color: #fff !important; margin: 0;
}
.footer-bottom { border-top: 1px solid #2a2d34; padding: 1.2rem 0; }
.footer-bottom-inner { display: flex; justify-content: space-between; align-items: center; font-size: 0.85rem; flex-wrap: wrap; gap: 1rem; }
.payment-icons { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.payment-icons span {
  background: #fff; color: #1a1a1a; font-size: 0.72rem; font-weight: 700;
  padding: 0.25rem 0.5rem; border-radius: 5px;
}

/* ---------------- Purchase popup ---------------- */
.purchase-popup {
  position: fixed; bottom: 20px; left: 20px; z-index: 80; background: #fff;
  border: 1px solid var(--border); border-radius: 12px; box-shadow: var(--shadow);
  padding: 0.9rem 1.1rem; display: flex; gap: 0.7rem; align-items: center; max-width: 300px;
  font-size: 0.85rem; animation: slideUp 0.4s ease;
}
.purchase-popup-icon { font-size: 1.4rem; }
.purchase-popup span { color: var(--primary); font-weight: 600; }
.purchase-popup-time { color: var(--muted); font-size: 0.72rem; margin-top: 2px; }
@keyframes slideUp { from { transform: translateY(20px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }

/* ---------------- Collection / pages ---------------- */
.collection-page, .page-content { padding: 2rem 1rem 3rem; min-height: 50vh; }
.collection-head { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 1.5rem; flex-wrap: wrap; gap: 1rem; }
.collection-head h1 { text-transform: capitalize; }
.collection-head select, .track-form input {
  border: 1px solid var(--border); border-radius: 8px; padding: 0.55rem 0.8rem; font-family: inherit;
}
.page-content h1 { margin-bottom: 1rem; }
.page-content > p { max-width: 760px; color: #444; margin-bottom: 1rem; }

/* ---------------- Product detail ---------------- */
.breadcrumb { font-size: 0.85rem; color: var(--muted); margin-bottom: 1.5rem; }
.breadcrumb a:hover { color: var(--primary); }
.product-detail { padding: 1.5rem 1rem 3rem; }
.product-detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; }
.product-detail-img { position: relative; border-radius: var(--radius); overflow: hidden; background: var(--bg-soft); }
.product-detail-info h1 { font-size: 2rem; margin: 0.4rem 0; }
.product-desc { color: #444; margin: 1.2rem 0; }
.qty-row { display: flex; gap: 1rem; align-items: center; margin: 1rem 0; }
.qty-selector { display: flex; align-items: center; border: 1px solid var(--border); border-radius: 10px; overflow: hidden; }
.qty-selector button { border: none; background: var(--bg-soft); width: 40px; height: 42px; font-size: 1.2rem; cursor: pointer; }
.qty-selector span { width: 46px; text-align: center; font-weight: 600; }
.qty-selector.small button { width: 30px; height: 32px; }
.qty-selector.small span { width: 34px; }
.product-perks { list-style: none; margin-top: 1.5rem; display: flex; flex-direction: column; gap: 0.5rem; color: #444; font-size: 0.9rem; }

/* ---------------- Cart ---------------- */
.cart-page { padding: 2rem 1rem 3rem; }
.cart-page h1 { margin-bottom: 1.5rem; }
.cart-layout { display: grid; grid-template-columns: 1.6fr 1fr; gap: 2rem; align-items: start; }
.cart-item { display: grid; grid-template-columns: 80px 1fr auto auto auto; gap: 1rem; align-items: center; padding: 1rem 0; border-bottom: 1px solid var(--border); }
.cart-item img { width: 80px; height: 80px; object-fit: cover; border-radius: 10px; }
.cart-item-info h4 { font-size: 0.95rem; }
.cart-item-total { font-weight: 700; }
.remove { background: none; border: none; cursor: pointer; font-size: 1rem; color: var(--muted); }
.remove:hover { color: var(--sale); }
.cart-summary { background: var(--bg-soft); border-radius: var(--radius); padding: 1.5rem; position: sticky; top: 90px; }
.summary-row { display: flex; justify-content: space-between; margin: 0.6rem 0; }
.summary-row.total { border-top: 1px solid var(--border); padding-top: 0.8rem; font-weight: 800; font-size: 1.2rem; }
.summary-row .free { color: var(--primary); font-weight: 700; }
.checkout-form { display: flex; flex-direction: column; gap: 0.6rem; margin-top: 1rem; }
.checkout-form input, .checkout-form textarea, .contact-form input, .contact-form textarea, .track-form input {
  border: 1px solid var(--border); border-radius: 10px; padding: 0.7rem 0.9rem; font-family: inherit; outline: none;
}
.checkout-form textarea, .contact-form textarea { resize: vertical; min-height: 70px; }
.pay-note { font-size: 0.78rem; color: var(--muted); text-align: center; margin-top: 1rem; }

/* ---------------- Misc pages ---------------- */
.empty-state { text-align: center; padding: 4rem 1rem; min-height: 50vh; }
.empty-state h2 { margin-bottom: 1rem; }
.cta-row { display: flex; gap: 0.8rem; justify-content: center; margin-top: 1.5rem; flex-wrap: wrap; }
.about-grid, .contact-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.2rem; margin-top: 1.5rem; }
.about-card { background: var(--bg-soft); border-radius: var(--radius); padding: 1.5rem; }
.contact-info { background: var(--bg-soft); border-radius: var(--radius); padding: 1.5rem; }
.contact-info p { margin: 0.5rem 0; }
.contact-form { display: flex; flex-direction: column; gap: 0.7rem; }
.track-form { display: flex; gap: 0.6rem; max-width: 420px; margin: 1rem 0; }
.track-form input { flex: 1; }
.track-result { background: var(--bg-soft); border-radius: var(--radius); padding: 1.5rem; margin-top: 1.5rem; max-width: 520px; }
.track-result p { margin: 0.4rem 0; }
.status-pill { background: var(--primary); color: #fff; padding: 0.15rem 0.6rem; border-radius: 999px; font-size: 0.8rem; }
.track-result ul { margin-left: 1.2rem; margin-top: 0.5rem; }

/* ---------------- Responsive ---------------- */
@media (max-width: 1024px) {
  .product-grid, .trust-grid { grid-template-columns: repeat(3, 1fr); }
  .gallery-grid { grid-template-columns: repeat(3, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
  .hamburger { display: block; }
  .nav { display: none; }
  .nav.open { display: block; }
  .nav-inner { flex-direction: column; align-items: flex-start; gap: 0.5rem; }
  .dropdown-menu { position: static; display: flex; box-shadow: none; border: none; padding-left: 1rem; }
  .dropdown:hover .dropdown-menu { display: flex; }
  .hero-cats { grid-template-columns: repeat(3, 1fr); }
  .hero-banner-cta { bottom: 10px; right: 10px; padding: 0.45rem 0.9rem; font-size: 0.78rem; }
  .product-grid, .trust-grid { grid-template-columns: repeat(2, 1fr); }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); }
  .product-detail-grid { grid-template-columns: 1fr; gap: 1.5rem; }
  .cart-layout { grid-template-columns: 1fr; }
  .about-grid, .contact-grid { grid-template-columns: 1fr; }
  .search { order: 3; max-width: 100%; flex-basis: 100%; }
  .header-inner { flex-wrap: wrap; }
}
@media (max-width: 480px) {
  .product-grid { grid-template-columns: 1fr 1fr; gap: 0.8rem; }
  .footer-grid { grid-template-columns: 1fr; }
  .hero-cats { grid-template-columns: repeat(2, 1fr); }
  .hero-cat { padding: 0.85rem 0.5rem; font-size: 0.82rem; }
  .hero-cat-icon { width: 44px; height: 44px; font-size: 1.3rem; }
}

/* ---------------- PHP/Bootstrap compatibility overrides ---------------- */
/* Ensure our custom design wins over Bootstrap defaults */
.btn { text-decoration: none; line-height: 1.2; }
.btn:disabled, .btn[disabled] { opacity: 0.6; cursor: not-allowed; transform: none; }
a.btn { display: inline-block; }
.product-card-img img { display: block; }
/* hide mobile nav by default handled by original media queries */
.nav.open { display: block; }
.flash { max-width: 1200px; margin: 1rem auto 0; padding: 0 1rem; }
.flash-msg { background: #eef6ee; border: 1px solid #cfe3cf; color: #1f5130; padding: 0.75rem 1rem; border-radius: 10px; font-weight: 600; }
.flash-msg.error { background: #fdecec; border-color: #f3c4c4; color: #a12626; }
