*,
*::before,
*::after {
  box-sizing: border-box;
}

* {
  margin: 0;
  padding: 0;
}

html,
body {
  height: 100%;
}

body {
  font-family:
    "Inter",
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  background: radial-gradient(
    circle at top,
    #122744 0,
    #020817 55%,
    #020617 100%
  );
  color: #e5e7eb;
  -webkit-font-smoothing: antialiased;
  padding-top: 72px;
}

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

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

ul {
  list-style: none;
}

.container {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.section {
  position: relative;
  padding: 5rem 0;
}

.section-header {
  width: 100%;
  margin-bottom: 2.5rem;
}

.section-header h2 {
  font-size: 2rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
}

.section-header p {
  color: #9ca3af;
  line-height: 1.6;
}

/* Header */

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 60;
  backdrop-filter: blur(16px);
  background: linear-gradient(
    to bottom,
    rgba(2, 6, 23, 0.95),
    rgba(2, 6, 23, 0.8)
  );
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
  box-shadow: 0 10px 30px rgba(2, 6, 23, 0.45);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1.5rem;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.04em;
}

.logo img {
  width: 32px;
  height: 32px;
}

.logo-text {
  font-size: 0.95rem;
  text-transform: uppercase;
  color: #e5e7eb;
}

.logo-text.logo-handwritten {
  font-family: "Caveat", cursive;
  font-size: 1.35rem;
  font-weight: 600;
  text-transform: none;
  letter-spacing: 0.02em;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.nav-list {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  font-size: 0.9rem;
}

.nav-list a {
  position: relative;
  color: #cbd5f5;
  padding: 0.25rem 0;
}

.nav-list a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(to right, #38bdf8, #4ade80);
  border-radius: 999px;
  transition: width 0.2s ease;
}

.nav-list a:hover::after,
.nav-list a:focus-visible::after {
  width: 100%;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 0.2rem;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.4);
  padding: 0.45rem 0.5rem;
  background: rgba(15, 23, 42, 0.85);
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  height: 2px;
  width: 100%;
  background: #e5e7eb;
  border-radius: 999px;
}

/* Hero */

#hero-network {
  position: fixed;
  inset: 0;
  z-index: -1;
  background: radial-gradient(
    circle at top,
    #020617 0,
    #020617 55%,
    #020617 100%
  );
}

.hero {
  padding-top: 5.5rem;
}

.hero-inner {
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(0, 2fr);
  gap: 3rem;
  align-items: center;
}

.hero-content {
  position: relative;
  z-index: 1;
}

.eyebrow {
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: #9ca3af;
  margin-bottom: 0.75rem;
}

.hero-title {
  font-size: clamp(2.4rem, 4vw, 3.2rem);
  font-weight: 700;
  letter-spacing: 0.02em;
  margin-bottom: 0.75rem;
}

.hero-subtitle {
  color: #9ca3af;
  line-height: 1.7;
  max-width: 36rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.75rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.7rem 1.4rem;
  border-radius: 999px;
  border: 1px solid transparent;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition:
    transform 0.15s ease,
    box-shadow 0.15s ease,
    background 0.15s ease,
    border-color 0.15s ease,
    color 0.15s ease;
}

.btn.primary {
  background: linear-gradient(135deg, #2563eb, #22c55e);
  color: white;
  box-shadow: 0 18px 40px rgba(37, 99, 235, 0.4);
}

.btn.primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 20px 45px rgba(37, 99, 235, 0.5);
}

.btn.ghost {
  border-color: rgba(148, 163, 184, 0.5);
  background: rgba(15, 23, 42, 0.7);
  color: #e5e7eb;
}

.btn.ghost:hover {
  border-color: #38bdf8;
  background: rgba(15, 23, 42, 0.9);
}

.hero-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 1.5rem;
  font-size: 0.9rem;
  color: #9ca3af;
}

.hero-links a {
  color: #e5e7eb;
}

.hero-links a:hover {
  color: #38bdf8;
}

.hero-photo-wrapper {
  position: relative;
  justify-self: center;
}

.hero-photo {
  width: 220px;
  height: 220px;
  border-radius: 999px;
  background: radial-gradient(
    circle at 30% 10%,
    #38bdf8,
    #0c2751 55%,
    #020617 100%
  );
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid rgba(148, 163, 184, 0.4);
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.9);
  overflow: hidden;
}

.hero-initials {
  font-size: 3rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #e5e7eb;
}

.hero-badge {
  position: absolute;
  bottom: 10px;
  left: 50%;
  transform: translateX(-50%);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 0.75rem;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.9);
  border: 1px solid rgba(148, 163, 184, 0.5);
  font-size: 0.8rem;
  color: #d1d5db;
  box-shadow: 0 16px 40px rgba(15, 23, 42, 0.95);
}

