/* ── Farmasi Schweiz – Main Stylesheet ── */
/* Design: 1:1 clone of farmasi.de visual style */

:root {
  --pink:        #ff5a68;
  --pink-dark:   #e6404e;
  --pink-light:  #fff1f2;
  --navy:        #2d354e;
  --gray:        #525767;
  --gray-light:  #bec5da;
  --bg:          #f3f5fa;
  --bg-light:    #fbfbfb;
  --white:       #ffffff;
  --border:      #eaecf2;
  --radius:      12px;
  --radius-sm:   8px;
  --radius-xs:   4px;
  --shadow:      0 4px 20px rgba(45,53,78,.08);
  --shadow-lg:   0 8px 32px rgba(45,53,78,.14);
  --container:   1280px;
  --transition:  .18s ease;
}

/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; scroll-behavior: smooth; }
body {
  font-family: 'Noto Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
  background: var(--white);
  color: var(--navy);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; transition: color var(--transition); }
img { max-width: 100%; height: auto; display: block; }
ul, ol { list-style: none; }
button { cursor: pointer; border: none; background: none; font: inherit; }

/* ── Container ── */
.container,
.section-inner,
.header-upper-inner,
.header-main-inner,
.header-cats-inner,
.footer-body-inner,
.footer-bottom-inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

/* ────────────────────────────────────────────
   HEADER
──────────────────────────────────────────── */

.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--white);
  box-shadow: 0 1px 0 var(--border);
}

/* ── Upper Utility Bar ── */
.header-upper {
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  height: 40px;
}
.header-upper-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  gap: 0;
}
.header-upper-link {
  color: var(--navy);
  font-size: 12px;
  font-weight: 500;
  padding: 0 14px;
  height: 40px;
  display: flex;
  align-items: center;
  border-bottom: 2px solid transparent;
  transition: color var(--transition), border-color var(--transition);
  white-space: nowrap;
}
.header-upper-link:hover { color: var(--pink); border-bottom-color: var(--pink); }
.header-upper-cta {
  color: var(--pink);
  font-weight: 600;
}
.header-upper-cta:hover { color: var(--pink-dark); border-bottom-color: var(--pink-dark); }

/* ── Main Header Row ── */
.header-main {
  background: var(--white);
  height: 64px;
  border-bottom: 1px solid var(--border);
}
.header-main-inner {
  height: 64px;
  display: flex;
  align-items: center;
  gap: 20px;
}

/* Logo */
.site-logo {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  transition: opacity var(--transition);
}
.site-logo:hover { opacity: .85; }
.site-logo svg { display: block; }

/* Search */
.header-search { flex: 1; max-width: 480px; }
.search-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 30px;
  padding: 0 16px;
  height: 40px;
  transition: border-color var(--transition), box-shadow var(--transition);
}
.search-wrap:focus-within {
  border-color: var(--pink);
  box-shadow: 0 0 0 3px rgba(255,90,104,.1);
  background: var(--white);
}
.search-icon { color: var(--gray-light); flex-shrink: 0; }
.search-input {
  border: none;
  background: transparent;
  font-size: 13px;
  color: var(--navy);
  width: 100%;
  outline: none;
  font-family: inherit;
}
.search-input::placeholder { color: var(--gray-light); }

/* Header Icons */
.header-icons {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
  margin-left: auto;
}
.header-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  color: var(--navy);
  transition: background var(--transition), color var(--transition);
  position: relative;
}
.header-icon:hover { background: var(--bg); color: var(--pink); }
.cart-count {
  position: absolute;
  top: 4px;
  right: 4px;
  background: var(--pink);
  color: var(--white);
  font-size: 9px;
  font-weight: 700;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}
.mobile-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  padding: 8px;
  transition: background var(--transition);
}
.mobile-toggle:hover { background: var(--bg); }
.mobile-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--navy);
  border-radius: 2px;
  transition: all .2s;
}
.mobile-toggle.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.mobile-toggle.active span:nth-child(2) { opacity: 0; }
.mobile-toggle.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ── Category Navigation Bar ── */
.header-cats {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  height: 48px;
  overflow: visible;
  position: relative;
  z-index: 999;
}
.header-cats-inner {
  display: flex;
  align-items: stretch;
  height: 48px;
  gap: 0;
  overflow: visible;
}

