:root {
  /* Branding Colors */
  --primary-color: #6366f1;
  --secondary-color: #a855f7;
  --bg-dark: #0f172a;
  --bg-card: #020e38;
  --text-main: #f8fafc;

  /* Standard Spacing */
  --border-radius: 12px;
}

body {
  background-color: var(--bg-dark);
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

/* ================= NAV ================= */
.main-nav {
  background: #0f172a;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 10%;
  border-bottom: 1px solid rgba(237, 227, 227, 0.5);
  height: 100px;
  position: sticky;
  top: 0;
  z-index: 10;
}

.logo img {
  display: block;
}

.nav-links {
  display: flex;
}

.nav-links a {
  color: var(--text-main);
  text-decoration: none;
  margin-right: 50px;
  transition: color 0.3s ease;
}

.nav-links a:last-child {
  margin-right: 0;
}

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

/* ================= BUTTONS ================= */
.btn-primary {
  color: var(--text-main);
  background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
  padding: 8px 18px;
  cursor: pointer;
  border: none;
  border-radius: 5px;
  transition: transform 0.3s ease-in;
  text-decoration: none;
  display: inline-block;
}

.btn-secondary {
  color: var(--text-main);
  background: transparent;
  padding: 8px 18px;
  cursor: pointer;
  border-radius: 5px;
  border: 1px solid #f8fafc;
  text-decoration: none;
  display: inline-block;
  transition: border-color 0.3s ease;
}

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

.btn-secondary:hover {
  border-color: var(--primary-color);
}

/* ================= HERO SECTION ================= */
.hero {
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  padding: 0 10%;
}

.hero-content {
  flex: 1;
  z-index: 2;
}

.hero-title {
  color: var(--text-main);
  font-size: 50px;
}

.hero-title span,
.projects span,
.skills h1 span,
.contact-heading h1 span {
  background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtext {
  color: var(--text-main);
  margin-bottom: 20px;
}

.hero-visual {
  flex: 1;
  display: flex;
  justify-content: center;
}

.hero-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, var(--primary-color), transparent 70%);
}

.hero-shape {
  width: 400px;
  height: 400px;
  background-color: var(--bg-card);
  border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
  border: 2px solid var(--primary-color);
  animation: rotate-shape 8s ease-in-out infinite alternate;
  margin-left: 40px;
  margin-top: 80px;
  object-fit: cover;
}

.hero-shape img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-shape-circle {
  width: 350px;
  height: 350px;
  border-radius: 50%;
  overflow: hidden;
  border: 3px solid var(--primary-color);
  margin-left: 40px;
  background-color: var(--bg-card);
}

.hero-shape-circle img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

@keyframes rotate-shape {
  to {
    border-radius: 50% 50% 10% 90% / 25% 80% 25% 80%;
  }
}

/* ================= PROJECTS SECTION ================= */
.projects {
  padding: 100px 10%;
  color: var(--text-main);
}

.projects h1 {
  font-size: 40px;
  margin-bottom: 20px;
}

.projects p {
  color: #cbd5e1;
  font-size: 17px;
  line-height: 1.6;
  max-width: 900px;
  margin-bottom: 15px;
}

.project-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 30px;
}

.project-card {
  flex: 1;
  min-width: 300px;
  position: relative;
  cursor: pointer;
  background-color: var(--bg-card);
  overflow: hidden;
  height: 400px;
}

.project-image-placeholder {
  width: 100%;
  height: 100%;
  transition: transform 0.3s ease-in-out;
}

.project-image-placeholder img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.project-card:hover .project-image-placeholder {
  transform: scale(1.1);
}

.project-details {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  background-color: #14203a;
  padding: 10px;
  transform: translateY(100%);
  transition: transform 0.3s ease-in-out;
  text-align: center;
}

.project-card:hover .project-details {
  transform: translateY(0);
}

.project-details h2,
.project-details h3 {
  color: var(--text-main);
  font-size: 25px;
  margin-bottom: 15px;
}

.project-card p {
  color: rgb(169, 167, 167);
  margin-top: 20px;
  margin-bottom: 15px;
}

/* ================= SKILLS SECTION ================= */
.skills {
  padding: 50px 10%;
  color: var(--text-main);
}

.skills h1 {
  font-size: 50px;
  margin-bottom: 20px;
  color: var(--text-main);
}

.skill-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 25px;
}

.skill-card {
  background-color: #2b4278;
  border: 1px solid rgba(148, 163, 184, 0.15);
  border-radius: var(--border-radius);
  padding: 30px;
  min-height: 180px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.skill-card:hover {
  transform: translateY(-5px);
  border-color: var(--primary-color);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.35);
}

.skill-card h2 {
  color: var(--text-main);
  font-size: 24px;
  margin-bottom: 15px;
}

.skill-card p {
  color: #cbd5e1;
  line-height: 1.5;
}

.badge {
  display: inline-block;
  background-color: #1e293b;
  color: #e2e8f0;
  padding: 10px 20px;
  margin-right: 8px;
  margin-bottom: 12px;
  border-radius: 30px;
  font-size: 16px;
  border: 1px solid rgba(148, 163, 184, 0.15);
  transition: 0.25s ease;
}

