/* Al Yarnaa Medical & Lab Consumables - Clean English LTR Theme */
:root {
  --primary: #446084;
  --primary-light: #5a7a9e;
  --primary-dark: #344b68;
  --accent: #a5a539;
  --accent-light: #c4c45a;
  --bg-light: #f8fafc;
  --bg-white: #ffffff;
  --text-dark: #1f2937;
  --text-medium: #4b5563;
  --text-light: #6b7280;
  --text-muted: #9ca3af;
  --border: #e5e7eb;
  --border-light: #f3f4f6;
  --whatsapp: #25D366;
  --danger: #ef4444;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  background-color: var(--bg-white);
  color: var(--text-dark);
  line-height: 1.7;
  overflow-x: hidden;
  direction: ltr;
}

h1, h2, h3, h4, h5, h6 {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  font-weight: 700;
  line-height: 1.4;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: all 0.3s ease;
}
a:hover { color: var(--primary-light); }

::selection { background: var(--primary); color: #fff; }
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg-light); }
::-webkit-scrollbar-thumb { background: var(--primary-light); border-radius: 3px; }

/* Utility Classes */
.text-primary { color: var(--primary); }
.text-accent { color: var(--accent); }
.bg-primary { background-color: var(--primary); }
.bg-accent { background-color: var(--accent); }
.border-primary { border-color: var(--primary); }

.line-clamp-2 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.line-clamp-3 { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }

/* Dividers */
.blue-divider {
  width: 80px;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--primary), transparent);
  margin: 0 auto;
}
.blue-divider-left {
  width: 60px;
  height: 2px;
  background: linear-gradient(90deg, var(--primary), transparent);
}

/* Buttons */
.btn-gold,
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 32px;
  background: var(--primary);
  color: #fff;
  font-weight: 600;
  font-size: 0.9rem;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}
.btn-gold:hover,
.btn-primary:hover {
  background: var(--primary-dark);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(68, 96, 132, 0.25);
}

.btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 32px;
  background: transparent;
  color: var(--primary);
  font-weight: 600;
  font-size: 0.9rem;
  border: 2px solid var(--primary);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
}
.btn-outline:hover {
  background: var(--primary);
  color: #fff;
}

/* Hero Section */
.hero-section {
  position: relative;
  height: 80vh;
  min-height: 500px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(68,96,132,0.6) 0%, rgba(68,96,132,0.3) 40%, rgba(52,75,104,0.7) 100%);
  z-index: 1;
}
.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 900px;
  padding: 0 24px;
}
.hero-content h1 {
  font-size: clamp(1.8rem, 5vw, 3.5rem);
  color: #fff;
  margin-bottom: 20px;
  text-shadow: 0 2px 20px rgba(0,0,0,0.3);
}
.hero-content p {
  font-size: clamp(1rem, 2vw, 1.25rem);
  color: rgba(255,255,255,0.85);
  max-width: 600px;
  margin: 0 auto 40px;
}

/* Product Cards */
.product-card {
  position: relative;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
}
.product-card:hover {
  border-color: var(--primary-light);
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(68,96,132,0.12);
}
.product-card .card-image {
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: var(--bg-light);
}
.product-card .card-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  transition: transform 0.5s ease;
}
.product-card:hover .card-image img { transform: scale(1.05); }
.product-card .card-body {
  padding: 16px;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.product-card .card-category {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--accent);
  margin-bottom: 6px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.product-card .card-title {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-dark);
  line-height: 1.5;
  margin-bottom: 10px;
  min-height: 2.4em;
}
.product-card .card-price {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--primary);
}
.product-card .featured-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  background: var(--accent);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 6px;
  z-index: 2;
}

/* Section Heading */
.section-heading {
  text-align: center;
  margin-bottom: 48px;
}
.section-heading .subtitle {
  font-size: 0.9rem;
  color: var(--accent);
  font-weight: 500;
  margin-bottom: 8px;
}
.section-heading h2 {
  font-size: clamp(1.4rem, 3vw, 2.2rem);
  color: var(--text-dark);
  margin-bottom: 16px;
}

/* Testimonial */
.testimonial-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 32px;
  position: relative;
}
.testimonial-card::before {
  content: '\201C';
  font-size: 4rem;
  color: var(--primary);
  opacity: 0.15;
  position: absolute;
  top: 10px;
  left: 20px;
  line-height: 1;
}

