* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --bg: #f8fafc;
  --surface: #ffffff;
  --dark: #0f1724;
  --text: #0f1724;
  --muted: #64748b;
  --primary: #0f4c81;
  --secondary: #0ea5a4;
  --border: #e6eef6;
  --shadow: 0 18px 40px rgba(16, 24, 40, 0.06);
  --radius: 16px;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Inter", sans-serif;
  background:
    radial-gradient(circle at top left, rgba(14, 165, 164, 0.06), transparent 34%),
    radial-gradient(circle at top right, rgba(15, 76, 129, 0.04), transparent 28%),
    var(--bg);
  color: var(--text);
  line-height: 1.7;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--surface);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 4px 14px rgba(16,24,40,0.04);
}

.navbar {
  width: min(1120px, 92%);
  margin: auto;
  height: 78px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--dark);
}

.logo span {
  color: var(--primary);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
  list-style: none;
}

.nav-links a {
  font-weight: 600;
  color: var(--text);
  transition: 0.3s ease;
}

.nav-links a:hover {
  color: var(--primary);
}

.nav-btn {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: white !important;
  padding: 11px 18px;
  border-radius: 999px;
  font-weight: 700;
}

.menu-btn {
  display: none;
  border: 0;
  background: transparent;
  font-size: 1.4rem;
  color: var(--dark);
  cursor: pointer;
}

.hero {
  width: min(1120px, 92%);
  margin: auto;
  min-height: calc(100vh - 78px);
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  align-items: center;
  gap: 48px;
  padding: 70px 0;
}

.eyebrow {
  display: inline-flex;
  margin-bottom: 18px;
  padding: 8px 16px;
  background: rgba(15, 76, 129, 0.06);
  color: var(--primary);
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.9rem;
}

.hero h1 {
  font-size: clamp(2.5rem, 6vw, 5rem);
  line-height: 1.05;
  letter-spacing: -2.5px;
  color: var(--dark);
  margin-bottom: 22px;
}

.hero-text {
  max-width: 620px;
  font-size: 1.08rem;
  color: var(--muted);
}

.hero-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin: 32px 0 24px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 22px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-weight: 700;
  cursor: pointer;
  transition: 0.3s ease;
}

.primary-btn {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: white;
  box-shadow: 0 14px 30px rgba(15, 76, 129, 0.18);
}

.secondary-btn {
  border-color: var(--border);
  background: var(--surface);
  color: var(--dark);
}

.btn:hover {
  transform: translateY(-3px);
}

.social-row,
.contact-socials {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.social-row a,
.contact-socials a {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--dark);
  transition: 0.3s ease;
}

.social-row a:hover,
.contact-socials a:hover {
  background: var(--primary);
  color: white;
  transform: translateY(-4px);
}

.whatsapp-float {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 1001;
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #25d366;
  color: white;
  font-size: 2rem;
  box-shadow: 0 14px 30px rgba(37, 211, 102, 0.35);
  transition: 0.3s ease;
}

.whatsapp-float:hover {
  transform: translateY(-4px);
  background: #1ebe5d;
}

.hero-card {
  position: relative;
}

.hero-card::before {
  content: "";
  position: absolute;
  inset: -18px;
  background: linear-gradient(135deg, rgba(15, 76, 129, 0.10), rgba(14, 165, 164, 0.06));
  border-radius: 36px;
  transform: rotate(-4deg);
}

.code-window {
  position: relative;
  background: #0b1220;
  color: #dbeafe;
  border-radius: 30px;
  padding: 26px;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.window-dots {
  display: flex;
  gap: 8px;
  margin-bottom: 28px;
}

.window-dots span {
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: #f87171;
}

.window-dots span:nth-child(2) {
  background: #fbbf24;
}

.window-dots span:nth-child(3) {
  background: #34d399;
}

pre {
  white-space: pre-wrap;
  font-size: 1rem;
  line-height: 1.9;
}

.section {
  width: min(1120px, 92%);
  margin: auto;
  padding: 90px 0;
}

.section-title {
  text-align: center;
  margin-bottom: 44px;
}

.section-title p {
  color: var(--primary);
  font-weight: 900;
  margin-bottom: 10px;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-size: 1rem;
}

.section-title h2 {
  font-size: clamp(3rem, 5.2vw, 5rem);
  color: var(--dark);
  letter-spacing: -1.5px;
  font-weight: 900;
}

.about-grid,
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
  align-items: stretch;
}

