:root {
  --bg-cream: #FAF5EE;
  --bg-warm: #F3E8D8;
  --bg-card: #FFFDF9;
  --bg-admin: #F6F1E9;
  --gold: #C59B5F;
  --gold-dark: #9D743B;
  --gold-light: #E6CB9A;
  --gold-soft: rgba(197, 155, 95, 0.14);
  --ink: #1A1614;
  --ink-soft: #3D322C;
  --ink-muted: #706055;
  --emerald: #234F3E;
  --rose: #8E4A49;
  --danger: #B43D3D;
  --border: rgba(197, 155, 95, 0.28);
  --border-soft: rgba(61, 50, 44, 0.09);
  --shadow-sm: 0 4px 14px rgba(45, 31, 20, 0.05);
  --shadow-md: 0 12px 32px rgba(45, 31, 20, 0.09);
  --shadow-lg: 0 22px 54px rgba(32, 21, 14, 0.16);
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --font-main: 'Vazirmatn', Tahoma, 'Segoe UI', Arial, sans-serif;
}

*, *::before, *::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  overflow-x: clip;
}

body {
  margin: 0;
  font-family: var(--font-main);
  background: var(--bg-cream);
  color: var(--ink);
  line-height: 1.7;
  direction: rtl;
  overflow-x: clip;
  -webkit-font-smoothing: antialiased;
}

.hero-grid > *,
.editorial-grid > *,
.about-grid > *,
.products-grid > *,
.kpi-grid > *,
.dashboard-panels > *,
.inventory-split > *,
.admin-shell > * {
  min-width: 0;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

button, input, select, textarea {
  font-family: inherit;
}

code {
  background: var(--bg-warm);
  padding: 2px 7px;
  border-radius: 6px;
  font-size: 0.88em;
  color: var(--gold-dark);
  direction: ltr;
  unicode-bidi: isolate;
  display: inline-block;
}

.hidden {
  display: none !important;
}

.container {
  width: min(1360px, calc(100% - clamp(24px, 4vw, 56px)));
  margin-inline: auto;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  font-weight: 600;
  font-size: 0.92rem;
  cursor: pointer;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease, border-color 0.18s ease;
}

.btn:active {
  transform: translateY(1px);
}

.btn-lg {
  padding: 13px 24px;
  font-size: 0.98rem;
  border-radius: 12px;
}

.btn-sm {
  padding: 6px 12px;
  font-size: 0.82rem;
}

.btn-block {
  width: 100%;
}

.btn-gold {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #D5AE72 0%, #B48646 100%);
  color: #FFFDF9;
  box-shadow: 0 8px 20px rgba(180, 134, 70, 0.28);
}

.btn-gold::after {
  content: '';
  position: absolute;
  top: -20%;
  left: -60%;
  width: 38%;
  height: 140%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.42), transparent);
  transform: skewX(-24deg);
  animation: sheenSweep 4.2s ease-in-out infinite;
  pointer-events: none;
}

.btn-gold:hover {
  background: linear-gradient(135deg, #DDB87E 0%, #A37638 100%);
  transform: translateY(-2px);
  box-shadow: 0 12px 26px rgba(180, 134, 70, 0.36);
}

.btn-gold:hover::after {
  animation-duration: 1.1s;
}

.btn-outline {
  background: var(--bg-card);
  border-color: var(--border);
  color: var(--ink-soft);
}

.btn-outline:hover {
  border-color: var(--gold);
  background: var(--bg-warm);
}

.btn-ghost {
  background: transparent;
  border-color: transparent;
  color: var(--gold-dark);
}

.btn-ghost:hover {
  background: var(--gold-soft);
}

.btn-danger {
  background: #FCECEC;
  color: var(--danger);
  border-color: rgba(180, 61, 61, 0.25);
}

.btn-danger:hover {
  background: var(--danger);
  color: #fff;
}

.link-btn {
  background: none;
  border: none;
  color: var(--gold-dark);
  font-weight: 600;
  cursor: pointer;
  padding: 0;
  font-size: inherit;
}

.link-btn:hover {
  text-decoration: underline;
}

/* Form Inputs */
.form-input, .form-select, .form-textarea {
  width: 100%;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: #FFFDFB;
  color: var(--ink);
  font-size: 0.92rem;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.form-input:focus, .form-select:focus, .form-textarea:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(197, 155, 95, 0.16);
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-group label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--ink-soft);
}

.form-row-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}

.form-row-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

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

.checkbox-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  font-size: 0.88rem;
  font-weight: 500;
  cursor: pointer;
  user-select: none;
}

/* Top Bar */
.top-bar {
  background: var(--ink);
  color: #F6EFE6;
  font-size: 0.83rem;
  padding: 8px 0;
  border-bottom: 1px solid rgba(197, 155, 95, 0.35);
}

.top-bar-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 16px;
  flex-wrap: wrap;
}

.top-announcement {
  display: flex;
  align-items: center;
  gap: 9px;
}

.pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gold-light);
  box-shadow: 0 0 0 4px rgba(230, 203, 154, 0.2);
}

.top-controls {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.sync-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  font-size: 0.78rem;
  color: #E7D9C6;
}

.admin-topbar .sync-badge {
  background: rgba(35, 79, 62, 0.08);
  border: 1px solid rgba(35, 79, 62, 0.25);
  color: var(--emerald);
  font-weight: 600;
}

.admin-topbar .sync-badge.offline {
  background: rgba(197, 155, 95, 0.16);
  border-color: rgba(157, 116, 59, 0.45);
  color: #7A521B;
}

.sync-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #4ADE80;
}

.sync-badge.offline .sync-dot {
  background: #FBBF24;
}

.mode-switcher {
  display: inline-flex;
  background: rgba(255, 255, 255, 0.08);
  padding: 3px;
  border-radius: 999px;
  border: 1px solid rgba(197, 155, 95, 0.3);
}

