/* ================= RESET & VARIABLES ================= */
:root {
  --cream: #faf7f2;
  --ivory: #fffdfa;
  --forest: #2b3d34;
  --forest-light: #4a6357;
  --sage: #a9c5b5;
  --sage-dark: #7ea892;
  --gold: #c9a96e;
  --gold-dark: #b0894f;
  --line: #e7e0d4;
  --radius: 18px;
  --shadow-sm: 0 4px 16px rgba(43, 61, 52, 0.06);
  --shadow-md: 0 12px 32px rgba(43, 61, 52, 0.1);
  --shadow-lg: 0 24px 60px rgba(43, 61, 52, 0.16);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  background: var(--cream);
  color: var(--forest);
  font-family: "Poppins", sans-serif;
  line-height: 1.6;
  font-weight: 300;
}

h1, h2, h3 {
  font-family: "Cormorant Garamond", serif;
  font-weight: 600;
  color: var(--forest);
}

a { text-decoration: none; }

img { max-width: 100%; display: block; }

/* ================= NAVBAR ================= */

header {
  position: sticky;
  top: 0;
  z-index: 900;
  background: rgba(250, 247, 242, 0.9);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}

.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  padding: 18px 40px;
  max-width: 1400px;
  margin: auto;
}

.nav-brand a {
  font-family: "Cormorant Garamond", serif;
  font-size: 28px;
  font-weight: 700;
  color: var(--forest);
  letter-spacing: 0.5px;
}

.nav-brand span { color: var(--gold-dark); }

.nav-center {
  display: flex;
  align-items: center;
  gap: 36px;
}

.nav-center > a {
  color: var(--forest);
  font-weight: 500;
  font-size: 15px;
  position: relative;
}

.nav-center > a::after {
  content: "";
  position: absolute;
  width: 0;
  height: 2px;
  left: 0;
  bottom: -6px;
  background: var(--gold-dark);
  transition: width 0.3s ease;
}

.nav-center > a:hover::after { width: 100%; }

.nav-search {
  display: flex;
  align-items: center;
  background: var(--ivory);
  border: 1px solid var(--line);
  border-radius: 30px;
  padding: 4px 4px 4px 16px;
}

#searchInput {
  border: none;
  outline: none;
  background: transparent;
  font-family: inherit;
  font-size: 14px;
  width: 170px;
  color: var(--forest);
}

.search-btn {
  background: var(--forest);
  color: var(--ivory);
  border: none;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.3s ease;
  flex-shrink: 0;
}

.search-btn:hover { background: var(--gold-dark); }

.nav-right { display: flex; align-items: center; }

.cart-container { position: relative; display: inline-block; }

#cart-btn {
  background: var(--forest);
  color: var(--ivory);
  border: none;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
}

#cart-btn:hover {
  background: var(--gold-dark);
  transform: translateY(-2px);
}

.cart-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  background: var(--gold-dark);
  color: white;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 600;
  border: 2px solid var(--cream);
}

.menu-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}

.menu-toggle span {
  width: 24px;
  height: 2px;
  background: var(--forest);
  border-radius: 2px;
}

/* ================= HERO ================= */

.hero {
  min-height: 88vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 40px 20px;
  background:
    radial-gradient(circle at 15% 20%, rgba(169, 197, 181, 0.35), transparent 45%),
    radial-gradient(circle at 85% 80%, rgba(201, 169, 110, 0.2), transparent 50%),
    var(--ivory);
  position: relative;
  overflow: hidden;
}

.hero-content { max-width: 640px; position: relative; z-index: 1; }

.hero-eyebrow {
  text-transform: uppercase;
  letter-spacing: 4px;
  font-size: 13px;
  color: var(--gold-dark);
  font-weight: 600;
  margin-bottom: 18px;
}

.hero h1 {
  font-size: clamp(42px, 8vw, 76px);
  line-height: 1.05;
  margin-bottom: 24px;
}

.hero p {
  font-size: 18px;
  margin-bottom: 36px;
  color: var(--forest-light);
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
}

.hero-btn {
  display: inline-block;
  padding: 17px 42px;
  background: var(--forest);
  color: var(--ivory);
  border-radius: 40px;
  font-weight: 600;
  font-size: 15px;
  letter-spacing: 0.3px;
  transition: all 0.35s ease;
  box-shadow: var(--shadow-md);
}

