:root {
  --bg: #f8f1e6;
  --surface: #ffffff;
  --surface-soft: #fbf6ed;
  --text: #2d2a22;
  --muted: #736a5d;
  --primary: #59663a;
  --primary-soft: #edf0dc;
  --accent: #9a7349;
  --border: #ded0bd;
  --footer-bg: #414a2d;
  --hero-overlay: rgba(143, 100, 61, 0.24);
  --shadow: 0 16px 36px rgba(44, 38, 30, 0.1);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Inter", system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
}

body:not(.admin-user) a[href="admin.html"] {
  display: none !important;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

.container {
  width: min(1140px, calc(100% - 2rem));
  margin: 0 auto;
}

.site-header {
  background: rgba(249, 242, 230, 0.95);
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid rgba(147, 124, 98, 0.12);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.9rem;
}

.brand-logo {
  width: 66px;
  height: 66px;
  object-fit: contain;
  border-radius: 12px;
  background: var(--primary);
  padding: 0.12rem;
}

.brand strong {
  display: block;
  font-size: 1.1rem;
}

.brand span {
  display: block;
  color: var(--muted);
  font-size: 0.95rem;
}

.main-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
}

.main-nav a {
  color: var(--text);
  font-weight: 500;
}

.user-menu {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
}

.user-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.55rem 0.85rem;
  border-radius: 999px;
  background: var(--primary-soft);
  color: var(--primary);
  font-weight: 600;
}

.user-role {
  display: inline-flex;
  align-items: center;
  padding: 0.35rem 0.85rem;
  border-radius: 999px;
  background: var(--accent);
  color: var(--surface);
  font-size: 0.8rem;
}

.auth-form {
  display: grid;
  gap: 1rem;
  margin-top: 1rem;
}

.auth-form label {
  display: grid;
  gap: 0.55rem;
  font-weight: 600;
  color: var(--text);
}

.auth-form input,
.auth-form textarea {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 0.95rem 1rem;
  background: var(--surface);
  color: var(--text);
}

.message {
  margin-top: 1rem;
  padding: 1rem;
  border-radius: 18px;
  background: #f4f1e6;
  color: var(--text);
}

.message.error {
  background: #fdecea;
  color: #8a2f2f;
}

.message.success {
  background: #eaf7e6;
  color: #2c542d;
}

.app-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 1rem;
  background: rgba(45, 42, 34, 0.42);
}

.app-modal {
  position: relative;
  width: min(440px, 100%);
  border-radius: 24px;
  padding: 1.6rem;
  background: var(--surface);
  border: 1px solid rgba(173, 146, 112, 0.24);
  box-shadow: 0 24px 60px rgba(42, 36, 29, 0.24);
}

.app-modal-icon {
  display: inline-flex;
  width: 2.8rem;
  height: 2.8rem;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--primary-soft);
  color: var(--primary);
  font-weight: 800;
  font-size: 1.4rem;
}

.app-modal-error .app-modal-icon {
  background: #fdecea;
  color: #8a2f2f;
}

.app-modal-success .app-modal-icon {
  background: #eaf7e6;
  color: #2c542d;
}

.app-modal h2 {
  margin: 1rem 2rem 0.4rem 0;
  line-height: 1.25;
}

.app-modal p {
  margin: 0;
  color: var(--muted);
}

.app-modal-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.2rem;
}

.app-modal-close {
  position: absolute;
  top: 0.85rem;
  right: 0.85rem;
  width: 2.2rem;
  height: 2.2rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
  font-size: 1.3rem;
  line-height: 1;
}

.app-toast {
  position: fixed;
  left: 50%;
  bottom: 1.2rem;
  z-index: 120;
  max-width: min(420px, calc(100% - 2rem));
  padding: 0.85rem 1rem;
  border-radius: 999px;
  background: rgba(45, 42, 34, 0.96);
  color: white;
  box-shadow: var(--shadow);
  opacity: 0;
  transform: translate(-50%, 16px);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

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

.app-toast-error {
  background: rgba(138, 47, 47, 0.96);
}

.app-toast-success {
  background: rgba(67, 93, 36, 0.96);
}

.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 0.3rem 0.65rem;
  background: var(--primary-soft);
  color: var(--primary);
  font-size: 0.82rem;
  font-weight: 700;
  white-space: nowrap;
}

.badge-muted {
  background: #f4f1e6;
  color: var(--muted);
}

.badge-success {
  background: #eaf7e6;
  color: #2c542d;
}

.badge-warning {
  background: #fff4d8;
  color: #7a5720;
}

.badge-error {
  background: #fdecea;
  color: #8a2f2f;
}

.skeleton {
  min-height: 5.5rem;
  border-radius: 18px;
  background: linear-gradient(90deg, #f5ede1 25%, #fff8ef 37%, #f5ede1 63%);
  background-size: 400% 100%;
  animation: skeleton-loading 1.2s ease-in-out infinite;
}

@keyframes skeleton-loading {
  0% { background-position: 100% 50%; }
  100% { background-position: 0 50%; }
}

.empty-state {
  padding: 1rem;
  border-radius: 18px;
  background: var(--surface-soft);
  color: var(--muted);
}

.order-timeline {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: 0.7rem;
}

.timeline-step {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  color: var(--muted);
  font-size: 0.85rem;
}

.timeline-step::before {
  content: "";
  width: 0.62rem;
  height: 0.62rem;
  border-radius: 999px;
  background: var(--border);
}

.timeline-step.done::before {
  background: var(--primary);
}

.profile-row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 0;
  border-bottom: 1px solid rgba(173, 146, 112, 0.18);
}

.profile-row span:last-child {
  font-weight: 600;
  color: var(--text);
  overflow-wrap: anywhere;
  text-align: right;
}

.password-panel {
  padding: 0;
  overflow: hidden;
}

.password-panel summary {
  cursor: pointer;
  padding: 1.2rem 1.4rem;
  font-weight: 700;
  color: var(--primary);
  list-style: none;
}