.mode-btn {
  border: none;
  background: transparent;
  color: #E7D9C6;
  padding: 5px 14px;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.mode-btn.active {
  background: linear-gradient(135deg, #D5AE72, #B48646);
  color: #FFFDF9;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
}

/* Header */
.shop-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(250, 245, 238, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 0;
}

.icon-btn.mobile-menu-btn {
  display: none;
  font-size: 1.2rem;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.brand-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: #FFFFFF;
  object-fit: contain;
  padding: 2px;
  border: 2px solid var(--gold);
  box-shadow: var(--shadow-sm);
}

.brand-text {
  display: flex;
  flex-direction: column;
}

.brand-text strong {
  font-size: 1.08rem;
  font-weight: 800;
  line-height: 1.25;
}

.brand-text span {
  font-size: 0.76rem;
  color: var(--gold-dark);
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 2px;
  flex-wrap: nowrap;
  min-width: 0;
}

.nav-link {
  background: transparent;
  border: none;
  padding: 6px 9px;
  border-radius: 9px;
  color: var(--ink-soft);
  font-size: 0.84rem;
  font-weight: 600;
  white-space: nowrap;
  flex-shrink: 0;
  cursor: pointer;
  transition: background 0.18s, color 0.18s;
}

.nav-link:hover, .nav-link.active {
  background: var(--gold-soft);
  color: var(--gold-dark);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.search-wrap {
  position: relative;
  width: clamp(148px, 14vw, 220px);
}

.search-input {
  width: 100%;
  padding: 8px 34px 8px 12px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--bg-card);
  font-size: 0.85rem;
  outline: none;
}

.search-input:focus {
  border-color: var(--gold);
}

.search-icon {
  position: absolute;
  right: 11px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 0.85rem;
  pointer-events: none;
}

.icon-btn {
  position: relative;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--bg-card);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 1.05rem;
}

.icon-btn .badge {
  position: absolute;
  top: -4px;
  left: -4px;
  background: var(--rose);
  color: #fff;
  font-size: 0.7rem;
  min-width: 18px;
  height: 18px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  padding: 0 4px;
}

.cart-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 15px;
  border-radius: 999px;
  border: 1px solid var(--gold);
  background: var(--ink);
  color: #FFFDF9;
  font-weight: 600;
  font-size: 0.88rem;
  white-space: nowrap;
  flex-shrink: 0;
  cursor: pointer;
  transition: transform 0.15s;
}

.cart-btn:hover {
  transform: translateY(-1px);
}

.cart-btn.cart-bump {
  animation: cartBump 0.48s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.cart-count {
  background: var(--gold);
  color: #1A1614;
  font-weight: 800;
  min-width: 22px;
  height: 22px;
  border-radius: 999px;
  display: inline-grid;
  place-items: center;
  padding: 0 6px;
  font-size: 0.8rem;
}

/* Hero Section */
.hero-section {
  padding: 46px 0 40px;
  overflow-x: clip;
  background:
    radial-gradient(circle at 18% 20%, rgba(197, 155, 95, 0.2), transparent 46%),
    radial-gradient(circle at 85% 80%, rgba(142, 74, 73, 0.09), transparent 40%),
    linear-gradient(180deg, #FAF5EE 0%, #F4EADF 100%);
  border-bottom: 1px solid var(--border);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.25fr 0.95fr;
  gap: 40px;
  align-items: center;
}

.hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: 999px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--gold-dark);
  font-size: 0.83rem;
  font-weight: 700;
  margin-bottom: 16px;
}

.hero-title {
  margin: 0 0 16px;
  font-size: clamp(1.9rem, 3.6vw, 2.85rem);
  font-weight: 900;
  line-height: 1.3;
  color: var(--ink);
}

.gold-text {
  background: linear-gradient(135deg, #B58644, #D2A86B, #8C632C);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-slogan-line {
  font-size: 0.72em;
  font-weight: 700;
  color: var(--ink-soft);
}

.hero-subtitle {
  margin: 0 0 24px;
  font-size: 1.03rem;
  color: var(--ink-muted);
  max-width: 600px;
}

.hero-cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 24px;
}

.hero-trust-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 22px;
  padding-top: 16px;
  border-top: 1px dashed var(--border);
  font-size: 0.86rem;
  color: var(--ink-soft);
}

.trust-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.hero-showcase {
  display: flex;
  justify-content: center;
}

.hero-arch-frame {
  position: relative;
  width: min(460px, 100%);
  padding: 18px;
  background: #FFFFFF;
  border: 2px solid var(--gold);
  border-radius: 28px;
  box-shadow: var(--shadow-lg), inset 0 0 0 5px #FAF5EE, inset 0 0 0 6px rgba(197, 155, 95, 0.38);
  text-align: center;
  animation: fadeInScale 0.7s ease-out both;
}

.hero-arch-frame::before {
  content: '';
  position: absolute;
  inset: -14px;
  border-radius: 36px;
  background: radial-gradient(circle at 50% 42%, rgba(213, 174, 114, 0.34), transparent 72%);
  z-index: -1;
  animation: auraPulse 4.5s ease-in-out infinite;
}

.hero-logo-main {
  width: 100%;
  max-width: 420px;
  height: auto;
  object-fit: contain;
  border-radius: 18px;
  display: block;
  margin: 0 auto;
  transition: transform 0.5s ease;
}

.hero-arch-frame:hover .hero-logo-main {
  transform: scale(1.02);
}

.hero-badges-strip {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.hero-floating-card {
  position: static;
  display: flex;
  align-items: center;
  gap: 8px;
  background: #FAF5EE;
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 8px 12px;
  box-shadow: var(--shadow-sm);
  text-align: right;
  font-size: 0.76rem;
}

.hero-floating-card strong {
  display: block;
  font-size: 0.82rem;
}

.hero-floating-card small {
  color: var(--ink-muted);
  font-size: 0.72rem;
}

.floating-dot {
  width: 10px;
  height: 10px;
  flex-shrink: 0;
  border-radius: 50%;
  background: var(--emerald);
  box-shadow: 0 0 0 4px rgba(35, 79, 62, 0.15);
}

.floating-mini-logo {
  width: 34px;
  height: 34px;
  flex-shrink: 0;
  border-radius: 50%;
  background: #FFFFFF;
  object-fit: contain;
  padding: 2px;
  border: 1px solid var(--gold);
}

/* Instagram Story Highlights */
.highlights-section {
  padding: 26px 0 18px;
  background: var(--bg-card);
  border-bottom: 1px solid var(--border-soft);
}

.section-mini-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.section-mini-header h2 {
  margin: 0;
  font-size: 1.08rem;
  font-weight: 800;
}

.en-tag {
  font-size: 0.85rem;
  color: var(--gold-dark);
  font-weight: 600;
  direction: ltr;
  display: inline-block;
}

.section-mini-header p {
  margin: 0;
  font-size: 0.82rem;
  color: var(--ink-muted);
}

.highlights-strip {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  overflow-x: auto;
  padding: 4px 10px 10px;
  scrollbar-width: thin;
}

.highlight-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
  min-width: 84px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 4px;
  transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.highlight-item:hover {
  transform: translateY(-6px) scale(1.05);
}

.highlight-ring {
  width: 74px;
  height: 74px;
  border-radius: 50%;
  padding: 3px;
  background: conic-gradient(from 40deg, #E8CFA1, #9E7339, #D9B477, #B58644, #E8CFA1);
  box-shadow: 0 6px 16px rgba(157, 116, 59, 0.22);
  transition: box-shadow 0.25s ease, transform 0.25s ease;
}

.highlight-item:hover .highlight-ring {
  box-shadow: 0 10px 24px rgba(197, 155, 95, 0.42);
}

.highlight-item.active .highlight-ring {
  background: linear-gradient(135deg, #234F3E, #C59B5F);
  box-shadow: 0 0 0 3px rgba(197, 155, 95, 0.35);
}

.highlight-ring img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  background: #FAF3E8;
  border: 2px solid #FFFDF9;
  display: block;
}

.highlight-item span {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--ink-soft);
  white-space: nowrap;
}

/* Catalog Section */
.catalog-section {
  padding: 42px 0 54px;
}

.catalog-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.section-title {
  margin: 0 0 4px;
  font-size: 1.55rem;
  font-weight: 800;
}

.section-desc {
  margin: 0;
  color: var(--ink-muted);
  font-size: 0.92rem;
}

.catalog-header-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.catalog-stats {
  background: var(--bg-card);
  border: 1px solid var(--border);
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--gold-dark);
}

