/* ===============================
   DESIGN SYSTEM
================================ */
:root {
  --primary: #0b6623;
  --primary-light: #158f3d;
  --accent: #ff9800;
  --bg: #f6f7f9;
  --card-bg: #ffffff;
  --text-main: #1f2937;
  --text-muted: #6b7280;

  --radius-lg: 18px;
  --radius-md: 12px;

  --shadow-soft: 0 10px 30px rgba(0,0,0,0.08);
  --shadow-hover: 0 20px 45px rgba(0,0,0,0.15);
}

/* ===============================
   BASE
================================ */
* {
  box-sizing: border-box;
  font-family: 'Segoe UI', sans-serif;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text-main);
}

/* ===============================
   NAVBAR
================================ */
.navbar {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: white;
  padding: 20px 40px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 4px 15px rgba(0,0,0,0.05);
  flex-wrap: wrap;
}

.logo {
  font-weight: 800;
  font-size: 1.2rem;
}

.navbar a {
  color: var(--text-main);
  margin-left: 20px;
  text-decoration: none;
  font-weight: 600;
}

.navbar a:hover {
  color: var(--primary);
}

.cart {
  cursor: pointer;
  font-weight: bold;
  background: var(--primary);
  color: white;
  padding: 10px 16px;
  border-radius: 25px;
}

/* ===============================
   HERO
================================ */
.hero {
  padding: 100px 20px;
  text-align: center;
  background: linear-gradient(
    135deg,
    var(--primary),
    var(--primary-light)
  );
  color: white;
}

.hero h1 {
  font-size: 3.2rem;
  font-weight: 800;
  margin-bottom: 10px;
}

.hero p {
  font-size: 1.2rem;
  opacity: 0.95;
}

.badge {
  display: inline-block;
  margin-top: 20px;
  padding: 12px 24px;
  background: white;
  color: var(--primary);
  border-radius: 30px;
  font-weight: bold;
}

/* ===============================
   ABOUT US + WHY CHOOSE US
================================ */
.about-us {
  background: white;
  padding: 80px 40px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
  margin: 60px 20px;
  text-align: center;
  opacity: 0;
  transform: translateY(50px);
  transition: opacity 1s ease, transform 1s ease;
}

.about-us.visible {
  opacity: 1;
  transform: translateY(0);
}

.about-us h2 {
  font-size: 2.4rem;
  color: var(--primary);
  margin-bottom: 20px;
}

.about-us p {
  font-size: 1rem;
  color: var(--text-main);
  max-width: 700px;
  margin: 0 auto 40px;
  line-height: 1.6;
}

/* WHY CHOOSE US */
.why-choose-us h3 {
  font-size: 1.8rem;
  color: var(--primary);
  margin-bottom: 30px;
}

.features {
  display: flex;
  gap: 25px;
  justify-content: center;
  flex-wrap: wrap;
}

.feature-card {
  background: var(--card-bg);
  border-radius: var(--radius-lg);
  padding: 25px;
  width: 260px;
  box-shadow: var(--shadow-soft);
  transition: transform 0.4s ease, box-shadow 0.4s ease;
  cursor: pointer;
}

.feature-card:hover {
  transform: translateY(-10px) scale(1.05);
  box-shadow: var(--shadow-hover);
}

.feature-card img {
  width: 200px;
  margin-bottom: 15px;
}

.feature-card h4 {
  font-size: 1.1rem;
  color: var(--primary);
  margin-bottom: 10px;
}

.feature-card p {
  font-size: 0.95rem;
  color: var(--text-main);
  line-height: 1.4;
}

/* MOBILE */
@media (max-width: 900px) {
  .features {
    flex-direction: column;
    align-items: center;
  }
  .feature-card {
    width: 80%;
    margin-bottom: 20px;
  }
}

@media (max-width: 600px) {
  .about-us {
    padding: 40px 20px;
  }
  .about-us h2 {
    font-size: 1.8rem;
  }
  .why-choose-us h3 {
    font-size: 1.5rem;
  }
}