.password-panel summary::-webkit-details-marker {
  display: none;
}

.password-panel summary::after {
  content: "+";
  float: right;
  font-size: 1.2rem;
}

.password-panel[open] summary::after {
  content: "−";
}

.password-panel-body {
  padding: 0 1.4rem 1.4rem;
}

.profile-order-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1rem;
}

.profile-order-card {
  display: grid;
  gap: 0.55rem;
  padding: 1rem;
  border-radius: 18px;
  background: var(--surface-soft);
  border: 1px solid rgba(173, 146, 112, 0.2);
}

.profile-order-card > div {
  display: flex;
  justify-content: space-between;
  gap: 0.7rem;
  align-items: center;
}

.profile-order-card p {
  margin: 0;
  font-weight: 800;
  color: var(--primary);
}

.profile-order-card small {
  color: var(--muted);
}

.bank-card {
  padding: 1rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  margin: 0.75rem 0;
}

.seller-contact-box {
  padding: 1rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface-soft);
  display: grid;
  gap: 0.45rem;
}

.seller-contact-box p {
  margin: 0;
  color: var(--muted);
}

.bank-card ul {
  margin: 0.6rem 0;
  padding-left: 1.1rem;
}

.bank-qr {
  width: min(180px, 100%);
  aspect-ratio: 1;
  object-fit: contain;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fff;
}

.product-gallery {
  display: flex;
  gap: 0.6rem;
  overflow-x: auto;
  margin-top: 0.75rem;
}

.product-gallery img {
  width: 88px;
  height: 88px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--border);
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #556B2F;
  color: white;
  border: none;
  border-radius: 999px;
  padding: 0.95rem 1.6rem;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease;
}

.button:hover {
  transform: translateY(-1px);
  background: #475b28;
}

.button-secondary {
  background: var(--surface);
  color: var(--primary);
  border: 1px solid #556B2F;
}

.button.small {
  padding: 0.65rem 1rem;
  font-size: 0.95rem;
}

.hero-section {
  padding: 3.25rem 0;
  position: relative;
  overflow: hidden;
  min-height: 500px;
  background: var(--bg);
}

.hero-section::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url('https://images.unsplash.com/photo-1500534314209-a25ddb2bd429?auto=format&fit=crop&w=1200&q=80');
  background-size: cover;
  background-position: center;
  opacity: 0.18;
  filter: blur(5px) saturate(0.85) brightness(0.95);
  z-index: 0;
}

.hero-section::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(247, 243, 234, 0.82);
  z-index: 1;
}

.hero-grid {
  position: relative;
  display: grid;
  gap: 2rem;
  grid-template-columns: 1.2fr 0.9fr;
  align-items: center;
  z-index: 2;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.22em;
  font-size: 0.82rem;
  color: #4B3A2F;
  margin-bottom: 0.9rem;
}

.hero-section h1 {
  margin: 0;
  font-size: clamp(2.8rem, 4vw, 3.6rem);
  line-height: 1.04;
  color: #4B3A2F;
  font-weight: 800;
  max-width: 10ch;
}

.hero-grid > div:first-child {
  text-align: center;
}

.hero-grid > div:first-child .eyebrow,
.hero-grid > div:first-child h1,
.hero-grid > div:first-child p {
  margin-left: auto;
  margin-right: auto;
}

.hero-section p {
  max-width: 40rem;
  color: #6B5B4B;
  font-size: 1rem;
  line-height: 1.8;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 1.5rem;
  justify-content: center;
}

.hero-card {
  overflow: hidden;
  border-radius: 32px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(172, 144, 113, 0.15);
  max-width: 460px;
  margin-left: auto;
}

.hero-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  aspect-ratio: 4 / 5;
  display: block;
}

.section {
  padding: 3rem 0;
}

.section-light {
  background: #fff;
}

.section-head {
  max-width: 48rem;
  margin-bottom: 2rem;
}

.section-head h2 {
  margin: 0 0 0.6rem;
}

.section-head p {
  margin: 0;
  color: var(--muted);
}

.product-grid,
.combo-grid,
.reviews-grid,
.categories-grid,
.story-grid {
  display: grid;
  gap: 1.5rem;
}

.product-grid,
.combo-grid,
.reviews-grid {
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.categories-grid {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.category-card,
.product-card,
.combo-card,
.review-card,
.cart-item,
.card,
.product-detail,
.orders-table {
  background: var(--surface);
  border: 1px solid rgba(173, 146, 112, 0.18);
  border-radius: 24px;
  padding: 1.4rem;
  box-shadow: 0 12px 30px rgba(42, 36, 29, 0.05);
}

.category-card {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 120px;
  text-align: center;
  font-size: 1.08rem;
  font-weight: 800;
  line-height: 1.25;
  color: #3f4f22;
  letter-spacing: 0.01em;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.96), rgba(247,241,228,0.92)),
    linear-gradient(135deg, rgba(101,112,63,0.16), rgba(167,123,76,0.12));
  border-color: rgba(101, 112, 63, 0.24);
  box-shadow: 0 14px 34px rgba(42, 36, 29, 0.08);
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.8);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.category-card:hover {
  transform: translateY(-2px);
  border-color: rgba(101, 112, 63, 0.42);
  box-shadow: 0 18px 40px rgba(42, 36, 29, 0.12);
}

.product-card {
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 1rem;
}

.product-card img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 20px;
}

.product-card h3 {
  margin: 0;
  text-align: center;
}

.product-card p {
  margin: 0.5rem 0 1rem;
  color: var(--muted);
  text-align: center;
}

.product-card small {
  display: block;
  text-align: center;
  color: var(--muted);
  font-weight: 700;
}

.product-card .price {
  font-size: 1.1rem;
  font-weight: 700;
  text-align: center;
  color: var(--accent);
  flex: 0 0 100%;
  width: 100%;
  margin: 0 0 0.15rem;
}

.product-card > div:last-child {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.65rem;
  text-align: center;
  align-items: center;
}

.product-card a {
  margin-top: auto;
  display: inline-flex;
  align-items: center;
}

