/* PetPulse - Main Stylesheet (RTL Hebrew) */
:root {
  --pp-green: #2d7d32;
  --pp-green-light: #4caf50;
  --pp-green-dark: #1b5e20;
  --pp-orange: #ff7043;
  --pp-bg: #f8faf8;
  --pp-text: #2c2c2c;
  --pp-border: #e0e8e0;
  --pp-shadow: 0 2px 12px rgba(45,125,50,.10);
  --pp-radius: 10px;
}

/* Base */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Segoe UI', 'Arial', 'Helvetica Neue', sans-serif;
  direction: rtl;
  text-align: right;
  background: var(--pp-bg);
  color: var(--pp-text);
  margin: 0;
  padding: 0;
  font-size: 16px;
  line-height: 1.6;
}
a { color: var(--pp-green); text-decoration: none; }
a:hover { color: var(--pp-green-dark); text-decoration: underline; }
img { max-width: 100%; }

/* ── Topbar ─────────────────────────────── */
.topbar {
  background: var(--pp-green-dark);
  color: #c8e6c9;
  padding: 6px 0;
  font-size: 13px;
}
.topbar a { color: #c8e6c9; }
.topbar a:hover { color: #fff; text-decoration: none; }

/* ── Marquee / Running Text ─────────────── */
.marquee-bar {
  background: var(--pp-green);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  overflow: hidden;
  white-space: nowrap;
  padding: 7px 0;
  letter-spacing: .01em;
}
.marquee-track {
  display: inline-flex;
  animation: marquee-rtl 28s linear infinite;
}
.marquee-bar:hover .marquee-track { animation-play-state: paused; }
.marquee-content { padding: 0 60px; }
@keyframes marquee-rtl {
  0%   { transform: translateX(-50%); }
  100% { transform: translateX(0); }
}

/* ── Navbar ─────────────────────────────── */
.navbar-main {
  background: #fff;
  box-shadow: var(--pp-shadow);
  padding: 12px 0;
  position: sticky;
  top: 0;
  z-index: 1000;
}
.navbar-brand img { height: 50px; object-fit: contain; }
.navbar-brand .brand-text { font-size: 24px; font-weight: 800; color: var(--pp-green); line-height: 1.1; }
.navbar-brand .brand-text span { color: var(--pp-orange); }
.nav-link { font-weight: 500; color: var(--pp-text) !important; padding: 8px 14px !important; border-radius: 6px; transition: all .2s; }
.nav-link:hover, .nav-link.active { background: #e8f5e9; color: var(--pp-green) !important; }
.cart-btn { position: relative; }
.cart-badge {
  position: absolute;
  top: -6px;
  left: -6px;
  background: var(--pp-orange);
  color: #fff;
  border-radius: 50%;
  width: 20px;
  height: 20px;
  font-size: 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
}

/* ── Hero Banner ─────────────────────────── */
.hero-banner { position: relative; overflow: hidden; border-radius: 0; }
.hero-banner img { width: 100%; height: 400px; object-fit: cover; }
.hero-banner .overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to left, rgba(27,94,32,.7), transparent);
  display: flex;
  align-items: center;
  padding: 0 60px;
}
.hero-banner .overlay h2 { font-size: 2.5rem; font-weight: 800; color: #fff; margin: 0; }
.hero-banner .overlay p { font-size: 1.2rem; color: #c8e6c9; }

/* Carousel banners */
.banner-carousel .carousel-img { height: 380px; object-fit: cover; border-radius: var(--pp-radius); }

/* ── Section ─────────────────────────────── */
.section-title {
  font-size: 1.7rem;
  font-weight: 800;
  color: var(--pp-green-dark);
  position: relative;
  padding-bottom: 10px;
  margin-bottom: 24px;
}
.section-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  right: 0;
  width: 60px;
  height: 4px;
  background: var(--pp-green);
  border-radius: 2px;
}

/* ── Product Cards ───────────────────────── */
.product-card {
  background: #fff;
  border: 1px solid var(--pp-border);
  border-radius: var(--pp-radius);
  overflow: hidden;
  transition: transform .2s, box-shadow .2s;
  height: 100%;
}
.product-card:hover { transform: translateY(-4px); box-shadow: 0 8px 24px rgba(45,125,50,.18); }
.product-card .img-wrap {
  position: relative;
  height: 200px;
  overflow: hidden;
  background: #f0f4f0;
}
.product-card .img-wrap img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.product-card:hover .img-wrap img { transform: scale(1.05); }
.product-card .badge-sale {
  position: absolute;
  top: 10px;
  right: 10px;
  background: var(--pp-orange);
  color: #fff;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 700;
}
.product-card .badge-stock {
  position: absolute;
  top: 10px;
  left: 10px;
  background: rgba(0,0,0,.5);
  color: #fff;
  padding: 3px 8px;
  border-radius: 20px;
  font-size: 11px;
}
.product-card .card-body { padding: 14px; }
.product-card .card-title { font-size: 15px; font-weight: 700; margin-bottom: 6px; color: var(--pp-text); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.product-card .price { font-size: 18px; font-weight: 800; color: var(--pp-green); }
.product-card .price-old { font-size: 13px; color: #999; text-decoration: line-through; margin-right: 6px; }
.product-card .btn-add { width: 100%; margin-top: 10px; border-radius: 8px; }

/* ── Btn ─────────────────────────────────── */
.btn-primary { background: var(--pp-green); border-color: var(--pp-green); }
.btn-primary:hover { background: var(--pp-green-dark); border-color: var(--pp-green-dark); }
.btn-outline-primary { color: var(--pp-green); border-color: var(--pp-green); }
.btn-outline-primary:hover { background: var(--pp-green); border-color: var(--pp-green); }

/* ── Cart ────────────────────────────────── */
.cart-item { background: #fff; border: 1px solid var(--pp-border); border-radius: var(--pp-radius); padding: 15px; margin-bottom: 12px; }
.cart-item img { width: 80px; height: 80px; object-fit: cover; border-radius: 8px; }
.qty-control { display: flex; align-items: center; gap: 8px; }
.qty-control input { width: 55px; text-align: center; border: 1px solid #ddd; border-radius: 6px; padding: 4px; }
.qty-control button { width: 30px; height: 30px; border: 1px solid #ddd; background: #f5f5f5; border-radius: 6px; cursor: pointer; font-size: 16px; display: flex; align-items: center; justify-content: center; }
.cart-summary { background: #fff; border: 1px solid var(--pp-border); border-radius: var(--pp-radius); padding: 20px; }
.cart-summary .total-row { font-size: 1.2rem; font-weight: 800; color: var(--pp-green); border-top: 2px solid var(--pp-border); padding-top: 12px; margin-top: 12px; }

/* ── Forms ───────────────────────────────── */
.form-card { background: #fff; border: 1px solid var(--pp-border); border-radius: var(--pp-radius); padding: 30px; box-shadow: var(--pp-shadow); }
.form-label { font-weight: 600; margin-bottom: 4px; }
.form-control, .form-select { border-radius: 8px; border: 1.5px solid #d0d8d0; padding: 10px 14px; }
.form-control:focus, .form-select:focus { border-color: var(--pp-green); box-shadow: 0 0 0 3px rgba(45,125,50,.12); }

/* ── Order Tracking ──────────────────────── */
.tracking-steps { display: flex; gap: 0; margin: 30px 0; }
.tracking-step {
  flex: 1;
  text-align: center;
  position: relative;
}
.tracking-step::before {
  content: '';
  position: absolute;
  top: 22px;
  right: 50%;
  left: 0;
  height: 3px;
  background: #ddd;
  z-index: 0;
}
.tracking-step:first-child::before { display: none; }
.tracking-step .step-icon {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: #ddd;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 8px;
  position: relative;
  z-index: 1;
  font-size: 18px;
  color: #888;
  transition: all .3s;
}
.tracking-step.active .step-icon, .tracking-step.done .step-icon {
  background: var(--pp-green);
  color: #fff;
}
.tracking-step.done::before { background: var(--pp-green); }
.tracking-step .step-label { font-size: 12px; font-weight: 600; color: #888; }
.tracking-step.active .step-label, .tracking-step.done .step-label { color: var(--pp-green); }

/* ── Category List ───────────────────────── */
.category-sidebar { background: #fff; border: 1px solid var(--pp-border); border-radius: var(--pp-radius); overflow: hidden; }
.category-sidebar .cat-title { background: var(--pp-green); color: #fff; padding: 12px 16px; font-weight: 700; margin: 0; }
.category-sidebar ul { list-style: none; margin: 0; padding: 0; }
.category-sidebar ul li a { display: block; padding: 10px 16px; color: var(--pp-text); border-bottom: 1px solid #f0f4f0; transition: background .15s; }
.category-sidebar ul li a:hover, .category-sidebar ul li a.active { background: #e8f5e9; color: var(--pp-green); text-decoration: none; }
.category-sidebar ul li ul li a { padding-right: 28px; font-size: 14px; }

/* ── WhatsApp Button ─────────────────────── */
.whatsapp-float {
  position: fixed;
  bottom: 24px;
  left: 24px;
  z-index: 9000;
  width: 56px;
  height: 56px;
  background: #25d366;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(37,211,102,.5);
  transition: transform .2s;
  cursor: pointer;
}
.whatsapp-float:hover { transform: scale(1.1); }
.whatsapp-float svg { width: 32px; height: 32px; fill: #fff; }

/* ── Accessibility Button ────────────────── */
.accessibility-btn {
  position: fixed;
  bottom: 90px;
  left: 24px;
  z-index: 9001;
  width: 50px;
  height: 50px;
  background: #1a237e;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(26,35,126,.4);
  border: none;
  transition: transform .2s;
}
.accessibility-btn:hover { transform: scale(1.1); }
.accessibility-btn svg { width: 26px; height: 26px; fill: #fff; }

.accessibility-panel {
  position: fixed;
  bottom: 150px;
  left: 24px;
  z-index: 9002;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0,0,0,.2);
  padding: 16px;
  width: 230px;
  display: none;
}
.accessibility-panel.open { display: block; }
.accessibility-panel h6 { font-weight: 800; margin-bottom: 12px; color: #1a237e; }
.acc-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  padding: 8px 10px;
  border: 1px solid #ddd;
  border-radius: 8px;
  background: #f9f9ff;
  cursor: pointer;
  font-size: 13px;
  margin-bottom: 6px;
  transition: background .15s;
}
.acc-btn:hover { background: #e8eaf6; }
.acc-btn.active { background: #1a237e; color: #fff; border-color: #1a237e; }

/* ── Footer ──────────────────────────────── */
footer {
  background: var(--pp-green-dark);
  color: #c8e6c9;
  margin-top: 60px;
}
footer h5 { color: #fff; font-weight: 700; margin-bottom: 14px; }
footer a { color: #a5d6a7; }
footer a:hover { color: #fff; text-decoration: none; }
footer .footer-bottom { border-top: 1px solid rgba(255,255,255,.1); padding: 14px 0; font-size: 13px; color: #a5d6a7; }

/* ── Badges / Status ─────────────────────── */
.status-badge { padding: 4px 12px; border-radius: 20px; font-size: 12px; font-weight: 700; }

/* ── Accessibility Themes ────────────────── */
body.acc-large { font-size: 20px !important; }
body.acc-larger { font-size: 24px !important; }
body.acc-high-contrast { filter: contrast(1.5); }
body.acc-invert { filter: invert(1) hue-rotate(180deg); }
body.acc-grayscale { filter: grayscale(1); }
body.acc-highlight-links a { outline: 2px solid #ff0 !important; text-decoration: underline !important; }
body.acc-dyslexia * { font-family: 'Comic Sans MS', 'OpenDyslexic', Arial, sans-serif !important; letter-spacing: .05em; word-spacing: .1em; }
body.acc-no-anim * { animation: none !important; transition: none !important; }

/* ── Responsive ──────────────────────────── */
@media (max-width: 768px) {
  .hero-banner img { height: 220px; }
  .hero-banner .overlay h2 { font-size: 1.5rem; }
  .hero-banner .overlay { padding: 0 20px; }
  .whatsapp-float { bottom: 16px; left: 16px; width: 48px; height: 48px; }
  .accessibility-btn { bottom: 74px; left: 16px; }
  .accessibility-panel { left: 10px; width: calc(100vw - 20px); }
  .tracking-step .step-label { font-size: 10px; }
}

/* ── Admin Flash ─────────────────────────── */
.page-header { border-bottom: 2px solid var(--pp-border); padding-bottom: 14px; margin-bottom: 24px; }
.stats-card { background: #fff; border-radius: var(--pp-radius); border: 1px solid var(--pp-border); padding: 20px; text-align: center; }
.stats-card .num { font-size: 2.2rem; font-weight: 800; color: var(--pp-green); }
.stats-card .lbl { color: #666; font-size: 14px; }
