/* RESET */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Inter", sans-serif;
}

:root {
  --bg: #0b1224;
  --bg-2: #0f172a;
  --card: #0f192e;
  --muted: #94a3b8;
  --text: #e5e7eb;
  --accent: #38bdf8;
  --accent-2: #818cf8;
  --border: rgba(148, 163, 184, 0.14);
  --glow: 0 15px 45px rgba(56, 189, 248, 0.2);
}

html {
  scroll-behavior: smooth;
}

body {
  background:
    radial-gradient(circle at 15% 20%, rgba(56, 189, 248, 0.10), transparent 32%),
    radial-gradient(circle at 80% 8%, rgba(129, 140, 248, 0.12), transparent 28%),
    radial-gradient(1200px at 50% 120%, rgba(56, 189, 248, 0.05), transparent 40%),
    linear-gradient(135deg, #0b1224 0%, #0f172a 50%, #0b1224 100%);
  color: var(--text);
  line-height: 1.6;
  background-attachment: fixed;
}

.detail-page {
  background-attachment: fixed;
}

#particles-js {
  position: fixed;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
}

a {
  color: inherit;
}

.container {
  width: min(1100px, calc(100% - 2.5rem));
  margin: 0 auto;
}

/* NAVBAR */
.navbar {
  position: fixed;
  width: 100%;
  top: 0;
  padding: 0.75rem 0;
  background: linear-gradient(180deg, rgba(11, 18, 36, 0.72) 0%, rgba(11, 18, 36, 0.48) 100%);
  backdrop-filter: blur(14px) saturate(140%);
  border-bottom: 1px solid rgba(148, 163, 184, 0.16);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.28);
  z-index: 100;
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.2rem;
}

.logo {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--accent);
  letter-spacing: 0.02em;
}

.navbar nav {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.navbar nav a {
  text-decoration: none;
  color: var(--text);
  font-weight: 500;
  padding: 0.35rem 0.65rem;
  border-radius: 8px;
  transition: color 0.2s, background 0.2s;
}

.navbar nav a:hover {
  color: var(--accent);
  background: rgba(56, 189, 248, 0.08);
}

.navbar nav a.active {
  color: var(--accent);
  background: transparent;
  box-shadow: none;
}

/* Responsive Navbar */
@media (max-width: 768px) {
  .navbar nav {
    gap: 0.5rem;
    flex-wrap: wrap;
  }

  .navbar nav a {
    font-size: 0.85rem;
    padding: 0.3rem 0.5rem;
  }

  .logo {
    font-size: 1.1rem;
  }
}

/* HERO */
.hero {
  min-height: 100vh;
  padding: 7.5rem 0 4rem;
  display: flex;
  align-items: center;
}

.hero-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2.5rem;
  align-items: center;
}

.hero-visual {
  position: relative;
  min-height: 320px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
  padding: 1rem;
}

.hero-visual__glow {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 30% 30%, rgba(56, 189, 248, 0.25), transparent 40%),
              radial-gradient(circle at 70% 60%, rgba(129, 140, 248, 0.2), transparent 45%);
  filter: blur(20px);
  opacity: 0.9;
  z-index: 0;
}