.badge:hover {
  background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
  transform: translateY(-2px);
}

/* ================= CONTACT SECTION ================= */
.contact {
  padding: 70px 10%;
  color: var(--text-main);
}

.contact-heading {
  text-align: center;
  margin-bottom: 60px;
}

.contact-heading h1 {
  font-size: 50px;
  margin-bottom: 20px;
  color: var(--text-main);
}

.contact-heading p {
  font-size: 18px;
  color: #cbd5e1;
}

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

.contact-form {
  background-color: var(--bg-card);
  padding: 45px;
  border-radius: var(--border-radius);
  border: 1px solid rgba(148, 163, 184, 0.15);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
}

.contact-form form {
  display: flex;
  flex-direction: column;
}

.contact-form label {
  color: var(--text-main);
  font-size: 18px;
  font-weight: bold;
  margin-bottom: 10px;
}

.contact-form input {
  width: 100%;
  box-sizing: border-box;
  background-color: #0f172a;
  color: var(--text-main);
  border: 1px solid #475569;
  border-radius: 8px;
  padding: 15px 18px;
  font-size: 15px;
  margin-bottom: 30px;
  outline: none;
}

.contact-form input:focus {
  border-color: var(--primary-color);
}

.contact-form input::placeholder {
  color: #94a3b8;
}

.contact-form button {
  width: 100%;
  padding: 16px;
  border: none;
  border-radius: 8px;
  background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
  color: white;
  font-size: 17px;
  font-weight: bold;
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.contact-form button:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(99, 102, 241, 0.3);
}

.contact-info {
  display: flex;
  flex-direction: column;
  gap: 25px;
}

.contact-card {
  background-color: var(--bg-card);
  padding: 35px;
  border-radius: var(--border-radius);
  border-left: 5px solid var(--primary-color);
  box-sizing: border-box;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease, border-color 0.3s ease;
}

.contact-card:hover {
  transform: translateX(5px);
  border-left-color: var(--secondary-color);
}

.contact-card h2 {
  color: var(--text-main);
  font-size: 25px;
  margin-bottom: 25px;
}

.contact-card a {
  color: #a5b4fc;
  font-size: 17px;
  text-decoration: none;
}

.contact-card a:hover {
  color: var(--secondary-color);
  text-decoration: underline;
}

.contact-card p {
  color: #cbd5e1;
  font-size: 17px;
  margin: 0;
}

.social-links {
  display: flex;
  gap: 12px;
}

.social-links a {
  background-color: #1e293b;
  color: var(--text-main);
  padding: 10px 20px;
  border-radius: 6px;
  text-decoration: none;
  font-weight: bold;
  font-size: 16px;
  transition: background 0.3s ease, transform 0.3s ease;
}

.social-links a:hover {
  background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
  transform: translateY(-2px);
  color: var(--text-main);
}

/* ================= FOOTER ================= */
footer {
  text-align: center;
  color: var(--text-main);
  border-top: 1px solid rgba(237, 227, 227, 0.5);
  padding: 30px 10%;
}

/* ================= RESPONSIVE / MOBILE ================= */
@media (max-width: 800px) {
  /* Navigation: Compact, centered pills */
  .main-nav {
    height: auto;
    flex-direction: column;
    align-items: center;
    padding: 12px 16px;
    gap: 12px;
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(8px);
  }

  .logo {
    width: auto;
  }

  .logo img {
    width: 65px;
    height: auto;
  }

  .nav-links {
    width: 100%;
    margin-right: 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px 10px;
  }

  .nav-links a {
    margin-right: 0;
    font-size: 13px;
    padding: 6px 12px;
    border-radius: 20px;
    background-color: rgba(255, 255, 255, 0.05);
    transition: background-color 0.2s ease, color 0.2s ease;
  }

  .nav-links a:hover,
  .nav-links a:active {
    background-color: rgba(99, 102, 241, 0.25);
    color: var(--secondary-color);
  }

  /* Hero */
  .hero {
    flex-direction: column-reverse;
    align-items: center;
    padding: 30px 5%;
    height: auto;
  }

  .hero-content {
    text-align: center;
    justify-content: center;
  }

  .hero-shape {
    width: 260px;
    height: 260px;
    margin-left: 0;
    margin-top: 20px;
  }

  .hero-shape-circle {
    width: 200px;
    height: 200px;
    margin-left: 0;
    margin-top: 25px;
  }

  .hero-shape-circle img {
    width: 200px;
    height: 200px;
  }

  /* Projects */
  .projects {
    padding: 40px 5%;
    text-align: center;
  }

  .projects h1 {
    font-size: 34px;
    margin-bottom: 10px;
  }

  /* Skills */
  .skills {
    padding: 40px 5%;
    text-align: center;
  }

  .skills h1 {
    font-size: 34px;
  }

  .skill-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  /* Contacts */
  .contact {
    padding: 40px 5%;
  }

  .contact-heading h1 {
    font-size: 34px;
  }

  .contact-grid {
    display: flex;
    flex-direction: column;
    gap: 35px;
  }

  .contact-form {
    padding: 25px;
  }
}