/* =========================================================
   TOKEN DASAR
   ========================================================= */
:root {
  --navy-900: #0f172a;
  --navy-800: #1e293b;
  --azure-500: #3b82f6;
  --azure-600: #2563eb;
  --cyan-400: #22d3ee;
  --cyan-500: #06b6d4;
  --ink: #0f172a;
}

* {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  * {
    scroll-behavior: auto;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

body {
  font-family: "Inter", sans-serif;
}
.icon-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }

::selection {
  background: var(--cyan-400);
  color: var(--navy-900);
}

:focus-visible {
  outline: 2px solid var(--cyan-400);
  outline-offset: 2px;
  border-radius: 4px;
}

/* =========================================================
   HEADER / NAV
   ========================================================= */
#site-header {
  background: rgba(15, 23, 42, 0.82);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
}
#site-header.is-scrolled {
  background: rgba(15, 23, 42, 0.94);
  backdrop-filter: blur(16px);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.08);
}

.logo-mark {
  font-family: "Inter", sans-serif;
  font-weight: 700;
  font-size: 1.35rem;
  color: #fff;
  letter-spacing: -0.01em;
}
.navbar-logo {
  display: block;
  width: 112px;
  height: 48px;
  object-fit: cover;
  object-position: center;
}

.nav-pill {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 999px;
  padding: 4px;
}

.nav-link {
  color: rgba(255, 255, 255, 0.75);
  font-size: 0.875rem;
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: 999px;
  transition: color 0.2s ease, background-color 0.2s ease;
}
.nav-link:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
}
.nav-link.is-active {
  color: #67e8f9;
  background: rgba(34, 211, 238, 0.1);
}

.nav-link-mobile {
  color: rgba(255, 255, 255, 0.8);
  font-weight: 500;
  padding: 0.65rem 0.25rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.btn-ghost {
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #fff;
  font-size: 0.875rem;
  font-weight: 600;
  padding: 0.5rem 1.1rem;
  border-radius: 999px;
  transition: background-color 0.2s ease, border-color 0.2s ease;
}
.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.4);
}

.btn-icon {
  color: #fff;
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

/* =========================================================
   HERO
   ========================================================= */
.hero-section {
  padding-top: 0;
  isolation: isolate;
  background: radial-gradient(circle at 80% 20%, rgba(59, 130, 246, 0.16), transparent 34%), radial-gradient(circle at 20% 80%, rgba(34, 211, 238, 0.08), transparent 28%), #0f172a;
}

.grid-overlay {
  position: absolute;
  inset: 0;
  background-image: linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse at top left, black 0%, transparent 65%);
  z-index: 0;
}

.blob-a,
.blob-b,
.blob-c {
  position: absolute;
  border-radius: 999px;
  filter: blur(70px);
  z-index: 0;
  pointer-events: none;
}
.blob-a {
  width: 420px;
  height: 420px;
  top: -120px;
  right: -100px;
  background: radial-gradient(circle, rgba(53, 104, 238, 0.55), transparent 70%);
}
.blob-b {
  width: 320px;
  height: 320px;
  bottom: -140px;
  left: -80px;
  background: radial-gradient(circle, rgba(34, 211, 238, 0.18), transparent 70%);
}
.blob-c {
  width: 380px;
  height: 380px;
  top: -100px;
  left: 50%;
  transform: translateX(-50%);
  background: radial-gradient(circle, rgba(53, 104, 238, 0.4), transparent 70%);
}

