/* ── STICKY FOOTER (fixes footer floating above the bottom on short
   pages like /login — main content area always fills leftover
   viewport height, pushing the footer to the true bottom) ── */
html {
  height: 100%;
}

body {
  min-height: 100%;
  display: flex;
  flex-direction: column;
}

.page-main {
  flex: 1 0 auto;
}

footer {
  flex-shrink: 0;
}

/* ── UNIFIED NAV BUTTON (Cart / Log In / Sign Up / Sign Out / Track
   Order) — same visual language as the hero's "Explore Products"
   button (.btn-g): solid gold, rounded, no underline, subtle hover
   lift. Used identically in both desktop .nav-right and the mobile
   dropdown, so there's exactly one button style across the whole nav. ── */
.nav-pill-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--gd);
  color: var(--bd);
  padding: 8px 16px;
  border-radius: 8px;
  font-family: 'DM Sans', sans-serif;
  font-weight: 600;
  font-size: .82rem;
  border: none;
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
  position: relative;
  transition: transform .2s, box-shadow .2s;
}

.nav-pill-btn:hover,
.nav-pill-btn:visited,
.nav-pill-btn:active {
  color: var(--bd);
  text-decoration: none;
}

.nav-pill-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(212, 168, 67, .4);
}

.nav-pill-btn--block {
  display: flex;
  justify-content: center;
  width: 100%;
  margin-bottom: 8px;
  box-sizing: border-box;
}

.nav-pill-btn--user {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  letter-spacing: 0.2px;
}

.mob-uname {
  display: block;
  color: var(--cr);
  font-weight: 600;
  font-size: .85rem;
  margin-bottom: 10px;
}

/* ── PRODUCT DETAIL MODAL SHELL (used by index.html's Featured
   Products "Learn More" modal) ── */
#pModal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(15, 5, 0, .82);
  overflow-y: auto
}

#pModal.on {
  display: block
}

.pm-box {
  background: var(--wh);
  border-radius: 20px;
  max-width: 720px;
  width: calc(100% - 32px);
  margin: 32px auto 48px;
  overflow: hidden;
  box-shadow: 0 28px 80px rgba(0, 0, 0, .5);
  animation: mIn .3s ease
}

.pm-hero {
  position: relative;
  height: 260px;
  overflow: hidden
}

.pm-hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block
}

.pm-hero-ov {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(25, 8, 0, .8) 0%, transparent 55%)
}

.pm-hero-txt {
  position: absolute;
  bottom: 18px;
  left: 26px;
  right: 52px
}

.pm-hero-txt h2 {
  font-family: 'Playfair Display', serif;
  font-size: 1.8rem;
  color: #fff;
  line-height: 1.15;
  margin-bottom: 3px
}

.pm-hero-txt small {
  color: rgba(255, 255, 255, .6);
  font-style: italic;
  font-size: .85rem
}

.pm-close {
  position: absolute;
  top: 13px;
  right: 13px;
  background: rgba(255, 255, 255, .93);
  border: none;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  font-size: .95rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(0, 0, 0, .2);
  z-index: 5
}

.pm-close:hover {
  background: var(--cd)
}

.pm-body {
  padding: 0 0 28px
}

/* ── SHARED PRODUCT-INFO COMPONENTS ── used by both the Featured
   Products modal AND the real product detail page, so both look
   consistent: .pds (labeled section), .bt (spec table), .chips/.chip
   (variety tags), .nt (nutrition table), .benefits/.ben (benefit
   cards), .uses/.use-tag, .storage-box. ── */
.pds {
  padding: 20px 26px 0
}

.pds-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: 'Playfair Display', serif;
  font-size: .98rem;
  color: var(--bd);
  font-weight: 700;
  margin-bottom: 11px;
  padding-bottom: 7px;
  border-bottom: 1.5px solid var(--cd)
}

.pds-title .ico {
  font-size: .95rem
}

.pds p,
.pds-intro p {
  color: var(--tm);
  line-height: 1.78;
  font-size: .92rem
}

.pds ul {
  list-style: none;
  padding: 0;
  margin: 0
}

.pds ul li {
  padding: 5px 0 5px 17px;
  position: relative;
  color: var(--tm);
  font-size: .9rem;
  line-height: 1.6
}

.pds ul li::before {
  content: '▸';
  position: absolute;
  left: 0;
  color: var(--bw)
}

.bt {
  width: 100%;
  border-collapse: collapse;
  font-size: .86rem
}

.bt tr {
  border-bottom: 1px solid var(--cd)
}

.bt tr:last-child {
  border-bottom: none
}

.bt td {
  padding: 7px 10px;
  color: var(--tm)
}

.bt td:first-child {
  font-weight: 600;
  color: var(--bm);
  width: 38%
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 7px
}

.chip {
  background: var(--cd);
  color: var(--bd);
  padding: 5px 13px;
  border-radius: 20px;
  font-size: .8rem;
  font-weight: 500
}

.nt {
  width: 100%;
  border-collapse: collapse;
  font-size: .86rem
}

.nt thead th {
  background: var(--bd);
  color: var(--cr);
  padding: 8px 12px;
  text-align: left;
  font-weight: 600;
  font-size: .78rem;
  letter-spacing: .04em
}

.nt tbody tr {
  border-bottom: 1px solid var(--cd)
}

.nt tbody tr:last-child {
  border-bottom: none
}

.nt tbody tr:nth-child(even) {
  background: #fdf8f3
}

.nt tbody td {
  padding: 7px 12px;
  color: var(--tm)
}

.nt tbody td:first-child {
  color: var(--bm);
  font-weight: 500
}

.benefits {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px
}

.ben {
  background: var(--cr);
  border-radius: 9px;
  padding: 11px 13px;
  display: flex;
  gap: 8px;
  align-items: flex-start
}

.ben-ico {
  font-size: 1.05rem;
  flex-shrink: 0;
  margin-top: 1px
}

.ben-txt {
  font-size: .83rem;
  color: var(--tm);
  line-height: 1.5
}

.ben-txt strong {
  display: block;
  color: var(--bd);
  font-size: .85rem;
  margin-bottom: 2px
}

.uses {
  display: flex;
  flex-wrap: wrap;
  gap: 7px
}

.use-tag {
  background: var(--bd);
  color: var(--cr);
  padding: 5px 13px;
  border-radius: 6px;
  font-size: .8rem
}

.storage-box {
  background: #fff8ed;
  border: 1px solid var(--cd);
  border-radius: 9px;
  padding: 13px 15px;
  font-size: .88rem;
  color: var(--tm);
  line-height: 1.72
}

@media(max-width:600px) {
  .pm-box {
    margin: 16px auto 32px;
    border-radius: 14px;
    width: calc(100% - 24px)
  }

  .pm-hero {
    height: 195px
  }

  .pm-hero-txt h2 {
    font-size: 1.35rem
  }

  .pm-hero-txt {
    left: 14px;
    bottom: 12px
  }

  .pds {
    padding: 16px 14px 0
  }

  .benefits {
    grid-template-columns: 1fr
  }
}

@keyframes mIn {
  from {
    opacity: 0;
    transform: scale(.94) translateY(18px)
  }

  to {
    opacity: 1;
    transform: scale(1) translateY(0)
  }
}

/* ── PRODUCT DETAIL PAGE ── */
#product-page {
  padding: 130px 48px 100px;
  background: var(--cr);
  min-height: 60vh;
}

.pd-wrap {
  max-width: 1080px;
  margin: 0 auto;
}