.combo-card {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 1rem;
  align-items: center;
}

.combo-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 18px;
}

.combo-card h3 {
  margin: 0 0 0.5rem;
  text-align: center;
}

.combo-card .price {
  color: var(--accent);
  font-weight: 700;
}

.review-card {
  min-height: 160px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.review-card p {
  margin: 0 0 1rem;
  color: var(--muted);
}

.review-card strong {
  color: var(--text);
}

.product-detail {
  display: grid;
  gap: 2rem;
  grid-template-columns: 1fr 1fr;
  align-items: start;
  overflow: hidden;
}

.product-detail > div {
  min-width: 0;
}

.product-detail img {
  width: 100%;
  display: block;
  border-radius: 28px;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.product-info {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  text-align: center;
  align-items: center;
}

.product-info h1,
.product-info h2 {
  margin: 0;
  text-align: center;
}

.product-info p {
  margin: 0.6rem 0;
  color: var(--muted);
  text-align: center;
}

.product-info > .price {
  color: var(--accent);
  font-size: 1.35rem;
  font-weight: 800;
  margin: 0;
}

.product-meta {
  display: grid;
  gap: 1rem;
  width: 100%;
}

.product-meta div {
  padding: 1rem;
  background: var(--primary-soft);
  border-radius: 18px;
  text-align: center;
}

.product-meta strong,
.seller-contact-box strong {
  display: block;
  text-align: center;
}

.product-info .seller-contact-box {
  width: 100%;
  text-align: center;
}

.product-info .help-actions {
  justify-content: center;
}

.product-info > .button {
  align-self: center;
}

.product-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(72px, 1fr));
  gap: 0.6rem;
  margin-top: 0.8rem;
}

.product-gallery img {
  width: 100%;
  height: auto;
  border-radius: 14px;
  aspect-ratio: 1 / 1;
  object-fit: cover;
}

.cart-section {
  display: grid;
  gap: 1.5rem;
  grid-template-columns: 1.5fr 0.9fr;
  align-items: start;
}

.cart-list {
  display: grid;
  gap: 1rem;
}

.cart-list .card {
  text-align: center;
}

.cart-list .card .button,
.cart-summary .button {
  margin-inline: auto;
}

.cart-item {
  display: grid;
  grid-template-columns: 100px 1fr auto;
  gap: 1rem;
  align-items: center;
  text-align: center;
}

.cart-item img {
  width: 100%;
  border-radius: 18px;
  aspect-ratio: 1 / 1;
  object-fit: cover;
}

.cart-item h3 {
  margin: 0;
  text-align: center;
}

.cart-item p {
  margin: 0.3rem 0 0;
  color: var(--muted);
  text-align: center;
}

.cart-item small {
  display: block;
  color: var(--muted);
  text-align: center;
}

.cart-item button {
  background: transparent;
  color: var(--accent);
  border: none;
  cursor: pointer;
  font-weight: 600;
}

.cart-summary {
  padding: 1.5rem;
  border-radius: 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 1rem;
  align-items: center;
  text-align: center;
}

.cart-summary h2,
.cart-summary p {
  text-align: center;
}

.quantity-control {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.65rem;
  padding: 0.25rem;
  border-radius: 999px;
  background: var(--surface-soft);
}

.quantity-control span {
  min-width: 1.8rem;
  text-align: center;
  font-weight: 800;
}

.cart-item .qty-button {
  display: inline-flex;
  width: 2rem;
  height: 2rem;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--border);
}

.cart-item .remove-item {
  padding: 0.55rem 0.8rem;
  border-radius: 999px;
  background: #fff6ef;
}

.payment-method-box,
.payment-choice-card {
  border: 1px solid rgba(173, 146, 112, 0.24);
  border-radius: 16px;
  background: var(--surface-soft);
}

.payment-method-box {
  display: grid;
  gap: 0.55rem;
  margin: 1rem 0;
  padding: 1rem;
}

.payment-method-box legend {
  padding: 0 0.35rem;
  color: var(--primary);
  font-weight: 800;
}

.payment-method-box label,
.payment-choice-card label {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin: 0;
  font-weight: 700;
}

.payment-method-box input[type="checkbox"],
.payment-choice-card input[type="radio"] {
  flex: 0 0 auto;
  width: 1.05rem;
  height: 1.05rem;
  margin: 0;
  accent-color: var(--primary);
}

.payment-method-box label {
  justify-content: center;
}

.payment-choice-card {
  display: grid;
  gap: 0.65rem;
  padding: 1rem;
  text-align: center;
}

.payment-choice-card > div {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.55rem;
}

.payment-choice-card label {
  min-height: 2.35rem;
  padding: 0.45rem 0.7rem;
  border: 1px solid rgba(101, 112, 63, 0.18);
  border-radius: 999px;
  background: var(--surface);
}

.payment-choice-error {
  background: #fdecea;
  color: #8a2f2f;
}

.order-form label {
  display: block;
  margin-bottom: 1rem;
  color: var(--text);
  text-align: center;
}

.order-form h2,
.order-form p,
.order-form .note,
.order-message,
.bank-info,
.bank-card {
  text-align: center;
}

.bank-info ul,
.bank-card ul {
  display: inline-block;
  padding-left: 1.1rem;
  text-align: left;
}

.order-form button[type="submit"] {
  display: flex;
  margin-inline: auto;
}

.order-form input,
.order-form textarea {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 0.95rem 1rem;
  background: var(--surface);
  color: var(--text);
}

.order-form textarea {
  resize: vertical;
}

.contact-form {
  display: grid;
  gap: 1rem;
  background: var(--surface);
  padding: 1.6rem;
  border-radius: 24px;
  border: 1px solid rgba(173, 146, 112, 0.18);
  box-shadow: 0 16px 30px rgba(42, 36, 29, 0.05);
}

.contact-form label {
  display: grid;
  gap: 0.55rem;
  font-weight: 600;
  color: var(--text);
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 0.95rem 1rem;
  background: var(--surface);
  color: var(--text);
}

