/* === Estilos Generales === */
body {
    margin: 0;
    padding: 0;
    font-family: 'Roboto', sans-serif;
    background: 
      radial-gradient(
        circle at 90% 20%,
        rgb(233, 228, 228),
        #333 30%,
        rgba(88, 84, 84, 0) 0%
      ),
      radial-gradient(
        circle at 10% 80%,
        rgb(233, 228, 228),
        #333 30%,
        rgba(88, 84, 84, 0) 0%
      ),
      radial-gradient(
        circle at 80% 65%,
        rgb(233, 228, 228),
        #333 10%,
        rgba(88, 84, 84, 0) 0%
      ),
      radial-gradient(
        circle at 20% 35%,
        rgb(233, 228, 228),
        #333 15%,
        rgba(88, 84, 84, 0) 0%
      ),
      radial-gradient(
        circle at 50% 10%,
        rgb(233, 228, 228),
        #333 25%,
        rgba(88, 84, 84, 0) 0%
      ),
      radial-gradient(
        circle at 35% 90%,
        rgb(233, 228, 228),
        #333 20%,
        rgba(88, 84, 84, 0) 0%
      ),
      radial-gradient(
        circle at 65% 50%,
        rgb(233, 228, 228),
        #333 18%,
        rgba(88, 84, 84, 0.123) 0%
      ),
      radial-gradient(
        circle at 85% 70%,
        rgb(233, 228, 228),
        #333 15%,
        rgba(88, 84, 84, 0) 0%
      ),
      radial-gradient(
        circle at 15% 50%,
        rgb(233, 228, 228),
        #333 12%,
        rgba(88, 84, 84, 0) 0%
      ),
      radial-gradient(
        circle at 95% 85%,
        rgb(233, 228, 228),
        #333 22%,
        rgba(88, 84, 84, 0.959) 0%
      ),
      lightblue; /* Color base original */
    
    background-blend-mode: multiply;
    background-size: cover;
    min-height: 100vh;
}
/* == Botón contactame == */
.btn {
    --border-color: linear-gradient(-45deg, #e0e0e0, #404040, #C1C2BD);
    --border-width: 0.125em;
    --curve-size: 0.5em;
    --blur: 30px;
    --bg: #2d2d2d;
    --color: #e0e0e0;
    color: var(--color);
    cursor: pointer;
    position: relative;
    isolation: isolate;
    display: inline-grid;
    place-content: center;
    padding: 0.5em 1.5em;
    font-size: 13px;
    border: 0;
    box-shadow: 10px 10px 20px rgba(0, 0, 0, 0.3);
    clip-path: polygon(
      0% var(--curve-size),
      var(--curve-size) 0,
      100% 0,
      100% calc(100% - var(--curve-size)),
      calc(100% - var(--curve-size)) 100%,
      0 100%
    );
    transition: color 250ms;
}

.btn::after,
.btn::before {
    content: "";
    position: absolute;
    inset: 0;
}

.btn::before {
    background: var(--border-color);
    background-size: 300% 300%;
    animation: move-bg7234 5s ease infinite;
    z-index: -2;
}

@keyframes move-bg7234 {
    0% { background-position: 31% 0%; }
    50% { background-position: 70% 100%; }
    100% { background-position: 31% 0%; }
}

.btn::after {
    background: var(--bg);
    z-index: -1;
    clip-path: polygon(
        var(--border-width) calc(var(--curve-size) + var(--border-width) * 0.5),
        calc(var(--curve-size) + var(--border-width) * 0.5) var(--border-width),
        calc(100% - var(--border-width)) var(--border-width),
        calc(100% - var(--border-width)) calc(100% - calc(var(--curve-size) + var(--border-width) * 0.5)),
        calc(100% - calc(var(--curve-size) + var(--border-width) * 0.5)) calc(100% - var(--border-width)),
        var(--border-width) calc(100% - var(--border-width))
    );
    transition: clip-path 500ms;
}

.btn:where(:hover, :focus)::after {
    clip-path: polygon(
        calc(100% - var(--border-width)) calc(100% - calc(var(--curve-size) + var(--border-width) * 0.5)),
        calc(100% - var(--border-width)) var(--border-width),
        calc(100% - var(--border-width)) var(--border-width),
        calc(100% - var(--border-width)) calc(100% - calc(var(--curve-size) + var(--border-width) * 0.5)),
        calc(100% - calc(var(--curve-size) + var(--border-width) * 0.5)) calc(100% - var(--border-width)),
        calc(100% - calc(var(--curve-size) + var(--border-width) * 0.5)) calc(100% - var(--border-width))
    );
    transition: 200ms;
}

.btn:where(:hover, :focus) {
    color: white;
}

/*== Github  Boton== */

.git-btn {
    width: 55px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    background-color: transparent;
    position: fixed;
    bottom: 20px;
    left: 10px;
    border-radius: 7px;
    cursor: pointer;
    transition: all .3s;
    margin-top: 20px; 
    
}

.svgContainer {
    width: 100%;    
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: transparent;
    backdrop-filter: blur(0px);
    letter-spacing: 0.8px;
    border-radius: 10px;
    transition: all .3s;
    border: 1px solid rgba(156, 156, 156, 0.466);
}

.BG {
    position: absolute;
    content: "";
    width: 80%;
    height: 100%;
    background: #181818;
    z-index: -1;
    border-radius: 10px;
    pointer-events: none;
    transition: all .3s;
}

.git-btn:hover .BG {
    transform: rotate(35deg);
    transform-origin: bottom;
}

.git-btn:hover .svgContainer {
    background-color: rgba(156, 156, 156, 0.466);
    backdrop-filter: blur(4px);
}

/* === Flip cards === */
.flip-card {
    background-color: transparent;
    max-width: 1200px;
    height: 554px;
    perspective: 1000px;
    font-family: sans-serif;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    padding: 2rem 5%;

}
  
.title {
    font-size: 1.5em;
    font-weight: 900;
    text-align: center;
    margin: 0;
}
  
.flip-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 1.2s;
    transform-style: preserve-3d;
    will-change: auto;
    
}
 
