/* ==========================================================================
   ĐIỆN MÁY TÚ THỦY - MODERN HIGH-END ELECTRONICS RETAIL DESIGN SYSTEM
   Palette: Rich Tech Red, Navy Sapphire, Warm Gold, Soft Glassmorphism
   Typography: 'Be Vietnam Pro', -apple-system, BlinkMacSystemFont, sans-serif
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Be+Vietnam+Pro:wght@300;400;500;600;700;800;900&display=swap');

:root {
  /* Brand Palette */
  --brand-red: #d32f2f;
  --brand-red-dark: #b71c1c;
  --brand-red-light: #ef4444;
  --brand-navy: #0f172a;
  --brand-blue: #0284c7;
  --brand-gold: #f59e0b;
  --brand-green: #10b981;

  /* Neutrals */
  --bg-primary: #ffffff;
  --bg-secondary: #f8fafc;
  --bg-surface: #ffffff;
  --bg-card: #ffffff;
  --text-main: #1e293b;
  --text-muted: #64748b;
  --text-inverse: #ffffff;
  --border-color: #e2e8f0;
  --border-focus: #ef4444;

  /* Effects */
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-full: 9999px;
  --shadow-sm: 0 2px 8px rgba(15, 23, 42, 0.06);
  --shadow-md: 0 8px 24px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 16px 40px rgba(15, 23, 42, 0.12);
  --shadow-red: 0 10px 30px rgba(211, 47, 47, 0.35);
  --glass-bg: rgba(255, 255, 255, 0.85);
  --glass-border: rgba(255, 255, 255, 0.3);
  --transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

body.dark-mode {
  --bg-primary: #090d16;
  --bg-secondary: #0f172a;
  --bg-surface: #131d33;
  --bg-card: #18233c;
  --text-main: #f1f5f9;
  --text-muted: #94a3b8;
  --border-color: rgba(255, 255, 255, 0.1);
  --glass-bg: rgba(19, 29, 51, 0.88);
  --glass-border: rgba(255, 255, 255, 0.15);
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.4);
}

/* Base Resets */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: 'Be Vietnam Pro', sans-serif;
  background-color: var(--bg-primary);
  color: var(--text-main);
  line-height: 1.6;
  overflow-x: hidden;
  transition: background-color 0.3s ease, color 0.3s ease;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  cursor: pointer;
  font-family: inherit;
  border: none;
  background: none;
}

img {
  max-width: 100%;
  display: block;
}

.container {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 20px;
}

/* ==========================================================================
   TOP NOTIFICATION BAR & HEADER
   ========================================================================== */
.top-notice-bar {
  background: linear-gradient(90deg, #b71c1c 0%, #d32f2f 50%, #dc2626 100%);
  color: #ffffff;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 7px 0;
  letter-spacing: 0.3px;
}

.top-notice-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.top-contact-pills {
  display: flex;
  gap: 16px;
  align-items: center;
}

.top-contact-pills a {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: opacity 0.2s;
}

.top-contact-pills a:hover {
  opacity: 0.85;
}

.main-header {
  position: sticky;
  top: 0;
  z-index: 990;
  background: var(--glass-bg);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-color);
  transition: var(--transition);
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  gap: 20px;
}

