/* Load Roboto from Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&display=swap');

:root {
  /* GENERAL */
  --font: "Inter", sans-serif;
  --bg: #121212;
  --bg_dark: #0e1131;
  --bg_light: #2c4078;
  --nav_dark: #0e1131e2;
  --nav_light: #2c4078e5;
  --nav_text: #789cff;
  --nav_highlight: #4964af;
  --text: #f0f0f0;
  --link: #0099ff;

  /* HOME PAGE */
  --button: #4964af;
  --button_hover: #0357ff;
  --card-bg: #0d0d1b;
  --card-bg-alt: #0d0d2d;
  --card-color: #007BFF;

  /* ABOUT PAGE */
  --tile-bg: #0d0d2d;
  --tile-bg-alt: #040404;

  /* PROJECTS PAGE */
  --project_tile_bg: #024a92;
}

html {
  scroll-padding-top: 70px;
}

body {
  background: linear-gradient(115deg, var(--bg_dark), var(--bg_light));
  color: var(--text);
  font-family: var(--font);
  font-optical-sizing: auto;
  margin: 0 0;
}
.background_image {
  width:100%;
  z-index:-1000;
}

header {
  align-items: center;
  padding: 1rem 0;
  margin: 1rem 0 1rem 5rem;
}

header h1 {
  font-size: 3.5rem;
}

nav {
  position: sticky;
  top: 0;
  padding: 0.75rem 1rem;
  margin: 0 20%;
  border-bottom: 1px solid var(--text);
  z-index:1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

nav.scrolled {
  background: linear-gradient(115deg, var(--nav_dark), var(--nav_light));
  backdrop-filter: blur(10px);
  margin: 0 0;
}

nav a {
  margin-right: 0.25rem;
  padding: 0.25rem 1rem;
  text-decoration: none;
  color: var(--nav_text);
  border-top-left-radius: 10px;
  border-top-right-radius: 10px;
  transition: background 0.3s ease, color 0.3s ease;
}


nav a.selected {
  border-bottom: 2px solid var(--text);
  color: var(--text);
}

nav a:hover {
  background-color: var(--nav_highlight);
  opacity: 0.95;
  color: var(--text);
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  position: sticky;
  top: 0.5rem;
  left: 0.5rem;
  font-size: 1.5rem;
  color: var(--nav_text);
  cursor: pointer;
}


/* Mobile menu hidden by default */
@media (max-width: 788px) {
  .nav-toggle {
    display: block;
  }

  .nav-links {
    display: none;
    flex-direction: column;
    position: sticky;
    top: 2rem;
    left: 0;
    margin: 0 0;
    background: linear-gradient(115deg, var(--nav_dark), var(--nav_light));
    width: 200px;
    padding: 1rem;
    border-radius: 0 8px 8px 8px;
  }

  .nav-links.show {
    display: flex;
  }
}

main {
  margin: 0 10%;
}

footer {
  text-align: center;
  padding: 1rem 0;
}

h1, h2{
  margin: 1rem 0;
}

h3 {
  margin: 1rem 0;
  margin-top: 2rem;
}

h4 {
  margin: 0;
}

a {
  color: var(--link);
}

ul {
  padding: 0 2rem;
}





/* HOME PAGE */
.hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  padding: 2rem;
  max-width: 1200px;
  margin: 4rem 3rem 6rem 3rem;
  border: 3px solid white;
  border-radius: 40px;
  position: relative;
  background: transparent;
}

.hero-content {
  flex: 1;
  padding: 1rem 11rem 1rem 1rem;
}

.hero h2 {
  font-size: 2rem;
  margin-bottom: 1rem;
}

.hero p {
  margin-bottom: 1.5rem;
  line-height: 1.7;
}

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

.hero-button {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  border: 2px solid var(--button);
  border-radius: 999px;
  text-decoration: none;
  font-weight: bold;
  transition: background 0.3s ease, color 0.3s ease;
}

.hero-button:hover {
  background: var(--button_hover);
  color: white;
}