.grid-toggle-group {
  display: none;
  align-items: center;
  gap: 4px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  padding: 3px;
  border-radius: 999px;
}

.grid-toggle-btn {
  border: none;
  background: transparent;
  color: var(--ink-muted);
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.18s, color 0.18s;
}

.grid-toggle-btn.active {
  background: var(--ink);
  color: #FFFDF9;
}

.filter-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  min-width: 0;
  max-width: 100%;
  margin-bottom: 24px;
  padding: 14px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}

.category-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  min-width: 0;
  max-width: 100%;
}

.cat-chip {
  padding: 7px 14px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--bg-cream);
  color: var(--ink-soft);
  font-size: 0.85rem;
  font-weight: 600;
  white-space: nowrap;
  flex-shrink: 0;
  cursor: pointer;
  transition: all 0.18s;
}

.cat-chip:hover {
  border-color: var(--gold);
}

.cat-chip.active {
  background: var(--ink);
  color: #FFFDF9;
  border-color: var(--ink);
}

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

.filter-controls .form-select {
  width: auto;
  min-width: 135px;
  padding: 7px 12px;
  font-size: 0.85rem;
}

/* Products Grid */
.products-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.product-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-sm);
  transition: transform 0.28s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.28s ease, border-color 0.28s ease;
  animation: cardFadeUp 0.48s ease both;
  animation-delay: calc(min(var(--i, 0), 8) * 55ms);
}

.product-card:hover {
  transform: translateY(-7px);
  box-shadow: 0 18px 36px rgba(42, 31, 20, 0.13);
  border-color: rgba(197, 155, 95, 0.7);
}

.product-media {
  position: relative;
  aspect-ratio: 1 / 1;
  background: var(--bg-warm);
  overflow: hidden;
  cursor: pointer;
}

.product-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}

.product-card:hover .product-media img {
  transform: scale(1.06);
}

.media-hover-cta {
  position: absolute;
  inset-inline: 12px;
  bottom: 12px;
  z-index: 2;
  padding: 9px 14px;
  border-radius: 999px;
  background: rgba(29, 25, 22, 0.82);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(217, 185, 134, 0.45);
  color: #F6E6CA;
  font-size: 0.8rem;
  font-weight: 600;
  text-align: center;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.26s ease, transform 0.26s cubic-bezier(0.22, 1, 0.36, 1);
  pointer-events: none;
}

.product-card:hover .media-hover-cta,
.product-media:focus-visible .media-hover-cta {
  opacity: 1;
  transform: translateY(0);
}

.product-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 2;
  background: rgba(26, 22, 20, 0.84);
  color: #F6E6CA;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 600;
  backdrop-filter: blur(4px);
}

.discount-pct-badge {
  position: absolute;
  top: 44px;
  right: 10px;
  z-index: 2;
  background: linear-gradient(135deg, #A33A3A, #7B2525);
  color: #FFFDF9;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  box-shadow: 0 4px 12px rgba(123, 37, 37, 0.28);
  border: 1px solid rgba(255, 253, 249, 0.24);
}

.wishlist-toggle-btn {
  position: absolute;
  top: 10px;
  left: 10px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: rgba(255, 253, 249, 0.92);
  display: grid;
  place-items: center;
  cursor: pointer;
  font-size: 0.95rem;
  transition: transform 0.15s;
}

.wishlist-toggle-btn:hover {
  transform: scale(1.08);
}

.out-of-stock-overlay {
  position: absolute;
  inset: 0;
  background: rgba(26, 22, 20, 0.56);
  display: grid;
  place-items: center;
  color: #FFFDF9;
  font-weight: 800;
  font-size: 1rem;
}

.product-body {
  padding: 15px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}

.product-cat-label {
  font-size: 0.75rem;
  color: var(--gold-dark);
  font-weight: 700;
}

.product-title {
  margin: 0;
  font-size: 1rem;
  font-weight: 800;
  line-height: 1.45;
  cursor: pointer;
}

.product-fabric {
  margin: 0;
  font-size: 0.8rem;
  color: var(--ink-muted);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-swatches {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 2px;
}

.swatch-dot {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid #FFFDF9;
  box-shadow: 0 0 0 1px rgba(61, 50, 44, 0.25);
  cursor: pointer;
  transition: transform 0.15s;
}

.swatch-dot.selected {
  box-shadow: 0 0 0 2px var(--gold-dark);
  transform: scale(1.12);
}

.swatch-name-hint {
  font-size: 0.75rem;
  color: var(--ink-muted);
  margin-right: 4px;
}

.card-sizes {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.size-pill {
  padding: 2px 8px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: var(--bg-cream);
  font-size: 0.74rem;
  font-weight: 600;
  cursor: pointer;
  color: var(--ink-soft);
}

.size-pill.selected {
  background: var(--ink);
  color: #FFFDF9;
  border-color: var(--ink);
}

.product-price-row {
  margin-top: auto;
  padding-top: 8px;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
}

.price-stack {
  display: flex;
  flex-direction: column;
}

.old-price {
  font-size: 0.78rem;
  color: var(--ink-muted);
  text-decoration: line-through;
}

.current-price {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--emerald);
}

.stock-hint {
  font-size: 0.74rem;
  color: var(--ink-muted);
}

.stock-hint.low {
  color: var(--rose);
  font-weight: 700;
}

.product-actions {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  margin-top: 4px;
}

/* Editorial & Tracking Banner */
.editorial-section {
  padding: 12px 0 46px;
}

.editorial-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
}

.editorial-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 26px;
  box-shadow: var(--shadow-sm);
}