.pd-back {
  display: inline-block;
  margin-bottom: 20px;
  color: var(--tm);
  font-size: .85rem;
  text-decoration: none;
}

.pd-back:hover {
  color: var(--bw);
  text-decoration: underline;
}

.pd-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 50px;
  align-items: start;
  margin-bottom: 50px;
}

.pd-image-box {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 18px;
  overflow: hidden;
  background: var(--cd);
  box-shadow: 0 12px 40px rgba(58, 26, 8, .12);
}

.pd-image-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.pd-details h1 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  color: var(--bd);
  margin: 10px 0 8px;
  line-height: 1.2;
}

.pd-seller-link {
  display: inline-block;
  font-size: .85rem;
  color: var(--tm);
  margin-bottom: 16px;
  text-decoration: none;
}

.pd-seller-link:hover {
  color: var(--bw);
  text-decoration: underline;
}

.pd-price-row {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}

.pd-price {
  font-family: 'Playfair Display', serif;
  font-size: 1.9rem;
  font-weight: 700;
  color: var(--gd);
}

.pd-price-unit {
  font-size: .85rem;
  color: var(--tm);
  font-weight: 400;
}

.pd-mrp {
  font-size: .95rem;
  color: var(--tm);
  text-decoration: line-through;
}

.pd-discount {
  font-size: .76rem;
  font-weight: 700;
  color: #2e7d32;
  background: rgba(46, 125, 50, .1);
  padding: 2px 9px;
  border-radius: 20px;
}

.pd-stock-pill {
  display: inline-block;
  font-size: .76rem;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 20px;
  margin-bottom: 18px;
}

.pd-stock-pill.in {
  background: rgba(46, 125, 50, .1);
  color: #2e7d32;
}

.pd-stock-pill.out {
  background: rgba(179, 38, 30, .1);
  color: #b3261e;
}

.pd-desc {
  color: var(--tm);
  line-height: 1.8;
  font-size: .95rem;
  margin-bottom: 18px;
}

.pd-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 24px;
}

.pd-purchase-box {
  background: var(--wh);
  border-radius: 14px;
  padding: 20px;
  box-shadow: 0 4px 18px rgba(58, 26, 8, .08);
  margin-bottom: 24px;
}

.pd-qty-row {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 4px;
}

.pd-qty-label {
  font-size: .82rem;
  font-weight: 600;
  color: var(--bm);
}

.pd-qty-controls {
  display: flex;
  align-items: center;
  gap: 8px;
}

.pd-qty-btn {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  border: 1.5px solid var(--cd);
  background: var(--cr);
  color: var(--bd);
  font-size: 1.1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.pd-qty-btn:hover {
  border-color: var(--gd);
}

.pd-qty-input {
  width: 90px;
  text-align: center;
  padding: 8px;
  border: 1.5px solid var(--cd);
  border-radius: 8px;
  font-family: 'DM Sans', sans-serif;
  font-size: .92rem;
  color: var(--tx);
}

.pd-qty-hint {
  font-size: .74rem;
  color: var(--tm);
  margin-top: 6px;
}

.pd-live-total-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 14px;
  margin-top: 12px;
  border-top: 1px solid var(--cd);
}

.pd-live-total-label {
  font-size: .85rem;
  color: var(--tm);
}

.pd-live-total {
  font-family: 'Playfair Display', serif;
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--bd);
}

.pd-add-btn {
  width: 100%;
  background: var(--gd);
  color: var(--bd);
  border: none;
  padding: 13px;
  border-radius: 9px;
  font-weight: 700;
  font-size: .92rem;
  cursor: pointer;
  margin-top: 16px;
  font-family: 'DM Sans', sans-serif;
}

.pd-add-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(212, 168, 67, .4);
}

.pd-login-btn {
  display: block;
  text-align: center;
  width: 100%;
  background: var(--gd);
  color: var(--bd);
  padding: 13px;
  border-radius: 9px;
  font-weight: 700;
  font-size: .92rem;
  text-decoration: none;
  box-sizing: border-box;
}

.pd-info-sections {
  background: var(--wh);
  border-radius: 16px;
  box-shadow: 0 4px 18px rgba(58, 26, 8, .08);
  overflow: hidden;
}

.pd-info-sections .pds {
  padding: 24px 28px;
  border-bottom: 1px solid var(--cd);
}

.pd-info-sections .pds:last-child {
  border-bottom: none;
  padding-bottom: 28px;
}

@media(max-width:900px) {
  #product-page {
    padding: 115px 20px 70px;
  }

  .pd-grid {
    grid-template-columns: 1fr;
    gap: 30px;
    margin-bottom: 36px;
  }

  .pd-image-box {
    aspect-ratio: 4 / 3;
  }
}

@media(max-width:480px) {
  .pd-info-sections .pds {
    padding: 18px 16px;
  }
}

/* ── PAYMENT METHOD SELECTOR (checkout page) ── */
.pay-method-options {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 6px;
}

.pay-method-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border: 1.5px solid var(--cd);
  border-radius: 9px;
  cursor: pointer;
  font-size: .88rem;
  color: var(--tx);
  transition: border-color .2s, background .2s;
}

.pay-method-option:has(input:checked) {
  border-color: var(--gd);
  background: rgba(212, 168, 67, .06);
}

.pay-method-option input[type="radio"] {
  accent-color: var(--gd);
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.pay-method-option.disabled {
  opacity: .5;
  cursor: not-allowed;
}

.pay-method-tag {
  margin-left: auto;
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  background: rgba(212, 168, 67, .15);
  color: var(--bw);
  padding: 2px 9px;
  border-radius: 20px;
}

/* ── RAZORPAY PAYMENT PAGE ── */
#pay-page {
  padding: 130px 48px 100px;
  background: var(--cr);
  min-height: 60vh;
  display: flex;
  justify-content: center;
}

.pay-box {
  background: var(--wh);
  border-radius: 18px;
  box-shadow: 0 8px 30px rgba(58, 26, 8, .1);
  padding: 40px 36px;
  width: 100%;
  max-width: 460px;
  text-align: center;
}

.pay-box h1 {
  font-family: 'Playfair Display', serif;
  font-size: 1.5rem;
  color: var(--bd);
  margin-bottom: 8px;
}

.pay-box .pay-amount {
  font-family: 'Playfair Display', serif;
  font-size: 2.2rem;
  font-weight: 700;
  color: var(--gd);
  margin: 14px 0;
}

.pay-test-note {
  background: var(--cr);
  border: 1px solid var(--cd);
  border-radius: 9px;
  padding: 14px 16px;
  font-size: .82rem;
  color: var(--tm);
  line-height: 1.7;
  text-align: left;
  margin: 20px 0;
}

.pay-test-note strong {
  color: var(--bd);
}

.pay-now-btn {
  width: 100%;
  background: var(--gd);
  color: var(--bd);
  border: none;
  padding: 14px;
  border-radius: 9px;
  font-weight: 700;
  font-size: .95rem;
  cursor: pointer;
  margin-top: 6px;
}

@media(max-width:600px) {
  #pay-page {
    padding: 115px 18px 70px;
  }

  .pay-box {
    padding: 28px 22px;
  }
}

/* ── LIVE MANDI SPOT COMMODITY TICKER (STOCK MARKET STYLE) ── */
.market-ticker-bar {
  position: fixed;
  top: 66px;
  /* directly below navbar (66px) */
  left: 0;
  right: 0;
  z-index: 895;
  height: 38px;
  display: flex;
  align-items: center;
  background: linear-gradient(90deg, #130702 0%, #1e0c04 25%, #291206 50%, #1e0c04 75%, #130702 100%);
  border-top: 1px solid rgba(212, 168, 67, 0.28);
  border-bottom: 1px solid rgba(212, 168, 67, 0.38);
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.45);
  overflow: hidden;
  user-select: none;
}

