/* ===========================
   VF3Custom — Design System
   Apple Minimalist · Mobile First
   =========================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

/* --- Reset & Base --- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --bg:         #ffffff;
  --surface:    #f5f5f7;
  --border:     #d2d2d7;
  --text-1:     #1d1d1f;
  --text-2:     #6e6e73;
  --text-3:     #aeaeb2;
  --accent:     #0071e3;
  --accent-dark:#0058b0;
  --thumb-bg:   #e8e8ed;
  --thumb-icon: #aeaeb2;
  --radius-sm:  10px;
  --radius-md:  16px;
  --radius-pill:100px;
  --shadow-card:0 4px 20px rgba(0,0,0,.04), 0 1px 4px rgba(0,0,0,.02);
  --shadow-btn: 0 4px 12px rgba(0,113,227,.25);
  --font:       'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --max-w:      640px;
  --page-px:    20px;
  --transition: 200ms cubic-bezier(.4,0,.2,1);
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text-1);
  line-height: 1.5;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, textarea, select { 
  font-family: inherit; 
}
button { cursor: pointer; border: none; background: none; }
ul { list-style: none; }

/* --- Layout --- */
.container {
  width: 100%;
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: var(--page-px);
}

/* ===========================
   HEADER
   =========================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255,255,255,.82);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--border);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 52px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 8px;
}

.logo-img {
  height: 22px;
  width: auto;
  display: block;
  object-fit: contain;
}

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

.header-nav-link {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-2);
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  transition: color var(--transition), background var(--transition);
}
.header-nav-link:hover { color: var(--text-1); background: var(--surface); }
.header-nav-link--active { color: var(--text-1); font-weight: 600; }

.header-cart-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 13px;
  background: var(--accent);
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  border-radius: var(--radius-pill);
  transition: background var(--transition), transform var(--transition);
  flex-shrink: 0;
  white-space: nowrap;
}
.header-cart-btn:hover {
  background: var(--accent-dark);
  transform: translateY(-1px);
}
.header-cart-btn svg {
  width: 15px;
  height: 15px;
  stroke: #fff;
  flex-shrink: 0;
}

/* ===========================
   HERO
   =========================== */
.hero {
  padding: 64px 0 48px;
  text-align: center;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 16px;
  opacity: 0;
  animation: fadeUp .5s .1s forwards;
}

.hero-eyebrow::before,
.hero-eyebrow::after {
  content: '';
  display: block;
  width: 20px;
  height: 1px;
  background: currentColor;
  opacity: .5;
}

.hero-tagline {
  font-size: clamp(30px, 8vw, 40px);
  font-weight: 700;
  letter-spacing: -.03em;
  line-height: 1.15;
  color: var(--text-1);
  margin-bottom: 14px;
  opacity: 0;
  animation: fadeUp .5s .2s forwards;
}

.hero-desc {
  font-size: 15px;
  color: var(--text-2);
  line-height: 1.65;
  max-width: 320px;
  margin-inline: auto;
  margin-bottom: 32px;
  opacity: 0;
  animation: fadeUp .5s .3s forwards;
}

/* --- CTA Group --- */
.cta-group {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  opacity: 0;
  animation: fadeUp .5s .4s forwards;
}

.btn-tiktok {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  background: #000;
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  border-radius: var(--radius-pill);
  transition: background var(--transition), transform var(--transition);
  text-decoration: none;
}
.btn-tiktok svg { width: 18px; height: 18px; fill: currentColor; flex-shrink: 0; }
.btn-tiktok:hover { background: #2a2a2a; transform: translateY(-1px); }
.btn-tiktok:active { transform: translateY(0); }

.btn-shopee-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  background: #ee4d2d;
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  border-radius: var(--radius-pill);
  transition: background var(--transition), transform var(--transition);
  text-decoration: none;
}
.btn-shopee-cta svg { width: 18px; height: 18px; fill: currentColor; flex-shrink: 0; }
.btn-shopee-cta:hover { background: #d44226; transform: translateY(-1px); }
.btn-shopee-cta:active { transform: translateY(0); }

.btn-zalo-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  background: #0068ff;
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  border-radius: var(--radius-pill);
  transition: background var(--transition), transform var(--transition);
  text-decoration: none;
}
.btn-zalo-cta svg { width: 18px; height: 18px; fill: currentColor; flex-shrink: 0; }
.btn-zalo-cta:hover { background: #0055cc; transform: translateY(-1px); }
.btn-zalo-cta:active { transform: translateY(0); }

/* Freeship note */
.hero-freeship {
  display: inline-block;
  margin-top: 4px;
  font-size: 13px;
  font-weight: 500;
  color: #1a7f37;
}


/* ===========================
   PRODUCT SECTION
   =========================== */
.products-section {
  padding: 0 0 64px;
}

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

.section-title {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -.02em;
}

.section-count {
  font-size: 13px;
  color: var(--text-3);
  font-weight: 400;
}

/* --- Grid --- */
.product-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

/* --- Card --- */
.product-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition);
  will-change: transform;
  opacity: 0;
  transform: translateY(10px);
}

