/* Reset and base styles */
@import url("https://fonts.googleapis.com/css2?family=Faustina:ital,wght@0,300..800;1,300..800&display=swap");

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

body {
  font-family: "Faustina", serif;
  line-height: 1.6;
  color: #2d3748;
  background-color: #f7f8fc;
  font-size: 18px;
}

/* Container */
.container {
  max-width: 72vw;
  margin: 0 auto;
  padding: 2rem 1.5rem;
  min-height: 100vh;
  animation: fadeIn 0.8s ease-in;
}

/* Header */
header {
  margin-bottom: 1rem;
  border-bottom: 1px solid #e2e8f0;
}

.header-content {
  padding: 2rem;
  margin-bottom: 2rem;
  position: relative;
}

.header-text {
  text-align: left;
}

.header-pic-wrapper {
  float: right;
  width: clamp(200px, 25vw, 300px); /* Responsive width: min 200px, max 300px */
  height: clamp(
    112px,
    14vw,
    168px
  ); /* Responsive height: maintains aspect ratio */
  margin: 0 0 1rem 2rem;
  shape-outside: margin-box;
}

.header-pic {
  width: 100%;
  height: 100%;
  border-radius: 12px;
  object-fit: cover;
}

.about {
  display: block;
  text-align: start;
  background: transparent;
  padding: 0;
  border-radius: 0;
  box-shadow: none;
  margin: 0;
  clear: none;
}

.about p {
  margin-bottom: 1rem;
  line-height: 1.6;
  text-align: left;
}

.header-text h1 {
  margin-bottom: 2rem;
  margin-top: 0;
  line-height: 1;
  padding-top: 0;
}

h1 {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  font-weight: 300;
  margin-bottom: 0.5rem;
  color: #1a202c;
  white-space: nowrap;
}

.subtitle {
  font-size: 1.1rem;
  color: #718096;
  font-style: italic;
  margin-bottom: 1.5rem;
}

