/* ========================================================
   SMKN 2 PURWOKERTO - MODERN DESIGN SYSTEM & STYLESHEET
   ======================================================== */

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

:root {
  /* Color Palette - Light Mode Default */
  --primary: #0284c7;
  --primary-hover: #0369a1;
  --primary-light: #e0f2fe;
  --primary-dark: #075985;
  --secondary: #0f172a;
  --accent: #f59e0b;
  --accent-hover: #d97706;
  --success: #10b981;
  --danger: #ef4444;
  --warning: #f59e0b;
  
  --bg-main: #f8fafc;
  --bg-card: #ffffff;
  --bg-glass: rgba(255, 255, 255, 0.85);
  --bg-glass-card: rgba(255, 255, 255, 0.7);
  --border-color: #e2e8f0;
  --border-glass: rgba(226, 232, 240, 0.8);
  
  --text-main: #0f172a;
  --text-muted: #64748b;
  --text-light: #94a3b8;
  
  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
  --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
  --shadow-glow: 0 0 25px rgba(2, 132, 199, 0.25);

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-full: 9999px;
  
  --font-sans: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Dark Mode Variables */
[data-theme="dark"] {
  --bg-main: #090d16;
  --bg-card: #131c2e;
  --bg-glass: rgba(15, 23, 42, 0.88);
  --bg-glass-card: rgba(19, 28, 46, 0.75);
  --border-color: #1e293b;
  --border-glass: rgba(51, 65, 85, 0.5);
  
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --text-light: #64748b;
  
  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.4);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.5);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.6);
  --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.7);
  --shadow-glow: 0 0 30px rgba(56, 189, 248, 0.2);
}

/* Global Reset */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-main);
  color: var(--text-main);
  line-height: 1.6;
  overflow-x: hidden;
  transition: background-color 0.3s ease, color 0.3s ease;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: var(--transition);
}
a:hover {
  color: var(--primary-hover);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

ul {
  list-style: none;
}

/* Typography Helpers */
h1, h2, h3, h4, h5, h6 {
  color: var(--text-main);
  font-weight: 700;
  line-height: 1.25;
}

.gradient-text {
  background: linear-gradient(135deg, var(--primary) 0%, #38bdf8 50%, var(--accent) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Container */
.container {
  width: 100%;
  max-width: 1240px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}

/* Header & Glass Navbar */
.top-bar {
  background: #0f172a;
  color: #94a3b8;
  font-size: 0.825rem;
  padding: 0.5rem 0;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.top-bar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.top-bar-links {
  display: flex;
  gap: 1.25rem;
  align-items: center;
}
.top-bar-links a {
  color: #cbd5e1;
  font-size: 0.8rem;
  display: flex;
  align-items: center;
  gap: 0.35rem;
}
.top-bar-links a:hover {
  color: #38bdf8;
}

.main-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--bg-glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-glass);
  transition: var(--transition);
}

.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.35rem 0;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.brand-logo img {
  height: 36px;
  width: auto;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.nav-item {
  position: relative;
}

.nav-link {
  color: var(--text-main);
  font-weight: 600;
  font-size: 0.85rem;
  padding: 0.3rem 0.5rem;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  gap: 0.35rem;
}
.nav-link:hover, .nav-link.active {
  color: var(--primary);
}

/* Dropdown */
.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 220px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-xl);
  padding: 0.5rem;
  display: none;
  opacity: 0;
  transform: translateY(10px);
  transition: var(--transition);
  z-index: 1050;
}
.nav-item:hover .dropdown-menu {
  display: block;
  opacity: 1;
  transform: translateY(0);
}
.dropdown-item {
  display: block;
  padding: 0.55rem 0.85rem;
  color: var(--text-main);
  font-size: 0.875rem;
  font-weight: 500;
  border-radius: var(--radius-sm);
  transition: var(--transition);
}
.dropdown-item:hover {
  background: var(--primary-light);
  color: var(--primary-dark);
}
[data-theme="dark"] .dropdown-item:hover {
  background: rgba(2, 132, 199, 0.2);
  color: #38bdf8;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Search Trigger & Dark Mode Buttons */
.btn-icon {
  width: 34px;
  height: 34px;
  font-size: 0.85rem;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-color);
  background: var(--bg-card);
  color: var(--text-main);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition);
}
.btn-icon:hover {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
  box-shadow: var(--shadow-glow);
}

