/* ==========================================================================
   OPLUNGDA.VN - GIAO DIỆN MOBILE-FIRST CHUẨN 100% MỌI DÒNG MÁY & VISUAL BUTTONS
   ========================================================================== */
:root {
  --bg-ivory: #FAF7F2;
  --bg-warm: #F3EDE2;
  --bg-card: #FFFFFF;
  --espresso: #181311;
  --espresso-soft: #2A201B;
  --cognac: #9A5B32;
  --cognac-dark: #7A4421;
  --gold: #C5A059;
  --gold-light: #E5C583;
  --text-main: #1E1815;
  --text-muted: #685A50;
  --border-light: #E6DDD0;
  --border-stitch: #CBB89D;
  --danger: #B91C1C;
  --success: #15803D;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 18px;
  --shadow-sm: 0 2px 10px rgba(24, 19, 17, 0.05);
  --shadow-md: 0 8px 24px rgba(24, 19, 17, 0.09);
  --shadow-lg: 0 14px 36px rgba(24, 19, 17, 0.14);
  --font-serif: 'Lora', 'Be Vietnam Pro', 'Times New Roman', serif;
  --font-sans: 'Be Vietnam Pro', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  min-width: 0; /* Chống tràn CSS Grid/Flex trên mọi trình duyệt di động */
}

html, body {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-ivory);
  color: var(--text-main);
  line-height: 1.5;
  font-size: 14.5px;
  padding-bottom: 118px; /* Chừa chỗ cho Sticky Buy Bar + Bottom Nav trên Mobile */
  position: relative;
}

@media (min-width: 960px) {
  body {
    padding-bottom: 0;
    font-size: 15.5px;
  }
}

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

img, svg {
  max-width: 100%;
  height: auto;
  display: block;
}

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

.container {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 12px;
}

@media (min-width: 768px) {
  .container {
    padding: 0 22px;
  }
}

/* 1. TOPBAR GỌN GÀNG */
.topbar {
  background: #181311;
  color: var(--gold-light);
  font-size: 11.5px;
  font-weight: 600;
  padding: 6px 10px;
  text-align: center;
  border-bottom: 1px dashed rgba(197, 160, 89, 0.35);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* 2. HEADER CHUẨN MOBILE (KHÔNG BAO GIỜ TRÀN NGANG) */
.site-header {
  position: sticky;
  top: 0;
  z-index: 900;
  background: rgba(250, 247, 242, 0.97);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border-light);
  box-shadow: 0 2px 10px rgba(24, 19, 17, 0.04);
  width: 100%;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 54px;
  padding: 6px 0;
}

.brand-logo {
  display: flex;
  align-items: center;
  flex-shrink: 1;
  max-width: 52%;
}

.brand-logo img {
  height: 36px;
  width: auto;
  max-width: 100%;
  object-fit: contain;
}

@media (min-width: 768px) {
  .header-inner {
    min-height: 70px;
  }
  .brand-logo {
    max-width: 260px;
  }
  .brand-logo img {
    height: 48px;
  }
}

.header-search {
  flex: 1;
  max-width: 400px;
  display: none;
}

@media (min-width: 820px) {
  .header-search {
    display: block;
  }
}

.search-form {
  display: flex;
  align-items: center;
  background: #FFFFFF;
  border: 1.5px solid var(--border-stitch);
  border-radius: 999px;
  padding: 3px 5px 3px 13px;
  width: 100%;
}

.search-form input {
  border: none;
  outline: none;
  background: transparent;
  width: 100%;
  font-size: 13.5px;
  color: var(--text-main);
}

.search-form button {
  background: var(--espresso);
  color: var(--gold-light);
  border: none;
  border-radius: 999px;
  padding: 6px 13px;
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
  flex-shrink: 0;
}

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