.contact-form textarea {
  min-height: 110px;
}

.filter-bar,
.product-filter-bar {
  display: grid;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.category-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.filter-button {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.75rem 1rem;
  cursor: pointer;
  color: var(--text);
  transition: background 0.2s ease, border-color 0.2s ease;
}

.filter-button.active,
.filter-button:hover {
  background: var(--primary-soft);
  border-color: var(--primary);
}

.product-filter-bar input {
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.95rem 1rem;
  background: var(--surface);
  color: var(--text);
}

.order-form textarea {
  resize: vertical;
}

.radio-group {
  display: grid;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.radio-group label {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-weight: 500;
  color: var(--text);
}

.radio-group input {
  width: auto;
}

.bank-info {
  background: var(--primary-soft);
  padding: 1rem;
  border-radius: 16px;
  border: 1px solid rgba(123, 77, 28, 0.15);
}

.bank-info ul {
  margin: 0.5rem 0 0;
  padding-left: 1.2rem;
  color: var(--text);
}

.hidden {
  display: none;
}

.order-message {
  margin-top: 1rem;
  padding: 1rem;
  border-radius: 18px;
  background: #edf7ef;
  color: #2f532f;
  display: none;
}

.orders-table {
  overflow-x: auto;
}

.orders-table table {
  width: 100%;
  border-collapse: collapse;
}

.orders-table th,
.orders-table td {
  padding: 0.95rem 0.8rem;
  border-bottom: 1px solid var(--border);
  text-align: center;
  vertical-align: middle;
}

.orders-table th {
  background: #faf6f0;
  color: #443827;
}

.orders-table h2,
#adminDashboard h2,
#sellerProducts h2,
#sellerRequests h2,
#sellerList h2,
#userList h2,
#sellerShop h2,
#sellerBank h2 {
  text-align: center;
}

.orders-table select {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0.5rem;
}

.orders-table .button,
.admin-actions .button {
  margin-inline: auto;
}

.admin-stat-grid,
.admin-dashboard-grid,
.form-grid {
  display: grid;
  gap: 1rem;
}

.admin-stat-grid {
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  margin: 1rem 0;
}

.admin-stat-grid article {
  border: 1px solid rgba(173, 146, 112, 0.22);
  border-radius: 18px;
  padding: 1rem;
  background: var(--surface-soft);
  text-align: center;
}

.admin-stat-grid strong {
  display: block;
  font-size: 1.4rem;
  color: var(--primary);
}

.admin-stat-grid span,
.chart-row span,
.top-products span {
  color: var(--muted);
}

.admin-dashboard-grid {
  grid-template-columns: minmax(0, 1fr) minmax(260px, 0.75fr);
  align-items: start;
  text-align: center;
}

.admin-dashboard-grid h3 {
  text-align: center;
}

.chart-row {
  display: grid;
  grid-template-columns: 110px minmax(120px, 1fr) 36px;
  align-items: center;
  gap: 0.75rem;
  margin: 0.65rem 0;
}

.chart-row div {
  height: 12px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--primary-soft);
}

.chart-row i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--primary);
}

.top-products {
  display: grid;
  gap: 0.6rem;
  width: min(520px, 100%);
  margin: 0 auto;
  padding-left: 0;
  list-style-position: inside;
}

.top-products li {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
}

.admin-form {
  display: grid;
  gap: 1rem;
  margin: 1rem 0 1.4rem;
  padding: 1rem;
  border-radius: 18px;
  background: var(--surface-soft);
  border: 1px solid rgba(173, 146, 112, 0.2);
  text-align: center;
}

.form-grid {
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
}

.admin-form label {
  display: grid;
  gap: 0.45rem;
  font-weight: 600;
  text-align: center;
}

.admin-form input,
.admin-form textarea,
.admin-form select,
.admin-filter-row input,
.admin-filter-row select {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 0.75rem 0.85rem;
  background: var(--surface);
  color: var(--text);
}

.toggle-row,
.admin-actions,
.admin-filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  align-items: center;
  justify-content: center;
}

.toggle-row label {
  display: inline-flex;
  grid-template-columns: auto;
  align-items: center;
  gap: 0.45rem;
}

.toggle-row input {
  width: auto;
}

.admin-filter-row {
  margin: 0.75rem 0 1rem;
}

.admin-filter-row input {
  flex: 1 1 260px;
}

.admin-thumb {
  width: 64px;
  height: 48px;
  object-fit: cover;
  border-radius: 10px;
  background: var(--surface-soft);
}

.image-url-tools {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto;
  gap: 0.75rem;
  align-items: end;
}

.image-url-help {
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.75rem 0.9rem;
  background: var(--surface-soft);
}

.image-url-help summary {
  cursor: pointer;
  font-weight: 700;
  color: var(--text);
}

.image-url-help p,
.image-url-help ul {
  margin: 0.55rem 0;
  color: var(--muted);
}

.image-url-help ul {
  padding-left: 1.2rem;
}

.help-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.7rem;
}

.image-preview {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.image-preview-item {
  position: relative;
  margin: 0;
}

.image-preview-item figcaption {
  display: none;
  margin-top: 0.3rem;
  max-width: 86px;
  color: #9f3a2f;
  font-size: 0.75rem;
  line-height: 1.2;
}

.image-preview-item.image-load-error figcaption {
  display: block;
}

.image-preview img,
.image-preview-item img {
  width: 86px;
  height: 70px;
  object-fit: cover;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--surface-soft);
}

.image-remove {
  position: absolute;
  right: 0.25rem;
  bottom: 0.25rem;
  border: 0;
  border-radius: 999px;
  padding: 0.2rem 0.45rem;
  background: rgba(45, 42, 34, 0.78);
  color: white;
  cursor: pointer;
  font-size: 0.75rem;
}

.order-detail {
  color: var(--muted);
}

.order-detail {
  margin-top: 1rem;
  padding: 1rem;
  border-radius: 18px;
  background: var(--surface-soft);
}

