/* ========================================
   Ristir — Mobile-First Responsive CSS
   ======================================== */

/* === RESET & BASE === */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box
}

:root {
  --bg: #0a0e1a;
  --surface: #111827;
  --card: #1a2236;
  --card-hover: #1f2a42;
  --accent: #00d4ff;
  --accent2: #7c3aed;
  --gradient: linear-gradient(135deg, #00d4ff, #7c3aed);
  --text: #f1f5f9;
  --text2: #94a3b8;
  --text3: #64748b;
  --success: #10b981;
  --warning: #f59e0b;
  --danger: #ef4444;
  --glass: rgba(255, 255, 255, 0.05);
  --border: rgba(255, 255, 255, 0.08);
  --radius: 16px;
  --radius-sm: 10px;
  --radius-lg: 24px;
  --shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  --header-h: 60px;
  --bnav-h: 64px;
  --max-w: 1280px;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%
}

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
  overflow-x: hidden;
  min-height: 100vh
}

a {
  color: inherit;
  text-decoration: none
}

img {
  max-width: 100%;
  height: auto;
  display: block
}

button {
  cursor: pointer;
  font-family: inherit
}

input,
textarea,
select {
  font-family: inherit
}

/* === MOBILE HEADER (< 768px) === */
.mobile-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 900;
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  background: rgba(10, 14, 26, 0.92);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border)
}

.header-left {
  display: flex;
  align-items: center;
  gap: 12px
}

.logo {
  display: flex;
  align-items: center;
  gap: 8px
}

.logo-img {
  height: 32px;
  width: auto;
  border-radius: 6px
}

.header-right {
  display: flex;
  align-items: center;
  gap: 4px
}

.header-icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: transparent;
  border: none;
  color: var(--text2);
  font-size: 17px;
  transition: all .3s;
  position: relative
}

.header-icon:hover,
.header-icon.active {
  color: var(--accent);
  background: rgba(0, 212, 255, 0.08)
}

.cart-badge,
.bnav-badge {
  position: absolute;
  top: 4px;
  right: 2px;
  min-width: 17px;
  height: 17px;
  background: var(--danger);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px
}

.bnav-badge {
  top: -4px;
  right: 12px
}

/* Hamburger */
.menu-toggle {
  width: 36px;
  height: 36px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  background: none;
  border: none;
  padding: 0
}

.menu-toggle span {
  width: 20px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: all .3s
}

.menu-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px)
}

.menu-toggle.active span:nth-child(2) {
  opacity: 0
}

.menu-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px)
}

/* === DESKTOP HEADER (≥ 768px) — hidden on mobile === */
.desktop-header {
  display: none
}

/* === SEARCH OVERLAY === */
.search-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 950;
  background: rgba(10, 14, 26, 0.95);
  backdrop-filter: blur(20px);
  display: flex;
  flex-direction: column;
  padding: 16px;
  transform: translateY(-100%);
  opacity: 0;
  transition: all .3s ease;
  pointer-events: none
}

.search-overlay.active {
  transform: translateY(0);
  opacity: 1;
  pointer-events: all
}

.search-form {
  display: flex;
  align-items: center;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 0 16px;
  margin-bottom: 16px
}

.search-form i {
  color: var(--text2);
  font-size: 16px;
  margin-right: 12px
}

.search-form input {
  flex: 1;
  padding: 16px 0;
  background: transparent;
  border: none;
  color: var(--text);
  font-size: 16px;
  outline: none
}

.search-close {
  background: none;
  border: none;
  color: var(--text2);
  font-size: 18px;
  padding: 8px
}

.search-results {
  flex: 1;
  overflow-y: auto
}

.search-result-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border-radius: 12px;
  transition: background .2s;
  cursor: pointer
}

.search-result-item:hover {
  background: var(--card)
}

.search-result-item img {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  object-fit: cover;
  background: var(--card)
}

.search-result-info h4 {
  font-size: 14px;
  font-weight: 600
}

.search-result-info p {
  font-size: 13px;
  color: var(--accent);
  font-weight: 600
}

/* === SIDEBAR === */
.sidebar-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 910;
  opacity: 0;
  pointer-events: none;
  transition: opacity .3s
}

.sidebar-overlay.active {
  opacity: 1;
  pointer-events: all
}

.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: 280px;
  max-width: 85vw;
  background: var(--surface);
  z-index: 920;
  transform: translateX(-100%);
  transition: transform .3s ease;
  overflow-y: auto;
  border-right: 1px solid var(--border)
}

.sidebar.active {
  transform: translateX(0)
}

.sidebar-header {
  padding: 24px 20px;
  border-bottom: 1px solid var(--border);
  background: var(--card)
}

.sidebar-user {
  display: flex;
  align-items: center;
  gap: 12px
}

.sidebar-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  flex-shrink: 0
}

.sidebar-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover
}

.sidebar-avatar span {
  font-size: 18px;
  font-weight: 700;
  color: #fff
}

.sidebar-name {
  font-size: 14px;
  font-weight: 600
}

