/* ==========================================================================
   E-Portfolio PPL Siklus 1 - Core Stylesheet & Design System
   ========================================================================== */

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

:root {
  /* Color Palette - Light Mode Default */
  --bg-primary: #f8fafc;
  --bg-surface: #ffffff;
  --bg-surface-elevated: #ffffff;
  --bg-subtle: #f1f5f9;
  --bg-glass: rgba(255, 255, 255, 0.82);
  --border-color: #e2e8f0;
  --border-light: #edf2f7;
  --border-accent: rgba(59, 130, 246, 0.25);

  --text-primary: #0f172a;
  --text-secondary: #475569;
  --text-muted: #64748b;
  --text-inverse: #ffffff;

  /* Brand Accents */
  --primary: #2563eb;
  --primary-hover: #1d4ed8;
  --primary-light: #eff6ff;
  --primary-glow: rgba(37, 99, 235, 0.2);

  --accent-teal: #0d9488;
  --accent-teal-light: #f0fdfa;
  --accent-amber: #d97706;
  --accent-amber-light: #fffbeb;
  --accent-purple: #7c3aed;
  --accent-purple-light: #f5f3ff;
  --accent-rose: #e11d48;
  --accent-rose-light: #fff1f2;

  /* Shadows */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.08), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.08), 0 4px 6px -4px rgba(0, 0, 0, 0.04);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.04);
  --shadow-glow: 0 0 25px rgba(37, 99, 235, 0.18);

  /* Layout */
  --container-max: 1200px;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 9999px;

  --transition-fast: 0.18s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-normal: 0.28s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Dark Theme Variables */
[data-theme="dark"] {
  --bg-primary: #090d16;
  --bg-surface: #0f172a;
  --bg-surface-elevated: #162036;
  --bg-subtle: #1e293b;
  --bg-glass: rgba(15, 23, 42, 0.85);
  --border-color: #1e293b;
  --border-light: #283548;
  --border-accent: rgba(96, 165, 250, 0.25);

  --text-primary: #f8fafc;
  --text-secondary: #cbd5e1;
  --text-muted: #94a3b8;
  --text-inverse: #090d16;

  --primary: #3b82f6;
  --primary-hover: #60a5fa;
  --primary-light: rgba(59, 130, 246, 0.15);
  --primary-glow: rgba(59, 130, 246, 0.3);

  --accent-teal: #14b8a6;
  --accent-teal-light: rgba(20, 184, 166, 0.15);
  --accent-amber: #f59e0b;
  --accent-amber-light: rgba(245, 158, 11, 0.15);
  --accent-purple: #8b5cf6;
  --accent-purple-light: rgba(139, 92, 246, 0.15);
  --accent-rose: #f43f5e;
  --accent-rose-light: rgba(244, 63, 94, 0.15);

  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.4);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.35);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.4);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 35px rgba(59, 130, 246, 0.25);
}

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

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

body {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  transition: background-color var(--transition-normal), color var(--transition-normal);
  overflow-x: hidden;
  position: relative;
  min-height: 100vh;
}

/* Ambient Background Light Mesh */
body::before {
  content: "";
  position: fixed;
  top: -200px;
  left: 20%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(37, 99, 235, 0.12) 0%, rgba(37, 99, 235, 0) 70%);
  pointer-events: none;
  z-index: 0;
  filter: blur(40px);
}

body::after {
  content: "";
  position: fixed;
  bottom: -150px;
  right: 15%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(13, 148, 136, 0.1) 0%, rgba(13, 148, 136, 0) 70%);
  pointer-events: none;
  z-index: 0;
  filter: blur(50px);
}

.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 24px;
  position: relative;
  z-index: 1;
}

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

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

a:hover {
  color: var(--primary-hover);
}

/* Header & Navbar */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  background-color: var(--bg-glass);
  border-bottom: 1px solid var(--border-color);
  transition: all var(--transition-fast);
}

.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.brand-icon {
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, var(--primary), #4f46e5);
  color: #ffffff;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.2rem;
  box-shadow: 0 4px 10px rgba(37, 99, 235, 0.35);
}

