:root {
  --primary-color: #7f5af0;
  --secondary-color: #6c4bd1;
  --dark-color: #0f0e17;
  --light-color: #fffffe;
  --gray-color: #a7a9be;
  --dark-gray: #242629;
  --accent-color: #2cb67d;
  --highlight-color: #ff8906;
  --text-primary: #fffffe;
  --text-secondary: #94a1b2;
}

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

body {
  font-family: "Poppins", sans-serif;
  background-color: var(--dark-color);
  color: var(--text-primary);
  line-height: 1.6;
  padding: 0;
  margin: 0;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem;
}

/* Sección de perfil */
.profile-section {
  background: linear-gradient(135deg, #16161a 0%, #242629 100%);
  border-radius: 16px;
  padding: 2.5rem;
  margin-bottom: 2rem;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.profile-header {
  display: flex;
  align-items: center;
  gap: 2rem;
  margin-bottom: 1.5rem;
}

.profile-img {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid var(--primary-color);
  box-shadow: 0 5px 20px rgba(127, 90, 240, 0.3);
}

.profile-title {
  font-size: 2.2rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: var(--text-primary);
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.profile-subtitle {
  font-size: 1.2rem;
  font-weight: 400;
  color: var(--primary-color);
  margin-bottom: 1rem;
}

.tag-list {
  display: flex;
  gap: 0.8rem;
}

.tag {
  background-color: rgba(127, 90, 240, 0.15);
  color: var(--primary-color);
  padding: 0.4rem 0.8rem;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 500;
  border: 1px solid rgba(127, 90, 240, 0.3);
}

.profile-description {
  font-size: 1.1rem;
  margin-bottom: 2rem;
  color: var(--gray-color);
  line-height: 1.8;
}

.social-links {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

/* Botones especiales */
.special-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 30px;
  color: white;
  text-decoration: none;
  font-weight: 600;
  font-size: 18px;
  text-transform: uppercase;
  letter-spacing: 1px;
  overflow: hidden;
  border-radius: 8px;
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
  cursor: pointer;
  margin: 0.5rem 0;
  border: none;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.special-btn i {
  margin-right: 10px;
  transition: all 0.3s ease;
}

.special-btn::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.2),
    transparent
  );
  transition: 0.5s;
}

.special-btn:hover::before {
  left: 100%;
}

.linkedin-btn {
  background: linear-gradient(135deg, #0a66c2 0%, #004182 100%);
}

.github-btn {
  background: linear-gradient(135deg, #333 0%, #000 100%);
}

.gitlab-btn {
  background: linear-gradient(135deg, #fc6d26 0%, #e24329 100%);
}

.special-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
}

.special-btn:hover i {
  transform: scale(1.2);
  text-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
}

/* Sección de habilidades */
.section-title {
  font-size: 1.8rem;
  margin-bottom: 2rem;
  position: relative;
  display: inline-block;
  font-weight: 600;
}

.section-title::after {
  content: "";
  position: absolute;
  bottom: -8px;
  left: 0;
  width: 50px;
  height: 3px;
  background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
  border-radius: 2px;
}

.skills-section {
  margin-bottom: 3rem;
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 1.5rem;
}

/* Botones brutalistas */
.button-container {
  display: flex;
  justify-content: center;
}

.brutalist-button {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border: 3px solid var(--dark-gray);
  border-radius: 12px;
  padding: 0;
  background-color: var(--main-color);
  color: #000;
  font-weight: bold;
  position: relative;
  box-shadow: 4px 4px 0px var(--dark-gray);
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  height: 130px;
  width: 130px;
  cursor: pointer;
}

.brutalist-button::before {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -150%;
  width: 300%;
  height: 300%;
  border-radius: 50%;
  transform: translateX(-50%) scale(0);
  transition: transform 0.6s cubic-bezier(0.19, 1, 0.22, 1);
  z-index: 1;
  background-color: var(--dark-color);
}

.tech-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 2;
  width: 90px;
  height: 90px;
  border-radius: 50%;
  transition: all 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  background-color: var(--light-color);
}

.tech-icon {
  font-size: 50px;
  color: var(--main-color);
  transition: all 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.button-text {
  display: flex;
  align-items: center;
  line-height: 1.3;
  transition: all 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  text-align: center;
  opacity: 0;
  transform: translateY(20px);
  z-index: 2;
  position: absolute;
  bottom: 18px;
  left: 0;
  right: 0;
  justify-content: center;
}

.button-text span {
  font-size: 16px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: #fff;
}

.brutalist-button:hover::before {
  transform: translateX(-50%) scale(1);
}

.brutalist-button:hover .tech-logo {
  animation: spin 5s linear infinite;
  width: 50px;
  height: 50px;
  top: 28%;
}

.brutalist-button:hover .tech-icon {
  transform: scale(0.6);
}

.brutalist-button:hover .button-text {
  opacity: 1;
  transform: translateY(0);
}

.brutalist-button:hover {
  transform: translate(-4px, -4px);
  box-shadow: 8px 8px 0px var(--dark-gray);
}

.brutalist-button:active {
  transform: translate(2px, 2px);
  box-shadow: 2px 2px 0px var(--dark-gray);
}

@keyframes spin {
  0% {
    transform: translate(-50%, -50%) rotate(0deg);
  }
  100% {
    transform: translate(-50%, -50%) rotate(360deg);
  }
}

/* Sección de proyectos */
.projects-section {
  margin-bottom: 3rem;
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 2rem;
}

.project-card {
  background-color: var(--dark-gray);
  border-radius: 12px;
  padding: 1.5rem;
  transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.project-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.4);
  border-color: var(--primary-color);
}

.project-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.project-header h3 {
  font-size: 1.3rem;
  font-weight: 600;
}

.project-links {
  display: flex;
  gap: 1rem;
}

.project-links a {
  color: rgba(255, 255, 255, 0.6);
  transition: color 0.3s ease;
}

.project-links a:hover {
  color: var(--primary-color);
}

.project-description {
  color: var(--gray-color);
  margin-bottom: 1.5rem;
  font-size: 0.95rem;
}

.project-tech {
  display: flex;
  gap: 0.8rem;
  flex-wrap: wrap;
}

.project-tech span {
  background-color: rgba(127, 90, 240, 0.15);
  color: var(--primary-color);
  padding: 0.4rem 0.8rem;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 500;
  border: 1px solid rgba(127, 90, 240, 0.3);
}

/* Sección de contacto */
.contact-section {
  margin-bottom: 3rem;
}

.contact-form {
  max-width: 600px;
  margin: 0 auto;
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 1rem;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background-color: var(--dark-gray);
  color: var(--text-primary);
  font-family: "Poppins", sans-serif;
  transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 2px rgba(127, 90, 240, 0.3);
}

.submit-btn {
  background: linear-gradient(
    135deg,
    var(--primary-color),
    var(--secondary-color)
  );
  color: white;
  border: none;
  padding: 1rem 2rem;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  width: 100%;
  letter-spacing: 1px;
}

.submit-btn:hover {
  background: linear-gradient(
    135deg,
    var(--secondary-color),
    var(--primary-color)
  );
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(127, 90, 240, 0.4);
}

/* Footer */
.main-footer {
  text-align: center;
  padding: 2rem 0;
  color: var(--text-secondary);
  font-size: 0.9rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

/* Grid layout para perfil y habilidades */
.profile-skills-wrapper {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: 2rem;
  margin-bottom: 3rem;
}

/* Responsive Design */
@media (max-width: 1024px) {
  .profile-skills-wrapper {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .profile-header {
    flex-direction: column;
    text-align: center;
  }

  .tag-list {
    justify-content: center;
  }

  .social-links {
    justify-content: center;
  }

  .skills-grid {
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  }

  .projects-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 1.5rem;
  }

  .profile-section {
    padding: 1.5rem;
  }

  .profile-img {
    width: 100px;
    height: 100px;
  }

  .profile-title {
    font-size: 1.8rem;
  }

  .special-btn {
    padding: 0.7rem 1.2rem;
    font-size: 0.9rem;
  }
}

/* Estilo para el botón de email */
.email-btn {
  background: linear-gradient(135deg, #d44638 0%, #b23121 100%);
}

.email-btn:hover {
  background: linear-gradient(135deg, #b23121 0%, #d44638 100%);
  box-shadow: 0 0 15px #d44638;
}

/* Estilo para el botón de CV */
.cv-btn {
  background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
}

.cv-btn:hover {
  background: linear-gradient(135deg, #c0392b 0%, #e74c3c 100%);
  box-shadow: 0 0 15px #e74c3c;
}

/* Facebook - Azul oscuro */
.facebook-btn {
  background: linear-gradient(135deg, #1877f2 0%, #146cdf 100%);
}
.facebook-btn:hover {
  background: linear-gradient(135deg, #146cdf 0%, #1877f2 100%);
  box-shadow: 0 0 15px #1877f2;
}

/* Instagram - Degradado morado/naranja */
.instagram-btn {
  background: linear-gradient(135deg, #833ab4 0%, #c13584 50%, #e1306c 100%);
}
.instagram-btn:hover {
  background: linear-gradient(135deg, #e1306c 0%, #c13584 50%, #833ab4 100%);
  box-shadow: 0 0 15px #c13584;
}

/* YouTube - Rojo */
.youtube-btn {
  background: linear-gradient(135deg, #ff0000 0%, #cc0000 100%);
}
.youtube-btn:hover {
  background: linear-gradient(135deg, #cc0000 0%, #ff0000 100%);
  box-shadow: 0 0 15px #ff0000;
}
