/* ==========================================================================
   Omnichannel Microservices Platform - Design System
   Enterprise Glassmorphism & High-Performance E-Commerce Theme
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@400;500;600;700;800&family=Plus+Jakarta+Sans:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500;600&display=swap');

:root {
  --bg-primary: #0a0d14;
  --bg-secondary: #0f1422;
  --bg-surface: rgba(22, 28, 45, 0.75);
  --bg-surface-elevated: rgba(30, 39, 63, 0.85);
  --bg-surface-hover: rgba(38, 49, 78, 0.95);
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-glow: rgba(99, 102, 241, 0.35);

  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --text-faint: #64748b;

  --accent-primary: #6366f1;
  --accent-primary-hover: #4f46e5;
  --accent-gradient: linear-gradient(135deg, #6366f1 0%, #a855f7 50%, #ec4899 100%);
  --flash-gradient: linear-gradient(135deg, #ef4444 0%, #f97316 100%);
  --emerald-gradient: linear-gradient(135deg, #10b981 0%, #06b6d4 100%);

  --danger: #ef4444;
  --warning: #f59e0b;
  --success: #10b981;
  --info: #06b6d4;

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-full: 9999px;

  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 10px 25px -5px rgba(0, 0, 0, 0.5), 0 8px 10px -6px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 25px rgba(99, 102, 241, 0.25);
  --shadow-fire: 0 0 30px rgba(239, 68, 68, 0.3);

  --font-heading: 'Outfit', sans-serif;
  --font-body: 'Plus Jakarta Sans', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  --transition-fast: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-smooth: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-primary);
  background-image: 
    radial-gradient(at 0% 0%, rgba(99, 102, 241, 0.15) 0px, transparent 50%),
    radial-gradient(at 100% 0%, rgba(236, 72, 153, 0.1) 0px, transparent 50%),
    radial-gradient(at 50% 100%, rgba(16, 185, 129, 0.08) 0px, transparent 50%);
  background-attachment: fixed;
  color: var(--text-main);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
}

/* ==========================================================================
   Navigation Bar
   ========================================================================== */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 2.5rem;
  background: rgba(10, 13, 20, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-subtle);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  cursor: pointer;
}

.brand-icon {
  width: 42px;
  height: 42px;
  border-radius: var(--radius-md);
  background: var(--accent-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  box-shadow: var(--shadow-glow);
}

.brand-text h1 {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.brand-text span {
  font-size: 0.72rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 600;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--bg-surface);
  padding: 0.35rem;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-subtle);
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.5rem 1.1rem;
  border-radius: var(--radius-full);
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-muted);
  background: transparent;
  border: none;
  cursor: pointer;
  transition: var(--transition-fast);
}

.nav-link:hover {
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.05);
}

.nav-link.active {
  color: #fff;
  background: var(--accent-primary);
  box-shadow: 0 0 15px rgba(99, 102, 241, 0.4);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.user-badge {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  padding: 0.4rem 0.9rem;
  border-radius: var(--radius-full);
  font-size: 0.85rem;
}

.user-avatar {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #3b82f6;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
}

.cart-btn {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-main);
  font-size: 1.2rem;
  cursor: pointer;
  transition: var(--transition-fast);
}

.cart-btn:hover {
  border-color: var(--accent-primary);
  transform: translateY(-2px);
}

.cart-count {
  position: absolute;
  top: -4px;
  right: -4px;
  background: var(--danger);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ==========================================================================
   Container & Tabs
   ========================================================================== */
.main-container {
  max-width: 1360px;
  margin: 0 auto;
  padding: 2rem 2rem 5rem;
}

.tab-pane {
  display: none;
  animation: fadeIn 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.tab-pane.active {
  display: block;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ==========================================================================
   Flash Sale Hero Banner
   ========================================================================== */
.flashsale-banner {
  background: radial-gradient(circle at 100% 50%, rgba(239, 68, 68, 0.25), transparent 70%),
              linear-gradient(135deg, rgba(26, 15, 30, 0.95), rgba(15, 20, 35, 0.95));
  border: 1px solid rgba(239, 68, 68, 0.3);
  border-radius: var(--radius-lg);
  padding: 2.2rem 3rem;
  margin-bottom: 2.5rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 2.5rem;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-fire);
}

.flashsale-banner::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(239, 68, 68, 0.08) 0%, transparent 60%);
  pointer-events: none;
}

.flash-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--flash-gradient);
  color: #fff;
  padding: 0.35rem 0.9rem;
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 1rem;
  box-shadow: 0 0 15px rgba(239, 68, 68, 0.5);
  animation: pulseFire 2s infinite;
}