.status-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.85);
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.14);
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
}
.dot-live {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: #34d399;
  box-shadow: 0 0 0 0 rgba(52, 211, 153, 0.6);
  animation: pulse-dot 2.2s ease-out infinite;
}
@keyframes pulse-dot {
  0% {
    box-shadow: 0 0 0 0 rgba(52, 211, 153, 0.55);
  }
  75% {
    box-shadow: 0 0 0 8px rgba(52, 211, 153, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(52, 211, 153, 0);
  }
}

.wavy-underline {
  position: relative;
  font-weight: 600;
}
.wavy-underline::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -6px;
  height: 8px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='8' viewBox='0 0 24 8'%3E%3Cpath d='M0 4 Q3 0 6 4 T12 4 T18 4 T24 4' fill='none' stroke='%2322D3EE' stroke-width='2'/%3E%3C/svg%3E");
  background-repeat: repeat-x;
  background-size: 24px 8px;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--azure-500);
  color: #fff;
  font-weight: 700;
  font-size: 0.95rem;
  padding: 0.75rem 1.4rem;
  border-radius: 999px;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  box-shadow: 0 8px 24px -8px rgba(59, 130, 246, 0.55);
}
.btn-primary:hover {
  transform: translateY(-2px);
  background: var(--azure-600);
  box-shadow: 0 12px 28px -8px rgba(59, 130, 246, 0.55);
}

.btn-outline {
  display: inline-flex;
  align-items: center;
  border: 1.5px solid rgba(255, 255, 255, 0.3);
  color: #fff;
  font-weight: 600;
  font-size: 0.95rem;
  padding: 0.72rem 1.35rem;
  border-radius: 999px;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}
.btn-outline:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.55);
}

.btn-text {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  color: rgba(255, 255, 255, 0.85);
  font-weight: 600;
  font-size: 0.95rem;
  padding: 0.72rem 0.4rem;
  transition: gap 0.2s ease, color 0.2s ease;
}
.btn-text:hover {
  gap: 0.6rem;
  color: #fff;
}

.hero-photo-wrap {
  position: relative;
  width: min(360px, 78vw);
  aspect-ratio: 1 / 1;
}
.hero-photo-ring {
  position: absolute;
  inset: -14px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--azure-500), var(--cyan-400));
  opacity: 0.9;
}
.hero-photo {
  position: relative;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  border: 4px solid #0f172a;
  background: radial-gradient(circle at 50% 25%, #1e3a5f, #1e293b 65%);
}
.img-fallback .hero-photo,
.img-fallback.hero-photo-wrap .hero-photo {
  display: none;
}
.img-fallback::before {
  content: "";
}

.badge-float {
  position: absolute;
  font-family: "Inter", sans-serif;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--navy-900);
  background: #fff;
  padding: 0.4rem 0.75rem;
  border-radius: 999px;
  box-shadow: 0 10px 24px -8px rgba(0, 0, 0, 0.35);
  animation: float-badge 5s ease-in-out infinite;
}
.badge-float-a {
  top: 6%;
  left: -6%;
  animation-delay: 0.3s;
}
.badge-float-b {
  bottom: 8%;
  right: -8%;
  animation-delay: 1.1s;
}
@keyframes float-badge {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-10px);
  }
}

.scroll-cue {
  position: absolute;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  color: rgba(255, 255, 255, 0.6);
  animation: bounce-cue 2s ease-in-out infinite;
}
@keyframes bounce-cue {
  0%,
  100% {
    transform: translate(-50%, 0);
  }
  50% {
    transform: translate(-50%, 8px);
  }
}

/* =========================================================
   SECTION UMUM
   ========================================================= */
.section-pad {
  padding-block: clamp(3.5rem, 6vw, 6rem);
}
.section-pad-lg {
  padding-block: clamp(4rem, 8vw, 7rem);
}

.section-title {
  font-family: "Inter", sans-serif;
  font-weight: 600;
  font-size: clamp(1.9rem, 3vw, 2.5rem);
  color: var(--navy-900);
  letter-spacing: -0.01em;
}
.section-sub {
  margin-top: 0.5rem;
  color: rgba(11, 18, 32, 0.55);
  font-size: 1rem;
}

.pill-tag {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--navy-800);
  background: rgba(53, 104, 238, 0.08);
  border: 1px solid rgba(53, 104, 238, 0.18);
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
}

/* Reveal saat masuk viewport */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}
.reveal-delay-1.is-visible {
  transition-delay: 0.12s;
}
.reveal-delay-2.is-visible {
  transition-delay: 0.24s;
}

/* =========================================================
   TENTANG
   ========================================================= */
