/* ตั้งค่าเบื้องต้น */
body {
  font-family: 'Segoe UI', sans-serif;
  margin: 0;
  padding: 0;
  background: linear-gradient(to right, #131313, #757575);
  color: #333;
}

/* กล่องหลัก */
.container {
  max-width: 900px;
  margin: auto;
  padding: 2rem;
  background: #fff;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
  border-radius: 15px;
  margin-top: 50px;
  animation: fadeIn 1.5s ease-in;
}

/* เฮดเดอร์ */
header {
  text-align: center;
  margin-bottom: 2rem;
}

header h1 {
  font-size: 2.5rem;
  color: #007acc;
  transition: color 0.5s;
}

header h1:hover {
  color: #ff6600;
}

header p {
  line-height: 1.6;
  margin: 5px 0;
}

/* ภาพ */
img {
  width: 30%;
  height: auto;
  border-radius: 15px;
  box-shadow: 0 0 8px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease;
}

img:hover {
  transform: scale(1.05);
}

/* ส่วนต่าง ๆ */
section {
  margin-bottom: 2rem;
}

h2 {
  color: #007acc;
  border-left: 5px solid #007acc;
  padding-left: 10px;
  margin-bottom: 1rem;
}

/* ทักษะ */
.skills ul {
  list-style: none;
  padding-left: 0;
}

.skills li {
  background-color: #e0f7fa;
  padding: 12px 20px;
  margin: 8px 0;
  border-radius: 8px;
  transition: background 0.3s, transform 0.2s;
}

.skills li:hover {
  background-color: #b2ebf2;
  transform: translateX(10px);
}

/* ส่วนติดต่อ */
.contact p {
  font-size: 1.1rem;
}

/* Animation fade-in */
@keyframes fadeIn {
  0% {
    opacity: 0;
    transform: translateY(20px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Responsive */
@media screen and (max-width: 768px) {
  img {
    width: 60%;
  }

  header h1 {
    font-size: 2rem;
  }

  .container {
    padding: 1rem;
  }
}