@keyframes pulseFire {
  0%, 100% { box-shadow: 0 0 15px rgba(239, 68, 68, 0.5); }
  50% { box-shadow: 0 0 25px rgba(249, 115, 22, 0.8); }
}

.flash-title {
  font-family: var(--font-heading);
  font-size: 2.3rem;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 0.75rem;
  color: #fff;
}

.flash-desc {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 1.5rem;
  max-width: 500px;
}

.flash-pricing {
  display: flex;
  align-items: baseline;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.price-current {
  font-family: var(--font-heading);
  font-size: 2.2rem;
  font-weight: 800;
  color: #ef4444;
}

.price-original {
  font-size: 1.2rem;
  text-decoration: line-through;
  color: var(--text-faint);
}

.flash-stock-wrap {
  margin-bottom: 1.5rem;
  max-width: 380px;
}

.stock-labels {
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 0.4rem;
}

.stock-meter-bg {
  width: 100%;
  height: 10px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.stock-meter-fill {
  height: 100%;
  background: var(--flash-gradient);
  border-radius: var(--radius-full);
  transition: width 0.4s ease;
  box-shadow: 0 0 10px rgba(239, 68, 68, 0.7);
}

.countdown-box {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-top: 1rem;
}

.time-digit {
  background: rgba(0, 0, 0, 0.6);
  border: 1px solid var(--border-subtle);
  padding: 0.4rem 0.7rem;
  border-radius: var(--radius-sm);
  font-family: var(--font-mono);
  font-size: 1.2rem;
  font-weight: 700;
  color: #fb923c;
}

.flash-hero-img-wrap {
  display: flex;
  justify-content: center;
  position: relative;
}

.flash-hero-img {
  max-width: 85%;
  max-height: 320px;
  object-fit: cover;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  transform: perspective(1000px) rotateY(-10deg) rotateX(4deg);
  transition: var(--transition-smooth);
}

.flash-hero-img:hover {
  transform: perspective(1000px) rotateY(0deg) rotateX(0deg) scale(1.03);
}

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius-md);
  font-family: var(--font-body);
  font-size: 0.92rem;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: var(--transition-fast);
  text-decoration: none;
}

.btn-primary {
  background: var(--accent-gradient);
  color: #fff;
  box-shadow: var(--shadow-glow);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 30px rgba(99, 102, 241, 0.5);
}

.btn-flash {
  background: var(--flash-gradient);
  color: #fff;
  font-weight: 700;
  box-shadow: var(--shadow-fire);
}

.btn-flash:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 0 35px rgba(239, 68, 68, 0.7);
}

.btn-secondary {
  background: var(--bg-surface-elevated);
  color: var(--text-main);
  border: 1px solid var(--border-subtle);
}

.btn-secondary:hover {
  background: var(--bg-surface-hover);
  border-color: rgba(255, 255, 255, 0.2);
}

.btn-success {
  background: var(--emerald-gradient);
  color: #fff;
}

.btn-danger {
  background: var(--danger);
  color: #fff;
}

.btn-sm {
  padding: 0.4rem 0.85rem;
  font-size: 0.8rem;
  border-radius: var(--radius-sm);
}

.btn-lg {
  padding: 1rem 2rem;
  font-size: 1.05rem;
}

/* ==========================================================================
   Product Catalog Grid
   ========================================================================== */
.catalog-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}

.category-chips {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.chip-btn {
  padding: 0.45rem 1rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  border-radius: var(--radius-full);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition-fast);
}

.chip-btn:hover {
  color: var(--text-main);
  border-color: rgba(255, 255, 255, 0.2);
}

.chip-btn.active {
  background: var(--accent-primary);
  color: #fff;
  border-color: var(--accent-primary);
}

.search-box {
  display: flex;
  align-items: center;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  padding: 0.4rem 1rem;
  width: 280px;
}

.search-box input {
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-main);
  font-family: var(--font-body);
  font-size: 0.88rem;
  width: 100%;
}

.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.75rem;
}

.product-card {
  background: var(--bg-surface);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: var(--transition-smooth);
  position: relative;
}

.product-card:hover {
  transform: translateY(-5px);
  border-color: var(--border-glow);
  box-shadow: var(--shadow-md), var(--shadow-glow);
}

.product-img-wrap {
  width: 100%;
  height: 200px;
  position: relative;
  overflow: hidden;
  background: #0d111a;
}

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

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

.product-tag {
  position: absolute;
  top: 10px;
  left: 10px;
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-full);
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
}

.tag-flash {
  background: var(--danger);
  color: #fff;
}

.tag-normal {
  background: rgba(0, 0, 0, 0.6);
  color: #38bdf8;
  backdrop-filter: blur(4px);
}