.about-card {
  background: #fff;
  border: 1px solid rgba(10, 27, 56, 0.08);
  border-radius: 24px;
  padding: 0.5rem 1.5rem;
  box-shadow: 0 20px 40px -24px rgba(10, 27, 56, 0.25);
}
.about-row {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1.15rem 0;
}
.about-icon {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: #f1f5f9;
  color: var(--azure-600);
}
.about-icon svg {
  width: 22px;
  height: 22px;
}
.about-label {
  font-size: 0.75rem;
  color: rgba(11, 18, 32, 0.5);
  font-weight: 500;
}
.about-value {
  font-weight: 600;
  color: var(--ink);
  transition: color 0.2s ease;
}

/* =========================================================
   KEAHLIAN (chip fleksibel)
   ========================================================= */
.skill-group-title {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  font-family: "Inter", sans-serif;
  font-weight: 600;
  font-size: 1.1rem;
  color: var(--navy-900);
  margin-bottom: 1.1rem;
}
.skill-dot {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  display: inline-block;
}

.chip-cloud {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem;
}

.chip {
  font-family: "Inter", sans-serif;
  font-weight: 600;
  color: var(--navy-800);
  background: rgba(53, 104, 238, 0.08);
  border: 1px solid rgba(53, 104, 238, 0.16);
  border-radius: 999px;
  padding: 0.5rem 1rem;
  font-size: 0.8rem;
  transition: transform 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}
.chip:hover {
  transform: translateY(-3px) rotate(-1deg);
  background: rgba(53, 104, 238, 0.14);
  box-shadow: 0 10px 20px -12px rgba(53, 104, 238, 0.5);
}
/* Ukuran mengikuti level penguasaan */
/* =========================================================
   PROJECT / PRODUK
   ========================================================= */
.project-card {
  background: #fff;
  border-radius: 22px;
  border: 1px solid rgba(10, 27, 56, 0.08);
  overflow: hidden;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}
.project-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 24px 48px -24px rgba(10, 27, 56, 0.35);
  border-color: rgba(53, 104, 238, 0.3);
}
.project-card:nth-child(even):hover {
  border-color: rgba(34, 211, 238, 0.4);
}

.project-media {
  aspect-ratio: 16 / 10;
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.12), rgba(34, 211, 238, 0.14));
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.project-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.project-media.img-fallback,
.project-media:has(img.img-fallback) {
  display: flex;
}

.project-body {
  padding: 1.5rem;
}

.tag-chip {
  font-family: "Inter", sans-serif;
  font-size: 0.68rem;
  font-weight: 600;
  color: var(--navy-800);
  background: rgba(10, 27, 56, 0.06);
  padding: 0.28rem 0.6rem;
  border-radius: 999px;
}

.project-title {
  margin-top: 0.9rem;
  font-family: "Inter", sans-serif;
  font-weight: 600;
  font-size: 1.2rem;
  color: var(--navy-900);
}
.project-desc {
  margin-top: 0.6rem;
  font-size: 0.92rem;
  line-height: 1.6;
  color: rgba(11, 18, 32, 0.65);
}
.project-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-top: 1.1rem;
  font-weight: 600;
  font-size: 0.88rem;
  color: var(--azure-600);
}
.project-links { display: flex; flex-wrap: wrap; align-items: center; column-gap: 1.5rem; row-gap: .25rem; }
.project-link::after {
  content: "→";
  transition: transform 0.2s ease;
}
.project-link:hover::after {
  transform: translateX(3px);
}

/* =========================================================
   KONTAK
   ========================================================= */
