/* =========================================================
   STYLE E-COMMERCE MODERN — TECHNO CYAN COMMERCIAL THEME
   ========================================================= */

:root {
  --eco-cyan: #0284C7;          /* Cyan / Pacific Blue */
  --eco-cyan-hover: #0369A1;
  --eco-cyan-light: #E0F2FE;    /* Highlight Cyan Soft */
  --eco-green: #10B981;         /* Emerald Green untuk Pendaftaran / Open */
  --eco-green-hover: #059669;
  --eco-orange: #F59E0B;        /* Gold / Orange untuk Harga Dinamis */
  --eco-wa: #25D366;            /* WhatsApp Green */
  --eco-dark: #0A192F;          /* Midnight Dark Navy */
  --eco-bg: #F8FAFC;            /* Background Clean Light Gray */
  --eco-card: #FFFFFF;
  --eco-text-main: #0F172A;     /* Dark Slate Text */
  --eco-text-muted: #64748B;
  --eco-border: #E2E8F0;
  --eco-radius: 12px;
  --eco-shadow-sm: 0 2px 8px rgba(2, 132, 199, 0.05);
  --eco-shadow-md: 0 10px 25px rgba(2, 132, 199, 0.12);
}

body {
  background-color: var(--eco-bg);
  color: var(--eco-text-main);
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  margin: 0;
  padding: 0;
}

.ecom-container {
  max-width: 1300px;
  margin: 0 auto;
  padding: 0 16px;
  box-sizing: border-box;
}

/* 1. HERO PROMO BANNER */
.events-hero {
  background-color: var(--eco-card);
  padding: 16px 0;
  border-bottom: 1px solid var(--eco-border);
}

.hero-banner-img {
  width: 100%;
  max-height: 260px;
  object-fit: cover;
  border-radius: var(--eco-radius);
  display: block;
  box-shadow: 0 4px 15px rgba(0,0,0,0.06);
}

/* 2. SAMBUTAN PELANGGAN (WELCOME BANNER) */
.welcome-section {
  padding: 20px 0 0 0;
}