.back-link {
  display: inline-block;
  margin-bottom: 1.5rem;
  color: var(--accent);
}

.site-footer {
  padding: 2rem 0;
  background: var(--footer-bg);
  color: #f3eddc;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  color: #f3eddc;
}

.footer-inner a {
  color: #f3eddc;
}

.contact-widget {
  position: fixed;
  right: 1rem;
  bottom: 1rem;
  display: flex;
  flex-direction: column-reverse;
  align-items: flex-end;
  gap: 0.55rem;
  z-index: 30;
}

.contact-widget::before {
  content: "Liên hệ sàn";
  padding: 0.35rem 0.55rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 700;
  text-align: center;
  box-shadow: 0 8px 18px rgba(42, 36, 29, 0.08);
}

.contact-item {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  background: var(--surface);
  color: var(--text);
  box-shadow: var(--shadow);
  text-align: center;
  padding: 0;
  font-size: 1.05rem;
  font-weight: 800;
  line-height: 1;
  text-decoration: none;
  border: 1px solid rgba(173, 146, 112, 0.18);
}

.contact-item:hover {
  transform: translateY(-1px);
  background: #f4efe3;
}

.contact-item[data-contact="phone"] {
  color: #3f6426;
}

.contact-item[data-contact="email"] {
  color: #7c4f1d;
}

.contact-item[data-contact="zalo"] {
  color: #0f69b4;
}

.contact-widget::before {
  content: none;
}

.contact-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  min-height: 2.55rem;
  padding: 0.45rem 0.75rem;
  border: 1px solid rgba(173, 146, 112, 0.2);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--muted);
  cursor: pointer;
  font: inherit;
  font-size: 0.82rem;
  font-weight: 700;
  text-align: center;
  box-shadow: 0 8px 18px rgba(42, 36, 29, 0.08);
}

.contact-toggle strong {
  display: inline-flex;
  width: 1.75rem;
  height: 1.75rem;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--primary);
  color: #fff;
  font-size: 0.9rem;
}

.contact-item {
  transition: opacity 0.16s ease, transform 0.16s ease, visibility 0.16s ease;
}

.contact-collapsed .contact-item {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(12px) scale(0.94);
}

.contact-open .contact-item {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0) scale(1);
}

.cart-badge {
  display: inline-flex;
  min-width: 1.6rem;
  height: 1.6rem;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--accent);
  color: white;
  font-size: 0.8rem;
  margin-left: 0.5rem;
  padding: 0 0.35rem;
}

.contact-grid,
.feature-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  align-items: center;
  justify-items: center;
}

.feature-card {
  padding: 1.4rem;
  border-radius: 24px;
  background: var(--surface);
  border: 1px solid rgba(173, 146, 112, 0.18);
  box-shadow: 0 12px 28px rgba(42, 36, 29, 0.06);
  display: flex;
  flex-direction: column;
  gap: 1rem;
  align-items: center;
  text-align: center;
}

.feature-card h3 {
    margin: 0;
  }

  .note {
    margin: 0;
    color: var(--muted);
    font-size: 0.95rem;
  }

  .quantity-control {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0.8rem 0 0;
  }

  .qty-button {
    width: 2.4rem;
    height: 2.4rem;
    border: 1px solid var(--border);
    border-radius: 14px;
    background: var(--surface);
    color: var(--text);
    font-size: 1.2rem;
    cursor: pointer;
  }

  .toast {
    position: fixed;
    right: 1rem;
    bottom: 5.7rem;
    background: rgba(67, 93, 36, 0.96);
    color: white;
    padding: 1rem 1.2rem;
    border-radius: 20px;
    box-shadow: var(--shadow);
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.2s ease, transform 0.2s ease;
    z-index: 60;
  }

  .toast.visible {
    opacity: 1;
    transform: translateY(0);
  }
@media (max-width: 720px) {
  .header-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .main-nav {
    width: 100%;
    justify-content: space-between;
  }

  .hero-section {
    padding: 2.5rem 0 2rem;
  }

  .hero-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .hero-card {
    max-width: 100%;
    margin: 0 auto;
  }

  .hero-section::before,
  .hero-section::after {
    opacity: 0.16;
    filter: blur(6px) brightness(1);
  }

  .hero-section h1 {
    max-width: 100%;
  }

  .hero-actions {
    justify-content: center;
  }

  .contact-widget {
    right: 0.75rem;
    bottom: 0.75rem;
  }

  .admin-dashboard-grid {
    grid-template-columns: 1fr;
  }

  .chart-row {
    grid-template-columns: 92px minmax(90px, 1fr) 32px;
  }

  .orders-table th,
  .orders-table td {
    padding: 0.75rem 0.6rem;
    white-space: nowrap;
  }

  .orders-table table,
  .orders-table thead,
  .orders-table tbody,
  .orders-table tr,
  .orders-table th,
  .orders-table td {
    display: block;
  }

  .orders-table thead {
    display: none;
  }

  .orders-table tr {
    margin-bottom: 1rem;
    padding: 0.85rem;
    border: 1px solid var(--border);
    border-radius: 18px;
    background: var(--surface);
  }

  .orders-table td {
    white-space: normal;
    border-bottom: 1px solid rgba(218, 201, 180, 0.55);
  }

  .orders-table td:last-child {
    border-bottom: 0;
  }

  .admin-actions,
  .admin-filter-row {
    position: sticky;
    bottom: 0;
    z-index: 10;
    padding: 0.75rem;
    margin-inline: -0.75rem;
    background: rgba(249, 242, 230, 0.94);
    border-top: 1px solid var(--border);
  }

  .image-url-tools {
    grid-template-columns: 1fr;
  }
}

/* VỊ QUÊ brand polish */
body {
  background:
    radial-gradient(circle at top left, rgba(237, 240, 220, 0.55), transparent 32rem),
    var(--bg);
  letter-spacing: 0;
}

.site-header {
  background: rgba(251, 246, 237, 0.92);
  border-bottom: 1px solid rgba(154, 115, 73, 0.12);
  box-shadow: 0 8px 24px rgba(42, 36, 29, 0.045);
}