.product-body {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.product-name {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 0.4rem;
  color: #fff;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  height: 2.8rem;
}

.product-desc {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 1rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  height: 2.4rem;
}

.product-footer {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 0.75rem;
  border-top: 1px solid var(--border-subtle);
}

.product-price-box {
  display: flex;
  flex-direction: column;
}

.card-price {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 800;
  color: #6366f1;
}

.card-price.flash {
  color: #ef4444;
}

.card-stock {
  font-size: 0.75rem;
  color: var(--text-faint);
  font-weight: 600;
}

/* ==========================================================================
   Benchmark & Concurrency Lab Tab
   ========================================================================== */
.lab-header {
  text-align: center;
  margin-bottom: 2.5rem;
}

.lab-title {
  font-family: var(--font-heading);
  font-size: 2.4rem;
  font-weight: 800;
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 0.5rem;
}

.lab-subtitle {
  color: var(--text-muted);
  font-size: 1rem;
  max-width: 700px;
  margin: 0 auto;
}

.lab-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  margin-bottom: 2rem;
}

.glass-panel {
  background: var(--bg-surface);
  backdrop-filter: blur(16px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  box-shadow: var(--shadow-md);
}

.panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.25rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border-subtle);
}

.panel-title {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.metric-cards-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.metric-card {
  background: rgba(15, 20, 32, 0.7);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1.1rem;
  text-align: center;
}

.metric-val {
  font-family: var(--font-heading);
  font-size: 2rem;
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 0.3rem;
}

.metric-val.emerald { color: #10b981; }
.metric-val.rose { color: #ef4444; }
.metric-val.indigo { color: #6366f1; }
.metric-val.amber { color: #f59e0b; }

.metric-title {
  font-size: 0.78rem;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 600;
  letter-spacing: 0.05em;
}

.concurrency-controls {
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
}

.control-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.control-label {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-muted);
}

.btn-group-toggle {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.5rem;
}

.toggle-btn {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  padding: 0.6rem;
  border-radius: var(--radius-sm);
  font-family: var(--font-mono);
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition-fast);
}

.toggle-btn.active {
  background: var(--accent-primary);
  color: #fff;
  border-color: var(--accent-primary);
  box-shadow: 0 0 10px rgba(99, 102, 241, 0.5);
}

.console-terminal {
  background: #06090e;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1rem;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: #10b981;
  height: 260px;
  overflow-y: auto;
  line-height: 1.5;
}

.console-line {
  margin-bottom: 0.25rem;
  word-break: break-all;
}

/* ==========================================================================
   Custom Select Dropdown with Chevron Arrow for Benchmark Product
   ========================================================================== */
.custom-select-wrap {
  position: relative;
  width: 100%;
}

.custom-select {
  width: 100% !important;
  appearance: none !important;
  -webkit-appearance: none !important;
  -moz-appearance: none !important;
  background: #0f172a !important;
  border: 1px solid var(--border-subtle) !important;
  color: #fff !important;
  padding: 0.85rem 2.8rem 0.85rem 1rem !important;
  border-radius: var(--radius-sm) !important;
  font-family: var(--font-body) !important;
  font-size: 0.92rem !important;
  font-weight: 600 !important;
  cursor: pointer !important;
  outline: none !important;
  transition: var(--transition-fast);
}

.custom-select::-ms-expand {
  display: none !important;
}

.custom-select:hover {
  border-color: rgba(99, 102, 241, 0.5) !important;
  background: #1e293b !important;
}

.custom-select:focus {
  border-color: var(--accent-primary) !important;
  box-shadow: 0 0 12px rgba(99, 102, 241, 0.35) !important;
}

.custom-select option {
  background: #0f172a !important;
  color: #f1f5f9 !important;
  padding: 0.75rem !important;
}

.custom-select-arrow {
  position: absolute;
  right: 1.1rem;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  color: var(--accent-primary);
  font-size: 0.85rem;
  transition: transform 0.2s ease;
}

.custom-select:focus + .custom-select-arrow {
  transform: translateY(-50%) rotate(180deg);
}

.benchmark-product-preview {
  margin-top: 0.5rem;
  padding: 0.6rem 0.9rem;
  background: rgba(0, 0, 0, 0.25);
  border-radius: var(--radius-sm);
  border: 1px dashed var(--border-subtle);
  font-size: 0.82rem;
  color: var(--text-muted);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.btn-xs {
  padding: 0.25rem 0.65rem;
  font-size: 0.75rem;
  border-radius: var(--radius-full);
}

.console-line.err { color: #ef4444; }
.console-line.warn { color: #f59e0b; }
.console-line.info { color: #38bdf8; }

/* ==========================================================================
   Saga & Microservices Topology Tab
   ========================================================================== */
.topology-flow {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  margin-bottom: 2.5rem;
}

.flow-step-card {
  display: grid;
  grid-template-columns: 60px 1fr auto;
  align-items: center;
  gap: 1.25rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  transition: var(--transition-fast);
}

.flow-step-card:hover {
  border-color: var(--border-glow);
}

.step-number {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--bg-surface-elevated);
  border: 2px solid var(--accent-primary);
  color: #fff;
  font-family: var(--font-heading);
  font-size: 1.2rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
}

.step-info h4 {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 0.2rem;
}

.step-info p {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.step-badge {
  padding: 0.35rem 0.85rem;
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  font-weight: 700;
}

.step-badge.sync {
  background: rgba(56, 189, 248, 0.15);
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.3);
}

.step-badge.async {
  background: rgba(168, 85, 247, 0.15);
  color: #c084fc;
  border: 1px solid rgba(168, 85, 247, 0.3);
}

.step-badge.saga {
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

/* Service Health Matrix */
.services-matrix {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
}

.service-health-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.service-meta h5 {
  font-size: 0.9rem;
  font-weight: 700;
}

.service-meta span {
  font-size: 0.75rem;
  color: var(--text-faint);
  font-family: var(--font-mono);
}

.status-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 10px #10b981;
}

.status-dot.down {
  background: #ef4444;
  box-shadow: 0 0 10px #ef4444;
}

/* ==========================================================================
   Order History & Notification Feed
   ========================================================================== */
.orders-table-wrap {
  overflow-x: auto;
}

.custom-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.88rem;
}

.custom-table th {
  padding: 1rem;
  background: rgba(15, 20, 32, 0.8);
  color: var(--text-muted);
  font-weight: 700;
  text-transform: uppercase;
  font-size: 0.75rem;
  border-bottom: 1px solid var(--border-subtle);
}

.custom-table td {
  padding: 1rem;
  border-bottom: 1px solid var(--border-subtle);
  color: var(--text-main);
}

.custom-table tr:hover td {
  background: rgba(255, 255, 255, 0.02);
}

.status-pill {
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 700;
}

.status-pill.pending { background: rgba(245, 158, 11, 0.15); color: #fbbf24; }
.status-pill.confirmed, .status-pill.paid { background: rgba(16, 185, 129, 0.15); color: #34d399; }
.status-pill.cancelled { background: rgba(239, 68, 68, 0.15); color: #f87171; }

.notif-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1rem;
  border-bottom: 1px solid var(--border-subtle);
  transition: var(--transition-fast);
}

.notif-item:hover {
  background: rgba(255, 255, 255, 0.02);
}

.notif-icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  background: var(--bg-surface-elevated);
}

.notif-content h5 {
  font-size: 0.92rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.2rem;
}

.notif-content p {
  font-size: 0.82rem;
  color: var(--text-muted);
}

.notif-time {
  font-size: 0.72rem;
  color: var(--text-faint);
  margin-top: 0.3rem;
  font-family: var(--font-mono);
}

/* ==========================================================================
   Modals & Drawers
   ========================================================================== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.modal-overlay.open {
  display: flex;
}

.modal-content {
  background: var(--bg-secondary);
  border: 1px solid var(--border-glow);
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 520px;
  padding: 2rem;
  position: relative;
  box-shadow: var(--shadow-md), var(--shadow-glow);
}

.modal-close {
  position: absolute;
  top: 1.25rem;
  right: 1.25rem;
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 1.5rem;
  cursor: pointer;
}

.cart-drawer {
  position: fixed;
  top: 0;
  right: -420px;
  width: 400px;
  height: 100vh;
  background: var(--bg-secondary);
  border-left: 1px solid var(--border-subtle);
  z-index: 1000;
  box-shadow: -10px 0 30px rgba(0, 0, 0, 0.7);
  transition: right 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
}

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

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

.cart-drawer-body {
  flex: 1;
  padding: 1.5rem;
  overflow-y: auto;
}

.cart-drawer-footer {
  padding: 1.5rem;
  border-top: 1px solid var(--border-subtle);
  background: rgba(10, 13, 20, 0.5);
}

/* Toast Alerts */
.toast-container {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 2000;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.toast {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-glow);
  border-radius: var(--radius-md);
  padding: 0.9rem 1.25rem;
  color: #fff;
  font-size: 0.88rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  box-shadow: var(--shadow-md);
  animation: slideInRight 0.3s ease;
}

.toast.success { border-color: var(--success); }
.toast.error { border-color: var(--danger); }

@keyframes slideInRight {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

@media (max-width: 992px) {
  .flashsale-banner { grid-template-columns: 1fr; }
  .lab-grid { grid-template-columns: 1fr; }
  .navbar { padding: 1rem; }
  .nav-links { display: none; }
}
