body {
  font-family: "Roboto", sans-serif;
  background-color: #2e2e2e;
  margin: 0;
  padding: 0;
  line-height: 1.6;
  overflow-x: hidden;
}

/* Fade-in on scroll */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Hero */
.hero {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  top: -10px;
  left: -10px;
  width: calc(100% + 20px);
  height: calc(100% + 20px);
  background-image: url(/img/sfondo3.jpg);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  filter: blur(5px);
  z-index: -1;
}

.hero-content {
  padding: 10px;
}

.hero-content img {
  width: 200px;
  height: 200px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid #f4cd58;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.5);
  transition: transform 0.3s ease;
}

.hero-content img:hover {
  transform: scale(1.05);
}

.hero-content h1 {
  font-size: 36px;
  color: #f4cd48;
  margin-top: 20px;
  text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.6);
}

.hero-subtitle {
  font-size: 20px;
  color: #f5f5f5;
  margin: 8px 0 20px;
  min-height: 30px;
  text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.5);
}

.cursor {
  color: #f4cd58;
  animation: blink 0.8s infinite;
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

.scroll-down {
  display: inline-block;
  margin-top: 30px;
  color: #f5f5f5;
  font-size: 24px;
  animation: bounce 2s infinite;
}

@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(8px); }
}

/* Social icons in hero */
.social-card {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-top: 20px;
}

.social-card a {
  color: #f5f5f5;
  transition: color 0.3s ease, transform 0.3s ease;
}

.social-card a:hover {
  color: #f4cd58;
  transform: scale(1.2);
}

/* Sections */
.section {
  padding: 60px 20px;
  text-align: center;
  max-width: 1200px;
  margin: 0 auto;
}

.section h2 {
  font-size: 32px;
  color: #f4cd58;
  margin-bottom: 20px;
}

/* About card */
.about-card p {
  font-size: 17px;
  color: #444;
  line-height: 1.9;
  text-align: left;
  margin: 0;
}

/* Skill cards grid */
.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin-top: 30px;
}

.project-card {
  background-color: #fff;
  padding: 20px;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  text-align: center;
}

.project-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.15);
}

.project-card h3 {
  margin: 10px 0 10px 0;
  font-size: 16px;
  color: #333;
}

.icon-project img {
  width: 80px;
  height: 80px;
  margin: 0 auto;
  object-fit: contain;
}

/* Progress bars */
.progress-bar {
  width: 100%;
  height: 10px;
  background-color: #eee;
  border-radius: 5px;
  overflow: hidden;
  margin-top: 8px;
}

.progress {
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, #f4cd58, #e6b800);
  border-radius: 5px;
  transition: width 1s ease;
}

.progress-label {
  display: block;
  font-size: 13px;
  color: #888;
  margin-top: 5px;
}

/* Contact section */
.contact-section {
  text-align: center;
  padding: 60px 20px;
  width: 100%;
  max-width: none;
  background-color: #fff;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.contact-section h2 {
  color: #333;
  margin: 0 0 20px;
}

.contact-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 40px;
  max-width: 600px;
  margin: 0 auto;
  text-align: center;
}

.contact-info {
  flex: 1;
  min-width: 250px;
  text-align: center;
}

.contact-email {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 16px;
  color: #424242;
  transition: color 0.3s ease;
  margin: 20px auto;
}

.contact-email:hover {
  color: #f4cd58;
}

.social-links {
  display: flex;
  gap: 20px;
  margin: 20px auto;
  justify-content: center;
}

.social-links a {
  color: #424242;
  transition: color 0.3s ease, transform 0.3s ease;
}

.social-links a:hover {
  color: #f4cd58;
  transform: scale(1.2);
}

.cta-button {
  display: inline-block;
  background-color: #f4cd58;
  color: #424242;
  border-radius: 8px;
  padding: 14px 35px;
  font-size: 16px;
  font-weight: 700;
  transition: background-color 0.3s ease, transform 0.2s ease, box-shadow 0.3s ease;
}

.cta-button:hover {
  background-color: #e6b800;
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(244, 205, 88, 0.45);
}

a {
  text-decoration: none;
}

footer {
  padding: 24px;
  text-align: center;
  background-color: #1e1e1e;
  color: #aaa;
  font-size: 14px;
}

footer p {
  margin: 0 0 8px;
}

footer a {
  color: #f4cd58;
  margin: 0 10px;
  transition: color 0.3s ease;
}

footer a:hover {
  color: #fff;
}

@media (max-width: 768px) {
  .hero {
    min-height: 80vh;
  }
  .hero-content h1 {
    font-size: 28px;
  }
  .hero-subtitle {
    font-size: 17px;
  }
  .section {
    padding: 40px 15px;
  }
  .contact-container {
    flex-direction: column;
    align-items: center;
  }
  .contact-info {
    text-align: center;
  }
  .social-links {
    justify-content: center;
  }
}
