#header{
    background: linear-gradient(135deg, #0147ff 0, 30%, #7de8f7 75%);
    position: sticky;
    top: 0;
    z-index: 1;

    box-shadow: 0 2px 0px rgba(0, 0, 0, 0.1);
}

.header-top{
    grid-column-start: 1;
    grid-column-end: 4;
    grid-row: 1;
    display: grid;
    grid-template-columns: 1.0fr auto 0.7fr;

    align-items: center;

    max-width: 1200px;
    margin: 0 auto;

    height: 75px;
}

.header-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: auto;
    min-height: 100%;
    background: url('/resources/header02.png') no-repeat center / cover;

    z-index: 0;
}

.header-bg::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, #0147ffc4 0, 30%, #7de8f7f2 75%);
}

.logo-with-effects-responsive-content {
    grid-column: 1;
    align-content: center;
}

.logo-with-effects {
    display: flex;
    align-items: center;
    overflow: hidden;
    grid-column: 1;
    border-radius: 2px;
}

.logo-canvas-container {
    position: relative;
    width: 100%;
    height: 60px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

canvas#waves {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.logo-svg-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
    display: flex;
    align-items: center;
    contain: layout style;
}

.img-logo{
    width: 350px;
}

.logo-text {
    font-family: 'Orbitron Black', 'Orbitron', 'Arial Black', sans-serif;
    font-size: 60px;
    font-weight: 900;
}

.logo-letter-a {
    font-size: 70px;
}

.logo-rest {
    font-size: 50px;
}

.img-logo {
    width: 100%;
    height: auto;
}

