/* ==========================================================================
   SHIPNEXUS — Premium E-Commerce Mockup Store Design System
   ========================================================================== */

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

:root {
  --bg-dark: #07080d;
  --bg-surface: #0f111d;
  --bg-surface-elevated: #16192b;
  --bg-surface-glass: rgba(15, 17, 29, 0.75);
  
  --color-primary: #8b5cf6;       /* Vivid Violet */
  --color-primary-glow: rgba(139, 92, 246, 0.35);
  --color-secondary: #06b6d4;     /* Neon Cyan */
  --color-secondary-glow: rgba(6, 182, 212, 0.3);
  --color-accent: #f43f5e;        /* Rose Red Alert */
  --color-gold: #f59e0b;          /* Soft Gold Amber */
  
  --text-primary: #f8fafc;
  --text-secondary: #cbd5e1;
  --text-muted: #64748b;
  
  --border-light: rgba(255, 255, 255, 0.06);
  --border-glow: rgba(139, 92, 246, 0.25);
  
  --font-heading: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  
  --max-width: 1240px;
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 24px;
  --radius-pill: 9999px;
  
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 10px 25px rgba(0, 0, 0, 0.5);
  --shadow-lg: 0 20px 50px rgba(0, 0, 0, 0.7);
  --shadow-glow-violet: 0 0 25px var(--color-primary-glow);
  --shadow-glow-cyan: 0 0 25px var(--color-secondary-glow);
  
  --ease-smooth: cubic-bezier(0.25, 1, 0.5, 1);
  --ease-out-back: cubic-bezier(0.34, 1.56, 0.64, 1);
  --transition-fast: 0.2s var(--ease-smooth);
  --transition-normal: 0.35s var(--ease-smooth);
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  background-color: var(--bg-dark);
  color: var(--text-primary);
  font-family: var(--font-body);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  position: relative;
}

/* Background Light Blobs Canvas */
#ambient-glow-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 0;
  opacity: 0.65;
}

.site-wrapper {
  position: relative;
  z-index: 1;
}

.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* --- Typography --- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 800;
  letter-spacing: -0.01em;
}

.gradient-text-violet {
  background: linear-gradient(135deg, #ffffff 40%, var(--color-primary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.gradient-text-cyan {
  background: linear-gradient(135deg, var(--color-secondary) 0%, #38bdf8 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.badge-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.35rem 0.9rem;
  background: rgba(139, 92, 246, 0.1);
  border: 1px solid var(--border-glow);
  color: var(--color-primary);
  font-family: var(--font-heading);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  border-radius: var(--radius-pill);
  margin-bottom: 1rem;
}

/* --- Header / Glass Navbar --- */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 80px;
  z-index: 1000;
  transition: all 0.35s var(--ease-smooth);
}

.header.scrolled {
  height: 68px;
  background: rgba(7, 8, 13, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-light);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

.header .container {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-heading);
  font-weight: 900;
  font-size: 1.5rem;
  text-decoration: none;
  color: var(--text-primary);
}

.logo span {
  color: var(--color-secondary);
}

.logo-symbol {
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 900;
  font-size: 1.1rem;
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: 2rem;
}

.nav-link {
  color: var(--text-secondary);
  text-decoration: none;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.95rem;
  transition: var(--transition-fast);
}

.nav-link:hover {
  color: var(--color-primary);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.search-bar-container {
  position: relative;
  display: flex;
  align-items: center;
}

.search-input {
  width: 180px;
  padding: 0.45rem 1rem 0.45rem 2.2rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-pill);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 0.85rem;
  outline: none;
  transition: width 0.3s ease, border-color 0.3s;
}

.search-input:focus {
  width: 260px;
  border-color: var(--color-secondary);
  background: rgba(255, 255, 255, 0.08);
}

.search-icon {
  position: absolute;
  left: 0.8rem;
  color: var(--text-muted);
}

.cart-btn-trigger {
  background: none;
  border: none;
  color: var(--text-primary);
  cursor: pointer;
  position: relative;
  padding: 0.4rem;
  transition: transform 0.2s;
}

.cart-btn-trigger:hover {
  transform: scale(1.1);
}

.cart-badge-count {
  position: absolute;
  top: -2px;
  right: -2px;
  background: var(--color-accent);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 900;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 8px rgba(244, 63, 94, 0.6);
}

/* --- Hero Banner --- */
.hero {
  padding-top: 140px;
  padding-bottom: 4rem;
  min-height: 80vh;
  display: flex;
  align-items: center;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 3rem;
  align-items: center;
}

.hero-tagline {
  font-size: clamp(2.8rem, 5vw, 4.5rem);
  font-weight: 900;
  line-height: 1.1;
  margin-bottom: 1.5rem;
}

.hero-desc {
  font-size: 1.15rem;
  color: var(--text-secondary);
  margin-bottom: 2.25rem;
  max-width: 500px;
}

.hero-image-frame {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border-light);
}