.ticker-live-badge {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 0 16px;
  height: 100%;
  background: linear-gradient(90deg, #1b0903 0%, rgba(27, 9, 3, 0.98) 75%, rgba(27, 9, 3, 0.8) 100%);
  border-right: 1px solid rgba(212, 168, 67, 0.35);
  z-index: 3;
  flex-shrink: 0;
  box-shadow: 4px 0 12px rgba(0, 0, 0, 0.35);
}

.ticker-pulse-glow {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 10px #22c55e, 0 0 4px #22c55e;
  animation: ticker-pulse 1.8s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

@keyframes ticker-pulse {
  0%, 100% {
    opacity: 1;
    transform: scale(1);
    box-shadow: 0 0 8px #22c55e;
  }
  50% {
    opacity: 0.35;
    transform: scale(0.8);
    box-shadow: 0 0 2px #22c55e;
  }
}

.ticker-badge-text {
  font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--gd);
  text-transform: uppercase;
  white-space: nowrap;
}

.market-ticker-viewport {
  flex: 1;
  height: 100%;
  overflow: hidden;
  position: relative;
  display: flex;
  align-items: center;
  mask-image: linear-gradient(90deg, transparent 0%, black 18px, black calc(100% - 18px), transparent 100%);
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, black 18px, black calc(100% - 18px), transparent 100%);
}

.market-ticker-track {
  display: flex;
  align-items: center;
  width: max-content;
  height: 100%;
  animation: market-ticker-scroll 55s linear infinite;
  will-change: transform;
}

.market-ticker-bar:hover .market-ticker-track {
  animation-play-state: paused;
}

.ticker-item {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 4px 14px;
  margin: 0 4px;
  border-radius: 6px;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  transition: background 0.2s ease, transform 0.15s ease;
}

.ticker-item:hover {
  background: rgba(212, 168, 67, 0.14);
  transform: translateY(-1px);
}

.ticker-symbol {
  font-family: 'DM Mono', 'SFMono-Regular', Consolas, monospace;
  font-size: 0.7rem;
  font-weight: 700;
  color: #f6d27e;
  background: rgba(212, 168, 67, 0.16);
  border: 1px solid rgba(212, 168, 67, 0.35);
  padding: 1.5px 6px;
  border-radius: 4px;
  letter-spacing: 0.03em;
}

.ticker-name {
  font-size: 0.78rem;
  font-weight: 500;
  color: #fdf5ec;
  letter-spacing: 0.01em;
}

.ticker-price {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.82rem;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: 0.02em;
}

.ticker-unit {
  font-size: 0.68rem;
  font-weight: 400;
  color: rgba(253, 245, 236, 0.65);
  margin-left: 1px;
}

.ticker-change {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 1.5px 5px;
  border-radius: 4px;
  font-family: 'DM Mono', monospace;
}

.ticker-change.ticker-up {
  color: #4ade80;
  background: rgba(34, 197, 94, 0.14);
  border: 1px solid rgba(34, 197, 94, 0.25);
}

.ticker-change.ticker-down {
  color: #f87171;
  background: rgba(239, 68, 68, 0.14);
  border: 1px solid rgba(239, 68, 68, 0.25);
}

.ticker-arrow {
  font-size: 0.65rem;
  line-height: 1;
}

.ticker-dot {
  color: rgba(212, 168, 67, 0.35);
  font-size: 0.75rem;
  margin-left: 6px;
  font-weight: 300;
}

@keyframes market-ticker-scroll {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .market-ticker-track {
    animation: none;
    overflow-x: auto;
  }
}

@media (max-width: 600px) {
  .market-ticker-bar {
    top: 66px;
    height: 35px;
  }

  .ticker-live-badge {
    padding: 0 10px;
    gap: 5px;
  }

  .ticker-badge-text {
    font-size: 0.65rem;
  }

  .ticker-item {
    padding: 2px 10px;
    gap: 5px;
  }

  .ticker-symbol {
    font-size: 0.65rem;
    padding: 1px 4px;
  }

  .ticker-name {
    font-size: 0.72rem;
  }

  .ticker-price {
    font-size: 0.76rem;
  }

  .ticker-change {
    font-size: 0.68rem;
    padding: 1px 4px;
  }
}

/* ── CIRCULAR CONSERVATIVE CART BUTTON ── */
.nav-cart-circle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(253, 245, 236, 0.08);
  border: 1.5px solid rgba(212, 168, 67, 0.5);
  color: var(--gd);
  cursor: pointer;
  text-decoration: none;
  transition: background-color 0.2s, border-color 0.2s, color 0.2s, transform 0.2s, box-shadow 0.2s;
  flex-shrink: 0;
}

.nav-cart-circle:hover {
  background: rgba(212, 168, 67, 0.18);
  border-color: var(--gd);
  color: #fff9f0;
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(212, 168, 67, 0.25);
}

.nav-cart-circle:active {
  transform: translateY(0);
}

.cart-circle-icon {
  width: 19px;
  height: 19px;
  stroke: currentColor;
  transition: stroke 0.2s;
}

.nav-cart-circle-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  background: var(--gd);
  color: var(--bd);
  border: 2px solid var(--bd);
  border-radius: 20px;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.65rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.35);
}

.nav-cart-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  background: var(--bd);
  color: var(--cr);
  border-radius: 20px;
  font-size: .68rem;
  font-weight: 700;
}

/* ── FLASH MESSAGES ── */
.flash-wrap {
  position: fixed;
  top: 110px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 950;
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: min(92%, 520px);
}

.flash-msg {
  padding: 12px 18px;
  border-radius: 9px;
  font-size: .88rem;
  font-weight: 500;
  box-shadow: 0 6px 20px rgba(0, 0, 0, .18);
}

.flash-success {
  background: #eaf6ec;
  color: #2e7d32;
  border: 1px solid rgba(46, 125, 50, .25);
}

.flash-error {
  background: #fdeceb;
  color: #b3261e;
  border: 1px solid rgba(179, 38, 30, .25);
}

/* ── GENERIC AUTH / FORM PAGES (login, signup, checkout) ── */
.form-page {
  min-height: 70vh;
  padding: 130px 22px 90px;
  background: var(--cr);
  display: flex;
  justify-content: center;
}

.form-card {
  background: var(--wh);
  border-radius: 18px;
  box-shadow: 0 8px 30px rgba(58, 26, 8, .1);
  padding: 40px 36px;
  width: 100%;
  max-width: 440px;
  height: fit-content;
}

.form-card h1 {
  font-family: 'Playfair Display', serif;
  font-size: 1.7rem;
  color: var(--bd);
  margin-bottom: 6px;
}

.form-card .form-sub {
  color: var(--tm);
  font-size: .88rem;
  margin-bottom: 26px;
}

.field-group {
  margin-bottom: 16px;
}

.field-group label {
  display: block;
  font-size: .78rem;
  font-weight: 600;
  color: var(--bm);
  margin-bottom: 6px;
  letter-spacing: .02em;
}

.field-input {
  width: 100%;
  padding: 11px 14px;
  border: 1.5px solid var(--cd);
  border-radius: 8px;
  font-family: 'DM Sans', sans-serif;
  font-size: .92rem;
  color: var(--tx);
  background: var(--cr);
  outline: none;
  transition: border-color .2s;
}

