/* ==========================================================================
   A2 SUNDRIES — STYLESHEET
   Colors taken from the logo: forest green + orange on a clean white/cream base.
   ========================================================================== */

:root {
  --green:      #0e5a2b;
  --green-deep: #073b1c;
  --green-soft: #e6f1e9;
  --orange:     #ee6b0f;
  --orange-deep:#c9560a;
  --cream:      #f6f8f3;
  --paper:      #ffffff;
  --ink:        #17251c;
  --ink-soft:   #5b6b60;
  --line:       rgba(14, 90, 43, 0.16);

  --font: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --r-lg: 18px;
  --r-md: 12px;
  --shadow: 0 10px 28px -16px rgba(7, 59, 28, 0.45);
}

/* ---------- Base ---------- */
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
button, input, textarea, select { font-family: inherit; }
h1, h2, h3, p { margin: 0; }

/* ---------- Header ---------- */
.site-header {
  background: var(--paper);
  border-bottom: 4px solid var(--green);
  padding: 14px 16px;
}
.header-inner {
  max-width: 1080px; margin: 0 auto;
  display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px;
}
.brand-logo { width: 84px; height: 84px; flex-shrink: 0; }
.brand-logo img { width: 100%; height: 100%; object-fit: contain; border-radius: 50%; }
.brand-copy { flex: 1 1 180px; min-width: 0; }
.brand-name { font-size: clamp(24px, 6vw, 34px); font-weight: 800; color: var(--green); line-height: 1.1; }
.brand-tagline { font-size: 13.5px; font-weight: 600; color: var(--orange); margin-top: 2px; }
.brand-sub { font-size: 12.5px; color: var(--ink-soft); }

/* ==========================================================================
   HEADER: OPENING HOURS + PHONE (simple, no boxes)
   Paste this block at the very bottom of style.css (after everything else).
   If you pasted the earlier version, delete it first and use this one instead.
   ========================================================================== */

.header-strip-item {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1 1 100%;
  padding: 0;
  background: none;
  border: 0;
  font-size: 13.5px;
  font-weight: 500;
  line-height: 1.5;
  color: var(--green-deep);
}

.header-icon {
  flex: 0 0 auto;
  font-size: 16px;
  line-height: 1;
}

/* Phone number: plain text, not styled like a link */
.header-strip-item a {
  color: var(--green-deep);
  font-weight: 600;
  font-size: 14px;
  text-decoration: none;
}

/* Larger screens: sit on the right of the logo and name */
@media (min-width: 900px) {
  .header-strip-item { flex: 0 0 auto; }
}
/* ---------- Sticky search + categories ---------- */
.shop-bar {
  position: sticky; top: 0; z-index: 50;
  background: var(--green);
  box-shadow: 0 6px 18px -10px rgba(7, 59, 28, 0.7);
}
.shop-bar-inner { max-width: 1080px; margin: 0 auto; padding: 10px 16px 4px; }

.search-wrap { position: relative; }
.search-icon { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); font-size: 14px; pointer-events: none; }
.search-input {
  width: 100%; height: 44px; padding: 0 40px 0 40px;
  border: 0; border-radius: 999px; background: var(--paper); color: var(--ink);
  font-size: 14px;
}
.search-input:focus-visible { outline: 3px solid var(--orange); outline-offset: 1px; }
.search-input::-webkit-search-cancel-button { display: none; }
.search-clear {
  position: absolute; right: 8px; top: 50%; transform: translateY(-50%);
  width: 28px; height: 28px; border: 0; border-radius: 50%; cursor: pointer;
  background: var(--green-soft); color: var(--green); font-size: 13px;
}

.category-nav-scroll {
  display: flex; gap: 8px; overflow-x: auto; -webkit-overflow-scrolling: touch;
  padding: 8px 16px 12px; scrollbar-width: none;
}
.category-nav-scroll::-webkit-scrollbar { display: none; }
.nav-pill:first-child { margin-left: auto; }
.nav-pill:last-child { margin-right: auto; }
.nav-pill {
  flex-shrink: 0; cursor: pointer; white-space: nowrap;
  min-height: 36px; padding: 6px 15px;
  border: 1.5px solid rgba(255, 255, 255, 0.55); background: transparent; color: #fff;
  font-weight: 500; font-size: 13px; border-radius: 999px;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}