.editorial-badge {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--gold-soft);
  color: var(--gold-dark);
  font-size: 0.78rem;
  font-weight: 700;
  margin-bottom: 10px;
}

.editorial-card h3 {
  margin: 0 0 12px;
  font-size: 1.2rem;
}

.care-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 0.9rem;
  color: var(--ink-soft);
}

.care-list li {
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.inline-track-form {
  display: flex;
  gap: 10px;
  margin-top: 12px;
}

.inline-track-result {
  margin-top: 16px;
}

.track-card-box {
  background: var(--bg-cream);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 14px;
}

.track-steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-top: 12px;
}

.track-step {
  text-align: center;
  padding: 8px 6px;
  border-radius: 8px;
  background: #FFFDF9;
  border: 1px solid var(--border-soft);
  font-size: 0.76rem;
  color: var(--ink-muted);
}

.track-step.done {
  background: rgba(35, 79, 62, 0.1);
  border-color: var(--emerald);
  color: var(--emerald);
  font-weight: 700;
}

/* About & Footer */
.about-section {
  padding: 46px 0;
  background: linear-gradient(180deg, #F3E8D8 0%, #EFE1CE 100%);
  border-top: 1px solid var(--border);
}

.about-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 28px;
  align-items: center;
}

.about-brand-box {
  display: flex;
  gap: 20px;
  align-items: flex-start;
}

.about-logo {
  width: 94px;
  height: 94px;
  border-radius: 50%;
  border: 2px solid var(--gold);
  background: #FFFFFF;
  object-fit: contain;
  padding: 3px;
  flex-shrink: 0;
  box-shadow: var(--shadow-md);
}

.about-brand-box h2 {
  margin: 0 0 4px;
  font-size: 1.35rem;
}

.about-slogan {
  margin: 0 0 10px;
  font-weight: 700;
  color: var(--gold-dark);
}

.memorial-badge {
  position: relative;
  margin-top: 14px;
  display: inline-block;
  padding: 12px 18px;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, rgba(255, 253, 249, 0.98), rgba(247, 237, 222, 0.96));
  border: 1px solid rgba(197, 155, 95, 0.85);
  box-shadow: 0 8px 24px rgba(157, 116, 59, 0.16), inset 0 1px 0 rgba(255, 255, 255, 0.9);
  font-size: 0.9rem;
  line-height: 1.85;
  color: var(--ink-soft);
  transition: transform 0.28s ease, box-shadow 0.28s ease, border-color 0.28s ease;
}

.memorial-badge:hover {
  transform: translateY(-2px);
  border-color: var(--gold);
  box-shadow: 0 12px 30px rgba(157, 116, 59, 0.22), 0 0 18px rgba(217, 185, 134, 0.25);
}

.candle-flame-wrap {
  position: relative;
  display: inline-block;
  vertical-align: middle;
  margin-inline-end: 6px;
  font-size: 1.05rem;
  line-height: 1;
  animation: candleFlicker 2.6s ease-in-out infinite;
  filter: drop-shadow(0 0 7px rgba(245, 180, 72, 0.65));
}

.candle-flame-wrap::before {
  content: "";
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(246, 196, 108, 0.42), transparent 72%);
  pointer-events: none;
  z-index: -1;
}

.memorial-olive-svg {
  display: inline-block;
  vertical-align: middle;
  margin-inline: 4px;
  color: var(--gold-dark);
  opacity: 0.88;
}

.memorial-badge strong {
  color: var(--gold-dark);
}

.about-info-cards {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.info-mini-card {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 13px 16px;
}

.info-mini-card p {
  margin: 2px 0 0;
  font-size: 0.88rem;
  color: var(--ink-muted);
}

.info-icon {
  font-size: 1.3rem;
}

.social-links-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 6px;
}

.social-pill {
  padding: 4px 11px;
  border-radius: 999px;
  background: var(--bg-warm);
  border: 1px solid var(--border);
  font-size: 0.8rem;
  font-weight: 600;
  transition: background 0.18s;
}

.social-pill:hover {
  background: var(--gold);
  color: #FFFDF9;
}

.shop-footer {
  background: var(--ink);
  color: #D7CBB9;
  padding: 18px 0;
  font-size: 0.84rem;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
}

.footer-memorial {
  padding: 5px 14px;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(197, 155, 95, 0.16), rgba(197, 155, 95, 0.08));
  border: 1px solid rgba(217, 185, 134, 0.42);
  box-shadow: 0 0 16px rgba(197, 155, 95, 0.14);
  color: #F2E2C9;
  font-size: 0.82rem;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.footer-memorial:hover {
  border-color: rgba(217, 185, 134, 0.72);
  box-shadow: 0 0 22px rgba(217, 185, 134, 0.24);
}

.footer-memorial strong {
  color: var(--gold-light);
}

/* Drawers */
.drawer-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(20, 15, 12, 0.52);
  backdrop-filter: blur(3px);
  z-index: 90;
}

.drawer {
  position: fixed;
  top: 0;
  left: 0;
  height: 100vh;
  width: min(430px, 95vw);
  background: var(--bg-card);
  z-index: 100;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-lg);
  border-right: 1px solid var(--border);
  animation: drawerSlideIn 0.26s cubic-bezier(0.22, 1, 0.36, 1);
}

.drawer.drawer-right {
  left: auto;
  right: 0;
  width: min(340px, 88vw);
  border-right: none;
  border-left: 1px solid var(--border);
  animation: drawerSlideRight 0.26s cubic-bezier(0.22, 1, 0.36, 1);
}

.mobile-nav-head {
  padding: 12px 16px;
}

.mobile-nav-body {
  gap: 8px;
  padding-bottom: 18px;
}

.mobile-nav-section-title {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--gold-dark);
  margin-top: 4px;
}

.mobile-cat-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.mobile-nav-link {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  text-align: right;
  padding: 8px 11px;
  border-radius: 11px;
  border: 1px solid var(--border-soft);
  background: var(--bg-cream);
  color: var(--ink-soft);
  font-size: 0.84rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.18s, border-color 0.18s, color 0.18s;
}

.mobile-nav-link:hover {
  background: var(--gold-soft);
  border-color: var(--gold);
  color: var(--gold-dark);
}

/* Sticky Mobile Bottom App Navigation */
.mobile-bottom-nav {
  display: none;
  position: fixed;
  inset-inline: 0;
  bottom: 0;
  z-index: 60;
  height: 62px;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  background: rgba(255, 253, 249, 0.96);
  backdrop-filter: blur(12px);
  border-top: 1px solid var(--border);
  box-shadow: 0 -6px 24px rgba(42, 31, 20, 0.08);
  padding: 4px 6px calc(4px + env(safe-area-inset-bottom, 0px));
}