.brand-title-wrap {
  display: flex;
  flex-direction: column;
}

.brand-name {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.brand-tag {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
  list-style: none;
}

.nav-link {
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--text-secondary);
  transition: color var(--transition-fast);
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 0;
  position: relative;
}

.nav-link:hover, .nav-link.active {
  color: var(--primary);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Theme Toggle Button */
.btn-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  background: var(--bg-surface);
  color: var(--text-secondary);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-fast);
}

.btn-icon:hover {
  background: var(--bg-subtle);
  color: var(--text-primary);
  border-color: var(--border-accent);
  transform: translateY(-1px);
}

/* Primary and Secondary Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: var(--radius-md);
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all var(--transition-fast);
  text-decoration: none;
  white-space: nowrap;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary), #1d4ed8);
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.28);
}

.btn-primary:hover {
  color: #ffffff;
  box-shadow: 0 6px 20px rgba(37, 99, 235, 0.38);
  transform: translateY(-2px);
}

.btn-secondary {
  background: var(--bg-surface);
  border-color: var(--border-color);
  color: var(--text-primary);
}

.btn-secondary:hover {
  background: var(--bg-subtle);
  border-color: var(--border-accent);
  transform: translateY(-1px);
}

.btn-sm {
  padding: 6px 12px;
  font-size: 0.82rem;
  border-radius: var(--radius-sm);
}

.btn-accent-red {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(239, 68, 68, 0.25);
}

.btn-accent-red:hover {
  color: #ffffff;
  box-shadow: 0 6px 18px rgba(239, 68, 68, 0.35);
  transform: translateY(-2px);
}

.btn-accent-drive {
  background: linear-gradient(135deg, #0d9488, #0f766e);
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(13, 148, 136, 0.25);
}

.btn-accent-drive:hover {
  color: #ffffff;
  box-shadow: 0 6px 18px rgba(13, 148, 136, 0.35);
  transform: translateY(-2px);
}

/* Section Header Styles */
.section-header {
  margin-bottom: 36px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
}

.section-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  background: var(--primary-light);
  color: var(--primary);
  border: 1px solid var(--border-accent);
}

.section-title {
  font-size: 1.85rem;
  font-weight: 800;
  letter-spacing: -0.025em;
  color: var(--text-primary);
}

.section-desc {
  font-size: 1rem;
  color: var(--text-muted);
  max-width: 680px;
}

/* Sections */
section {
  padding: 60px 0;
  position: relative;
}

/* Footer */
.footer {
  background: var(--bg-surface);
  border-top: 1px solid var(--border-color);
  padding: 48px 0 32px 0;
  margin-top: 40px;
  position: relative;
  z-index: 1;
}

.footer-grid {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 40px;
  margin-bottom: 40px;
  flex-wrap: wrap;
}

.footer-brand {
  max-width: 480px;
}

.footer-brand p {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-top: 12px;
  max-width: 420px;
}

.footer-links-col {
  text-align: right;
  margin-left: auto;
}

.footer-links-col h4 {
  font-size: 0.95rem;
  margin-bottom: 16px;
  color: var(--text-primary);
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: flex-end;
}

.footer-links a {
  color: var(--text-muted);
  font-size: 0.88rem;
  transition: color var(--transition-fast);
}

.footer-links a:hover {
  color: var(--primary);
}

.footer-bottom {
  padding-top: 24px;
  border-top: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.85rem;
  color: var(--text-muted);
  flex-wrap: wrap;
  gap: 16px;
}

/* Responsive adjustments */
@media (max-width: 960px) {
  .nav-links {
    display: none;
  }
}

@media (max-width: 640px) {
  .footer-links-col {
    text-align: left;
    margin-left: 0;
  }
  .footer-links {
    align-items: flex-start;
  }
  .container {
    padding: 0 16px;
  }
  section {
    padding: 40px 0;
  }
  .section-title {
    font-size: 1.5rem;
  }
}