.nav-pill:hover { background: rgba(255, 255, 255, 0.15); }
.nav-pill.active { background: var(--orange); border-color: var(--orange); color: #fff; font-weight: 600; }
.nav-pill:focus-visible { outline: 3px solid #fff; outline-offset: 2px; }

/* ---------- Products ---------- */
.products { max-width: 1080px; margin: 0 auto; padding: 8px 14px 120px; }

.category-section { margin-top: 28px; scroll-margin-top: 120px; }
.category-heading {
  display: flex; align-items: baseline; gap: 10px;
  font-size: clamp(1.15rem, 3.8vw, 1.5rem); font-weight: 700; color: var(--green);
  padding-bottom: 8px; margin-bottom: 12px; border-bottom: 2px solid var(--orange);
}
.category-count { font-size: 12px; font-weight: 500; color: var(--ink-soft); }

.product-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }

.product-card {
  display: flex; flex-direction: column; justify-content: space-between; gap: 10px;
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--r-md);
  padding: 12px; box-shadow: 0 2px 10px -8px rgba(7, 59, 28, 0.5);
  transition: border-color 0.2s ease;
}
.product-card.in-cart { border-color: var(--green); box-shadow: 0 0 0 1px var(--green); }
.product-name { font-size: 13.5px; font-weight: 600; line-height: 1.35; overflow-wrap: anywhere; }
.product-price { font-size: 15px; font-weight: 700; color: var(--green); margin-top: 2px; white-space: nowrap; }