.brand-logo-block {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-logo-icon {
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, #d32f2f 0%, #b71c1c 100%);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 900;
  font-size: 1.4rem;
  box-shadow: 0 6px 16px rgba(211, 47, 47, 0.4);
  border: 2px solid rgba(255, 255, 255, 0.6);
}

.brand-logo-text {
  display: flex;
  flex-direction: column;
}

.brand-main-title {
  font-size: 1.35rem;
  font-weight: 900;
  letter-spacing: -0.3px;
  color: var(--brand-red);
  line-height: 1.2;
}

.brand-sub-title {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Search Bar in Header */
.header-search-box {
  flex: 1;
  max-width: 460px;
  position: relative;
}

.header-search-box input {
  width: 100%;
  padding: 10px 42px 10px 18px;
  border-radius: var(--radius-full);
  border: 1.5px solid var(--border-color);
  background: var(--bg-surface);
  color: var(--text-main);
  font-size: 0.9rem;
  outline: none;
  transition: var(--transition);
}

.header-search-box input:focus {
  border-color: var(--brand-red);
  box-shadow: 0 0 0 3px rgba(211, 47, 47, 0.15);
}

.header-search-box .search-icon {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  pointer-events: none;
}

/* Header Action Controls */
.header-action-group {
  display: flex;
  align-items: center;
  gap: 12px;
}

.header-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border-radius: var(--radius-full);
  font-weight: 700;
  font-size: 0.88rem;
  transition: var(--transition);
}

.btn-hotline {
  background: #fee2e2;
  color: #b91c1c;
  border: 1px solid #fca5a5;
}

body.dark-mode .btn-hotline {
  background: rgba(220, 38, 38, 0.2);
  color: #fca5a5;
  border-color: rgba(220, 38, 38, 0.4);
}

.btn-hotline:hover {
  background: #dc2626;
  color: #ffffff;
}

.btn-cart-trigger {
  position: relative;
  background: var(--bg-surface);
  border: 1.5px solid var(--border-color);
  color: var(--text-main);
  padding: 8px 16px;
}

.btn-cart-trigger:hover {
  border-color: var(--brand-red);
  color: var(--brand-red);
}

.cart-count-badge {
  position: absolute;
  top: -6px;
  right: -6px;
  background: var(--brand-red);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 800;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 6px rgba(211, 47, 47, 0.4);
}

.theme-toggle-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.theme-toggle-btn:hover {
  transform: rotate(20deg);
}

/* Secondary Navigation */
.sub-nav-bar {
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border-color);
  padding: 10px 0;
}

.sub-nav-links {
  display: flex;
  gap: 24px;
  overflow-x: auto;
  white-space: nowrap;
  padding-bottom: 2px;
}

.sub-nav-links a {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-main);
  transition: color 0.2s;
  display: flex;
  align-items: center;
  gap: 6px;
}

.sub-nav-links a:hover,
.sub-nav-links a.active {
  color: var(--brand-red);
}

/* ==========================================================================
   HERO BANNER & STORE SHOWCASE
   ========================================================================== */
.hero-section {
  position: relative;
  padding: 40px 0 60px;
  background: radial-gradient(circle at 10% 20%, rgba(211, 47, 47, 0.08) 0%, transparent 40%),
              radial-gradient(circle at 90% 80%, rgba(2, 132, 199, 0.08) 0%, transparent 40%);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 40px;
  align-items: center;
}

.hero-badge-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(211, 47, 47, 0.1);
  color: var(--brand-red);
  padding: 6px 16px;
  border-radius: var(--radius-full);
  font-size: 0.82rem;
  font-weight: 700;
  margin-bottom: 18px;
  border: 1px solid rgba(211, 47, 47, 0.2);
}

.hero-title {
  font-size: 2.7rem;
  font-weight: 900;
  line-height: 1.2;
  letter-spacing: -0.5px;
  margin-bottom: 18px;
}

.hero-title span.highlight {
  color: var(--brand-red);
  position: relative;
  display: inline-block;
}

.hero-description {
  font-size: 1.05rem;
  color: var(--text-muted);
  margin-bottom: 28px;
  max-width: 540px;
}

.hero-feature-pills {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-bottom: 32px;
}

.hero-pill-item {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--bg-surface);
  padding: 10px 14px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  font-size: 0.88rem;
  font-weight: 600;
}

.hero-pill-item i {
  color: var(--brand-red);
  font-size: 1.1rem;
}

.hero-cta-buttons {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 28px;
  border-radius: var(--radius-full);
  font-weight: 700;
  font-size: 0.95rem;
  transition: var(--transition);
}

