/* ============================================
   iSegigit Indonesia — Animations CSS
   ============================================ */

/* --- Hero Gradient Background --- */
.hero-gradient {
  background: radial-gradient(ellipse 80% 60% at 50% -10%, rgba(0,113,227,0.25) 0%, transparent 70%),
              radial-gradient(ellipse 40% 30% at 80% 50%, rgba(191,90,242,0.12) 0%, transparent 60%),
              var(--bg-primary);
}

/* --- Floating animation --- */
@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-16px); }
}
.float { animation: float 4s ease-in-out infinite; }

/* --- Pulse glow --- */
@keyframes pulseGlow {
  0%, 100% { box-shadow: 0 0 0 0 rgba(0,113,227,0); }
  50% { box-shadow: 0 0 40px 10px rgba(0,113,227,0.25); }
}
.pulse-glow { animation: pulseGlow 3s ease-in-out infinite; }

/* --- Shimmer text --- */
@keyframes shimmerText {
  0% { background-position: -200% center; }
  100% { background-position: 200% center; }
}
.shimmer-text {
  background: linear-gradient(90deg, #f5f5f7 0%, #0071e3 40%, #bf5af2 60%, #f5f5f7 100%);
  background-size: 200% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: shimmerText 4s linear infinite;
}

/* --- Fade in up --- */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(40px); }
  to { opacity: 1; transform: translateY(0); }
}
.fade-in-up {
  animation: fadeInUp 0.7s cubic-bezier(0.4,0,0.2,1) both;
}
.delay-1 { animation-delay: 0.1s; }
.delay-2 { animation-delay: 0.2s; }
.delay-3 { animation-delay: 0.3s; }
.delay-4 { animation-delay: 0.4s; }
.delay-5 { animation-delay: 0.6s; }

/* --- Stagger children --- */
.stagger-children > * {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.stagger-children.visible > *:nth-child(1) { opacity: 1; transform: none; transition-delay: 0s; }
.stagger-children.visible > *:nth-child(2) { opacity: 1; transform: none; transition-delay: 0.08s; }
.stagger-children.visible > *:nth-child(3) { opacity: 1; transform: none; transition-delay: 0.16s; }
.stagger-children.visible > *:nth-child(4) { opacity: 1; transform: none; transition-delay: 0.24s; }
.stagger-children.visible > *:nth-child(5) { opacity: 1; transform: none; transition-delay: 0.32s; }
.stagger-children.visible > *:nth-child(6) { opacity: 1; transform: none; transition-delay: 0.4s; }

/* --- Glassmorphism Card --- */
.glass-card {
  background: rgba(28, 28, 30, 0.6);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-xl);
}

/* --- Gradient Border --- */
.gradient-border {
  position: relative;
  border-radius: var(--radius-lg);
  padding: 1px;
  background: linear-gradient(135deg, rgba(0,113,227,0.6), rgba(191,90,242,0.4), rgba(0,113,227,0.2));
}
.gradient-border-inner {
  background: var(--bg-card);
  border-radius: calc(var(--radius-lg) - 1px);
  height: 100%;
}

/* --- Horizontal Scroll Track --- */
.scroll-track {
  display: flex;
  gap: 20px;
  overflow-x: auto;
  padding-bottom: 16px;
  scrollbar-width: thin;
  scrollbar-color: var(--bg-elevated) transparent;
  scroll-snap-type: x mandatory;
}
.scroll-track::-webkit-scrollbar { height: 4px; }
.scroll-track::-webkit-scrollbar-track { background: transparent; }
.scroll-track::-webkit-scrollbar-thumb { background: var(--bg-elevated); border-radius: 2px; }
.scroll-track > * { scroll-snap-align: start; flex-shrink: 0; }

/* --- Hero Video/Image Overlay --- */
.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, transparent 40%, var(--bg-primary) 100%);
  z-index: 1;
}

/* --- Trust Badge --- */
.trust-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(52, 199, 89, 0.1);
  border: 1px solid rgba(52, 199, 89, 0.25);
  border-radius: 100px;
  padding: 6px 14px;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--accent-green);
}

/* --- Category Card --- */
.category-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 32px 24px;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}
.category-card:hover {
  border-color: var(--accent);
  background: var(--bg-elevated);
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(0,113,227,0.15);
}
.category-card svg {
  width: 48px; height: 48px;
  color: var(--accent);
}
.category-card h3 { font-size: 1.1rem; font-weight: 600; color: var(--text-primary); }
.category-card p { font-size: 0.85rem; color: var(--text-muted); }

/* --- Spec Table --- */
.spec-table { width: 100%; border-collapse: collapse; }
.spec-table tr { border-bottom: 1px solid var(--border-light); }
.spec-table tr:last-child { border-bottom: none; }
.spec-table td { padding: 12px 0; font-size: 0.9rem; }
.spec-table td:first-child { color: var(--text-muted); width: 40%; }
.spec-table td:last-child { color: var(--text-primary); font-weight: 500; }

