/* Auth form, member dashboard, favorites and last-played pages. */

.auth-page-shell{
    margin-top: 24px;
}

.auth-page-card{
    background: transparent;
border: 0;
}

.auth-page-top-shell{
    padding: 0;
}

.auth-panel-card{
    padding: 0;
    border: 0;
background: transparent;
}

.auth-card-head{
    margin-bottom: 20px;
    min-width: 0;
}

.auth-card-head h2{
    margin: 0 0 8px;
    color: #5c2f75 !important;
    font-size: 28px;
    line-height: 1.18;
}

.auth-card-head p,
.auth-form-footnote{
    margin: 0;
    color: #56485f;
    font-size: 14px;
    line-height: 1.7;
}

.auth-inline-badge{
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    padding: 0 14px;
    border-radius: 999px;
    background: rgba(108, 51, 145, 0.10);
    border: 1px solid rgba(108, 51, 145, 0.12);
    color: #6c3391;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    margin-bottom: 12px;
    width: fit-content;
    max-width: 100%;
    align-self: flex-start;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.auth-form-footnote{
    margin-top: 14px;
}

.auth-form-footnote a{
    color: #6c3391;
    font-weight: 700;
    text-decoration: none;
}

.auth-form-footnote a:hover{
    color: #4b2364;
}

.auth-form{
    display: grid;
    gap: 14px;
}

.auth-field{
    display: grid;
    gap: 8px;
}

.auth-field span,
.auth-check span{
    color: #5b4766;
    font-weight: 700;
    font-size: 14px;
}

.auth-field input{
    width: 100%;
    min-height: 54px;
    padding: 0 16px;
    border-radius: 16px;
    border: 1px solid rgba(116, 63, 149, 0.18);
    background: #fcfbff;
    color: #2f2337;
    font-size: 15px;
    outline: none;
    transition: border-color 0.2s ease, background 0.2s ease;
}

.auth-field input:focus{
    border-color: rgba(108, 51, 145, 0.48);
    background: #ffffff;
}

.auth-field-row{
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.auth-check{
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-top: 2px;
}

.auth-check input{
    width: 18px;
    height: 18px;
    accent-color: #6c3391;
}

.auth-submit-button{
    min-height: 54px;
    border: 0;
    border-radius: 16px;
    background: linear-gradient(180deg, #6c3391, #4f226c);
    color: #ffffff;
    font-size: 15px;
    font-weight: 800;
    cursor: pointer;
transition: transform 0.2s ease, filter 0.2s ease;
}

.auth-submit-button:hover{
    transform: translateY(-1px);
filter: brightness(1.03);
}

.auth-alert{
    margin-bottom: 16px;
    padding: 14px 16px;
    border-radius: 16px;
    font-size: 14px;
    font-weight: 700;
}

.auth-alert-error{
    background: rgba(220, 85, 85, 0.10);
    border: 1px solid rgba(220, 85, 85, 0.14);
    color: #9b2f2f;
}

.auth-alert-success{
    background: rgba(77, 177, 98, 0.12);
    border: 1px solid rgba(77, 177, 98, 0.16);
    color: #2b6b3b;
}

@media (max-width: 767px) {
    .auth-page-shell{
        margin-top: 18px;
    }

    .auth-card-head p,
.auth-form-footnote{
        font-size: 14px;
    }

    .auth-card-head h2{
        font-size: 24px;
    }

    .auth-field-row{
        grid-template-columns: 1fr;
        flex-direction: column;
        align-items: flex-start;
    }

    .auth-switcher{
        max-width: none;
    }
}

.auth-page-top-shell--member{
    padding: 26px;
}

.auth-page-layout--guest{
    max-width: 760px;
    margin: 0 auto;
}

.auth-page-layout--guest-solo{
    max-width: 620px;
}

.auth-page-panel--guest-solo{
    padding: 28px;
}

.auth-page-panel--guest-solo .auth-switcher{
    max-width: none;
    margin-bottom: 22px;
}

.auth-page-layout--member{
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    gap: 22px;
}

.auth-page-panel--guest,
.member-sidebar-card,
.member-content-card{
    background: rgba(255,255,255,0.92);
    border: 1px solid rgba(120, 42, 160, 0.10);
    border-radius: 24px;
}

.auth-page-panel--guest,
.member-content-card{
    padding: 24px;
}

.member-sidebar-card{
    padding: 18px;
    align-self: start;
    position: sticky;
    top: 24px;
}

.member-sidebar-meta h1,
.member-content-head h2{
    color: var(--text-dark);
}

.auth-alert-info{
    background: rgba(123, 31, 162, 0.08);
    border: 1px solid rgba(123, 31, 162, 0.14);
    color: #5a2874;
}

.member-sidebar-profile{
    display: flex;
    align-items: center;
    gap: 14px;
    padding-bottom: 16px;
    margin-bottom: 16px;
    border-bottom: 1px solid rgba(120, 42, 160, 0.10);
}

.member-sidebar-avatar img,
.member-sidebar-avatar .avatar{
    width: 96px;
    height: 96px;
    border-radius: 50%;
    border: 2px solid rgba(123, 31, 162, 0.14);
    object-fit: cover;
}

.member-sidebar-meta{
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.member-sidebar-meta p{
    margin: 0;
    color: rgba(58, 36, 76, 0.72);
}

.member-sidebar-stats{
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-bottom: 18px;
}

.member-stat-card{
    min-height: 76px;
    padding: 12px 10px;
    border-radius: 16px;
    background: linear-gradient(180deg, rgba(255,255,255,0.98), rgba(244,236,251,0.88));
    border: 1px solid rgba(120, 42, 160, 0.10);
    text-align: center;
}

.member-stat-card strong{
    display: block;
    color: #5a2874;
    font-size: 22px;
    line-height: 1;
    margin-bottom: 6px;
}

.member-stat-card span{
    color: rgba(58, 36, 76, 0.78);
    font-size: 12px;
    font-weight: 700;
}

.member-sidebar-nav{
    display: grid;
    gap: 9px;
}

.member-sidebar-link{
    display: flex;
    align-items: center;
    min-height: 48px;
    padding: 0 14px;
    border-radius: 14px;
    text-decoration: none;
    color: var(--text-dark);
    background: #fff;
    border: 1px solid rgba(120, 42, 160, 0.10);
    font-weight: 700;
    transition: transform 0.18s ease, border-color 0.18s ease;
}

.member-sidebar-link:hover,
.member-sidebar-link.is-active{
    transform: translateY(-1px);
    border-color: rgba(236, 181, 0, 0.34);
}

.member-content-head{
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 18px;
}

.member-content-head p,
.member-empty-state p{
    color: rgba(0, 0, 0, 0.88);
}

.member-dashboard-grid{
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.member-dashboard-card{
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-height: 145px;
    padding: 18px;
    text-decoration: none;
    border-radius: 18px;
    background: linear-gradient(180deg, rgba(255,255,255,0.98), rgba(245,239,251,0.90));
    border: 1px solid rgba(120, 42, 160, 0.10);
    color: var(--text-dark);
    transition: transform 0.18s ease, border-color 0.18s ease;
}

.member-dashboard-card:hover{
    transform: translateY(-2px);
    border-color: rgba(236, 181, 0, 0.34);
}

.member-dashboard-card strong{
    font-size: 18px;
}

.member-dashboard-card span{
    color: rgba(58, 36, 76, 0.74);
    line-height: 1.55;
}

.member-empty-state{
    padding: 28px;
    border-radius: 20px;
    border: 1px dashed rgba(120, 42, 160, 0.20);
    background: linear-gradient(180deg, rgba(255,255,255,0.95), rgba(246,239,252,0.82));
}

.member-empty-state h3{
    margin: 0 0 8px;
    color: #5a2874;
}

.member-empty-state p{
    margin: 0;
    color: rgba(58, 36, 76, 0.76);
}

.member-games-grid{
    margin-bottom: 16px;
}

.member-pagination .page-numbers{
    min-width: 42px;
}

.avatar-manager-card{
    display: grid;
    grid-template-columns: 160px minmax(0, 1fr);
    gap: 22px;
    align-items: start;
}

.avatar-manager-preview{
    display: flex;
    justify-content: center;
    align-self: start;
    margin-top: 190px;
}

.avatar-manager-preview img,
.avatar-manager-preview .avatar{
    width: 140px;
    height: 140px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid rgba(123, 31, 162, 0.16);
}

.avatar-manager-actions{
    display: grid;
    gap: 18px;
    align-content: start;
}

.avatar-manager-actions > .auth-form{
    margin: 0;
}

.auth-form-compact{
    gap: 12px;
}

.auth-form-remove-avatar{
    margin: 0;
}

.auth-page-panel--guest .auth-field input,
.auth-page-panel--guest .auth-check,
.avatar-manager-card .auth-field input[type="file"],
.avatar-manager-card .auth-field input[type="text"],
.avatar-manager-card .auth-field input[type="email"],
.avatar-manager-card .auth-field input[type="password"]{
    border-radius: 16px;
}

@media (max-width: 991px) {
    .auth-page-layout--member{
        grid-template-columns: 1fr;
    }

    .member-sidebar-card{
        position: static;
    }

    .member-dashboard-grid{
        grid-template-columns: 1fr;
    }

    .avatar-manager-card{
        grid-template-columns: 1fr;
    }

    .avatar-manager-preview{
        justify-self: center;
        margin-top: 0;
    }

}

@media (max-width: 767px) {
    .member-sidebar-stats{
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .auth-page-panel--guest,
.member-content-card,
.member-sidebar-card{
        padding: 18px;
    }
}

.auth-switcher{
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    width: 100%;
    max-width: 360px;
    margin-bottom: 18px;
    padding: 0;
    background: transparent;
    border: 0;
    border-radius: 18px;
}

.auth-switcher-link,
.auth-submit-button,
.auth-submit-button-secondary,
.auth-link-button,
.auth-form-remove-avatar .auth-submit-button,
.auth-form-remove-avatar .auth-submit-button-secondary,
.member-empty-actions .game-comment-submit,
.member-empty-actions .game-comment-submit.game-comment-submit-secondary{
    min-height: 46px;
    border: 2px solid var(--mustard-line);
    border-radius: 14px;
    background: linear-gradient(180deg, var(--purple-1) 0%, var(--purple-2) 100%);
    color: #fff4c7;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 22px;
    font: inherit;
    font-size: 16px;
    font-weight: 800;
    text-decoration: none;
    cursor: pointer;
    transition: 0.2s ease;
}

.auth-switcher-link:hover,
.auth-switcher-link:focus-visible,
.auth-submit-button:hover,
.auth-submit-button:focus-visible,
.auth-submit-button-secondary:hover,
.auth-submit-button-secondary:focus-visible,
.auth-link-button:hover,
.auth-link-button:focus-visible,
.auth-form-remove-avatar .auth-submit-button:hover,
.auth-form-remove-avatar .auth-submit-button:focus-visible,
.auth-form-remove-avatar .auth-submit-button-secondary:hover,
.auth-form-remove-avatar .auth-submit-button-secondary:focus-visible,
.member-empty-actions .game-comment-submit:hover,
.member-empty-actions .game-comment-submit:focus-visible,
.member-empty-actions .game-comment-submit.game-comment-submit-secondary:hover,
.member-empty-actions .game-comment-submit.game-comment-submit-secondary:focus-visible{
    transform: translateY(-1px);
    border-color: #ffd15a;
    background: linear-gradient(180deg, #9f32c7 0%, #74208e 100%);
    color: #fff4c7;
}

.auth-switcher-link:active,
.auth-submit-button:active,
.auth-submit-button-secondary:active,
.auth-link-button:active,
.member-empty-actions .game-comment-submit:active,
.member-empty-actions .game-comment-submit.game-comment-submit-secondary:active{
    transform: translateY(0);
}

.auth-switcher-link{
    min-width: 0;
}

.auth-switcher-link.is-active{
    color: #fff4c7;
    background: linear-gradient(180deg, var(--purple-1) 0%, var(--purple-2) 100%);
    border-color: var(--mustard-line);
}

.auth-switcher-link:not(.is-active){
    background: #ffffff;
    color: #5a2874;
}

.auth-switcher-link:not(.is-active):hover,
.auth-switcher-link:not(.is-active):focus-visible{
    color: #fff4c7;
}

.auth-submit-button,
.auth-submit-button-secondary,
.auth-link-button,
.auth-form-remove-avatar .auth-submit-button,
.auth-form-remove-avatar .auth-submit-button-secondary{
    width: 100%;
}

.member-archive-section > .section-head p,
.member-archive-page .section-head-member p{
    color: rgba(255, 255, 255, 0.88);
}

.auth-form-footnote--center{
    text-align: center;
}

/* Member text overflow rules. */

.member-sidebar-display-name{
    display: block;
}

.member-sidebar-meta p.member-sidebar-username{
    display: block;
    overflow: visible;
    text-overflow: clip;
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: break-word;
}