.add-btn {
  width: 100%; min-height: 38px; border: 1.5px solid var(--orange); border-radius: 999px;
  background: transparent; color: var(--orange-deep); font-weight: 600; font-size: 13px; cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease, transform 0.15s ease;
}
.add-btn:hover { background: var(--orange); color: #fff; }
.add-btn:active { transform: scale(0.97); }
.add-btn.added { background: var(--green); border-color: var(--green); color: #fff; }

.stepper {
  display: flex; align-items: center; justify-content: space-between;
  min-height: 38px; border-radius: 999px; background: var(--green); color: #fff; padding: 3px;
}
.stepper button {
  width: 32px; height: 32px; border: 0; border-radius: 50%; cursor: pointer;
  background: rgba(255, 255, 255, 0.18); color: #fff; font-size: 18px; font-weight: 600; line-height: 1;
}
.stepper button:active { transform: scale(0.92); }
.stepper span { font-weight: 700; font-size: 14px; min-width: 24px; text-align: center; }

.no-results { text-align: center; color: var(--ink-soft); padding: 40px 20px 120px; }

/* ---------- Footer ---------- */
.site-footer { background: var(--green-deep); color: #fff; text-align: center; padding: 28px 16px 110px; }
.footer-name { font-weight: 700; font-size: 1.1rem; color: #fff; }
.footer-tagline { font-size: 0.85rem; color: rgba(255, 255, 255, 0.8); margin-top: 2px; }
.footer-copyright { font-size: 0.78rem; color: rgba(255, 255, 255, 0.6); margin-top: 14px; }

/* ---------- Cart button (small, bottom-right) ---------- */
.cart-bar {
  position: fixed; right: 14px; bottom: calc(14px + env(safe-area-inset-bottom)); z-index: 80;
  display: flex; align-items: center; gap: 8px;
  background: var(--orange); color: #fff; border: 0; border-radius: 999px;
  padding: 9px 14px; font-weight: 600; font-size: 13px; cursor: pointer;
  box-shadow: 0 8px 20px rgba(7, 59, 28, 0.35);
  transition: transform 0.15s ease;
}
.cart-bar:hover { transform: translateY(-2px); }
.cart-bar-left { display: flex; align-items: center; gap: 6px; font-size: 16px; line-height: 1; }
.cart-bar-count {
  min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px;
  background: #fff; color: var(--orange-deep); font-size: 12px; font-weight: 700;
  display: inline-flex; align-items: center; justify-content: center;
}
.cart-bar-total { font-weight: 700; font-size: 12.5px; }

/* ---------- Overlay + drawer ---------- */
.cart-overlay { position: fixed; inset: 0; z-index: 90; background: rgba(7, 30, 16, 0.55); opacity: 0; transition: opacity 0.25s ease; }
.cart-overlay.visible { opacity: 1; }
body.cart-open { overflow: hidden; }

.cart-drawer {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 100;
  display: flex; flex-direction: column;
  max-height: 92vh; max-height: 92dvh;
  background: var(--paper); border-radius: 20px 20px 0 0;
  box-shadow: 0 -8px 30px rgba(7, 59, 28, 0.3);
  transform: translateY(100%); transition: transform 0.28s ease;
}
.cart-drawer.open { transform: translateY(0); }

.cart-drawer-header {
  flex: 0 0 auto; display: flex; align-items: center; justify-content: space-between;
  padding: 16px 18px 12px; border-bottom: 1px solid var(--line);
}
.cart-drawer-header h2 { font-size: 1.15rem; font-weight: 700; color: var(--green); }
.cart-close-btn {
  width: 34px; height: 34px; border: 0; border-radius: 50%; cursor: pointer;
  background: var(--green-soft); color: var(--green); font-size: 16px;
}

.cart-body { flex: 1 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain; }
.cart-items { display: flex; flex-direction: column; gap: 10px; padding: 12px 18px; }

.cart-item {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  background: var(--cream); border: 1px solid var(--line); border-radius: var(--r-md); padding: 12px 14px;
}
.cart-item-info { min-width: 0; flex: 1 1 auto; }
.cart-item-name { font-weight: 600; font-size: 14px; line-height: 1.35; overflow-wrap: anywhere; }
.cart-item-unit-price { font-size: 12px; color: var(--ink-soft); margin-top: 2px; }
.cart-item-controls { flex: 0 0 auto; display: flex; flex-direction: column; align-items: flex-end; gap: 6px; }
.cart-qty { display: flex; align-items: center; gap: 8px; }
.cart-qty-btn {
  width: 30px; height: 30px; flex: 0 0 30px; border-radius: 50%; cursor: pointer;
  border: 1.5px solid var(--green); background: var(--paper); color: var(--green);
  font-size: 16px; font-weight: 700; line-height: 1;
  display: flex; align-items: center; justify-content: center;
}
.cart-qty-value { min-width: 18px; text-align: center; font-weight: 600; font-size: 14px; }
.cart-item-subtotal { font-weight: 700; font-size: 14px; color: var(--green); white-space: nowrap; }
.cart-remove-btn { border: 0; background: none; padding: 2px; cursor: pointer; font-size: 11.5px; color: var(--ink-soft); text-decoration: underline; }

.cart-empty { padding: 40px 24px 44px; text-align: center; color: var(--ink-soft); }
.cart-empty p { margin-bottom: 16px; }
.cart-browse-btn {
  padding: 10px 22px; border: 1.5px solid var(--green); background: transparent; color: var(--green);
  font-weight: 600; font-size: 14px; border-radius: 999px; cursor: pointer;
}

/* ---------- Order details ---------- */
.cart-footer { padding: 6px 18px calc(18px + env(safe-area-inset-bottom)); }
.order-details-box {
  position: relative; margin-bottom: 14px; padding: 16px 16px 14px;
  background: var(--cream); border: 1.5px solid var(--line); border-radius: var(--r-lg);
}
.order-details-box::before {
  content: ""; position: absolute; top: 10px; bottom: 10px; left: 0; width: 4px;
  border-radius: 0 4px 4px 0; background: var(--orange);
}
.order-type-label { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; font-weight: 600; font-size: 13px; color: var(--green-deep); }
.order-type-label-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--orange); }

.order-type-options { display: grid; grid-template-columns: repeat(2, 1fr); gap: 9px; }
.order-type-btn {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  min-height: 70px; padding: 10px 4px; cursor: pointer; text-align: center;
  border: 1.5px solid var(--line); background: var(--paper); color: var(--ink-soft);
  font-weight: 600; font-size: 13px; border-radius: var(--r-md);
  transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease, transform 0.15s ease;
}
.order-type-icon { font-size: 20px; line-height: 1; }
.order-type-btn:hover { border-color: var(--green); }
.order-type-btn:active { transform: scale(0.96); }
.order-type-btn.active { background: var(--green); border-color: var(--green); color: #fff; }
.order-type-hint { margin-top: 10px; font-size: 11.5px; color: var(--ink-soft); font-style: italic; }

.order-details-divider { height: 1px; margin: 14px 2px 12px; background: var(--line); }

.cart-customer-fields, .cart-group { display: flex; flex-direction: column; gap: 8px; }
.cart-input-label { font-size: 12.5px; font-weight: 600; color: var(--green-deep); margin-bottom: -4px; }
.cart-input {
  width: 100%; min-height: 42px; padding: 10px 12px;
  border: 1.5px solid var(--line); border-radius: var(--r-md);
  background: var(--paper); color: var(--ink); font-size: 13.5px;
}
.cart-select { appearance: auto; cursor: pointer; }
.cart-input:focus-visible { outline: 3px solid var(--green); outline-offset: 1px; }
.cart-textarea { min-height: 82px; resize: none; overflow: hidden; line-height: 1.45; }
.cart-textarea::placeholder { color: var(--ink-soft); opacity: 0.8; }

/* ---------- Totals + WhatsApp ---------- */
.cart-total-breakdown { margin-bottom: 12px; }
.cart-total-line { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 4px 0; font-size: 14px; }
.cart-grand-total {
  margin-top: 6px; padding-top: 10px; border-top: 1px solid var(--line);
  font-weight: 700; font-size: 17px; color: var(--green);
}
.whatsapp-btn {
  display: block; width: 100%; min-height: 48px; margin-bottom: 8px; padding: 14px 16px;
  border: 0; border-radius: 999px; cursor: pointer;
  background: #25D366; color: #06210F; font-weight: 700; font-size: 15.5px;
}
.whatsapp-btn:disabled { opacity: 0.5; cursor: not-allowed; }
.whatsapp-btn:not(:disabled):hover { filter: brightness(1.05); }
.whatsapp-hint { margin-bottom: 10px; font-size: 11.5px; line-height: 1.4; color: var(--ink-soft); text-align: center; }
.clear-cart-btn { display: block; width: 100%; padding: 6px; border: 0; background: none; cursor: pointer; font-size: 12.5px; color: var(--ink-soft); text-decoration: underline; }

/* ---------- Larger screens ---------- */
@media (min-width: 640px) {
  .product-grid { grid-template-columns: repeat(3, 1fr); gap: 12px; }
  .brand-logo { width: 100px; height: 100px; }
}
@media (min-width: 900px) {
  .product-grid { grid-template-columns: repeat(4, 1fr); }
}
@media (min-width: 700px) {
  .cart-drawer {
    left: 50%; right: auto; bottom: 50%;
    width: 440px; max-width: calc(100vw - 40px); max-height: 85vh;
    border-radius: var(--r-lg);
    transform: translate(-50%, 50%) scale(0.96); opacity: 0;
    transition: transform 0.25s ease, opacity 0.25s ease;
  }
  .cart-drawer.open { transform: translate(-50%, 50%) scale(1); opacity: 1; }
}
@media (max-width: 380px) {
  .product-card { padding: 10px; }
  .product-name { font-size: 12.5px; }
  .cart-items { padding: 10px 14px; }
  .cart-footer { padding-left: 14px; padding-right: 14px; }
  .order-details-box { padding: 13px 12px 12px; }
}