.product-card.visible {
  opacity: 1;
  transform: translateY(0);
  transition: opacity .4s ease, transform .4s ease,
              box-shadow var(--transition), border-color var(--transition), scale var(--transition);
}

.product-card:hover {
  box-shadow: var(--shadow-card);
  border-color: #b8b8be;
  transform: scale(1.015);
}

.product-card:active {
  transform: scale(.98);
}

/* Thumbnail */
.product-thumb {
  width: 100%;
  aspect-ratio: 1 / 1 !important;
  background: var(--surface);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--border); /* Phân tách với info */
}

.product-thumb svg {
  width: 40%;
  height: 40%;
  fill: var(--thumb-icon);
  opacity: .7;
}

.product-thumb img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  object-position: center !important;
  position: absolute;
  inset: 0;
  background-color: transparent !important;
}

/* Info */
.product-info {
  padding: 12px 12px 14px;
}

.product-name {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-1);
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 6px;
}

.product-price {
  font-size: 14px;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: -.01em;
}

/* --- Loading skeleton --- */
.product-card.skeleton .product-thumb,
.product-card.skeleton .product-name,
.product-card.skeleton .product-price {
  background: linear-gradient(90deg,
    var(--surface) 25%,
    var(--border) 50%,
    var(--surface) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.4s infinite;
  border-radius: 4px;
}

.product-card.skeleton .product-name { height: 16px; width: 80%; }
.product-card.skeleton .product-price { height: 14px; width: 45%; margin-top: 8px; }

@keyframes shimmer {
  0%   { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* ===========================
   EMPTY STATE
   =========================== */
.empty-state {
  grid-column: 1 / -1;
  text-align: center;
  padding: 48px 0;
  color: var(--text-3);
  font-size: 14px;
}

/* ===========================
   FOOTER
   =========================== */
.site-footer {
  margin-top: auto;
  border-top: 1px solid var(--border);
  background: var(--bg);
  padding: 20px 0;
  text-align: center;
}

.site-footer p {
  font-size: 12px;
  color: var(--text-3);
  line-height: 1.6;
}

.site-footer a {
  color: var(--text-2);
  transition: color var(--transition);
}
.site-footer a:hover { color: var(--accent); }

/* ===========================
   ANIMATIONS
   =========================== */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ===========================
   RESPONSIVE — Tablet / Desktop
   =========================== */
@media (min-width: 640px) {
  :root { --page-px: 32px; }

  .hero { padding: 80px 0 64px; }

  .hero-tagline { font-size: 44px; }

  .product-grid {
    gap: 16px;
  }

  .product-card:hover {
    transform: translateY(-3px) scale(1.01);
  }
}

@media (min-width: 900px) {
  :root {
    --max-w: 800px;
    --page-px: 40px;
  }

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

/* ===========================
   POLICY PAGE
   =========================== */

.policy-hero {
  padding: 48px 0 36px;
  text-align: center;
  border-bottom: 1px solid var(--border);
  margin-bottom: 36px;
}

.policy-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 14px;
}

.policy-hero-badge::before,
.policy-hero-badge::after {
  content: '';
  display: block;
  width: 16px;
  height: 1px;
  background: currentColor;
  opacity: .5;
}

.policy-hero h1 {
  font-size: clamp(22px, 6vw, 32px);
  font-weight: 700;
  letter-spacing: -.03em;
  line-height: 1.2;
  color: var(--text-1);
  margin-bottom: 10px;
}

.policy-hero .sub {
  font-size: 14px;
  color: var(--text-2);
}

/* Policy sections */
.policy-body {
  padding-bottom: 64px;
}

.policy-intro {
  font-size: 15px;
  color: var(--text-2);
  line-height: 1.7;
  margin-bottom: 28px;
  padding: 16px;
  background: var(--surface);
  border-radius: var(--radius-sm);
  border-left: 3px solid var(--accent);
}

.policy-section {
  margin-bottom: 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity .4s ease, transform .4s ease;
}

.policy-section.visible {
  opacity: 1;
  transform: translateY(0);
}

.policy-section-header {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px 16px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

.policy-number {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--text-1);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.policy-section-title {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-1);
  flex: 1;
  line-height: 1.3;
}

.policy-chevron {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  color: var(--text-3);
  transition: transform var(--transition);
}

.policy-section[open] .policy-chevron {
  transform: rotate(180deg);
}

.policy-section-body {
  padding: 16px;
}

.policy-section-body p {
  font-size: 14px;
  color: var(--text-2);
  line-height: 1.7;
  margin-bottom: 12px;
}

.policy-section-body p:last-child {
  margin-bottom: 0;
}

.policy-item {
  display: flex;
  gap: 10px;
  padding: 12px;
  background: var(--surface);
  border-radius: var(--radius-sm);
  margin-bottom: 8px;
}

.policy-item:last-child { margin-bottom: 0; }

.policy-item-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
  margin-top: 6px;
}

.policy-item-content {
  flex: 1;
}

.policy-item-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-1);
  margin-bottom: 3px;
}