.field-input:focus {
  border-color: var(--gd);
}

.field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.form-submit-btn {
  width: 100%;
  background: var(--gd);
  color: var(--bd);
  border: none;
  padding: 13px;
  border-radius: 9px;
  font-family: 'DM Sans', sans-serif;
  font-size: .92rem;
  font-weight: 700;
  cursor: pointer;
  margin-top: 6px;
  transition: transform .2s, box-shadow .2s;
}

.form-submit-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(212, 168, 67, .4);
}

.form-footnote {
  text-align: center;
  font-size: .85rem;
  color: var(--tm);
  margin-top: 20px;
}

.form-footnote a {
  color: var(--bw);
  font-weight: 600;
  text-decoration: none;
}

.form-footnote a:hover {
  text-decoration: underline;
}

.form-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 22px 0;
  color: var(--tm);
  font-size: .78rem;
}

.form-divider::before,
.form-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--cd);
}

.google-btn-wrap {
  display: flex;
  justify-content: center;
  width: 100%;
}

.btn-google-custom {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  padding: 11px 18px;
  background: var(--wh);
  color: #3c4043;
  border: 1.5px solid #dadce0;
  border-radius: 9px;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 1px 3px rgba(60, 64, 67, 0.08);
  transition: background-color 0.2s, box-shadow 0.2s, border-color 0.2s, transform 0.2s;
}

.btn-google-custom:hover {
  background-color: #f8fafd;
  border-color: #d2e3fc;
  box-shadow: 0 4px 12px rgba(66, 133, 244, 0.15);
  transform: translateY(-1px);
}

.btn-google-custom:active {
  background-color: #f1f3f4;
  transform: translateY(0);
}

.google-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.google-unavailable-note {
  text-align: center;
  font-size: .8rem;
  color: var(--tm);
  background: var(--cr);
  border: 1px solid var(--cd);
  border-radius: 8px;
  padding: 10px 14px;
}

@media(max-width:480px) {
  .form-card {
    padding: 30px 22px;
  }

  .field-row {
    grid-template-columns: 1fr;
  }
}

/* ── CART PAGE ── */
#cart-page {
  padding: 130px 48px 100px;
  background: var(--cr);
  min-height: 60vh;
}

.cart-layout {
  max-width: 1050px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 30px;
  align-items: start;
}

.cart-items {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.cart-item {
  background: var(--wh);
  border-radius: 14px;
  box-shadow: 0 4px 16px rgba(58, 26, 8, .07);
  padding: 16px;
  display: flex;
  gap: 16px;
  align-items: center;
}

.cart-item img {
  width: 74px;
  height: 74px;
  border-radius: 10px;
  object-fit: cover;
  flex-shrink: 0;
  background: var(--cd);
}

.cart-item-body {
  flex: 1;
  min-width: 0;
}

.cart-item-body h3 {
  font-family: 'Playfair Display', serif;
  font-size: 1.02rem;
  color: var(--bd);
  margin-bottom: 3px;
}

.cart-item-shop {
  font-size: .78rem;
  color: var(--tm);
  margin-bottom: 8px;
}

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

.qty-form {
  display: flex;
  align-items: center;
  gap: 6px;
}

.qty-input {
  width: 80px;
  padding: 7px 9px;
  border: 1.5px solid var(--cd);
  border-radius: 7px;
  font-family: 'DM Sans', sans-serif;
  font-size: .85rem;
  color: var(--tx);
}

.qty-update-btn {
  background: var(--cd);
  color: var(--bd);
  border: none;
  padding: 7px 12px;
  border-radius: 7px;
  font-size: .78rem;
  font-weight: 600;
  cursor: pointer;
}

.remove-btn {
  background: none;
  border: none;
  color: #b3261e;
  font-size: .78rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: underline;
}

.cart-item-price {
  text-align: right;
  flex-shrink: 0;
  font-family: 'Playfair Display', serif;
  color: var(--bd);
  font-weight: 700;
  font-size: 1.05rem;
  min-width: 90px;
}

.cart-summary {
  background: var(--wh);
  border-radius: 14px;
  box-shadow: 0 4px 16px rgba(58, 26, 8, .07);
  padding: 24px 22px;
  position: sticky;
  top: 90px;
}

.cart-summary h3 {
  font-family: 'Playfair Display', serif;
  color: var(--bd);
  font-size: 1.15rem;
  margin-bottom: 16px;
}

.cart-summary-row {
  display: flex;
  justify-content: space-between;
  font-size: .9rem;
  color: var(--tm);
  padding: 8px 0;
  border-bottom: 1px solid var(--cd);
}

.cart-summary-row.total {
  color: var(--bd);
  font-weight: 700;
  font-size: 1rem;
  border-bottom: none;
  padding-top: 12px;
}

.checkout-btn {
  display: block;
  width: 100%;
  text-align: center;
  background: var(--gd);
  color: var(--bd);
  border: none;
  padding: 13px;
  border-radius: 9px;
  font-weight: 700;
  font-size: .92rem;
  text-decoration: none;
  margin-top: 16px;
  cursor: pointer;
}

.cart-empty {
  text-align: center;
  padding: 60px 20px;
  color: var(--tm);
}

.cart-empty a {
  color: var(--bw);
  font-weight: 600;
}

@media(max-width:800px) {
  #cart-page {
    padding: 125px 18px 70px;
  }

  .cart-layout {
    grid-template-columns: 1fr;
  }

  .cart-summary {
    position: static;
  }
}

/* ── CHECKOUT PAGE ── */
#checkout-page {
  padding: 130px 48px 100px;
  background: var(--cr);
  min-height: 60vh;
}

.checkout-layout {
  max-width: 1050px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 30px;
  align-items: start;
}

.checkout-form-card {
  background: var(--wh);
  border-radius: 16px;
  box-shadow: 0 6px 22px rgba(58, 26, 8, .08);
  padding: 32px 30px;
}

.checkout-form-card h2 {
  font-family: 'Playfair Display', serif;
  color: var(--bd);
  font-size: 1.35rem;
  margin-bottom: 20px;
}

.order-review {
  background: var(--wh);
  border-radius: 16px;
  box-shadow: 0 6px 22px rgba(58, 26, 8, .08);
  padding: 24px 22px;
  position: sticky;
  top: 90px;
}

.order-review h3 {
  font-family: 'Playfair Display', serif;
  color: var(--bd);
  font-size: 1.1rem;
  margin-bottom: 14px;
}

.review-item {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  font-size: .85rem;
  color: var(--tm);
  padding: 8px 0;
  border-bottom: 1px solid var(--cd);
}

.review-item-name {
  color: var(--tx);
}

.cod-note {
  background: var(--cr);
  border: 1px solid var(--cd);
  border-radius: 9px;
  padding: 12px 14px;
  font-size: .82rem;
  color: var(--tm);
  margin-top: 16px;
  line-height: 1.6;
}

@media(max-width:850px) {
  #checkout-page {
    padding: 125px 18px 70px;
  }

  .checkout-layout {
    grid-template-columns: 1fr;
  }

  .order-review {
    position: static;
  }
}

/* ── ORDER HISTORY / DETAIL ── */
#orders-page,
#order-detail-page {
  padding: 130px 48px 100px;
  background: var(--cr);
  min-height: 60vh;
}

