/* =====================================================================
   STYLE PORTOFOLIO (mobile-first)
   Urutan: 1 Variabel · 2 Dasar · 3 Komponen · 4 Section · 5 Responsif
   ===================================================================== */

/* ========== 1. VARIABEL (ubah warna aksen di sini) ========== */
:root {
  --bg: #0a0a0f;
  --surface: #12121a;
  --surface-2: #1a1a24;
  --text: #f4f4f8;
  --muted: #a0a0b5;
  --line: rgba(255, 255, 255, 0.09);

  /* Warna aksen: violet (default).
     Mau cyan? Ganti tiga baris + --on-accent seperti ini:
       --accent: #22d3ee; --accent-rgb: 34, 211, 238;
       --accent-strong: #06b6d4; --accent-soft: #67e8f9; --on-accent: #04141a; */
  --accent: #8b5cf6;
  --accent-rgb: 139, 92, 246;
  --accent-strong: #7c3aed;
  --accent-soft: #a78bfa;
  --on-accent: #ffffff;

  --radius: 20px;
  --font-head: "Space Grotesk", system-ui, sans-serif;
  --font-body: "Inter", system-ui, sans-serif;
  --gutter: clamp(16px, 5vw, 48px);
  --maxw: 1200px;
}

/* ========== 2. DASAR ========== */
*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}
html.no-scroll { overflow: hidden; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 clamp(1rem, 0.95rem + 0.25vw, 1.125rem) / 1.65 var(--font-body);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img, canvas { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, p { margin: 0; }
section[id] { scroll-margin-top: 84px; }

:focus-visible {
  outline: 2px solid var(--accent-soft);
  outline-offset: 3px;
}

.container {
  width: min(100% - 2 * var(--gutter), var(--maxw));
  margin-inline: auto;
}

.skip-link {
  position: fixed;
  top: -60px;
  left: 16px;
  z-index: 10000;
  padding: 10px 16px;
  background: var(--accent-strong);
  color: var(--on-accent);
  border-radius: 10px;
  transition: top 0.2s;
}
.skip-link:focus { top: 12px; }

/* Latar aurora */
.aurora {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}
.aurora span {
  position: absolute;
  width: 70vmax;
  height: 70vmax;
  border-radius: 50%;
  will-change: transform;
}
.aurora span:nth-child(1) {
  top: -30vmax; left: -20vmax;
  background: radial-gradient(circle, rgba(var(--accent-rgb), 0.28), transparent 62%);
  animation: drift-a 28s ease-in-out infinite alternate;
}
.aurora span:nth-child(2) {
  bottom: -38vmax; right: -26vmax;
  background: radial-gradient(circle, rgba(59, 130, 246, 0.16), transparent 62%);
  animation: drift-b 34s ease-in-out infinite alternate;
}
.aurora span:nth-child(3) {
  top: 30vh; left: 35vw;
  width: 50vmax; height: 50vmax;
  background: radial-gradient(circle, rgba(var(--accent-rgb), 0.1), transparent 62%);
  animation: drift-c 40s ease-in-out infinite alternate;
}

/* Garis progres scroll */
.progress {
  position: fixed;
  top: 0; left: 0;
  z-index: 200;
  width: 100%;
  height: 3px;
  background: linear-gradient(90deg, var(--accent-strong), var(--accent-soft));
  transform: scaleX(0);
  transform-origin: left;
}

/* ========== 3. KOMPONEN ========== */

/* Kaca (glassmorphism) */
.glass {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.025));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
}

/* Cahaya yang mengikuti kursor di dalam kartu (var --mx/--my diisi JS) */
.spot { position: relative; isolation: isolate; }
.spot::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  background: radial-gradient(320px circle at var(--mx, 50%) var(--my, 50%), rgba(var(--accent-rgb), 0.2), transparent 60%);
  opacity: 0;
  transition: opacity 0.3s;
  pointer-events: none;
}
.spot:hover::before { opacity: 1; }

/* Tombol */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 52px;
  padding: 0 1.7rem;
  border: 1px solid transparent;
  border-radius: 999px;
  font: 600 1rem var(--font-head);
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.3s, background 0.3s, border-color 0.3s;
}
.btn:active { transform: translateY(0) scale(0.97); }
.btn-sm { min-height: 44px; padding: 0 1.25rem; font-size: 0.95rem; }
.btn-block { width: 100%; }
.btn-primary {
  background: var(--accent-strong);
  color: var(--on-accent);
  box-shadow: 0 6px 24px rgba(var(--accent-rgb), 0.35);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 34px rgba(var(--accent-rgb), 0.55);
}
.btn-outline {
  background: rgba(255, 255, 255, 0.03);
  border-color: rgba(255, 255, 255, 0.22);
  color: var(--text);
}
.btn-outline:hover {
  transform: translateY(-2px);
  border-color: var(--accent-soft);
  background: rgba(var(--accent-rgb), 0.1);
}

/* Judul section */
.section { padding-block: clamp(72px, 12vw, 140px); position: relative; overflow-x: clip; }
.section-label {
  margin-bottom: 14px;
  font: 600 0.8rem var(--font-head);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent-soft);
}
.section-title {
  max-width: 18ch;
  font: 700 clamp(2rem, 5.2vw, 3.6rem) / 1.08 var(--font-head);
  letter-spacing: -0.025em;
}

