:root {
  --bg: #fff8f0;
  --bg-2: #f7dde8;
  --card: rgba(255, 255, 255, 0.86);
  --text: #261d21;
  --muted: #7c6f75;
  --primary: #7a1f3d;
  --primary-2: #a22f58;
  --accent: #d4af37;
  --line: rgba(122, 31, 61, 0.13);
  --shadow: 0 24px 80px rgba(59, 22, 38, 0.13);
  --radius: 26px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(circle at 12% 10%, rgba(247, 221, 232, 0.95), transparent 28rem),
    radial-gradient(circle at 86% 18%, rgba(212, 175, 55, 0.18), transparent 26rem),
    linear-gradient(135deg, var(--bg) 0%, #fff 45%, #fff7fb 100%);
  min-height: 100vh;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.28;
  background-image:
    linear-gradient(45deg, rgba(122,31,61,.05) 25%, transparent 25%),
    linear-gradient(-45deg, rgba(122,31,61,.04) 25%, transparent 25%);
  background-size: 38px 38px;
  mask-image: linear-gradient(to bottom, #000 0%, transparent 72%);
}

button, input, textarea, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

.page-shell { width: min(1500px, calc(100% - 32px)); margin: 0 auto; padding: 14px 0 56px; }
.glass {
  background: var(--card);
  backdrop-filter: blur(18px);
  border: 1px solid rgba(255,255,255,0.72);
  box-shadow: var(--shadow);
}
.site-header {
  position: sticky;
  top: 12px;
  z-index: 20;
  display: grid;
  grid-template-columns: auto minmax(260px, 1fr) auto;
  align-items: center;
  gap: 24px;
  padding: 14px 18px;
  border-radius: 28px;
}
.brand { display: flex; align-items: center; gap: 12px; min-width: 245px; }
.brand-mark {
  width: 48px; height: 48px; border-radius: 16px;
  display: grid; place-items: center;
  color: white; font-weight: 900; letter-spacing: -1px;
  background: linear-gradient(135deg, var(--primary), #f0649a);
  box-shadow: 0 12px 28px rgba(122,31,61,.22);
}
.brand strong { display:block; font-size: 1.18rem; letter-spacing: -0.03em; }
.brand small { color: var(--muted); font-size: .78rem; }
.search-box { display: flex; align-items: center; padding: 7px; border: 1px solid var(--line); border-radius: 22px; background: white; }
.search-box input { border: 0; outline: 0; background: transparent; flex: 1; padding: 0 16px; font-size: 1rem; min-height: 44px; }
.search-box button { border: 0; width: 46px; height: 46px; border-radius: 16px; background: var(--primary); color: white; font-size: 1.4rem; cursor: pointer; transition: transform .2s ease, background .2s ease; }
.search-box button:hover { transform: scale(1.04); background: var(--primary-2); }
.header-actions { display: flex; align-items: center; gap: 10px; }
.ghost-btn, .soft-btn, .outline-btn, .primary-btn, .whatsapp-mini {
  border: 0; cursor: pointer; border-radius: 16px; min-height: 44px; padding: 0 18px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; font-weight: 750; transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}
.ghost-btn { background: white; color: var(--primary); border: 1px solid var(--line); }
.soft-btn { background: #fff1f7; color: var(--primary); border: 1px solid rgba(122,31,61,.1); }
.outline-btn { background: white; color: var(--primary); border: 1px solid rgba(122,31,61,.2); }
.primary-btn { background: linear-gradient(135deg, var(--primary), var(--primary-2)); color: white; box-shadow: 0 18px 38px rgba(122,31,61,.25); }
.whatsapp-mini { background: #eafff2; color: #087b3a; border: 1px solid rgba(8,123,58,.15); }
.ghost-btn:hover, .soft-btn:hover, .outline-btn:hover, .primary-btn:hover, .whatsapp-mini:hover { transform: translateY(-2px); }
.full { width: 100%; }
.cart-button { display: flex; align-items: center; gap: 8px; border: 0; padding: 9px 14px; border-radius: 17px; background: #1f1a1d; color: white; cursor: pointer; transition: transform .2s ease; }
.cart-button strong { background: var(--accent); color: #2a2207; border-radius: 999px; min-width: 25px; height: 25px; display: grid; place-items: center; }
.cart-button.bump { animation: bump .42s ease; }
.avatar-btn { width: 44px; height: 44px; border: 0; border-radius: 50%; background: var(--accent); color: #2a2207; font-weight: 900; cursor: pointer; }
.hidden { display: none !important; }

.hero { display: grid; grid-template-columns: 1.08fr .92fr; gap: 36px; align-items: center; padding: 62px 10px 34px; }
.hero-copy h1 { font-size: clamp(2.5rem, 5vw, 5.9rem); line-height: .94; letter-spacing: -0.075em; margin: 10px 0 20px; max-width: 850px; }
.hero-copy p { color: var(--muted); font-size: 1.13rem; line-height: 1.7; max-width: 630px; }
.eyebrow { margin: 0; color: var(--primary); text-transform: uppercase; letter-spacing: .16em; font-size: .75rem; font-weight: 900; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 30px; }
.hero-card { position: relative; border-radius: 38px; padding: 12px; background: rgba(255,255,255,.8); box-shadow: var(--shadow); transform: rotate(1deg); overflow: hidden; }
.hero-card img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; border-radius: 30px; }
.floating-badge, .save-badge {
  position: absolute; top: 22px; right: 22px; color: #1e200d; background: linear-gradient(135deg, #f2d86a, var(--accent)); border-radius: 999px; padding: 9px 14px; font-weight: 900; box-shadow: 0 14px 34px rgba(84,69,13,.18); animation: softPulse 2.3s ease-in-out infinite;
}
.quick-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin: 10px 0 26px; }
.quick-stats div { padding: 20px; border: 1px solid var(--line); border-radius: 22px; background: rgba(255,255,255,.62); }
.quick-stats strong { display:block; margin-bottom: 6px; }
.quick-stats span { color: var(--muted); font-size: .93rem; }
.store-grid { display: grid; grid-template-columns: 290px 1fr; gap: 24px; align-items: start; }
.sidebar, .catalog { border-radius: var(--radius); overflow: hidden; }
.sidebar { position: sticky; top: 104px; padding: 18px; max-height: calc(100vh - 130px); }
.sidebar-title { font-size: 1.1rem; font-weight: 900; padding: 8px 8px 18px; }
.category-list { display: grid; gap: 8px; }
.category-item { border: 0; background: white; text-align: left; border-radius: 16px; padding: 16px; font-weight: 760; cursor: pointer; color: var(--text); transition: transform .2s ease, background .2s ease, color .2s ease; }
.category-item:hover { transform: translateX(4px); }
.category-item.active { background: var(--primary); color: white; }
.catalog { padding: 20px; }
.catalog-top { display: flex; justify-content: space-between; align-items: center; gap: 18px; margin-bottom: 18px; }
.catalog-top h2 { margin: 4px 0 0; letter-spacing: -0.04em; }
.sort-control { display: flex; align-items: center; gap: 10px; color: var(--muted); font-weight: 650; }
.sort-control select { border: 1px solid var(--line); background: white; padding: 12px 14px; border-radius: 15px; outline: 0; }
.product-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.product-card { position: relative; background: white; border: 1px solid rgba(122,31,61,.08); border-radius: 24px; overflow: hidden; box-shadow: 0 15px 40px rgba(43,31,36,.06); transition: transform .24s ease, box-shadow .24s ease; }
.product-card:hover { transform: translateY(-7px); box-shadow: 0 26px 60px rgba(43,31,36,.12); }
.image-button { position: relative; display: block; width: 100%; border: 0; background: transparent; padding: 0; cursor: zoom-in; overflow: hidden; }
.image-button img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; transition: transform .45s ease; }
.product-card:hover .image-button img { transform: scale(1.055); }
.save-badge { top: 14px; right: 14px; font-size: .78rem; padding: 7px 10px; }
.product-info { padding: 18px; }
.product-code { display: inline-flex; width: fit-content; font-weight: 900; font-size: .77rem; color: var(--primary); background: #fff1f7; border-radius: 999px; padding: 6px 10px; margin-bottom: 10px; }
.product-info h3 { font-size: 1.08rem; min-height: 2.65em; line-height: 1.3; letter-spacing: -0.025em; margin: 0 0 12px; }
.price-line { display: flex; align-items: baseline; gap: 9px; flex-wrap: wrap; }
.price-line .mrp { color: #ff4c5f; text-decoration: line-through; }
.price-line strong { font-size: 1.35rem; }
.price-line em { font-style: normal; color: #087b3a; font-weight: 900; font-size: .84rem; }
.price-line.large strong { font-size: 2rem; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; margin: 14px 0; }
.chips span { color: var(--muted); background: #f8f1f4; border-radius: 999px; padding: 6px 9px; font-size: .78rem; font-weight: 700; }
.card-actions { display: grid; grid-template-columns: 1fr auto; gap: 9px; }
.empty-state, .empty-cart { padding: 30px; text-align: center; color: var(--muted); border: 1px dashed var(--line); border-radius: 20px; background: rgba(255,255,255,.7); }

.modal-backdrop, .drawer-overlay { position: fixed; inset: 0; z-index: 40; background: rgba(25,18,22,.44); backdrop-filter: blur(10px); display: grid; place-items: center; padding: 20px; }
.product-modal, .checkout-modal { position: relative; width: min(1080px, 96vw); max-height: 92vh; overflow: auto; border-radius: 30px; padding: 24px; animation: modalIn .22s ease both; }
.icon-close { position: absolute; top: 14px; right: 14px; z-index: 2; border: 0; width: 42px; height: 42px; border-radius: 50%; background: white; font-size: 1.5rem; cursor: pointer; }
.modal-grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: 28px; }
.modal-image-wrap { position: relative; border-radius: 24px; overflow: hidden; background: white; }
.modal-image-wrap img { aspect-ratio: 4 / 5; object-fit: cover; width: 100%; }
.modal-save { top: 18px; right: 18px; }
.modal-copy h2 { font-size: clamp(2rem, 4vw, 3.4rem); line-height: .96; letter-spacing: -0.06em; margin: 8px 0 14px; }
.modal-copy p { color: var(--muted); line-height: 1.7; }
.detail-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin: 20px 0; }
.detail-list div { background: rgba(255,255,255,.75); border: 1px solid var(--line); border-radius: 16px; padding: 14px; }
.detail-list span { display: block; color: var(--muted); font-size: .78rem; margin-bottom: 4px; }
.modal-actions { display: flex; gap: 10px; flex-wrap: wrap; }

.cart-drawer { position: fixed; top: 0; right: 0; z-index: 50; width: min(440px, 94vw); height: 100vh; background: #fffdfb; box-shadow: -30px 0 80px rgba(35,20,27,.22); transform: translateX(105%); transition: transform .32s cubic-bezier(.2,.8,.2,1); padding: 20px; display: flex; flex-direction: column; }
.cart-drawer.open { transform: translateX(0); }
.drawer-overlay { z-index: 45; display: block; }
.drawer-head { display: flex; justify-content: space-between; gap: 16px; align-items: center; }
.cart-items { flex: 1; overflow: auto; padding: 20px 0; display: grid; gap: 12px; align-content: start; }
.cart-item { display: grid; grid-template-columns: 74px 1fr auto; gap: 12px; align-items: center; padding: 10px; border: 1px solid var(--line); border-radius: 18px; background: white; }
.cart-item img { width: 74px; height: 74px; border-radius: 14px; object-fit: cover; }
.cart-item strong, .cart-item span, .cart-item small { display: block; }
.cart-item span { color: var(--primary); font-weight: 800; font-size: .78rem; }
.cart-item small { color: var(--muted); margin-top: 3px; }
.qty-control { display: grid; grid-template-columns: 28px 26px 28px; gap: 3px; align-items: center; text-align: center; }
.qty-control button { border: 0; border-radius: 9px; height: 28px; cursor: pointer; background: #fff1f7; color: var(--primary); font-weight: 900; }
.cart-summary { border-top: 1px solid var(--line); padding-top: 16px; display: grid; gap: 10px; }
.cart-summary div { display: flex; justify-content: space-between; color: var(--muted); }
.cart-summary .grand { color: var(--text); font-size: 1.2rem; }

.checkout-modal { width: min(760px, 96vw); }
.checkout-modal h2 { font-size: 2.3rem; letter-spacing: -0.06em; margin: 8px 0; }
.checkout-note, .muted { color: var(--muted); }
.checkout-form { display: grid; gap: 14px; margin-top: 18px; }
.form-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.form-row:has(label:nth-child(3)) { grid-template-columns: repeat(3, minmax(0, 1fr)); }
label { display: grid; gap: 7px; font-weight: 760; }
input, textarea, select { width: 100%; border: 1px solid var(--line); background: white; border-radius: 15px; padding: 13px 14px; outline: 0; }
textarea { min-height: 92px; resize: vertical; }
.success-box { padding: 18px; border-radius: 18px; background: #ecfff4; color: #087b3a; border: 1px solid rgba(8,123,58,.14); }
.success-box strong, .success-box span { display: block; }

.admin-layout { display: grid; grid-template-columns: 1.2fr .8fr; gap: 22px; padding-top: 30px; }
.admin-card { border-radius: var(--radius); padding: 24px; }
.admin-product-list { display: grid; gap: 12px; margin: 18px 0; }
.admin-product-row { display: grid; grid-template-columns: 62px 1fr auto; align-items: center; gap: 12px; padding: 10px; border: 1px solid var(--line); border-radius: 18px; background: white; }
.admin-product-row img { width: 62px; height: 62px; border-radius: 14px; object-fit: cover; }
.admin-product-row span, .admin-product-row small { display: block; color: var(--muted); }

.reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s ease; }
.reveal.visible { opacity: 1; transform: translateY(0); }
@keyframes bump { 0%,100%{transform:scale(1)} 45%{transform:scale(1.11)} }
@keyframes softPulse { 0%,100%{transform:scale(1)} 50%{transform:scale(1.04)} }
@keyframes modalIn { from{opacity:0; transform: translateY(12px) scale(.985)} to{opacity:1; transform: translateY(0) scale(1)} }

@media (max-width: 1100px) {
  .site-header { grid-template-columns: 1fr; }
  .brand { min-width: 0; }
  .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hero { grid-template-columns: 1fr; }
  .store-grid { grid-template-columns: 1fr; }
  .sidebar { position: static; max-height: none; }
  .category-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .admin-layout { grid-template-columns: 1fr; }
}
@media (max-width: 680px) {
  .page-shell { width: min(100% - 20px, 1500px); }
  .site-header { top: 8px; gap: 12px; padding: 12px; border-radius: 22px; }
  .header-actions { display: grid; grid-template-columns: 1fr auto; }
  .hero { padding-top: 34px; gap: 22px; }
  .hero-copy h1 { font-size: 2.75rem; }
  .quick-stats, .product-grid, .modal-grid, .form-row, .form-row:has(label:nth-child(3)) { grid-template-columns: 1fr; }
  .catalog-top { align-items: stretch; flex-direction: column; }
  .category-list { grid-template-columns: 1fr; }
  .card-actions { grid-template-columns: 1fr; }
  .detail-list { grid-template-columns: 1fr; }
  .cart-item { grid-template-columns: 64px 1fr; }
  .qty-control { grid-column: 2; justify-self: start; }
}

/* v15 dedicated auth/account/order pages */
.slim-header { grid-template-columns: 1fr auto; }
.auth-page { min-height: 100vh; }
.auth-shell { min-height: calc(100vh - 110px); display: grid; place-items: center; padding: 34px 0; }
.auth-card, .account-card, .orders-shell { border-radius: 34px; padding: clamp(24px, 4vw, 42px); }
.auth-card { width: min(720px, 100%); text-align: left; }
.center-card { text-align: center; }
.center-mark { margin: 0 auto 16px; }
.auth-card h1, .account-card h1, .orders-shell h1 { font-size: clamp(2.45rem, 6vw, 4.6rem); line-height: .94; letter-spacing: -0.075em; margin: 10px 0 16px; }
.google-signin-btn { width: 100%; min-height: 58px; border: 0; border-radius: 18px; background: #fff; color: var(--text); box-shadow: 0 14px 38px rgba(43,31,36,.09); border: 1px solid var(--line); margin: 22px 0 12px; display: flex; align-items: center; justify-content: center; gap: 12px; font-weight: 900; cursor: pointer; transition: transform .2s ease, box-shadow .2s ease; }
.google-signin-btn:hover { transform: translateY(-2px); box-shadow: 0 22px 55px rgba(43,31,36,.13); }
.google-signin-btn:disabled { opacity: .65; cursor: not-allowed; transform: none; }
.google-dot { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; background: linear-gradient(135deg,#4285f4,#34a853,#fbbc05,#ea4335); color: white; font-weight: 900; }
.auth-message { border-radius: 16px; padding: 14px 16px; background: rgba(255,255,255,.72); border: 1px solid var(--line); }
.auth-message.success { color: #087b3a; background: #ecfff4; border-color: rgba(8,123,58,.16); }
.auth-message.error { color: #9b1230; background: #fff1f4; border-color: rgba(155,18,48,.18); }
.auth-benefits { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 22px; }
.auth-benefits div { background: rgba(255,255,255,.62); border: 1px solid var(--line); border-radius: 20px; padding: 16px; }
.auth-benefits strong, .auth-benefits span { display:block; }
.auth-benefits span { color: var(--muted); font-size: .9rem; margin-top: 5px; }
.account-grid { display: grid; grid-template-columns: minmax(0,1fr) 350px; gap: 22px; padding-top: 30px; }
.profile-row { display: flex; gap: 18px; align-items: center; margin: 18px 0 24px; }
.profile-row img, .avatar-large { width: 88px; height: 88px; border-radius: 28px; object-fit: cover; box-shadow: 0 16px 42px rgba(122,31,61,.15); }
.avatar-large { display: grid; place-items: center; color: white; font-size: 2rem; font-weight: 900; background: linear-gradient(135deg,var(--primary),#f0649a); }
.account-details strong { overflow-wrap: anywhere; }
.account-actions { display: grid; gap: 12px; margin-top: 14px; }
.orders-shell { margin-top: 30px; }
.orders-list { display: grid; gap: 14px; margin-top: 22px; }
.order-card { display: grid; gap: 12px; padding: 18px; background: white; border: 1px solid var(--line); border-radius: 22px; box-shadow: 0 14px 34px rgba(43,31,36,.06); }
.order-card strong, .order-card span { display: block; }
.order-card span { color: var(--muted); font-size: .9rem; }
.order-status-row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.order-status-row span { color: var(--primary); background: #fff1f7; border-radius: 999px; padding: 8px 12px; font-weight: 850; }
.order-status-row b { margin-left: auto; font-size: 1.15rem; }
@media (max-width: 780px) {
  .slim-header { grid-template-columns: 1fr; }
  .auth-benefits, .account-grid { grid-template-columns: 1fr; }
  .account-card h1, .auth-card h1, .orders-shell h1 { font-size: 2.7rem; }
  .order-status-row b { margin-left: 0; width: 100%; }
}