/* Category Items */
.hcat {
  position: relative;
  display: flex;
  align-items: stretch;
}
.hcat-link {
  display: flex;
  align-items: center;
  gap: 3px;
  padding: 0 14px;
  font-size: 13px;
  font-weight: 500;
  color: var(--navy);
  white-space: nowrap;
  border-bottom: 2px solid transparent;
  transition: color var(--transition), border-color var(--transition);
  height: 100%;
  text-transform: none !important;
  letter-spacing: normal !important;
}
.hcat-link:hover,
.hcat.active .hcat-link {
  color: var(--pink);
  border-bottom-color: var(--pink);
}
.hcat-arrow {
  opacity: .5;
  transition: transform .2s;
  flex-shrink: 0;
}
.hcat:hover .hcat-arrow { transform: rotate(180deg); opacity: 1; }

/* Dropdowns */
.hcat-drop {
  display: none;
  position: absolute;
  top: calc(100% + 1px);
  left: 0;
  min-width: 200px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 0 0 var(--radius) var(--radius);
  box-shadow: 0 16px 40px rgba(45,53,78,.12);
  padding: 8px 0;
  z-index: 1001;
}
.hcat.has-drop:hover .hcat-drop { display: block; }
.hcat-drop a {
  display: block;
  padding: 9px 20px;
  font-size: 14px;
  font-weight: 400;
  color: var(--gray);
  transition: color var(--transition), background var(--transition);
  white-space: nowrap;
  text-transform: none !important;
}
.hcat-drop a:hover {
  color: var(--pink);
  background: var(--pink-light);
}

/* Mega-menu Dropdowns — matches farmasi.de layout */
.hcat-mega {
  min-width: 560px;
  display: none;
  flex-direction: row;
  gap: 0;
  padding: 24px 0;
  left: 0;
  /* override simple-dropdown radius */
  border-radius: 0 var(--radius) var(--radius) var(--radius);
}
/* Prevent simple-drop rule from overriding flex */
.hcat.has-drop.has-mega:hover .hcat-drop { display: flex; }
.mega-col {
  flex: 1;
  padding: 0 24px;
  border-right: 1px solid var(--border);
  min-width: 160px;
}
.mega-col:last-child { border-right: none; }
.mega-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border);
  text-transform: none;
  letter-spacing: 0;
}
.mega-col a {
  padding: 6px 0;
  font-size: 14px;
  font-weight: 400;
  color: var(--gray);
  border: none;
  display: block;
  transition: color var(--transition);
  text-transform: none !important;
}
.mega-col a:hover { color: var(--pink); background: transparent; padding-left: 0; }

/* ── Mobile Navigation ── */
.mobile-nav {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--white);
  z-index: 2000;
  overflow-y: auto;
  padding-top: 64px;
  transform: translateX(-100%);
  transition: transform .3s ease;
}
.mobile-nav.open {
  transform: translateX(0);
}
.mobile-nav-list {
  padding: 16px 0 32px;
}
.mobile-nav-list a {
  display: block;
  padding: 14px 24px;
  font-size: 15px;
  font-weight: 500;
  color: var(--navy);
  border-bottom: 1px solid var(--border);
}
.mobile-nav-list a:hover { color: var(--pink); background: var(--pink-light); }
.mobile-nav-list hr {
  margin: 8px 0;
  border: none;
  border-top: 4px solid var(--bg);
}


/* ────────────────────────────────────────────
   HOMEPAGE
──────────────────────────────────────────── */

/* Hero Banner */
.hero {
  position: relative;
  background: linear-gradient(135deg, #fff1f2 0%, #fff8f9 40%, #f3f5fa 100%);
  overflow: hidden;
}
.hero-inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: 60px 24px 52px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 56px;
}
.hero-eyebrow {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--pink);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.hero-eyebrow::before {
  content: '';
  display: block;
  width: 24px;
  height: 2px;
  background: var(--pink);
  border-radius: 2px;
}
.hero-text h1 {
  font-size: clamp(32px, 4vw, 52px);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -1.5px;
  color: var(--navy);
  margin-bottom: 18px;
}
.hero-text h1 span { color: var(--pink); }
.hero-sub {
  font-size: 16px;
  color: var(--gray);
  line-height: 1.7;
  margin-bottom: 32px;
  max-width: 440px;
}
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }

.hero-image { display: flex; justify-content: flex-end; }
.hero-img-wrap {
  width: 100%;
  max-width: 500px;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(45,53,78,.14);
}
.hero-img-wrap img { width: 100%; aspect-ratio: 4/3; object-fit: cover; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  border-radius: 30px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .4px;
  text-decoration: none;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all .2s;
  line-height: 1;
}
.btn-primary {
  background: var(--pink);
  color: var(--white);
  border-color: var(--pink);
}
.btn-primary:hover {
  background: var(--pink-dark);
  border-color: var(--pink-dark);
  color: var(--white);
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(255,90,104,.3);
}
.btn-outline {
  background: transparent;
  color: var(--navy);
  border-color: var(--gray-light);
}
.btn-outline:hover { border-color: var(--pink); color: var(--pink); }

/* Category Strip (below hero, tab-style) */
.cat-strip {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 152px; /* below all 3 header rows */
  z-index: 100;
}
.cat-strip-inner {
  display: flex;
  align-items: stretch;
  gap: 0;
  overflow-x: auto;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.cat-strip-inner::-webkit-scrollbar { display: none; }
.cat-pill {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  padding: 0 18px;
  height: 48px;
  font-size: 13px;
  font-weight: 600;
  color: var(--gray);
  border-bottom: 2px solid transparent;
  transition: color var(--transition), border-color var(--transition);
  white-space: nowrap;
}
.cat-pill:hover, .cat-pill.active { color: var(--pink); border-bottom-color: var(--pink); }

/* Product Sections */
.product-section { padding: 56px 0; }
.product-section.bg-alt { background: var(--bg); }
.section-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 28px;
}
.section-header h2 {
  font-size: 24px;
  font-weight: 800;
  color: var(--navy);
  letter-spacing: -.5px;
}
.see-all {
  font-size: 13px;
  font-weight: 600;
  color: var(--pink);
}
.see-all:hover { text-decoration: underline; color: var(--pink-dark); }

/* Promo Strip */
.promo-strip { background: var(--navy); }
.promo-strip-inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: 28px 24px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}
.promo-item {
  display: flex;
  align-items: center;
  gap: 14px;
  color: var(--white);
}
.promo-item svg { flex-shrink: 0; opacity: .75; }
.promo-item strong { display: block; font-size: 13px; font-weight: 700; margin-bottom: 2px; }
.promo-item span { font-size: 12px; opacity: .65; }

/* ── Custom Product Grid (farmasi_product_grid()) ── */
.fs-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.fs-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: box-shadow .2s, transform .2s;
}
.fs-card:hover {
  box-shadow: 0 8px 32px rgba(45,53,78,.12);
  transform: translateY(-3px);
}
.fs-card-img-wrap {
  display: block;
  overflow: hidden;
  aspect-ratio: 1 / 1;
  background: var(--bg);
}
.fs-card-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .3s;
}
.fs-card:hover .fs-card-img-wrap img { transform: scale(1.04); }
.fs-card-no-img {
  width: 100%;
  height: 100%;
  background: var(--bg);
}
.fs-card-body {
  padding: 12px 14px 14px;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.fs-card-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--navy);
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 6px;
  flex: 1;
}
.fs-card-title:hover { color: var(--pink); }
.fs-card-price {
  font-size: 16px;
  font-weight: 700;
  color: var(--pink);
  margin-bottom: 10px;
}
.fs-card-price .woocommerce-Price-amount,
.fs-card-price bdi { color: var(--pink); }
.fs-card-btn {
  display: block;
  width: 100%;
  text-align: center;
  padding: 9px 12px;
  background: var(--pink);
  color: var(--white);
  border-radius: 25px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .4px;
  transition: background .18s;
  cursor: pointer;
}
.fs-card-btn:hover { background: var(--pink-dark); color: var(--white); }

@media (max-width: 900px) {
  .fs-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 480px) {
  .fs-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
}

/* ────────────────────────────────────────────
   GENERAL PAGE CONTENT
──────────────────────────────────────────── */

.page-wrap, .woo-page-wrap {
  max-width: var(--container);
  margin: 0 auto;
  padding: 48px 24px;
}
.page-title {
  font-size: 28px;
  font-weight: 800;
  color: var(--navy);
  margin-bottom: 28px;
  letter-spacing: -.5px;
}
.entry-content {
  font-size: 15px;
  line-height: 1.8;
  color: var(--gray);
}
.entry-content h2 {
  font-size: 20px;
  font-weight: 700;
  color: var(--navy);
  margin: 28px 0 10px;
}
.entry-content h3 {
  font-size: 17px;
  font-weight: 700;
  color: var(--navy);
  margin: 20px 0 8px;
}
.entry-content p { margin-bottom: 14px; }
.entry-content ul { list-style: disc; padding-left: 20px; }
.entry-content ul li { margin-bottom: 6px; }