/* Animasi muncul saat di-scroll (kelas is-visible ditambah oleh JS) */
.js .reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.8s cubic-bezier(0.2, 0.7, 0.2, 1), transform 0.8s cubic-bezier(0.2, 0.7, 0.2, 1);
  transition-delay: var(--d, 0ms);
}
.js .reveal.is-visible { opacity: 1; transform: none; }

/* Kursor kustom (hanya muncul di perangkat dengan mouse) */
.cursor-dot, .cursor-ring {
  position: fixed;
  top: 0; left: 0;
  z-index: 9999;
  border-radius: 50%;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.3s;
}
.cursor-dot { width: 6px; height: 6px; margin: -3px 0 0 -3px; background: var(--accent-soft); }
.cursor-ring {
  width: 38px; height: 38px;
  margin: -19px 0 0 -19px;
  border: 1px solid rgba(255, 255, 255, 0.4);
  transition: opacity 0.3s, scale 0.25s, background 0.25s, border-color 0.25s;
}
.cursor-ring.is-hover {
  scale: 1.7;
  background: rgba(var(--accent-rgb), 0.14);
  border-color: var(--accent-soft);
}
html.has-cursor .cursor-dot, html.has-cursor .cursor-ring { opacity: 1; }
html.has-cursor, html.has-cursor a, html.has-cursor button, html.has-cursor [data-tilt] { cursor: none; }
html.has-cursor input, html.has-cursor textarea { cursor: text; }

/* ---------- Navbar ---------- */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  justify-content: center;
  padding: 12px var(--gutter) 0;
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  width: min(100%, 1040px);
  padding: 8px 10px 8px 16px;
  border-radius: 999px;
  transition: background 0.3s, border-color 0.3s;
}
.nav.is-scrolled .nav-inner {
  background: rgba(14, 14, 22, 0.78);
  border-color: rgba(255, 255, 255, 0.12);
}
.logo { display: inline-flex; align-items: center; gap: 10px; font: 700 1rem var(--font-head); }
/* Logo monogram SR (SVG) + kursor terminal yang berkedip */
.logo-svg {
  flex: none;
  width: 38px; height: 38px;
  filter: drop-shadow(0 4px 14px rgba(var(--accent-rgb), 0.5));
  transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.logo:hover .logo-svg { transform: rotate(-8deg) scale(1.08); }
.logo-cursor { animation: blink 1.1s steps(2) infinite; }
.logo-name { letter-spacing: -0.01em; }
.logo-name { display: none; }
.nav-links { display: none; }
.nav-cta { display: none; }

.burger {
  display: grid; place-content: center; gap: 6px;
  width: 44px; height: 44px;
  margin-left: auto;
  background: transparent;
  border: 0;
  cursor: pointer;
}
.burger span {
  display: block;
  width: 22px; height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform 0.3s;
}
.burger[aria-expanded="true"] span:first-child { transform: translateY(4px) rotate(45deg); }
.burger[aria-expanded="true"] span:last-child { transform: translateY(-4px) rotate(-45deg); }

/* Menu layar penuh (HP) */
.menu {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 32px;
  padding: 100px var(--gutter) 40px;
  background: rgba(8, 8, 13, 0.96);
  -webkit-backdrop-filter: blur(20px);
  backdrop-filter: blur(20px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.35s, visibility 0s linear 0.35s;
}
.menu.is-open { opacity: 1; visibility: visible; transition: opacity 0.35s; }
.menu ul { display: grid; gap: 8px; }
.menu li a {
  display: inline-block;
  padding: 6px 0;
  font: 700 clamp(2.2rem, 11vw, 3.4rem) / 1.15 var(--font-head);
  letter-spacing: -0.03em;
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.5s, transform 0.5s, color 0.2s;
}
.menu li a:hover, .menu li a[aria-current] { color: var(--accent-soft); }
.menu.is-open li a { opacity: 1; transform: none; }
.menu.is-open li:nth-child(1) a { transition-delay: 0.08s; }
.menu.is-open li:nth-child(2) a { transition-delay: 0.14s; }
.menu.is-open li:nth-child(3) a { transition-delay: 0.2s; }
.menu.is-open li:nth-child(4) a { transition-delay: 0.26s; }
.menu.is-open li:nth-child(5) a { transition-delay: 0.32s; }
.menu.is-open li:nth-child(6) a { transition-delay: 0.38s; }
.menu.is-open li:nth-child(7) a { transition-delay: 0.44s; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 100vh;
  min-height: 100svh;
  padding: 120px 0 100px;
  overflow: hidden;
}
#hero-canvas { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; }
.hero-inner { position: relative; z-index: 1; }

.badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 7px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  font-size: 0.85rem;
  color: var(--muted);
}
.pulse-dot {
  position: relative;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #34d399;
}
.pulse-dot::after {
  content: "";
  position: absolute; inset: 0;
  border-radius: 50%;
  background: #34d399;
  animation: pulse 2s ease-out infinite;
}

.hero-name {
  margin: 22px 0 10px;
  font: 700 clamp(3.2rem, 13.5vw, 9.5rem) / 0.98 var(--font-head);
  letter-spacing: -0.045em;
}
.hero-name .word {
  display: inline-block;
  margin-right: 0.22em;
  padding: 0.06em 0 0.1em;
  overflow: hidden;
  vertical-align: top;
}
.hero-name .char {
  display: inline-block;
  background: linear-gradient(180deg, #ffffff 35%, var(--accent-soft));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  transform: translateY(115%);
  animation: rise 0.9s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
  animation-delay: calc(var(--i) * 45ms + 150ms);
}
.hero-role {
  font: 600 clamp(1rem, 2.5vw, 1.35rem) var(--font-head);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent-soft);
}
.hero-typed {
  min-height: 3.4em;
  margin-top: 22px;
  font: 500 clamp(1.25rem, 3.4vw, 2rem) / 1.3 var(--font-head);
}
.typed { color: var(--accent-soft); }
.caret {
  display: inline-block;
  width: 2px; height: 1em;
  margin-left: 3px;
  vertical-align: -0.12em;
  background: var(--accent-soft);
  animation: blink 1s steps(2) infinite;
}
.hero-tagline { max-width: 52ch; margin-top: 4px; color: var(--muted); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 34px; }

.js .reveal-load {
  opacity: 0;
  animation: fade-up 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) forwards;
  animation-delay: var(--d, 0ms);
}