.about-card,
.contact-info,
.contact-form,
.timeline,
.skill-card,
.project-card,
.stat-box {
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  border-radius: var(--radius);
}

.about-card {
  padding: 34px;
}

.about-card h3,
.contact-info h3 {
  color: var(--dark);
  font-size: 1.55rem;
  margin-bottom: 14px;
}

.about-card p + p {
  margin-top: 14px;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
}

.stat-box {
  padding: 26px;
}

.stat-box h3 {
  color: var(--secondary);
  font-size: 2rem;
  margin-bottom: 4px;
  font-weight: 800;
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.projects-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

.skill-card,
.project-card {
  padding: 28px;
  transition: 0.3s ease;
}

.skill-card:hover,
.project-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow);
  border-color: var(--primary);
  background: rgba(15, 76, 129, 0.06);
}

.skill-card i {
  font-size: 2.4rem;
  color: var(--primary);
  margin-bottom: 18px;
}

.skill-card h3,
.project-card h3,
.timeline-item h3 {
  color: var(--dark);
  margin-bottom: 8px;
}

.timeline {
  max-width: 780px;
  margin: auto;
  padding: 34px;
}

.timeline-item {
  position: relative;
  padding-left: 38px;
}

.timeline-item + .timeline-item {
  margin-top: 34px;
}

.timeline-item::before {
  content: "";
  position: absolute;
  left: 9px;
  top: 24px;
  width: 2px;
  height: calc(100% + 20px);
  background: var(--border);
}

.timeline-item:last-child::before {
  display: none;
}

.timeline-dot {
  position: absolute;
  left: 0;
  top: 7px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  box-shadow: 0 0 0 6px rgba(15, 76, 129, 0.08);
}

.timeline-item small {
  display: inline-block;
  margin-top: 6px;
  color: var(--primary);
  font-weight: 700;
}

.education-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
  max-width: 1100px;
  margin: auto;
}

.education-card {
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  transition: 0.3s ease;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.education-card:hover {
  border-color: var(--primary);
  background: rgba(15, 76, 129, 0.06);
  transform: translateY(-6px);
  box-shadow: var(--shadow);
}

.edu-icon {
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  border-radius: 14px;
  font-size: 1.6rem;
  color: white;
  margin-bottom: 8px;
}

.education-card h3 {
  color: var(--dark);
  font-size: 1.3rem;
  margin: 0;
  line-height: 1.3;
}

.education-card .institution {
  color: var(--muted);
  font-size: 0.95rem;
  margin: 0;
}

.education-card .year {
  color: var(--primary);
  font-weight: 700;
  margin: 8px 0 0 0;
  font-size: 1.1rem;
}

.edu-badge {
  display: inline-block;
  background: rgba(15, 76, 129, 0.06);
  color: var(--primary);
  padding: 6px 14px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.85rem;
  margin-top: 8px;
  width: fit-content;
}

.project-card {
  color: var(--text);
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 26px;
  align-items: center;
}

.project-card:nth-child(even) {
  grid-template-columns: 0.9fr 1.1fr;
}

.project-card:nth-child(even) .project-visual {
  order: 2;
}

.project-card:nth-child(even) .project-content {
  order: 1;
}

.project-visual {
  min-width: 0;
}

.project-content {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
}

.project-card:nth-child(even) .project-content {
  align-items: flex-start;
}

.project-image {
  overflow: hidden;
  border-radius: 24px;
  border: 1px solid var(--border);
}

.project-image img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.project-card:hover .project-image img {
  transform: scale(1.04);
}

.project-icon {
  width: 60px;
  height: 60px;
  display: grid;
  place-items: center;
  background: rgba(15, 76, 129, 0.06);
  border-radius: 18px;
  color: var(--primary);
  font-size: 1.45rem;
  margin-bottom: 20px;
}

.project-card span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--primary);
  font-weight: 800;
  margin-top: 20px;
}

