/* =============== Reset & Box Sizing =============== */
*,
*::before,
*::after {
  box-sizing: border-box;
}
body, h1, h2, h3, h4, ul, p, figure {
  margin: 0;
  padding: 0;
}
ul {
  list-style: none;
}

/* =============== Root & Base Styles =============== */
:root {
  --font-sans: 'Helvetica Neue', Arial, sans-serif;
  --primary-color: #005f73;
  --accent-color: #0a9396;
  --text-color: #333;
  --bg-light: #fafafa;
  --spacing: 1rem;
}

body {
  font-family: var(--font-sans);
  color: var(--text-color);
  line-height: 1.6;
  background-color: grey;
  min-height: 100vh;
}

/* =============== Typography =============== */
h1 {
  font-size: 2.0rem;
  color: white;
  text-align: left;
}
h2 {
  font-size: 2.5rem;
  margin-bottom: 1.5rem;
  text-align: center;
}
h3 {
  font-size: 1.5rem;
  color: var(--accent-color);
}

/* =============== Layout Containers =============== */
main {
  max-width: 1000px;
  margin: 0 auto;
  padding: var(--spacing);
  padding-top: 100px; 
}

/* =============== Header & Navigation =============== */
header {
  background-color: var(--primary-color);
  color: white;
  text-align: left;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  padding: 8px 10px;     /* Top and bottom padding reduced */
  font-size: 1.0rem;      /* Smaller text */
  line-height: 1.0;
}
header nav ul {
  display: flex;
  justify-content: center;
  gap: var(--spacing);
   padding: 0px; 
}
header nav a {
  color: white;
  text-decoration: none;
  font-weight: bold;
  padding-top: 0px;
}
header nav a:hover {
  text-decoration: underline;
}

/* =============== About Section =============== */
#about {
  display: legacy;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--spacing);
}
#about img {
  border-radius: 50%;
  width: 150px;
  height: 150px;
  object-fit: cover;
}
#about p {
  flex: 1;
}

/* =============== Skills, Education, Interests =============== */
section {
  margin-top: calc(var(--spacing) * 2);
}
section ul {
  display: flex;
  flex-wrap: wrap;
  gap: var(--spacing);
}
section ul li {
  background-color: white;
  padding: 0.5em 1em;
  border-radius: 5px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}
#skills img {
  border-radius: 100%;
  width: 20px;
  height: 20px;
  object-fit: cover;
}
#education img {
  border-radius: 100%;
  width: 100px;
  height: 100px;
  object-fit: cover;
}
#interests img {
  border-radius: 100%;
  width: 100px;
  height: 100px;
  object-fit: cover;
}
/* =============== Projects =============== */
#projects article {
  background-color: white;
  padding: var(--spacing);
  margin-bottom: calc(var(--spacing) * 1.5);
  border-radius: 5px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  transition: transform 0.3s ease;
}
#projects article:hover {
  transform: translateY(-5px);
}
#projects a {
  color: var(--accent-color);
  text-decoration: none;
  font-weight: bold;
}
#projects a:hover {
  text-decoration: underline;
}

/* =============== Contact Form =============== */
form {
  display: grid;
  gap: var(--spacing);
  margin-top: var(--spacing);
}
form label {
  font-weight: bold;
}
form input,
form textarea {
  padding: 0.75em;
  font: inherit;
  border: 1px solid #ccc;
  border-radius: 4px;
  width: 100%;
}
form button {
  background-color: var(--accent-color);
  color: white;
  border: none;
  padding: 0.75em 1.5em;
  border-radius: 4px;
  font-size: 1rem;
  cursor: pointer;
}
form button:hover {
  background-color: var(--primary-color);
}
#contact img {
  border-radius: 100%;
  width: 30px;
  height: 30px;
  object-fit: cover;
}
/* =============== Footer =============== */
footer {
  margin-top: calc(var(--spacing) * 2);
  background-color: var(--primary-color);
  color: black;
  padding: var(--spacing);
  text-align: center;
}
footer a {
  color: black;
  text-decoration: none;
  margin: 0 0.5em;
}
footer a:hover {
  text-decoration: underline;
}
#footer img {
  border-radius: 100%;
  width: 30px;
  height: 30px;
  object-fit: cover;
}
/* =============== Responsive Design =============== */
@media (max-width: 786px) {
  #about {
    flex-direction: column;
    text-align: center;
  }
  header nav ul {
    flex-direction: column;
    gap: 1rem;
  }
}