.btn-primary {
  background: linear-gradient(135deg, #d32f2f 0%, #b71c1c 100%);
  color: #fff;
  box-shadow: var(--shadow-red);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 34px rgba(211, 47, 47, 0.5);
}

.btn-outline {
  border: 2px solid var(--brand-red);
  color: var(--brand-red);
  background: transparent;
}

.btn-outline:hover {
  background: rgba(211, 47, 47, 0.08);
}

/* Hero Store Showcase Image Card */
.hero-visual-card {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  border: 2px solid rgba(255, 255, 255, 0.4);
}

.hero-visual-card img {
  width: 100%;
  height: auto;
  max-height: 540px;
  object-fit: cover;
  object-position: center top;
  display: block;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.hero-visual-card:hover img {
  transform: scale(1.03);
}

.hero-visual-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 24px;
  background: linear-gradient(to top, rgba(15, 23, 42, 0.95) 0%, rgba(15, 23, 42, 0.5) 60%, transparent 100%);
  color: #ffffff;
}

.hero-overlay-tag {
  background: var(--brand-red);
  padding: 4px 10px;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  display: inline-block;
  margin-bottom: 6px;
}

.hero-overlay-title {
  font-size: 1.25rem;
  font-weight: 800;
  margin-bottom: 4px;
}

.hero-overlay-sub {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.85);
}

/* Authorized Brands Marquee Bar */
.brand-marquee-section {
  padding: 24px 0;
  background: var(--bg-surface);
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
}

.brand-marquee-title {
  text-align: center;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-muted);
  letter-spacing: 1px;
  margin-bottom: 16px;
}

.brand-logos-row {
  display: flex;
  justify-content: space-around;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
}

.brand-badge-item {
  font-weight: 800;
  font-size: 1.15rem;
  color: var(--text-muted);
  letter-spacing: 1px;
  opacity: 0.75;
  transition: var(--transition);
}

.brand-badge-item:hover {
  opacity: 1;
  color: var(--brand-red);
  transform: translateY(-2px);
}

/* ==========================================================================
   360° SHOWROOM VIRTUAL TOUR SECTION
   ========================================================================== */
.tour-360-section {
  padding: 70px 0;
  background: var(--bg-secondary);
}

.section-head {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 40px;
}

.section-badge {
  display: inline-block;
  background: rgba(2, 132, 199, 0.12);
  color: var(--brand-blue);
  padding: 5px 14px;
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  font-weight: 700;
  margin-bottom: 10px;
}

.section-title {
  font-size: 2.1rem;
  font-weight: 900;
  letter-spacing: -0.5px;
  margin-bottom: 12px;
  line-height: 1.35;
  text-wrap: balance;
}

.section-desc {
  font-size: 0.98rem;
  color: var(--text-muted);
  line-height: 1.6;
  text-wrap: pretty;
}

.tour-360-card {
  position: relative;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border-color);
}

.panorama-container {
  width: 100%;
  height: 520px;
  position: relative;
  background: #000;
  cursor: grab;
}

.panorama-container:active {
  cursor: grabbing;
}

.p360-canvas {
  width: 100%;
  height: 100%;
  display: block;
}

.p360-controls {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(15, 23, 42, 0.75);
  backdrop-filter: blur(12px);
  padding: 8px 16px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  gap: 10px;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.2);
  z-index: 20;
}

.p360-btn {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.p360-btn:hover,
.p360-btn.active {
  background: var(--brand-red);
}

.p360-hint {
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.9);
  padding: 0 6px;
}

/* 360 Hotspots */
.p360-hotspots-layer {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 10;
}

.p360-hotspot {
  position: absolute;
  transform: translate(-50%, -50%);
  pointer-events: auto;
}

.p360-hotspot-pin {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--brand-red);
  border: 2px solid #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1.1rem;
  box-shadow: 0 4px 14px rgba(211, 47, 47, 0.6);
  cursor: pointer;
  position: relative;
  transition: var(--transition);
}

.p360-pin-pulse {
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 2px solid var(--brand-red);
  animation: hotspotPulse 2s cubic-bezier(0.16, 1, 0.3, 1) infinite;
}

@keyframes hotspotPulse {
  0% { transform: scale(0.9); opacity: 1; }
  100% { transform: scale(1.6); opacity: 0; }
}

