@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700&display=swap');

/* Dynamic Smooth Scroll & Global Reset */
html {
  scroll-behavior: smooth;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Plus Jakarta Sans', sans-serif;
}

body {
  background: #0f172a;
  color: #f8fafc;
  line-height: 1.6;
  overflow-x: hidden;
}

/* Glassmorphism Navigation */
nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.2rem 8%;
  background: rgba(15, 23, 42, 0.75);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  position: sticky;
  top: 0;
  z-index: 1000;
  transition: all 0.3s ease;
}

nav h2 {
  font-size: 1.5rem;
  font-weight: 700;
  background: linear-gradient(135deg, #38bdf8, #818cf8);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

nav ul {
  display: flex;
  list-style: none;
  gap: 2rem;
  align-items: center;
}

nav a {
  color: #94a3b8;
  text-decoration: none;
  font-weight: 500;
  transition: color 0.3s ease;
}

nav a:hover {
  color: #38bdf8;
}

#auth-btn {
  background: linear-gradient(135deg, #6366f1, #4f46e5);
  color: #fff;
  padding: 0.6rem 1.4rem;
  border-radius: 50px;
  box-shadow: 0 4px 14px rgba(99, 102, 241, 0.3);
  transition: all 0.3s ease;
}

#auth-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(99, 102, 241, 0.5);
  color: #fff;
}

/* Modern Sections Layout */
section {
  padding: 5rem 8%;
  max-width: 1200px;
  margin: 0 auto;
}

section h1 {
  font-size: 2.8rem;
  font-weight: 700;
  margin-bottom: 1rem;
  background: linear-gradient(135deg, #ffffff, #94a3b8);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

section h2 {
  font-size: 2rem;
  margin-bottom: 2rem;
  color: #f8fafc;
  position: relative;
  display: inline-block;
}

section h2::after {
  content: '';
  position: absolute;
  bottom: -6px;
  left: 0;
  width: 50%;
  height: 4px;
  background: linear-gradient(90deg, #38bdf8, transparent);
  border-radius: 2px;
}

/* Glassmorphism Cards & Grid */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1.8rem;
  margin-top: 1.5rem;
}

.card {
  background: rgba(30, 41, 59, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  padding: 1.2rem;
  text-align: center;
  backdrop-filter: blur(8px);
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.card:hover {
  transform: translateY(-8px);
  border-color: rgba(56, 189, 248, 0.4);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.3);
}

.card img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-radius: 12px;
  margin-bottom: 1rem;
}

.card h3 {
  font-size: 1.1rem;
  color: #f1f5f9;
}

.card p {
  color: #94a3b8;
  font-size: 0.9rem;
}

.card a {
  display: inline-block;
  margin-top: 0.6rem;
  color: #38bdf8;
  text-decoration: none;
  font-weight: 500;
}

.card button {
  background: #ef4444;
  color: #fff;
  border: none;
  padding: 0.5rem 1rem;
  border-radius: 8px;
  cursor: pointer;
  margin-top: 1rem;
  transition: background 0.3s ease;
}

.card button:hover {
  background: #dc2626;
}

/* Form Admin Styling */
form {
  background: rgba(30, 41, 59, 0.5);
  padding: 1.5rem;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  display: flex;
  gap: 1rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}

form input {
  flex: 1;
  padding: 0.8rem;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(15, 23, 42, 0.5);
  color: #f8fafc;
}

/* =========================================
   LOADING SCREEN POPUP STYLING
========================================= */

/* Container Full Overlay Gelap + Blur */
#loading-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  background-color: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 99999;
  transition: opacity 0.5s ease, visibility 0.5s ease;
}

/* Kotak Popup Putih di Tengah */
.loader-content {
  background: #ffffff;
  padding: 2rem 2.5rem;
  border-radius: 16px;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.4), 0 8px 10px -6px rgba(0, 0, 0, 0.3);
  text-align: center;
  min-width: 220px;
  animation: popupAnim 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

/* Angka Counter Progress (1% - 100%) */
.loader-progress {
  font-size: 2.5rem;
  font-weight: 800;
  color: #0f172a;
  line-height: 1;
  margin-bottom: 0.5rem;
}

/* Teks Keterangan Loading Website... */
.loader-text {
  font-size: 0.875rem;
  font-weight: 600;
  color: #64748b;
  letter-spacing: 0.5px;
}

/* Animasi Popup saat pertama muncul */
@keyframes popupAnim {
  from {
    transform: scale(0.8);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

/* Class pembantu untuk menyembunyikan loading screen */
#loading-screen.hide {
  opacity: 0;
  visibility: hidden;
}