.hero-lottie {
  position: relative;
  z-index: 1;
  width: min(2000px, 100%);
  aspect-ratio: 1;
  background: transparent;
  border: none;
  box-shadow: none;
  border-radius: 18px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-visual__card {
  position: relative;
  background: linear-gradient(160deg, rgba(56, 189, 248, 0.18), rgba(129, 140, 248, 0.14));
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 18px;
  padding: 1.6rem;
  min-width: 280px;
  max-width: 360px;
  box-shadow: var(--glow);
  display: grid;
  gap: 0.65rem;
  z-index: 1;
}

.hero-visual__chip {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  background: rgba(11, 18, 36, 0.55);
  color: var(--text);
  border: 1px solid rgba(148, 163, 184, 0.4);
  font-size: 0.9rem;
  width: fit-content;
}

.hero-visual__title {
  font-size: 1.1rem;
  font-weight: 700;
}

.hero-visual__stack {
  color: var(--muted);
  font-size: 0.95rem;
}

.hero-visual__metrics {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  font-size: 0.95rem;
}

.hero-visual__metrics span {
  background: rgba(11, 18, 36, 0.5);
  border: 1px solid rgba(148, 163, 184, 0.25);
  padding: 0.35rem 0.65rem;
  border-radius: 10px;
}

.hero h1 {
  font-size: clamp(2.4rem, 5vw, 3.4rem);
  line-height: 1.1;
  margin-bottom: 0.75rem;
}

.hero h1 span {
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero h2 {
  font-size: 1.1rem;
  color: var(--muted);
  margin-bottom: 1rem;
}

.hero p {
  max-width: 620px;
  color: #cbd5f5;
  margin-bottom: 1.5rem;
}

.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  margin: 1rem 0 1.4rem;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.4rem 0.9rem;
  border-radius: 999px;
  background: rgba(56, 189, 248, 0.12);
  color: var(--text);
  border: 1px solid rgba(56, 189, 248, 0.35);
  font-size: 0.95rem;
}

.pill.secondary {
  background: rgba(129, 140, 248, 0.14);
  border-color: rgba(129, 140, 248, 0.35);
}

.hero-buttons {
  display: flex;
  gap: 0.8rem;
  margin-top: 1rem;
}

.btn {
  padding: 0.85rem 1.5rem;
  border-radius: 10px;
  text-decoration: none;
  font-weight: 600;
  border: 1px solid transparent;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease, color 0.18s ease;
}

.primary {
  background: linear-gradient(120deg, var(--accent), var(--accent-2));
  color: #0b1020;
  box-shadow: var(--glow);
}

.primary:hover {
  transform: translateY(-2px);
}

.secondary {
  border: 1px solid rgba(56, 189, 248, 0.45);
  color: var(--text);
}

.secondary:hover {
  background: rgba(56, 189, 248, 0.12);
  transform: translateY(-2px);
}

/* SECTIONS */
.section {
  padding: 5.5rem 0;
}

.section.dark {
  background-color: rgba(2, 6, 23, 0.6);
  border-top: 1px solid rgba(148, 163, 184, 0.08);
  border-bottom: 1px solid rgba(148, 163, 184, 0.08);
}

.section-header {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  margin-bottom: 2rem;
}

.section-header h3 {
  font-size: 2rem;
}

.section-header p {
  color: var(--muted);
}

/* SKILLS */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
}

.skill-card {
  background: linear-gradient(160deg, rgba(56, 189, 248, 0.08), rgba(129, 140, 248, 0.05));
  border: 1px solid rgba(148, 163, 184, 0.18);
  padding: 1.4rem;
  border-radius: 14px;
  transition: transform 0.25s, border-color 0.25s, box-shadow 0.25s;
}

.skill-card:hover {
  transform: translateY(-4px);
  border-color: rgba(56, 189, 248, 0.4);
  box-shadow: var(--glow);
}

/* PROJECTS */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.4rem;
}

.project-card {
  background: radial-gradient(circle at 20% 20%, rgba(56, 189, 248, 0.12), transparent 45%), var(--card);
  padding: 1.5rem;
  border-radius: 14px;
  border: 1px solid rgba(148, 163, 184, 0.12);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
  text-decoration: none;
}

.project-card h4,
.project-card p {
  text-decoration: none;
}

.project-card a {
  display: inline-block;
  margin-top: 1rem;
  color: #38bdf8;
  text-decoration: none;
}

.project-card.tech-card {
  background: #0b1224;
  border-color: rgba(56, 189, 248, 0.15);
}

.project-card:hover {
  transform: translateY(-5px);
  border-color: rgba(56, 189, 248, 0.35);
  box-shadow: var(--glow);
}