.mobile-toggle {
  display: none;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.65rem 1.35rem;
  font-weight: 600;
  font-size: 0.925rem;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: var(--transition);
  border: 1px solid transparent;
}
.btn-primary {
  background: linear-gradient(135deg, var(--primary) 0%, #0284c7 100%);
  color: #ffffff !important;
  box-shadow: 0 4px 14px rgba(2, 132, 199, 0.35);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(2, 132, 199, 0.45);
}
.btn-secondary {
  background: var(--bg-card);
  color: var(--text-main);
  border-color: var(--border-color);
}
.btn-secondary:hover {
  background: var(--border-color);
}
.btn-accent {
  background: var(--accent);
  color: #fff !important;
}
.btn-accent:hover {
  background: var(--accent-hover);
}

/* Hero Section */
.hero-section {
  position: relative;
  min-height: auto;
  display: flex;
  align-items: center;
  padding: 2rem 0 2.5rem;
  background: radial-gradient(circle at 80% 20%, rgba(2, 132, 199, 0.15) 0%, transparent 50%),
              radial-gradient(circle at 10% 80%, rgba(245, 158, 11, 0.1) 0%, transparent 40%),
              var(--bg-main);
  overflow: hidden;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.85rem;
  background: rgba(2, 132, 199, 0.12);
  color: var(--primary);
  border: 1px solid rgba(2, 132, 199, 0.3);
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  animation: pulse 2s infinite;
}

.hero-title {
  font-size: 2.75rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 0.75rem;
  line-height: 1.15;
}

.hero-desc {
  font-size: 1.05rem;
  color: var(--text-muted);
  max-width: 600px;
  margin-bottom: 1.25rem;
}

.hero-buttons {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.hero-stats-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  margin-top: 1.5rem;
}

.stat-card {
  background: var(--bg-glass-card);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border-glass);
  padding: 1rem;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  text-align: center;
  transition: var(--transition);
}
.stat-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-xl);
  border-color: var(--primary);
}
.stat-number {
  font-size: 1.85rem;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 0.15rem;
}
.stat-label {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-weight: 600;
}

/* Running Marquee Announcement */
.marquee-bar {
  background: #0284c7;
  color: #fff;
  padding: 0.5rem 0;
  overflow: hidden;
  font-size: 0.85rem;
  font-weight: 600;
  display: flex;
  align-items: center;
}
.marquee-label {
  background: #0369a1;
  padding: 0.25rem 0.7rem;
  border-radius: var(--radius-sm);
  margin-right: 1rem;
  white-space: nowrap;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.marquee-content {
  display: inline-block;
  white-space: nowrap;
  animation: marquee 25s linear infinite;
}
@keyframes marquee {
  0% { transform: translate3d(100%, 0, 0); }
  100% { transform: translate3d(-100%, 0, 0); }
}

/* Sections */
.section {
  padding: 0.85rem 0 2rem 0;
}
.section-alt {
  background: var(--bg-card);
}

.section-header {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 1.25rem auto;
}
.section-subtitle {
  text-transform: uppercase;
  color: var(--primary);
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 2px;
  margin-bottom: 0.35rem;
}
.section-title {
  font-size: 2rem;
  font-weight: 800;
  margin-bottom: 0.5rem;
}
.section-desc {
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* Cards & Grids */
.grid-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.25rem;
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}
.card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-xl);
  border-color: var(--primary);
}

.card-img-wrap {
  position: relative;
  overflow: hidden;
  height: 220px;
  background: #1e293b;
}
.card-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}
.card:hover .card-img-wrap img {
  transform: scale(1.06);
}

.card-badge {
  position: absolute;
  top: 1rem;
  left: 1rem;
  background: rgba(15, 23, 42, 0.85);
  color: #fff;
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 700;
  backdrop-filter: blur(8px);
}