.badge-dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #22c55e;
  box-shadow: 0 0 0 6px rgba(34, 197, 94, 0.2);
}

/* Carousel */

.carousel {
  position: relative;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.carousel-window {
  overflow: hidden;
  flex: 1;
}

.carousel-track {
  display: flex;
  gap: 1.5rem;
  transition: transform 0.6s cubic-bezier(0.22, 0.61, 0.36, 1);
}

.carousel-track .project-card {
  flex: 0 0 calc((100% - 1.5rem) / 2);
}

.carousel-control {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.5);
  background: radial-gradient(
    circle at 30% 20%,
    rgba(56, 189, 248, 0.32),
    rgba(15, 23, 42, 0.96)
  );
  color: #e5e7eb;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1.5rem;
  transition:
    background 0.15s ease,
    transform 0.15s ease,
    box-shadow 0.15s ease;
  flex-shrink: 0;
}

.carousel-control:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.9);
}

.carousel-dots {
  display: flex;
  justify-content: center;
  margin-top: 1.75rem;
  gap: 0.45rem;
}

.carousel-dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.4);
  transition:
    width 0.2s ease,
    background 0.2s ease;
}

.carousel-dot.active {
  width: 18px;
  background: linear-gradient(to right, #38bdf8, #4ade80);
}

.project-card {
  position: relative;
  border-radius: 1rem;
  overflow: hidden;
  background: radial-gradient(
    circle at top left,
    rgba(56, 189, 248, 0.18),
    rgba(15, 23, 42, 0.98)
  );
  border: 1px solid rgba(148, 163, 184, 0.35);
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.9);
  display: flex;
  flex-direction: column;
  min-height: 560px;
}

.project-image {
  height: 240px;
  background: rgba(2, 6, 23, 0.55);
  padding: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.project-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.project-body {
  padding: 1.2rem 1.3rem 1.3rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.project-body h3 {
  font-size: 1.05rem;
  font-weight: 600;
}

.project-body h3 a {
  color: inherit;
  transition: color 0.15s ease;
}

.project-body h3 a:hover {
  color: #38bdf8;
}

.project-company {
  font-size: 0.8rem;
  color: #9ca3af;
  margin-top: 0.15rem;
  margin-bottom: 0.35rem;
}

.project-body p {
  font-size: 0.9rem;
  color: #d1d5db;
  line-height: 1.6;
}

.project-actions {
  margin-top: auto;
  padding-top: 0.25rem;
}

.btn.btn-sm {
  padding: 0.55rem 1.05rem;
  font-size: 0.85rem;
}

.back-to-top {
  position: fixed;
  right: 1.5rem;
  bottom: 1.5rem;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.5);
  background: radial-gradient(
    circle at 30% 20%,
    rgba(56, 189, 248, 0.32),
    rgba(15, 23, 42, 0.96)
  );
  color: #e5e7eb;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.9);
  opacity: 0;
  pointer-events: none;
  transition:
    opacity 0.2s ease,
    transform 0.15s ease,
    box-shadow 0.15s ease;
}

.back-to-top.visible {
  opacity: 1;
  pointer-events: auto;
}

.back-to-top:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 32px rgba(15, 23, 42, 0.95);
}

.project-meta {
  margin-top: 0.4rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.project-meta span {
  font-size: 0.75rem;
  padding: 0.25rem 0.55rem;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.9);
  border: 1px solid rgba(148, 163, 184, 0.5);
}

/* Timeline */

.timeline {
  position: relative;
  margin-top: 0.5rem;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 10px;
  top: 0;
  bottom: 0;
  width: 1px;
  background: linear-gradient(
    to bottom,
    rgba(148, 163, 184, 0.5),
    rgba(148, 163, 184, 0.1)
  );
}

.timeline-item {
  position: relative;
  padding-left: 2.5rem;
  padding-bottom: 2rem;
}

.timeline-item:last-child {
  padding-bottom: 0;
}

.timeline-marker {
  position: absolute;
  left: 4px;
  top: 0.2rem;
  width: 12px;
  height: 12px;
  border-radius: 999px;
  border: 2px solid #38bdf8;
  background: #020617;
  box-shadow: 0 0 0 6px rgba(56, 189, 248, 0.12);
}

.timeline-content {
  background: rgba(15, 23, 42, 0.9);
  border-radius: 0.9rem;
  padding: 1.15rem 1.2rem 1.2rem;
  border: 1px solid rgba(148, 163, 184, 0.4);
}

.timeline-content h3 {
  font-size: 1rem;
  font-weight: 600;
}