.orders-list {
  max-width: 900px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.order-card {
  background: var(--wh);
  border-radius: 14px;
  box-shadow: 0 4px 16px rgba(58, 26, 8, .07);
  padding: 18px 22px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  color: inherit;
  flex-wrap: wrap;
}

.order-card-id {
  font-family: 'Playfair Display', serif;
  color: var(--bd);
  font-weight: 700;
}

.order-card-meta {
  font-size: .8rem;
  color: var(--tm);
}

.order-status {
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  padding: 4px 12px;
  border-radius: 20px;
  background: rgba(212, 168, 67, .15);
  color: var(--bw);
  border: 1px solid rgba(212, 168, 67, .3);
}

.order-detail-box {
  max-width: 700px;
  margin: 0 auto;
  background: var(--wh);
  border-radius: 16px;
  box-shadow: 0 6px 22px rgba(58, 26, 8, .08);
  padding: 30px 28px;
}

.order-detail-box h1 {
  font-family: 'Playfair Display', serif;
  color: var(--bd);
  font-size: 1.5rem;
  margin-bottom: 6px;
}

.order-detail-address {
  background: var(--cr);
  border-radius: 10px;
  padding: 14px 16px;
  font-size: .88rem;
  color: var(--tm);
  line-height: 1.7;
  margin: 18px 0;
}

.orders-empty {
  text-align: center;
  padding: 60px 20px;
  color: var(--tm);
}

/* ── ORDER TRACKING STEPPER (order detail page) ── */
.order-tracker {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  position: relative;
  margin: 26px 0 20px;
}

.order-tracker::before {
  content: '';
  position: absolute;
  top: 17px;
  left: 8%;
  right: 8%;
  height: 2px;
  background: var(--cd);
  z-index: 0;
}

.tracker-step {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  flex: 1;
}

.tracker-num {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--cr);
  border: 2px solid var(--cd);
  color: var(--tm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .9rem;
  font-weight: 700;
  transition: background .2s, border-color .2s, color .2s;
}

.tracker-label {
  font-size: .72rem;
  color: var(--tm);
  font-weight: 600;
  text-align: center;
  text-transform: capitalize;
}

.tracker-step.done .tracker-num {
  background: var(--gd);
  border-color: var(--gd);
  color: var(--bd);
}

.tracker-step.done .tracker-label {
  color: var(--bd);
}

.tracker-step.active .tracker-num {
  background: var(--bd);
  border-color: var(--bd);
  color: var(--cr);
  box-shadow: 0 0 0 4px rgba(212, 168, 67, .25);
}

.tracker-step.active .tracker-label {
  color: var(--bd);
  font-weight: 700;
}

.tracker-cancelled-note {
  background: rgba(179, 38, 30, .08);
  border: 1px solid rgba(179, 38, 30, .2);
  color: #b3261e;
  border-radius: 9px;
  padding: 12px 14px;
  font-size: .85rem;
  text-align: center;
  font-weight: 600;
  margin: 20px 0;
}

@media(max-width:480px) {
  .tracker-label {
    font-size: .6rem;
  }

  .tracker-num {
    width: 28px;
    height: 28px;
    font-size: .78rem;
  }
}

/* ── LANGUAGE TOGGLE BUTTON ── */
.nav-lang-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(212, 168, 67, 0.15);
  color: var(--gd);
  border: 1px solid rgba(212, 168, 67, 0.35);
  padding: 6px 14px;
  border-radius: 8px;
  font-family: 'DM Sans', sans-serif;
  font-weight: 600;
  font-size: .82rem;
  cursor: pointer;
  transition: all .2s ease;
}

.nav-lang-btn:hover {
  background: var(--gd);
  color: var(--bd);
  border-color: var(--gd);
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(212, 168, 67, 0.35);
}

.mob-lang-btn {
  margin-bottom: 12px;
  justify-content: center;
}

/* ── CART TRUST NOTE ── */
.cart-trust-note {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 14px 0 16px;
  padding: 10px 14px;
  background: rgba(46, 125, 50, 0.08);
  border: 1px solid rgba(46, 125, 50, 0.22);
  border-radius: 8px;
  font-size: 0.78rem;
  color: #2e7d32;
  line-height: 1.4;
}

.cart-trust-note .trust-ico {
  font-size: 1.1rem;
}

/* ── GOOGLE TRANSLATE BANNER SUPPRESSION (Section 15 & 16) ── */
.goog-te-banner-frame.skiptranslate,
.goog-te-banner-frame,
iframe.goog-te-banner-frame {
  display: none !important;
  visibility: hidden !important;
  height: 0 !important;
}

body {
  top: 0px !important;
}

.goog-logo-link,
.goog-te-gadget span,
div#goog-gt-tt,
.goog-te-balloon-frame {
  display: none !important;
}

.goog-te-gadget {
  color: transparent !important;
  font-size: 0px !important;
}

#google_translate_element {
  display: none !important;
}

/* ═══════════════════════════════════════════════════════════════
   BUYER PROFILE DASHBOARD STYLES
   ═══════════════════════════════════════════════════════════════ */
#profile-page {
  padding: 100px 24px 80px;
  min-height: 80vh;
  background: var(--cr);
}

.profile-container {
  max-width: 1080px;
  margin: 0 auto;
}

/* ── HERO CARD ── */
.profile-hero-card {
  background: linear-gradient(135deg, var(--bd) 0%, #200e04 100%);
  border-radius: 20px;
  padding: 36px 40px;
  color: var(--cr);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 24px;
  box-shadow: 0 16px 40px rgba(58, 26, 8, 0.25);
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(212, 168, 67, 0.2);
  margin-bottom: 28px;
}

.profile-hero-card::after {
  content: '';
  position: absolute;
  top: -60px;
  right: -60px;
  width: 260px;
  height: 260px;
  background: radial-gradient(circle, rgba(212, 168, 67, 0.15), transparent 70%);
  pointer-events: none;
}

.profile-hero-content {
  display: flex;
  align-items: center;
  gap: 22px;
}

.profile-avatar-wrap {
  position: relative;
  width: 82px;
  height: 82px;
  flex-shrink: 0;
}

.profile-avatar-img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--gd);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.3);
}

.profile-avatar-initial {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: rgba(212, 168, 67, 0.15);
  border: 2.5px solid var(--gd);
  color: var(--gd);
  font-family: 'Playfair Display', serif;
  font-size: 2.2rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.3);
}

.profile-status-dot {
  position: absolute;
  bottom: 2px;
  right: 2px;
  width: 14px;
  height: 14px;
  background: #2e7d32;
  border: 2px solid var(--bd);
  border-radius: 50%;
}

.profile-badge-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
  flex-wrap: wrap;
}

.profile-pill-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(212, 168, 67, 0.2);
  color: var(--gd);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 3px 10px;
  border-radius: 20px;
  border: 1px solid rgba(212, 168, 67, 0.4);
}

.profile-pill-badge.google-badge {
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.25);
}

.google-mini-icon {
  width: 13px;
  height: 13px;
}

.profile-hero-text h1 {
  font-family: 'Playfair Display', serif;
  font-size: 1.85rem;
  color: var(--wh);
  margin-bottom: 4px;
}

.profile-email-line {
  font-size: 0.88rem;
  color: rgba(253, 245, 236, 0.75);
}

.profile-hero-actions {
  display: flex;
  gap: 12px;
  align-items: center;
}

.btn-profile-primary {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--gd);
  color: var(--bd);
  padding: 10px 20px;
  border-radius: 9px;
  font-weight: 700;
  font-size: 0.88rem;
  text-decoration: none;
  transition: transform 0.2s, box-shadow 0.2s;
}