.hero-image-frame::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 60%, rgba(7, 8, 13, 0.9) 100%);
}

.hero-img {
  width: 100%;
  height: auto;
  display: block;
}

/* --- Flash Sale Countdown Banner --- */
.countdown-section {
  padding: 2.5rem 0;
  background: linear-gradient(90deg, rgba(139, 92, 246, 0.08), rgba(6, 182, 212, 0.08));
  border-y: 1px solid var(--border-light);
  margin-bottom: 5rem;
}

.countdown-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 2rem;
}

.countdown-label {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.countdown-label h3 {
  font-size: 1.35rem;
  font-weight: 800;
}

.countdown-timer {
  display: flex;
  gap: 1rem;
}

.timer-box {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  width: 60px;
  height: 60px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-sm);
}

.timer-num {
  font-family: var(--font-heading);
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--color-secondary);
}

.timer-lbl {
  font-size: 0.65rem;
  color: var(--text-muted);
  text-transform: uppercase;
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  font-family: var(--font-heading);
  font-weight: 700;
  padding: 0.8rem 1.6rem;
  border-radius: var(--radius-md);
  border: none;
  cursor: pointer;
  transition: transform 0.25s var(--ease-out-back), box-shadow 0.25s var(--ease-smooth), background-color 0.2s;
  text-decoration: none;
  font-size: 0.95rem;
}

.btn-primary {
  background: linear-gradient(135deg, var(--color-primary) 0%, #7c3aed 100%);
  color: #fff;
  box-shadow: var(--shadow-glow-violet);
}

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 25px rgba(139, 92, 246, 0.6);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-primary);
  border: 1px solid var(--border-light);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
  transform: translateY(-2px);
}

/* --- Filter & Product Grid --- */
.filter-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 3rem;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.filter-tabs {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.filter-tab {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-light);
  color: var(--text-secondary);
  padding: 0.5rem 1.1rem;
  border-radius: var(--radius-pill);
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  transition: var(--transition-fast);
}

.filter-tab.active, .filter-tab:hover {
  background: var(--color-secondary);
  border-color: var(--color-secondary);
  color: var(--bg-dark);
  box-shadow: var(--shadow-glow-cyan);
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 2rem;
  margin-bottom: 6rem;
}

.product-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: transform 0.35s var(--ease-out-back), box-shadow 0.35s ease, border-color 0.3s;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.product-card:hover {
  transform: translateY(-8px);
  border-color: rgba(6, 182, 212, 0.3);
  box-shadow: var(--shadow-lg), var(--shadow-glow-cyan);
}

.product-img-frame {
  height: 260px;
  position: relative;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.01);
}

.product-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s var(--ease-smooth);
}

.product-card:hover .product-img {
  transform: scale(1.06);
}

.product-badge {
  position: absolute;
  top: 1rem;
  left: 1rem;
  background: var(--color-accent);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 800;
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-pill);
  text-transform: uppercase;
}

.product-info {
  padding: 1.5rem;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.product-title {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  line-height: 1.35;
}

.product-price-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.product-price {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--color-secondary);
}