.flip-card-container:hover > .flip-card-inner {
    animation-play-state: running;
    transform: rotateY(180deg) ;
}
  
.flip-card-front, .flip-card-back {
    box-shadow: 0 8px 14px 0 rgba(0,0,0,0.2);
    position: absolute;
    display: flex;
    flex-direction: column;
    justify-content: center;
    width: 100%;
    height: 100%;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    border: 1px solid ;
    border-radius: 1rem;
}
  
.flip-card-front {
    background: linear-gradient(120deg, #2d2d2d 60%, #383838 88%,
       #404040 40%, rgba(45, 45, 45, 0.8) 48%);
    color: #e0e0e0;
}
  
.flip-card-back {
    background: linear-gradient(120deg, #2d2d2d 30%, #404040 88%,
       #383838 40%, #333333 78%);
    color: #e0e0e0;
    transform: rotateY(180deg);
}
/* === Contenedor Central === */
.portfolio-container {
    width: 90%;
    max-width: 1200px;
    margin: 20px auto; /* Centrado */
    background: #2d2d2d; /* Fondo oscuro como antes */
    border-radius: 16px; /* Bordes redondeados */
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3); /* Sombra suave */
    overflow: hidden; /* Asegura que los bordes redondeados se apliquen */
}

.background{
    background-image: url("fondo.png");
    background-repeat: no-repeat; 
    background-size: cover;
}

/* === Estilos Responsive del Navbar === */
.Navbar {
    width: 100%;
    height: 90px;
    padding: 10px;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 1000; /* Asegura que esté por encima de todo */
}

.Navbar ul {
    list-style-type: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 30px;
}

.Navbar li {
    margin-top: 13px;
}

.Navbar li a {
    color: white;
    text-decoration: none;
    font-size: 13px;
    padding: 12px 13px;
    border-radius: 15px;
    transition: all 0.3s ease;
    display: inline-block;
    position: relative;
}

/* Hamburger */
.hamburger {
    display: none;
    cursor: pointer;
    padding: 10px;
    position: absolute;
    right: 20px;
    top: 25px;
    z-index: 1001;
}

.hamburger .line {
    width: 25px;
    height: 2px;
    background-color: white;
    margin: 5px 0;
    transition: 0.3s;
}

/* Animaciones del hamburguesa */
.hamburger.active .line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.hamburger.active .line:nth-child(2) {
    opacity: 0;
}

.hamburger.active .line:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
}


.Navbar li a:hover {
    background-color: #111;
    transform: scale(1.05); /* Efecto de zoom suave */
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2); /* Profundidad al hover */
}

/* Línea decorativa bajo el texto al hacer hover */
.Navbar li a::after {
    content: '';
    position: absolute;
    bottom: 8px;
    left: 50%;
    width: 0;
    height: 2px;
    background: white;
    transition: all 0.3s ease;
}

.Navbar li a:hover::after {
    width: 60%;
    left: 20%;
}

/* Estilos específicos para el logo */
.logo-item a {
    display: flex !important; /* Forzar flexbox */
    align-items: center;
    gap: 8px;
    ;
    margin-top: -6px;
    font-size: 13px;
    pointer-events: none; /* Desactiva interacciones */
}

.logo-item svg {
    width: 28px;
    height: 28px;
    margin-bottom: -0.3px; /* Ajuste de alineación */
    fill: #5ddcff;
}


/* Estilos para pantallas pequeñas */
@media (max-width: 768px) {
    .logo-item span {
        display: none; /* Oculta el texto en móviles */
    }
    .logo-item svg {
        width: 24px;
        height: 24px;
    }
    .git-btn {
        width: 45px;
        height: 35px;
        bottom: 5px;
        left: 5px;
    }
}
/* === Sección Home === */
.home {
    padding: 30px 5%;
    text-align: left;
    
    background-size: cover; 
   
}