.welcome-card {
  background: linear-gradient(135deg, var(--eco-dark) 0%, #0F2942 60%, var(--eco-cyan) 100%);
  color: #FFFFFF;
  padding: 24px 30px;
  border-radius: var(--eco-radius);
  border-left: 5px solid var(--eco-cyan);
  box-shadow: var(--eco-shadow-md);
}

.welcome-badge {
  display: inline-block;
  background: rgba(2, 132, 199, 0.3);
  border: 1px solid var(--eco-cyan);
  color: #7DD3FC;
  font-size: 0.72rem;
  font-weight: 800;
  padding: 4px 12px;
  border-radius: 20px;
  margin-bottom: 8px;
  letter-spacing: 0.5px;
}

.welcome-title {
  font-size: 1.4rem;
  font-weight: 900;
  margin: 0 0 8px 0;
  color: #FFFFFF;
}

.welcome-desc {
  font-size: 0.88rem;
  color: #E0F2FE;
  margin: 0;
  line-height: 1.6;
  max-width: 900px;
}

/* 3. LAYOUT E-COMMERCE (GRID SYSTEM) */
.ecom-layout {
  padding: 24px 0 60px 0;
}

.ecom-grid-system {
  display: grid;
  grid-template-columns: 250px 1fr;
  gap: 24px;
  align-items: start;
}

/* 4. SIDEBAR FILTER (KIRI) */
.ecom-sidebar {
  background: var(--eco-card);
  border-radius: var(--eco-radius);
  border: 1px solid var(--eco-border);
  position: sticky;
  top: 20px;
  max-height: 88vh;
  overflow-y: auto;
  box-shadow: var(--eco-shadow-sm);
}

.ecom-sidebar::-webkit-scrollbar { width: 5px; }
.ecom-sidebar::-webkit-scrollbar-thumb { background: #CBD5E1; border-radius: 4px; }

.sidebar-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px;
  border-bottom: 1px solid var(--eco-border);
  position: sticky;
  top: 0;
  background: var(--eco-card);
  z-index: 10;
}

.sidebar-header h3 {
  font-size: 0.95rem;
  font-weight: 800;
  margin: 0;
  color: var(--eco-text-main);
}

.btn-reset-text {
  background: none;
  border: none;
  color: var(--eco-cyan);
  font-weight: 700;
  font-size: 0.82rem;
  cursor: pointer;
  transition: color 0.2s;
}

.btn-reset-text:hover { color: var(--eco-cyan-hover); text-decoration: underline; }

.sidebar-content { padding: 16px; }

.filter-section {
  margin-bottom: 18px;
  border-bottom: 1px dashed var(--eco-border);
  padding-bottom: 14px;
}
.filter-section:last-child { border-bottom: none; margin-bottom: 0; padding-bottom: 0; }

.filter-heading {
  font-size: 0.8rem;
  font-weight: 800;
  color: var(--eco-text-muted);
  margin: 0 0 10px 0;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.m-chip {
  background: #F1F5F9;
  border: 1px solid var(--eco-border);
  color: var(--eco-text-main);
  font-size: 0.76rem;
  font-weight: 600;
  padding: 5px 10px;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.m-chip:hover {
  border-color: var(--eco-cyan);
  color: var(--eco-cyan);
}

.m-chip.active {
  background: var(--eco-cyan);
  border-color: var(--eco-cyan);
  color: #FFFFFF;
  font-weight: 700;
  box-shadow: 0 3px 8px rgba(2, 132, 199, 0.3);
}

/* 5. MAIN KONTEN (KANAN) */
.ecom-main {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.ecom-search-bar {
  display: flex;
  align-items: center;
  background: var(--eco-card);
  border: 1.5px solid var(--eco-border);
  border-radius: var(--eco-radius);
  padding: 10px 16px;
  box-shadow: var(--eco-shadow-sm);
  transition: border-color 0.2s ease;
}

.ecom-search-bar:focus-within {
  border-color: var(--eco-cyan);
  box-shadow: 0 0 0 3px rgba(2, 132, 199, 0.15);
}

.ecom-search-bar input {
  width: 100%;
  border: none;
  outline: none;
  margin-left: 10px;
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--eco-text-main);
}

.ecom-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 18px;
}

/* 6. KARTU PRODUK MINIMALIS (STYLE TOKOPEDIA CYAN) */
.event-card {
  background: var(--eco-card);
  border: 1.5px solid var(--eco-border);
  border-radius: var(--eco-radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.event-card:hover {
  transform: translateY(-4px);
  border-color: var(--eco-cyan);
  box-shadow: var(--eco-shadow-md);
}

.card-slider {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  background: #0A192F;
  overflow: hidden;
}

.slide-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: none;
}
.slide-img.active { display: block; }

.status-badge {
  position: absolute;
  top: 8px;
  left: 8px;
  padding: 3px 8px;
  border-radius: 4px;
  font-size: 0.65rem;
  font-weight: 800;
  text-transform: uppercase;
  z-index: 5;
  box-shadow: 0 2px 6px rgba(0,0,0,0.15);
}
.status-badge.open { background: var(--eco-green); color: #FFF; }
.status-badge.close { background: #EF4444; color: #FFF; }

.slider-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255,255,255,0.85);
  border: 1px solid #DDD;
  color: #333;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  cursor: pointer;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: bold;
}
.slider-btn.prev { left: 4px; }
.slider-btn.next { right: 4px; }

.card-body {
  padding: 12px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.card-title {
  font-size: 0.92rem;
  font-weight: 800;
  line-height: 1.4;
  margin: 0 0 8px 0;
  color: var(--eco-text-main);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-price-box {
  margin-bottom: 12px;
}

.price-amount {
  font-size: 1.05rem;
  font-weight: 900;
  color: var(--eco-cyan);
}

.price-badge.free {
  display: inline-block;
  background: #DCFCE7;
  color: #15803D;
  border: 1px solid #86EFAC;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 900;
}

.card-actions {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.btn-cta-detail {
  background: #F1F5F9;
  color: var(--eco-text-main);
  border: 1px solid var(--eco-border);
  padding: 7px;
  border-radius: 6px;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: center;
}

.btn-cta-detail:hover {
  background: var(--eco-cyan-light);
  border-color: var(--eco-cyan);
  color: var(--eco-cyan);
}

.btn-cta-checkout {
  background: linear-gradient(135deg, var(--eco-cyan) 0%, var(--eco-cyan-hover) 100%);
  color: #FFFFFF;
  text-align: center;
  padding: 8px;
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 800;
  text-decoration: none;
  transition: all 0.2s ease;
  box-shadow: 0 3px 10px rgba(2, 132, 199, 0.2);
}

.btn-cta-checkout:hover {
  box-shadow: 0 5px 15px rgba(2, 132, 199, 0.35);
  transform: translateY(-1px);
}

.btn-cta-wa {
  background: var(--eco-wa);
  color: #FFFFFF;
  text-align: center;
  padding: 7px;
  border-radius: 6px;
  font-size: 0.78rem;
  font-weight: 700;
  text-decoration: none;
  transition: background 0.2s ease;
}

.btn-cta-wa:hover {
  background: #128C7E;
}

/* 7. POP-UP MODAL OVERLAY STYLING (INSTAGRAM WEB LAYOUT) */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(10, 25, 47, 0.8);
  backdrop-filter: blur(6px);
  z-index: 999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  box-sizing: border-box;
}

.modal-card {
  background: #FFFFFF;
  border-radius: 16px;
  max-width: 960px;
  width: 100%;
  max-height: 90vh;
  padding: 0;
  overflow: hidden;
  position: relative;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.4);
  animation: modalSlideUp 0.25s ease-out;
}

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

.modal-close-btn {
  position: absolute;
  top: 10px;
  right: 14px;
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid var(--eco-border);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  font-size: 1.5rem;
  line-height: 1;
  color: var(--eco-dark);
  cursor: pointer;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.modal-close-btn:hover {
  background: #FFFFFF;
  color: #EF4444;
}

.ig-modal-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  height: 80vh;
  max-height: 650px;
}

/* SISI KIRI: POSTER CAROUSEL */
.ig-modal-media {
  position: relative;
  background: #0A192F;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.modal-slide-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: none;
}

.modal-slide-img.active { display: block; }

.modal-slider-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid #DDD;
  color: #0F172A;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  cursor: pointer;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}
.modal-slider-btn.prev { left: 10px; }
.modal-slider-btn.next { right: 10px; }

/* SISI KANAN: PANEL DISKUSI & INFO */
.ig-modal-side {
  display: flex;
  flex-direction: column;
  background: #FFFFFF;
  border-left: 1px solid var(--eco-border);
}

.ig-side-header {
  padding: 16px;
  border-bottom: 1px solid var(--eco-border);
}

.ig-user-info {
  display: flex;
  align-items: center;
  gap: 10px;
}

.ig-avatar {
  font-size: 1.5rem;
  background: var(--eco-cyan-light);
  padding: 6px;
  border-radius: 50%;
}

.ig-username {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--eco-dark);
}

.ig-subtext {
  font-size: 0.75rem;
  color: var(--eco-text-muted);
}

/* SCROLLABLE BODY INFO & KOMENTAR */
.ig-side-body {
  padding: 16px;
  flex-grow: 1;
  overflow-y: auto;
}

.ig-event-title {
  font-size: 1.15rem;
  font-weight: 900;
  margin: 0 0 6px 0;
  color: var(--eco-dark);
}

.ig-price-tag {
  font-size: 1.2rem;
  font-weight: 900;
  color: var(--eco-cyan);
  margin-bottom: 12px;
}

.ig-info-table {
  background: #F8FAFC;
  border: 1px solid var(--eco-border);
  padding: 10px;
  border-radius: 8px;
  font-size: 0.78rem;
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 12px;
}

.ig-info-table div { display: flex; justify-content: space-between; }

.ig-desc-box p {
  font-size: 0.82rem;
  color: var(--eco-text-muted);
  line-height: 1.5;
  margin: 0;
}

.ig-divider {
  border: none;
  border-top: 1px solid var(--eco-border);
  margin: 16px 0;
}

/* LIST KOMENTAR */
.ig-comments-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 0.82rem;
}

.comment-item {
  background: #F1F5F9;
  padding: 8px 12px;
  border-radius: 8px;
  line-height: 1.4;
}

.comment-time {
  display: block;
  font-size: 0.68rem;
  color: var(--eco-text-muted);
  margin-top: 2px;
}

.no-comment-text {
  font-size: 0.8rem;
  color: var(--eco-text-muted);
  font-style: italic;
  text-align: center;
}

/* FOOTER INTERAKSI (LIKE & INPUT) */
.ig-side-footer {
  padding: 12px 16px;
  border-top: 1px solid var(--eco-border);
  background: #FFFFFF;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.ig-action-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.btn-ig-like {
  background: none;
  border: none;
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  color: var(--eco-text-main);
  display: flex;
  align-items: center;
  gap: 4px;
}

.btn-ig-like.liked { color: #EF4444; }

.ig-wa-cs-link a {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--eco-wa);
  text-decoration: none;
}

.ig-comment-form {
  display: flex;
  gap: 6px;
}

.ig-input-name {
  width: 30%;
  border: 1px solid var(--eco-border);
  border-radius: 6px;
  padding: 6px 8px;
  font-size: 0.78rem;
  outline: none;
}

.ig-input-text {
  width: 55%;
  border: 1px solid var(--eco-border);
  border-radius: 6px;
  padding: 6px 8px;
  font-size: 0.78rem;
  outline: none;
}

.btn-ig-send {
  width: 15%;
  background: var(--eco-cyan);
  color: #FFF;
  border: none;
  border-radius: 6px;
  font-weight: 800;
  font-size: 0.75rem;
  cursor: pointer;
}

.ig-checkout-btn {
  margin-top: 4px;
}

/* STATE KOSONG */
.ecom-empty-state {
  text-align: center;
  padding: 60px 20px;
  background: var(--eco-card);
  border-radius: var(--eco-radius);
  border: 1px solid var(--eco-border);
}

/* RESPONSIF MOBILE */
@media (max-width: 992px) {
  .ecom-grid-system { grid-template-columns: 1fr; }
  .ecom-sidebar { position: static; max-height: 250px; }
  .ecom-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); }
}

@media (max-width: 768px) {
  .ig-modal-grid {
    grid-template-columns: 1fr;
    height: auto;
    max-height: 85vh;
    overflow-y: auto;
  }
  .ig-modal-media { height: 260px; }
}