/* ────────────────────────────────────────────
   FOOTER
──────────────────────────────────────────── */

.site-footer {
  background: var(--navy);
  color: rgba(255,255,255,.65);
  margin-top: 64px;
  position: relative;
  overflow: hidden;
}

/* Watermark SVG */
.footer-watermark {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 1400px;
  height: 183px;
  pointer-events: none;
  overflow: hidden;
}
.footer-watermark svg {
  width: 100%;
  height: 100%;
}

/* Footer Body */
.footer-body {
  position: relative;
  z-index: 1;
  padding-top: 180px; /* below watermark */
}
.footer-body-inner {
  padding-top: 0;
  padding-bottom: 56px;
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 64px;
  align-items: start;
}

/* Brand Section */
.footer-brand {}
.footer-join-text {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: rgba(255,255,255,.5);
  margin-bottom: 16px;
}
.footer-logo { margin-bottom: 20px; }
.footer-social-title {
  font-size: 12px;
  color: rgba(255,255,255,.5);
  margin-bottom: 12px;
}
.footer-social {
  display: flex;
  gap: 8px;
  margin-bottom: 24px;
}
.footer-social-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255,255,255,.1);
  color: rgba(255,255,255,.7);
  transition: background var(--transition), color var(--transition);
}
.footer-social-btn:hover { background: var(--pink); color: var(--white); }
.footer-country {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  color: var(--navy);
  font-size: 13px;
  font-weight: 600;
  width: fit-content;
}
.footer-country-flag { font-size: 20px; }

/* Link Columns */
.footer-links {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
}
.footer-col-title {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--white);
  margin-bottom: 16px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.footer-col ul li { margin-bottom: 8px; }
.footer-col a {
  font-size: 13px;
  color: rgba(255,255,255,.55);
  transition: color var(--transition);
}
.footer-col a:hover { color: var(--white); }

/* Footer Bottom Bar */
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.08);
  position: relative;
  z-index: 1;
}
.footer-bottom-inner {
  display: flex;
  align-items: center;
  gap: 16px;
  height: 52px;
  font-size: 12px;
  color: rgba(255,255,255,.35);
}
.footer-bottom-sep { color: rgba(255,255,255,.15); }
.footer-bottom-inner a {
  color: rgba(255,255,255,.45);
  transition: color var(--transition);
}
.footer-bottom-inner a:hover { color: var(--white); }


/* ────────────────────────────────────────────
   RESPONSIVE
──────────────────────────────────────────── */

@media (max-width: 1100px) {
  .promo-strip-inner { grid-template-columns: repeat(2, 1fr); gap: 16px; }
  .header-upper-link { padding: 0 10px; font-size: 11px; }
}

@media (max-width: 900px) {
  /* Hide desktop elements, show mobile */
  .header-search { display: none; }
  .header-cats { display: none; }
  .header-upper { display: none; }
  .mobile-toggle { display: flex; }

  /* Mobile nav overlay */
  .mobile-nav { display: block; }

  /* Hero */
  .hero-inner { grid-template-columns: 1fr; gap: 32px; text-align: center; padding: 40px 24px 36px; }
  .hero-sub { max-width: 100%; }
  .hero-actions { justify-content: center; }
  .hero-image { display: none; }
  .hero-eyebrow { justify-content: center; }

  /* Footer */
  .footer-body-inner { grid-template-columns: 1fr; gap: 40px; padding-bottom: 40px; }
  .footer-links { grid-template-columns: repeat(2, 1fr); gap: 28px; }
  .footer-watermark { height: 120px; }
  .footer-body { padding-top: 130px; }
}

@media (max-width: 640px) {
  .hero-inner { padding: 32px 16px 28px; }
  .section-inner { padding: 0 16px; }
  .promo-strip-inner { grid-template-columns: 1fr 1fr; padding: 20px 16px; gap: 12px; }
  .footer-links { grid-template-columns: 1fr; gap: 24px; }
  .footer-bottom-inner { flex-direction: column; height: auto; padding: 14px 0; text-align: center; gap: 8px; }
  .footer-bottom-sep { display: none; }
  .page-wrap, .woo-page-wrap { padding: 32px 16px; }
}