.btn-icon-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 10px;
  border-radius: 999px;
  background: #FFFFFF;
  border: 1px solid var(--border-stitch);
  font-size: 12.5px;
  font-weight: 700;
  color: var(--espresso);
  cursor: pointer;
  white-space: nowrap;
}

.hide-mobile-text {
  display: none;
}

@media (min-width: 560px) {
  .hide-mobile-text {
    display: inline;
  }
}

.cart-badge {
  background: var(--cognac);
  color: #FFF;
  font-size: 11px;
  font-weight: 700;
  min-width: 19px;
  height: 19px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 5px;
}

.mobile-search-bar {
  padding: 0 0 8px 0;
  display: block;
}

@media (min-width: 820px) {
  .mobile-search-bar {
    display: none;
  }
}

/* Thanh Menu Ngang */
.nav-strip {
  background: var(--espresso);
  color: #FAF7F2;
  width: 100%;
}

.nav-strip-inner {
  display: flex;
  align-items: center;
  gap: 6px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding: 7px 0;
  white-space: nowrap;
}

.nav-strip-inner::-webkit-scrollbar {
  display: none;
}

.nav-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 12px;
  border-radius: 999px;
  font-size: 12.5px;
  font-weight: 600;
  color: #EDE6DA;
  flex-shrink: 0;
}

.nav-link:hover, .nav-link.active {
  background: var(--cognac);
  color: #FFFFFF;
}

.nav-link-highlight {
  background: rgba(197, 160, 89, 0.2);
  color: var(--gold-light);
  border: 1px dashed rgba(229, 197, 131, 0.5);
}

/* ==========================================================================
   3. HỆ THỐNG NÚT HÌNH ẢNH SINH ĐỘNG (VISUAL IMAGE BUTTONS)
   ========================================================================== */

/* A. Lưới Nút Ảnh Chọn Hãng Máy (6 cột trên Desktop, 3 cột trên Mobile) */
.brand-img-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 12px;
}

@media (min-width: 640px) {
  .brand-img-grid {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }
}

.brand-img-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 10px 6px;
  background: #FFFFFF;
  border: 1.5px solid var(--border-light);
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.18s ease;
  text-align: center;
  position: relative;
}

.brand-img-btn svg {
  width: 30px;
  height: 30px;
  flex-shrink: 0;
}

.brand-img-btn span {
  font-size: 12px;
  font-weight: 700;
  color: var(--espresso);
  line-height: 1.2;
}

.brand-img-btn.active, .brand-img-btn:hover {
  border-color: var(--cognac);
  background: #FFF7ED;
  box-shadow: 0 3px 10px rgba(154, 91, 50, 0.16);
}

.brand-img-btn.active::after {
  content: "✓";
  position: absolute;
  top: 4px;
  right: 5px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--cognac);
  color: #FFF;
  font-size: 10px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* B. Lưới Nút Ảnh Đời Máy (Model Pill Image Buttons) */
.model-img-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
  max-height: 185px;
  overflow-y: auto;
  padding: 4px 2px;
}

@media (min-width: 540px) {
  .model-img-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.model-img-btn {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 8px 9px;
  background: #FFFFFF;
  border: 1.5px solid var(--border-light);
  border-radius: 10px;
  cursor: pointer;
  text-align: left;
  font-size: 12px;
  font-weight: 700;
  color: var(--espresso);
  transition: all 0.15s;
}

.model-img-btn .model-mini-icon {
  width: 22px;
  height: 28px;
  border-radius: 5px;
  background: var(--bg-warm);
  border: 1.5px solid var(--cognac);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 11px;
}

.model-img-btn.active {
  background: var(--espresso);
  color: var(--gold-light);
  border-color: var(--espresso);
}

.model-img-btn.active .model-mini-icon {
  background: var(--cognac);
  border-color: var(--gold-light);
  color: #FFF;
}

/* C. Lưới Nút Ảnh Vân Da Thật (Visual Texture Image Swatches - Ít chữ, Hình ảnh to sinh động) */
.swatch-img-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

@media (min-width: 420px) {
  .swatch-img-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}

@media (min-width: 640px) {
  .swatch-img-grid {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }
}

.swatch-img-option {
  cursor: pointer;
  position: relative;
}

.swatch-img-option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.swatch-img-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 6px 4px;
  border-radius: 12px;
  background: #FFFFFF;
  border: 2px solid var(--border-light);
  transition: all 0.18s ease;
  position: relative;
}