.bnav-btn {
  position: relative;
  border: none;
  background: transparent;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--ink-muted);
  cursor: pointer;
  border-radius: 10px;
  padding: 4px 2px;
  transition: color 0.18s, background 0.18s;
}

.bnav-btn.active {
  color: var(--gold-dark);
  background: var(--gold-soft);
}

.bnav-icon {
  font-size: 1.12rem;
  line-height: 1.1;
}

.bnav-badge {
  position: absolute;
  top: 2px;
  left: calc(50% - 24px);
  min-width: 17px;
  height: 17px;
  border-radius: 999px;
  background: var(--ink);
  color: var(--gold-light);
  border: 1px solid var(--gold);
  font-size: 0.64rem;
  font-weight: 800;
  display: grid;
  place-items: center;
  padding: 0 4px;
}

.drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  background: var(--bg-cream);
}

.drawer-header h3 {
  margin: 0;
  font-size: 1.1rem;
}

.close-btn {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: #FFFDF9;
  cursor: pointer;
  font-size: 1rem;
}

.free-shipping-bar {
  padding: 10px 20px;
  background: var(--bg-warm);
  border-bottom: 1px solid var(--border);
  font-size: 0.82rem;
}

.progress-track {
  height: 7px;
  border-radius: 999px;
  background: rgba(197, 155, 95, 0.22);
  margin-top: 6px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--gold), var(--emerald));
  transition: width 0.3s ease;
}

.drawer-body {
  flex: 1;
  overflow-y: auto;
  padding: 16px 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.cart-item {
  display: flex;
  gap: 12px;
  padding: 12px;
  background: var(--bg-cream);
  border: 1px solid var(--border);
  border-radius: 12px;
}

.cart-item img {
  width: 72px;
  height: 72px;
  border-radius: 10px;
  object-fit: cover;
  flex-shrink: 0;
}

.cart-item-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.cart-item-info h4 {
  margin: 0;
  font-size: 0.92rem;
}

.cart-item-meta {
  font-size: 0.78rem;
  color: var(--ink-muted);
}

.cart-item-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 6px;
}

.qty-stepper {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #FFFDF9;
}

.qty-stepper button {
  border: none;
  background: transparent;
  width: 28px;
  height: 28px;
  cursor: pointer;
  font-weight: 700;
}

.qty-stepper span {
  padding: 0 8px;
  font-size: 0.85rem;
  font-weight: 700;
}

.drawer-footer {
  padding: 16px 20px;
  border-top: 1px solid var(--border);
  background: var(--bg-cream);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.coupon-row {
  display: flex;
  gap: 8px;
}

.coupon-feedback {
  font-size: 0.8rem;
  min-height: 16px;
}

.coupon-feedback.ok {
  color: var(--emerald);
  font-weight: 600;
}

.coupon-feedback.err {
  color: var(--danger);
}

.cart-delivery-select {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 0.84rem;
}

.cart-delivery-select .form-select {
  width: 65%;
  padding: 6px 10px;
  font-size: 0.82rem;
}

.cart-totals {
  display: flex;
  flex-direction: column;
  gap: 5px;
  font-size: 0.88rem;
}

.total-line {
  display: flex;
  justify-content: space-between;
}

.discount-line {
  color: var(--rose);
}

.grand-total {
  font-size: 1rem;
  padding-top: 6px;
  border-top: 1px dashed var(--border);
}

/* Modals */
.modal {
  position: fixed;
  inset: 0;
  z-index: 120;
  background: rgba(20, 15, 12, 0.58);
  backdrop-filter: blur(3px);
  display: grid;
  place-items: center;
  padding: 16px;
  overflow-y: auto;
}

.modal-card {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  width: 100%;
  max-height: 92vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
  animation: modalZoomIn 0.24s cubic-bezier(0.22, 1, 0.36, 1);
}

.modal-sm { max-width: 460px; }
.modal-md { max-width: 680px; }
.modal-lg { max-width: 880px; }

.modal-close {
  position: sticky;
  top: 0;
  float: left;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--bg-cream);
  cursor: pointer;
  z-index: 2;
}

.product-modal-grid {
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  gap: 24px;
  align-items: start;
}

.modal-product-img {
  width: 100%;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  object-fit: cover;
}

.size-guide-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8rem;
  margin-top: 10px;
}

.size-guide-table th, .size-guide-table td {
  border: 1px solid var(--border);
  padding: 6px 8px;
  text-align: center;
}

.size-guide-table th {
  background: var(--bg-warm);
}

.story-modal-card {
  text-align: center;
  background: linear-gradient(180deg, #FFFDF9 0%, #F4E8D7 100%);
}

.story-modal-avatar {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  border: 3px solid var(--gold);
  background: #FFFFFF;
  object-fit: contain;
  padding: 2px;
  margin: 0 auto 12px;
  display: block;
}

/* =========================================================
   ADMIN PANEL STYLES
   ========================================================= */
.admin-shell {
  display: grid;
  grid-template-columns: 260px 1fr;
  min-height: calc(100vh - 45px);
  background: var(--bg-admin);
}

.admin-sidebar {
  background: #1D1815;
  color: #F4EAE0;
  padding: 22px 16px;
  display: flex;
  flex-direction: column;
  gap: 22px;
  min-width: 0;
  max-width: 100%;
  border-left: 1px solid rgba(197, 155, 95, 0.22);
}

.admin-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.admin-logo {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #FFFFFF;
  object-fit: contain;
  padding: 2px;
  border: 2px solid var(--gold);
}

.admin-brand strong {
  display: block;
  font-size: 1rem;
}

.admin-brand small {
  color: var(--gold-light);
  font-size: 0.72rem;
  letter-spacing: 1px;
}

.admin-nav {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
  min-width: 0;
  max-width: 100%;
}

.admin-nav-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 14px;
  border-radius: 12px;
  border: none;
  background: transparent;
  color: #DFD2C3;
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
  text-align: right;
  transition: all 0.18s;
}

.admin-nav-btn:hover {
  background: rgba(255, 255, 255, 0.08);
}

.admin-nav-btn.active {
  background: linear-gradient(135deg, #D5AE72, #B48646);
  color: #FFFDF9;
}

.nav-count-pill {
  margin-right: auto;
  background: var(--rose);
  color: #fff;
  font-size: 0.74rem;
  padding: 2px 8px;
  border-radius: 999px;
}

.admin-main {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.admin-topbar {
  background: var(--bg-card);
  border-bottom: 1px solid var(--border);
  padding: 16px 26px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  min-width: 0;
  max-width: 100%;
}

.admin-topbar-title h1 {
  margin: 0;
  font-size: 1.32rem;
}

.admin-topbar-title span {
  font-size: 0.84rem;
  color: var(--ink-muted);
}

.admin-content {
  padding: 24px 26px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  min-width: 0;
  max-width: 100%;
}

.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.kpi-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 18px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.24s ease, box-shadow 0.24s ease, border-color 0.24s ease;
}

.kpi-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 26px rgba(42, 31, 20, 0.09);
  border-color: rgba(197, 155, 95, 0.55);
}