.scroll-hint {
  display: none; /* tampil hanya di layar lebar (lihat bagian Hero kolom kanan) */
  position: absolute;
  bottom: 28px; left: 50%;
  z-index: 1;
  translate: -50% 0;
  justify-items: center;
  width: 26px; height: 42px;
  padding-top: 8px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 16px;
}
.scroll-hint span {
  width: 4px; height: 8px;
  border-radius: 4px;
  background: var(--accent-soft);
  animation: scroll-dot 1.8s ease-in-out infinite;
}

/* ---------- Hero: kolom kanan (jendela terminal) ---------- */
.hero-visual {
  display: block;
  margin-top: 40px;
  padding-top: 3.5rem; /* ruang untuk kepala yang menonjol keluar dari lingkaran */
}
.hero-visual .photo-stage { width: min(100%, 340px); }
/* Terminal ada di section About, hanya di layar lebar */
.about-visual { display: none; }

@media (min-width: 1000px) {
  .hero-inner {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
    gap: clamp(32px, 5vw, 72px);
    align-items: center;
  }
  /* Nama sedikit lebih kecil agar muat di kolom kiri */
  .hero-name { font-size: clamp(3.2rem, 7vw, 6.4rem); }
  .scroll-hint { display: grid; }
  .hero-visual { margin-top: 0; justify-self: center; width: 100%; max-width: 500px; }
  .hero-visual .photo-stage { width: min(100%, 460px); }
}