/* ===============================
   SLIDE-IN & BOUNCE ANIMATIONS
================================ */
.slide-left, .slide-right, .bounce {
  opacity: 0;
  transform: translateX(0);
  transition: all 1s ease;
}

.slide-left.visible {
  opacity: 1;
  transform: translateX(0); /* center */
  animation: slideFromLeft 1s forwards;
}

.slide-right.visible {
  opacity: 1;
  transform: translateX(0); /* center */
  animation: slideFromRight 1s forwards;
}

.bounce.visible {
  opacity: 1;
  animation: bounceUp 1s forwards;
}

/* Slide in from left */
@keyframes slideFromLeft {
  0% { transform: translateX(-100px); opacity: 0; }
  60% { transform: translateX(15px); opacity: 1; }
  80% { transform: translateX(-5px); }
  100% { transform: translateX(0); }
}

/* Slide in from right */
@keyframes slideFromRight {
  0% { transform: translateX(100px); opacity: 0; }
  60% { transform: translateX(-15px); opacity: 1; }
  80% { transform: translateX(5px); }
  100% { transform: translateX(0); }
}

/* Small bounce effect for feature cards */
@keyframes bounceUp {
  0% { transform: translateY(30px); opacity: 0; }
  60% { transform: translateY(-10px); opacity: 1; }
  80% { transform: translateY(5px); }
  100% { transform: translateY(0); }
}


/* ===============================
   FILTERS
================================ */
.filters {
  display: flex;
  gap: 15px;
  justify-content: center;
  padding: 40px 40px 0;
  flex-wrap: wrap;
}

.filters input,
.filters select {
  padding: 14px 16px;
  border-radius: var(--radius-md);
  border: 1px solid #ccc;
  min-width: 220px;
  font-size: 0.95rem;
}

.filters input:focus,
.filters select:focus {
  outline: none;
  border-color: var(--primary);
}

/* ===============================
   PRODUCTS GRID
================================ */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 28px;
  padding: 60px 40px;
}

/* ===============================
   PRODUCT CARD
================================ */
.card {
  background: var(--card-bg);
  border-radius: var(--radius-lg);
  padding: 16px;
  text-align: center;
  box-shadow: var(--shadow-soft);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
  transform: translateY(-10px);
  box-shadow: var(--shadow-hover);
}

.card img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-radius: var(--radius-md);
}

.card h3 {
  font-size: 1.05rem;
  margin: 12px 0 6px;
}

.price {
  font-size: 1.2rem;
  font-weight: bold;
  color: var(--primary);
  margin-bottom: 10px;
}

/* ===============================
   BUTTONS
================================ */
button {
  width: 100%;
  background: var(--accent);
  color: white;
  font-weight: bold;
  border: none;
  padding: 14px;
  border-radius: 14px;
  cursor: pointer;
  font-size: 0.95rem;
  transition: background 0.3s, transform 0.2s, opacity 0.2s;
}

button:hover {
  background: #ffb300;
}

button:active {
  transform: scale(0.97);
}

button:disabled {
  opacity: 0.85;
  cursor: not-allowed;
}