.swatch-img-thumb {
  width: 48px;
  height: 48px;
  aspect-ratio: 1 / 1;
  display: inline-block;
  flex-shrink: 0;
  overflow: hidden;
  border-radius: 50%;
  position: relative;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.22), inset 0 2px 5px rgba(255, 255, 255, 0.22);
  border: 2px dashed rgba(255, 255, 255, 0.65);
  margin-bottom: 5px;
  background-image: radial-gradient(rgba(255,255,255,0.12) 1px, transparent 0), radial-gradient(rgba(0,0,0,0.18) 1px, transparent 0);
  background-size: 6px 6px;
  background-position: 0 0, 3px 3px;
}

.swatch-img-short {
  font-size: 10.5px;
  font-weight: 700;
  color: var(--espresso);
  text-align: center;
  line-height: 1.15;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
  width: 100%;
}

.swatch-extra-tag {
  position: absolute;
  top: 2px;
  left: 2px;
  background: var(--espresso);
  color: var(--gold-light);
  font-size: 9px;
  font-weight: 800;
  padding: 1px 4px;
  border-radius: 6px;
  z-index: 2;
}

.swatch-img-option input:checked + .swatch-img-card {
  border-color: var(--cognac);
  background: #FFF7ED;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(154, 91, 50, 0.22);
}

.swatch-img-option input:checked + .swatch-img-card::after {
  content: "✓";
  position: absolute;
  top: 3px;
  right: 3px;
  width: 17px;
  height: 17px;
  border-radius: 50%;
  background: var(--cognac);
  color: #FFF;
  font-size: 10px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* D. Lưới Nút Ảnh Chọn Kiểu Chữ Khắc (Font Visual Image Cards) */
.font-img-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 12px;
}

