/* =========================
   1. Root Variables & Reset
   ========================= */
:root {
  --system-font-stack: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
  --space-xs: 0.5rem;
  --space-s: 1rem;
  --space-m: 2rem;
  --space-l: 3rem;
  --space-xl: 4rem;
  --space-2xl: 6rem;
  --space-3xl: 8rem;
  --color-accent: #8a2be2;
  --color-primary: #1a1a40;
  --color-secondary: #c7d6db;
  --color-light: #fafafa;
  --color-dark: #0c0c0c;
  --color-link: #007bff;
  --color-link-hover: #0056b3;
  --border-radius: 8px;
  --transition: 0.3s ease-in-out;
  --max-width: 1200px;
  --header-height: 64px;
  font-size: 16px;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body, h1, h2, h3, h4, h5, h6, p, figure, blockquote, dl, dd {
  margin: 0;
}

body {
  font-family: var(--system-font-stack);
  background: #f9f9f9;
  color: #222;
  line-height: 1.6;
  min-height: 100vh;
}

/* =========================
   2. Layout Helpers
   ========================= */
.wrapper {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1rem;
}

.wrapper_inner {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
}

.hero-background .wrapper_inner {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 300px;
}

.flex {
  display: flex;
}

.flex_center {
  justify-content: center;
  align-items: center;
}

.flex_around {
  justify-content: space-around;
  align-items: center;
}

.flex_between {
  justify-content: space-between;
  align-items: center;
}

.flex_wrap {
  flex-wrap: wrap;
}

/* =========================
   3. Header & Navigation
   ========================= */
.site_header {
  background: #fff;
  box-shadow: 0 2px 8px rgba(0,0,0,0.03);
  position: sticky;
  top: 0;
  z-index: 100;
}

.site_header_nav ul {
  list-style: none;
  gap: 1.5rem;
  padding: 1rem 0;
}

.site_header_nav a {
  text-decoration: none;
  color: #222;
  font-weight: 500;
  transition: color 0.2s;
  padding: 0.5rem 0.8rem;
  border-radius: 4px;
}

.site_header_nav a:hover,
.site_header_nav a:focus {
  background: #f0f0f0;
  color: #0078d4;
}

/* =========================
   4. Hero Section
   ========================= */
.hero-background {
  background: linear-gradient(120deg, #e0e7ff 0%, #fff 100%);
  padding: 4rem 0 3rem 0;
  text-align: center;
}

.hero_content h1 {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: #222;
}

.hero_content .h5 {
  font-size: 1.3rem;
  color: #0078d4;
  letter-spacing: 2px;
}

/* =========================
   5. About Section
   ========================= */
#about {
  background: #fff;
  padding: 3rem 0;
  border-bottom: 1px solid #ececec;
}

.about_figure {
  flex: 1 1 250px;
}

.about_img {
  border-radius: 50%;
  width: 220px;
  height: 220px;
  object-fit: cover;
  border: 4px solid #e0e7ff;
  box-shadow: 0 2px 12px rgba(0,0,0,0.07);
}

.about_details {
  flex: 2 1 350px;
  padding-left: 2rem;
}

.about_highlights {
  list-style: none;
  margin-top: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.about_highlights li {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  font-size: 1rem;
}

/* =========================
   6. Section Headings
   ========================= */
section header h2,
section header h2 img {
  vertical-align: middle;
}

section header h2 {
  font-size: 2rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: #222;
}

section header p {
  color: #555;
  margin-bottom: 1rem;
}

/* =========================
   7. Skills Section
   ========================= */
#skills {
  background: #f5f7fa;
  padding: 3rem 0;
}

.skills-list {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  justify-content: center;
  margin-top: 2rem;
  list-style: none;
}

.skills-list li {
  text-align: center;
  min-width: 90px;
}

.skills-list img {
  margin-bottom: 0.5rem;
}

/* =========================
   8. Education Section
   ========================= */
#education {
  background: #fff;
  padding: 3rem 0;
  border-bottom: 1px solid #ececec;
}

.education-details {
  margin-top: 1.5rem;
  font-size: 1.1rem;
}

.download-cv {
  display: inline-block;
  margin-top: 1rem;
  background: #0078d4;
  color: #fff;
  padding: 0.5rem 1.2rem;
  border-radius: 4px;
  text-decoration: none;
  font-weight: 500;
  transition: background 0.2s;
}

.download-cv:hover,
.download-cv:focus {
  background: #005fa3;
}

/* =========================
   9. Interests Section
   ========================= */
#interests {
  background: #f5f7fa;
  padding: 3rem 0;
}

.interests-article ul {
  list-style: disc inside;
  margin-top: 1.5rem;
  color: #444;
  font-size: 1.1rem;
  padding-left: 1.5rem;
}