.product-compare-price {
  text-decoration: line-through;
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* Variant Selector inside Card */
.variant-selector {
  display: flex;
  gap: 0.4rem;
  margin-bottom: 1.25rem;
}

.variant-dot {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 2px solid transparent;
  cursor: pointer;
  transition: border-color 0.2s;
}

.variant-dot.active {
  border-color: #fff;
}

/* --- Cart Drawer Panel --- */
.cart-drawer {
  position: fixed;
  top: 0;
  right: -420px;
  width: 400px;
  height: 100vh;
  background: var(--bg-surface);
  border-left: 1px solid var(--border-light);
  z-index: 2000;
  box-shadow: -10px 0 40px rgba(0, 0, 0, 0.8);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  transition: right 0.4s var(--ease-smooth);
}

.cart-drawer.open {
  right: 0;
}

.cart-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-light);
}

.cart-close-btn {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  transition: color 0.2s;
}

.cart-close-btn:hover {
  color: var(--text-primary);
}

.cart-items-list {
  flex-grow: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  margin-bottom: 1.5rem;
}

.cart-item {
  display: flex;
  gap: 1rem;
  align-items: center;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 0.75rem;
}

.cart-item-img {
  width: 60px;
  height: 60px;
  object-fit: cover;
  border-radius: var(--radius-sm);
}

.cart-item-details {
  flex-grow: 1;
}

.cart-item-title {
  font-size: 0.9rem;
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 0.2rem;
}

.cart-item-price {
  font-size: 0.85rem;
  color: var(--color-secondary);
  font-weight: 700;
}

.cart-item-qty {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.4rem;
}

.qty-btn {
  width: 20px;
  height: 20px;
  border-radius: 4px;
  border: 1px solid var(--border-light);
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cart-item-remove {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  transition: color 0.2s;
}

.cart-item-remove:hover {
  color: var(--color-accent);
}

.cart-footer {
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-light);
}

.cart-total-row {
  display: flex;
  justify-content: space-between;
  font-size: 1.15rem;
  font-weight: 800;
  margin-bottom: 1.5rem;
}

.cart-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(6px);
  z-index: 1999;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.cart-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

/* --- Features Section --- */
.features-section {
  padding: 5rem 0;
  background: var(--bg-surface);
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2.5rem;
}

.feature-box {
  text-align: center;
  padding: 2rem;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  transition: transform 0.3s var(--ease-out-back);
}

.feature-box:hover {
  transform: translateY(-5px);
}

.feature-icon-wrapper {
  width: 56px;
  height: 56px;
  background: rgba(6, 182, 212, 0.1);
  border: 1px solid var(--color-secondary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-secondary);
  margin: 0 auto 1.25rem auto;
}

.feature-box h4 {
  font-size: 1.15rem;
  margin-bottom: 0.5rem;
}

.feature-box p {
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* --- Footer --- */
.footer {
  background: #040509;
  padding: 5rem 0 2rem 0;
  border-top: 1px solid var(--border-light);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr repeat(2, 1fr);
  gap: 3rem;
  margin-bottom: 3.5rem;
}

.footer-brand p {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-top: 1rem;
  max-width: 320px;
}

.footer-col h4 {
  font-size: 1.1rem;
  margin-bottom: 1.25rem;
  color: var(--text-primary);
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.footer-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.9rem;
  transition: color 0.2s;
}

.footer-links a:hover {
  color: var(--color-primary);
}

.footer-bottom {
  border-top: 1px solid var(--border-light);
  padding-top: 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--text-muted);
  font-size: 0.85rem;
}

/* --- Responsive Breakpoints --- */
@media (max-width: 1024px) {
  .hero-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .hero-content {
    display: flex;
    flex-direction: column;
    align-items: center;
  }
  .features-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .nav-menu {
    display: none;
  }
  .cart-drawer {
    width: 100%;
    right: -100%;
  }
  .footer-grid {
    grid-template-columns: 1fr;
  }
  .footer-bottom {
    flex-direction: column;
    gap: 1rem;
    text-align: center;
  }
}