.hero-btn:hover {
  background: var(--gold-dark);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

/* ================= SECTION HEADINGS ================= */

.section-heading {
  text-align: center;
  max-width: 600px;
  margin: 0 auto 55px;
}

.section-eyebrow {
  text-transform: uppercase;
  letter-spacing: 4px;
  font-size: 12px;
  color: var(--gold-dark);
  font-weight: 600;
  margin-bottom: 12px;
}

.section-heading h2 { font-size: clamp(30px, 4vw, 42px); }

/* ================= PRODUCTS ================= */

.products {
  padding: 100px 40px;
  max-width: 1400px;
  margin: auto;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 32px;
}

.card {
  background: var(--ivory);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
  text-align: center;
  transition: all 0.4s cubic-bezier(.2,.8,.2,1);
  display: flex;
  flex-direction: column;
}

.card img {
  width: 100%;
  height: 200px;
  object-fit: contain;
  border-radius: 12px;
  margin-bottom: 16px;
  background: var(--cream);
}

.stars {
  color: var(--gold-dark);
  font-size: 15px;
  letter-spacing: 2px;
  margin-bottom: 8px;
}

.card h3 {
  font-size: 19px;
  margin-bottom: 6px;
  font-weight: 600;
}

.card .price {
  font-size: 16px;
  color: var(--forest-light);
  font-weight: 500;
  margin-bottom: 16px;
}

.card button {
  margin-top: auto;
  background: transparent;
  color: var(--forest);
  border: 1.5px solid var(--forest);
  padding: 11px 20px;
  border-radius: 30px;
  cursor: pointer;
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.3px;
  transition: all 0.3s ease;
}

.card button:hover {
  background: var(--forest);
  color: var(--ivory);
}

.card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
  border-color: transparent;
}

/* ================= CART PANEL ================= */

.cart-overlay {
  position: fixed;
  top: 0;
  right: -420px;
  width: 400px;
  max-width: 90vw;
  height: 100vh;
  background: var(--ivory);
  z-index: 1100;
  transition: right 0.4s cubic-bezier(.2,.8,.2,1);
  overflow-y: auto;
  padding: 30px;
  box-shadow: -20px 0 50px rgba(0,0,0,0.15);
  display: flex;
  flex-direction: column;
}

.cart-overlay.active { right: 0; }

.cart-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(43,61,52,0.4);
  z-index: 1050;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
}

.cart-backdrop.active {
  opacity: 1;
  pointer-events: auto;
}

.cart-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.cart-header h2 { font-size: 26px; }

.close {
  cursor: pointer;
  font-size: 26px;
  line-height: 1;
  color: var(--forest-light);
}

#cart-items { flex: 1; }

.cart-empty {
  text-align: center;
  color: var(--forest-light);
  padding: 40px 0;
  display: none;
}

.cart-empty.show { display: block; }

.cart-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}

.cart-info strong { font-weight: 600; font-size: 14px; }
.cart-info div { font-size: 13px; color: var(--forest-light); margin-top: 2px; }

.cart-controls {
  display: flex;
  align-items: center;
  gap: 10px;
}

.cart-controls button {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--cream);
  cursor: pointer;
  font-size: 14px;
}

.cart-item .remove-btn {
  background: none;
  border: none;
  color: var(--forest-light);
  cursor: pointer;
  font-size: 16px;
}

.cart-total {
  margin-top: 10px;
  font-weight: 600;
  font-size: 18px;
  text-align: right;
}

.cart-buttons {
  margin-top: 20px;
  display: flex;
  gap: 10px;
}

.cart-buttons button { flex: 1; }

.continue-btn {
  background: var(--cream);
  border: 1px solid var(--line);
  padding: 14px;
  border-radius: 30px;
  cursor: pointer;
  font-weight: 600;
  color: var(--forest);
}

.buy-btn {
  background: var(--forest);
  color: var(--ivory);
  border: none;
  padding: 14px;
  border-radius: 30px;
  cursor: pointer;
  font-weight: 600;
  transition: 0.3s ease;
}

.buy-btn:hover { background: var(--gold-dark); }

/* ================= CHECKOUT MODAL ================= */

.checkout-modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(43,61,52,0.55);
  justify-content: center;
  align-items: center;
  z-index: 1200;
  padding: 20px;
}

.checkout-modal.active { display: flex; }

.checkout-content {
  background: var(--ivory);
  padding: 40px;
  border-radius: 24px;
  width: 100%;
  max-width: 450px;
  position: relative;
}

.checkout-content h2 {
  margin-bottom: 22px;
  text-align: center;
  font-size: 28px;
}