.terminal-float { animation: float 7s ease-in-out infinite; }
.terminal {
  overflow: hidden;
  background: linear-gradient(180deg, rgba(20, 20, 32, 0.78), rgba(10, 10, 18, 0.7));
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55), 0 0 70px rgba(var(--accent-rgb), 0.22);
  transition: transform 0.2s ease-out;
}
.terminal-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.03);
}
.terminal-bar i { width: 11px; height: 11px; border-radius: 50%; background: #ff5f57; }
.terminal-bar i:nth-child(2) { background: #febc2e; }
.terminal-bar i:nth-child(3) { background: #28c840; }
.terminal-bar span {
  margin-left: 10px;
  font: 500 0.8rem ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  color: var(--muted);
}
.terminal-body {
  min-height: 21rem;
  padding: 22px 22px 26px;
  font: 400 0.92rem / 1.75 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
.t-line { display: flex; gap: 10px; min-height: 1.75em; }
.t-prompt { flex: none; color: var(--accent-soft); font-weight: 600; user-select: none; }
.t-cmd { color: var(--text); }
.t-out { padding-left: 1.4em; color: var(--muted); overflow-wrap: anywhere; }
.t-tags { display: flex; flex-wrap: wrap; gap: 6px; padding: 2px 0 4px 1.4em; }
.t-tags span {
  padding: 1px 10px;
  border: 1px solid rgba(var(--accent-rgb), 0.45);
  border-radius: 999px;
  background: rgba(var(--accent-rgb), 0.12);
  color: var(--accent-soft);
  font-size: 0.82rem;
}
.t-caret {
  display: inline-block;
  width: 0.55em; height: 1.1em;
  margin-left: 2px;
  vertical-align: -0.2em;
  background: var(--accent-soft);
  animation: blink 1s steps(2) infinite;
}

/* ---------- Tentang + Foto ---------- */
.about-grid { display: grid; gap: clamp(48px, 9vw, 80px); align-items: center; }

.photo-stage {
  position: relative;
  width: min(100%, 440px);
  aspect-ratio: 4 / 5;
  margin-inline: auto;
}
.photo-orb {
  position: absolute;
  left: 5%; bottom: 6%;
  width: 90%;
  aspect-ratio: 1;
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 30%, rgba(var(--accent-rgb), 0.95), rgba(var(--accent-rgb), 0.4) 55%, rgba(var(--accent-rgb), 0.08) 78%);
  box-shadow: 0 0 110px rgba(var(--accent-rgb), 0.45), inset 0 0 60px rgba(255, 255, 255, 0.1);
}
.photo-ring {
  position: absolute;
  left: -2%; bottom: 3%;
  width: 104%;
  aspect-ratio: 1;
  border-radius: 50%;
  border: 1px dashed rgba(255, 255, 255, 0.28);
  animation: spin 50s linear infinite;
}
/* Foto lebih tinggi dari lingkaran → kepala menonjol keluar (efek 3D).
   Bagian bawah (paha) memudar halus. */
.photo-img {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 112%;
  width: auto;
  max-width: 100%;
  margin-inline: auto;
  object-fit: contain;
  object-position: bottom;
  -webkit-mask-image: linear-gradient(to bottom, #000 78%, transparent 100%);
  mask-image: linear-gradient(to bottom, #000 78%, transparent 100%);
  filter: drop-shadow(0 20px 40px rgba(0, 0, 0, 0.45));
}
.chip { position: absolute; z-index: 3; }
.chip-in {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 15px;
  border-radius: 999px;
  font: 600 0.85rem var(--font-head);
  white-space: nowrap;
  animation: float 6s ease-in-out infinite;
}
.chip-in::before {
  content: "";
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--accent-soft);
}
.chip-1 { top: 16%; left: -2%; }
.chip-2 { top: 44%; right: -3%; }
.chip-3 { bottom: 13%; left: 2%; }
.chip-2 .chip-in { animation-delay: -2s; }
.chip-3 .chip-in { animation-delay: -4s; }

.about-text .section-title { max-width: 16ch; }
#about-paragraphs { display: grid; gap: 14px; margin-top: 22px; color: var(--muted); max-width: 56ch; }

.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin: 32px 0;
}
.stats li {
  padding: 16px 10px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.03);
  text-align: center;
}
.stat-value {
  display: block;
  font: 700 clamp(1.8rem, 5vw, 2.6rem) / 1.1 var(--font-head);
  background: linear-gradient(180deg, #fff, var(--accent-soft));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.stat-label { display: block; margin-top: 4px; font-size: 0.78rem; line-height: 1.35; color: var(--muted); }
.about-actions { display: flex; flex-wrap: wrap; gap: 14px; }

/* ---------- Skills ---------- */
.skill-groups {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
  gap: 20px;
  margin-top: 48px;
}
.skill-group { padding: 24px; }
.skill-group h3 {
  margin-bottom: 18px;
  font: 600 0.8rem var(--font-head);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}
.skill-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(88px, 1fr)); gap: 12px; }
.skill-tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 18px 8px 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.03);
  font-size: 0.8rem;
  color: var(--muted);
  transition: transform 0.2s ease-out, border-color 0.3s, color 0.3s, box-shadow 0.3s;
}
.skill-tile i { font-size: 2rem; line-height: 1; color: var(--text); transition: color 0.3s; }
/* Skill tanpa ikon: tampil sebagai kotak berisi singkatan */
.skill-glyph {
  display: grid; place-items: center;
  width: 2rem; height: 2rem;
  border: 1.5px solid currentColor;
  border-radius: 8px;
  font: 700 0.62rem var(--font-head);
  letter-spacing: 0.04em;
  color: var(--text);
  transition: color 0.3s;
}
.skill-tile:hover .skill-glyph { color: var(--accent-soft); }
/* Tile berwarna merek (Word, Excel, dst.) */
.skill-glyph.is-brand {
  border-color: transparent;
  background: var(--c);
  color: #fff;
  font-size: 0.95rem;
  letter-spacing: 0;
}
.skill-tile:hover .skill-glyph.is-brand { color: #fff; box-shadow: 0 0 18px var(--c); }
/* Logo Simple Icons: dipakai sebagai mask supaya warnanya mengikuti tema */
.skill-si {
  width: 2rem; height: 2rem;
  background-color: var(--text);
  -webkit-mask: var(--si) center / contain no-repeat;
  mask: var(--si) center / contain no-repeat;
  transition: background-color 0.3s;
}
.skill-tile:hover .skill-si { background-color: var(--accent-soft); }
.skill-tile:hover {
  border-color: rgba(var(--accent-rgb), 0.6);
  color: var(--text);
  box-shadow: 0 0 28px rgba(var(--accent-rgb), 0.25);
}
.skill-tile:hover i { color: var(--accent-soft); }

/* ---------- Proyek ---------- */
.filters {
  display: flex;
  gap: 10px;
  margin: 36px 0 28px;
  padding-bottom: 6px;
  overflow-x: auto;
  scrollbar-width: none;
}
.filters::-webkit-scrollbar { display: none; }
.pill {
  flex: none;
  min-height: 44px;
  padding: 0 1.2rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font: 500 0.95rem var(--font-body);
  cursor: pointer;
  transition: background 0.25s, color 0.25s, border-color 0.25s;
}
.pill:hover { color: var(--text); border-color: rgba(255, 255, 255, 0.25); }
.pill[aria-pressed="true"] {
  background: var(--accent-strong);
  border-color: var(--accent-strong);
  color: var(--on-accent);
}

.project-grid { display: grid; grid-template-columns: 1fr; gap: 20px; }
.project-card {
  display: flex;
  flex-direction: column;
  width: 100%;
  padding: 0;
  overflow: hidden;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: transform 0.2s ease-out, border-color 0.3s, box-shadow 0.3s;
  animation: card-in 0.55s cubic-bezier(0.2, 0.7, 0.2, 1) both;
  animation-delay: calc(var(--i, 0) * 70ms);
}
.project-card:hover {
  border-color: rgba(var(--accent-rgb), 0.55);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.4), 0 0 40px rgba(var(--accent-rgb), 0.18);
}
.thumb {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: linear-gradient(135deg, hsl(var(--h) 85% 52%), hsl(calc(var(--h) + 60) 75% 24%));
}
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.thumb-ui {
  position: absolute;
  inset: 16% 9% 0;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-bottom: 0;
  border-radius: 12px 12px 0 0;
  background: rgba(10, 10, 16, 0.62);
  transition: transform 0.4s ease-out;
}
.thumb-ui::before {
  content: "";
  position: absolute;
  left: 12px; top: 10px;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #ff5f57;
  box-shadow: 14px 0 #febc2e, 28px 0 #28c840;
}
.thumb-ui::after {
  content: "";
  position: absolute;
  inset: 34px 14px 0;
  background:
    linear-gradient(rgba(255, 255, 255, 0.22), rgba(255, 255, 255, 0.22)) 0 0 / 55% 8px no-repeat,
    linear-gradient(rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.12)) 0 22px / 90% 6px no-repeat,
    linear-gradient(rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.12)) 0 38px / 75% 6px no-repeat,
    linear-gradient(rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.08)) 0 62px / 100% 40px no-repeat;
}
.project-card:hover .thumb-ui { transform: translateY(-6px); }
.project-body { display: grid; gap: 10px; padding: 20px 22px 24px; }
.project-cat {
  font: 600 0.75rem var(--font-head);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent-soft);
}
.project-body h3 { font: 700 1.3rem / 1.25 var(--font-head); letter-spacing: -0.01em; }
.project-body p { color: var(--muted); font-size: 0.95rem; }
.tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.tag {
  padding: 4px 11px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  font-size: 0.78rem;
  color: var(--muted);
}
.more {
  margin-top: 6px;
  font: 600 0.9rem var(--font-head);
  color: var(--accent-soft);
}

