html, body {
    min-height: 100%;
    margin: 0;
}

body {
    background: linear-gradient(to bottom left, #000000, #121212);
    color: #ffffff;
    font-family: "Open Sans", sans-serif;
}

body.auth-page {
    height: 100vh;
    overflow: hidden;
}

.page {
    min-height: 100vh;
    padding-top: 24px;
    display: flex;
    flex-direction: column;
}

.top-header {
    height: 80px;
    margin: 0 36px 24px;
    padding: 0 28px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 30px;
    background: linear-gradient(
        120deg,
        rgba(255, 255, 255, 0.12),
        rgba(255, 255, 255, 0.05),
        rgba(0, 0, 0, 0.2)
    );
    backdrop-filter: blur(14px) saturate(140%);
    -webkit-backdrop-filter: blur(14px) saturate(140%);
    box-shadow:
        0 12px 30px rgba(0, 0, 0, 0.35),
        inset 0 1px 0 rgba(255, 255, 255, 0.12);
    position: sticky;
    top: 24px;
    z-index: 10;
    display: flex;
    align-items: center;
    gap: 20px;
}

.header-brand {
    font-size: 24px;
    font-weight: 700;
    letter-spacing: 0.5px;
    white-space: nowrap;
    text-decoration: none;
    color: inherit;
}

.header-slot {
    flex: 1;
    min-height: 1px;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 10px;
}

.user-menu {
    position: relative;
}

.user-trigger {
    background: transparent;
    border: none;
    color: #ffffff;
    font: inherit;
    font-weight: 600;
    cursor: pointer;
    padding: 6px 8px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.user-dropdown {
    position: absolute;
    top: calc(100% + 29px);
    right: -28px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 16px;
    border-radius: 30px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: linear-gradient(
        120deg,
        rgba(255, 255, 255, 0.12),
        rgba(255, 255, 255, 0.05),
        rgba(0, 0, 0, 0.2)
    );
    backdrop-filter: blur(14px) saturate(140%);
    -webkit-backdrop-filter: blur(14px) saturate(140%);
    box-shadow:
        0 12px 30px rgba(0, 0, 0, 0.35),
        inset 0 1px 0 rgba(255, 255, 255, 0.12);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-6px);
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s ease;
    z-index: 20;
}

.user-menu:focus-within .user-dropdown,
.user-menu:hover .user-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.user-btn {
    display: inline-block;
    text-align: center;
    text-decoration: none;
    width: 160px;
}

.user-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.user-avatar-placeholder {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 700;
    background: rgba(0, 0, 0, 0.35);
    color: #ffffff;
}

.user-nickname {
    white-space: nowrap;
}

.footer-telegram {
    margin-top: 6px;
    display: flex;
    justify-content: center;
    align-items: center;
    color: rgba(255, 255, 255, 0.9);
    font-size: 18px;
    gap: 10px;
}

.content {
    min-height: calc(100vh - 158px);
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 1;
}

.home-content {
    min-height: calc(100vh - 158px);
    align-items: center;
    justify-content: flex-start;
    padding: 4px 24px 0;
    flex-direction: column;
    gap: 16px;
}

.ban-content {
    justify-content: center !important;
    align-items: center !important;
}

.ban-card {
    border: 1px solid rgba(255, 255, 255, 0.22);
    background: linear-gradient(
        120deg,
        rgba(255, 255, 255, 0.22),
        rgba(255, 255, 255, 0.08),
        rgba(0, 0, 0, 0.25)
    );
    text-align: center;
    min-height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.site-footer {
    margin-top: 24px;
    padding: 16px 24px 20px;
    border-top: 1px solid #171a1f;
    text-align: center;
    color: rgba(255, 255, 255, 0.75);
    font-size: 14px;
}

.profile-card {
    margin: 0 50px;
    width: calc(100% - 100px);
    border-radius: 30px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: linear-gradient(
        120deg,
        rgba(255, 255, 255, 0.12),
        rgba(255, 255, 255, 0.05),
        rgba(0, 0, 0, 0.2)
    );
    backdrop-filter: blur(14px) saturate(140%);
    -webkit-backdrop-filter: blur(14px) saturate(140%);
    box-shadow:
        0 12px 30px rgba(0, 0, 0, 0.35),
        inset 0 1px 0 rgba(255, 255, 255, 0.12);
    padding: 24px;
    box-sizing: border-box;
}

.profile-header {
    display: flex;
    align-items: center;
    gap: 16px;
    position: relative;
}

.profile-avatar {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.3);
}

.profile-avatar-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    font-weight: 700;
    background: rgba(0, 0, 0, 0.35);
    color: #ffffff;
}