.checkout-content form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.checkout-content input,
.checkout-content select {
  padding: 13px 16px;
  border-radius: 10px;
  border: 1px solid var(--line);
  font-size: 14px;
  font-family: inherit;
  background: var(--cream);
}

.checkout-content input:focus,
.checkout-content select:focus {
  outline: none;
  border-color: var(--gold-dark);
}

/* ================= CONTACT ================= */

.contact {
  padding: 100px 40px;
  background: linear-gradient(to bottom, var(--ivory), var(--cream));
}

.contact-wrapper {
  max-width: 1100px;
  margin: auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.contact-info h2 { font-size: 38px; margin-bottom: 16px; }

.contact-info p {
  font-size: 16px;
  color: var(--forest-light);
  margin-bottom: 20px;
}

.contact-details {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.contact-details li {
  font-weight: 500;
  color: var(--forest);
}

.contact form {
  background: var(--ivory);
  padding: 34px;
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.contact form input,
.contact form textarea {
  padding: 13px 16px;
  border-radius: 10px;
  border: 1px solid var(--line);
  outline: none;
  font-size: 14px;
  font-family: inherit;
  background: var(--cream);
  resize: vertical;
}

.contact form input:focus,
.contact form textarea:focus {
  border-color: var(--gold-dark);
}

.btn {
  background: var(--forest);
  color: var(--ivory);
  border: none;
  padding: 14px 20px;
  border-radius: 30px;
  cursor: pointer;
  font-weight: 600;
  transition: all 0.3s ease;
}

.btn:hover {
  background: var(--gold-dark);
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

/* ================= FOOTER ================= */

.footer {
  background: var(--forest);
  color: rgba(255,255,255,0.85);
  padding: 60px 40px 30px;
}

.footer-container {
  max-width: 1200px;
  margin: auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 40px;
}

.footer h3 {
  color: white;
  font-size: 26px;
  margin-bottom: 10px;
}

.footer h3 span { color: var(--gold); }

.footer h4 {
  color: white;
  margin-bottom: 14px;
  font-size: 16px;
  font-weight: 600;
}

.footer p { font-size: 14px; margin-bottom: 6px; }

.footer a {
  display: block;
  margin: 8px 0;
  color: rgba(255,255,255,0.85);
  font-size: 14px;
  transition: color 0.3s ease;
}

.footer a:hover { color: var(--gold); }

.footer hr {
  margin: 36px 0 20px;
  border: none;
  height: 1px;
  background: rgba(255,255,255,0.15);
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
}

.copyright {
  text-align: center;
  font-size: 13px;
  color: rgba(255,255,255,0.6);
}

/* ================= TOAST ================= */

.toast {
  position: fixed;
  bottom: 30px;
  left: 50%;
  transform: translate(-50%, 20px);
  background: var(--forest);
  color: var(--ivory);
  padding: 14px 26px;
  border-radius: 30px;
  font-size: 14px;
  font-weight: 500;
  box-shadow: var(--shadow-lg);
  opacity: 0;
  pointer-events: none;
  transition: all 0.35s ease;
  z-index: 1400;
}

.toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

/* ================= RESPONSIVE ================= */

@media (max-width: 1024px) {
  .nav-center { gap: 24px; }
  #searchInput { width: 130px; }
}

@media (max-width: 860px) {
  .navbar { padding: 16px 20px; }

  .menu-toggle { display: flex; }

  .nav-center {
    position: fixed;
    top: 72px;
    left: 0;
    right: 0;
    background: var(--ivory);
    flex-direction: column;
    align-items: stretch;
    gap: 18px;
    padding: 26px 24px;
    box-shadow: var(--shadow-md);
    transform: translateY(-140%);
    opacity: 0;
    transition: all 0.35s ease;
    z-index: 800;
  }

  .nav-center.active {
    transform: translateY(0);
    opacity: 1;
  }

  .nav-center > a { text-align: center; font-size: 17px; }

  .nav-search { width: 100%; }
  #searchInput { width: 100%; }

  .contact-wrapper {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .products { padding: 70px 24px; }
}

@media (max-width: 640px) {
  .hero { min-height: 80vh; }

  .grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
  }

  .card { padding: 16px; }
  .card img { height: 140px; }
  .card h3 { font-size: 16px; }
  .card button { padding: 9px 14px; font-size: 12px; }

  .cart-overlay { width: 100%; max-width: 100%; }

  .checkout-content { padding: 28px 22px; }

  .contact { padding: 60px 20px; }
}

@media (max-width: 400px) {
  .grid { grid-template-columns: 1fr; }
}