.btn-profile-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(212, 168, 67, 0.4);
}

.btn-profile-secondary {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.12);
  color: var(--cr);
  border: 1px solid rgba(255, 255, 255, 0.25);
  padding: 10px 18px;
  border-radius: 9px;
  font-weight: 600;
  font-size: 0.88rem;
  text-decoration: none;
  transition: background 0.2s, transform 0.2s;
}

.btn-profile-secondary:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

.btn-profile-signout {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(211, 47, 47, 0.15);
  color: #ffcdd2;
  border: 1px solid rgba(211, 47, 47, 0.4);
  padding: 10px 18px;
  border-radius: 9px;
  font-weight: 600;
  font-size: 0.88rem;
  text-decoration: none;
  transition: background 0.2s, color 0.2s, transform 0.2s, border-color 0.2s;
}

.btn-profile-signout:hover {
  background: rgba(211, 47, 47, 0.35);
  color: #ffffff;
  border-color: #ef5350;
  transform: translateY(-2px);
}

/* ── STATS GRID ── */
.profile-stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  margin-bottom: 30px;
}

.p-stat-card {
  background: var(--wh);
  border-radius: 14px;
  padding: 18px 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  box-shadow: 0 4px 18px rgba(58, 26, 8, 0.05);
  border: 1px solid var(--cd);
  transition: transform 0.2s, box-shadow 0.2s;
}

.p-stat-card--link {
  text-decoration: none;
  color: inherit;
  cursor: pointer;
}

.p-stat-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(58, 26, 8, 0.1);
  border-color: var(--gd);
}

.p-stat-icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: rgba(212, 168, 67, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  flex-shrink: 0;
}

.p-stat-val {
  display: block;
  font-family: 'Playfair Display', serif;
  font-size: 1.45rem;
  font-weight: 700;
  color: var(--bd);
  line-height: 1.2;
}

.p-stat-lbl {
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--tm);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* ── DASHBOARD GRID ── */
.profile-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 26px;
  align-items: start;
}

.profile-col {
  display: flex;
  flex-direction: column;
  gap: 26px;
}

.profile-card {
  background: var(--wh);
  border-radius: 18px;
  padding: 30px 28px;
  box-shadow: 0 6px 24px rgba(58, 26, 8, 0.06);
  border: 1px solid var(--cd);
}

.p-card-hdr {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 18px;
}

.p-card-title-group {
  display: flex;
  align-items: center;
  gap: 10px;
}

.p-card-ico {
  font-size: 1.3rem;
}

.p-card-hdr h2 {
  font-family: 'Playfair Display', serif;
  font-size: 1.25rem;
  color: var(--bd);
}

.p-card-desc {
  font-size: 0.82rem;
  color: var(--tm);
  margin-top: -10px;
  margin-bottom: 20px;
}

.p-card-link-more {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--bw);
  text-decoration: none;
}

.p-card-link-more:hover {
  text-decoration: underline;
}

.address-saved-pill {
  background: rgba(46, 125, 50, 0.1);
  color: #2e7d32;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 20px;
  border: 1px solid rgba(46, 125, 50, 0.3);
}

.readonly-input {
  background: #f8f9fa !important;
  color: #6c757d !important;
  cursor: not-allowed;
}

.input-note {
  display: block;
  font-size: 0.74rem;
  color: var(--tm);
  margin-top: 4px;
}

.profile-btn-save {
  width: 100%;
  background: var(--gd);
  color: var(--bd);
  border: none;
  padding: 12px;
  border-radius: 9px;
  font-weight: 700;
  font-size: 0.9rem;
  cursor: pointer;
  margin-top: 8px;
  transition: transform 0.2s, box-shadow 0.2s;
}

.profile-btn-save:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(212, 168, 67, 0.35);
}

.profile-btn-outline {
  width: 100%;
  background: transparent;
  color: var(--bd);
  border: 1.5px solid var(--bd);
  padding: 11px;
  border-radius: 9px;
  font-weight: 700;
  font-size: 0.88rem;
  cursor: pointer;
  margin-top: 8px;
  transition: background 0.2s, color 0.2s;
}

.profile-btn-outline:hover {
  background: var(--bd);
  color: var(--cr);
}

.profile-btn-track-all {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  background: var(--cr);
  color: var(--bd);
  border: 1.5px solid var(--gd);
  padding: 12px;
  border-radius: 9px;
  font-weight: 700;
  font-size: 0.88rem;
  text-decoration: none;
  transition: background 0.2s, transform 0.2s, box-shadow 0.2s;
}

.profile-btn-track-all:hover {
  background: var(--gd);
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(212, 168, 67, 0.3);
}

/* ── RECENT ORDERS ON PROFILE ── */
.profile-orders-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.profile-order-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 16px;
  border-radius: 10px;
  background: var(--cr);
  border: 1px solid var(--cd);
  text-decoration: none;
  color: inherit;
  transition: transform 0.2s, border-color 0.2s, background 0.2s;
}

.profile-order-item:hover {
  transform: translateX(3px);
  border-color: var(--gd);
  background: #fff9f0;
}

.p-order-id {
  font-weight: 700;
  font-size: 0.88rem;
  color: var(--bd);
}

.p-order-date {
  font-size: 0.78rem;
  color: var(--tm);
  margin-top: 2px;
}

.p-order-right {
  text-align: right;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 4px;
}

.p-order-price {
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--bd);
}

.profile-empty-state {
  text-align: center;
  padding: 24px 0;
}

.profile-empty-state .empty-ico {
  font-size: 2.4rem;
  display: block;
  margin-bottom: 8px;
}

.profile-empty-state p {
  color: var(--tm);
  font-size: 0.88rem;
  margin-bottom: 14px;
}

.btn-g-sm {
  display: inline-block;
  background: var(--gd);
  color: var(--bd);
  padding: 7px 16px;
  border-radius: 7px;
  font-size: 0.8rem;
  font-weight: 700;
  text-decoration: none;
}

/* ── GOOGLE CONNECTED BOX ── */
.google-connected-box {
  background: #f8fafd;
  border: 1.5px solid #d2e3fc;
  border-radius: 12px;
  padding: 18px 20px;
}

.google-conn-top {
  display: flex;
  align-items: center;
  gap: 14px;
}

.google-conn-top strong {
  display: block;
  font-size: 0.9rem;
  color: #1a73e8;
  margin-bottom: 2px;
}

.google-conn-top p {
  font-size: 0.8rem;
  color: var(--tm);
  margin: 0;
}

/* ── SIGN OUT CARD ── */
.profile-signout-card {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  background: #fff8f8;
  border: 1px solid #ffcdd2;
  border-radius: 12px;
  padding: 14px 18px;
}

.signout-text strong {
  display: block;
  font-size: 0.88rem;
  color: #b71c1c;
  margin-bottom: 2px;
}

.signout-text p {
  font-size: 0.78rem;
  color: var(--tm);
  margin: 0;
}

.btn-profile-signout-danger {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #d32f2f;
  color: #ffffff;
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 0.82rem;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
  transition: background 0.2s, transform 0.2s, box-shadow 0.2s;
}

.btn-profile-signout-danger:hover {
  background: #b71c1c;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(211, 47, 47, 0.3);
}

/* ── RESPONSIVE PROFILE ── */
@media(max-width: 900px) {
  .profile-stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .profile-grid {
    grid-template-columns: 1fr;
  }

  .profile-hero-card {
    padding: 28px 24px;
  }
}