/* ---------- Modal ---------- */
.modal {
  width: min(100% - 32px, 760px);
  max-height: min(90vh, 90dvh);
  margin: auto;
  padding: 0;
  overflow: auto;
  overscroll-behavior: contain;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--surface);
  color: var(--text);
}
.modal[open] { animation: modal-in 0.35s cubic-bezier(0.2, 0.8, 0.2, 1); }
.modal::backdrop {
  background: rgba(4, 4, 8, 0.72);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
}
.modal-close {
  position: sticky;
  top: 12px;
  z-index: 5;
  display: grid; place-items: center;
  width: 44px; height: 44px;
  margin: 12px 12px -56px auto;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: rgba(10, 10, 15, 0.7);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  color: var(--text);
  font-size: 1rem;
  cursor: pointer;
}
.modal-close:hover { border-color: var(--accent-soft); }
.modal-media { aspect-ratio: 16 / 9; position: relative; overflow: hidden; }
.modal-media > img { width: 100%; height: 100%; object-fit: cover; }
.modal-thumbs { display: flex; gap: 8px; padding: 12px 24px 0; overflow-x: auto; }
.modal-thumbs button {
  flex: none;
  width: 72px; height: 48px;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 10px;
  overflow: hidden;
  background: none;
  cursor: pointer;
  opacity: 0.6;
}
.modal-thumbs button[aria-current="true"] { border-color: var(--accent-soft); opacity: 1; }
.modal-thumbs img { width: 100%; height: 100%; object-fit: cover; }
.modal-content { display: grid; gap: 22px; padding: 26px clamp(20px, 5vw, 36px) 32px; }
.modal-content h3 { font: 700 clamp(1.5rem, 4vw, 2rem) / 1.2 var(--font-head); letter-spacing: -0.02em; }
.modal-section h4 {
  margin: 0 0 6px;
  font: 600 0.78rem var(--font-head);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent-soft);
}
.modal-section p { color: var(--muted); }
.modal-links { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- Timeline ---------- */
.timeline { position: relative; margin-top: 56px; }
.timeline-line {
  position: absolute;
  top: 6px; bottom: 6px; left: 15px;
  width: 2px;
  background: var(--line);
}
.timeline-line span {
  display: block;
  width: 100%;
  height: calc(var(--p, 0) * 100%);
  background: linear-gradient(var(--accent-strong), var(--accent-soft));
  box-shadow: 0 0 14px rgba(var(--accent-rgb), 0.7);
}
.tl-item { position: relative; padding: 0 0 44px 48px; }
.tl-item:last-child { padding-bottom: 0; }
.tl-dot {
  position: absolute;
  left: 8px; top: 6px;
  width: 16px; height: 16px;
  border: 2px solid var(--line);
  border-radius: 50%;
  background: var(--bg);
  transition: border-color 0.4s, background 0.4s, box-shadow 0.4s;
}
.tl-item.is-active .tl-dot {
  border-color: var(--accent-soft);
  background: var(--accent);
  box-shadow: 0 0 16px rgba(var(--accent-rgb), 0.8);
}
.tl-card { padding: 20px 22px; }
.tl-period { font: 600 0.8rem var(--font-head); letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent-soft); }
.tl-card h3 { margin-top: 6px; font: 700 1.25rem / 1.3 var(--font-head); }
.tl-place { color: var(--muted); font-size: 0.95rem; }
.tl-card p:last-child { margin-top: 10px; color: var(--muted); font-size: 0.95rem; }