.kpi-label {
  font-size: 0.84rem;
  color: var(--ink-muted);
}

.kpi-value {
  font-size: 1.55rem;
  font-weight: 900;
  margin: 6px 0 4px;
}

.kpi-sub {
  font-size: 0.78rem;
  color: var(--emerald);
  font-weight: 600;
}

.kpi-sub.warn {
  color: var(--rose);
}

.dashboard-panels {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 18px;
  margin: 18px 0;
}

.panel-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 20px;
  box-shadow: var(--shadow-sm);
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
}

.panel-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 14px;
  flex-wrap: wrap;
}

.panel-card-header h3 {
  margin: 0;
  font-size: 1.06rem;
}

.panel-muted {
  color: var(--ink-muted);
  font-size: 0.84rem;
}

.chart-bars {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.chart-row {
  display: flex;
  flex-direction: column;
  gap: 5px;
  font-size: 0.84rem;
}

.chart-row-head {
  display: flex;
  justify-content: space-between;
}

.chart-bar-bg {
  height: 10px;
  border-radius: 999px;
  background: var(--bg-warm);
  overflow: hidden;
}

.chart-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--gold), var(--emerald));
  border-radius: 999px;
  transform-origin: right center;
  animation: barGrow 0.7s ease-out;
}

.low-stock-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.low-stock-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 10px;
  background: var(--bg-cream);
  border: 1px solid var(--border);
  font-size: 0.85rem;
}

.admin-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.admin-toolbar-left {
  display: flex;
  gap: 10px;
  flex: 1;
  min-width: 260px;
}

.table-responsive {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}

.admin-table th, .admin-table td {
  padding: 11px 10px;
  border-bottom: 1px solid var(--border-soft);
  text-align: right;
  vertical-align: middle;
}

.admin-table th {
  font-weight: 700;
  color: var(--ink-muted);
  background: var(--bg-cream);
}

.table-thumb {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  object-fit: cover;
  border: 1px solid var(--border);
}

.status-badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 700;
}

.status-awaiting_payment { background: #FFF7ED; color: #C2410C; border: 1px solid #FED7AA; }
.status-pending { background: #FEF3C7; color: #92400E; }
.status-processing { background: #E0F2FE; color: #075985; }
.status-shipped { background: #EDE9FE; color: #5B21B6; }
.status-delivered { background: #DCFCE7; color: #166534; }
.status-cancelled { background: #FEE2E2; color: #991B1B; }

.status-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.status-pill {
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--bg-cream);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
}

.status-pill.active {
  background: var(--ink);
  color: #FFFDF9;
  border-color: var(--ink);
}

.orders-cards-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.order-admin-card {
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 16px;
  background: var(--bg-cream);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.order-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  padding-bottom: 10px;
  border-bottom: 1px dashed var(--border);
}

.order-card-items {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.order-item-chip {
  background: #FFFDF9;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 5px 10px;
  font-size: 0.8rem;
}

.order-card-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
}

.inventory-split {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 18px;
}

.categories-admin-list, .coupons-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 14px;
}

.cat-admin-row, .coupon-admin-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 14px;
  background: var(--bg-cream);
  border: 1px solid var(--border);
  border-radius: 12px;
}

.add-category-form {
  display: flex;
  gap: 8px;
}

.icon-input {
  width: 60px;
  text-align: center;
}

/* Admin Product Modal Extras */
.admin-product-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.quick-size-picks {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 4px;
}

.chip-mini {
  padding: 3px 9px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--bg-cream);
  font-size: 0.74rem;
  cursor: pointer;
}

.image-upload-box {
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 10px;
  border: 1px dashed var(--gold);
  border-radius: 12px;
  background: var(--bg-cream);
}

.upload-preview-thumb {
  width: 68px;
  height: 68px;
  border-radius: 10px;
  object-fit: cover;
  border: 1px solid var(--border);
}

.upload-controls {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.color-builder-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 6px;
}

.color-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--bg-cream);
  border: 1px solid var(--border);
  font-size: 0.82rem;
}

.color-tag-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 1px solid rgba(0, 0, 0, 0.2);
}

.color-add-row {
  display: flex;
  gap: 8px;
  align-items: center;
}

.color-picker-input {
  width: 46px;
  height: 38px;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 2px;
  background: #fff;
  cursor: pointer;
}

.modal-footer-actions {
  display: flex;
  gap: 10px;
  margin-top: 12px;
  justify-content: flex-start;
}

.backup-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: 4px 0;
}

/* Invoice */
.invoice-box {
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 20px;
  background: #fff;
}

.invoice-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 2px solid var(--gold);
  padding-bottom: 12px;
  margin-bottom: 14px;
}