@media(max-width: 580px) {
  .profile-hero-content {
    flex-direction: column;
    text-align: center;
  }

  .profile-badge-row {
    justify-content: center;
  }

  .profile-hero-actions {
    width: 100%;
    justify-content: center;
    flex-wrap: wrap;
  }

  .profile-stats-grid {
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }

  .profile-signout-card {
    flex-direction: column;
    text-align: center;
  }
}

/* ═══════════════════════════════════════════════════════════════
   FLOATING AI CHATBOT & WIDGET DESIGN SYSTEM
   ═══════════════════════════════════════════════════════════════ */

/* Re-position #btt smoothly above the chatbot button */
#btt {
  bottom: 92px !important;
  right: 28px !important;
}

/* ── FLOATING CHAT TRIGGER BUTTON ── */
.chat-floating-btn {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 990;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--bd) 0%, #1f0c03 100%);
  border: 2px solid var(--gd);
  color: var(--gd);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 24px rgba(58, 26, 8, 0.35), 0 0 16px rgba(212, 168, 67, 0.25);
  transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.25s;
  user-select: none;
}

.chat-floating-btn:hover {
  transform: scale(1.08) translateY(-2px);
  box-shadow: 0 12px 30px rgba(58, 26, 8, 0.45), 0 0 24px rgba(212, 168, 67, 0.4);
}

.chat-floating-btn:active {
  transform: scale(0.96);
}

.chat-btn-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  transition: transform 0.2s, opacity 0.2s;
}

.chat-btn-icon--ai svg {
  width: 26px;
  height: 26px;
  stroke: var(--gd);
}

.chat-sparkle-dot {
  position: absolute;
  top: -6px;
  right: -6px;
  font-size: 0.72rem;
  color: #fff4d1;
  animation: pulse-sparkle 1.8s infinite ease-in-out;
}

.chat-btn-icon--close {
  display: none;
  font-size: 1.4rem;
  font-weight: 700;
  color: #ffffff;
}

.chat-floating-btn.active .chat-btn-icon--ai {
  display: none;
}

.chat-floating-btn.active .chat-btn-icon--close {
  display: flex;
}

.chat-floating-btn.active {
  background: #2a1205;
  border-color: #f0e0c8;
}

.chat-badge-pulse {
  position: absolute;
  top: -3px;
  right: -3px;
  background: var(--gd);
  color: var(--bd);
  font-family: 'DM Sans', sans-serif;
  font-size: 0.62rem;
  font-weight: 800;
  padding: 1px 5px;
  border-radius: 10px;
  border: 1.5px solid var(--bd);
  line-height: 1.2;
}

@keyframes pulse-sparkle {
  0%, 100% { transform: scale(1); opacity: 0.8; }
  50% { transform: scale(1.35) rotate(15deg); opacity: 1; text-shadow: 0 0 8px #d4a843; }
}

/* ── CHATBOT WIDGET CONTAINER ── */
.chat-widget {
  position: fixed;
  bottom: 92px;
  right: 24px;
  z-index: 1000;
  width: 390px;
  max-width: calc(100vw - 32px);
  height: 540px;
  max-height: calc(100vh - 110px);
  background: #ffffff;
  border-radius: 20px;
  box-shadow: 0 20px 60px rgba(35, 14, 4, 0.3), 0 0 1px rgba(0, 0, 0, 0.2);
  border: 1.5px solid var(--cd);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
  transform: translateY(20px) scale(0.95);
  transform-origin: bottom right;
  transition: opacity 0.25s ease, transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.chat-widget.active {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0) scale(1);
}

/* ── CHAT HEADER ── */
.chat-header {
  background: linear-gradient(135deg, var(--bd) 0%, #2a1104 100%);
  padding: 14px 18px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--cr);
  border-bottom: 1px solid rgba(212, 168, 67, 0.2);
  flex-shrink: 0;
}

.chat-header-info {
  display: flex;
  align-items: center;
  gap: 10px;
}

.chat-avatar {
  position: relative;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(212, 168, 67, 0.2);
  border: 1.5px solid var(--gd);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
}

.chat-online-dot {
  position: absolute;
  bottom: 0;
  right: 0;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #4caf50;
  border: 2px solid var(--bd);
}

.chat-header-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--wh);
  margin: 0;
  line-height: 1.15;
}

.chat-header-sub {
  font-size: 0.72rem;
  color: var(--gd);
  display: block;
}

.chat-header-close {
  background: rgba(255, 255, 255, 0.08);
  border: none;
  color: rgba(253, 245, 236, 0.8);
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.95rem;
  transition: background 0.2s, color 0.2s;
}

.chat-header-close:hover {
  background: rgba(255, 255, 255, 0.2);
  color: #ffffff;
}

/* ── SUGGESTION PILLS ── */
.chat-suggestions {
  display: flex;
  gap: 6px;
  padding: 8px 14px;
  background: var(--cr);
  border-bottom: 1px solid var(--cd);
  overflow-x: auto;
  white-space: nowrap;
  scrollbar-width: none;
  flex-shrink: 0;
}

.chat-suggestions::-webkit-scrollbar {
  display: none;
}

.chat-pill-btn {
  background: #ffffff;
  border: 1px solid var(--cd);
  color: var(--bm);
  font-family: 'DM Sans', sans-serif;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 14px;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s, color 0.2s, transform 0.15s;
  flex-shrink: 0;
}

.chat-pill-btn:hover {
  background: var(--bd);
  color: var(--gd);
  border-color: var(--bd);
  transform: translateY(-1px);
}

/* ── MESSAGE HISTORY ── */
.chat-messages {
  flex: 1;
  padding: 16px 14px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 14px;
  background: #faf6f0;
}

.chat-msg {
  display: flex;
  gap: 8px;
  max-width: 88%;
}

.chat-msg--bot {
  align-self: flex-start;
}

.chat-msg--user {
  align-self: flex-end;
  flex-direction: row-reverse;
}

.chat-msg-avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--cr);
  border: 1px solid var(--cd);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  flex-shrink: 0;
  overflow: hidden;
}

.chat-btn-logo-img {
  width: 34px;
  height: 34px;
  object-fit: contain;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.4));
  transition: transform 0.2s ease;
}

.chat-floating-btn:hover .chat-btn-logo-img {
  transform: scale(1.08) rotate(3deg);
}

.chat-avatar-logo-img {
  width: 30px;
  height: 30px;
  object-fit: contain;
  border-radius: 50%;
}

.chat-bot-avatar-img {
  width: 22px;
  height: 22px;
  object-fit: contain;
  border-radius: 50%;
}

.chat-msg--user .chat-msg-avatar {
  background: var(--bw);
  color: #ffffff;
}

.chat-msg-bubble {
  padding: 10px 14px;
  border-radius: 14px;
  font-size: 0.84rem;
  line-height: 1.5;
  position: relative;
  word-break: break-word;
}

.chat-msg--bot .chat-msg-bubble {
  background: #ffffff;
  color: var(--tx);
  border: 1px solid var(--cd);
  border-top-left-radius: 4px;
  box-shadow: 0 2px 8px rgba(58, 26, 8, 0.04);
}

.chat-msg--user .chat-msg-bubble {
  background: var(--bw);
  color: #ffffff;
  border-top-right-radius: 4px;
}

.chat-msg-bubble strong {
  color: var(--bd);
}

.chat-msg--user .chat-msg-bubble strong {
  color: #ffffff;
}

.chat-msg-bubble ul {
  margin: 6px 0;
  padding-left: 18px;
}

.chat-msg-bubble li {
  margin-bottom: 3px;
}