.sidebar-email {
  font-size: 12px;
  color: var(--text2)
}

.sidebar-login-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 20px;
  background: var(--gradient);
  border-radius: 12px;
  color: #fff;
  font-weight: 600;
  font-size: 14px
}

.sidebar-menu {
  padding: 12px 0
}

.sidebar-link {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 20px;
  font-size: 14px;
  color: var(--text2);
  transition: all .2s;
  font-weight: 500
}

.sidebar-link:hover,
.sidebar-link.active {
  color: var(--accent);
  background: rgba(0, 212, 255, 0.05)
}

.sidebar-link i {
  width: 20px;
  text-align: center;
  font-size: 16px
}

.sidebar-badge {
  margin-left: auto;
  background: var(--accent);
  color: #000;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 10px
}

.sidebar-divider {
  height: 1px;
  background: var(--border);
  margin: 8px 20px
}

.sidebar-link.logout {
  color: var(--danger)
}

/* === MAIN CONTENT === */
.main-content {
  padding-top: var(--header-h);
  padding-bottom: calc(var(--bnav-h) + 16px);
  min-height: 100vh;
  max-width: var(--max-w);
  margin: 0 auto;
}

/* === FLASH MESSAGES === */
.flash-message {
  position: fixed;
  top: calc(var(--header-h) + 8px);
  left: 16px;
  right: 16px;
  z-index: 800;
  padding: 14px 16px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  font-weight: 500;
  animation: slideDown .4s ease;
  max-width: 600px;
  margin: 0 auto
}

.flash-success {
  background: rgba(16, 185, 129, 0.15);
  color: var(--success);
  border: 1px solid rgba(16, 185, 129, 0.2)
}

.flash-error {
  background: rgba(239, 68, 68, 0.15);
  color: var(--danger);
  border: 1px solid rgba(239, 68, 68, 0.2)
}

.flash-message button {
  margin-left: auto;
  background: none;
  border: none;
  color: inherit;
  font-size: 16px
}

@keyframes slideDown {
  from {
    transform: translateY(-20px);
    opacity: 0
  }

  to {
    transform: translateY(0);
    opacity: 1
  }
}

/* === HERO BANNER === */
.hero-section {
  margin: 16px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  position: relative;
  height: 190px;
  background: linear-gradient(135deg, #0f172a 0%, #1e1b4b 100%)
}

.hero-content {
  position: absolute;
  inset: 0;
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  z-index: 2
}

.hero-tag {
  font-size: 11px;
  font-weight: 700;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: 8px
}

.hero-title {
  font-size: 22px;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 6px
}

.hero-sub {
  font-size: 13px;
  color: var(--text2);
  margin-bottom: 14px
}

.hero-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  background: var(--gradient);
  border: none;
  border-radius: 25px;
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  width: fit-content;
  transition: transform .2s, box-shadow .2s
}

.hero-btn:hover {
  transform: scale(1.05);
  box-shadow: 0 8px 30px rgba(0, 212, 255, 0.3)
}

.hero-glow {
  position: absolute;
  right: -40px;
  top: -40px;
  width: 220px;
  height: 220px;
  background: radial-gradient(circle, rgba(0, 212, 255, 0.12), transparent 70%);
  z-index: 1
}

.hero-dots {
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
  z-index: 3
}

.hero-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--text2);
  opacity: .3;
  cursor: pointer;
  transition: .3s
}

.hero-dot.active {
  opacity: 1;
  background: var(--accent);
  width: 24px;
  border-radius: 4px
}

/* === CATEGORY PILLS === */
.categories-scroll {
  display: flex;
  gap: 10px;
  padding: 0 16px 16px;
  overflow-x: auto;
  scrollbar-width: none
}

.categories-scroll::-webkit-scrollbar {
  display: none
}

.cat-pill {
  flex-shrink: 0;
  padding: 10px 18px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text2);
  cursor: pointer;
  transition: all .3s;
  white-space: nowrap
}

.cat-pill:hover {
  border-color: var(--accent);
  color: var(--accent)
}

.cat-pill.active {
  background: var(--gradient);
  color: #fff;
  border-color: transparent
}

/* === SECTION === */
.section {
  margin-bottom: 24px
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 16px;
  margin-bottom: 14px
}

.section-header h2 {
  font-size: 18px;
  font-weight: 700
}

.section-header a {
  font-size: 13px;
  color: var(--accent);
  font-weight: 500
}

/* === PRODUCT GRID === */
.product-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  padding: 0 16px
}

.product-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: all .3s;
  position: relative;
  display: flex;
  flex-direction: column;
}

.product-card:hover {
  transform: translateY(-4px);
  border-color: rgba(0, 212, 255, 0.2);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.3)
}

.product-card a {
  display: block
}

.product-img {
  aspect-ratio: 1/1;
  background: linear-gradient(135deg, #1a2236, #0f172a);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden
}

.product-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .4s
}

.product-card:hover .product-img img {
  transform: scale(1.05)
}