.policy-item-desc {
  font-size: 13px;
  color: var(--text-2);
  line-height: 1.6;
  margin: 0 !important;
}

/* Contact CTA */
.policy-contact {
  margin-top: 28px;
  padding: 24px 20px;
  background: var(--text-1);
  border-radius: var(--radius-md);
  text-align: center;
  color: #fff;
}

.policy-contact p {
  font-size: 14px;
  color: rgba(255,255,255,.65);
  line-height: 1.6;
  margin-bottom: 16px;
}

.policy-contact-brand {
  font-size: 17px;
  font-weight: 700;
  color: #fff;
  letter-spacing: -.02em;
  margin-bottom: 6px;
}

.policy-contact-tagline {
  font-size: 13px;
  color: rgba(255,255,255,.55);
  margin-bottom: 20px !important;
}

.btn-zalo {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 22px;
  background: #0068ff;
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  border-radius: var(--radius-pill);
  transition: background var(--transition), transform var(--transition);
}

.btn-zalo:hover {
  background: #0056d2;
  transform: translateY(-1px);
}

.btn-zalo svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.btn-zalo-phone {
  font-size: 13px;
  opacity: .8;
  margin-top: 4px;
  font-weight: 400;
}

/* ===========================
   PRODUCT DETAIL PAGE
   =========================== */

/* Back nav */
.back-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 12px 0;
  font-size: 14px;
  font-weight: 500;
  color: var(--accent);
  cursor: pointer;
  width: fit-content;
  transition: opacity var(--transition);
  -webkit-tap-highlight-color: transparent;
}
.back-nav:hover { opacity: .7; }
.back-nav svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  fill: none;
}

/* ===========================
   SLIDER
   =========================== */
.slider-section {
  /* Full bleed — no horizontal padding */
  margin-inline: calc(-1 * var(--page-px));
}

.slider-wrapper {
  position: relative;
  background: var(--thumb-bg);
  overflow: hidden;
}

.slider-track {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  cursor: grab;
}
.slider-track:active { cursor: grabbing; }
.slider-track::-webkit-scrollbar { display: none; }

.slide {
  flex: 0 0 100%;
  scroll-snap-align: start;
  aspect-ratio: 1 / 1;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--thumb-bg);
  position: relative;
  overflow: hidden;
}

.slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: absolute;
  inset: 0;
}

.slide video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: absolute;
  inset: 0;
}

/* Placeholder slide */
.slide-placeholder svg {
  width: 28%;
  height: 28%;
  fill: var(--thumb-icon);
  opacity: .6;
}

/* Video badge */
.slide-video-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  background: rgba(0,0,0,.55);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: var(--radius-pill);
  display: flex;
  align-items: center;
  gap: 4px;
  z-index: 2;
  pointer-events: none;
}
.slide-video-badge svg {
  width: 10px;
  height: 10px;
  fill: currentColor;
}

/* Slide counter badge */
.slide-counter {
  position: absolute;
  top: 10px;
  right: 10px;
  background: rgba(0,0,0,.45);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: var(--radius-pill);
  z-index: 2;
  pointer-events: none;
}

/* Dot indicators */
.slider-dots {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 6px;
  padding: 12px 0 8px;
}