.chat-msg-bubble code {
  background: rgba(212, 168, 67, 0.2);
  color: var(--bd);
  padding: 1px 4px;
  border-radius: 4px;
  font-size: 0.78rem;
  font-weight: 700;
}

.chat-msg--user .chat-msg-bubble code {
  background: rgba(255, 255, 255, 0.2);
  color: #ffffff;
}

.chat-msg-time {
  display: block;
  font-size: 0.65rem;
  color: var(--tm);
  margin-top: 5px;
  text-align: right;
  opacity: 0.8;
}

.chat-msg--user .chat-msg-time {
  color: rgba(255, 255, 255, 0.75);
}

/* ── TYPING INDICATOR ── */
.typing-dots {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-right: 6px;
}

.typing-dots span {
  width: 6px;
  height: 6px;
  background: var(--bm);
  border-radius: 50%;
  animation: typing-bounce 1.4s infinite ease-in-out both;
}

.typing-dots span:nth-child(1) { animation-delay: -0.32s; }
.typing-dots span:nth-child(2) { animation-delay: -0.16s; }

@keyframes typing-bounce {
  0%, 80%, 100% { transform: scale(0); opacity: 0.3; }
  40% { transform: scale(1); opacity: 1; }
}

.typing-text {
  font-size: 0.74rem;
  color: var(--tm);
  font-style: italic;
}

/* ── CHAT INPUT FOOTER ── */
.chat-input-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: #ffffff;
  border-top: 1px solid var(--cd);
  flex-shrink: 0;
}

.chat-input-field {
  flex: 1;
  padding: 9px 14px;
  border: 1.5px solid var(--cd);
  border-radius: 20px;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.84rem;
  color: var(--tx);
  background: var(--cr);
  outline: none;
  transition: border-color 0.2s, background 0.2s;
}

.chat-input-field:focus {
  border-color: var(--gd);
  background: #ffffff;
}

.chat-send-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--bw);
  border: none;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.2s, transform 0.15s;
}

.chat-send-btn:hover {
  background: var(--bd);
  transform: scale(1.08);
}

.chat-send-btn svg {
  width: 16px;
  height: 16px;
  margin-left: 2px;
}

.chat-footer-note {
  font-size: 0.65rem;
  text-align: center;
  color: var(--tm);
  background: var(--cr);
  padding: 4px 10px;
  border-top: 1px solid rgba(240, 224, 200, 0.5);
  flex-shrink: 0;
}

/* ═══════════════════════════════════════════════════════════════
   COMPREHENSIVE MOBILE RESPONSIVENESS SUITE (<= 580px & <= 380px)
   ═══════════════════════════════════════════════════════════════ */

@media (max-width: 580px) {
  /* Chatbot Widget & Floating Button */
  .chat-widget {
    bottom: 76px;
    right: 10px;
    left: 10px;
    width: auto;
    max-width: none;
    height: min(490px, calc(100vh - 105px));
    border-radius: 16px;
    box-shadow: 0 16px 40px rgba(35, 14, 4, 0.35);
  }

  .chat-header {
    padding: 12px 14px;
  }

  .chat-avatar {
    width: 32px;
    height: 32px;
  }

  .chat-avatar-logo-img {
    width: 24px;
    height: 24px;
  }

  .chat-header-title {
    font-size: 0.95rem;
  }

  .chat-header-sub {
    font-size: 0.68rem;
  }

  .chat-suggestions {
    padding: 6px 10px;
    gap: 5px;
    -webkit-overflow-scrolling: touch;
  }

  .chat-pill-btn {
    font-size: 0.68rem;
    padding: 3px 8px;
  }

  .chat-messages {
    padding: 12px 10px;
    gap: 10px;
  }

  .chat-msg {
    max-width: 94%;
  }

  .chat-msg-bubble {
    padding: 8px 12px;
    font-size: 0.8rem;
  }

  .chat-input-row {
    padding: 8px 10px;
    gap: 6px;
  }

  .chat-input-field {
    padding: 7px 12px;
    font-size: 0.8rem;
  }

  .chat-send-btn {
    width: 32px;
    height: 32px;
  }

  .chat-floating-btn {
    bottom: 16px;
    right: 16px;
    width: 50px;
    height: 50px;
  }

  .chat-btn-logo-img {
    width: 28px;
    height: 28px;
  }

  #btt {
    bottom: 76px !important;
    right: 18px !important;
    width: 38px !important;
    height: 38px !important;
    font-size: 0.85rem !important;
  }

  /* Cart Layout & Items */
  #cart-page {
    padding: 110px 14px 60px;
  }

  .cart-item {
    padding: 12px;
    gap: 12px;
    flex-wrap: wrap;
  }

  .cart-item img {
    width: 58px;
    height: 58px;
  }

  .cart-item-body h3 {
    font-size: 0.95rem;
  }

  .cart-item-shop {
    font-size: 0.72rem;
  }

  .cart-item-controls {
    gap: 6px;
  }

  .qty-input {
    width: 68px;
    padding: 5px 7px;
    font-size: 0.8rem;
  }

  .qty-update-btn, .remove-btn {
    padding: 5px 8px;
    font-size: 0.74rem;
  }

  .cart-item-price {
    width: 100%;
    text-align: left;
    margin-top: 4px;
    font-size: 0.98rem;
    border-top: 1px dashed var(--cd);
    padding-top: 6px;
  }

  .cart-summary {
    padding: 18px 14px;
    border-radius: 12px;
  }

  /* Checkout Layout */
  #checkout-page {
    padding: 110px 14px 60px;
  }

  .checkout-form-card {
    padding: 20px 14px;
    border-radius: 12px;
  }

  .checkout-form-card h2 {
    font-size: 1.15rem;
    margin-bottom: 14px;
  }

  .pay-method-option {
    padding: 10px 12px;
    font-size: 0.82rem;
  }

  .order-review {
    padding: 18px 14px;
    border-radius: 12px;
  }

  /* Orders & Order Details */
  #orders-page,
  #order-detail-page {
    padding: 110px 14px 60px;
  }

  .order-card {
    padding: 16px 12px;
    border-radius: 12px;
  }

  .order-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
  }

  .tracker {
    padding: 14px 4px;
    margin: 14px 0 20px;
  }

  .tracker-step {
    min-width: 58px;
  }

  .tracker-num {
    width: 26px;
    height: 26px;
    font-size: 0.74rem;
  }

  .tracker-label {
    font-size: 0.58rem;
    letter-spacing: 0;
  }

  .order-item {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    padding: 10px 0;
  }

  .order-item-total {
    text-align: left;
    font-weight: 700;
  }

  /* Buyer Profile */
  #profile-page {
    padding: 110px 14px 60px;
  }

  .profile-card {
    padding: 18px 14px;
    border-radius: 12px;
  }

  .profile-user-badge {
    padding: 14px 12px;
    gap: 12px;
  }

  .profile-user-avatar {
    width: 44px;
    height: 44px;
    font-size: 1.1rem;
  }

  .profile-user-name {
    font-size: 1.05rem;
  }

  .profile-stats-grid {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }

  .profile-stat-card {
    padding: 12px 10px;
  }

  .profile-stat-value {
    font-size: 1.15rem;
  }

  .profile-stat-label {
    font-size: 0.65rem;
  }
}

@media (max-width: 360px) {
  .chat-widget {
    height: 420px;
    bottom: 70px;
    left: 6px;
    right: 6px;
  }

  .profile-stats-grid {
    grid-template-columns: 1fr;
  }
}