.product-img .placeholder-icon {
  font-size: 48px
}

.product-heart {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 32px;
  height: 32px;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(8px);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  color: var(--text2);
  cursor: pointer;
  border: none;
  transition: all .3s;
  z-index: 5
}

.product-heart:hover,
.product-heart.liked {
  color: var(--danger)
}

.product-discount-tag {
  position: absolute;
  top: 8px;
  left: 8px;
  padding: 4px 8px;
  background: var(--danger);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  border-radius: 6px
}

.product-info {
  padding: 12px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.product-name {
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 4px;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden
}

.product-rating {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-bottom: 6px
}

.product-rating i {
  font-size: 10px;
  color: var(--warning)
}

.product-rating span {
  font-size: 11px;
  color: var(--text2)
}

.product-prices {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.price-current {
  font-size: 17px;
  font-weight: 700;
  color: var(--accent)
}

.price-original {
  font-size: 12px;
  color: var(--text3);
  text-decoration: line-through
}

.add-cart-btn {
  width: 100%;
  padding: 10px;
  background: var(--glass);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--accent);
  font-size: 12px;
  font-weight: 600;
  margin-top: auto;
  transition: all .3s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px
}

.add-cart-btn:hover {
  background: var(--accent);
  color: #000;
  border-color: var(--accent)
}

/* === BOTTOM NAV === */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 800;
  height: var(--bnav-h);
  background: rgba(17, 24, 39, 0.95);
  backdrop-filter: blur(20px);
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-around;
  align-items: center;
  padding: 0 8px
}

.bnav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  font-size: 10px;
  color: var(--text3);
  padding: 8px 12px;
  border-radius: 12px;
  transition: all .3s;
  position: relative
}

.bnav-item i {
  font-size: 18px;
  transition: all .3s
}

.bnav-item.active {
  color: var(--accent)
}

.bnav-item.active i {
  transform: translateY(-2px)
}

/* === AUTH PAGES === */
.auth-page {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 40px 24px;
  text-align: center
}

.auth-logo-icon {
  font-size: 48px;
  margin-bottom: 12px
}

.auth-title {
  font-size: 28px;
  font-weight: 800;
  margin-bottom: 4px
}

.auth-title span {
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent
}

.auth-sub {
  color: var(--text2);
  font-size: 14px;
  margin-bottom: 32px
}

.auth-form {
  width: 100%;
  max-width: 400px
}

.input-group {
  position: relative;
  margin-bottom: 14px
}

.input-group i.input-icon {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text2);
  font-size: 14px
}

.input-group input,
.input-group textarea,
.input-group select {
  width: 100%;
  padding: 16px 16px 16px 44px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  color: var(--text);
  font-size: 14px;
  outline: none;
  transition: border .3s
}

.input-group input:focus,
.input-group textarea:focus,
.input-group select:focus {
  border-color: var(--accent)
}

.input-group .toggle-password {
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: var(--text2);
  font-size: 14px
}

.forgot-link {
  text-align: right;
  font-size: 12px;
  color: var(--accent);
  margin: -6px 0 20px;
  cursor: pointer;
  display: block
}

.auth-btn {
  width: 100%;
  padding: 16px;
  background: var(--gradient);
  border: none;
  border-radius: 14px;
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  transition: opacity .3s, transform .2s
}

.auth-btn:hover {
  opacity: .9;
  transform: translateY(-1px)
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 24px 0;
  color: var(--text3);
  font-size: 12px
}

.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border)
}

.social-btn {
  width: 100%;
  padding: 14px;
  border-radius: 14px;
  font-size: 14px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 10px;
  transition: all .3s
}

.google-btn {
  background: #fff;
  color: #333;
  border: none
}

.google-btn:hover {
  background: #f0f0f0
}

.email-btn {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border)
}

.email-btn:hover {
  border-color: var(--accent)
}

.auth-switch {
  margin-top: 24px;
  font-size: 13px;
  color: var(--text2)
}

.auth-switch a {
  color: var(--accent);
  font-weight: 600
}

/* === PRODUCT DETAIL PAGE === */
.detail-topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 16px
}

.detail-topbar button {
  width: 40px;
  height: 40px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 50%;
  color: var(--text);
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center
}

.detail-gallery {
  margin: 0 16px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 1/1;
  background: var(--card);
  position: relative
}

.gallery-slider {
  display: flex;
  width: 100%;
  height: 100%;
  transition: transform 0.3s ease;
}

.gallery-slide {
  min-width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.gallery-slide img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.gallery-slide video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000;
}

.detail-gallery .placeholder-icon {
  font-size: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%
}

.gallery-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin: 12px 0
}

.gallery-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--text2);
  opacity: .3;
  cursor: pointer;
  transition: .3s;
  border: none
}

.gallery-dot.active {
  opacity: 1;
  background: var(--accent);
  width: 24px;
  border-radius: 4px
}

.detail-info {
  padding: 20px 16px
}

.detail-name {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 8px;
  line-height: 1.3
}

.detail-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
  flex-wrap: wrap
}

