/*
 * APServer Website Switcher - centered overlay (desktop-first) matching provided mock.
 * Keep styling isolated via the apserver-ws-* namespace.
 */

.apserver-ws-overlay {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(0, 0, 0, 0.25);
    -webkit-backdrop-filter: blur(2px);
    backdrop-filter: blur(2px);
}

.apserver-ws-overlay.is-open {
    display: flex;
}

.apserver-ws-modal {
    position: relative;
    width: min(760px, 92vw);
    background: #ffffff;
    border-radius: 10px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
}

.apserver-ws-content {
    padding: 48px 56px 44px;
    text-align: center;
}

.apserver-ws-close {
    position: absolute;
    top: 5px;
    right: -22px;
    width: 44px;
    height: 44px !important;
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    outline: none !important;
    color: #111;
    font-size: 34px;
    line-height: 2px !important;
    cursor: pointer;
}
.apserver-ws-close:hover {
    background: transparent;
    color: #111;
}
/* Hide the native select: we keep it only for data+logic */
.apserver-ws-select {
    display: none;
}

/* Fake select (graphical options) */
.apserver-ws-fakeselect {
    width: min(600px, 86vw);
    position: relative;
}

.apserver-ws-fakeselect-toggle {
    width: 100%;
    height: 64px;
    font-size: 20px;
    padding: 0 18px;
    border: 2px solid #e7efe8;
    border-radius: 8px;
    background: #f7fbf7;
    color: #111;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.apserver-ws-fakeselect-toggle:focus {
    border-color: #b7d4c0;
    box-shadow: 0 0 0 3px rgba(94, 160, 122, 0.15);
    outline: none;
}

.apserver-ws-fakeselect-caret {
    opacity: 0.6;
    font-size: 18px;
}

.apserver-ws-fakeselect-list {
    position: absolute;
    left: 0;
    right: 0;
    top: calc(100% + 8px);
    background: #fff;
    border: 1px solid #e7efe8;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.14);
    max-height: 360px;
    overflow: auto;
    padding: 10px;
    display: none;
    z-index: 1;
}

.apserver-ws-fakeselect.is-open .apserver-ws-fakeselect-list {
    display: block;
    top:-80px;
}

.apserver-ws-fakeselect-option {
    width: 100%;
    text-align: left;
    border: 0;
    background: #fff;
    padding: 14px 14px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 18px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.apserver-ws-fakeselect-option:hover,
.apserver-ws-fakeselect-option.is-selected {
    background: #000000;
}

.apserver-ws-fakeselect-option:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(94, 160, 122, 0.15);
}

.apserver-ws-title {
    font-weight: 700;
    letter-spacing: 2px;
    color: #896455;
    font-size: clamp(42px, 5vw, 76px);
    margin: 0 0 12px;
}

.apserver-ws-subtitle {
    font-size: 20px;
    line-height: 1.35;
    color: #2b2b2b;
    margin: 0 auto 28px;
    max-width: 720px;
}

.apserver-ws-field {
    display: flex;
    justify-content: center;
    margin: 0 0 22px;
}



.apserver-ws-actions {
    margin-top: 12px;
}

.apserver-ws-submit {
    border: 0;
    background: #896455 !important;
    color: #fff !important;
    font-weight: 700;
    font-size: 18px;
    height: 54px !important;
    min-width: 170px;
    border-radius: 10px;
    cursor: pointer;
    letter-spacing: 0.5px;
}

.apserver-ws-submit:hover {
    background: #60473E !important;
}

.apserver-ws-submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

@media (max-width: 640px) {
    .apserver-ws-content {
        padding: 32px 18px 28px;
    }
    .apserver-ws-subtitle {
        font-size: 16px;
    }
    .apserver-ws-fakeselect-toggle {
        height: 56px;
        font-size: 18px;
    }
}
@media (min-width: 640px) {
    .page-header .switcher .options ul.dropdown, .page-footer .switcher .options ul.dropdown {
        min-width: 0 !important;
    }
    .switcher-language span { display:none; }
}