.card-body {
  padding: 1.15rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.card-title {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 0.4rem;
  line-height: 1.35;
}
.card-title a {
  color: var(--text-main);
}
.card-title a:hover {
  color: var(--primary);
}

.card-text {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 0.75rem;
  line-height: 1.55;
}

.card-footer {
  margin-top: auto;
  padding-top: 0.75rem;
  border-top: 1px solid var(--border-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.8rem;
  color: var(--text-light);
}

/* Jurusan Card Modern */
.jurusan-card {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 2rem;
  transition: var(--transition);
  overflow: hidden;
}
.jurusan-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 5px;
  height: 100%;
  background: var(--primary);
  opacity: 0;
  transition: var(--transition);
}
.jurusan-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-xl);
  border-color: var(--primary);
}
.jurusan-card:hover::before {
  opacity: 1;
}
.jurusan-icon {
  width: 54px;
  height: 54px;
  border-radius: var(--radius-md);
  background: var(--primary-light);
  color: var(--primary-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 1.25rem;
  transition: var(--transition);
}
[data-theme="dark"] .jurusan-icon {
  background: rgba(2, 132, 199, 0.2);
  color: #38bdf8;
}
.jurusan-card:hover .jurusan-icon {
  background: var(--primary);
  color: #fff;
}

/* Modern Wide Timeline Sejarah (Lebar & Hemat Tempat) */
.timeline-wide {
  position: relative;
  max-width: 1060px;
  margin: 0 auto;
  padding: 1rem 0 2rem 0;
}
.timeline-wide::before {
  content: '';
  position: absolute;
  top: 15px;
  bottom: 15px;
  left: 36px;
  width: 3px;
  background: linear-gradient(180deg, var(--primary) 0%, rgba(56, 189, 248, 0.2) 100%);
  border-radius: 3px;
}
.timeline-row {
  display: flex;
  align-items: flex-start;
  position: relative;
  margin-bottom: 0.9rem;
  padding-left: 72px;
}
.timeline-node {
  position: absolute;
  left: 24px;
  top: 18px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #0f172a;
  border: 3px solid #38bdf8;
  box-shadow: 0 0 12px rgba(56, 189, 248, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
}
.timeline-node::after {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #38bdf8;
}
.timeline-card {
  width: 100%;
  background: rgba(15, 23, 42, 0.7);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(56, 189, 248, 0.2);
  border-radius: 12px;
  padding: 1.1rem 1.4rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
  transition: all 0.25s ease;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1.5rem;
}
.timeline-card:hover {
  border-color: rgba(56, 189, 248, 0.5);
  transform: translateX(5px);
  box-shadow: 0 8px 25px rgba(56, 189, 248, 0.15);
  background: rgba(15, 23, 42, 0.85);
}
.timeline-card-content {
  flex: 1;
}
.timeline-meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.35rem;
  flex-wrap: wrap;
}
.timeline-badge-year {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(56, 189, 248, 0.15);
  color: #38bdf8;
  font-size: 0.82rem;
  font-weight: 800;
  padding: 3px 9px;
  border-radius: 6px;
  border: 1px solid rgba(56, 189, 248, 0.35);
  letter-spacing: 0.5px;
}
.timeline-badge-order {
  font-size: 0.75rem;
  color: #94a3b8;
  font-weight: 600;
}
.timeline-card-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: #ffffff;
  margin: 0 0 0.35rem 0;
  line-height: 1.35;
}
.timeline-card-desc {
  font-size: 0.875rem;
  color: #cbd5e1;
  line-height: 1.55;
  margin: 0;
}
.timeline-thumb-box {
  flex-shrink: 0;
}
.timeline-thumb {
  width: 140px;
  height: 85px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid rgba(56, 189, 248, 0.25);
  display: block;
  transition: transform 0.2s;
}
.timeline-thumb:hover {
  transform: scale(1.03);
}

@media (max-width: 768px) {
  .timeline-wide {
    padding-left: 0;
  }
  .timeline-wide::before {
    left: 20px;
  }
  .timeline-row {
    padding-left: 48px;
  }
  .timeline-node {
    left: 9px;
    width: 22px;
    height: 22px;
  }
  .timeline-card {
    flex-direction: column;
    align-items: flex-start;
    padding: 1rem 1.15rem;
    gap: 0.75rem;
  }
  .timeline-thumb {
    width: 100%;
    height: 140px;
  }
}

/* Struktur Organisasi Interaktif */
.org-tree {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
}
.org-level {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1.5rem;
}
.org-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  text-align: center;
  width: 240px;
  box-shadow: var(--shadow-md);
  transition: var(--transition);
  cursor: pointer;
}
.org-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-xl);
  border-color: var(--primary);
}
.org-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  margin: 0 auto 0.75rem auto;
  object-fit: cover;
  border: 3px solid var(--primary);
}
.org-name {
  font-size: 0.95rem;
  font-weight: 700;
  margin-bottom: 0.2rem;
}
.org-title {
  font-size: 0.8rem;
  color: var(--primary);
  font-weight: 600;
}