.detail-rating {
  display: flex;
  align-items: center;
  gap: 4px
}

.detail-rating i {
  color: var(--warning);
  font-size: 14px
}

.detail-rating span {
  color: var(--text2);
  font-size: 13px;
  margin-left: 4px
}

.detail-pricing {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
  flex-wrap: wrap
}

.detail-price {
  font-size: 28px;
  font-weight: 800;
  color: var(--accent)
}

.detail-original {
  font-size: 16px;
  color: var(--text3);
  text-decoration: line-through
}

.detail-discount {
  padding: 4px 10px;
  background: rgba(239, 68, 68, 0.12);
  color: var(--danger);
  border-radius: 6px;
  font-size: 12px;
  font-weight: 700
}

.stock-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 16px
}

.stock-badge.in-stock {
  background: rgba(16, 185, 129, 0.1);
  color: var(--success)
}

.stock-badge.out-of-stock {
  background: rgba(239, 68, 68, 0.1);
  color: var(--danger)
}

.detail-desc {
  color: var(--text2);
  font-size: 14px;
  line-height: 1.7;
  margin-bottom: 20px
}

.qty-row {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px
}

.qty-label {
  font-size: 14px;
  font-weight: 600
}

.qty-control {
  display: flex;
  align-items: center;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden
}

.qty-control button {
  width: 40px;
  height: 40px;
  border: none;
  background: var(--card);
  color: var(--text);
  font-size: 16px;
  transition: background .2s
}

.qty-control button:hover {
  background: var(--card-hover)
}

.qty-control span {
  width: 48px;
  text-align: center;
  font-weight: 600;
  font-size: 15px
}

.detail-actions {
  display: flex;
  gap: 10px;
  padding: 0 16px 24px
}

.btn-outline {
  flex: 1;
  padding: 14px;
  border: 1px solid var(--accent);
  border-radius: 14px;
  background: transparent;
  color: var(--accent);
  font-size: 14px;
  font-weight: 600;
  transition: all .3s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px
}

.btn-outline:hover {
  background: rgba(0, 212, 255, 0.08)
}

.btn-primary {
  flex: 1;
  padding: 14px;
  border: none;
  border-radius: 14px;
  background: var(--gradient);
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  transition: all .3s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px
}

.btn-primary:hover {
  opacity: .9;
  transform: translateY(-1px)
}

/* === CART PAGE === */
.page-header {
  padding: 20px 16px 12px;
  display: flex;
  align-items: center;
  gap: 12px
}

.page-header h1 {
  font-size: 22px;
  font-weight: 700
}

.page-header .count {
  color: var(--text2);
  font-size: 14px
}

.cart-list {
  padding: 0 16px;
  display: flex;
  flex-direction: column;
  gap: 12px
}

.cart-item {
  display: flex;
  gap: 12px;
  padding: 14px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  position: relative
}

.cart-item-img {
  width: 80px;
  height: 80px;
  border-radius: 12px;
  overflow: hidden;
  flex-shrink: 0;
  background: var(--surface)
}

.cart-item-img img {
  width: 100%;
  height: 100%;
  object-fit: cover
}

.cart-item-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between
}

.cart-item-name {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.3;
  margin-bottom: 4px
}

.cart-item-price {
  font-size: 16px;
  font-weight: 700;
  color: var(--accent)
}

.cart-item-controls {
  display: flex;
  align-items: center;
  justify-content: space-between
}

.cart-item-remove {
  background: none;
  border: none;
  color: var(--danger);
  font-size: 13px;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 4px
}

.cart-summary {
  margin: 20px 16px;
  padding: 20px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius)
}

.cart-summary-row {
  display: flex;
  justify-content: space-between;
  padding: 8px 0;
  font-size: 14px;
  color: var(--text2)
}

.cart-summary-row.total {
  font-size: 18px;
  font-weight: 700;
  color: var(--text);
  border-top: 1px solid var(--border);
  padding-top: 14px;
  margin-top: 4px
}

.cart-checkout-btn {
  margin: 16px;
  padding: 16px;
  background: var(--gradient);
  border: none;
  border-radius: 14px;
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  width: calc(100% - 32px);
  transition: all .3s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px
}

.cart-checkout-btn:hover {
  opacity: .9
}

.empty-state {
  text-align: center;
  padding: 60px 24px
}

.empty-state i {
  font-size: 64px;
  color: var(--text3);
  margin-bottom: 16px
}

.empty-state h3 {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 8px
}

.empty-state p {
  color: var(--text2);
  font-size: 14px;
  margin-bottom: 20px
}

.empty-state .btn-primary {
  display: inline-flex;
  padding: 12px 28px;
  border-radius: 12px
}

/* === CHECKOUT PAGE === */
.checkout-form {
  padding: 0 16px
}

.form-section {
  margin-bottom: 24px
}

.form-section h3 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 8px
}

.form-section h3 i {
  color: var(--accent)
}

.form-row {
  display: flex;
  gap: 12px
}