.p360-hotspot-card {
  position: absolute;
  bottom: 48px;
  left: 50%;
  transform: translateX(-50%) translateY(10px);
  width: 250px;
  background: rgba(15, 23, 42, 0.92);
  backdrop-filter: blur(12px);
  color: #ffffff;
  padding: 14px;
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.2);
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
  font-size: 0.85rem;
}

.p360-hotspot:hover .p360-hotspot-card {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

.p360-hotspot-card h4 {
  font-size: 0.92rem;
  font-weight: 800;
  margin-bottom: 4px;
  color: #fca5a5;
}

.p360-hotspot-btn {
  margin-top: 8px;
  width: 100%;
  padding: 6px;
  background: var(--brand-red);
  color: #fff;
  border-radius: var(--radius-sm);
  font-size: 0.78rem;
  font-weight: 700;
}

/* Tour Scene Switcher Bar */
.tour-scenes-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  background: var(--bg-surface);
  border-top: 1px solid var(--border-color);
  flex-wrap: wrap;
  gap: 14px;
}

.tour-angle-group {
  display: flex;
  gap: 10px;
}

.tour-angle-btn {
  padding: 8px 16px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-color);
  background: var(--bg-secondary);
  font-size: 0.84rem;
  font-weight: 700;
  color: var(--text-main);
  transition: var(--transition);
}

.tour-angle-btn.active,
.tour-angle-btn:hover {
  background: var(--brand-red);
  color: #fff;
  border-color: var(--brand-red);
}

.google-maps-360-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.86rem;
  font-weight: 700;
  color: var(--brand-blue);
  background: rgba(2, 132, 199, 0.1);
  padding: 8px 16px;
  border-radius: var(--radius-full);
}

/* ==========================================================================
   DYNAMIC PRODUCT CATALOG
   ========================================================================== */
.catalog-section {
  padding: 70px 0;
  background: var(--bg-primary);
}

.catalog-header-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
  margin-bottom: 30px;
}

.catalog-tabs {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.cat-tab {
  padding: 9px 18px;
  border-radius: var(--radius-full);
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text-main);
  white-space: nowrap;
  transition: var(--transition);
}

.cat-tab.active,
.cat-tab:hover {
  background: var(--brand-red);
  color: #fff;
  border-color: var(--brand-red);
}

.catalog-filter-controls {
  display: flex;
  gap: 12px;
}

.catalog-filter-controls select {
  padding: 8px 14px;
  border-radius: var(--radius-md);
  border: 1.5px solid var(--border-color);
  background: var(--bg-surface);
  color: var(--text-main);
  font-size: 0.85rem;
  font-weight: 600;
  outline: none;
}

/* Product Grid */
.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}

.product-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  transition: var(--transition);
}

.product-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-md);
  border-color: rgba(211, 47, 47, 0.4);
}

.product-img-box {
  position: relative;
  height: 230px;
  background: #f1f5f9;
  overflow: hidden;
}

body.dark-mode .product-img-box {
  background: #0f172a;
}

.product-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.product-card:hover .product-img {
  transform: scale(1.06);
}

.product-badge {
  position: absolute;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  z-index: 2;
}

.badge-discount {
  top: 12px;
  left: 12px;
  background: var(--brand-red);
  color: #fff;
}

.badge-feature {
  top: 12px;
  right: 12px;
  background: var(--brand-navy);
  color: #fff;
}

.product-overlay-actions {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: var(--transition);
}

.product-card:hover .product-overlay-actions {
  opacity: 1;
}

.btn-quick-view {
  background: #ffffff;
  color: #0f172a;
  padding: 8px 18px;
  border-radius: var(--radius-full);
  font-weight: 700;
  font-size: 0.84rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  transform: translateY(10px);
  transition: var(--transition);
}

.product-card:hover .btn-quick-view {
  transform: translateY(0);
}