/* Category Banner */
.category-banner {
  position: relative;
  height: 250px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
}
.category-banner::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(68,96,132,0.4), rgba(52,75,104,0.7));
}
.category-banner h2 {
  position: relative;
  z-index: 1;
  color: #fff;
  font-size: clamp(1.5rem, 4vw, 2.5rem);
}

/* WhatsApp Float */
.whatsapp-float {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 60px;
  height: 60px;
  background: var(--whatsapp);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 999;
  box-shadow: 0 4px 20px rgba(37, 211, 102, 0.35);
  animation: whatsapp-pulse 2s infinite;
  transition: transform 0.3s;
}
.whatsapp-float:hover { transform: scale(1.1); }
.whatsapp-float svg { width: 30px; height: 30px; fill: #fff; }

@keyframes whatsapp-pulse {
  0%, 100% { box-shadow: 0 4px 20px rgba(37, 211, 102, 0.35); }
  50% { box-shadow: 0 4px 40px rgba(37, 211, 102, 0.5), 0 0 60px rgba(37, 211, 102, 0.15); }
}

/* Animations */
.fade-ready .fade-up {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}
.fade-ready .fade-up.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== HEADER NAV ===== */
/* Desktop nav links */
.main-nav a.nav-link {
  color: #374151;
  font-weight: 500;
  font-size: 0.875rem;
  padding: 8px 12px;
  border-radius: 6px;
  transition: color 0.2s, background 0.2s;
}
.main-nav a.nav-link:hover {
  color: var(--primary) !important;
  background: rgba(68,96,132,0.06);
}

/* Shop dropdown - trigger */
.shop-dropdown { position: relative; }
.shop-dropdown .nav-link { cursor: pointer; }
.shop-dropdown .nav-link svg { transition: transform 0.3s; }

/* Shop dropdown - panel */
.shop-dropdown-panel {
  position: absolute;
  top: 100%;
  left: 0;
  padding-top: 4px;
  width: 420px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: opacity 0.25s, visibility 0.25s, transform 0.25s;
  z-index: 50;
}
.shop-dropdown:hover .shop-dropdown-panel {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.shop-dropdown:hover .nav-link svg { transform: rotate(180deg); }

.shop-dropdown-inner {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.12), 0 0 0 1px rgba(0,0,0,0.04);
  padding: 24px;
}

/* Dropdown category cards */
.dd-cat {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px;
  border-radius: 10px;
  transition: background 0.2s;
  text-decoration: none;
}
.dd-cat:hover {
  background: rgba(68,96,132,0.05);
}
.dd-cat-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all 0.25s;
}
.dd-cat-icon.medical { background: rgba(68,96,132,0.1); color: var(--primary); }
.dd-cat-icon.lab { background: rgba(165,165,57,0.1); color: var(--accent); }
.dd-cat:hover .dd-cat-icon.medical { background: var(--primary); color: #fff; }
.dd-cat:hover .dd-cat-icon.lab { background: var(--accent); color: #fff; }
.dd-cat h4 { font-size: 0.875rem; font-weight: 700; color: var(--text-dark); margin: 0; }
.dd-cat:hover h4 { color: var(--primary); }
.dd-cat p { font-size: 0.75rem; color: #9ca3af; margin: 4px 0 0; line-height: 1.4; }

.dd-footer {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid #f3f4f6;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.dd-footer a {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 6px;
}
.dd-footer a:hover { text-decoration: underline; color: var(--primary); }
.dd-footer span { font-size: 0.75rem; color: #d1d5db; }

/* Mobile Menu */
#mobile-menu {
  transition: transform 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
  scrollbar-width: none;
}
#mobile-menu::-webkit-scrollbar { display: none; }

/* Mobile nav items */
.mobile-nav-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 20px;
  font-size: 0.875rem;
  font-weight: 500;
  color: #374151;
  border-radius: 8px;
  transition: color 0.2s, background 0.2s;
}
.mobile-nav-link:hover {
  color: var(--primary) !important;
  background: rgba(68,96,132,0.05);
}
.mobile-nav-link svg { color: rgba(68,96,132,0.4); }

/* Responsive */
@media (max-width: 768px) {
  .hero-section { min-height: 450px; }
  .btn-gold, .btn-primary, .btn-outline { padding: 10px 24px; font-size: 0.85rem; }
}

/* Admin Override */
body.admin-body {
  font-family: 'Inter', system-ui, sans-serif;
  background: #f3f4f6;
  color: #111827;
  direction: ltr;
}