.form-row .input-group {
  flex: 1
}

.order-summary-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 20px
}

.summary-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid var(--border)
}

.summary-item:last-child {
  border-bottom: none
}

.summary-item-name {
  font-size: 13px;
  font-weight: 500
}

.summary-item-qty {
  font-size: 12px;
  color: var(--text2)
}

.summary-item-price {
  font-size: 14px;
  font-weight: 600;
  color: var(--accent)
}

.cod-badge {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px;
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.15);
  border-radius: 12px;
  margin-bottom: 16px;
  font-size: 13px;
  color: var(--success)
}

/* === LANDING PAGE (FB AD) === */
.landing-page {
  background: radial-gradient(circle at top, #111827 0%, #030712 100%);
  color: #f3f4f6;
}

.landing-hero {
  padding: 40px 20px 20px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

/* Add a subtle background glow behind the hero */
.landing-hero::before {
  content: '';
  position: absolute;
  top: -100px;
  left: 50%;
  transform: translateX(-50%);
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, rgba(0, 212, 255, 0.15) 0%, transparent 70%);
  z-index: 0;
}

.limited-tag {
  display: inline-block;
  padding: 8px 24px;
  background: linear-gradient(90deg, rgba(239, 68, 68, 0.15), rgba(239, 68, 68, 0.05));
  color: #fca5a5;
  border: 1px solid rgba(239, 68, 68, 0.3);
  border-radius: 30px;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: 24px;
  position: relative;
  z-index: 1;
  box-shadow: 0 0 20px rgba(239, 68, 68, 0.2);
  animation: pulse-glow 2s infinite;
}

@keyframes pulse-glow {

  0%,
  100% {
    box-shadow: 0 0 15px rgba(239, 68, 68, 0.2);
  }

  50% {
    box-shadow: 0 0 30px rgba(239, 68, 68, 0.5);
  }
}

.landing-img {
  aspect-ratio: 1/1;
  max-width: 340px;
  margin: 0 auto 32px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.05) 0%, rgba(255, 255, 255, 0.01) 100%);
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.1);
  overflow: hidden;
  position: relative;
  z-index: 1;
  animation: float 6s ease-in-out infinite;
}

@keyframes float {
  0% {
    transform: translateY(0px);
  }

  50% {
    transform: translateY(-12px);
  }

  100% {
    transform: translateY(0px);
  }
}

.landing-img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 20px;
  transform: scale(1.05);
  /* Make product pop slightly */
}