/* ---------- Kontak ---------- */
.contact-grid { display: grid; gap: 48px; }
.contact-text { max-width: 44ch; margin-top: 20px; color: var(--muted); }
.socials { display: flex; flex-wrap: wrap; gap: 10px; margin: 28px 0 22px; }
.socials a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 1.1rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 0.95rem;
  transition: border-color 0.25s, background 0.25s, transform 0.2s;
}
.socials a:hover { border-color: var(--accent-soft); background: rgba(var(--accent-rgb), 0.12); transform: translateY(-2px); }
.mail-link {
  display: inline-block;
  font: 600 clamp(1.1rem, 4vw, 1.5rem) var(--font-head);
  color: var(--accent-soft);
  border-bottom: 1px solid rgba(var(--accent-rgb), 0.5);
  overflow-wrap: anywhere;
}

.contact-form { display: grid; gap: 18px; padding: clamp(20px, 4vw, 32px); }
.field { display: grid; gap: 8px; }
.field label { font: 600 0.9rem var(--font-head); }
.field input, .field textarea {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  font: 400 1rem var(--font-body); /* 16px: mencegah zoom otomatis di iPhone */
  transition: border-color 0.25s, box-shadow 0.25s;
}
.field textarea { resize: vertical; min-height: 130px; }
.field input::placeholder, .field textarea::placeholder { color: #6c6c82; }
.field input:focus, .field textarea:focus {
  outline: none;
  border-color: var(--accent-soft);
  box-shadow: 0 0 0 3px rgba(var(--accent-rgb), 0.25);
}
.field.is-invalid input, .field.is-invalid textarea { border-color: #fb7185; }
.error { min-height: 0; font-size: 0.85rem; color: #fb7185; }
.error:empty { display: none; }
.form-status { min-height: 1.4em; text-align: center; font-size: 0.95rem; color: #6ee7b7; }
.form-status.is-error { color: #fb7185; }
.btn:disabled { opacity: 0.6; cursor: wait; transform: none; }
/* Kolom jebakan untuk bot: tidak terlihat oleh pengunjung */
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ---------- Footer ---------- */
.footer { padding: 36px 0; border-top: 1px solid var(--line); color: var(--muted); font-size: 0.9rem; }
.footer-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.to-top {
  flex: none;
  width: 46px; height: 46px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  font-size: 1.1rem;
  cursor: pointer;
  transition: border-color 0.25s, transform 0.2s, background 0.25s;
}
.to-top:hover { border-color: var(--accent-soft); background: rgba(var(--accent-rgb), 0.15); transform: translateY(-3px); }

/* ========== ANIMASI ========== */
@keyframes rise { to { transform: translateY(0); } }
@keyframes fade-up { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes blink { 50% { opacity: 0; } }
@keyframes pulse { 0% { transform: scale(1); opacity: 0.7; } 100% { transform: scale(3); opacity: 0; } }
@keyframes scroll-dot { 0% { transform: translateY(0); opacity: 1; } 70% { transform: translateY(14px); opacity: 0; } 100% { opacity: 0; } }
@keyframes card-in { from { opacity: 0; transform: translateY(22px) scale(0.97); } to { opacity: 1; transform: none; } }
@keyframes modal-in { from { opacity: 0; transform: translateY(24px) scale(0.97); } to { opacity: 1; transform: none; } }
@keyframes drift-a { to { transform: translate(14vmax, 10vmax) scale(1.15); } }
@keyframes drift-b { to { transform: translate(-12vmax, -8vmax) scale(1.1); } }
@keyframes drift-c { to { transform: translate(-10vmax, 12vmax) scale(0.9); } }

/* ========== 5. RESPONSIF (makin lebar layar → makin banyak kolom) ========== */
@media (min-width: 640px) {
  .skill-group { padding: 28px; }
}

@media (min-width: 700px) {
  .project-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 900px) {
  /* Navbar penuh, burger hilang */
  .burger, .menu { display: none; }
  .nav-links { display: flex; gap: 4px; margin-left: auto; }
  .nav-links a {
    display: block;
    padding: 9px 14px;
    border-radius: 999px;
    font-size: 0.95rem;
    color: var(--muted);
    transition: color 0.2s, background 0.2s;
  }
  .nav-links a:hover { color: var(--text); background: rgba(255, 255, 255, 0.06); }
  .nav-links a[aria-current] { color: var(--text); background: rgba(var(--accent-rgb), 0.18); }
  .nav-cta { display: inline-flex; }

  .about-grid { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); }
  .about-visual { display: block; width: 100%; max-width: 520px; justify-self: center; }
  .contact-grid { grid-template-columns: 1fr 1fr; align-items: start; gap: 72px; }

  /* Timeline bergantian kiri-kanan */
  .timeline-line { left: 50%; margin-left: -1px; }
  .tl-item { width: 50%; padding: 0 56px 52px 0; }
  .tl-item:nth-child(even) { margin-left: 50%; padding: 0 0 52px 56px; }
  .tl-item .tl-dot { left: auto; right: -8px; }
  .tl-item:nth-child(even) .tl-dot { right: auto; left: -8px; }
  .tl-item:nth-child(odd) .tl-card { text-align: right; }
}

@media (min-width: 1100px) {
  .project-grid { grid-template-columns: repeat(3, 1fr); }
}

/* Layar sangat kecil */
@media (max-width: 380px) {
  .stats { gap: 8px; }
  .stats li { padding: 14px 6px; }
  .chip-in { padding: 8px 12px; font-size: 0.78rem; }
}

/* Pengguna yang meminta animasi dikurangi */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  .js .reveal, .js .reveal-load { opacity: 1; transform: none; }
  .hero-name .char { transform: none; }
  .aurora span { animation: none; }
}

/* ========== HALAMAN LAIN: blog, proyek, testimoni ========== */
.container-narrow { width: min(100% - 2 * var(--gutter), 760px); margin-inline: auto; }
.page-head { padding-top: clamp(120px, 16vw, 170px); }
.page-lead { max-width: 56ch; margin-top: 16px; color: var(--muted); }
.section-more { margin-top: 36px; }
.empty-note { margin-top: 40px; color: var(--muted); }

.crumbs { margin-bottom: 22px; font-size: 0.9rem; color: var(--muted); }
.crumbs a { color: var(--accent-soft); }
.crumbs a:hover { text-decoration: underline; }

/* Tombol filter tag memakai tautan */
a.pill { display: inline-flex; align-items: center; }
.tag-filter { display: flex; flex-wrap: wrap; gap: 10px; margin: 32px 0 8px; }
a.tag { transition: border-color 0.25s, color 0.25s; }
a.tag:hover { border-color: var(--accent-soft); color: var(--text); }

/* Kartu tulisan */
.post-grid { display: grid; grid-template-columns: 1fr; gap: 20px; margin-top: 40px; }
.post-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transition: transform 0.2s ease-out, border-color 0.3s, box-shadow 0.3s;
}
.post-card:hover { border-color: rgba(var(--accent-rgb), 0.55); box-shadow: 0 18px 50px rgba(0, 0, 0, 0.4), 0 0 40px rgba(var(--accent-rgb), 0.18); }
.post-card-cover { width: 100%; aspect-ratio: 16 / 8.4; object-fit: cover; background: var(--surface-2); }
.post-card-placeholder {
  display: grid; place-items: center;
  background: linear-gradient(135deg, rgba(var(--accent-rgb), 0.55), rgba(40, 20, 90, 0.9));
}
.post-card-placeholder span { font: 700 3rem var(--font-head); color: rgba(255, 255, 255, 0.35); }
.post-card-body { display: grid; gap: 10px; padding: 20px 22px 24px; }
.post-card h3 { font: 700 1.25rem / 1.3 var(--font-head); letter-spacing: -0.01em; }
.post-excerpt { color: var(--muted); font-size: 0.95rem; }
.post-meta { display: flex; flex-wrap: wrap; gap: 8px; font-size: 0.85rem; color: var(--muted); }

.pager { display: flex; justify-content: space-between; gap: 12px; margin-top: 40px; }

/* Satu tulisan / satu proyek */
.post-title { margin: 18px 0 10px; font: 700 clamp(2rem, 5.5vw, 3.2rem) / 1.12 var(--font-head); letter-spacing: -0.025em; }
.post .post-meta { margin-top: 6px; }
.post-cover { width: 100%; height: auto; margin: 32px 0 8px; border: 1px solid var(--line); border-radius: var(--radius); }
.post-footer { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 56px; padding-top: 28px; border-top: 1px solid var(--line); }

.prose { margin-top: 32px; font-size: 1.05rem; line-height: 1.8; color: #d6d6e2; overflow-wrap: anywhere; }
.prose > * + * { margin-top: 1.2em; }
.prose h2, .prose h3, .prose h4 { color: var(--text); font-family: var(--font-head); line-height: 1.25; letter-spacing: -0.015em; margin-top: 2em; }
.prose h2 { font-size: 1.7rem; }
.prose h3 { font-size: 1.3rem; }
.prose a { color: var(--accent-soft); text-decoration: underline; text-underline-offset: 3px; }
.prose strong { color: var(--text); }
.prose ul, .prose ol { padding-left: 1.4em; }
.prose ul { list-style: disc; }
.prose li + li { margin-top: 0.4em; }
.prose blockquote { padding: 4px 0 4px 20px; border-left: 3px solid var(--accent); color: var(--muted); font-style: italic; }
.prose code { padding: 2px 7px; border-radius: 6px; background: rgba(255, 255, 255, 0.08); font: 0.9em ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.prose pre { padding: 18px 20px; overflow-x: auto; border: 1px solid var(--line); border-radius: 14px; background: rgba(0, 0, 0, 0.4); }
.prose pre code { padding: 0; background: none; }
.prose img { height: auto; border-radius: 14px; }
.prose hr { border: 0; border-top: 1px solid var(--line); margin-block: 2.5em; }
.prose table { width: 100%; border-collapse: collapse; font-size: 0.95rem; }
.prose th, .prose td { padding: 10px 12px; border: 1px solid var(--line); text-align: left; }

.project-links { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.project-gallery { display: grid; grid-template-columns: 1fr; gap: 14px; margin-top: 36px; }
.project-gallery img { width: 100%; height: auto; border: 1px solid var(--line); border-radius: 16px; }
.project-hero { margin-top: 36px; border-radius: var(--radius); }
.case-study { display: grid; gap: 28px; margin-top: 48px; }
.case-block h2 { margin-bottom: 8px; font: 600 0.8rem var(--font-head); letter-spacing: 0.16em; text-transform: uppercase; color: var(--accent-soft); }
.case-block p { color: #d6d6e2; max-width: 62ch; }
.project-nav { display: grid; grid-template-columns: 1fr; gap: 14px; margin-top: 64px; }
.project-nav a { display: grid; gap: 4px; padding: 18px 22px; }
.project-nav small { color: var(--muted); }
.project-nav strong { font: 700 1.05rem var(--font-head); }
.project-nav .next { text-align: right; }

.draft-banner {
  position: relative;
  z-index: 5;
  margin: 92px auto -80px;
  width: min(100% - 2 * var(--gutter), 760px);
  padding: 12px 18px;
  border: 1px solid rgba(251, 191, 36, 0.5);
  border-radius: 14px;
  background: rgba(251, 191, 36, 0.12);
  color: #fde68a;
  font-size: 0.92rem;
}
.draft-banner a { margin-left: 8px; text-decoration: underline; }

/* Testimoni */
.testimonial-grid { display: grid; grid-template-columns: 1fr; gap: 20px; margin-top: 44px; }
.testimonial { display: flex; flex-direction: column; justify-content: space-between; gap: 22px; margin: 0; padding: 26px; }
.testimonial blockquote { margin: 0; font-size: 1.05rem; line-height: 1.7; color: #e4e4ef; }
.testimonial figcaption { display: flex; align-items: center; gap: 14px; }
.testimonial figcaption span:last-child { display: grid; gap: 2px; }
.testimonial small { color: var(--muted); }
.avatar { flex: none; width: 44px; height: 44px; border-radius: 50%; object-fit: cover; }
.avatar-fallback { display: grid; place-items: center; background: var(--accent-strong); color: var(--on-accent); font: 700 1rem var(--font-head); }

@media (min-width: 700px) {
  .post-grid, .testimonial-grid { grid-template-columns: repeat(2, 1fr); }
  .project-gallery:not(.is-single) { grid-template-columns: repeat(2, 1fr); }
  .project-nav { grid-template-columns: 1fr 1fr; }
}
@media (min-width: 1100px) {
  .post-grid, .testimonial-grid { grid-template-columns: repeat(3, 1fr); }
  /* Nama di navbar hanya muncul di layar lebar agar menu tidak sesak */
  .logo-name { display: inline; }
}

.page-head .tags { margin-top: 18px; }

/* Tulisan unggulan */
.badge-featured {
  justify-self: start;
  display: inline-block;
  width: fit-content;
  padding: 3px 12px;
  border: 1px solid rgba(251, 191, 36, 0.5);
  border-radius: 999px;
  background: rgba(251, 191, 36, 0.12);
  color: #fcd34d;
  font: 600 0.72rem var(--font-head);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.featured-post {
  display: grid;
  grid-template-columns: 1fr;
  margin-top: 40px;
  overflow: hidden;
  transition: border-color 0.3s, box-shadow 0.3s;
}
.featured-post:hover { border-color: rgba(var(--accent-rgb), 0.55); box-shadow: 0 18px 50px rgba(0, 0, 0, 0.4), 0 0 40px rgba(var(--accent-rgb), 0.18); }
.featured-cover { width: 100%; height: 100%; min-height: 200px; aspect-ratio: 16 / 9; object-fit: cover; }
.featured-body { display: grid; align-content: center; gap: 12px; padding: 24px; }
.featured-body h2 { font: 700 clamp(1.5rem, 3.5vw, 2.1rem) / 1.2 var(--font-head); letter-spacing: -0.02em; }
.list-heading { margin-top: 44px; font: 600 0.8rem var(--font-head); letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted); }
.list-heading + .post-grid { margin-top: 16px; }
@media (min-width: 900px) {
  .featured-post { grid-template-columns: 1.1fr 1fr; }
  .featured-cover { aspect-ratio: auto; }
  .featured-body { padding: 36px; }
}
