/* ==========================================================================
   exosplash.com — Clean Black & White (Putih Hitam) Design System v8
   Minimalist, High-Contrast Monochrome Aesthetics
   ========================================================================== */

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

:root {
  /* Outer & Inner Backgrounds (Clean Light Monochrome) */
  --bg-outer:      linear-gradient(135deg, #FAFAFA 0%, #F4F4F5 50%, #E4E4E7 100%);
  --bg:            #FFFFFF;
  --bg-soft:       #F4F4F5;
  --surface:       #FFFFFF;
  --surface-2:     #FAFAFA;
  --surface-hover: #F4F4F5;
  
  --line:          #E4E4E7;
  --line-strong:   #000000;

  --text:          #000000;
  --text-muted:    #52525B;
  --text-dim:      #A1A1AA;

  /* Black & White Accent Tokens */
  --black:         #000000;
  --dark-charcoal: #18181B;
  --mint:          #000000;
  --mint-dark:     #18181B;
  --mint-glow:     rgba(0, 0, 0, 0.08);
  
  --magenta:       #000000;
  --magenta-glow:  rgba(0, 0, 0, 0.08);
  
  --amber:         #27272A;
  --amber-glow:    rgba(0, 0, 0, 0.08);
  
  --danger:        #DC2626;
  --cyan:          #000000;
  --purple:        #000000;
  --purple-glow:   rgba(0, 0, 0, 0.08);

  --pink-gradient: linear-gradient(135deg, #18181B 0%, #000000 100%);

  /* Typography */
  --f-display: 'Outfit', system-ui, -apple-system, sans-serif;
  --f-body: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;

  /* Geometry & Shadows */
  --radius-pill: 999px;
  --radius-xl:   24px;
  --radius-lg:   16px;
  --radius-md:   12px;
  --radius-sm:   8px;

  --shadow-card: 0 4px 20px rgba(0, 0, 0, 0.04), 0 1px 3px rgba(0, 0, 0, 0.02);
  --shadow-lift: 0 16px 36px rgba(0, 0, 0, 0.1);
  --shadow-soft: 0 2px 12px rgba(0, 0, 0, 0.04);
}

*, *::before, *::after {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg-outer);
  color: var(--text);
  font-family: var(--f-body);
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}

body {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
}

#bg-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}

@media (max-width: 640px) {
  body { padding: 8px; }
}

h1, h2, h3, h4, h5 {
  font-family: var(--f-display);
  margin: 0;
  line-height: 1.15;
  letter-spacing: -0.03em;
  color: var(--text);
}

p {
  margin: 0;
  color: var(--text-muted);
  line-height: 1.65;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font-family: var(--f-body);
  cursor: pointer;
  border: none;
  background: none;
  color: inherit;
}

input, select, textarea {
  font-family: var(--f-body);
  color: var(--text);
  background: #FFFFFF;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 14px 18px;
  font-size: 14.5px;
  outline: none;
  transition: all 0.2s ease;
}

input:focus, select:focus, textarea:focus {
  border-color: #000000;
  box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.1);
  background: #FFFFFF;
}

/* App Central Frame — Clean White Canvas */
.app {
  width: 100%;
  max-width: 1140px;
  min-height: 85vh;
  background: #FFFFFF;
  border-radius: var(--radius-xl);
  border: 1px solid var(--line);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.06);
  overflow: hidden;
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
}

.wrap {
  width: 100%;
  margin: 0 auto;
}

/* Base Panel */
.panel {
  background: #FFFFFF;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-bottom: 20px;
  box-shadow: var(--shadow-card);
  transition: all 0.22s ease;
}

.panel:hover {
  border-color: #000000;
  box-shadow: var(--shadow-lift);
}

/* Button System — High Contrast Black & White */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 15px 30px;
  border-radius: var(--radius-pill);
  font-family: var(--f-display);
  font-weight: 700;
  font-size: 15px;
  letter-spacing: -0.01em;
  position: relative;
  overflow: hidden;
  transition: all 0.22s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.btn:active {
  transform: scale(0.97);
}

