/* ===== DESIGN TOKENS ===== */

:root {
  /* Colors - Light Theme */
  --bg-primary: #ffffff;
  --bg-secondary: #f5f7fa;
  --bg-elevated: #ffffff;
  --bg-card: #ffffff;
  --text-primary: #121416;
  --text-secondary: #4a5568;
  --text-muted: #718096;

  /* SDG Accent Colors */
  --accent: #E5243B;
  /* SDG 1 Red */
  --accent-secondary: #00689D;
  /* SDG 16 Blue */
  --accent-glow: rgba(229, 36, 59, 0.15);

  /* 17 SDG Colors */
  --sdg-1: #E5243B;
  --sdg-2: #DDA63A;
  --sdg-3: #4C9F38;
  --sdg-4: #C5192D;
  --sdg-5: #FF3A21;
  --sdg-6: #26BDE2;
  --sdg-7: #FCC30B;
  --sdg-8: #A21942;
  --sdg-9: #FD6925;
  --sdg-10: #DD1367;
  --sdg-11: #FD9D24;
  --sdg-12: #BF8B2E;
  --sdg-13: #3F7E44;
  --sdg-14: #0A97D9;
  --sdg-15: #56C02B;
  --sdg-16: #00689D;
  --sdg-17: #19486A;

  /* SDG Gradient Multi-color (all 17 with crisp hard stops for a ribbon effect) */
  --gradient-sdg-colors:
    var(--sdg-1) 0% 5.88%,
    var(--sdg-2) 5.88% 11.76%,
    var(--sdg-3) 11.76% 17.64%,
    var(--sdg-4) 17.64% 23.52%,
    var(--sdg-5) 23.52% 29.41%,
    var(--sdg-6) 29.41% 35.29%,
    var(--sdg-7) 35.29% 41.17%,
    var(--sdg-8) 41.17% 47.05%,
    var(--sdg-9) 47.05% 52.94%,
    var(--sdg-10) 52.94% 58.82%,
    var(--sdg-11) 58.82% 64.70%,
    var(--sdg-12) 64.70% 70.58%,
    var(--sdg-13) 70.58% 76.47%,
    var(--sdg-14) 76.47% 82.35%,
    var(--sdg-15) 82.35% 88.23%,
    var(--sdg-16) 88.23% 94.11%,
    var(--sdg-17) 94.11% 100%;

  --border-subtle: rgba(0, 0, 0, 0.08);
  --border-hover: rgba(0, 0, 0, 0.15);

  /* Typography */
  --font-display: 'Space Grotesk', sans-serif;
  --font-body: 'Inter', sans-serif;
  --fs-hero: clamp(3.5rem, 10vw, 9rem);
  --fs-h1: clamp(2.5rem, 5vw, 5rem);
  --fs-h2: clamp(2rem, 4vw, 3.5rem);
  --fs-h3: clamp(1.25rem, 2vw, 1.75rem);
  --fs-body: clamp(1rem, 1.2vw, 1.125rem);
  --fs-small: clamp(0.8rem, 1vw, 0.875rem);
  --fs-tag: 0.75rem;

  /* Spacing */
  --space-xs: 0.5rem;
  --space-sm: 1rem;
  --space-md: 1rem;
  --space-lg: 1rem;
  --space-xl: 2rem;
  --space-2xl: 4rem;

  /* Layout */
  --container-max: 1400px;
  --container-padding: clamp(1.5rem, 4vw, 4rem);

  /* Effects */
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-xl: 32px;
  --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-smooth: 0.5s cubic-bezier(0.32, 0.72, 0, 1);
  --transition-elastic: 0.75s cubic-bezier(0.34, 1.56, 0.64, 1);

  /* Glassmorphism - Light */
  --glass-bg: rgba(255, 255, 255, 0.85);
  --glass-blur: 24px;
  --glass-border: rgba(0, 0, 0, 0.06);
}

/* ===== RESET & BASE ===== */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Lenis Recommended Base CSS */
html.lenis,
html.lenis body {
  height: auto;
}

.lenis.lenis-smooth {
  scroll-behavior: auto !important;
}

.lenis.lenis-smooth [data-lenis-prevent] {
  overscroll-behavior: contain;
}

.lenis.lenis-stopped {
  overflow: hidden;
}

.lenis.lenis-smooth iframe {
  pointer-events: none;
}

body {
  font-family: var(--font-body);
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

img,
video {
  max-width: 100%;
  display: block;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

input {
  font-family: inherit;
  border: none;
  outline: none;
}

/* ===== UTILITY ===== */
.section-tag {
  display: inline-block;
  font-family: var(--font-display);
  font-size: var(--fs-tag);
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
  padding: 0.4em 1em;
  border: 1px solid var(--accent);
  border-radius: 100px;
  margin-bottom: var(--space-md);
}

/* ===== SELECTION ===== */
::selection {
  background: var(--accent);
  color: var(--bg-primary);
}

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar {
  display: none;
  width: 0;
  height: 0;
}

html {
  scrollbar-width: none;
  -ms-overflow-style: none;
  /* Untuk IE 10+ (Legacy) */
}

/* ===== PRELOADER ===== */
/* Keep sections invisible until preloader finishes */
body.is-loading>section,
body.is-loading>header,
body.is-loading>footer {
  opacity: 0 !important;
  visibility: hidden !important;
}

.preloader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background-color: var(--bg-primary);
  display: flex;
  align-items: center;
  justify-content: center;
}

.preloader__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-md);
}

.preloader__logo {
  height: 48px;
  width: auto;
  opacity: 0.8;
}

.preloader__spinner {
  width: 40px;
  height: 40px;
  border: 3px solid var(--border-subtle);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spinner 0.8s linear infinite;
}

@keyframes spinner {
  to {
    transform: rotate(360deg);
  }
}