/* Custom Styling for Pondok Pesantren Darul Muttaqin Batu */

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

:root {
  --primary-emerald: #0b6b4e;
  --primary-light: #109b72;
  --primary-dark: #074734;
  --accent-gold: #e28e18;
  --accent-gold-light: #f59e0b;
  --sidebar-w: 260px;
}

body {
  font-family: 'Plus Jakarta Sans', sans-serif;
  background-color: #f8fafc;
  color: #1e293b;
  overflow-x: hidden;
}

.font-arabic {
  font-family: 'Amiri', serif;
}

/* Islamic Geometric Background Pattern */
.islamic-pattern-bg {
  background-color: #072a20;
  background-image: 
    radial-gradient(circle at 50% 50%, rgba(16, 155, 114, 0.25) 0%, transparent 65%),
    radial-gradient(circle at 10% 20%, rgba(226, 142, 24, 0.15) 0%, transparent 40%),
    radial-gradient(circle at 90% 80%, rgba(16, 155, 114, 0.18) 0%, transparent 45%),
    url("data:image/svg+xml,%3Csvg width='80' height='80' viewBox='0 0 80 80' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23109b72' fill-opacity='0.08'%3E%3Cpath d='M40 0l40 40-40 40L0 40 40 0zm0 10l30 30-30 30-30-30 30-30zm0 10l20 20-20 20-20-20 20-20z'/%3E%3C/g%3E%3C/svg%3E");
  background-attachment: fixed;
}

.islamic-card-pattern {
  background-image: url("data:image/svg+xml,%3Csvg width='40' height='40' viewBox='0 0 40 40' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23059669' fill-opacity='0.03'%3E%3Cpath d='M20 0l20 20-20 20L0 20 20 0zm0 5l15 15-15 15-15-15 15-15z'/%3E%3C/g%3E%3C/svg%3E");
}

/* Neumorphism Luxury Login System (Matching User Screenshot Example) */
.neu-bg {
  background-color: #ebf0f7;
  background-image: 
    radial-gradient(circle at 15% 15%, rgba(13, 148, 136, 0.08) 0%, transparent 45%),
    radial-gradient(circle at 85% 85%, rgba(2, 132, 199, 0.08) 0%, transparent 45%);
}

.neu-card {
  background: #ebf0f7;
  border-radius: 40px;
  box-shadow: 20px 20px 50px #c5d0e0, -20px -20px 50px #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.6);
}

.neu-circle-outer {
  width: 116px;
  height: 116px;
  background: #ebf0f7;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 10px 10px 24px #c5d0e0, -10px -10px 24px #ffffff;
  margin: 0 auto;
  border: 1px solid rgba(255, 255, 255, 0.75);
}

.neu-circle-inner {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #ffffff 0%, #f0fdf4 70%, #dcfce7 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12px;
  box-shadow: inset 2px 2px 5px rgba(0, 0, 0, 0.08), inset -2px -2px 6px rgba(255, 255, 255, 0.9), 0 4px 12px rgba(6, 78, 59, 0.15);
  border: 2px solid rgba(16, 185, 129, 0.35);
}

.neu-input-pill {
  background: #ebf0f7;
  box-shadow: inset 5px 5px 10px #c8d3e2, inset -5px -5px 10px #ffffff;
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.4);
  transition: all 0.25s ease;
}

.neu-input-pill:focus-within {
  box-shadow: inset 6px 6px 12px #bccad9, inset -6px -6px 12px #ffffff, 0 0 0 2px rgba(13, 148, 136, 0.35);
}

