/* ==============================================================================
   Custom Styles for Feng Shui & Candidate Compatibility System
   Developed for Mr. NGO SOMETHEA (លោក ង៉ោ សុមេធា)
   ============================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Kantumruy+Pro:ital,wght@0,300..700;1,300..700&display=swap');

:root {
  font-family: 'Kantumruy Pro', 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --gold-primary: #d97706;
  --gold-light: #fbbf24;
  --gold-dark: #b45309;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Custom scrollbars */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: hsl(var(--b2, 210 20% 95%));
}

::-webkit-scrollbar-thumb {
  background: hsl(var(--bc, 215 28% 17%) / 0.25);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: hsl(var(--bc, 215 28% 17%) / 0.45);
}

/* Glassmorphism card effects */
.glass-card {
  background: rgba(255, 255, 255, 0.75);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.35);
}

[data-theme="dark"] .glass-card,
[data-theme="luxury"] .glass-card {
  background: rgba(23, 28, 38, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Luxury Gold Accents */
.gold-gradient-bg {
  background: linear-gradient(135deg, #fef3c7 0%, #fde68a 50%, #f59e0b 100%);
  color: #78350f;
}

[data-theme="dark"] .gold-gradient-bg,
[data-theme="luxury"] .gold-gradient-bg {
  background: linear-gradient(135deg, #78350f 0%, #92400e 50%, #b45309 100%);
  color: #fef3c7;
}

.gold-border {
  border-color: #f59e0b;
}

.gold-text {
  color: #d97706;
}

/* Five Elements Tag Colors */
.element-tag-wood {
  background-color: #d1fae5;
  color: #065f46;
  border: 1px solid #10b981;
}

.element-tag-fire {
  background-color: #fee2e2;
  color: #991b1b;
  border: 1px solid #ef4444;
}

.element-tag-earth {
  background-color: #fef3c7;
  color: #92400e;
  border: 1px solid #f59e0b;
}

.element-tag-metal {
  background-color: #f3f4f6;
  color: #374151;
  border: 1px solid #9ca3af;
}

.element-tag-water {
  background-color: #dbeafe;
  color: #1e40af;
  border: 1px solid #3b82f6;
}

/* Live Active Pulse for Current Hour */
.active-hour-card {
  position: relative;
  border: 2px solid #10b981 !important;
  box-shadow: 0 0 15px rgba(16, 185, 129, 0.35);
}

.pulse-badge {
  animation: pulse-glow 2s infinite;
}

@keyframes pulse-glow {
  0% {
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
  }
  70% {
    box-shadow: 0 0 0 10px rgba(16, 185, 129, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
  }
}

/* Drag and Drop Zone */
.dropzone {
  border: 2px dashed #9ca3af;
  transition: all 0.2s ease;
}

.dropzone.dragover {
  border-color: #3b82f6;
  background-color: rgba(59, 130, 246, 0.08);
}

/* SweetAlert2 Modal & Button Styling Fixes (Fixes invisible buttons in delete dialog) */
.swal2-popup {
  border-radius: 1.25rem !important;
  font-family: 'Kantumruy Pro', 'Inter', sans-serif !important;
  padding: 1.75rem !important;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.2), 0 8px 10px -6px rgba(0, 0, 0, 0.1) !important;
}

[data-theme="dark"] .swal2-popup,
[data-theme="luxury"] .swal2-popup {
  background: #1e293b !important;
  color: #f8fafc !important;
}

.swal2-actions {
  display: flex !important;
  justify-content: center !important;
  gap: 12px !important;
  margin-top: 1.75rem !important;
  width: 100% !important;
}

/* Confirm Button (Delete) - High contrast solid red with crisp white text */
.swal2-confirm,
button.swal2-confirm {
  background-color: #dc2626 !important; /* solid red-600 */
  color: #ffffff !important;
  font-family: 'Kantumruy Pro', sans-serif !important;
  font-size: 0.875rem !important;
  font-weight: 700 !important;
  padding: 0.65rem 1.4rem !important;
  border-radius: 0.6rem !important;
  border: 1px solid #b91c1c !important;
  box-shadow: 0 4px 6px -1px rgba(220, 38, 38, 0.35) !important;
  cursor: pointer !important;
  transition: all 0.2s ease !important;
  opacity: 1 !important;
}

.swal2-confirm:hover,
button.swal2-confirm:hover {
  background-color: #b91c1c !important;
  transform: translateY(-1px) !important;
}

/* Cancel Button - High contrast solid slate with clear dark/light text */
.swal2-cancel,
button.swal2-cancel {
  background-color: #e2e8f0 !important; /* solid slate-200 */
  color: #1e293b !important;            /* dark slate-800 */
  font-family: 'Kantumruy Pro', sans-serif !important;
  font-size: 0.875rem !important;
  font-weight: 700 !important;
  padding: 0.65rem 1.4rem !important;
  border-radius: 0.6rem !important;
  border: 1px solid #cbd5e1 !important;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05) !important;
  cursor: pointer !important;
  transition: all 0.2s ease !important;
  opacity: 1 !important;
}

.swal2-cancel:hover,
button.swal2-cancel:hover {
  background-color: #cbd5e1 !important;
  color: #0f172a !important;
}

[data-theme="dark"] .swal2-cancel,
[data-theme="luxury"] .swal2-cancel {
  background-color: #334155 !important;
  color: #f8fafc !important;
  border-color: #475569 !important;
}

[data-theme="dark"] .swal2-cancel:hover,
[data-theme="luxury"] .swal2-cancel:hover {
  background-color: #475569 !important;
  color: #ffffff !important;
}

/* Remedy Box High Contrast Styles */
.remedy-box-header {
  color: #78350f !important; /* Deep dark amber/brown */
  font-weight: 800 !important;
}

[data-theme="dark"] .remedy-box-header,
[data-theme="luxury"] .remedy-box-header {
  color: #fde68a !important; /* Crisp light gold */
}

/* Activity Specific Badges */
.activity-badge-buy {
  background-color: #f0fdf4;
  color: #166534;
  border: 1px solid #86efac;
}

.activity-badge-sell {
  background-color: #eff6ff;
  color: #1e40af;
  border: 1px solid #93c5fd;
}

.activity-badge-meet {
  background-color: #fefce8;
  color: #854d0e;
  border: 1px solid #fde047;
}

.activity-badge-avoid {
  background-color: #fef2f2;
  color: #991b1b;
  border: 1px solid #fca5a5;
}

/* Print Styles */
@media print {
  .no-print {
    display: none !important;
  }
  
  body {
    background: #ffffff !important;
    color: #000000 !important;
  }

  .drawer-content {
    margin: 0 !important;
    padding: 0 !important;
  }

  .card {
    box-shadow: none !important;
    border: 1px solid #e5e7eb !important;
    break-inside: avoid;
  }

  .print-only {
    display: block !important;
  }
}

.print-only {
  display: none;
}