.timeline-meta {
  font-size: 0.85rem;
  color: #9ca3af;
  margin-top: 0.6rem;
  margin-bottom: 0.6rem;
}

.timeline-content ul {
  padding-left: 1.1rem;
}

.timeline-content li {
  font-size: 0.9rem;
  color: #d1d5db;
  line-height: 1.6;
  list-style: disc;
}

.timeline-content li + li {
  margin-top: 0.35rem;
}

/* Skills */

.skills-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1.5rem;
}

.skills-group {
  background: rgba(15, 23, 42, 0.9);
  border-radius: 0.9rem;
  padding: 1.3rem 1.3rem 1.4rem;
  border: 1px solid rgba(148, 163, 184, 0.4);
}

.skills-group h3 {
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.skills-group ul {
  padding-left: 1.1rem;
}

.skills-group li {
  list-style: disc;
  font-size: 0.9rem;
  color: #d1d5db;
  line-height: 1.6;
}

.skills-group li + li {
  margin-top: 0.2rem;
}

/* Contact */

.contact-inner {
  grid-template-columns: minmax(0, 3fr) minmax(0, 2fr);
  gap: 3rem;
  align-items: center;
}

.contact-links {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.contact-links.contact-links-icons {
  flex-direction: row;
  gap: 1rem;
}

.contact-link {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.8rem 1rem;
  border-radius: 0.75rem;
  border: 1px solid rgba(148, 163, 184, 0.4);
  background: rgba(15, 23, 42, 0.9);
  font-size: 0.9rem;
  color: #d1d5db;
  transition:
    border-color 0.15s ease,
    transform 0.15s ease,
    box-shadow 0.15s ease;
}

.contact-link.contact-link-icon {
  justify-content: center;
  padding: 0.85rem;
  border-radius: 50%;
  color: #e5e7eb;
}

.contact-link.contact-link-icon:hover {
  color: #38bdf8;
}

.contact-link:hover {
  border-color: #38bdf8;
  transform: translateY(-1px);
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.9);
}

.contact-note {
  background: radial-gradient(
    circle at top left,
    rgba(56, 189, 248, 0.2),
    rgba(15, 23, 42, 0.95)
  );
  border-radius: 1rem;
  padding: 1.5rem 1.6rem;
  border: 1px solid rgba(148, 163, 184, 0.5);
  font-size: 0.9rem;
  color: #d1d5db;
  line-height: 1.7;
}

/* Footer */

.site-footer {
  border-top: 1px solid rgba(148, 163, 184, 0.2);
  padding: 1.5rem 0 2rem;
  margin-top: 2rem;
  background: radial-gradient(
    circle at top,
    rgba(15, 23, 42, 0.85),
    rgba(2, 6, 23, 0.98)
  );
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  font-size: 0.8rem;
  color: #9ca3af;
}

.footer-meta {
  text-align: right;
}

/* Reveal Animations */

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 0.5s ease,
    transform 0.5s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Responsive */

@media (max-width: 960px) {
  .hero-inner {
    grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
    gap: 2.25rem;
  }

  .skills-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .contact-inner {
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  }
}

@media (max-width: 768px) {
  .header-inner {
    padding-inline: 1.25rem;
  }

  .nav-toggle {
    display: inline-flex;
  }

  .nav-list {
    position: absolute;
    inset: 3.4rem 1.25rem auto;
    border-radius: 0.9rem;
    background: rgba(15, 23, 42, 0.98);
    border: 1px solid rgba(148, 163, 184, 0.4);
    padding: 0.6rem 0.9rem;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.3rem;
    font-size: 0.95rem;
    transform-origin: top right;
    transform: scaleY(0.8);
    opacity: 0;
    pointer-events: none;
    translate: 0 -8px;
    transition:
      opacity 0.15s ease,
      translate 0.15s ease,
      transform 0.15s ease;
  }

  .nav-list.open {
    opacity: 1;
    pointer-events: auto;
    translate: 0 0;
    transform: scaleY(1);
  }

  .hero-inner {
    grid-template-columns: minmax(0, 1fr);
  }

  .hero-photo-wrapper {
    order: -1;
  }

  .hero {
    padding-top: 4.25rem;
  }

  .carousel {
    flex-direction: column;
  }

  .carousel-track {
    gap: 1rem;
  }

  .carousel-track .project-card {
    flex-basis: 100%;
  }

  .contact-inner {
    grid-template-columns: minmax(0, 1fr);
  }

  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 640px) {
  .section {
    padding: 3.5rem 0;
  }

  .skills-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .hero-photo {
    width: 180px;
    height: 180px;
  }
}