/* Modal Popup */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(15, 23, 42, 0.8);
  backdrop-filter: blur(8px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  padding: 1rem;
}
.modal-overlay.active {
  display: flex;
}
.modal-content {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
  max-width: 650px;
  width: 100%;
  padding: 2rem;
  position: relative;
  box-shadow: var(--shadow-xl);
  animation: modalIn 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  max-height: 90vh;
  overflow-y: auto;
}
@keyframes modalIn {
  from { opacity: 0; transform: scale(0.95) translateY(10px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}
.modal-close {
  position: absolute;
  top: 1.25rem;
  right: 1.25rem;
  background: none;
  border: none;
  font-size: 1.5rem;
  color: var(--text-muted);
  cursor: pointer;
}

/* Lightbox Modal */
.lightbox-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.92);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 2100;
  padding: 2rem;
}
.lightbox-modal.active {
  display: flex;
}
.lightbox-img {
  max-width: 90%;
  max-height: 80vh;
  border-radius: var(--radius-md);
  box-shadow: 0 10px 30px rgba(0,0,0,0.8);
}
.lightbox-caption {
  color: #fff;
  text-align: center;
  margin-top: 1rem;
  font-size: 1.1rem;
  font-weight: 600;
}

/* Form Styles */
.form-group {
  margin-bottom: 1.25rem;
}
.form-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 0.4rem;
  color: var(--text-main);
}
.form-control {
  width: 100%;
  padding: 0.75rem 1rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  background: var(--bg-card);
  color: var(--text-main);
  font-family: inherit;
  font-size: 0.925rem;
  transition: var(--transition);
}
.form-control:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(2, 132, 199, 0.15);
}

/* Footer */
.main-footer {
  background: transparent;
  color: var(--text-muted);
  padding: 0.75rem 0 1rem;
  border: none;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.5fr;
  gap: 3rem;
  margin-bottom: 3.5rem;
}
.footer-title {
  color: #fff;
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 1.25rem;
  position: relative;
  padding-bottom: 0.5rem;
}
.footer-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 35px;
  height: 2px;
  background: var(--primary);
}
.footer-links li {
  margin-bottom: 0.65rem;
}
.footer-links a {
  color: #94a3b8;
  font-size: 0.9rem;
  transition: var(--transition);
}
.footer-links a:hover {
  color: #38bdf8;
  padding-left: 5px;
}
.footer-bottom {
  padding-top: 2rem;
  border-top: 1px solid #1e293b;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  font-size: 0.85rem;
  color: #64748b;
}

/* Social Icon Badges */
.social-links {
  display: flex;
  gap: 0.65rem;
  margin-top: 1.25rem;
}
.social-icon {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  background: #1e293b;
  color: #cbd5e1;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}
.social-icon:hover {
  background: var(--primary);
  color: #fff;
  transform: translateY(-3px);
}

/* Animations & Responsive */
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}

/* Shimmer Skeleton Loader */
.skeleton {
  background: linear-gradient(90deg, #e2e8f0 25%, #f1f5f9 50%, #e2e8f0 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: var(--radius-sm);
}
[data-theme="dark"] .skeleton {
  background: linear-gradient(90deg, #1e293b 25%, #334155 50%, #1e293b 75%);
  background-size: 200% 100%;
}
@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* Responsive Grid Layout Classes */
.grid-hero {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 2rem;
  align-items: center;
}

.grid-sambutan {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 2.5rem;
  align-items: center;
}

.sambutan-foto-wrap {
  text-align: center;
  position: relative;
  display: inline-block;
  margin: 0 auto;
}

.sambutan-foto-img {
  width: 240px;
  max-width: 100%;
  height: 300px;
  object-fit: cover;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xl);
  border: 4px solid var(--primary);
}

.sambutan-badge {
  position: absolute;
  bottom: -14px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--primary);
  color: #fff;
  padding: 0.35rem 1rem;
  border-radius: var(--radius-full);
  font-weight: 700;
  font-size: 0.8rem;
  white-space: nowrap;
  box-shadow: 0 4px 12px rgba(2, 132, 199, 0.4);
}

.sambutan-nama {
  margin-top: 1.5rem;
  font-size: 1.15rem;
  font-weight: 700;
}

.sambutan-nip {
  color: var(--text-muted);
  font-size: 0.85rem;
}

.sambutan-content {
  text-align: left;
}

.sambutan-isi {
  font-size: 1rem;
  line-height: 1.8;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}