/* Toasts */
.toast-container {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 200;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.toast {
  background: var(--ink);
  color: #FFFDF9;
  padding: 11px 16px;
  border-radius: 12px;
  border-right: 4px solid var(--gold);
  box-shadow: var(--shadow-md);
  font-size: 0.88rem;
  animation: slideUp 0.2s ease;
}

@keyframes slideUp {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes sheenSweep {
  0%, 58% { left: -60%; }
  100% { left: 145%; }
}

@keyframes cartBump {
  0% { transform: scale(1); }
  35% { transform: scale(1.16) rotate(-3deg); }
  65% { transform: scale(0.96) rotate(2deg); }
  100% { transform: scale(1) rotate(0); }
}

@keyframes fadeInScale {
  from { opacity: 0; transform: scale(0.95) translateY(12px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

@keyframes auraPulse {
  0%, 100% { opacity: 0.72; transform: scale(0.98); }
  50% { opacity: 1; transform: scale(1.03); }
}

@keyframes floatSlow {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-9px); }
}

@keyframes floatReverse {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(9px); }
}

@keyframes cardFadeUp {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes candleFlicker {
  0%, 100% { transform: scale(1) rotate(-1.5deg); opacity: 0.94; }
  35% { transform: scale(1.08) rotate(2deg); opacity: 1; }
  70% { transform: scale(0.97) rotate(-1deg); opacity: 0.9; }
}

@keyframes drawerSlideIn {
  from { opacity: 0; transform: translateX(-28px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes drawerSlideRight {
  from { opacity: 0; transform: translateX(28px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes modalZoomIn {
  from { opacity: 0; transform: scale(0.94) translateY(12px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

@keyframes barGrow {
  from { transform: scaleX(0); }
  to { transform: scaleX(1); }
}

/* Admin Login Modal */
.admin-login-card {
  max-width: 430px;
  text-align: center;
  padding: 28px 24px 24px;
}

.admin-login-card.shake {
  animation: modalShake 0.36s cubic-bezier(0.36, 0.07, 0.19, 0.97);
}

.admin-login-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
}

.admin-login-logo {
  width: 68px;
  height: 68px;
  border-radius: 50%;
  background: #FFFFFF;
  object-fit: contain;
  padding: 4px;
  border: 2px solid var(--gold);
  box-shadow: var(--shadow-sm);
}

.admin-login-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--gold-soft);
  border: 1px solid var(--border);
  color: var(--gold-dark);
  font-size: 0.78rem;
  font-weight: 700;
}

.admin-login-header h3 {
  margin: 4px 0 0;
  font-size: 1.15rem;
}

.admin-login-header p {
  margin: 0;
  font-size: 0.85rem;
  line-height: 1.6;
}

.admin-login-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
  text-align: right;
}

.password-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.password-input-wrap .form-input {
  padding-left: 44px;
  font-family: 'Segoe UI', Tahoma, var(--font-main);
  letter-spacing: 0.04em;
}

.pass-toggle-btn {
  position: absolute;
  left: 8px;
  top: 50%;
  transform: translateY(-50%);
  width: 32px;
  height: 32px;
  border: none;
  background: transparent;
  border-radius: 8px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  opacity: 0.75;
  transition: background 0.15s, opacity 0.15s;
}

.pass-toggle-btn:hover {
  background: var(--gold-soft);
  opacity: 1;
}

.admin-login-error {
  padding: 9px 12px;
  border-radius: var(--radius-sm);
  background: rgba(180, 61, 61, 0.1);
  border: 1px solid rgba(180, 61, 61, 0.35);
  color: var(--danger);
  font-size: 0.84rem;
  font-weight: 700;
  text-align: center;
}

@keyframes modalShake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-7px); }
  40% { transform: translateX(7px); }
  60% { transform: translateX(-5px); }
  80% { transform: translateX(5px); }
}

.storage-status-box {
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--bg-cream);
  color: var(--ink-soft);
  font-size: 0.85rem;
  font-weight: 600;
  line-height: 1.6;
}

.storage-status-box.ok {
  background: rgba(35, 79, 62, 0.08);
  border-color: rgba(35, 79, 62, 0.35);
  color: var(--emerald);
}

.storage-status-box.warn {
  background: rgba(197, 155, 95, 0.16);
  border-color: rgba(157, 116, 59, 0.45);
  color: #7A521B;
}

.bnav-badge.hidden {
  display: none;
}

.zarinpal-settings-box {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 14px 16px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: rgba(197, 155, 95, 0.08);
  margin: 4px 0;
}

.zarinpal-settings-title {
  font-size: 0.92rem;
  font-weight: 800;
  color: var(--ink);
}

.checkout-payment-hint {
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--gold-soft);
  color: var(--ink-soft);
  font-size: 0.82rem;
  line-height: 1.6;
}

.payment-badge-paid {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 9px;
  border-radius: 999px;
  background: #DCFCE7;
  color: #166534;
  font-size: 0.75rem;
  font-weight: 700;
}

.payment-badge-failed {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 9px;
  border-radius: 999px;
  background: #FEE2E2;
  color: #991B1B;
  font-size: 0.75rem;
  font-weight: 700;
}

.payment-badge-unpaid {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 9px;
  border-radius: 999px;
  background: #FFF7ED;
  color: #C2410C;
  font-size: 0.75rem;
  font-weight: 700;
}

.empty-state {
  grid-column: 1 / -1;
  text-align: center;
  padding: 46px 20px;
  background: var(--bg-card);
  border: 1px dashed var(--border);
  border-radius: var(--radius-md);
  color: var(--ink-muted);
}

/* Responsive */
@media (max-width: 1180px) {
  .products-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .admin-shell { grid-template-columns: 220px minmax(0, 1fr); }
}

@media (max-width: 1220px) and (min-width: 993px) {
  .header-inner { gap: 8px; padding-block: 10px; }
  .brand-avatar { width: 40px; height: 40px; }
  .brand-text strong { font-size: 0.94rem; }
  .brand-text span { font-size: 0.66rem; }
  .nav-link { padding: 6px 7px; font-size: 0.78rem; }
  .search-wrap { width: 136px; }
  .cart-btn { padding: 8px 11px; font-size: 0.8rem; }
}

@media (max-width: 1120px) and (min-width: 993px) {
  .brand-avatar { width: 38px; height: 38px; }
  .brand-text span { display: none; }
  .main-nav { gap: 1px; overflow-x: auto; scrollbar-width: none; }
  .main-nav::-webkit-scrollbar { display: none; }
  .nav-link { padding: 5px 6px; font-size: 0.75rem; }
  .search-wrap { width: 122px; }
  .search-input { font-size: 0.78rem; padding: 7px 28px 7px 10px; }
  .icon-btn { width: 35px; height: 35px; }
  .cart-btn { padding: 7px 10px; font-size: 0.78rem; }
}

@media (max-width: 992px) {
  .icon-btn.mobile-menu-btn { display: inline-flex; }
  .main-nav { display: none; }
  .header-inner { gap: 10px; }
  .header-actions { margin-right: auto; }
  .search-wrap { width: min(260px, 34vw); }
  .hero-grid, .editorial-grid, .about-grid, .product-modal-grid, .dashboard-panels, .inventory-split {
    grid-template-columns: minmax(0, 1fr);
  }
  .hero-section { padding: 28px 0 34px; }
  .hero-content { text-align: center; max-width: 680px; margin-inline: auto; }
  .hero-subtitle { margin-inline: auto; }
  .hero-cta-row, .hero-trust-row { justify-content: center; }
  .hero-visual { max-width: 480px; margin-inline: auto; width: 100%; }
  .filter-toolbar { flex-direction: column; align-items: stretch; }
  .category-chips {
    width: 100%;
    min-width: 0;
    max-width: 100%;
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 4px;
    scrollbar-width: none;
  }
  .category-chips::-webkit-scrollbar { display: none; }
  .filter-controls { width: 100%; max-width: 100%; justify-content: space-between; }
  .products-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
  .admin-shell { grid-template-columns: minmax(0, 1fr); }
  .admin-sidebar { border-left: none; border-bottom: 1px solid rgba(197, 155, 95, 0.25); padding: 14px 16px; gap: 12px; }
  .admin-nav {
    width: 100%;
    min-width: 0;
    max-width: 100%;
    flex-direction: row;
    overflow-x: auto;
    padding-bottom: 4px;
    scrollbar-width: none;
  }
  .admin-nav::-webkit-scrollbar { display: none; }
  .admin-nav-btn { white-space: nowrap; flex-shrink: 0; }
  .admin-content, .admin-topbar { padding: 16px; }
}

@media (max-width: 768px) {
  .top-bar { font-size: 0.74rem; padding-block: 6px; }
  .top-bar-inner { justify-content: center; text-align: center; gap: 6px; }
  .top-controls { width: 100%; justify-content: center; }
  .mobile-bottom-nav { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); }
  #shop-view { padding-bottom: calc(74px + env(safe-area-inset-bottom, 0px)); }
  .grid-toggle-group { display: inline-flex; }
  .hero-arch-frame { padding: 18px; border-radius: 24px; }
  .hero-badges-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .table-responsive { overflow-x: auto; -webkit-overflow-scrolling: touch; max-width: 100%; }
  .admin-table { min-width: 620px; }
  .modal-card { width: calc(100% - 20px); max-height: calc(100vh - 24px); padding: 18px 14px; }
  .modal-card.wide { max-width: calc(100% - 20px); }
  .drawer { width: min(100vw, 390px); max-width: 100vw; }
}

@media (max-width: 640px) {
  .container { width: calc(100% - 20px); }
  .header-inner { flex-wrap: wrap; align-items: center; gap: 8px 6px; padding-block: 8px; }
  .icon-btn.mobile-menu-btn { order: 1; width: 36px; height: 36px; font-size: 1rem; flex-shrink: 0; }
  .brand-logo { order: 2; margin-left: auto; gap: 8px; min-width: 0; }
  .brand-avatar { width: 36px; height: 36px; }
  .brand-text strong { font-size: 0.92rem; white-space: nowrap; }
  .brand-text span { display: none; }
  .header-actions { display: contents; }
  .header-actions > .icon-btn { order: 3; width: 36px; height: 36px; font-size: 0.95rem; flex-shrink: 0; }
  .header-actions > .cart-btn { order: 4; padding: 6px 10px; font-size: 0.76rem; gap: 5px; flex-shrink: 0; }
  .search-wrap { order: 5; flex: 1 0 100%; width: 100%; min-width: 0; }
  .hero-section { padding: 18px 0 24px; }
  .hero-grid { gap: 18px; }
  .hero-content h1 { font-size: clamp(1.45rem, 6.2vw, 1.85rem); line-height: 1.38; }
  .hero-cta-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; width: 100%; }
  .hero-cta-row .btn { width: 100%; padding-inline: 10px; font-size: 0.82rem; justify-content: center; }
  .hero-trust-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; width: 100%; font-size: 0.76rem; }
  .hero-arch-frame { padding: 14px; border-radius: 20px; }
  .hero-badges-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-top: 10px; }
  .hero-floating-card { position: static; margin-top: 0; padding: 8px 10px; font-size: 0.72rem; justify-content: center; animation: none; }
  .catalog-header { flex-direction: column; align-items: stretch; gap: 10px; }
  .catalog-header-meta { width: 100%; justify-content: space-between; }
  .filter-controls { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); width: 100%; gap: 8px; }
  .filter-controls .form-select { width: 100%; min-width: 0; font-size: 0.82rem; padding: 8px 10px; }
  .filter-controls .checkbox-pill { grid-column: 1 / -1; justify-content: center; }
  .products-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .products-grid.grid-cols-1 { grid-template-columns: minmax(0, 1fr); gap: 14px; }
  .products-grid:not(.grid-cols-1) .product-card { border-radius: 16px; }
  .products-grid:not(.grid-cols-1) .product-body { padding: 10px; gap: 6px; }
  .products-grid:not(.grid-cols-1) .product-title { font-size: 0.84rem; line-height: 1.35; }
  .products-grid:not(.grid-cols-1) .product-subtitle { font-size: 0.72rem; }
  .products-grid:not(.grid-cols-1) .product-price-row { flex-direction: column; align-items: flex-start; gap: 2px; }
  .products-grid:not(.grid-cols-1) .current-price { font-size: 0.88rem; }
  .products-grid:not(.grid-cols-1) .product-actions { grid-template-columns: minmax(0, 1fr); gap: 6px; margin-top: 6px; }
  .products-grid:not(.grid-cols-1) .product-actions .btn { width: 100%; padding: 7px 8px; font-size: 0.76rem; white-space: nowrap; }
  .products-grid:not(.grid-cols-1) .badge-pill { font-size: 0.66rem; padding: 3px 7px; }
  .inline-track-form { flex-direction: column; }
  .inline-track-form .btn { width: 100%; }
  .track-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .about-brand-box { flex-direction: column; align-items: center; text-align: center; }
  .memorial-badge { width: 100%; text-align: center; }
  .footer-inner { flex-direction: column; text-align: center; justify-content: center; }
  .kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .kpi-card { padding: 12px; gap: 8px; }
  .kpi-value { font-size: 1.15rem; }
  .form-row-2, .form-row-3 { grid-template-columns: minmax(0, 1fr); }
  .admin-topbar { flex-direction: column; align-items: stretch; gap: 10px; }
  .admin-topbar-actions { width: 100%; justify-content: space-between; flex-wrap: wrap; gap: 8px; }
  .admin-toolbar { flex-direction: column; align-items: stretch; gap: 10px; }
  .admin-toolbar-left, .add-category-form, .color-add-row { flex-direction: column; width: 100%; min-width: 0; }
  .icon-input { width: 100%; }
  .toast-container { bottom: calc(82px + env(safe-area-inset-bottom, 0px)); }
}

@media (max-width: 380px) {
  .container { width: calc(100% - 16px); }
  .brand-text span { display: none; }
  .brand-text strong { font-size: 0.86rem; }
  .header-actions > .cart-btn { padding: 6px 8px; font-size: 0.74rem; }
  .hero-cta-row, .hero-trust-row, .hero-badges-strip { grid-template-columns: minmax(0, 1fr); }
  .products-grid:not(.grid-cols-1) { gap: 8px; }
  .products-grid:not(.grid-cols-1) .product-body { padding: 8px; }
  .products-grid:not(.grid-cols-1) .product-title { font-size: 0.79rem; }
}

@media print {
  .no-print, .admin-sidebar, .admin-topbar, .top-bar { display: none !important; }
  body { background: #fff; }
  .modal { position: static; background: none; padding: 0; }
  .modal-card { box-shadow: none; border: none; max-height: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