/* =========================
   10. Projects Section
   ========================= */
#projects {
  background: #fff;
  padding: 3rem 0;
}

.projects-list {
  list-style: none;
  margin-top: 2rem;
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  justify-content: center;
}

.projects-list li {
  background: #f5f7fa;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.03);
  padding: 2rem 1.5rem 1.5rem 1.5rem;
  min-width: 260px;
  max-width: 340px;
  flex: 1 1 260px;
  display: flex;
  flex-direction: column;
  align-items: center;
  transition: box-shadow 0.2s;
}

.projects-list li:hover,
.projects-list li:focus-within {
  box-shadow: 0 4px 16px rgba(0,0,0,0.08);
}

.projects-list a {
  color: #0078d4;
  font-weight: 600;
  text-decoration: none;
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
  display: inline-block;
}

.projects-list a:hover,
.projects-list a:focus {
  text-decoration: underline;
}

.projects-list img {
  margin: 1rem 0;
  border-radius: 6px;
  background: #fff;
  box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}

.projects-list p {
  color: #333;
  font-size: 1rem;
  margin-bottom: 1rem;
  text-align: center;
}

.projects-list ul {
  list-style: disc inside;
  padding-left: 0;
  margin: 0;
  width: 100%;
}

.projects-list ul li {
  font-size: 0.98rem;
  color: #555;
  margin-bottom: 0.3rem;
  text-align: left;
}

.projects-list ul li a {
  font-size: 0.98rem;
  color: #0078d4;
  font-weight: 500;
  text-decoration: underline;
  margin-left: 0;
}

/* =========================
   11. Contact Section
   ========================= */
#contact {
  background: #f5f7fa;
  padding: 3rem 0;
}

.contact_form {
  max-width: 500px;
  margin: 0 auto;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
  padding: 2rem;
}

.form_group {
  margin-bottom: 1.2rem;
}

.form_group label {
  display: block;
  margin-bottom: 0.4rem;
  font-weight: 500;
  color: #222;
}

.form_group input,
.form_group textarea {
  width: 100%;
  padding: 0.7rem;
  border: 1px solid #d1d5db;
  border-radius: 4px;
  font-size: 1rem;
  background: #f9f9f9;
  transition: border 0.2s;
}

.form_group input:focus,
.form_group textarea:focus {
  border-color: #0078d4;
  outline: none;
}

button[type="submit"] {
  background: #0078d4;
  color: #fff;
  border: none;
  padding: 0.7rem 1.5rem;
  border-radius: 4px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
}

button[type="submit"]:hover,
button[type="submit"]:focus {
  background: #005fa3;
}

#contact .wrapper_inner {
  display: flex;
  justify-content: center;
  align-items: center;
}

/* =========================
   12. Footer
   ========================= */
footer {
  background: #222;
  color: #fff;
  padding: 2rem 0 1rem 0;
  text-align: center;
}

footer .social-links {
  margin-bottom: 1rem;
}

footer .social-links ul {
  gap: 1rem;
  justify-content: center;
  align-items: center;
}

footer .social-links a img {
  vertical-align: middle;
  transition: filter 0.2s;
}

footer .social-links a:hover img,
footer .social-links a:focus img {
  filter: brightness(1.3);
}

footer p {
  font-size: 0.95rem;
  margin-top: 1rem;
  color: #bbb;
}

/* =========================
   13. Responsive Styles
   ========================= */
@media (max-width: 900px) {
  .wrapper_inner.about_content {
    flex-direction: column;
    align-items: center;
    gap: 2rem;
  }
  .about_details {
    padding-left: 0;
  }
  .projects-list {
    flex-direction: column;
    align-items: center;
  }
  .projects-list li {
    max-width: 95vw;
    min-width: 80vw;
  }
}

@media (max-width: 700px) {
  .site_header_nav ul {
    flex-direction: column;
    gap: 0.5rem;
    padding: 0.5rem 0;
  }
  .hero_content h1 {
    font-size: 2rem;
  }
  .about_img {
    width: 160px;
    height: 160px;
  }
  .skills-list {
    gap: 1rem;
  }
  .projects-list li {
    min-width: 90vw;
    max-width: 98vw;
    padding: 1.2rem 0.7rem;
  }
  .contact_form {
    padding: 1rem;
  }
}

@media (max-width: 500px) {
  html {
    font-size: 15px;
  }
  .wrapper {
    padding: 0 0.3rem;
  }
  .about_img {
    width: 110px;
    height: 110px;
  }
  .hero_content h1 {
    font-size: 1.8rem;
  }
  .hero_content .h5 {
    font-size: 1.2rem;
  }
  .skills-list {
    flex-direction: column;
    align-items: center;
  }
  .projects-list li {
    padding: 1rem;
  }
  .contact_form {
    padding: 0.8rem;
  }
}