.header-menu {
    text-align: center;
    width: auto;
    padding: 8px 12px;
    background-color: rgba(255, 255, 255, 0.15);
    border-radius: 12px;
    backdrop-filter: blur(5px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    margin: 4px;
    z-index: 4;
    grid-column: 2;
    display: flex;
    justify-content: space-between;
    border: none;

    height: 55%;
}

.header-menu .menu {
    color: white;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    padding: 6px 12px;
    margin: 0 3px;
    border-radius: 8px;
    transition: all 0.3s ease;
    position: relative;
    letter-spacing: 0.5px;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
    cursor: pointer;

    display: flex;
    align-items: center;
    gap: 2px;
}

.header-menu .menu:hover {
    background-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.header-menu .menu::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, #8100ff, #00c0ff);
    transition: width 0.3s ease, left 0.3s ease;
    transform: translateX(-50%);
}

.header-menu .menu:hover::after {
    width: 80%;
}

.search-container {
    grid-column: 3;
    display: flex;
    justify-content: flex-end;
    align-items: center;
}

.search-player-bar {
    display: flex;
    align-items: center;
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    padding: 10px 16px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    max-width: 180px;
    backdrop-filter: blur(5px);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.search-player-bar:hover, .search-player-bar:focus-within {
    background-color: rgba(255, 255, 255, 0.3);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.search-player-textbox {
    background: transparent;
    border: none;
    padding: 8px 4px;
    font-size: 14px;
    color: white;
    width: 100%;
    outline: none;
    font-family: 'Montserrat', sans-serif;
}

.search-player-textbox::placeholder {
    color: rgba(255, 255, 255, 0.7);
    font-style: italic;
}

.search-player-button {
    display: flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    cursor: pointer;
    padding: 6px;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.search-player-button:hover {
    background-color: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
}

.img-icon-search {
    width: 16px;
    height: 16px;
    filter: brightness(0) invert(1);
}


@keyframes pulse {
    0% { opacity: 1; }
    50% { opacity: 0.6; }
    100% { opacity: 1; }
}

.search-player-button[title="Coming soon"] {
    animation: pulse 2s infinite;
    position: relative;
}

.search-player-button[title="Coming soon"]:hover::after {
    opacity: 1;
}


.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 999;
    display: none;
}

.overlay.active {
    display: block;
}

.popup {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    border-radius: 5px;
    padding: 20px;
    z-index: 1000;
    display: none;

    background-image: linear-gradient(rgb(81, 94, 255) 0%, rgb(0, 192, 255) 100%);
    color: white;
    border: none;
}

.popup.hidden {
    display: none;
}

.popup-content {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-right: 20px;
}

.about-popup-title {
    padding: 0px;
    margin: 0px;
    font-weight: bold;
}

.about-popup-info {
    margin: 0px;
}

.close-popup-button {
    background-color: transparent;
    user-select: none;
    border: none;
    cursor: pointer;
    position: absolute;
    top: 8px;
    right: 4px;
}

.close-popup-button:hover {
    background-color: transparent !important;
    transition: transform 0.7s ease;
    transform: rotate(360deg);
}

.close-popup-button-image {
    width: 1.6rem;
    height: 1.6rem;
    display: inline-block; 
    vertical-align: middle; 
}

@media only screen and (orientation: portrait), (max-aspect-ratio: 4/3) {

    .header-bg {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: auto;
        min-height: 100%;
        background: url('/resources/header02.png') no-repeat center / cover;

        z-index: 0;
    }

    #header {
        display: flex;
    }

    .header-top {
        display: flex;
        justify-content: space-between;
        align-items: center;
        grid-template-columns: none;

        max-width: initial;
        margin: initial;

        width: 100%;

        flex-direction: row;
        gap: 5px;
    }

    .logo-with-effects-responsive-content {
        grid-column: none;
        flex: 1;
        display: flex;
        justify-content: flex-start;
        align-items: center;
    }

    .logo-with-effects {
        width: 100%;
        display: flex;
        align-items: center;
        overflow: hidden;
        border-radius: 2px;
    }

    .logo-canvas-container {
        height: 70px;
        position: relative;
        overflow: hidden;
        display: flex;
        align-items: center;
        justify-content: center;
        width: 100%;
    }

    .img-logo {
        width: 200px;
    }

    .logo-letter-a {
        font-size: 80px;
    }

    .logo-rest {
        font-size: 60px;
    }
    
    #waves {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        z-index: 1;
    }
    
    .mobile-menu-button {
        display: flex;
        flex-direction: column;
        justify-content: center;
        width: 43px;
        height: 43px;
        background: rgba(255, 255, 255, 0.2);
        border-radius: 5px;
        cursor: pointer;
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        padding: 10px;
        flex-shrink: 0;
        z-index: 1;
    }
    
    .mobile-menu-button:hover {
        background: rgba(255, 255, 255, 0.3);
        transform: scale(1.05);
    }
    
    .mobile-side-panel {
        position: fixed;
        top: 0;
        right: -60%;
        width: 60%;
        height: 100vh;
        background: linear-gradient(135deg, rgba(77, 119, 255, 0.95) 0%, rgba(0, 200, 255, 0.95) 100%);
        backdrop-filter: blur(20px);
        border-left: 1px solid #00c8ff;
        z-index: 3;
        transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    }
    
    .mobile-side-panel.active {
        right: 0;
    }
    
    .side-panel-header {
        display: flex;
        justify-content: flex-end;
        padding: 20px;
        border-bottom: 2px solid rgba(255, 255, 255, 0.2);
    }
    
    .close-panel-button {
        width: 40px;
        height: 40px;
        background: rgba(255, 255, 255, 0.2);
        border: 2px solid #00c8ff;
        border-radius: 50%;
        color: white;
        font-size: 20px;
        font-weight: bold;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: all 0.3s ease;
    }
    
    .close-panel-button:hover {
        background: rgba(255, 255, 255, 0.3);
        transform: scale(1.1);
    }
    
    .side-panel-menu {
        color: white;

        display: flex;
        flex-direction: column;
        height: calc(100vh - 80px);
        overflow-y: auto;
        overflow-x: hidden;
    }
    
    .side-panel-menu-item {
        display: flex;
        align-items: center;
        padding: 15px 25px;
        color: white;
        text-decoration: none;
        font-size: 16px;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        transition: all 0.3s ease;
        cursor: pointer;
        font-weight: bold;
        flex-shrink: 0;
    }
    
    .side-panel-menu-item:hover {
        background: rgba(255, 255, 255, 0.1);
        padding-left: 35px;
    }
    
    .side-panel-menu-item img {
        width: 24px;
        height: 24px;
        margin-right: 15px;
        filter: brightness(0) invert(1);
    }

    .side-panel-menu-item.about-item {

        border-top: none;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }
    
    .search-dropdown {
        max-height: 0;
        overflow: hidden;
        background: rgba(255, 255, 255, 0.1);
        margin: 0 25px;
        border-radius: 10px;
        transition: all 0.3s ease;
    }
    
    .search-dropdown.active {
        max-height: 80px;
        margin-top: 10px;
    }
    
    .mobile-search-form {
        display: flex;
        gap: 10px;
        align-items: center;
        width: 100%;
    }
    
    .mobile-search-input {
        flex: 1;
        padding: 10px 8px;
        border: none;
        border-radius: 8px;
        background: rgba(255, 255, 255, 0.9);
        font-size: 14px;
        min-width: 0;
    }

    .mobile-search-input:disabled {
        background: rgba(255, 255, 255, 0.5);
        color: #666;
    }
    
    .mobile-search-button {
        padding: 8px 12px;
        background: linear-gradient(135deg, #4d77ff, #00c8ff);
        border: none;
        border-radius: 8px;
        color: white;
        font-weight: bold;
        cursor: pointer;
        transition: transform 0.2s ease;
        white-space: nowrap;
        flex-shrink: 0;
        min-width: 45px;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .mobile-search-button img {
        width: 20px;
        height: 20px;
    }
    
    .mobile-search-button:hover {
        transform: scale(1.05);
    }


}

@media only screen and (max-width: 1024px) and (orientation: landscape) {

    .header-bg {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: auto;
        min-height: 100%;
        background: url('/resources/header02.png') no-repeat center / cover;

        z-index: 0;
    }

    #header {
        display: flex;
    }

    .header-top {
        display: flex;
        justify-content: space-between;
        align-items: center;
        grid-template-columns: none;

        max-width: initial;
        margin: initial;

        width: 100%;

        flex-direction: row;
        gap: 5px;
    }

    .logo-with-effects-responsive-content {
        grid-column: none;
        flex: 1;
        display: flex;
        justify-content: flex-start;
        align-items: center;
    }

    .logo-with-effects {
        width: 100%;
        display: flex;
        align-items: center;
        overflow: hidden;
        border-radius: 2px;
    }

    .logo-canvas-container {
        height: 70px;
        position: relative;
        overflow: hidden;
        display: flex;
        align-items: center;
        justify-content: center;
        width: 100%;
    }

    .img-logo {
        width: 200px;
    }

    .logo-letter-a {
        font-size: 80px;
    }

    .logo-rest {
        font-size: 60px;
    }
    
    #waves {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        z-index: 1;
    }
    
    .mobile-menu-button {
        display: flex;
        flex-direction: column;
        justify-content: center;
        width: 43px;
        height: 43px;
        background: rgba(255, 255, 255, 0.2);
        border-radius: 5px;
        cursor: pointer;
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        padding: 10px;
        flex-shrink: 0;
        z-index: 1;
    }
    
    .mobile-menu-button:hover {
        background: rgba(255, 255, 255, 0.3);
        transform: scale(1.05);
    }
    
    .mobile-side-panel {
        position: fixed;
        top: 0;
        right: -60%;
        height: 100vh;
        background: linear-gradient(135deg, rgba(77, 119, 255, 0.95) 0%, rgba(0, 200, 255, 0.95) 100%);
        backdrop-filter: blur(20px);
        border-left: 1px solid #00c8ff;
        z-index: 3;
        transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    }
    
    .mobile-side-panel.active {
        right: 0;
    }
    
    .side-panel-header {
        display: flex;
        justify-content: flex-end;
        padding: 20px;
        border-bottom: 2px solid rgba(255, 255, 255, 0.2);
    }
    
    .close-panel-button {
        width: 40px;
        height: 40px;
        background: rgba(255, 255, 255, 0.2);
        border: 2px solid #00c8ff;
        border-radius: 50%;
        color: white;
        font-size: 20px;
        font-weight: bold;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: all 0.3s ease;
    }
    
    .close-panel-button:hover {
        background: rgba(255, 255, 255, 0.3);
        transform: scale(1.1);
    }
    
    .side-panel-menu {
        color: white;

        display: flex;
        flex-direction: column;
        height: calc(100vh - 80px);
        overflow-y: auto;
        overflow-x: hidden;
    }
    
    .side-panel-menu-item {
        display: flex;
        align-items: center;
        padding: 15px 25px;
        color: white;
        text-decoration: none;
        font-size: 16px;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        transition: all 0.3s ease;
        cursor: pointer;
        font-weight: bold;
        flex-shrink: 0;
    }
    
    .side-panel-menu-item:hover {
        background: rgba(255, 255, 255, 0.1);
        padding-left: 35px;
    }
    
    .side-panel-menu-item img {
        width: 24px;
        height: 24px;
        margin-right: 15px;
        filter: brightness(0) invert(1);
    }

    .side-panel-menu-item.about-item {
        border-top: none;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }
    
    .search-dropdown {
        max-height: 0;
        overflow: hidden;
        background: rgba(255, 255, 255, 0.1);
        margin: 0 25px;
        border-radius: 10px;
        transition: all 0.3s ease;
    }
    
    .search-dropdown.active {
        max-height: 80px;
        margin-top: 10px;
        overflow: visible;
    }
    
    .mobile-search-form {
        display: flex;
        gap: 10px;
        align-items: center;
        width: 100%;
    }
    
    .mobile-search-input {
        flex: 1;
        padding: 10px 8px;
        border: none;
        border-radius: 8px;
        background: rgba(255, 255, 255, 0.9);
        font-size: 14px;
        min-width: 0;
    }

    .mobile-search-input:disabled {
        background: rgba(255, 255, 255, 0.5);
        color: #666;
    }
    
    .mobile-search-button {
        padding: 8px 12px;
        background: linear-gradient(135deg, #4d77ff, #00c8ff);
        border: none;
        border-radius: 8px;
        color: white;
        font-weight: bold;
        cursor: pointer;
        transition: transform 0.2s ease;
        white-space: nowrap;
        flex-shrink: 0;
        min-width: 45px;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .mobile-search-button img {
        width: 20px;
        height: 20px;
    }
    
    .mobile-search-button:hover {
        transform: scale(1.05);
    }

}