/* Hex Header - Subpage header with hexagonal grid background */
.hex-header {
    position: relative;
    width: 100%;
    padding: 160px 0 140px;
    overflow: hidden;
    background: #0a0e1a;
}

.hex-header .hex-grid-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.hex-header .hex-fade-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, transparent 0%, transparent 10%, rgba(50, 50, 50, 0.3) 35%, rgba(50, 50, 50, 0.5) 60%, rgba(50, 50, 50, 0.9) 100%);
    pointer-events: none;
    z-index: 150;
}

.hex-header .hex-grid {
    position: relative;
    width: 100%;
    height: 100%;
}

.hex-header .hex-text-area {
    position: absolute;
    top: 0;
    right: 0;
    width: 45%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 40px 60px 0;
    z-index: 200;
    pointer-events: none;
}

.hex-header .hex-text-area h1 {
    color: #fff;
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 700;
    margin-bottom: 0.5rem;
    text-shadow: 0 0 10px rgba(180, 100, 255, 0.8), 0 0 20px rgba(180, 100, 255, 0.4), 0 2px 4px rgba(0, 0, 0, 0.5);
}

.hex-header .hex-text-area .hex-subtitle {
    color: rgba(255, 255, 255, 0.7);
    font-size: 1rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
}

.hex-header .hex-text-area p {
    color: #fff;
    font-size: 1.1rem;
    line-height: 1.7;
    opacity: 0.85;
    text-shadow: 0 0 8px rgba(180, 100, 255, 0.6), 0 0 16px rgba(180, 100, 255, 0.3), 0 1px 3px rgba(0, 0, 0, 0.5);
}

.hex-header .hex-cell {
    position: absolute;
    transition: transform 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                filter 0.35s ease;
    will-change: transform, filter;
}

.hex-header .hex-cell::before {
    content: '';
    position: absolute;
    top: -3px;
    left: -3px;
    right: -3px;
    bottom: -3px;
    background: var(--gap-color, rgba(255, 223, 0, 0.85));
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
    transition: background 0.3s ease;
}

.hex-header .hex-cell::after {
    content: none;
}

.hex-header .hex-cell-inner {
    position: relative;
    width: 100%;
    height: 100%;
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
    overflow: hidden;
    background: #1a1f2e;
}

.hex-header .hex-cell-inner img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.hex-header .hex-cell.active {
    transform: scale(1.15) translateY(-15px) !important;
    z-index: 100;
    filter: drop-shadow(0 0 20px rgba(180, 100, 255, 0.9)) drop-shadow(0 10px 30px rgba(0, 0, 0, 0.5));
}

.hex-header .hex-cell.active::before {
    background: #b464ff !important;
    box-shadow: 0 0 25px #b464ff, 0 0 50px rgba(180, 100, 255, 0.4);
}

.hex-header .hex-cell.neighbor-1 {
    transform: scale(1.05) translateY(-5px);
    z-index: 50;
    filter: drop-shadow(0 0 10px rgba(0, 212, 255, 0.4));
}

.hex-header .hex-cell.neighbor-1::before {
    background: rgba(0, 212, 255, 0.7) !important;
}

.hex-header .hex-cell.neighbor-2 {
    transform: scale(1.02);
    z-index: 40;
    filter: brightness(1.1);
}

.hex-header .hex-cell.neighbor-2::before {
    background: rgba(0, 212, 255, 0.45) !important;
}

@media (max-width: 768px) {
    .hex-header {
        padding: 120px 0 80px;
    }
    .hex-header .hex-text-area {
        width: 100%;
        padding: 0 20px;
        text-align: center;
        align-items: center;
    }
    .hex-header .hex-text-area h1 {
        font-size: 2.5rem;
    }
    .hex-header .hex-text-area p {
        font-size: 1.1rem;
    }
}