.product-info {
  padding: 18px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.product-brand-tag {
  font-size: 0.72rem;
  font-weight: 800;
  color: var(--brand-blue);
  margin-bottom: 6px;
  letter-spacing: 0.5px;
}

.product-title {
  font-size: 1.02rem;
  font-weight: 700;
  line-height: 1.35;
  margin-bottom: 10px;
  cursor: pointer;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  height: 2.7em;
}

.product-title:hover {
  color: var(--brand-red);
}

.product-spec-list {
  list-style: none;
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-bottom: 14px;
}

.product-spec-list li {
  margin-bottom: 3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.product-price-box {
  display: flex;
  flex-direction: column;
  margin-bottom: 8px;
}

.product-price-meta-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.74rem;
  color: var(--text-muted);
  font-weight: 700;
  margin-bottom: 3px;
}

.price-daily-tag {
  font-size: 0.68rem;
  background: rgba(2, 132, 199, 0.1);
  color: var(--brand-blue);
  padding: 1px 6px;
  border-radius: 4px;
  font-weight: 600;
}

.product-price-main-row {
  display: flex;
  align-items: baseline;
  gap: 8px;
  flex-wrap: wrap;
}

.product-sale-price {
  font-size: 1.25rem;
  font-weight: 900;
  color: var(--brand-red);
  letter-spacing: -0.3px;
}

.product-sale-price .price-prefix {
  font-size: 1.05rem;
  font-weight: 800;
  margin-right: 1px;
}

.product-orig-price {
  font-size: 0.86rem;
  color: var(--text-muted);
  text-decoration: line-through;
}

.product-installment-tag {
  background: rgba(245, 158, 11, 0.12);
  color: #b45309;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  font-size: 0.75rem;
  font-weight: 600;
  margin-bottom: 16px;
}

body.dark-mode .product-installment-tag {
  color: #fbbf24;
}

.product-card-footer {
  margin-top: auto;
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 8px;
}

.btn-card-cart {
  background: var(--bg-secondary);
  color: var(--text-main);
  border: 1px solid var(--border-color);
  padding: 9px 12px;
  border-radius: var(--radius-md);
  font-size: 0.82rem;
  font-weight: 700;
  transition: var(--transition);
}

.btn-card-cart:hover {
  background: var(--brand-red);
  color: #fff;
  border-color: var(--brand-red);
}

.btn-card-call {
  background: #fee2e2;
  color: #b91c1c;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 9px 12px;
  border-radius: var(--radius-md);
  font-size: 0.82rem;
  font-weight: 700;
}

.btn-card-call:hover {
  background: #dc2626;
  color: #fff;
}

/* ==========================================================================
   INSTALLMENT 0% CALCULATOR SECTION
   ========================================================================== */
.installment-section {
  padding: 70px 0;
  background: radial-gradient(circle at 80% 20%, rgba(211, 47, 47, 0.05) 0%, transparent 50%), var(--bg-secondary);
}

.installment-calculator-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-lg);
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  overflow: hidden;
}

.calc-left {
  padding: 36px;
  border-right: 1px solid var(--border-color);
}

.calc-right {
  padding: 36px;
  background: linear-gradient(135deg, rgba(211, 47, 47, 0.03) 0%, rgba(2, 132, 199, 0.03) 100%);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.calc-group {
  margin-bottom: 24px;
}

.calc-label {
  font-size: 0.88rem;
  font-weight: 700;
  margin-bottom: 8px;
  display: flex;
  justify-content: space-between;
}

.calc-slider {
  width: 100%;
  accent-color: var(--brand-red);
  height: 8px;
  border-radius: var(--radius-full);
}

.calc-btn-group {
  display: flex;
  gap: 10px;
}

.calc-option-btn {
  flex: 1;
  padding: 10px;
  border-radius: var(--radius-md);
  border: 1.5px solid var(--border-color);
  background: var(--bg-surface);
  font-size: 0.86rem;
  font-weight: 700;
  color: var(--text-main);
  transition: var(--transition);
}

.calc-option-btn.active,
.calc-option-btn:hover {
  border-color: var(--brand-red);
  background: rgba(211, 47, 47, 0.08);
  color: var(--brand-red);
}

.calc-result-box {
  background: var(--bg-surface);
  border-radius: var(--radius-md);
  padding: 24px;
  border: 1px solid var(--border-color);
  margin-bottom: 20px;
}

.calc-monthly-highlight {
  font-size: 2.2rem;
  font-weight: 900;
  color: var(--brand-red);
  line-height: 1.1;
  margin: 8px 0;
}

.calc-meta-row {
  display: flex;
  justify-content: space-between;
  padding: 8px 0;
  border-bottom: 1px dashed var(--border-color);
  font-size: 0.88rem;
}

.calc-meta-row:last-child {
  border-bottom: none;
}

/* ==========================================================================
   GOOGLE MAPS & CONTACT SECTION
   ========================================================================== */
.contact-map-section {
  padding: 70px 0;
  background: var(--bg-primary);
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 36px;
}

.contact-info-card {
  background: var(--bg-card);
  padding: 32px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-md);
}