.landing-headline {
  font-size: 28px;
  font-weight: 900;
  line-height: 1.25;
  margin-bottom: 12px;
  position: relative;
  z-index: 1;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.landing-headline span {
  background: linear-gradient(90deg, #00d4ff, #7c3aed);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.landing-sub {
  color: #9ca3af;
  font-size: 16px;
  line-height: 1.6;
  max-width: 500px;
  margin: 0 auto 32px;
  position: relative;
  z-index: 1;
}

.countdown {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-bottom: 40px;
  position: relative;
  z-index: 1;
}

.countdown-item {
  background: rgba(17, 24, 39, 0.7);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  padding: 14px 0;
  text-align: center;
  min-width: 72px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.countdown-num {
  font-size: 26px;
  font-weight: 900;
  color: #00d4ff;
  text-shadow: 0 0 15px rgba(0, 212, 255, 0.4);
}

.countdown-label {
  font-size: 10px;
  color: #9ca3af;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin-top: 4px;
  font-weight: 600;
}

.benefits-row {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-bottom: 40px;
  padding: 0 20px;
  flex-wrap: wrap;
}

.benefit {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  width: 80px;
  /* Consistent width */
}

.benefit-icon {
  width: 60px;
  height: 60px;
  background: linear-gradient(135deg, rgba(124, 58, 237, 0.15) 0%, rgba(0, 212, 255, 0.15) 100%);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  color: #e5e7eb;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease;
}

.benefit:hover .benefit-icon {
  transform: translateY(-5px);
  border-color: rgba(255, 255, 255, 0.2);
}

.benefit span {
  font-size: 12px;
  color: #d1d5db;
  font-weight: 600;
  text-align: center;
  line-height: 1.3;
}

.social-proof-card {
  background: rgba(17, 24, 39, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 20px;
  padding: 24px;
  margin: 0 20px 40px;
  text-align: center;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
}

.proof-avatars {
  display: flex;
  justify-content: center;
  margin-bottom: 12px;
}

.proof-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 3px solid #111827;
  margin-left: -12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 800;
  color: #fff;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

.proof-avatar:first-child {
  margin-left: 0;
}

.proof-count {
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 8px;
  color: #f3f4f6;
}

.proof-count span {
  color: #00d4ff;
  text-shadow: 0 0 10px rgba(0, 212, 255, 0.3);
}

.proof-stars {
  color: #fbbf24;
  font-size: 18px;
  margin-bottom: 10px;
  text-shadow: 0 0 10px rgba(251, 191, 36, 0.4);
}

.proof-review {
  font-size: 14px;
  color: #d1d5db;
  font-style: italic;
  line-height: 1.6;
}

.landing-sticky {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 800;
  padding: 16px 20px 24px;
  background: rgba(3, 7, 18, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.5);
}

.landing-price-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.landing-price {
  font-size: 28px;
  font-weight: 900;
  color: #00d4ff;
  text-shadow: 0 0 15px rgba(0, 212, 255, 0.5);
}

.landing-old-price {
  font-size: 16px;
  color: #6b7280;
  text-decoration: line-through;
  font-weight: 600;
}

.order-now-btn {
  width: 100%;
  max-width: 600px;
  margin: 0 auto;
  display: flex;
  padding: 18px;
  background: linear-gradient(90deg, #00d4ff, #7c3aed);
  border: none;
  border-radius: 16px;
  color: #fff;
  font-size: 18px;
  font-weight: 800;
  align-items: center;
  justify-content: center;
  gap: 10px;
  animation: glow-btn 2.5s infinite;
  text-transform: uppercase;
  letter-spacing: 1px;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

@keyframes glow-btn {

  0%,
  100% {
    box-shadow: 0 0 20px rgba(0, 212, 255, 0.4), inset 0 2px 0 rgba(255, 255, 255, 0.2);
    transform: scale(1);
  }

  50% {
    box-shadow: 0 0 40px rgba(124, 58, 237, 0.6), inset 0 2px 0 rgba(255, 255, 255, 0.2);
    transform: scale(1.02);
  }
}

.cod-text {
  text-align: center;
  font-size: 12px;
  color: #9ca3af;
  margin-top: 12px;
  font-weight: 600;
}

/* === ORDERS PAGE === */
.order-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  margin: 0 16px 12px
}

.order-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px
}

.order-number {
  font-size: 14px;
  font-weight: 700
}

.order-date {
  font-size: 12px;
  color: var(--text2)
}

.order-status {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 600
}

.status-pending {
  background: rgba(245, 158, 11, 0.12);
  color: var(--warning)
}

.status-confirmed {
  background: rgba(0, 212, 255, 0.12);
  color: var(--accent)
}

.status-shipped {
  background: rgba(124, 58, 237, 0.12);
  color: var(--accent2)
}

.status-delivered {
  background: rgba(16, 185, 129, 0.12);
  color: var(--success)
}

.status-cancelled {
  background: rgba(239, 68, 68, 0.12);
  color: var(--danger)
}

.order-items-list {
  border-top: 1px solid var(--border);
  padding-top: 10px
}

.order-item-row {
  display: flex;
  justify-content: space-between;
  padding: 6px 0;
  font-size: 13px
}

.order-total-row {
  display: flex;
  justify-content: space-between;
  border-top: 1px solid var(--border);
  padding-top: 10px;
  margin-top: 6px;
  font-weight: 700;
  font-size: 15px
}

.order-total-row span:last-child {
  color: var(--accent)
}

/* === UTILITIES === */
.text-center {
  text-align: center
}

.text-accent {
  color: var(--accent)
}

.mt-1 {
  margin-top: 8px
}

.mt-2 {
  margin-top: 16px
}

.mt-3 {
  margin-top: 24px
}

.mb-1 {
  margin-bottom: 8px
}

.mb-2 {
  margin-bottom: 16px
}

.mb-3 {
  margin-bottom: 24px
}

.px {
  padding-left: 16px;
  padding-right: 16px
}

/* ====================================
   RESPONSIVE — TABLET (≥ 600px)
   ==================================== */
@media(min-width:600px) {
  .hero-section {
    height: 220px;
    margin: 20px
  }

  .hero-title {
    font-size: 28px
  }

  .product-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    padding: 0 20px
  }

  .section-header,
  .categories-scroll {
    padding-left: 20px;
    padding-right: 20px
  }

  .categories-scroll {
    gap: 12px
  }

  .auth-page {
    padding: 60px 32px
  }

  .detail-gallery {
    max-width: 500px;
    margin: 0 auto;
    max-height: 500px
  }

  .detail-actions {
    padding: 0 20px 24px
  }

  .cart-list {
    padding: 0 20px
  }

  .cart-summary {
    margin: 20px
  }

  .flash-message {
    left: 20px;
    right: 20px
  }

  .landing-img {
    max-height: 340px
  }

  .benefits-row {
    gap: 24px
  }
}

/* ====================================
   RESPONSIVE — TABLET NAV (≥ 768px)
   ==================================== */
@media(min-width:768px) {

  /* Hide mobile header, show desktop header */
  .mobile-header {
    display: none !important
  }

  .desktop-header {
    display: block;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 900;
    background: rgba(10, 14, 26, 0.95);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border)
  }

  .desktop-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    height: 64px;
    max-width: var(--max-w);
    margin: 0 auto
  }

  :root {
    --header-h: 64px
  }

  /* Desktop Logo */
  .desktop-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0
  }

  .desktop-logo-img {
    height: 36px;
    width: auto;
    border-radius: 6px
  }

  .desktop-logo-text {
    font-size: 22px;
    font-weight: 800;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent
  }

  /* Desktop Nav Links */
  .desktop-nav {
    display: flex;
    align-items: center;
    gap: 4px
  }

  .desktop-nav-link {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 500;
    color: var(--text2);
    transition: all .3s;
    position: relative;
    white-space: nowrap
  }

  .desktop-nav-link:hover {
    color: var(--accent);
    background: rgba(0, 212, 255, 0.06)
  }

  .desktop-nav-link.active {
    color: var(--accent);
    background: rgba(0, 212, 255, 0.1)
  }

  .desktop-nav-link i {
    font-size: 14px
  }

  .desktop-cart-badge {
    position: absolute;
    top: 2px;
    right: 4px;
    min-width: 16px;
    height: 16px;
    background: var(--danger);
    color: #fff;
    font-size: 9px;
    font-weight: 700;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px
  }

  /* Desktop Header Actions */
  .desktop-header-actions {
    display: flex;
    align-items: center;
    gap: 12px
  }

  /* Desktop Search */
  .desktop-search {
    position: relative
  }

  .desktop-search-form {
    display: flex;
    align-items: center;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 0 12px;
    width: 200px;
    transition: width .3s
  }

  .desktop-search-form:focus-within {
    width: 280px;
    border-color: var(--accent)
  }

  .desktop-search-form i {
    color: var(--text2);
    font-size: 13px;
    margin-right: 8px
  }

  .desktop-search-form input {
    flex: 1;
    padding: 9px 0;
    background: transparent;
    border: none;
    color: var(--text);
    font-size: 13px;
    outline: none
  }

  .desktop-search-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin-top: 8px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    max-height: 300px;
    overflow-y: auto;
    display: none;
    z-index: 100;
    box-shadow: var(--shadow)
  }

  .desktop-search-results.active {
    display: block
  }

  /* Desktop User Menu */
  .desktop-user-menu {
    position: relative
  }

  .desktop-user-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 10px;
    color: var(--text);
    font-size: 13px;
    font-weight: 500;
    transition: all .3s;
    cursor: pointer
  }

  .desktop-user-btn:hover {
    border-color: var(--accent)
  }

  .desktop-user-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    object-fit: cover
  }

  .desktop-user-initial {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
    color: #fff
  }

  .desktop-user-name {
    max-width: 100px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap
  }

  .desktop-user-btn .fa-chevron-down {
    font-size: 10px;
    color: var(--text2);
    transition: transform .3s
  }

  .desktop-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 8px;
    width: 200px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 8px;
    display: none;
    z-index: 100;
    box-shadow: var(--shadow)
  }

  .desktop-dropdown.active {
    display: block
  }

  .desktop-dropdown a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 8px;
    font-size: 13px;
    color: var(--text2);
    transition: all .2s
  }

  .desktop-dropdown a:hover {
    background: rgba(0, 212, 255, 0.06);
    color: var(--accent)
  }

  .desktop-dropdown a i {
    width: 16px;
    text-align: center;
    font-size: 13px
  }

  .dropdown-divider {
    height: 1px;
    background: var(--border);
    margin: 4px 0
  }

  .dropdown-logout {
    color: var(--danger) !important
  }

  .dropdown-logout:hover {
    background: rgba(239, 68, 68, 0.06) !important;
    color: var(--danger) !important
  }

  /* Desktop Login Button */
  .desktop-login-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 9px 18px;
    background: var(--gradient);
    border-radius: 10px;
    color: #fff;
    font-size: 13px;
    font-weight: 600;
    transition: opacity .3s
  }

  .desktop-login-btn:hover {
    opacity: .9
  }

  /* Hide hamburger, sidebar overlay, sidebar, bottom nav */
  .menu-toggle {
    display: none !important
  }

  .sidebar {
    display: none !important
  }

  .sidebar-overlay {
    display: none !important
  }

  .bottom-nav {
    display: none !important
  }

  .main-content {
    padding-bottom: 24px
  }

  .product-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    padding: 0 24px
  }

  .section-header,
  .categories-scroll {
    padding-left: 24px;
    padding-right: 24px
  }

  .hero-section {
    margin: 20px 24px;
    height: 240px
  }
}