.slider-dot {
  height: 6px;
  width: 6px;
  border-radius: var(--radius-pill);
  background: var(--border);
  border: none;
  padding: 0;
  cursor: pointer;
  transition: background var(--transition), width var(--transition);
  flex-shrink: 0;
}
.slider-dot.active {
  width: 18px;
  background: var(--text-1);
}

/* ===========================
   PRODUCT DETAIL INFO
   =========================== */
.product-detail {
  padding: 20px 0 160px; /* bottom padding for sticky CTA */
}

.product-detail-price {
  font-size: 22px;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: -.02em;
  margin-bottom: 6px;
}

.product-detail-name {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -.02em;
  line-height: 1.3;
  color: var(--text-1);
  margin-bottom: 16px;
}

.product-detail-divider {
  height: 1px;
  background: var(--border);
  margin: 16px 0;
}

.product-detail-desc-label {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--text-3);
  margin-bottom: 8px;
}

.product-detail-desc {
  font-size: 15px;
  color: var(--text-2);
  line-height: 1.75;
}

/* ===========================
   STICKY ACTION BAR
   =========================== */
.product-actions {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 200;
  background: rgba(255,255,255,.9);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-top: 1px solid var(--border);
  padding: 12px var(--page-px) max(12px, env(safe-area-inset-bottom));
}

.product-actions-inner {
  display: flex;
  gap: 10px;
  max-width: var(--max-w);
  margin-inline: auto;
}

.btn-add-order {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 14px 12px;
  background: var(--text-1);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  border-radius: var(--radius-pill);
  border: none;
  cursor: pointer;
  transition: background var(--transition), transform var(--transition);
  -webkit-tap-highlight-color: transparent;
}
.btn-add-order svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
  flex-shrink: 0;
}
.btn-add-order:hover { background: #3a3a3c; }
.btn-add-order:active { transform: scale(.97); }

.btn-buy-shopee {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 14px 12px;
  background: var(--accent);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  border-radius: var(--radius-pill);
  text-decoration: none;
  transition: background var(--transition), transform var(--transition);
  -webkit-tap-highlight-color: transparent;
}
.btn-buy-shopee svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
  flex-shrink: 0;
}
.btn-buy-shopee:hover { background: var(--accent-dark); }
.btn-buy-shopee:active { transform: scale(.97); }

/* ===========================
   ORDER TOAST / BOTTOM SHEET
   =========================== */
.order-toast {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 300;
  transform: translateY(100%);
  transition: transform .35s cubic-bezier(.4,0,.2,1);
}
.order-toast.show { transform: translateY(0); }

.order-toast-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.3);
  z-index: 299;
  opacity: 0;
  transition: opacity .3s ease;
  pointer-events: none;
}
.order-toast-backdrop.show {
  opacity: 1;
  pointer-events: auto;
}

.order-toast-sheet {
  background: var(--bg);
  border-radius: 20px 20px 0 0;
  padding: 20px 20px max(20px, env(safe-area-inset-bottom));
  max-width: var(--max-w);
  margin-inline: auto;
}

.order-toast-handle {
  width: 36px;
  height: 4px;
  background: var(--border);
  border-radius: var(--radius-pill);
  margin: 0 auto 16px;
}

.order-toast-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-1);
  margin-bottom: 4px;
}

.order-toast-subtitle {
  font-size: 13px;
  color: var(--text-2);
  margin-bottom: 20px;
  line-height: 1.5;
}

.order-toast-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.btn-zalo-order {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px;
  background: #0068ff;
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  border-radius: var(--radius-pill);
  text-decoration: none;
  transition: background var(--transition);
}
.btn-zalo-order:hover { background: #0056d2; }
.btn-zalo-order svg { width: 18px; height: 18px; fill: currentColor; }

.btn-toast-close {
  padding: 13px;
  text-align: center;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-2);
  border-radius: var(--radius-pill);
  background: var(--surface);
  border: none;
  cursor: pointer;
  width: 100%;
}
.btn-toast-close:hover { background: var(--border); }

/* ===========================
   PRODUCT PAGE RESPONSIVE
   =========================== */
@media (min-width: 640px) {
  .slider-section {
    margin-inline: 0;
    border-radius: var(--radius-md);
    overflow: hidden;
  }

  .product-actions-inner {
    max-width: var(--max-w);
  }
}

/* ===========================
   CART BADGE
   =========================== */