.contact-item {
  display: flex;
  gap: 16px;
  margin-bottom: 22px;
}

.contact-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: rgba(211, 47, 47, 0.1);
  color: var(--brand-red);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  flex-shrink: 0;
}

.map-wrapper {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-color);
  min-height: 400px;
}

.map-wrapper iframe {
  width: 100%;
  height: 100%;
  min-height: 440px;
  border: none;
  display: block;
}

/* ==========================================================================
   CART INQUIRY DRAWER & MODAL
   ========================================================================== */
.cart-drawer-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
}

.cart-drawer-overlay.active {
  opacity: 1;
  visibility: visible;
}

.cart-drawer {
  position: fixed;
  top: 0;
  right: -420px;
  width: 420px;
  max-width: 90vw;
  height: 100vh;
  background: var(--bg-card);
  z-index: 1001;
  display: flex;
  flex-direction: column;
  box-shadow: -8px 0 30px rgba(0, 0, 0, 0.25);
  transition: right 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.cart-drawer.active {
  right: 0;
}

.cart-drawer-header {
  padding: 20px;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.cart-drawer-body {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
}

.cart-item-row {
  display: flex;
  gap: 12px;
  padding-bottom: 14px;
  margin-bottom: 14px;
  border-bottom: 1px solid var(--border-color);
}

.cart-item-thumb {
  width: 64px;
  height: 64px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  background: #f1f5f9;
}

.cart-item-details {
  flex: 1;
}

.cart-item-title {
  font-size: 0.85rem;
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 4px;
}

.cart-item-price {
  font-size: 0.9rem;
  font-weight: 800;
  color: var(--brand-red);
}

.cart-qty-ctrls {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 6px;
}

.cart-qty-ctrls button {
  width: 24px;
  height: 24px;
  border-radius: 4px;
  border: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
}

.cart-remove-btn {
  margin-left: auto;
  color: #ef4444;
}

.cart-drawer-footer {
  padding: 20px;
  border-top: 1px solid var(--border-color);
  background: var(--bg-surface);
}

/* Modal Chi Tiết Sản Phẩm */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(8px);
  z-index: 1010;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.modal-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  max-width: 900px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border-color);
}

.modal-close-btn {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.1);
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
}

.modal-product-layout {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 30px;
  padding: 30px;
}

.modal-product-img {
  width: 100%;
  height: 320px;
  object-fit: cover;
  border-radius: var(--radius-md);
  margin-bottom: 16px;
}