@media (min-width: 540px) {
  .font-img-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

.font-img-btn {
  background: linear-gradient(135deg, #4A2B18 0%, #2B170C 100%);
  border: 2px solid #6E472B;
  border-radius: 10px;
  padding: 8px 6px;
  color: #F5DF9E;
  text-align: center;
  cursor: pointer;
  position: relative;
}

.font-img-btn .font-sample-preview {
  display: block;
  font-size: 16px;
  color: #FFF3D1;
  margin-bottom: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.font-img-btn small {
  font-size: 10px;
  color: #D5B882;
  display: block;
}

.font-img-btn.active {
  border-color: #F0D596;
  box-shadow: 0 0 0 2px rgba(197, 160, 89, 0.45);
}

/* E. Lưới Nút Ảnh Chọn Mẫu Khắc Laser (Visual Pattern Emblem Buttons) */
.pattern-tabs-row {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  scrollbar-width: none;
  margin-bottom: 8px;
  padding-bottom: 2px;
}

.pattern-tabs-row::-webkit-scrollbar {
  display: none;
}

.pattern-tab-chip {
  flex-shrink: 0;
  padding: 5px 11px;
  border-radius: 999px;
  background: #FFFFFF;
  border: 1px solid var(--border-stitch);
  font-size: 11.5px;
  font-weight: 700;
  color: var(--espresso);
  cursor: pointer;
}

.pattern-tab-chip.active {
  background: var(--espresso);
  color: var(--gold-light);
  border-color: var(--espresso);
}

.pattern-img-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 7px;
  max-height: 210px;
  overflow-y: auto;
  padding: 2px;
}

@media (min-width: 540px) {
  .pattern-img-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}

.pattern-img-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 8px 4px;
  background: #FFFFFF;
  border: 1.5px solid var(--border-light);
  border-radius: 10px;
  cursor: pointer;
  text-align: center;
  position: relative;
}

.pattern-emblem-circle {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: radial-gradient(circle, #3D2415 0%, #1F120A 100%);
  border: 1px dashed #C5A059;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  margin-bottom: 4px;
}

.pattern-short-name {
  font-size: 10.5px;
  font-weight: 700;
  color: var(--espresso);
  line-height: 1.15;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.pattern-img-btn.selected {
  border-color: var(--cognac);
  background: #FFF7ED;
  box-shadow: 0 2px 8px rgba(154, 91, 50, 0.2);
}

.pattern-img-btn.selected::after {
  content: "✓";
  position: absolute;
  top: 3px;
  right: 3px;
  width: 15px;
  height: 15px;
  border-radius: 50%;
  background: var(--cognac);
  color: #FFF;
  font-size: 9px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* F. Lưới Nút Ảnh Chọn Quà Tặng Kèm (Gift Visual Cards) */
.gift-img-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

@media (min-width: 540px) {
  .gift-img-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

.gift-img-option {
  cursor: pointer;
  position: relative;
}

.gift-img-option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.gift-img-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 10px 8px;
  background: #FFFFFF;
  border: 1.5px solid var(--border-light);
  border-radius: 12px;
  position: relative;
  height: 100%;
}

.gift-icon-box {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: linear-gradient(135deg, #3A2314, #1E120A);
  border: 1px dashed #C5A059;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  margin-bottom: 6px;
}

.gift-img-card strong {
  font-size: 11.5px;
  color: var(--espresso);
  line-height: 1.25;
  margin-bottom: 3px;
}

.gift-free-badge {
  font-size: 10px;
  font-weight: 800;
  background: #DCFCE7;
  color: #166534;
  padding: 1px 7px;
  border-radius: 999px;
}

.gift-img-option input:checked + .gift-img-card {
  border-color: var(--cognac);
  background: #FFF7ED;
  box-shadow: 0 3px 10px rgba(154, 91, 50, 0.18);
}

.gift-img-option input:checked + .gift-img-card::after {
  content: "✓";
  position: absolute;
  top: 4px;
  right: 5px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--cognac);
  color: #FFF;
  font-size: 10px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* G. Lưới Nút Ảnh Danh Mục Nhanh Trên Trang Chủ */
.cat-visual-strip {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 24px;
}

@media (min-width: 640px) {
  .cat-visual-strip {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}

.cat-visual-card {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #FFFFFF;
  border: 1.5px solid var(--border-light);
  border-radius: 14px;
  padding: 10px;
  box-shadow: var(--shadow-sm);
  transition: all 0.2s;
}

.cat-visual-card:hover {
  border-color: var(--cognac);
  transform: translateY(-2px);
}

.cat-visual-card img {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  object-fit: cover;
  flex-shrink: 0;
  background: #181311;
}

.cat-visual-card strong {
  font-size: 13px;
  color: var(--espresso);
  display: block;
  line-height: 1.25;
}

.cat-visual-card small {
  font-size: 11px;
  color: var(--cognac);
  font-weight: 600;
}

/* ==========================================================================
   4. HERO BANNER & TRANG CHỦ (CHUẨN CO GIÃN MOBILE)
   ========================================================================== */
.hero-section {
  padding: 14px 0 20px;
}

.hero-card {
  background: radial-gradient(circle at 70% 30%, #332016 0%, #160F0B 78%);
  color: #FAF7F2;
  border-radius: var(--radius-lg);
  border: 1.5px solid rgba(197, 160, 89, 0.45);
  box-shadow: var(--shadow-md);
  padding: 18px 14px;
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
  align-items: center;
}

@media (min-width: 900px) {
  .hero-card {
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr);
    padding: 38px 42px;
  }
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(197, 160, 89, 0.18);
  border: 1px solid rgba(229, 197, 131, 0.5);
  color: var(--gold-light);
  padding: 4px 11px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  margin-bottom: 10px;
}

.hero-title {
  font-family: var(--font-serif);
  font-size: 22px;
  line-height: 1.28;
  color: #FFFDF9;
  margin-bottom: 10px;
}

@media (min-width: 900px) {
  .hero-title {
    font-size: 36px;
  }
}

.hero-subtitle {
  color: #D9CEC1;
  font-size: 13.5px;
  margin-bottom: 16px;
}

.hero-cta-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: linear-gradient(135deg, #D9B671 0%, #A8762A 100%);
  color: #181311;
  font-weight: 800;
  padding: 11px 18px;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  font-size: 13.5px;
  box-shadow: 0 4px 14px rgba(197, 160, 89, 0.3);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.08);
  color: #FAF7F2;
  border: 1px solid rgba(229, 197, 131, 0.45);
  font-weight: 700;
  padding: 11px 16px;
  border-radius: 999px;
  font-size: 13.5px;
  cursor: pointer;
}

.hero-trust-pills {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

@media (min-width: 600px) {
  .hero-trust-pills {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

.trust-pill {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(229, 197, 131, 0.22);
  border-radius: 9px;
  padding: 8px 9px;
  font-size: 11.5px;
  color: #E8DFD3;
}

.trust-pill strong {
  display: block;
  color: var(--gold-light);
  font-size: 12.5px;
}

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

.hero-visual img {
  width: 100%;
  max-width: 260px;
  border-radius: 14px;
  border: 1px solid rgba(229, 197, 131, 0.35);
}

@media (min-width: 900px) {
  .hero-visual img {
    max-width: 320px;
  }
}

/* 5. BỘ CHỌN NHANH THEO DÒNG MÁY */
.device-finder-box {
  background: #FFFFFF;
  border: 2px dashed var(--border-stitch);
  border-radius: var(--radius-md);
  padding: 14px;
  margin-bottom: 24px;
  box-shadow: var(--shadow-sm);
}

.finder-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 12px;
}

.finder-title {
  font-family: var(--font-serif);
  font-size: 17.5px;
  color: var(--espresso);
}

.finder-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 8px;
}

@media (min-width: 768px) {
  .finder-grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr) minmax(0, 1fr) auto;
  }
}

.finder-select {
  width: 100%;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1.5px solid var(--border-light);
  background: var(--bg-ivory);
  font-weight: 600;
  color: var(--espresso);
}

/* 6. LƯỚI SẢN PHẨM (2 CỘT CHUẨN MOBILE) */
.section-block {
  margin-bottom: 30px;
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 14px;
  border-bottom: 1px dashed var(--border-stitch);
  padding-bottom: 8px;
}

.section-title {
  font-family: var(--font-serif);
  font-size: 19px;
  color: var(--espresso);
}

@media (min-width: 768px) {
  .section-title {
    font-size: 25px;
  }
}

.section-sub {
  font-size: 12.5px;
  color: var(--text-muted);
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

@media (min-width: 768px) {
  .product-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
  }
}

@media (min-width: 1080px) {
  .product-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px;
  }
}

.product-card {
  background: #FFFFFF;
  border: 1px solid var(--border-light);
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  position: relative;
}

.product-thumb-wrap {
  position: relative;
  aspect-ratio: 1 / 1;
  background: #181311;
  overflow: hidden;
}

.product-thumb-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.badge-top-left {
  position: absolute;
  top: 6px;
  left: 6px;
  background: linear-gradient(135deg, #D9B671, #9A6B22);
  color: #181311;
  font-size: 10px;
  font-weight: 800;
  padding: 2px 7px;
  border-radius: 999px;
  z-index: 2;
}

.badge-discount {
  position: absolute;
  top: 6px;
  right: 6px;
  background: #B91C1C;
  color: #FFFFFF;
  font-size: 10px;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: 999px;
  z-index: 2;
}

.product-body {
  padding: 10px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.product-meta-tag {
  font-size: 10.5px;
  color: var(--cognac);
  font-weight: 600;
  margin-bottom: 3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.product-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--espresso);
  line-height: 1.35;
  margin-bottom: 6px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

@media (min-width: 768px) {
  .product-title {
    font-size: 14.5px;
  }
}

.product-swatch-dots {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-bottom: 8px;
}

.dot-color {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 1px solid rgba(0, 0, 0, 0.25);
  flex-shrink: 0;
}

.product-price-row {
  margin-top: auto;
  display: flex;
  align-items: baseline;
  gap: 6px;
  flex-wrap: wrap;
}

.price-current {
  font-size: 15px;
  font-weight: 800;
  color: var(--cognac-dark);
}

.price-old {
  font-size: 11.5px;
  color: #9A8F85;
  text-decoration: line-through;
}

.product-card-btn {
  margin-top: 8px;
  width: 100%;
  padding: 7px 8px;
  border-radius: 8px;
  background: var(--espresso);
  color: var(--gold-light);
  font-size: 12px;
  font-weight: 700;
  text-align: center;
  display: block;
}

/* ==========================================================================
   7. TRANG CHI TIẾT SẢN PHẨM & BỘ TÙY BIẾN HÌNH ẢNH (KHỚP 100% ĐIỆN THOẠI)
   ========================================================================== */
.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
  margin: 12px 0 28px;
  width: 100%;
}

@media (min-width: 960px) {
  .detail-layout {
    grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr);
    gap: 30px;
    align-items: start;
  }
}

.detail-gallery-card {
  background: #FFFFFF;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 12px;
  box-shadow: var(--shadow-sm);
  width: 100%;
}

@media (min-width: 960px) {
  .detail-gallery-card {
    position: sticky;
    top: 88px;
    padding: 16px;
  }
}

.main-preview-stage {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  background: #181311;
  aspect-ratio: 1 / 0.88;
  width: 100%;
}

.main-preview-stage img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.live-stage-overlay {
  position: absolute;
  bottom: 8px;
  left: 8px;
  right: 8px;
  background: rgba(24, 19, 17, 0.9);
  backdrop-filter: blur(6px);
  border: 1px dashed rgba(229, 197, 131, 0.55);
  border-radius: 10px;
  padding: 8px 11px;
  color: #FAF7F2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.live-color-chip {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 12px;
  min-width: 0;
}

.live-color-dot {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid var(--gold-light);
  flex-shrink: 0;
}

.laser-preview-patch {
  margin-top: 10px;
  background: linear-gradient(135deg, #5C3317 0%, #361C0B 100%);
  border: 2px dashed rgba(229, 197, 131, 0.65);
  border-radius: 12px;
  padding: 12px 10px;
  text-align: center;
  color: #F2D398;
  box-shadow: inset 0 3px 10px rgba(0, 0, 0, 0.45);
  width: 100%;
}

.laser-preview-label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: rgba(242, 211, 152, 0.8);
  margin-bottom: 4px;
}

.laser-preview-output {
  min-height: 28px;
  font-size: 18px;
  color: #F7DFB2;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.85);
  word-break: break-word;
}

.font-script { font-family: 'Dancing Script', 'Be Vietnam Pro', 'Segoe UI', cursive; font-weight: 700; font-size: 21px; }
.font-serif-classic { font-family: 'Lora', 'Times New Roman', serif; font-weight: 700; letter-spacing: 0.6px; }
.font-modern { font-family: 'Be Vietnam Pro', -apple-system, 'Segoe UI', Arial, sans-serif; font-weight: 700; letter-spacing: 1px; }
.font-mono { font-family: Consolas, 'Segoe UI', Roboto, monospace; font-weight: 700; letter-spacing: 1.6px; text-transform: uppercase; }

/* Khung tùy biến bên phải */
.customizer-panel {
  background: #FFFFFF;
  border: 1.5px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 14px 12px;
  box-shadow: var(--shadow-sm);
  width: 100%;
}

@media (min-width: 768px) {
  .customizer-panel {
    padding: 22px;
  }
}

.step-box {
  border: 1px solid var(--border-light);
  background: var(--bg-ivory);
  border-radius: 12px;
  padding: 12px 10px;
  margin-bottom: 14px;
  width: 100%;
}

.step-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  margin-bottom: 10px;
  font-weight: 700;
  color: var(--espresso);
  font-size: 13.5px;
  flex-wrap: wrap;
}

.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--espresso);
  color: var(--gold-light);
  font-size: 11.5px;
  margin-right: 6px;
}