/* --- Variant Selector --- */
.variant-group { display: flex; flex-wrap: wrap; gap: 8px; }
.variant-btn {
  padding: 8px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-secondary);
  cursor: pointer;
  transition: var(--transition);
}
.variant-btn:hover { border-color: var(--accent); color: var(--text-primary); }
.variant-btn.active {
  border-color: var(--accent);
  background: var(--accent-light);
  color: var(--accent);
}

/* --- Payment Method Card --- */
.payment-card {
  background: var(--bg-card);
  border: 2px solid var(--border);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 14px;
}
.payment-card:hover { border-color: var(--accent); }
.payment-card.selected { border-color: var(--accent); background: var(--accent-light); }
.payment-card .radio-dot {
  width: 18px; height: 18px;
  border: 2px solid var(--border);
  border-radius: 50%;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}
.payment-card.selected .radio-dot { border-color: var(--accent); }
.payment-card.selected .radio-dot::after {
  content: '';
  width: 8px; height: 8px;
  background: var(--accent);
  border-radius: 50%;
}

/* --- Sticky Buy Bar --- */
.sticky-buy-bar {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  background: rgba(28, 28, 30, 0.92);
  backdrop-filter: blur(20px);
  border-top: 1px solid var(--border);
  padding: 16px 24px;
  z-index: 100;
  transform: translateY(100%);
  transition: transform 0.35s cubic-bezier(0.4,0,0.2,1);
}
.sticky-buy-bar.visible { transform: translateY(0); }
.sticky-buy-bar-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

/* --- Cart Item --- */
.cart-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px 0;
  border-bottom: 1px solid var(--border-light);
}
.cart-item-img {
  width: 80px; height: 80px;
  background: var(--bg-secondary);
  border-radius: var(--radius-md);
  overflow: hidden;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.cart-item-img img { width: 100%; height: 100%; object-fit: cover; }
.cart-item-info { flex: 1; }
.cart-item-name { font-weight: 600; font-size: 0.95rem; }
.cart-item-variant { font-size: 0.82rem; color: var(--text-muted); }
.cart-item-price { font-weight: 700; font-size: 1rem; }
.qty-control {
  display: flex;
  align-items: center;
  gap: 0;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
}
.qty-btn {
  width: 32px; height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition);
  font-size: 1.1rem;
  color: var(--text-secondary);
}
.qty-btn:hover { background: var(--bg-card); color: var(--text-primary); }
.qty-num { min-width: 32px; text-align: center; font-size: 0.9rem; font-weight: 600; }

/* --- Order Summary --- */
.order-summary {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
}
.summary-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0;
  font-size: 0.9rem;
}
.summary-row.total {
  border-top: 1px solid var(--border);
  margin-top: 8px;
  padding-top: 16px;
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--text-primary);
}
.summary-row span:first-child { color: var(--text-muted); }
.summary-row span:last-child { color: var(--text-primary); font-weight: 500; }

/* --- Admin Sidebar --- */
.admin-layout { display: flex; min-height: 100vh; }
.admin-sidebar {
  width: 240px;
  background: var(--bg-secondary);
  border-right: 1px solid var(--border-light);
  padding: 24px 16px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
  position: fixed;
  top: 0; bottom: 0;
}
.admin-main { margin-left: 240px; flex: 1; padding: 32px; }
.admin-sidebar-logo { padding: 8px 12px; margin-bottom: 16px; }
.admin-sidebar-logo span { font-size: 1.1rem; font-weight: 700; color: var(--text-primary); }
.sidebar-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-muted);
  transition: var(--transition);
  cursor: pointer;
}
.sidebar-link:hover, .sidebar-link.active {
  background: var(--bg-elevated);
  color: var(--text-primary);
}
.sidebar-link.active { color: var(--accent); }
.sidebar-link svg { width: 18px; height: 18px; flex-shrink: 0; }

/* --- Stat Card --- */
.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
}
.stat-card h3 { font-size: 2rem; font-weight: 700; color: var(--text-primary); }
.stat-card p { font-size: 0.85rem; color: var(--text-muted); margin-top: 4px; }

/* --- Table --- */
.admin-table { width: 100%; border-collapse: collapse; }
.admin-table th {
  text-align: left;
  padding: 12px 16px;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border);
}
.admin-table td {
  padding: 14px 16px;
  font-size: 0.88rem;
  color: var(--text-primary);
  border-bottom: 1px solid var(--border-light);
  vertical-align: middle;
}
.admin-table tr:last-child td { border-bottom: none; }
.admin-table tr:hover td { background: var(--bg-elevated); }

/* --- Modal --- */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.7);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}
.modal-overlay.open { opacity: 1; pointer-events: all; }
.modal {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  width: 100%;
  max-width: 600px;
  max-height: 90vh;
  overflow-y: auto;
  padding: 32px;
  transform: scale(0.95);
  transition: transform 0.25s ease;
}
.modal-overlay.open .modal { transform: scale(1); }
.modal-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 24px; }
.modal-close {
  width: 32px; height: 32px;
  border-radius: 50%;
  background: var(--bg-elevated);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-muted);
  transition: var(--transition);
}
.modal-close:hover { color: var(--text-primary); background: var(--bg-card); border: 1px solid var(--border); }

