body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background-color: #f6e5d9;
  background-image: url('img/portfoliobg.png');
  background-repeat: repeat;
  color: #3a3a3a;
  margin: 30px;
  font-size: 16px;
  line-height: 20px;
}

header, section {
  padding: 20px 40px;
  margin: 30px auto;
  max-width: 1000px;
  background: #fffef7;
  border-radius: 20px;
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.06);
  transition: box-shadow 0.3s ease;
}

section:hover {
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.08);
}

h1 {
  font-family: 'Radley';
  font-size: 45px;
}

.wipe-text {
  display: inline-block;
  position: relative;
  overflow: hidden;
  line-height: 1.2;
}

.wipe-text::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  width: 100%;
  background: #fffef7;
  transform: translateX(0);
  animation: wipeReveal 2s ease forwards;
  z-index: 1;
}

@keyframes wipeReveal {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(100%);
  }
}


h2 {
  color: #69443c;
  font-family: 'Roca One';
}

h3 {
  color: #552b19;
  font-family: 'Lato', sans-serif;
}

.intro {
  display: flex;
  gap: 40px;
  align-items: center;
  justify-content: center;
  min-height: 300px;
  flex-wrap: wrap;
  text-align: center;
}

/* .intro img {
  width: 150px;
  height: 190px;
  border-radius: 50px 50px 0 0;
  border: 5px solid transparent;
  background-color: #8b5e3c;        
} */

.link-block {
  color: #c26d2d;
  text-decoration: none;
  padding: 8px 15px;
}

.skills .grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
  gap: 20px;
  margin-top: 30px;
  justify-items: center;
}

.skills .grid img {
  width: 60px;
  height: 60px;
  object-fit: contain;
  border-radius: 16px;
  background: linear-gradient(145deg, #f3f7ee, #e0e9d7);
  padding: 12px;
  box-shadow:
    4px 4px 8px #c1cfb7,
    -4px -4px 8px #ffffff;
}

.portfolio .projects {
  display: flex;
  flex-wrap: wrap;
  gap: 28px;
  justify-content: center;
}

.project-card {
  width: 100%;        
  max-width: 300px;       
  background-color: #fffef7;
  border-radius: 16px;
  overflow: hidden;
  cursor: pointer;
  box-shadow: 0 6px 18px rgba(160, 180, 140, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border: 1px solid #dfe6d0;

  display: flex;
  flex-direction: column;
}

.project-card:hover {
  transform: scale(1.05);
  box-shadow: 0 12px 28px rgba(160, 180, 140, 0.2);
}

.project-card img {
  width: 100%;
  height: 160px;
  object-fit: cover;
  border-bottom: 2px solid #dfe6d0;
}

.project-card .desc {
  padding: 16px 14px;
  font-weight: 500;
  color: #4a4a4a;
  flex-grow: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-size: 16px;
}

.portfolio-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
}

.image-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr); /* 2 columns */
  gap: 4px;
  width: 100%;
  aspect-ratio: 1 / 1; 
}

.image-grid img {
  width: 100%;
  aspect-ratio: 1 / 1;  
  object-fit: cover;
  display: block;
}


/* ------------------ Responsive for Mobile ------------------ */
@media (max-width: 768px) {
  header, section {
    padding: 32px 20px;
    margin: 30px;
  }

  .intro {
    flex-direction: column;
    gap: 25px;
    min-height: auto;
  }

  .intro img {
    width: 120px;
    height: 160px;
  }

  h1 {
    font-family: 'Radley';
    font-size: 32px;
  }

  .skills .grid {
    grid-template-columns: repeat(auto-fit, minmax(60px, 1fr));
    gap: 16px;
  }

  .skills .grid img {
    width: 50px;
    height: 50px;
    padding: 10px;
  }

  .portfolio-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .project-card {
    width: 100%;
  }

  .project-card img {
    height: 140px;
  }
}