.home h1 {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    color: white;
    font-weight: 500;
    font-family: serif;
}

.home-content {
    max-width: 600px; /* Ajusta este valor según tus necesidades */
    padding: 0px; 
}

.home-content p {
    text-align: left; 
    line-height: 1.6; 
    font-size: 1rem; 
    color: white; 
}
/* === Sección Subclases=== */
.Subclases{
    padding: 30px 5%;
    font-size: 2.5rem;
    margin-bottom: -2.0rem;
    color: white;
    font-weight: 500;
    font-family: serif;
}

.Subclase-tecnica{
    padding: 30px 5%;
    font-size: 2.5rem;
    margin-bottom: -2.0rem;
    color: white;
    font-weight: 500;
    font-family: serif;
    text-align: center;
}

/* === Sistema de Cards === */
.cards-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    padding: 2rem 5%;
    max-width: 1200px;
    margin: 0 auto;
}

.card {
    background: #2d2d2d;
    border-radius: 12px;
    padding: 1.5rem;
    border: 1px solid #404040;
    transition: transform 0.2s ease;
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(120deg, #2d2d2d 30%, #404040 88%,
       #383838 40%, #333333 78%);
    color: #e0e0e0;
    z-index: -1;
    border-radius: 14px;
    opacity: 0.3;
}

.card:hover {
    transform: translateY(-5px);
}

.card-title {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: #C1C2BD;
}

.card-content {
    font-size: 1rem;
    line-height: 1.6;
    color: #e0e0e0;
}

/* === Skills === */


.skills-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
    margin-top: 1.5rem;
}

.skill-item {
    background: #404040;
    padding: 0.5rem 1.2rem;
    border-radius: 20px;
    font-size: 0.9rem;
    transition: all 0.3s;
}

.skill-item:hover {
    background: #5ddcff;
    color: #333;
}

/* === Infinite Scroll === */
.scroller {
    max-width: 600px;
    margin: 2rem auto;
    width: 90%;
}
  
.scroller__inner {
    padding-block: 1rem;
    display: flex;
    gap: 1rem;
}
  
.scroller[data-animated="true"] {
    overflow: hidden;
    -webkit-mask: linear-gradient(
    90deg,
    transparent,
    white 20%,
    white 80%,
    transparent
    );
    mask: linear-gradient(90deg, transparent, white 20%, white 80%, transparent);
}
  
.scroller[data-animated="true"] .scroller__inner {
    width: max-content;
    flex-wrap: nowrap;
    animation: scroll var(--_animation-duration, 40s) linear infinite;
}
  
.scroller[data-speed="fast"] {
    --_animation-duration: 20s;
}
  
@keyframes scroll {
    from {
        transform: translateX(0);
    }
    to {
        transform: translateX(calc(-50% - 0.5rem)); /* Ajuste preciso */
    }
}
  
.scroller[data-animated="true"] .scroller__inner {
    animation: scroll var(--_animation-duration, 40s) linear infinite;
    width: max-content;
    flex-wrap: nowrap;
}
  
/* Ajustes para tu tema existente */
.tag-list {
    margin: 0;
    padding: 0;
    list-style: none;
}
  
.tag-list li {
    color: white;
    padding: 0.7rem 1.5rem;
    background: #404040;
    border-radius: 25px;
    font-size: 0.9rem;
    white-space: nowrap;
    transition: all 0.3s ease;
}
  

/* === Responsive === */
@media (max-width: 768px) {
    .Navbar ul {
        gap: 20px;
    }

    .home h1 {
        font-size: 2.5rem;
        text-align: center;
    }

    .cards-container {
        grid-template-columns: 1fr;
        padding: 2rem 10%;
    }

    .logo-item span {
        display: none;
    }
}

@media (max-width: 480px) {
    .hamburger {
        display: block;
    }
    
    .Navbar ul {
        
        position: fixed;
        top: 70px;
        right: -100%;
        width: 100%;
        height: calc(100vh - 70px);
        background: #2d2d2d;
        flex-direction: column;
        gap: 0;
        transition: 0.3s;
        padding-top: 20px;
    }
    
    .Navbar ul.active {
        width: 60%;
        right: 0;
    }
    
    .Navbar li {
        padding-top: 10px;
        width: 70%;
        text-align: left;
        margin: 0;
    }
    
    .Navbar li a {
        width: 100%;
        padding: 20px;
        border-radius: 0;
    }
    
    .Navbar li a:hover::after {
        width: 0;
    }
    
    .Navbar li button.btn {
        width: 80%;
        margin: 10px auto;
        padding: 10px;
    }
    
    .logo-item {
        display: none;
    }

    .card {
        padding: 1.5rem;
        height: fit-content;
    }

    .git-btn {
        width: 35px;
        height: 25px;
        bottom: 5px;
        left: 1px;
        top: auto;
    }
    
}