.contact-info,
.contact-form {
  padding: 34px;
}

.contact-item {
  display: flex;
  gap: 14px;
  margin-top: 24px;
  align-items: flex-start;
}

.contact-item i {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: rgba(15, 76, 129, 0.06);
  color: var(--primary);
}

.contact-item h4 {
  color: var(--dark);
}

.contact-item a {
  color: var(--primary);
  font-weight: 700;
}

.contact-socials {
  margin-top: 28px;
}

.form-group {
  margin-bottom: 18px;
}

label {
  display: block;
  color: var(--dark);
  font-weight: 700;
  margin-bottom: 8px;
}

input,
textarea {
  width: 100%;
  border: 1px solid var(--border);
  background: #ffffff;
  color: var(--dark);
  padding: 14px 16px;
  border-radius: 12px;
  outline: none;
  font-family: inherit;
  font-size: 1rem;
  transition: 0.3s ease;
}

input::placeholder,
textarea::placeholder {
  color: var(--muted);
}

input:focus,
textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(15, 76, 129, 0.12);
}

textarea {
  resize: vertical;
}

/* Cursor Following Animation */
.cursor-follower {
  position: fixed;
  pointer-events: none;
  z-index: 999;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  border-radius: 50%;
  box-shadow: 0 8px 18px rgba(15, 76, 129, 0.18);
  animation: float 3s ease-in-out infinite;
}

@keyframes float {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.2);
  }
}

.full-btn {
  width: 100%;
  border: 0;
  font-family: inherit;
  font-size: 1rem;
}

.footer {
  width: min(1120px, 92%);
  margin: 40px auto 30px;
  padding: 34px;
  background: var(--surface);
  color: var(--dark);
  border-radius: 30px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 22px;
  align-items: center;
  border: 1px solid var(--border);
}


.footer h3 {
  margin-bottom: 4px;
}

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

.footer-links {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
}

.footer-links a {
  color: var(--primary);
  font-weight: 600;
}

.copyright {
  grid-column: 1 / -1;
  border-top: 1px solid var(--border);
  padding-top: 20px;
  font-size: 0.92rem;
}

@media (max-width: 900px) {
  .menu-btn {
    display: block;
  }

  .nav-links {
    position: absolute;
    top: 78px;
    left: 0;
    width: 100%;
    padding: 24px;
    background: var(--surface);
    flex-direction: column;
    align-items: flex-start;
    border-bottom: 1px solid var(--border);
    transform: translateY(-120%);
    opacity: 0;
    pointer-events: none;
    transition: 0.3s ease;
  }

  .nav-links.active {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .hero,
  .about-grid,
  .contact-grid {
    grid-template-columns: 1fr;
  }

  .hero {
    padding-top: 48px;
  }

  .hero-card {
    order: -1;
  }

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

  .projects-grid {
    display: grid;
    grid-template-columns: 1fr;
    overflow: visible;
  }

  .project-card {
    grid-template-columns: 1fr;
    scroll-snap-align: unset;
  }

  .project-card:nth-child(even) {
    grid-template-columns: 1fr;
  }

  .project-card:nth-child(even) .project-visual {
    order: 0;
  }

  .project-card:nth-child(even) .project-content {
    order: 0;
  }

  .education-grid {
    grid-template-columns: 1fr;
  }

  .footer {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 620px) {
  .skills-grid,
  .projects-grid,
  .stats-grid,
  .education-grid {
    grid-template-columns: 1fr;
  }

  .section {
    padding: 66px 0;
  }

  .hero h1 {
    letter-spacing: -1.5px;
  }

  .code-window {
    padding: 22px;
  }

  pre {
    font-size: 0.88rem;
  }

  .whatsapp-float {
    right: 18px;
    bottom: 18px;
    width: 52px;
    height: 52px;
    font-size: 1.8rem;
  }
}