.hero-image {
  width: 250px;
  height: auto;
  border-radius: 50%;
  position: absolute;
  right: -75px;
  top: 50%;
  transform: translateY(-50%);
  border: 4px solid white;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

@media (max-width: 730px) {
  .hero {
    display: block;
    padding: 2rem;
    margin: 2rem 0;
    text-align: center;
  }

  .hero h2 {
  margin-right: 1rem;
  margin-left: 1rem;
  }

  .hero-content {
    padding: 0; /* Full width text */
  }

  .hero-image {
    position: absolute;
    top: -2rem;
    right: -2rem;
    transform: none;
    width: 100px;
    height: auto;
    border-radius: 50%;
    border: 3px solid white;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
  }

  .hero-buttons {
    justify-content: center;
    flex-wrap: wrap;
  }
}

/* Card grid container */
.highlights {
  max-width: 900px;
  margin: 2rem auto;
}

.highlight-card {
  display: flex;
  align-items: center;
  text-decoration: none;
  background: linear-gradient(180deg, var(--card-bg), var(--card-bg-alt));
  border-radius: 20px;
  padding: 2rem 1rem;
  margin: 2rem 0;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  transition: transform 0.2s ease;
}

.highlight-card:hover {
  transform: translateY(-4px);
}

.card-icon {
  flex-shrink: 0;
  width: 80px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--card-color);
  border-radius: 50%;
  margin-right: 1rem;
}

.card-icon img {
  width: 60%;
  height: auto;
}

.card-content h4 {
  margin: 0;
  font-size: 1.2rem;
}

.card-content p {
  margin: 0.5rem 0 0;
  color: #555;
}

.contact-button {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  background: var(--card-bg-alt);
  border-radius: 999px;
  text-decoration: none;
  font-weight: bold;
  transition: background 0.3s ease, color 0.3s ease;
}

.contact-button:hover {
  background: var(--card-bg);
  color: white;
}




/* ABOUT PAGE */

.about h2 {
  font-size: 2.5rem;
}

.education-tiles {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); /* Responsive grid */
    gap: 30px; /* Space between tiles */
    width: 100%;
    max-width: 100vw; /* Prevents horizontal scrolling */
    padding: 20px;
    box-sizing: border-box; /* Ensures padding doesn't add extra width */
    align-items: stretch;
}

.education-tile {
  width: 90%; /* Adjust based on preference */
  aspect-ratio: 1/1; /* Ensures square shape */
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 15px;
  text-align: center;
  background: linear-gradient(180deg, var(--tile-bg), var(--tile-bg-alt));
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between; /* Keeps content evenly spaced */
}

.education-tile p {
  color: white;
}

.certificate-icons {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); /* Responsive grid */
    gap: 30px; /* Space between tiles */
    width: 100%;
    max-width: 100vw; /* Prevents horizontal scrolling */
    padding: 20px;
    box-sizing: border-box; /* Ensures padding doesn't add extra width */
    align-items: stretch;
}

.certificate-icons a {
  text-decoration: none;
}
.certificate-icons img {
  width: 100%;
}




/* PROJECTS PAGE*/
.featured-projects {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); /* Responsive grid */
    gap: 20px; /* Space between tiles */
    width: 100%;
    max-width: 100vw; /* Prevents horizontal scrolling */
    padding: 20px;
    box-sizing: border-box; /* Ensures padding doesn't add extra width */
}

.featured-projects a {
  text-decoration: none;
}

.project-tile {
  width: 90%; /* Adjust based on preference */
  aspect-ratio: 1/1; /* Ensures square shape */
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 15px;
  box-shadow: 2px 2px 10px rgba(0, 0, 0, 0.1);
  text-align: center;
  background: var(--project_tile_bg);
  position: relative;
  transition: transform 0.3s ease-in-out, box-shadow 0.3s ease-in-out;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between; /* Keeps content evenly spaced */
}

.project-name {
  color: white;
  margin-bottom: 8px;
}
.project-tile p {
  color: white;
}

/* Ensure all images have a fixed size and maintain aspect ratio */
.project-tile img {
  width: 100%; /* Fixed image size */
  height: 80%; /* Fixed image size */
  object-fit: cover; /* Ensures images fill without distortion */
  border-radius: 2px;
}

/* Adjust hover effect */
.project-tile:hover {
  transform: scale(1.05);
  box-shadow: 4px 4px 15px rgba(0, 0, 0, 0.2);
  z-index: 10;
}