/* ===============================
   CART PANEL (FIXED)
================================ */
.cart-panel {
  position: fixed;
  top: 100px; /* distance from top of the page */
  right: 20px;
  width: 300px;
  max-height: 70vh;
  overflow-y: auto;
  background: white;
  padding: 25px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
  z-index: 1001;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

/* optional: initially hidden on mobile */
@media (max-width: 900px) {
  .cart-panel {
    position: static;
    width: auto;
    max-height: none;
    margin: 20px;
  }
}

.cart-item {
  display: flex;
  justify-content: space-between;
  padding: 12px 0;
  border-bottom: 1px solid #eee;
  font-size: 0.95rem;
}

.cart-summary {
  margin: 20px 0;
  font-size: 1.2rem;
  font-weight: bold;
}

.cart-actions button {
  width: auto;
  padding: 6px 10px;
  font-size: 0.9rem;
  border-radius: 8px;
}



/* ===============================
   CHECKOUT
================================ */
.checkout {
  max-width: 500px;
  margin: 80px auto;
  background: white;
  padding: 40px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
  border-top: 6px solid var(--primary);
}

.checkout input {
  width: 100%;
  padding: 15px;
  margin-bottom: 15px;
  border-radius: var(--radius-md);
  border: 1px solid #ccc;
  font-size: 0.95rem;
}

.checkout input:focus {
  outline: none;
  border-color: var(--primary);
}

.delivery-note {
  font-weight: bold;
  margin-bottom: 15px;
  color: var(--primary);
}

.checkout textarea {
  width: 100%;
  padding: 15px;
  margin-bottom: 15px;
  border-radius: var(--radius-md);
  border: 1px solid #ccc;
  font-size: 0.95rem;
  resize: vertical;
}

.checkout textarea:focus {
  outline: none;
  border-color: var(--primary);
}


/* ===============================
   ORDER SUCCESS
================================ */
.order-success {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
}

.success-card {
  background: white;
  padding: 40px;
  border-radius: var(--radius-lg);
  text-align: center;
  max-width: 400px;
  box-shadow: var(--shadow-hover);
}

.success-card h2 {
  color: var(--primary);
}

/* ===============================
   FOOTER
================================ */
footer {
  text-align: center;
  padding: 30px;
  background: #111;
  color: #aaa;
}

.footer-contact {
  margin-top: 15px;
  display: flex;
  justify-content: center;
  gap: 15px;
  flex-wrap: wrap;
}

.whatsapp-footer,
.email-footer {
  padding: 10px 18px;
  border-radius: 25px;
  font-weight: bold;
  text-decoration: none;
  color: white;
}

.whatsapp-footer {
  background: #25d366;
}

.email-footer {
  background: #333;
}

/* ===============================
   MOBILE
================================ */
@media (max-width: 600px) {
  .hero h1 {
    font-size: 2.2rem;
  }

  .product-grid {
    padding: 40px 20px;
  }

  .checkout {
    margin: 40px 20px;
    padding: 30px;
  }
}


/* ===============================
   CART ITEM CONTROLS
================================ */
.cart-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}

.cart-controls {
  display: flex;
  gap: 6px;
}

.cart-controls button {
  width: auto;
  padding: 4px 8px;
  font-size: 0.85rem;
  border-radius: 6px;
  background: var(--primary);
}

.cart-controls button.remove {
  background: #e53935;
}

/* ===============================
   ADD TO CART FEEDBACK
================================ */
button.added {
  background: var(--primary-light) !important;
}

/* ===============================
   FLOATING MOBILE CART BUTTON
================================ */
.floating-cart {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: var(--primary);
  color: white;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  font-size: 26px;
  display: none; /* hidden by default */
  justify-content: center;
  align-items: center;
  box-shadow: var(--shadow-hover);
  cursor: pointer;
  z-index: 2000;
}

.floating-cart span {
  position: absolute;
  top: -6px;
  right: -6px;
  background: #ff3d00;
  color: white;
  font-size: 12px;
  font-weight: bold;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Show floating cart ONLY on mobile */
@media (max-width: 768px) {
  .floating-cart {
    display: flex;
  }

  /* Optional: hide navbar cart on mobile */
  .navbar .cart {
    display: none;
  }
}

.price {
  display: flex;
  gap: 8px;
  align-items: center;
}

.old-price {
  text-decoration: line-through;
  color: #9ca3af;
  font-size: 0.9rem;
}

.new-price {
  color: #0b5cff;
  font-weight: 700;
}

.old-price::after {
  content: " SALE";
  color: #ef4444;
  font-size: 0.7rem;
  font-weight: bold;
}