.neu-btn-primary {
  background: linear-gradient(135deg, #0284c7 0%, #0d9488 50%, #059669 100%);
  box-shadow: 6px 6px 16px rgba(13, 148, 136, 0.35), -4px -4px 10px #ffffff;
  border-radius: 9999px;
  transition: all 0.25s ease;
}

.neu-btn-primary:hover {
  transform: translateY(-1.5px);
  box-shadow: 8px 10px 22px rgba(13, 148, 136, 0.45), -6px -6px 14px #ffffff;
}

.neu-btn-primary:active {
  transform: translateY(1px);
  box-shadow: inset 3px 3px 6px rgba(0, 0, 0, 0.25);
}

.neu-btn-demo {
  background: #ebf0f7;
  box-shadow: 4px 4px 8px #c8d3e2, -4px -4px 8px #ffffff;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.6);
  transition: all 0.2s ease;
}

.neu-btn-demo:hover {
  box-shadow: 6px 6px 12px #c8d3e2, -6px -6px 12px #ffffff;
  transform: translateY(-1px);
}

.neu-btn-demo:active,
.neu-btn-demo.active {
  box-shadow: inset 3px 3px 6px #c8d3e2, inset -3px -3px 6px #ffffff;
  transform: translateY(0);
}

.glass-dark {
  background: rgba(13, 49, 38, 0.82);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

/* Glowing Border & Floating Animation */
@keyframes floatAnim {
  0%, 100% {
    transform: translateY(0px) rotate(0deg);
  }
  50% {
    transform: translateY(-8px) rotate(1deg);
  }
}

.animate-float {
  animation: floatAnim 6s ease-in-out infinite;
}

@keyframes pulseGlow {
  0%, 100% {
    box-shadow: 0 0 25px rgba(16, 155, 114, 0.35);
  }
  50% {
    box-shadow: 0 0 45px rgba(226, 142, 24, 0.45);
  }
}

.animate-glow {
  animation: pulseGlow 4s ease-in-out infinite;
}

/* Particles Canvas */
#particles-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
}

/* Scrollbar Customization */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: #f1f5f9;
}
::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* Luxury & Clean Table Styling (Strictly Rata Kiri) */
.custom-table th,
.custom-table td {
  text-align: left;
}

.custom-table th {
  font-weight: 700;
  letter-spacing: 0.03em;
}

.custom-table tr {
  transition: all 0.15s ease-in-out;
}

.custom-table tr:hover td {
  background-color: #f8fafc;
}

/* Luxury Islamic Badges with Refined Micro-borders */
.badge-target-ideal {
  background-color: #f0fdf4;
  color: #166534;
  border: 1px solid #bbf7d0;
  box-shadow: 0 1px 2px rgba(22, 101, 52, 0.05);
}

.badge-target-under {
  background-color: #fef2f2;
  color: #991b1b;
  border: 1px solid #fecaca;
  box-shadow: 0 1px 2px rgba(153, 27, 27, 0.05);
}

.badge-target-over {
  background-color: #eff6ff;
  color: #1e40af;
  border: 1px solid #bfdbfe;
  box-shadow: 0 1px 2px rgba(30, 64, 175, 0.05);
}

/* Print Stylesheet for Official Pesantren Documents */
@media print {
  body {
    background: #ffffff !important;
    color: #000000 !important;
  }
  .no-print, header, aside, .sidebar-wrapper, #toast-container, .modal-backdrop, .btn-action, #payroll-settings-modal {
    display: none !important;
  }
  #payroll-slip-modal {
    display: block !important;
    position: static !important;
    background: transparent !important;
    padding: 0 !important;
    margin: 0 !important;
    width: 100% !important;
  }
  #payroll-slip-modal > div {
    max-width: 100% !important;
    box-shadow: none !important;
    border: none !important;
  }
  #payroll-slip-modal .px-6.py-4.border-b,
  #payroll-slip-modal .px-6.py-3.5.border-t {
    display: none !important;
  }
  #slip-print-card {
    border: none !important;
    box-shadow: none !important;
    padding: 0 !important;
    margin: 0 !important;
    width: 100% !important;
  }
  main, #main-content {
    margin: 0 !important;
    padding: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
  }
  .print-only {
    display: block !important;
  }
  .print-card {
    border: none !important;
    box-shadow: none !important;
    padding: 0 !important;
  }
  .print-kop {
    display: flex !important;
    border-bottom: 3px double #000 !important;
    padding-bottom: 12px !important;
    margin-bottom: 20px !important;
  }
  table {
    border-collapse: collapse !important;
    width: 100% !important;
  }
  table th, table td {
    border: 1px solid #333 !important;
    padding: 6px 8px !important;
    font-size: 10pt !important;
  }
  .page-break {
    page-break-before: always;
  }
}

.print-only {
  display: none;
}
