/* assets/css/portfolio-hub.css */
.ht-hub-wrapper {
    position: relative;
    width: 100%;
    min-height: 85vh;
    padding: 140px 20px 100px;
    background-color: #050505;
    color: #fff;
    overflow: hidden;
    font-family: 'Inter', sans-serif;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

/* Efecto de luz ambiental en el fondo */
.ht-hub-ambient-glow {
    position: absolute;
    top: -20%;
    left: 50%;
    transform: translateX(-50%);
    width: 60%;
    height: 60%;
    background: radial-gradient(circle, rgba(26, 188, 254, 0.15) 0%, rgba(162, 89, 255, 0.05) 40%, transparent 70%);
    filter: blur(100px);
    pointer-events: none;
    z-index: 0;
}

#ht-hub-particles-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
    opacity: 0.5;
}

.ht-hub-header {
    position: relative;
    z-index: 2;
    text-align: center;
    margin-bottom: 80px;
    max-width: 800px;
    opacity: 0; /* Para GSAP */
    visibility: hidden;
}

.ht-hub-title {
    font-size: clamp(3rem, 6vw, 5rem);
    font-weight: 800;
    margin-bottom: 20px;
    letter-spacing: -0.04em;
    color: #fff;
    line-height: 1.1;
}

.ht-hub-desc {
    font-size: clamp(1.1rem, 1.5vw, 1.3rem);
    color: #a0a0a0;
    line-height: 1.6;
    max-width: 600px;
    margin: 0 auto;
}

.ht-hub-grid {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
    gap: 30px;
    width: 100%;
    max-width: 1200px;
}

.ht-hub-card {
    position: relative;
    display: flex;
    flex-direction: column;
    text-decoration: none;
    border-radius: 24px;
    background: rgba(15, 15, 15, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.04);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    overflow: hidden;
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.5s ease;
    padding: 1px; /* Para el border dinámico */
    opacity: 0; /* Para GSAP */
    visibility: hidden;
}

.ht-hub-card:hover {
    transform: translateY(-12px) scale(1.02);
    box-shadow: 0 30px 60px -15px rgba(0, 0, 0, 0.8), 0 0 40px -10px rgba(26, 188, 254, 0.1);
}

.ht-hub-card-inner {
    background: linear-gradient(180deg, rgba(20, 20, 20, 0.9) 0%, rgba(10, 10, 10, 0.95) 100%);
    border-radius: 23px;
    padding: 50px 40px;
    height: 100%;
    display: flex;
    flex-direction: column;
    position: relative;
    z-index: 2;
}

.ht-hub-icon-wrapper {
    width: 70px;
    height: 70px;
    border-radius: 20px;
    background: linear-gradient(135deg, rgba(255,255,255,0.05) 0%, rgba(255,255,255,0.01) 100%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 35px;
    color: #fff;
    transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    overflow: hidden;
}

.ht-hub-icon-wrapper::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--ht-celeste);
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: 0;
}

.ht-hub-icon-wrapper svg {
    position: relative;
    z-index: 1;
    width: 32px;
    height: 32px;
    transition: transform 0.4s ease;
}

.ht-hub-card:hover .ht-hub-icon-wrapper {
    border-color: transparent;
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 10px 20px rgba(26, 188, 254, 0.2);
}

.ht-hub-card:hover .ht-hub-icon-wrapper::before {
    opacity: 1;
}

.ht-hub-card:hover .ht-hub-icon-wrapper svg {
    color: #000;
}

.ht-hub-card-title {
    font-size: 1.6rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 18px;
    letter-spacing: -0.02em;
}

.ht-hub-card-desc {
    font-size: 1rem;
    color: #888;
    line-height: 1.6;
    margin-bottom: 40px;
    font-weight: 400;
}

.ht-hub-spacer {
    flex-grow: 1;
}

.ht-hub-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: auto;
    padding-top: 25px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    position: relative;
}

.ht-hub-btn-text {
    font-size: 0.95rem;
    font-weight: 600;
    color: #999;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    transition: color 0.3s ease;
}

.ht-hub-arrow-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.ht-hub-card:hover .ht-hub-btn-text {
    color: #fff;
}

.ht-hub-card:hover .ht-hub-arrow-icon {
    background: #fff;
    color: #000;
    transform: translateX(8px);
}

/* Glow Border Effect (Awwwards Style) */
.ht-hub-card-bg-glow {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at var(--mouse-x, 50%) var(--mouse-y, 50%), rgba(26, 188, 254, 0.6) 0%, rgba(162, 89, 255, 0.3) 20%, transparent 60%);
    opacity: 0;
    z-index: 1;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.ht-hub-card:hover .ht-hub-card-bg-glow {
    opacity: 1;
}

@media (max-width: 768px) {
    .ht-hub-wrapper {
        padding: 120px 20px 80px;
    }
    
    .ht-hub-card-inner {
        padding: 40px 25px;
    }
    
    .ht-hub-title {
        font-size: 2.5rem;
    }
}