.header-inner {
  min-height: 72px;
}

.brand-logo {
  border-radius: 16px;
  background: #f7f2e8;
  border: 1px solid rgba(89, 102, 58, 0.18);
  box-shadow: 0 8px 18px rgba(42, 36, 29, 0.06);
}

.brand strong {
  color: #39451f;
  font-size: 1.24rem;
  font-weight: 900;
  letter-spacing: 0.04em;
}

.brand span {
  color: #7a6d5d;
  font-size: 0.88rem;
}

.main-nav {
  gap: 0.35rem;
}

.main-nav a,
.main-nav a:not(.button) {
  min-height: 2.35rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.55rem 0.8rem;
  border-radius: 999px;
  color: #5d5448;
  font-weight: 700;
}

.main-nav a:hover,
.main-nav a.nav-active {
  background: var(--primary-soft);
  color: var(--primary);
  box-shadow: none;
}

.main-nav a[href="admin.html"].nav-active {
  background: var(--primary);
  color: #fff;
}

.hero-section {
  min-height: auto;
  padding: clamp(4rem, 8vw, 7rem) 0 clamp(3rem, 6vw, 5rem);
  overflow-x: hidden;
}

.hero-section::before {
  opacity: 0.12;
  filter: blur(4px) saturate(0.8);
}

.hero-section::after {
  background: rgba(248, 241, 230, 0.86);
}

.hero-grid {
  grid-template-columns: minmax(0, 1fr);
  justify-items: center;
  text-align: center;
  width: 100%;
}

.hero-grid > div:first-child {
  max-width: 780px;
}

.eyebrow {
  color: var(--accent);
  font-weight: 800;
  letter-spacing: 0.18em;
}

.hero-section h1 {
  max-width: none;
  font-size: clamp(3.5rem, 9vw, 6.4rem);
  letter-spacing: 0.08em;
  color: #39451f;
}

.hero-subtitle {
  margin-top: 0.75rem;
  color: #4f5a34 !important;
  font-size: clamp(1.35rem, 2.4vw, 1.9rem) !important;
  font-weight: 800;
}

.hero-section p:not(.eyebrow):not(.hero-subtitle) {
  max-width: 680px;
  color: #675e51;
  font-size: 1.08rem;
}

.hero-card {
  width: min(560px, calc(100% - 2rem));
  margin: 1.4rem auto 0;
  border-radius: 22px;
  opacity: 0.96;
  background: #fffaf1;
  box-shadow: 0 18px 42px rgba(42, 36, 29, 0.12);
  border: 1px solid rgba(154, 115, 73, 0.14);
}

.hero-card img {
  width: 100%;
  height: auto;
  aspect-ratio: auto;
  object-fit: contain;
  object-position: center;
  border-radius: inherit;
}

.button {
  background: var(--primary);
  box-shadow: 0 10px 18px rgba(89, 102, 58, 0.13);
}

.button:hover {
  background: #4d5a31;
}

.button-secondary {
  background: #fff;
  color: var(--primary);
  border-color: rgba(89, 102, 58, 0.42);
  box-shadow: none;
}

.section {
  padding: clamp(3.4rem, 6vw, 5.4rem) 0;
}

.section-head {
  max-width: 780px;
}

.section-head h2 {
  color: #3f392f;
  font-weight: 900;
}

.section-head p {
  color: var(--muted);
}

.product-card,
.combo-card,
.review-card,
.story-grid > div,
.feature-card,
.card {
  border-radius: 18px;
  border-color: rgba(154, 115, 73, 0.15);
  box-shadow: 0 14px 34px rgba(42, 36, 29, 0.055);
}

.product-card {
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.product-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 42px rgba(42, 36, 29, 0.09);
}

.product-card img {
  border-radius: 16px;
}

.product-card h3 {
  color: #342f27;
  font-size: 1.1rem;
  font-weight: 850;
}

.product-card .price {
  color: #8f6036;
  font-size: 1.18rem;
}

.story-grid > div::before {
  background: #f3eadb;
  color: var(--accent);
}

.review-card::before {
  background: #f3eadb;
}

.contact-grid {
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
}

.contact-form {
  box-shadow: 0 14px 34px rgba(42, 36, 29, 0.05);
}

.orders-table,
#adminDashboard,
#sellerProducts,
#sellerList,
#sellerRequests,
#userList,
#sellerShop,
#sellerBank {
  margin-inline: auto;
  border-radius: 18px;
}

.orders-table th {
  background: #f7f1e7;
}

@media (max-width: 720px) {
  .header-inner {
    gap: 0.6rem;
  }

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

  .brand span {
    font-size: 0.72rem;
  }

  .main-nav {
    max-height: 2.25rem;
  }

  body.mobile-nav-open .main-nav {
    max-height: 8.2rem;
  }

  .main-nav a,
  .main-nav a:not(.button),
  .main-nav .button {
    min-height: 2rem;
    padding: 0.38rem 0.56rem;
    font-size: 0.8rem;
  }

  .hero-section {
    padding-top: 3rem;
  }

  .hero-section h1 {
    font-size: clamp(3rem, 16vw, 4.4rem);
  }

  .hero-card {
    width: min(100% - 1.5rem, 560px);
    margin-top: 1.2rem;
    border-radius: 18px;
  }

  .hero-card img {
    aspect-ratio: auto;
    height: auto;
    object-fit: contain;
    object-position: center;
  }
}

@media (max-width: 560px) {
  .product-card {
    grid-template-columns: 1fr;
  }

  .cart-item button {
    justify-self: center;
  }
}

/* UI refinement pass */
.container {
  width: min(1280px, calc(100% - 2rem));
}

.site-header {
  backdrop-filter: blur(14px);
  box-shadow: 0 8px 24px rgba(42, 36, 29, 0.05);
}

.header-inner {
  min-height: 76px;
  padding: 0.75rem 0;
}

.brand {
  min-width: max-content;
}