/* ====================================
   RESPONSIVE — DESKTOP (≥ 1024px)
   ==================================== */
@media(min-width:1024px) {
  :root {
    --header-h: 68px
  }

  .desktop-header-inner {
    padding: 0 40px;
    height: 68px
  }

  .desktop-search-form {
    width: 260px
  }

  .desktop-search-form:focus-within {
    width: 360px
  }

  .product-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    padding: 0 40px;
    max-width: var(--max-w);
    margin: 0 auto
  }

  .section-header,
  .categories-scroll {
    padding-left: 40px;
    padding-right: 40px;
    max-width: var(--max-w);
    margin-left: auto;
    margin-right: auto
  }

  .hero-section {
    margin: 24px 40px;
    height: 280px;
    max-width: calc(var(--max-w) - 80px);
    margin-left: auto;
    margin-right: auto
  }

  .hero-title {
    font-size: 32px
  }

  .hero-sub {
    font-size: 15px
  }

  /* Detail page side-by-side */
  .detail-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px;
    padding: 24px 40px;
    max-width: var(--max-w);
    margin: 0 auto
  }

  /* Cart wider */
  .cart-list {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 40px
  }

  .cart-summary {
    max-width: 800px;
    margin: 20px auto
  }

  .cart-checkout-btn {
    max-width: 800px;
    margin: 16px auto;
    width: 100%
  }

  /* Auth centered wider */
  .auth-form {
    max-width: 440px
  }

  /* Landing page */
  .landing-hero {
    max-width: 700px;
    margin: 0 auto
  }

  .landing-headline {
    font-size: 32px
  }

  /* Orders */
  .order-card {
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 16px
  }

  .page-header {
    padding: 24px 40px;
    max-width: var(--max-w);
    margin: 0 auto
  }
}