.contact-card {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 18px;
  padding: 1.1rem 1.25rem;
  transition: transform 0.2s ease, background-color 0.2s ease, border-color 0.2s ease;
}
.contact-card:hover {
  transform: translateY(-3px);
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(34, 211, 238, 0.4);
}
.contact-card--accent {
  background: rgba(34, 211, 238, 0.12);
  border-color: rgba(34, 211, 238, 0.3);
}
.contact-icon {
  flex-shrink: 0;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  color: #67e8f9;
}
.contact-icon svg {
  width: 22px;
  height: 22px;
}
.footer-link { display: inline-flex; align-items: center; gap: .5rem; color: rgba(248, 250, 252, .8); transition: color .2s ease; }
.footer-link:hover { color: #fff; }
.footer-icon { display: inline-flex; align-items: center; justify-content: center; width: 26px; height: 26px; border-radius: 7px; background: #fff; }
.footer-icon svg { width: 17px; height: 17px; }
.footer-brand { width: 68px; height: 32px; object-fit: cover; object-position: center; flex-shrink: 0; }
.cv-dialog {
  width: min(960px, calc(100vw - 24px));
  height: min(92dvh, 900px);
  max-width: none;
  max-height: none;
  padding: 0;
  border: 1px solid #334155;
  border-radius: 18px;
  background: #f8fafc;
  box-shadow: 0 24px 70px rgba(0, 0, 0, .4);
  overflow: hidden;
}
.cv-dialog[open] { display: flex; flex-direction: column; }
.cv-dialog::backdrop { background: rgba(15, 23, 42, .8); backdrop-filter: blur(6px); }
.cv-dialog-header, .cv-dialog-footer { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .9rem 1.2rem; }
.cv-dialog-header { background: #0f172a; color: #f8fafc; }
.cv-dialog-header h2 { font-size: 1.05rem; font-weight: 700; }
.cv-dialog-eyebrow { color: #67e8f9; font-size: .7rem; text-transform: uppercase; letter-spacing: .08em; }
.cv-close { flex-shrink: 0; display: grid; place-items: center; width: 36px; height: 36px; border: 1px solid #475569; border-radius: 8px; color: #f8fafc; font-size: 1.6rem; line-height: 1; }
.cv-close:hover { background: #1e293b; }
.cv-preview { display: block; width: 100%; flex: 1; min-height: 0; border: 0; background: #e2e8f0; }
.cv-dialog-footer { background: #fff; color: #64748b; font-size: .78rem; }
.cv-dialog-actions { display: flex; flex-wrap: wrap; gap: .6rem; flex-shrink: 0; }
.cv-dialog-actions a { display: inline-flex; align-items: center; padding: .55rem .8rem; border: 1px solid #cbd5e1; border-radius: 8px; color: #0f172a; font-weight: 600; }
.cv-dialog-actions a:hover { border-color: #3b82f6; }
.cv-dialog-actions .cv-download { background: #2563eb; border-color: #2563eb; color: #fff; }
.cv-dialog-actions .cv-download:hover { background: #1d4ed8; }
.contact-label {
  display: block;
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.55);
  font-weight: 500;
}
.contact-value {
  display: block;
  font-weight: 600;
  color: #fff;
  font-size: 0.92rem;
  word-break: break-word;
}

/* Portfolio Thariq: layout dan komponen baru */
html { scroll-padding-top: 84px; }
body { overflow-x: hidden; }
.hero-section h1 { overflow-wrap: anywhere; }
.status-chip { border-color: rgba(34, 211, 238, .24); }
.dot-live { background: #22d3ee; animation: none; }
.hero-photo-wrap { filter: drop-shadow(0 20px 35px rgba(0, 0, 0, .2)); }
.hero-photo-ring { opacity: 1; }
.badge-float { animation: none; border: 1px solid rgba(59, 130, 246, .18); }
.section-sub { color: #64748b; max-width: 42rem; line-height: 1.65; }
.reveal { transition-duration: .45s; }
.about-card, .project-card, .education-card, .experience-card, .award-card { border-radius: 20px; }
.skill-group {
  padding: 1.5rem;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 18px;
  box-shadow: 0 12px 32px rgba(15, 23, 42, .04);
}
.skill-group-title { margin-bottom: 1rem; }
.chip { font-size: .78rem; font-weight: 600; background: #eff6ff; border-color: #dbeafe; color: #1e40af; }
.chip:hover { transform: translateY(-2px); background: #dbeafe; box-shadow: none; }
.project-card--featured { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.project-card--featured .project-media { height: 100%; min-height: 340px; aspect-ratio: auto; }
.project-card--featured .project-body { padding: clamp(1.5rem, 4vw, 3rem); align-self: center; }
.project-card--featured .project-media img { transition: transform .35s ease; }
.project-card--featured:hover .project-media img { transform: scale(1.035); }
.project-kicker { color: #2563eb; font-size: .75rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; margin-bottom: 1rem; }
.project-role { color: #0e7490; font-weight: 600; font-size: .88rem; margin-top: .35rem; }
.experience-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.25rem; }
.experience-card { position: relative; background: #fff; border: 1px solid #e2e8f0; padding: 1.5rem 1.5rem 1.5rem 1.85rem; box-shadow: 0 12px 32px rgba(15, 23, 42, .04); transition: transform .25s ease, border-color .25s ease; }
.experience-card::before { content: ""; position: absolute; left: 0; top: 1.4rem; bottom: 1.4rem; width: 3px; background: linear-gradient(#3b82f6, #22d3ee); }
.experience-card:hover, .education-card:hover, .award-card:hover { transform: translateY(-4px); border-color: #93c5fd; }
.experience-year, .education-year { color: #2563eb; font-size: .76rem; font-weight: 700; letter-spacing: .03em; }
.experience-card h3, .education-card h3, .award-card h3 { color: #0f172a; font-size: 1.08rem; font-weight: 700; margin-top: .45rem; }
.experience-role { color: #0e7490 !important; font-weight: 600; margin-top: .2rem !important; }
.experience-card p, .education-card p, .award-card p { color: #64748b; line-height: 1.65; margin-top: .7rem; font-size: .91rem; }
.experience-extra { border: 1px solid #dbeafe; border-radius: 16px; padding: 1.25rem 1.5rem; background: #eff6ff; }
.experience-extra h3 { color: #0f172a; font-weight: 700; }
.experience-extra p { color: #475569; margin-top: .3rem; line-height: 1.6; font-size: .9rem; }
.education-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.25rem; }
.education-card { display: flex; align-items: flex-start; gap: 1.25rem; background: #fff; border: 1px solid #e2e8f0; padding: 1.5rem; transition: transform .25s ease, border-color .25s ease; }
.education-logo, .education-initial { flex: 0 0 64px; width: 64px; height: 64px; object-fit: contain; }
.education-initial { display: grid; place-items: center; border-radius: 14px; background: #dbeafe; color: #1d4ed8; font-weight: 700; font-size: .85rem; }
.award-card { display: flex; align-items: flex-start; gap: 1.25rem; max-width: 720px; border: 1px solid #e2e8f0; padding: 1.5rem; box-shadow: 0 12px 32px rgba(15, 23, 42, .04); transition: transform .25s ease, border-color .25s ease; }
.award-icon { display: grid; place-items: center; flex: 0 0 50px; width: 50px; height: 50px; border-radius: 14px; color: #0e7490; background: #cffafe; font-size: 1.8rem; }
.contact-icon { font-weight: 700; font-size: 1.1rem; }
@media (max-width: 1023px) {
  .nav-link { padding: .5rem .65rem; font-size: .8rem; }
}
@media (max-width: 767px) {
  .cv-dialog-footer { flex-direction: column; align-items: stretch; }
  .cv-dialog-actions { justify-content: flex-end; }
  .hero-section h1 { font-size: clamp(2.15rem, 9vw, 3.4rem); }
  .hero-photo-wrap { width: min(300px, 70vw); margin: 0 auto; }
  .project-card--featured, .experience-grid, .education-grid { grid-template-columns: 1fr; }
  .project-card--featured .project-media { min-height: 0; aspect-ratio: 16 / 10; }
  .badge-float-a { left: -2%; }
  .badge-float-b { right: -2%; }
}
@media (max-width: 389px) {
  .contact-card { padding: .85rem; gap: .65rem; }
  .contact-value { font-size: .78rem; }
  .education-card { padding: 1.1rem; gap: .8rem; }
  .education-logo, .education-initial { flex-basis: 48px; width: 48px; height: 48px; }
}