.cart-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  background: #ff3b30;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  border-radius: 9px;
  line-height: 1;
  margin-left: 2px;
}
.cart-badge[hidden] { display: none !important; }

/* ===========================
   ADD-TO-CART FEEDBACK TOAST
   =========================== */
.add-toast {
  position: fixed;
  bottom: calc(70px + env(safe-area-inset-bottom, 12px));
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  background: #1c1c1e;
  color: #fff;
  font-size: 14px;
  font-weight: 500;
  border-radius: var(--radius-pill);
  box-shadow: 0 4px 20px rgba(0,0,0,.3);
  white-space: nowrap;
  z-index: 300;
  animation: fadeUp .25s ease;
}
.add-toast svg { width: 16px; height: 16px; stroke: #30d158; }
.add-toast[hidden] { display: none; }

.btn-add-order.added {
  background: #30d158;
}

/* ===========================
   CART PAGE
   =========================== */
.cart-page-header {
  display: flex;
  align-items: baseline;
  gap: 10px;
  padding: 24px 0 16px;
}
.cart-page-title {
  font-size: 28px;
  font-weight: 700;
  letter-spacing: -.03em;
  margin: 0;
}
.cart-page-count {
  font-size: 14px;
  color: var(--text-2);
}

/* Cart list */
.cart-list {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin-bottom: 16px;
}

.cart-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 0;
  border-bottom: 1px solid var(--border);
}

.cart-item-thumb {
  width: 72px;
  height: 72px;
  border-radius: var(--radius-sm);
  background: var(--surface);
  overflow: hidden;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.cart-item-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.cart-item-thumb svg {
  width: 36px;
  height: 36px;
  fill: var(--text-3);
}

.cart-item-info { flex: 1; min-width: 0; }
.cart-item-name { font-size: 14px; font-weight: 500; margin: 0 0 4px; line-height: 1.3; }
.cart-item-link { color: var(--text-1); text-decoration: none; }
.cart-item-link:hover { text-decoration: underline; }
.cart-item-price {
  font-size: 15px;
  font-weight: 600;
  color: var(--accent);
  margin: 0 0 10px;
}

/* Qty control */
.qty-control {
  display: inline-flex;
  align-items: center;
  gap: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  height: 32px;
}
.qty-btn {
  width: 32px;
  height: 32px;
  font-size: 18px;
  font-weight: 400;
  line-height: 1;
  background: transparent;
  color: var(--text-1);
  border: none;
  cursor: pointer;
  transition: background var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
}
.qty-btn:hover { background: var(--surface); }
.qty-val {
  min-width: 32px;
  text-align: center;
  font-size: 14px;
  font-weight: 600;
  border-left: 1px solid var(--border);
  border-right: 1px solid var(--border);
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Remove button */
.cart-item-remove {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: transparent;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-2);
  transition: background var(--transition), color var(--transition);
  flex-shrink: 0;
}
.cart-item-remove:hover { background: #ff3b3015; color: #ff3b30; }
.cart-item-remove svg { width: 16px; height: 16px; }

/* Summary */
.cart-summary {
  background: var(--surface);
  border-radius: var(--radius-md);
  padding: 16px 18px;
  margin-bottom: 100px;
}
.cart-summary-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 15px;
  margin-bottom: 8px;
}
.cart-summary-total {
  font-size: 20px;
  font-weight: 700;
  color: var(--accent);
}
.cart-summary-note {
  font-size: 12px;
  color: var(--text-2);
  margin: 0;
}

/* Empty state */
.cart-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 64px 20px;
  text-align: center;
}
.cart-empty-icon { font-size: 48px; margin-bottom: 16px; }
.cart-empty-title { font-size: 17px; font-weight: 600; margin: 0 0 16px; }
.cart-empty-link {
  font-size: 14px;
  color: var(--accent);
  font-weight: 500;
  text-decoration: none;
}
.cart-empty-link:hover { text-decoration: underline; }

/* Cart order bar */
.cart-order-bar { z-index: 200; }

/* ===========================
   VARIANT SHEET
   =========================== */
.variant-sheet-backdrop {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.5);
  z-index: 400;
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  opacity: 1; transition: opacity .25s ease;
}
.variant-sheet-backdrop[hidden] { opacity: 0; pointer-events: none; }

.variant-sheet {
  position: fixed; left: 0; right: 0; bottom: 0;
  z-index: 401;
  transform: translateY(0);
  transition: transform .3s cubic-bezier(0.32, 0.72, 0, 1);
}
.variant-sheet[hidden] { transform: translateY(100%); pointer-events: none; }