@media (max-width: 992px) {
  .hero-title { font-size: 2.2rem; }
  .grid-hero {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  .grid-sambutan {
    grid-template-columns: 1fr;
    gap: 2rem;
    text-align: center;
  }
  .sambutan-content {
    text-align: left;
  }
  .hero-stats-row {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
  }
  .timeline::after { left: 31px; }
  .timeline-item { width: 100%; padding-left: 70px; padding-right: 25px; }
  .timeline-item.right { left: 0%; text-align: left; }
  .timeline-item.left { text-align: left; }
  .timeline-item::after { left: 21px; }
  
  .nav-menu {
    position: fixed;
    top: 50px;
    left: -100%;
    width: 85%;
    max-width: 340px;
    height: calc(100vh - 50px);
    background: var(--bg-card);
    flex-direction: column;
    align-items: stretch;
    padding: 1.5rem 1.25rem;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    transition: left 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow-y: auto;
    z-index: 9999;
    border-right: 1px solid var(--border-color);
  }
  .nav-menu.open {
    left: 0;
  }
  .nav-item {
    width: 100%;
  }
  .nav-link {
    width: 100%;
    padding: 0.65rem 0.85rem;
    font-size: 0.925rem;
    border-radius: var(--radius-sm);
  }
  .dropdown-menu {
    position: static;
    box-shadow: none;
    border: 1px solid var(--border-color);
    background: var(--bg-main);
    opacity: 1;
    transform: none;
    margin: 0.25rem 0 0.5rem 0.75rem;
    display: none;
  }
  .nav-item.open .dropdown-menu,
  .nav-item:hover .dropdown-menu {
    display: block;
  }
  .mobile-toggle {
    display: inline-flex;
  }
}

@media (max-width: 768px) {
  html, body {
    overflow-x: hidden !important;
    width: 100% !important;
  }

  .container {
    padding-left: 1rem !important;
    padding-right: 1rem !important;
  }

  .navbar {
    padding: 0.35rem 0;
  }

  .brand-logo img {
    height: 30px;
  }

  .header-actions {
    gap: 0.35rem;
  }

  .btn-icon {
    width: 32px;
    height: 32px;
    font-size: 0.8rem;
  }

  /* Universal Single Column Flow for Multi-column Layouts */
  .grid-hero,
  .grid-sambutan,
  [style*="grid-template-columns: 1.2fr 0.8fr"],
  [style*="grid-template-columns: 1.1fr 0.9fr"],
  [style*="grid-template-columns: 1.15fr 1fr"],
  [style*="grid-template-columns: 1.1fr 1fr"],
  [style*="grid-template-columns: 300px 1fr"],
  [style*="grid-template-columns: 280px 1fr"],
  [style*="grid-template-columns: 340px 1fr"],
  [style*="grid-template-columns: 1fr 340px"],
  [style*="grid-template-columns: 1fr 320px"],
  [style*="grid-template-columns: 1fr 1.2fr"],
  [style*="grid-template-columns: 1fr 1fr"],
  [style*="grid-template-columns: 2fr 1fr"],
  [style*="grid-template-columns: 2fr 1fr 1fr"] {
    grid-template-columns: 1fr !important;
    gap: 1.25rem !important;
  }

  .hero-section {
    padding: 1rem 0 1.5rem;
  }
  .hero-title {
    font-size: 1.65rem !important;
    line-height: 1.25 !important;
  }
  .hero-desc {
    font-size: 0.875rem !important;
    margin-bottom: 1rem !important;
  }
  .hero-buttons {
    flex-direction: column;
    width: 100%;
    gap: 0.5rem;
  }
  .hero-buttons .btn {
    width: 100%;
    justify-content: center;
  }
  .hero-stats-row {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 0.5rem !important;
  }
  .stat-card {
    padding: 0.65rem 0.5rem !important;
  }
  .stat-number {
    font-size: 1.35rem !important;
  }
  .stat-label {
    font-size: 0.72rem !important;
  }

  .section {
    padding: 1.25rem 0 !important;
  }
  .section-title {
    font-size: 1.45rem !important;
  }
  .section-subtitle {
    font-size: 0.72rem !important;
  }

  .sambutan-foto-img {
    width: 190px !important;
    height: 240px !important;
  }
  .sambutan-content h2 {
    font-size: 1.45rem !important;
    margin-bottom: 1rem !important;
  }
  .sambutan-isi {
    font-size: 0.9rem !important;
    line-height: 1.7 !important;
  }

  .grid-cards {
    grid-template-columns: 1fr !important;
    gap: 1rem !important;
  }

  .footer-grid {
    grid-template-columns: 1fr !important;
    gap: 1.25rem !important;
  }
  .top-bar {
    display: none !important;
  }

  .table-responsive {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin-bottom: 1rem;
    border-radius: var(--radius-sm);
  }

  /* Touch Targets */
  .btn,
  .btn-icon,
  .nav-link,
  .dropdown-item,
  input[type="submit"],
  button {
    min-height: 40px;
    touch-action: manipulation;
  }

  .form-control,
  input[type="text"],
  input[type="password"],
  input[type="email"],
  select {
    font-size: 16px !important;
    min-height: 40px;
  }
}

/* Base Responsive Data Table Styling */
table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 1rem;
}