/* ====================================
   RESPONSIVE — LARGE DESKTOP (≥ 1280px)
   ==================================== */
@media(min-width:1280px) {
  .product-grid {
    grid-template-columns: repeat(5, 1fr)
  }

  .hero-section {
    height: 320px
  }

  .desktop-nav-link {
    padding: 8px 18px;
    font-size: 14px
  }
}

/* === GLOBAL MODAL === */
.global-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 14, 26, 0.8);
  backdrop-filter: blur(8px);
  z-index: 2000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.global-modal-overlay.active {
  display: flex;
  opacity: 1;
}

.global-modal-content {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 20px;
  width: 100%;
  max-width: 420px;
  padding: 32px 24px;
  position: relative;
  transform: translateY(20px);
  transition: transform 0.3s ease;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.global-modal-overlay.active .global-modal-content {
  transform: translateY(0);
}

.global-modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text2);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 14px;
  transition: all 0.3s ease;
}

.global-modal-close:hover {
  background: var(--danger);
  color: #fff;
  border-color: var(--danger);
}

/* Modal form inputs reuse existing auth-form styles from login.php or define here */
.modal-auth-form .input-group {
  position: relative;
  margin-bottom: 16px;
}

.modal-auth-form .input-icon {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text2);
}

.modal-auth-form input {
  width: 100%;
  padding: 14px 16px 14px 44px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  color: var(--text);
  outline: none;
  font-size: 14px;
  transition: border 0.3s;
}

.modal-auth-form input:focus {
  border-color: var(--accent);
}

.modal-auth-form .auth-btn {
  width: 100%;
  padding: 14px;
  background: var(--gradient);
  border: none;
  border-radius: 12px;
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.3s;
}

.modal-auth-form .auth-btn:hover {
  opacity: 0.9;
}

.modal-auth-title {
  font-size: 24px;
  font-weight: 800;
  text-align: center;
  margin-bottom: 4px;
}

.modal-auth-title span {
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.modal-auth-sub {
  color: var(--text2);
  text-align: center;
  font-size: 13px;
  margin-bottom: 24px;
}

.modal-auth-divider {
  text-align: center;
  position: relative;
  margin: 24px 0;
  color: var(--text2);
  font-size: 12px;
}

.modal-auth-divider::before,
.modal-auth-divider::after {
  content: '';
  position: absolute;
  top: 50%;
  width: 40%;
  height: 1px;
  background: var(--border);
}

.modal-auth-divider::before {
  left: 0;
}

.modal-auth-divider::after {
  right: 0;
}

.modal-social-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  padding: 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  color: var(--text);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: all 0.3s;
}

.modal-social-btn:hover {
  background: rgba(255, 255, 255, 0.05);
}

/* ========================================
   Checkout Payment Options
   ======================================== */
.payment-option {
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  margin-bottom: 12px;
  transition: all 0.2s ease;
  text-align: center;
}

.payment-option:hover {
  border-color: rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.02);
}

.payment-option input[type="radio"] {
  display: none;
  /* Hide standard radio button for a cleaner centered look */
}

/* Custom radio style for centered options */
.payment-option::before {
  content: '';
  display: inline-block;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid var(--text2);
  margin-right: 14px;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.payment-option:has(input[type="radio"]:checked)::before {
  border-color: var(--accent);
  background: radial-gradient(circle, var(--accent) 40%, transparent 45%);
}

.payment-option:has(input[type="radio"]:checked) {
  border-color: var(--accent);
  background: rgba(0, 212, 255, 0.05);
  /* Subtle highlight */
}

.payment-option-content {
  display: flex;
  align-items: center;
  gap: 14px;
  justify-content: center;
}

.payment-option-content div {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.payment-option-content strong {
  font-size: 15px;
  color: var(--text);
  margin-bottom: 2px;
}

.payment-option-content small {
  font-size: 13px;
  color: var(--text2);
}

.cart-checkout-btn {
  width: 100%;
  max-width: 400px;
  margin: 0 auto 24px;
  display: flex;
}