.variant-sheet-container {
  background: var(--bg);
  border-radius: 20px 20px 0 0;
  box-shadow: 0 -4px 24px rgba(0,0,0,0.1);
  display: flex; flex-direction: column;
  max-height: 85vh;
}

.variant-sheet-handle {
  width: 40px; height: 4px;
  background: var(--border);
  border-radius: 2px;
  margin: 12px auto;
}

.variant-sheet-header {
  display: flex; gap: 16px;
  padding: 0 20px 20px;
  border-bottom: 1px solid var(--border);
  position: relative;
}

.variant-sheet-thumb {
  width: 64px; height: 64px;
  border-radius: var(--radius-sm);
  background: var(--surface);
  overflow: hidden;
  display: flex; align-items: center; justify-content: center;
}
.variant-sheet-thumb img { width: 100%; height: 100%; object-fit: cover; }
.variant-sheet-thumb svg { width: 32px; height: 32px; fill: var(--text-3); }

.variant-sheet-info { flex: 1; min-width: 0; padding-top: 4px; }
.variant-sheet-title { font-size: 15px; font-weight: 500; margin: 0 0 6px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.variant-sheet-price { font-size: 16px; font-weight: 600; color: var(--accent); margin: 0; }

.variant-sheet-close {
  position: absolute; top: -4px; right: 16px;
  width: 32px; height: 32px; border-radius: 50%;
  background: var(--surface); border: none; cursor: pointer; color: var(--text-2);
  display: flex; align-items: center; justify-content: center;
}
.variant-sheet-close:hover { background: var(--border); }

.variant-sheet-body {
  padding: 20px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.variant-group { margin-bottom: 24px; }
.variant-group-title { font-size: 14px; font-weight: 600; margin: 0 0 12px; }
.variant-group-title.error { color: #ff3b30; }

.variant-options { display: flex; flex-wrap: wrap; gap: 10px; }
.variant-opt-btn {
  padding: 8px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg); color: var(--text-1);
  font-size: 14px; font-weight: 500;
  cursor: pointer; transition: all var(--transition);
}
.variant-opt-btn:hover { border-color: var(--text-2); }
.variant-opt-btn.active { border-color: var(--accent); background: var(--accent); color: #fff; }

.variant-sheet-footer {
  padding: 16px 20px calc(16px + env(safe-area-inset-bottom, 12px));
  border-top: 1px solid var(--border);
}

.btn-primary {
  width: 100%; padding: 14px;
  background: var(--text-1); color: var(--bg);
  border: none; border-radius: var(--radius-pill);
  font-size: 16px; font-weight: 600;
  cursor: pointer; transition: opacity .2s ease;
}
.btn-primary:active { opacity: .8; }
.btn-primary:disabled { background: var(--surface); color: var(--text-3); cursor: not-allowed; }

/* ===========================
   BUY GUIDE (Hướng dẫn)
   =========================== */
.buy-guide {
  width: 100%;
  max-width: 360px;
  margin: 0 auto 24px;
  border-radius: var(--radius-md);
  overflow: hidden;
  text-align: left;
  background: #000;
  border: 1px solid #333;
}

.buy-guide-toggle {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 13px 16px;
  font-size: 14px;
  font-weight: 600;
  color: #fff;
  background: #000;
  cursor: pointer;
  list-style: none;
  user-select: none;
  border-radius: calc(var(--radius-md) - 1px) calc(var(--radius-md) - 1px) 0 0;
}
.buy-guide-toggle::-webkit-details-marker { display: none; }
.buy-guide-toggle:hover { background: #222; }

.buy-guide-icon { display: none; }

.buy-guide-chevron {
  width: 16px;
  height: 16px;
  margin-left: auto;
  flex-shrink: 0;
  stroke: #fff;
  transition: transform .25s ease;
}

.buy-guide[open] .buy-guide-chevron {
  transform: rotate(180deg);
}

.buy-guide-steps {
  list-style: none;
  margin: 0;
  padding: 0 16px;
  border-top: 1px solid #333;
  display: flex;
  flex-direction: column;
}

.buy-guide-step {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 0;
  border-bottom: 1px solid #333;
}
.buy-guide-step:last-child { border-bottom: none; }

.buy-guide-num {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  background: #30d158;
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 1px;
}

.buy-guide-step p {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.55;
  color: #fff;
}