.avatar-menu {
    position: relative;
}

.avatar-trigger {
    background: transparent;
    border: none;
    padding: 0;
    cursor: pointer;
}

.avatar-dropdown {
    position: absolute;
    top: calc(100% + 12px);
    left: 0;
    padding: 16px;
    border-radius: 30px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: linear-gradient(
        120deg,
        rgba(255, 255, 255, 0.12),
        rgba(255, 255, 255, 0.05),
        rgba(0, 0, 0, 0.2)
    );
    backdrop-filter: blur(14px) saturate(140%);
    -webkit-backdrop-filter: blur(14px) saturate(140%);
    box-shadow:
        0 12px 30px rgba(0, 0, 0, 0.35),
        inset 0 1px 0 rgba(255, 255, 255, 0.12);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-6px);
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s ease;
    z-index: 20;
    min-width: 260px;
}

.avatar-menu:focus-within .avatar-dropdown,
.avatar-menu:hover .avatar-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.avatar-form {
    display: grid;
    gap: 12px;
}

.nav-link {
    color: #ffffff;
    text-decoration: none;
    padding: 8px 12px;
    border-radius: 10px;
    border: 1px solid #171a1f;
    background: rgba(0, 0, 0, 0.25);
}

.form-shell {
    width: min(440px, calc(100% - 48px));
    border-radius: 30px;
    border: 1px solid #171a1f;
    background: -webkit-linear-gradient(90deg, #000000, #444444);
    background: linear-gradient(90deg, #000000, #444444);
    padding: 28px;
    box-sizing: border-box;
}

.auth-stack {
    width: min(440px, calc(100% - 48px));
    display: grid;
    gap: 12px;
}

.auth-stack .form-shell {
    width: 100%;
}

.error-shell {
    width: 100%;
    border-radius: 30px;
    border: 1px solid #962c23;
    background: -webkit-linear-gradient(90deg, #ff0000, #000000);
    background: linear-gradient(90deg, #ff0000, #000000);
    padding: 16px 20px;
    box-sizing: border-box;
    color: #ffffff;
    font-weight: 600;
}

.form-title {
    margin: 0 0 18px;
    font-size: 26px;
    font-weight: 700;
}

.hero-text {
    margin: 0;
    font-size: clamp(26px, 3.2vw, 42px);
    font-weight: 700;
    line-height: 1.1;
    text-align: center;
}

.hero-word {
    background: linear-gradient(90deg, #aea4e3, #d3ffe8);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.profile-info .hero-text {
    text-align: left;
}

.profile-uid {
    margin: 6px 0 0;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.6);
}

.profile-form {
    display: grid;
    gap: 12px;
    max-width: 420px;
}

.profile-label {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.75);
}

.profile-edit {
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    border: 1px solid #171a1f;
    background: rgba(0, 0, 0, 0.25);
    color: #ffffff;
    text-decoration: none;
    font-size: 18px;
}

.profile-telegram {
    margin-left: 0;
}

.profile-actions {
    margin-left: auto;
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.hero-actions {
    display: flex;
    justify-content: center;
    gap: 14px;
    width: 100%;
    margin-top: 30px;
}

.hero-btn {
    text-transform: lowercase;
    width: 350px;
    text-align: center;
}


.form-grid {
    display: grid;
    gap: 12px;
}

.input-new {
    width: 100%;
    border-radius: 12px;
    border: 1px solid #171a1f;
    padding: 12px 14px;
    box-sizing: border-box;
    color: #ffffff;
    background: -webkit-linear-gradient(90deg, #000000, #575757);
    background: linear-gradient(90deg, #000000, #575757);
}

.input-new::placeholder {
    color: rgba(255, 255, 255, 0.72);
}

.btn-new {
    text-align: center;
    transition: 0.5s;
    background-size: 200% auto;
    color: white;
    box-shadow: 0 0 20px #111111;
    border-radius: 10px;
    background-image: linear-gradient(to right, #000000 0%, #1a1a1a 51%, #000000 100%);
    border: 1px solid #171a1f;
    padding: 12px 14px;
    cursor: pointer;
    font-weight: 600;
}

.btn-new:hover {
    background-position: right center;
}

.hero-actions .btn-new:nth-child(2) {
    background-image: linear-gradient(to left, #000000 0%, #1a1a1a 51%, #000000 100%);
    background-position: right center;
}

.hero-actions .btn-new:nth-child(2):hover {
    background-position: left center;
}