table th,
table td {
  padding: 0.75rem 0.85rem;
  text-align: left;
  vertical-align: middle;
  border-bottom: 1px solid var(--border-color);
}

table th {
  font-weight: 700;
  background: var(--bg-card);
  color: var(--text-main);
  white-space: nowrap;
}

/* Optimasi performa render gambar dan animasi */
img[loading="lazy"] {
  content-visibility: auto;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ==========================================================
   PWA (PROGRESSIVE WEB APP) MOBILE PROMPT & BANNER
   ========================================================== */
.pwa-floating-banner {
  position: fixed;
  bottom: 20px;
  right: 20px;
  max-width: 420px;
  width: calc(100% - 40px);
  z-index: 99999;
  animation: pwaSlideUp 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

@keyframes pwaSlideUp {
  from {
    transform: translateY(100px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.pwa-banner-hiding {
  animation: pwaSlideDown 0.3s ease forwards;
}

@keyframes pwaSlideDown {
  from {
    transform: translateY(0);
    opacity: 1;
  }
  to {
    transform: translateY(120px);
    opacity: 0;
  }
}

.pwa-banner-inner {
  position: relative;
  background: linear-gradient(145deg, #1e293b 0%, #0f172a 100%);
  border: 1px solid rgba(56, 189, 248, 0.4);
  border-radius: 16px;
  padding: 1rem 1.15rem;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.5), 0 0 20px rgba(2, 132, 199, 0.2);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.pwa-banner-close {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 26px;
  height: 26px;
  background: rgba(255, 255, 255, 0.08);
  border: none;
  border-radius: 50%;
  color: #94a3b8;
  font-size: 1.1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.pwa-banner-close:hover {
  background: rgba(239, 68, 68, 0.25);
  color: #ef4444;
}

.pwa-banner-content {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.pwa-banner-icon {
  width: 50px;
  height: 50px;
  border-radius: 12px;
  object-fit: contain;
  background: rgba(2, 132, 199, 0.15);
  border: 1px solid rgba(56, 189, 248, 0.3);
  padding: 4px;
  flex-shrink: 0;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

.pwa-banner-text {
  flex: 1;
  padding-right: 1.5rem;
}

.pwa-banner-title {
  font-size: 0.95rem;
  font-weight: 800;
  color: #ffffff;
  line-height: 1.25;
  margin-bottom: 2px;
}

.pwa-banner-desc {
  font-size: 0.78rem;
  color: #94a3b8;
  line-height: 1.35;
}

.pwa-banner-actions {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 0.5rem;
}

.pwa-btn-install {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
  color: #ffffff;
  border: none;
  border-radius: 8px;
  padding: 0.55rem 1.15rem;
  font-size: 0.84rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(2, 132, 199, 0.35);
  transition: all 0.2s ease;
  width: 100%;
  justify-content: center;
}

.pwa-btn-install:hover {
  background: linear-gradient(135deg, #0369a1 0%, #0284c7 100%);
  box-shadow: 0 6px 16px rgba(2, 132, 199, 0.5);
  transform: translateY(-1px);
}

.btn-pwa-install-trigger {
  display: none;
  align-items: center;
  gap: 6px;
  background: rgba(2, 132, 199, 0.15);
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.3);
  border-radius: 20px;
  padding: 0.35rem 0.85rem;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s ease;
}

.btn-pwa-install-trigger:hover {
  background: #0284c7;
  color: #ffffff;
}

@media (max-width: 600px) {
  .pwa-floating-banner {
    bottom: 15px;
    right: 15px;
    left: 15px;
    width: auto;
  }
}