/* --- Breadcrumb --- */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 32px;
}
.breadcrumb a { color: var(--text-muted); transition: var(--transition); }
.breadcrumb a:hover { color: var(--text-primary); }
.breadcrumb span { color: var(--text-muted); }
.breadcrumb .current { color: var(--text-primary); }

/* --- Pagination --- */
.pagination { display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 48px; }
.page-btn {
  width: 36px; height: 36px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-secondary);
  background: var(--bg-card);
  border: 1px solid var(--border);
  cursor: pointer;
  transition: var(--transition);
}
.page-btn:hover, .page-btn.active { background: var(--accent); border-color: var(--accent); color: #fff; }

/* --- Promo Banner --- */
.promo-banner {
  background: linear-gradient(135deg, #0071e3 0%, #3a46c5 50%, #bf5af2 100%);
  border-radius: var(--radius-xl);
  padding: 48px;
  position: relative;
  overflow: hidden;
  text-align: center;
}
.promo-banner::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 70% 50%, rgba(255,255,255,0.12) 0%, transparent 60%);
}
.promo-banner * { position: relative; z-index: 1; }
.promo-banner h2 { color: #fff; margin-bottom: 12px; }
.promo-banner p { color: rgba(255,255,255,0.8); margin-bottom: 24px; }

/* --- Image Gallery --- */
.gallery-main {
  aspect-ratio: 4/3;
  background: var(--bg-secondary);
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-bottom: 12px;
}
.gallery-main img { width: 100%; height: 100%; object-fit: contain; padding: 20px; }
.gallery-thumbs { display: flex; gap: 8px; }
.gallery-thumb {
  width: 72px; height: 72px;
  background: var(--bg-secondary);
  border-radius: var(--radius-sm);
  border: 2px solid transparent;
  overflow: hidden;
  cursor: pointer;
  transition: var(--transition);
}
.gallery-thumb img { width: 100%; height: 100%; object-fit: cover; }
.gallery-thumb.active { border-color: var(--accent); }
.gallery-thumb:hover { border-color: var(--border); }

/* Toggle Switch */
.toggle { position: relative; width: 44px; height: 24px; }
.toggle input { opacity: 0; width: 0; height: 0; }
.toggle-slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 12px;
  transition: var(--transition);
}
.toggle-slider::before {
  content: '';
  position: absolute;
  height: 16px; width: 16px;
  left: 3px; bottom: 3px;
  background: var(--text-muted);
  border-radius: 50%;
  transition: var(--transition);
}
.toggle input:checked + .toggle-slider { background: var(--accent); border-color: var(--accent); }
.toggle input:checked + .toggle-slider::before { transform: translateX(20px); background: #fff; }

/* --- Search Bar --- */
.search-bar {
  position: relative;
  max-width: 480px;
  width: 100%;
}
.search-bar svg {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  width: 18px; height: 18px;
  color: var(--text-muted);
}
.search-bar input {
  width: 100%;
  padding: 11px 16px 11px 42px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 100px;
  color: var(--text-primary);
  font-size: 0.9rem;
  font-family: var(--font);
  outline: none;
  transition: var(--transition);
}
.search-bar input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(0,113,227,0.15); }
.search-bar input::placeholder { color: var(--text-muted); }

/* --- Filter Chip --- */
.filter-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  padding: 6px 14px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 100px;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-secondary);
  cursor: pointer;
  transition: var(--transition);
  white-space: nowrap;
}
.chip:hover { border-color: var(--accent); color: var(--text-primary); }
.chip.active { background: var(--accent-light); border-color: var(--accent); color: var(--accent); }

/* --- Empty State --- */
.empty-state {
  text-align: center;
  padding: 80px 24px;
}
.empty-state svg { width: 64px; height: 64px; color: var(--text-muted); margin: 0 auto 16px; }
.empty-state h3 { color: var(--text-primary); margin-bottom: 8px; }
.empty-state p { font-size: 0.9rem; }

/* --- Testimonial --- */
.testimonial-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 28px;
}
.testimonial-card .stars { color: #FF9F0A; font-size: 1rem; letter-spacing: 2px; margin-bottom: 12px; }
.testimonial-card p { font-size: 0.92rem; color: var(--text-secondary); line-height: 1.7; margin-bottom: 16px; }
.testimonial-author { display: flex; align-items: center; gap: 12px; }
.testimonial-avatar {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), #bf5af2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
  color: #fff;
  flex-shrink: 0;
}
.testimonial-author-info strong { display: block; font-size: 0.88rem; font-weight: 600; color: var(--text-primary); }
.testimonial-author-info span { font-size: 0.78rem; color: var(--text-muted); }