.modal-store-badges {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.modal-store-badges .badge-item {
  font-size: 0.78rem;
  font-weight: 600;
  background: var(--bg-secondary);
  padding: 6px 10px;
  border-radius: var(--radius-sm);
}

.modal-sale-price {
  font-size: 1.8rem;
  font-weight: 900;
  color: var(--brand-red);
}

.modal-orig-price {
  font-size: 1.1rem;
  color: var(--text-muted);
  text-decoration: line-through;
  margin-left: 10px;
}

.modal-discount-pill {
  background: #fee2e2;
  color: #b91c1c;
  padding: 3px 8px;
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  font-weight: 800;
  margin-left: 10px;
}

.modal-installment-banner {
  background: rgba(245, 158, 11, 0.12);
  color: #b45309;
  padding: 10px 14px;
  border-radius: var(--radius-md);
  font-size: 0.85rem;
  margin: 16px 0;
}

.modal-specs-list {
  list-style: none;
  margin: 12px 0 20px;
}

.modal-specs-list li {
  padding: 4px 0;
  border-bottom: 1px dashed var(--border-color);
  font-size: 0.88rem;
}

.modal-action-buttons {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

/* ==========================================================================
   BRAND ASSISTANT INTEGRATOR (HỎI ĐIỆN MÁY TÚ THỦY)
   Standard: No AI tags, Pure Brand, High-end Glassmorphism FAB
   ========================================================================== */
.dmtt-fab-launcher {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9995;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 20px 12px 14px;
  background: linear-gradient(135deg, #d32f2f 0%, #b71c1c 100%);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: var(--radius-full);
  box-shadow: 0 10px 30px rgba(211, 47, 47, 0.45);
  cursor: pointer;
  user-select: none;
  transition: var(--transition);
}

.dmtt-fab-launcher:hover {
  transform: translateY(-4px) scale(1.03);
  box-shadow: 0 16px 36px rgba(211, 47, 47, 0.65);
}

.dmtt-fab-icon-box {
  position: relative;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
}

.dmtt-fab-pulse {
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 2px solid #fca5a5;
  animation: fabPulse 2s cubic-bezier(0.16, 1, 0.3, 1) infinite;
}

@keyframes fabPulse {
  0% { transform: scale(0.9); opacity: 0.9; }
  100% { transform: scale(1.5); opacity: 0; }
}

.dmtt-fab-text {
  display: flex;
  flex-direction: column;
  text-align: left;
  line-height: 1.2;
}

.dmtt-fab-title {
  font-size: 0.92rem;
  font-weight: 800;
  letter-spacing: 0.2px;
}

.dmtt-fab-sub {
  font-size: 0.68rem;
  font-weight: 500;
  opacity: 0.9;
}

.dmtt-fab-badge {
  background: #ffffff;
  color: #b71c1c;
  font-size: 0.65rem;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: var(--radius-full);
  text-transform: uppercase;
  margin-left: 2px;
}

/* Chat Window Modal */
.dmtt-chat-window {
  position: fixed;
  bottom: 90px;
  right: 24px;
  width: 400px;
  max-width: 92vw;
  height: 600px;
  max-height: 82vh;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  border: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  z-index: 9996;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px) scale(0.96);
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}

.dmtt-chat-window.open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
}

.dmtt-chat-header {
  padding: 16px;
  background: linear-gradient(135deg, #d32f2f 0%, #b71c1c 100%);
  color: #ffffff;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.dmtt-chat-profile {
  display: flex;
  align-items: center;
  gap: 10px;
}

.dmtt-avatar {
  position: relative;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
}

.dmtt-online-dot {
  position: absolute;
  bottom: 0;
  right: 0;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #10b981;
  border: 2px solid #ffffff;
}

.dmtt-title {
  font-size: 1rem;
  font-weight: 800;
  line-height: 1.2;
}

.dmtt-status-text {
  font-size: 0.7rem;
  opacity: 0.88;
}

.dmtt-header-actions {
  display: flex;
  gap: 6px;
}

.dmtt-icon-btn {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
}

.dmtt-chips-bar {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding: 10px 14px;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-color);
}

.dmtt-chip {
  padding: 5px 12px;
  border-radius: var(--radius-full);
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  font-size: 0.74rem;
  font-weight: 600;
  white-space: nowrap;
  color: var(--text-main);
  transition: var(--transition);
}

.dmtt-chip:hover {
  background: var(--brand-red);
  color: #fff;
  border-color: var(--brand-red);
}

.dmtt-chat-body {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.dmtt-msg {
  display: flex;
  gap: 8px;
  max-width: 88%;
}

.dmtt-msg.bot {
  align-self: flex-start;
}

.dmtt-msg.user {
  align-self: flex-end;
  flex-direction: row-reverse;
}

.dmtt-msg-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(211, 47, 47, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  flex-shrink: 0;
}

.dmtt-msg-bubble {
  padding: 10px 14px;
  border-radius: 14px;
  font-size: 0.88rem;
  line-height: 1.45;
}

.dmtt-msg.bot .dmtt-msg-bubble {
  background: var(--bg-secondary);
  color: var(--text-main);
  border: 1px solid var(--border-color);
  border-bottom-left-radius: 4px;
}

.dmtt-msg.user .dmtt-msg-bubble {
  background: linear-gradient(135deg, #d32f2f 0%, #b71c1c 100%);
  color: #ffffff;
  border-bottom-right-radius: 4px;
}

.dmtt-typing-indicator {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 10px 14px;
  background: var(--bg-secondary);
  border-radius: 14px;
  width: fit-content;
}

.dmtt-typing-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--text-muted);
  animation: typingBounce 1.4s infinite ease-in-out;
}

.dmtt-typing-dot:nth-child(1) { animation-delay: -0.32s; }
.dmtt-typing-dot:nth-child(2) { animation-delay: -0.16s; }

@keyframes typingBounce {
  0%, 80%, 100% { transform: scale(0); }
  40% { transform: scale(1); }
}

.dmtt-chat-footer {
  padding: 12px 14px;
  background: var(--bg-surface);
  border-top: 1px solid var(--border-color);
}

.dmtt-input-form {
  display: flex;
  gap: 8px;
  align-items: flex-end;
}

.dmtt-input-field {
  flex: 1;
  padding: 10px 14px;
  border-radius: var(--radius-md);
  border: 1.5px solid var(--border-color);
  background: var(--bg-secondary);
  color: var(--text-main);
  font-size: 0.88rem;
  outline: none;
  resize: none;
  max-height: 80px;
}

.dmtt-input-field:focus {
  border-color: var(--brand-red);
}

.dmtt-send-btn {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  background: var(--brand-red);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.dmtt-footer-note {
  font-size: 0.68rem;
  text-align: center;
  color: var(--text-muted);
  margin-top: 6px;
}

/* Toast System */
.dmtt-toast-container {
  position: fixed;
  top: 24px;
  right: 24px;
  z-index: 10000;
  display: flex;
  flex-direction: column;
  gap: 8px;
  pointer-events: none;
}

.dmtt-toast-item {
  background: rgba(15, 23, 42, 0.92);
  backdrop-filter: blur(8px);
  color: #fff;
  padding: 12px 20px;
  border-radius: var(--radius-full);
  font-size: 0.85rem;
  font-weight: 600;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
  opacity: 0;
  transform: translateY(-10px);
  transition: var(--transition);
}

.dmtt-toast-item.show {
  opacity: 1;
  transform: translateY(0);
}

/* Footer Section */
.main-footer {
  background: #090d16;
  color: #e2e8f0;
  padding: 60px 0 30px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 36px;
  margin-bottom: 40px;
}

.footer-brand-title {
  font-size: 1.4rem;
  font-weight: 900;
  color: #ef4444;
  margin-bottom: 12px;
}

.footer-col h4 {
  font-size: 1rem;
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 16px;
}

.footer-links {
  list-style: none;
}

.footer-links li {
  margin-bottom: 10px;
  font-size: 0.88rem;
  color: #94a3b8;
}

.footer-links a:hover {
  color: #ffffff;
}

.footer-bottom-row {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 0.82rem;
  color: #64748b;
}

/* ==========================================================================
   RESPONSIVE DESIGN (MOBILE & TABLET)
   ========================================================================== */
@media (max-width: 992px) {
  .hero-grid,
  .installment-calculator-card,
  .contact-grid {
    grid-template-columns: 1fr;
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  .hero-title {
    font-size: 2rem;
  }
  .header-search-box {
    display: none;
  }
  .panorama-container {
    height: 380px;
  }
  .modal-product-layout {
    grid-template-columns: 1fr;
  }
  .footer-grid {
    grid-template-columns: 1fr;
  }
  .dmtt-chat-window {
    bottom: 0;
    right: 0;
    width: 100vw;
    max-width: 100vw;
    height: 100vh;
    max-height: 100vh;
    border-radius: 0;
    border: none;
  }
  .dmtt-fab-launcher {
    bottom: 16px;
    right: 16px;
    padding: 10px 14px;
  }
}