.brand strong {
  font-size: 1.18rem;
  line-height: 1.2;
  color: #3f4f22;
  font-weight: 850;
}

.brand span {
  font-size: 0.86rem;
  color: #7a6349;
}

.main-nav {
  justify-content: center;
  gap: 0.35rem;
}

.main-nav a:not(.button) {
  padding: 0.55rem 0.7rem;
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.95rem;
}

.main-nav a:not(.button):hover {
  background: rgba(101, 112, 63, 0.1);
  color: var(--primary);
}

.main-nav a.nav-active {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
  box-shadow: 0 8px 18px rgba(85, 107, 47, 0.16);
}

.main-nav a.button-secondary.nav-active {
  background: var(--primary);
  color: #fff;
}

.user-menu {
  justify-content: flex-end;
  max-width: 360px;
}

.profile-chip {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 0.05rem;
  min-height: 2.45rem;
  padding: 0.45rem 0.85rem;
  text-align: center;
}

.profile-chip strong {
  max-width: 11rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--primary);
  font-size: 0.9rem;
  line-height: 1.05;
}

.profile-chip span {
  color: var(--muted);
  font-size: 0.74rem;
  line-height: 1;
}

.logout-button {
  width: 2.35rem;
  padding-inline: 0;
  justify-content: center;
  border-radius: 999px;
  white-space: nowrap;
}

.logout-button span {
  display: none;
}

.logout-icon {
  width: 1rem;
  height: 1rem;
  flex: 0 0 auto;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.mobile-nav-toggle {
  display: none;
}

.user-badge,
.user-role {
  padding: 0.42rem 0.7rem;
  font-size: 0.82rem;
}

.button {
  border-radius: 999px;
  min-height: 2.65rem;
  align-items: center;
  justify-content: center;
  transition: transform 0.16s ease, box-shadow 0.16s ease, background 0.16s ease;
}

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

.button.small {
  min-height: 2.25rem;
  padding-inline: 0.9rem;
}

.section {
  padding: clamp(3.2rem, 6vw, 5.5rem) 0;
}

.section-light {
  width: min(1280px, calc(100% - 2rem));
  margin-inline: auto;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.68);
  border: 1px solid rgba(173, 146, 112, 0.13);
}

.section-head {
  max-width: 760px;
  margin: 0 auto 2.4rem;
  text-align: center;
}

.section-head h1,
.section-head h2 {
  margin: 0 0 0.75rem;
  color: #443827;
  line-height: 1.14;
}

.section-head h1 {
  font-size: clamp(2.05rem, 4vw, 3.2rem);
}

.section-head h2 {
  font-size: clamp(1.8rem, 3vw, 2.55rem);
}

.section-head h3 {
  margin: 0 0 0.5rem;
  font-size: clamp(1.35rem, 2.2vw, 1.8rem);
}

.section-head p {
  font-size: 1.06rem;
  line-height: 1.75;
}

.sub-category > h3 {
  margin: 0 auto 1.6rem;
  text-align: center;
  color: #443827;
  font-size: clamp(1.8rem, 3vw, 2.45rem);
  line-height: 1.16;
  font-weight: 850;
}

.hero-grid {
  gap: clamp(2rem, 5vw, 4rem);
}

.hero-section h1 {
  max-width: 12ch;
}

.hero-section p {
  font-size: 1.08rem;
}

.product-grid,
.combo-grid,
.reviews-grid,
.categories-grid,
.story-grid,
.contact-grid {
  gap: clamp(1rem, 2vw, 1.6rem);
}

.story-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.story-grid > div,
.review-card,
.feature-card {
  min-height: 100%;
  border-radius: 18px;
  padding: clamp(1.35rem, 2vw, 1.9rem);
  background: var(--surface);
  border: 1px solid rgba(173, 146, 112, 0.18);
  box-shadow: 0 14px 34px rgba(42, 36, 29, 0.06);
  text-align: center;
}

.story-grid > div::before {
  content: "";
  display: grid;
  place-items: center;
  width: 2.8rem;
  height: 2.8rem;
  margin: 0 auto 1rem;
  border-radius: 50%;
  background: var(--primary-soft);
  color: var(--primary);
  font-weight: 800;
}

.story-grid > div:nth-child(1)::before {
  content: "1";
}

.story-grid > div:nth-child(2)::before {
  content: "2";
}

.story-grid > div:nth-child(3)::before {
  content: "3";
}

.story-grid h3,
.feature-card h3 {
  margin: 0 0 0.65rem;
  font-size: 1.2rem;
  color: var(--primary);
}

.story-grid p,
.review-card p,
.feature-card p {
  margin: 0;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.72;
}

.reviews-grid {
  align-items: stretch;
}

.review-card {
  position: relative;
  justify-content: space-between;
  gap: 1.4rem;
}

.review-card::before {
  content: "\"";
  display: block;
  width: 2.4rem;
  height: 2.4rem;
  margin: 0 auto 0.4rem;
  border-radius: 50%;
  background: rgba(167, 123, 76, 0.13);
  color: var(--accent);
  font-size: 2rem;
  line-height: 2.25rem;
  font-weight: 800;
}

.review-card strong {
  display: block;
  margin-top: 1rem;
  color: #443827;
  font-size: 1rem;
}

.contact-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  align-items: stretch;
}

.feature-card {
  justify-content: space-between;
}

.feature-card .button {
  width: fit-content;
  margin-inline: auto;
}

.platform-bank-card p {
  margin: 0.25rem 0;
}

.platform-bank-card strong {
  color: #443827;
}

.contact-form {
  width: min(820px, 100%);
  margin: 0 auto;
  padding: clamp(1.2rem, 2vw, 1.8rem);
  border: 1px solid rgba(173, 146, 112, 0.16);
  border-radius: 18px;
  background: var(--surface);
  box-shadow: 0 14px 34px rgba(42, 36, 29, 0.05);
}

.card,
.orders-table,
.product-detail,
.cart-summary,
.cart-item {
  border-radius: 18px;
}

