:root {
  /* Colores modo claro */
  --bg-color: #ffffff;
  --text-color: #1a1a1a;
  --card-bg: #f0f0f0;
}



[data-theme="dark"] {
  /* Colores modo oscuro */
  --bg-color: #1a1a1a;
  --text-color: #ffffff;
  --card-bg: #2d2d2d;

}

/* Ocultar iconos según el tema (opcional) */
[data-theme="dark"] .icon-dark { display: inline; font-size: 1.5rem; } 
[data-theme="dark"] .icon-light { display: none; font-size: 1.5rem }
[data-theme="light"] .icon-dark { display: none; font-size: 1.5rem }
[data-theme="light"] .icon-light { display: inline; font-size: 1.5rem }



body {
    font-family: sans-serif;
    margin: 0;
    padding: 0;
    background-size: 100%;
    background-repeat: no-repeat;
    background-position: center center;
    background-attachment: fixed;
    background-color: var(--bg-color);
    color: var(--text-color);
    transition: background-color 0.3s, color 0.3s; 


.btn-toggle {
  padding: 10px 20px;
  cursor: pointer;
  border-radius: 30px;
  border: 2px solid var(--text-color); 
  background-color: var(--bg-color);   
  color: var(--text-color);
  font-weight: bold;
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 20px;
  transition: all 0.3s ease;
}

/* Efecto hover */
.btn-toggle:hover {
  opacity: 0.8;
  transform: scale(1.05);
}


.navbar {
    background-color: lightslategray;
    color: white;
    text-align: center;
    padding: 10px;
    margin: auto;
}


#hero {
    background-color: var(--bg-color);
    justify-content: center;
    align-items: center;
    text-align: center;
    width: 100%;
    margin: auto;
    height: 100vh;
    height: 100dvh;
    color: var(--text-color);
    padding: 20dvw;
}

.icon-link{
  padding: 4px;
}

.icon-link img{
  width: 55px;
  height: 55px;
  line-height: 0;
  pointer-events: auto !important;
  transform: transform 0.5s ease;
}

  .icon-link:hover img {
    transform: scale(1.1) !important; 
  }

  .icon-dark{
    display: none;
  }

.grid {
  margin: auto;
  width: 100%;
  max-width: 1500px;
  display: grid;
  gap: 1.5vw;
  padding: 1vw;
  grid-template-columns: repeat(6, 1fr);
  grid-template-rows: auto;
  grid-template-areas:
  "about-me about-me about-me about-me projects projects"
  "experience experience form form form form";
}


.item {
  border: 2px solid #464545;
  border-radius: 5px;
  background-color: var(--card-bg); 
  color: var(--text-color);
  transition: background-color 0.4s ease, border-color 0.4s ease, transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease ;
  border: 1px solid rgba(0,0,0,0.1);
  
  
}


.item:hover {
  transform: translateY(-3px); 
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1); 
  border-color: var(--text-color); 
}



.grid .item:nth-child(1) {
  grid-area: about-me;
  
}
.grid .item:nth-child(2) {
  grid-area: projects;
}

.grid .item:nth-child(3) {
  grid-area: experience;
}
.grid .item:nth-child(4) {
  grid-area: form;
}

@media screen and (max-width: 750px) {
  .grid {
    grid-template-columns: repeat(1, 1fr);
    grid-template-areas:
      "about-me" 
      "experience"
      "projects" 
      "form";
  }
  #hero {
    height: 50vh;
    height: 50dvh;
    margin-top: auto;
  }
}

#bento-grid {
    background-color: var(--bg-color)
}


.contact-container {
  max-width: 400px;
  margin: 2rem auto;
  padding: 2rem;
  background: var(--card-bg);
  border-radius: 20px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.175);
}

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

input, textarea {
  width: 100%;
  padding: 12px;
  border: 1px solid rgba(0,0,0,0.1);
  border-radius: 10px;
  background: var(--bg-color);
  color: var(--text-color);
  font-family: inherit;
  transition: border-color 0.3s ease;
}

input:focus, textarea:focus {
  outline: none;
  border-color: #3498db;
}

textarea { height: 120px; resize: none; }

button .submit-button {
  width: 100%;
  padding: 12px;
  background: #1a1a1a; 
  color: white;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  font-weight: 600;
  transition: transform 0.2s ease;
}

button:hover { transform: scale(1.02); }