/* 8. STICKY BUY BAR & BOTTOM NAV TRÊN MOBILE */
.mobile-sticky-buy {
  position: fixed;
  bottom: 56px;
  left: 0;
  right: 0;
  width: 100%;
  background: #FFFFFF;
  border-top: 1.5px solid var(--border-stitch);
  padding: 8px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  z-index: 880;
  box-shadow: 0 -4px 14px rgba(0, 0, 0, 0.08);
}

@media (min-width: 960px) {
  .mobile-sticky-buy {
    display: none;
  }
}

.mobile-bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  width: 100%;
  height: 56px;
  background: var(--espresso);
  border-top: 1px dashed rgba(229, 197, 131, 0.35);
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  z-index: 910;
}

@media (min-width: 960px) {
  .mobile-bottom-nav {
    display: none;
  }
}

.bottom-nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: #D9CEC1;
  font-size: 10px;
  font-weight: 600;
  gap: 2px;
  white-space: nowrap;
  overflow: hidden;
}

.bottom-nav-item.active, .bottom-nav-item:hover {
  color: var(--gold-light);
}

.bottom-nav-icon {
  font-size: 16px;
  line-height: 1;
}

/* 9. CÁC THÀNH PHẦN CHUNG */
.card-panel {
  background: #FFFFFF;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 15px;
  box-shadow: var(--shadow-sm);
  margin-bottom: 18px;
  width: 100%;
}

