/* ==========================================================================
   Media Pembelajaran Interaktif: Sistem Persamaan Linier Dua Variabel (SPLDV)
   Khusus Murid Kelas X NKPI (Nautika Kapal Penangkap Ikan) SMK Negeri 1 Mundu
   Styles & Nautical Maritime Theme
   ========================================================================== */

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

:root {
  --primary-navy: #091e3a;
  --secondary-navy: #102a4e;
  --ocean-blue: #0284c7;
  --deep-cyan: #0077b6;
  --aqua-cyan: #00b4d8;
  --marine-teal: #0d9488;
  --sea-mint: #10b981;
  --maritime-gold: #f59e0b;
  --coral-red: #ef4444;
  --bg-slate: #f8fafc;
  --text-main: #0f172a;
}

* {
  box-sizing: border-box;
}

body {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background-color: #f8fafc;
  color: var(--text-main);
  overflow-x: hidden;
  scroll-behavior: smooth;
  margin: 0;
  padding: 0;
}

.font-mono-math {
  font-family: 'JetBrains Mono', monospace;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: #f1f5f9;
}
::-webkit-scrollbar-thumb {
  background: #94a3b8;
  border-radius: 9999px;
}
::-webkit-scrollbar-thumb:hover {
  background: #64748b;
}

/* Glassmorphism Styles */
.glass-panel {
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(226, 232, 240, 0.9);
}

.glass-nav {
  background: rgba(9, 30, 58, 0.96);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.glass-card-hover {
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}
.glass-card-hover:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 32px -8px rgba(10, 30, 60, 0.12);
}

/* Nautical Maritime Gradients */
.gradient-marine {
  background: linear-gradient(135deg, #091e3a 0%, #0f3969 50%, #0284c7 100%);
}

.gradient-ocean-deep {
  background: linear-gradient(180deg, #07172c 0%, #0e294b 100%);
}

.gradient-gold {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
}

.gradient-mesh {
  background-image: 
    radial-gradient(at 10% 20%, rgba(0, 180, 216, 0.12) 0px, transparent 50%),
    radial-gradient(at 90% 10%, rgba(16, 185, 129, 0.10) 0px, transparent 50%),
    radial-gradient(at 50% 90%, rgba(9, 30, 58, 0.08) 0px, transparent 50%);
}

/* Radar & Pulse Animation */
@keyframes radarSweep {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

.radar-sweep {
  animation: radarSweep 4s linear infinite;
}

@keyframes softPulse {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(0, 180, 216, 0.4);
  }
  50% {
    box-shadow: 0 0 0 12px rgba(0, 180, 216, 0);
  }
}
.pulse-glow {
  animation: softPulse 2.5s infinite;
}

/* Floating Animation */
@keyframes waveFloat {
  0%, 100% {
    transform: translateY(0px) rotate(0deg);
  }
  50% {
    transform: translateY(-6px) rotate(1deg);
  }
}
.wave-float {
  animation: waveFloat 3.5s ease-in-out infinite;
}

/* Interactive Cartesian Canvas */
#cartesianCanvas {
  background-color: #0c1a2e;
  border-radius: 0.75rem;
  box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.4);
  touch-action: none;
}

/* Active navigation item indicator */
.nav-btn-active {
  background-color: rgba(0, 180, 216, 0.2) !important;
  color: #38bdf8 !important;
  font-weight: 700 !important;
  border-bottom: 2px solid #38bdf8 !important;
}

/* Tab active style */
.tab-btn-active {
  background-color: #0284c7 !important;
  color: #ffffff !important;
  box-shadow: 0 4px 12px rgba(2, 132, 199, 0.3) !important;
}

/* KaTeX custom spacing */
.katex-display {
  margin: 0.5em 0 !important;
  overflow-x: auto;
  overflow-y: hidden;
  padding: 4px 0;
}

/* Certificate Styles */
.certificate-frame {
  background: #ffffff;
  border: 12px solid #091e3a;
  outline: 3px dashed #d97706;
  outline-offset: -8px;
  position: relative;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.certificate-seal {
  background: radial-gradient(circle, #fbbf24 0%, #d97706 70%, #b45309 100%);
  box-shadow: 0 6px 18px rgba(217, 119, 6, 0.4);
}

/* Print Styles for Certificate & Reports */
@media print {
  body {
    background: #ffffff !important;
    color: #000000 !important;
  }
  
  nav, footer, .no-print, button, .action-buttons {
    display: none !important;
  }

  #page-hasil {
    display: block !important;
  }

  .certificate-print-container {
    page-break-inside: avoid;
    box-shadow: none !important;
    border: 8px solid #091e3a !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 auto !important;
  }
}

/* Custom Checkbox / Radio styling */
.custom-radio {
  appearance: none;
  width: 20px;
  height: 20px;
  border: 2px solid #cbd5e1;
  border-radius: 50%;
  outline: none;
  transition: all 0.2s ease;
  cursor: pointer;
  display: inline-grid;
  place-content: center;
}

.custom-radio:checked {
  border-color: #0284c7;
  background-color: #0284c7;
}

.custom-radio:checked::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: white;
}