.error-msg {
  color: #e74c3c;
  font-size: 12px;
  display: none; 
  margin-top: 5px;
}

#success-message {
  margin-bottom: 14px;
  text-align: center;
  font-size: 14px;
  display:none;
}

#fail-send-message {
  margin-bottom: 14px;
  text-align: center;
  font-size: 14px;
  display:none;
}

#hero {
  position: relative;
  overflow: hidden; 
  z-index: 1;
}


.hero-bg {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  z-index: -1; 
  filter: blur(60px); 
  opacity: 0.6;
  overflow: hidden; 
  pointer-events: none;
}


.blob {
  position: absolute;
  width: 150px;
  height: 150px;
  background: var(--text-color); 
  border-radius: 50%;
  animation: float 15s infinite alternate ease-in-out;
  pointer-events: none; 
  user-select: none;
  mix-blend-mode: screen;
  mix-blend-mode: multiply;
}


.blob:nth-child(1) {
  top: 10%;
  left: 20%;
  background: #0f7fca81; 
}

.blob:nth-child(2) {
  bottom: 20%;
  right: 10%;
  background: rgba(0, 255, 255, 0.28);
  animation-duration: 20s;
  animation-delay: -5s;
}

.blob:nth-child(3) {
  top: 10%;
  right: 20%;
  background:rgba(76, 0, 130, 0.307); 
  animation-duration: 20s;
  animation-delay: -2s;
}

.blob:nth-child(4) {
  bottom: 20%;
  left: 10%;
  background: rgba(170, 255, 196, 0.284); 
  animation-duration: 20s;
  animation-delay: -2s;
}

.blob:nth-child(5) {
  bottom: 40%;
  left: 50%;
  background: rgb(252, 252, 252); 
  animation-duration: 20s;
  animation-delay: -5s;
}

.blob:nth-child(6) {
  bottom: 60%;
  left: 40%;
  background:rgba(76, 0, 130, 0.52); 
  animation-duration: 20s;
  animation-delay: -2s;
}

.blob:nth-child(7) {
  bottom: 60%;
  left: 60%;
  background: rgb(5, 255, 255);
  animation-duration: 20s;
  animation-delay: -5s;
}


.blob:nth-child(8) {
  bottom: 40%;
  right: 55%;
  background: #0f7fca81; 
  animation-duration: 20s;
  animation-delay: -2s;
}



@keyframes float {
  0% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(30px, -50px) scale(1.2); }
  66% { transform: translate(-20px, 20px) scale(0.8); }
  100% { transform: translate(0, 0) scale(1); }
}


.hero-content {
  position: relative;
  z-index: 2;
  pointer-events: none; 
}


.hero-content h1, h2{
  padding: 20px; 
}

.flex-container {
  display: flex;             
  flex-direction: row;      
  align-items: center;     
  justify-content: space-between; 
  gap: 20px;              
  padding: 2rem;        
  ;
}
.text-content{

padding: 20px;
border-radius: 20px;
box-shadow: 0 10px 30px rgba(0, 0, 0, 0.175);
line-height: 1.5rem;

}

@media (max-width: 600px) {
  .flex-container {
    flex-direction: column-reverse; 
  }
}

.text-content {
  flex: 1;
  font-size: 14px;                  
}

.image-content {
  flex: 1;                 
  display: flex;
  justify-content: flex-end;
}

.image-content img {
  max-width: 100%;          
  height:20rem;
  border-radius: 15px;      
  object-fit: cover;
  margin:auto;
}

#education {
    font-size: 14px;
    margin: auto;
    justify-content: center;
    align-items: center;
    align-content: center;
    text-align: center;
    margin-top: 3rem;
    padding-top: 3rem;
    padding-bottom: 3rem;
    line-height: 3px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.175);
    border-radius: 20px;

    
}

@media (max-width: 750px) {
  #education {
    margin-top: 2rem;
    margin-bottom: 2rem; 
    padding: 1px;
  }
}

.item #skills{
    font-size: 14px;
    margin: auto;
    padding: 3rem;
    list-style: none; 
    text-align: center;   
}

.item .skill {

   box-shadow: 0 10px 30px rgba(0, 0, 0, 0.175); 
   padding: 10px;
   border-radius: 20px;
}


h3 {
    text-align: center;
    justify-content: center;
    align-items: center;
}

.list {
    list-style: none;
    padding: 0;
    line-height: 1.7rem;
}

}