.form-group {
  margin-bottom: 12px;
}

.form-label {
  display: block;
  font-weight: 600;
  font-size: 13px;
  margin-bottom: 4px;
  color: var(--espresso);
}

.form-control {
  width: 100%;
  padding: 10px 12px;
  border: 1.5px solid var(--border-light);
  border-radius: 9px;
  background: #FFFFFF;
  color: var(--text-main);
}

.alert-box {
  padding: 11px 14px;
  border-radius: 10px;
  margin-bottom: 14px;
  font-weight: 600;
  font-size: 13.5px;
}

.alert-success { background: #ECFDF5; border: 1px solid #A7F3D0; color: #065F46; }
.alert-error { background: #FEF2F2; border: 1px solid #FECACA; color: #991B1B; }

.site-footer {
  background: var(--espresso);
  color: #D9CEC1;
  padding: 36px 0 28px;
  margin-top: 36px;
  border-top: 3px solid var(--gold);
  width: 100%;
}

.footer-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 22px;
}

@media (min-width: 768px) {
  .footer-grid {
    grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1.1fr);
  }
}

.footer-title {
  font-family: var(--font-serif);
  color: var(--gold-light);
  font-size: 16px;
  margin-bottom: 10px;
}

.footer-links { list-style: none; }
.footer-links li { margin-bottom: 7px; font-size: 13.5px; }
.desc-heading { font-family: var(--font-serif); font-size: 18px; color: var(--espresso); margin: 14px 0 8px; }
.desc-list { padding-left: 18px; margin-bottom: 12px; }
.desc-list li { margin-bottom: 6px; }
.desc-para { margin-bottom: 10px; }