/* Banner Navigation */
.banner {
  position: sticky;
  top: 0;
  background-color: rgba(247, 248, 252, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid #e2e8f0;
  z-index: 100;
  margin: -2rem -1.5rem 2rem -1.5rem;
  padding: 0 1.5rem;
}

.banner-content {
  max-width: 72vw;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 0;
}

.logo h1 {
  font-size: 1.5rem;
  font-weight: 500;
  margin: 0;
  color: #1a202c;
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 2rem;
  margin: 0;
  padding: 0;
}

.nav-links a {
  color: #4a5568;
  text-decoration: none;
  font-weight: 500;
  padding: 0.5rem 0;
  border-bottom: 2px solid transparent;
  transition: all 0.2s ease;
  font-size: 1rem;
}

.nav-links a:hover {
  border-bottom-color: #4299e1;
  color: #2d3748;
}

/* Main content */
main {
  margin-bottom: 3rem;
}

section {
  margin-bottom: 3rem;
}

h2 {
  font-size: 1.5rem;
  font-weight: 400;
  margin-bottom: 1rem;
  color: #2d3748;
  position: relative;
  display: inline-block;
}

h2::after {
  content: "";
  position: absolute;
  bottom: -0.5rem;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: #4299e1;
}

p {
  margin-bottom: 1rem;
  color: #4a5568;
}

/* Experience section */
.experience-grid {
  display: grid;
  gap: 1.5rem;
  margin-top: 1.5rem;
}

.experience-card {
  background: transparent;
  padding: 1.5rem;
  border-radius: 8px;
  box-shadow: none;
  transition: all 0.3s ease;
}

.experience-card:hover {
  background: white;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  transform: translateY(-2px);
}

.experience-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 0.5rem;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.experience-header h3 {
  font-size: 1.2rem;
  margin: 0;
  color: #2d3748;
  font-weight: 500;
}

.experience-date {
  font-size: 0.9rem;
  color: #718096;
  font-weight: 400;
  white-space: nowrap;
}

.experience-company {
  font-size: 1rem;
  color: #4299e1;
  font-weight: 500;
  margin-bottom: 1rem;
}

.experience-description {
  margin-bottom: 1rem;
}

.experience-description p {
  margin-bottom: 1rem;
  line-height: 1.6;
  color: #4a5568;
}

.experience-description p:last-child {
  margin-bottom: 0;
}

.experience-skills {
  font-size: 0.9rem;
  padding-top: 0.75rem;
  border-top: 1px solid #e2e8f0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.experience-skills::before {
  content: "Technologies: ";
  color: #718096;
  font-weight: 500;
  margin-right: 0.25rem;
  align-self: center;
}

/* Projects grid */
.projects-grid {
  display: grid;
  gap: 1.5rem;
  margin-top: 1.5rem;
}

.project-card {
  background: transparent;
  padding: 1.5rem;
  border-radius: 8px;
  box-shadow: none;
  transition: all 0.3s ease;
}

.project-card:hover {
  background: white;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  transform: translateY(-2px);
}

.project-card h3 {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
  color: #2d3748;
}

.project-description {
  margin-bottom: 1rem;
}

.project-description p {
  font-size: 1rem;
  margin-bottom: 0.5rem;
}

.project-skills {
  font-size: 0.9rem;
  padding-top: 0.75rem;
  border-top: 1px solid #e2e8f0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.project-skills::before {
  content: "Technologies: ";
  color: #718096;
  font-weight: 500;
  margin-right: 0.25rem;
  align-self: center;
}

.project-links {
  margin-top: 1rem;
}

.project-links a {
  color: #4299e1;
  text-decoration: none;
  font-size: 0.9rem;
  margin-right: 1rem;
}

.project-links a:hover {
  text-decoration: underline;
}

/* Contact section */
.contact {
  text-align: center;
  background: white;
  padding: 2rem;
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.contact-links {
  display: flex;
  justify-content: center;
  gap: 2rem;
  margin-top: 1rem;
  flex-wrap: wrap;
}

.contact-link {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: #4299e1;
  text-decoration: none;
  font-weight: 500;
  padding: 0.75rem 1rem;
  border-radius: 8px;
  transition: all 0.2s ease;
  background-color: rgba(66, 153, 225, 0.1);
}

.contact-link:hover {
  background-color: rgba(66, 153, 225, 0.2);
  transform: translateY(-2px);
  text-decoration: none;
}

.contact-icon {
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.contact-icon svg {
  width: 20px;
  height: 20px;
}

/* Skill tags */
.skill-tag {
  display: inline-block;
  background-color: #f1f5f9;
  color: #1e293b;
  font-size: 0.8rem;
  font-weight: 700;
  padding: 0.25rem 0.75rem;
  border-radius: 16px;
  border: 1px solid #e2e8f0;
  transition: all 0.2s ease;
}

.skill-tag:hover {
  background-color: #e2e8f0;
  border-color: #cbd5e1;
  transform: translateY(-1px);
}

/* Footer */
footer {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid #e2e8f0;
  color: #718096;
  font-size: 0.9rem;
}

/* Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Responsive design */
@media (max-width: 768px) {
  .container {
    padding: 1rem;
  }

  .header-content {
    text-align: center;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .header-text {
    text-align: center;
    order: 2;
  }

  .header-pic-wrapper {
    float: none;
    display: block;
    margin: 0 auto 1.5rem auto;
    order: 1;
    width: clamp(200px, 50vw, 300px);
    height: clamp(112px, 28vw, 168px);
  }

  .experience-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.25rem;
  }

  .experience-date {
    white-space: normal;
  }

  h1 {
    font-size: clamp(1.5rem, 5vw, 2rem);
    white-space: nowrap;
  }

  .banner {
    margin: -1rem -1rem 2rem -1rem;
    padding: 0 1rem;
  }

  .banner-content {
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 0;
  }

  .logo h1 {
    font-size: 1.3rem;
  }

  .nav-links {
    gap: 1.5rem;
  }

  .nav-links a {
    font-size: 0.9rem;
  }

  .contact-links {
    flex-direction: column;
    gap: 1rem;
    align-items: center;
  }

  .contact-link {
    width: 100%;
    max-width: 280px;
    justify-content: center;
  }
}

/* Additional breakpoint for very small screens */
@media (max-width: 480px) {
  .header-content {
    padding: 0.5rem;
  }

  .header-pic-wrapper {
    width: 180px;
    height: 101px;
    margin: 0 auto 1rem auto;
  }

  h1 {
    font-size: clamp(1.3rem, 6vw, 1.8rem);
    white-space: nowrap;
  }
}

/* Print styles */
@media print {
  body {
    background: white;
  }

  .about,
  .project-card,
  .contact {
    box-shadow: none;
    border: 1px solid #e2e8f0;
  }
}