main.container.section {
  display: grid;
  gap: 1.25rem;
}

.admin-stat-grid {
  gap: 1rem;
  margin: 1.25rem 0 1.5rem;
}

.admin-stat-grid article {
  border-radius: 16px;
  padding: 1.25rem;
  background: linear-gradient(180deg, rgba(233, 236, 212, 0.75), rgba(255, 255, 255, 0.92));
}

.orders-table,
#adminDashboard,
#sellerProducts,
#sellerList,
#sellerRequests,
#userList,
#sellerShop,
#sellerBank {
  padding: clamp(1rem, 2vw, 1.6rem);
}

.empty-state {
  text-align: center;
  border-radius: 16px;
  padding: 1.4rem;
  background: var(--surface-soft);
  color: var(--muted);
}

.page-nav {
  display: none;
}

@media (max-width: 1040px) {
  .header-inner {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .main-nav {
    order: 3;
    width: 100%;
    justify-content: flex-start;
  }

  .user-menu {
    margin-left: auto;
  }

  .contact-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

  .cart-summary {
    position: static;
  }
}

@media (max-width: 720px) {
  .container,
  .section-light {
    width: min(100% - 1rem, 1280px);
  }

  .header-inner {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 0.75rem;
  }

  .brand {
    min-width: 0;
    grid-column: 1;
    grid-row: 1;
    order: 1;
  }

  .brand > div {
    min-width: 0;
  }

  .brand strong,
  .brand span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .brand-logo {
    width: 54px;
    height: 54px;
    flex: 0 0 auto;
  }

  .main-nav {
    grid-column: 1 / -1;
    grid-row: 2;
    order: 3;
    justify-content: center;
    gap: 0.25rem;
    overflow: hidden;
    flex-wrap: wrap;
    max-height: 2.45rem;
    padding-bottom: 0.15rem;
    transition: max-height 0.18s ease;
  }

  body.mobile-nav-open .main-nav {
    max-height: 9rem;
  }

  .main-nav a:not(.button),
  .main-nav .button {
    white-space: nowrap;
    flex: 0 0 auto;
    font-size: 0.82rem;
    min-height: 2.05rem;
    padding: 0.42rem 0.6rem;
    text-align: center;
  }

  .user-menu {
    grid-column: 2;
    grid-row: 1;
    order: 2;
    width: auto;
    max-width: min(48vw, 240px);
    margin-left: 0;
    justify-content: flex-end;
    gap: 0.3rem;
  }

  .user-menu .profile-chip {
    display: inline-flex;
    max-width: 7.6rem;
    min-height: 2.2rem;
    padding: 0.38rem 0.58rem;
  }

  .user-menu .profile-chip strong {
    max-width: 6.5rem;
    font-size: 0.78rem;
  }

  .user-menu .profile-chip span {
    font-size: 0.66rem;
  }

  .user-menu .button {
    min-height: 2.05rem;
    padding: 0.38rem 0.58rem;
    font-size: 0.78rem;
  }

  .user-menu .logout-button {
    padding-inline: 0;
    width: 2.08rem;
    justify-content: center;
  }

  .mobile-nav-toggle {
    display: inline-flex;
    grid-column: 1 / -1;
    grid-row: 3;
    order: 4;
    justify-self: center;
    width: 2rem;
    height: 1.35rem;
    align-items: center;
    justify-content: center;
    margin-top: -0.45rem;
    border: 1px solid rgba(101, 112, 63, 0.22);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.62);
    color: var(--primary);
    font-size: 0.9rem;
    font-weight: 800;
  }

  .hero-section h1 {
    margin-inline: auto;
  }

  .hero-actions {
    justify-content: center;
  }

  .story-grid,
  .reviews-grid,
  .contact-grid,
  .product-grid,
  .combo-grid,
  .categories-grid {
    grid-template-columns: 1fr;
  }

  .section-head {
    margin-bottom: 1.5rem;
  }

  .section-light {
    border-radius: 20px;
  }

  .contact-form {
    padding: 1rem;
  }

  .cart-section {
    gap: 1rem;
  }

  .product-detail {
    grid-template-columns: 1fr;
    gap: 1.15rem;
    width: 100%;
    padding: 1rem;
    border-radius: 20px;
    text-align: center;
  }

  .product-detail > div:first-child {
    width: 100%;
  }

  .product-detail img {
    max-height: 360px;
    border-radius: 18px;
    aspect-ratio: 4 / 3;
    object-fit: contain;
    background: var(--surface-soft);
  }

  .product-info {
    gap: 0.85rem;
    width: 100%;
    align-items: stretch;
  }

  .product-info h1 {
    font-size: clamp(1.65rem, 8vw, 2.3rem);
    line-height: 1.05;
    overflow-wrap: anywhere;
  }

  .product-info > .price {
    font-size: 1.35rem;
    text-align: center;
  }

  .product-info p {
    max-width: 34rem;
    margin-inline: auto;
    line-height: 1.7;
  }

  .product-meta {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }

  .product-meta div,
  .product-info .seller-contact-box {
    border-radius: 16px;
    padding: 0.95rem;
  }

  .product-info .help-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
  }

  .product-info > .button {
    width: min(100%, 18rem);
    margin-inline: auto;
  }

  #relatedProducts {
    margin-top: 1rem;
  }

  .cart-item {
    grid-template-columns: 76px minmax(0, 1fr);
    gap: 0.8rem;
    align-items: start;
    padding: 1rem;
    text-align: center;
  }

  .cart-item img {
    justify-self: center;
    border-radius: 14px;
  }

  .cart-item h3,
  .cart-item p,
  .cart-item small {
    overflow-wrap: anywhere;
  }

  .cart-item .remove-item {
    grid-column: 1 / -1;
    justify-self: center;
  }

  .cart-summary,
  .order-form.card {
    padding: 1rem;
  }

  .footer-inner {
    justify-content: center;
    text-align: center;
  }

  .footer-inner p,
  .footer-links {
    width: 100%;
    text-align: center;
  }
}