/* Primary Black Button */
.btn-primary {
  background: #000000;
  color: #FFFFFF;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.18);
  border: 1px solid #000000;
}

.btn-primary:hover {
  background: #27272A;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.28);
  transform: translateY(-2px);
}

.btn-ghost {
  background: #FFFFFF;
  border: 1px solid var(--line);
  color: #000000;
  box-shadow: var(--shadow-soft);
}

.btn-ghost:hover {
  border-color: #000000;
  background: #F4F4F5;
  color: #000000;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08);
  transform: translateY(-2px);
}

.btn-danger {
  background: #DC2626;
  color: #FFFFFF;
  border: 1px solid #DC2626;
}

.btn-danger:hover {
  background: #B91C1C;
  transform: translateY(-2px);
}

.btn-block { width: 100%; }
.btn-sm { padding: 10px 20px; font-size: 13.5px; }
.btn[disabled] { opacity: 0.4; pointer-events: none; }

/* Badges — Clean Monochrome */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  font-size: 11.5px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.badge-success { background: #000000; color: #FFFFFF; border: 1px solid #000000; }
.badge-warning { background: #F4F4F5; color: #000000; border: 1px solid #000000; }
.badge-danger  { background: #DC2626; color: #FFFFFF; border: 1px solid #DC2626; }
.badge-primary { background: #F4F4F5; color: #000000; border: 1px solid #E4E4E7; }

/* Animations */
.reveal {
  animation: reveal-up 0.4s cubic-bezier(0.16, 1, 0.3, 1) both;
}

@keyframes reveal-up {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Toast — Sleek Dark Pill */
#toast {
  position: fixed;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%) translateY(80px);
  background: #000000;
  color: #FFFFFF;
  padding: 14px 26px;
  border-radius: var(--radius-pill);
  font-weight: 600;
  font-size: 14px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.25);
  z-index: 9999;
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

#toast.show {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

#toast.error {
  background: #DC2626;
}

/* Utility */
.hidden { display: none !important; }

/* Modal Overlay — Fullscreen Backdrop */
.modal-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 5000;
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  align-items: center;
  justify-content: center;
  padding: 24px;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.modal-backdrop.show {
  display: flex;
  opacity: 1;
}

/* Modal Card */
.modal {
  background: #FFFFFF;
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.18);
  padding: 36px 32px;
  width: 100%;
  max-width: 440px;
  max-height: 90vh;
  overflow-y: auto;
  animation: modal-pop 0.3s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.modal-wide {
  max-width: 480px;
}

@keyframes modal-pop {
  from { opacity: 0; transform: scale(0.95) translateY(12px); }
  to   { opacity: 1; transform: scale(1) translateY(0); }
}

/* Modal Fields */
.modal-field {
  margin-bottom: 16px;
}

.modal-field label {
  display: block;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--text-muted);
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.modal-field input {
  width: 100%;
}

/* Modal Actions */
.modal-actions {
  display: flex;
  gap: 12px;
  margin-top: 20px;
}

.modal-actions .btn {
  flex: 1;
}

@media (max-width: 520px) {
  .modal {
    padding: 28px 20px;
    border-radius: var(--radius-lg);
  }
}

/* ==========================================
   ANIMATED POPUP MODAL & ENHANCED TOAST SYSTEM
   ========================================== */
.exo-popup-overlay {
  position: fixed;
  inset: 0;
  z-index: 10000;
  background: rgba(5, 8, 18, 0.75);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.exo-popup-overlay.active {
  display: flex;
  opacity: 1;
  pointer-events: auto;
}

.exo-popup-card {
  width: 100%;
  max-width: 440px;
  background: linear-gradient(135deg, rgba(20, 24, 40, 0.95), rgba(12, 14, 25, 0.98));
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 20px;
  padding: 32px 28px 28px;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.6), 0 0 40px rgba(99, 102, 241, 0.15);
  text-align: center;
  transform: scale(0.8) translateY(24px);
  opacity: 0;
  transition: transform 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.25s ease;
}

.exo-popup-overlay.active .exo-popup-card {
  transform: scale(1) translateY(0);
  opacity: 1;
}

/* Icon Ring */
.exo-popup-icon-wrap {
  width: 68px;
  height: 68px;
  margin: 0 auto 20px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  animation: exoPulseRing 2s infinite;
}

.exo-popup-icon-wrap svg {
  width: 32px;
  height: 32px;
  stroke-width: 2.2;
}

/* Variant styles */
.exo-popup-icon-wrap.success {
  background: rgba(16, 185, 129, 0.15);
  color: #10B981;
  border: 2px solid rgba(16, 185, 129, 0.4);
  box-shadow: 0 0 25px rgba(16, 185, 129, 0.3);
}

.exo-popup-icon-wrap.error {
  background: rgba(239, 68, 68, 0.15);
  color: #EF4444;
  border: 2px solid rgba(239, 68, 68, 0.4);
  box-shadow: 0 0 25px rgba(239, 68, 68, 0.3);
}

.exo-popup-icon-wrap.info {
  background: rgba(99, 102, 241, 0.15);
  color: #818CF8;
  border: 2px solid rgba(99, 102, 241, 0.4);
  box-shadow: 0 0 25px rgba(99, 102, 241, 0.3);
}

.exo-popup-icon-wrap.confirm {
  background: rgba(236, 72, 153, 0.15);
  color: #F472B6;
  border: 2px solid rgba(236, 72, 153, 0.4);
  box-shadow: 0 0 25px rgba(236, 72, 153, 0.3);
}

@keyframes exoPulseRing {
  0% { transform: scale(1); }
  50% { transform: scale(1.05); }
  100% { transform: scale(1); }
}

.exo-popup-title {
  font-size: 20px;
  font-weight: 700;
  color: #FFFFFF;
  margin: 0 0 10px 0;
  letter-spacing: -0.01em;
}

.exo-popup-message {
  font-size: 14px;
  line-height: 1.55;
  color: #94A3B8;
  margin-bottom: 24px;
  word-break: break-word;
}

.exo-popup-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
}

.exo-popup-btn {
  flex: 1;
  padding: 12px 20px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.exo-popup-btn.primary {
  background: linear-gradient(135deg, #6366F1, #4F46E5);
  color: #FFFFFF;
  box-shadow: 0 4px 16px rgba(99, 102, 241, 0.4);
}

.exo-popup-btn.primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 22px rgba(99, 102, 241, 0.55);
}

.exo-popup-btn.secondary {
  background: rgba(255, 255, 255, 0.08);
  color: #CBD5E1;
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.exo-popup-btn.secondary:hover {
  background: rgba(255, 255, 255, 0.15);
  color: #FFFFFF;
}

.exo-popup-btn:active {
  transform: scale(0.97);
}

/* Enhanced Animated Toast Card */
#toast {
  position: fixed;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%) translateY(90px) scale(0.9);
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(30, 41, 59, 0.96));
  color: #F8FAFC;
  padding: 14px 22px;
  border-radius: 16px;
  font-weight: 600;
  font-size: 14px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45), 0 0 20px rgba(99, 102, 241, 0.2);
  z-index: 10050;
  opacity: 0;
  pointer-events: none;
  display: flex;
  align-items: center;
  gap: 12px;
  transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.3s ease;
  overflow: hidden;
  max-width: 90vw;
}

#toast.show {
  transform: translateX(-50%) translateY(0) scale(1);
  opacity: 1;
  pointer-events: auto;
}

#toast.error {
  border-color: rgba(239, 68, 68, 0.5);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45), 0 0 25px rgba(239, 68, 68, 0.3);
}

#toast .toast-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(16, 185, 129, 0.2);
  color: #10B981;
  flex-shrink: 0;
}

#toast.error .toast-icon {
  background: rgba(239, 68, 68, 0.2);
  color: #EF4444;
}

#toast .toast-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  height: 3px;
  background: linear-gradient(90deg, #6366F1, #10B981);
  width: 100%;
}

#toast.error .toast-bar {
  background: linear-gradient(90deg, #EF4444, #F59E0B);
}

#toast.show .toast-bar {
  animation: toastProgress 2.8s linear forwards;
}

@keyframes toastProgress {
  from { width: 100%; }
  to { width: 0%; }
}