/* CONTACT */
.contact-links {
  display: flex;
  gap: 2rem;
  flex-wrap: wrap;
}

.contact-links a {
  color: var(--text);
  text-decoration: none;
  font-size: 1.05rem;
  padding: 0.7rem 1.1rem;
  border-radius: 10px;
  border: 1px solid rgba(148, 163, 184, 0.2);
  background: rgba(148, 163, 184, 0.06);
  transition: transform 0.2s ease, border-color 0.2s ease, color 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.contact-links a:hover {
  transform: translateY(-2px);
  border-color: rgba(56, 189, 248, 0.45);
  color: var(--accent);
}

.contact-links img {
  width: 23px;
  height: 23px;
  object-fit: cover;
  display: inline-block;
  background: transparent;
}

.contact-links .icon-box {
  width: 21px;
  height: 21px;
  background: #fff;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.28);
}

/* FOOTER */
footer {
  text-align: center;
  padding: 2rem;
  font-size: 0.9rem;
  color: #94a3b8;
}

/* DETAIL PAGE */
.detail-wrap {
  display: grid;
  gap: 2rem;
}

.detail-hero {
  display: grid;
  gap: 0.6rem;
}

.detail-kicker {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.8rem;
  color: #8fbdf8;
}

.detail-hero h1 {
  font-size: clamp(2.2rem, 4vw, 3rem);
  line-height: 1.1;
}

.detail-sub {
  color: #cbd5f5;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.detail-block {
  position: relative;
  padding: 1.5rem 1.25rem 1.25rem 1.25rem;
  backdrop-filter: blur(6px);
  background: linear-gradient(120deg, rgba(148, 163, 184, 0.08), rgba(56, 189, 248, 0.03));
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 14px;
}

.detail-block::before {
  content: "";
  position: absolute;
  left: 0;
  top: 12px;
  bottom: 12px;
  width: 3px;
  border-radius: 8px;
  background: linear-gradient(180deg, var(--accent), var(--accent-2));
  opacity: 0.8;
}

.detail-title {
  font-weight: 700;
  margin-bottom: 0.35rem;
  letter-spacing: 0.01em;
  border-bottom: none;
  padding-bottom: 0;
}

.detail-body {
  color: #d5def5;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.detail-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.25rem;
  justify-items: center;
}

.gallery-chip {
  border: 1px dashed rgba(148, 163, 184, 0.35);
  border-radius: 12px;
  padding: 1.1rem;
  text-align: center;
  color: #cbd5f5;
  background: rgba(11, 18, 36, 0.4);
}

.gallery-image {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(148, 163, 184, 0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
  cursor: pointer;
  max-width: 400px;
  width: 100%;
}

.gallery-image:hover {
  transform: translateY(-4px);
  border-color: rgba(56, 189, 248, 0.5);
  box-shadow: 0 10px 30px rgba(56, 189, 248, 0.25);
}

.gallery-image img {
  width: 100%;
  max-width: 400px;
  height: auto;
  max-height: 600px;
  display: block;
  object-fit: contain;
  transition: transform 0.3s ease;
  margin: 0 auto;
}

.gallery-image:hover img {
  transform: scale(1.02);
}

.gallery-image-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(to top, rgba(11, 18, 36, 0.9), transparent);
  padding: 0.75rem;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.gallery-image:hover .gallery-image-overlay {
  opacity: 1;
}

.gallery-image-title {
  color: var(--text);
  font-size: 0.85rem;
  font-weight: 500;
  text-align: center;
}

/* Lightbox Modal */
.lightbox {
  display: none;
  position: fixed;
  z-index: 9999;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(11, 18, 36, 0.95);
  backdrop-filter: blur(10px);
  animation: fadeIn 0.3s ease;
}

.lightbox.active {
  display: flex;
  align-items: center;
  justify-content: center;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.lightbox-content {
  position: relative;
  max-width: 90%;
  max-height: 90%;
  margin: auto;
  animation: zoomIn 0.3s ease;
}

@keyframes zoomIn {
  from {
    transform: scale(0.8);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

.lightbox-content img {
  max-width: 100%;
  max-height: 90vh;
  width: auto;
  height: auto;
  border-radius: 12px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  object-fit: contain;
}

.lightbox-close {
  position: absolute;
  top: -40px;
  right: 0;
  color: var(--text);
  font-size: 2rem;
  font-weight: bold;
  cursor: pointer;
  background: rgba(11, 18, 36, 0.8);
  border: 1px solid rgba(148, 163, 184, 0.3);
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}

.lightbox-close:hover {
  background: rgba(56, 189, 248, 0.2);
  border-color: rgba(56, 189, 248, 0.5);
  transform: rotate(90deg);
}

.lightbox-title {
  position: absolute;
  bottom: -40px;
  left: 0;
  right: 0;
  text-align: center;
  color: var(--text);
  font-size: 1rem;
  font-weight: 500;
  padding: 0.5rem;
  background: rgba(11, 18, 36, 0.8);
  border-radius: 8px;
  margin-top: 1rem;
}

.detail-links {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.detail-link {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.85rem 1.2rem;
  border-radius: 12px;
  text-decoration: none;
  color: var(--text);
  background: radial-gradient(circle at 0% 0%, rgba(56,189,248,0.22), transparent 55%), rgba(15,23,42,0.9);
  border: 1px solid rgba(148, 163, 184, 0.32);
  box-shadow: 0 14px 35px rgba(15, 23, 42, 0.6);
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease, background 0.22s ease;
  min-width: 0;
}

.detail-link:hover {
  transform: translateY(-3px);
  border-color: rgba(56, 189, 248, 0.7);
  box-shadow: var(--glow);
  background: radial-gradient(circle at 0% 0%, rgba(56,189,248,0.28), transparent 55%), rgba(15,23,42,0.96);
}

.detail-link-icon {
  width: 32px;
  height: 32px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.98);
  border: 1px solid rgba(148, 163, 184, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.06em;
}

.detail-link-text {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  min-width: 0;
}

.detail-link-label {
  font-size: 0.95rem;
  font-weight: 600;
}

.detail-link-sub {
  font-size: 0.8rem;
  color: var(--muted);
  white-space: nowrap;
  text-overflow: ellipsis;
  overflow: hidden;
}

.detail-link-arrow {
  margin-left: auto;
  font-size: 0.85rem;
  color: var(--accent);
}

/* PROJECT CATEGORIES */
.project-category {
  background: linear-gradient(140deg, rgba(56, 189, 248, 0.12), rgba(129, 140, 248, 0.1));
  padding: 2rem;
  border-radius: 16px;
  text-decoration: none;
  color: var(--text);
  border: 1px solid rgba(148, 163, 184, 0.18);
  transition: transform 0.25s, box-shadow 0.25s, border-color 0.25s;
}

.project-category:hover {
  transform: translateY(-6px);
  border-color: rgba(56, 189, 248, 0.45);
  box-shadow: var(--glow);
}

.project-category h4 {
  font-size: 1.3rem;
  margin-bottom: 0.5rem;
}

.project-category p {
  color: #94a3b8;
}

/* ACCORDION */
.accordion {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.accordion details {
  background: var(--card);
  border-radius: 14px;
  border: 1px solid rgba(148, 163, 184, 0.12);
  overflow: hidden;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.accordion summary {
  cursor: pointer;
  padding: 1rem 1.25rem;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  font-weight: 600;
}

.accordion summary::-webkit-details-marker {
  display: none;
}

.accordion .accordion-icon {
  font-size: 0.9rem;
  color: #94a3b8;
  transition: transform 0.2s ease;
}

.accordion details[open] .accordion-icon {
  transform: rotate(-180deg);
}

.project-list {
  padding: 0 1.25rem 1.25rem;
}

.project-list .projects-grid {
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
}

.text-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}

