.user-page {
    min-height: 100vh;
}

.skip-link {
    position: absolute;
    left: -9999px;
    top: auto;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.profile-shell {
    width: min(1180px, calc(100% - 24px));
    margin: 0 auto;
    padding: 110px 0 56px;
}

.profile-top-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.header-link-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 120px;
    min-height: 42px;
    padding: 0 16px;
    border-radius: 999px;
    border: 1px solid rgba(255,255,255,0.16);
    background: rgba(255,255,255,0.08);
    color: #fff;
    text-decoration: none;
    font-weight: 800;
    cursor: pointer;
    transition: transform 0.18s ease, background 0.18s ease, border-color 0.18s ease;
}

.header-link-btn:hover {
    transform: translateY(-1px);
    background: rgba(255,255,255,0.14);
    border-color: rgba(255,255,255,0.28);
}

.header-link-btn.danger {
    background: rgba(255, 92, 108, 0.12);
    border-color: rgba(255, 92, 108, 0.36);
}

.profile-hero-card,
.profile-card {
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.14);
    box-shadow: 0 16px 36px rgba(0,0,0,0.18);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
}

.profile-hero-card {
    border-radius: 28px;
    padding: 28px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 22px;
}

.profile-hero-left h1 {
    margin: 10px 0 10px;
    font-size: clamp(1.9rem, 4vw, 2.8rem);
    line-height: 1.08;
    color: #fff;
}

.profile-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 36px;
    padding: 0 14px;
    border-radius: 999px;
    background: rgba(255,255,255,0.10);
    color: #ffd93d;
    font-weight: 900;
    letter-spacing: 0.02em;
}

.profile-subtitle {
    margin: 0;
    max-width: 720px;
    color: rgba(255,255,255,0.82);
    font-size: 1rem;
    line-height: 1.6;
}

.profile-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.45fr) minmax(320px, 0.95fr);
    gap: 22px;
    align-items: start;
}

.profile-side-col {
    display: grid;
    gap: 22px;
}

.profile-card {
    border-radius: 26px;
    padding: 26px;
}

.profile-card-main {
    min-height: 100%;
}

.section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 18px;
}

.section-head h2 {
    margin: 0;
    color: #fff;
    font-size: 1.32rem;
}

.section-chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    padding: 0 12px;
    border-radius: 999px;
    background: rgba(54, 241, 167, 0.12);
    border: 1px solid rgba(54, 241, 167, 0.24);
    color: #36f1a7;
    font-size: 0.82rem;
    font-weight: 900;
}

.section-chip.alt {
    background: rgba(0, 234, 255, 0.12);
    border-color: rgba(0, 234, 255, 0.24);
    color: #00eaff;
}

.section-chip.danger {
    background: rgba(255, 92, 108, 0.12);
    border-color: rgba(255, 92, 108, 0.28);
    color: #ff8a96;
}

.section-note,
.danger-text,
.loading-text {
    margin: 0;
    color: rgba(255,255,255,0.76);
    line-height: 1.6;
}

.info-stack {
    display: grid;
    gap: 16px;
}

.info-block label {
    display: block;
    margin-bottom: 8px;
    color: #ffd93d;
    font-size: 0.78rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.input-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 14px 16px;
    border-radius: 18px;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.10);
}

.input-wrapper.locked {
    align-items: flex-start;
}

.field-content {
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-width: 0;
    flex: 1;
    color: #fff;
    font-weight: 700;
}

.field-content span {
    word-break: break-word;
}

.locked-hint {
    color: rgba(255,255,255,0.56);
    font-size: 0.78rem;
    font-weight: 700;
}

.hidden {
    display: none !important;
}

#name-input,
#pass-input {
    width: 100%;
    min-height: 44px;
    border-radius: 14px;
    border: 1px solid rgba(255,255,255,0.16);
    background: rgba(6, 16, 34, 0.55);
    color: #fff;
    padding: 0 14px;
    outline: none;
    font-size: 0.96rem;
}

#name-input::placeholder,
#pass-input::placeholder {
    color: rgba(255,255,255,0.44);
}

#name-input:focus,
#pass-input:focus {
    border-color: rgba(0,234,255,0.45);
    box-shadow: 0 0 0 3px rgba(0,234,255,0.10);
}

.btn-edit,
.btn-save,
.btn-delete {
    border: none;
    cursor: pointer;
    transition: transform 0.18s ease, box-shadow 0.18s ease, opacity 0.18s ease;
}

.btn-edit:hover,
.btn-save:hover,
.btn-delete:hover {
    transform: translateY(-1px);
}

.btn-edit {
    flex-shrink: 0;
    min-width: 100px;
    min-height: 42px;
    padding: 0 16px;
    border-radius: 14px;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(54, 241, 167, 0.26);
    color: #36f1a7;
    font-weight: 800;
}

.btn-save {
    width: 100%;
    min-height: 50px;
    margin-top: 18px;
    border-radius: 16px;
    background: linear-gradient(135deg, #36f1a7, #00eaff);
    color: #071221;
    font-weight: 900;
    font-size: 1rem;
    box-shadow: 0 12px 24px rgba(0, 234, 255, 0.18);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
    gap: 14px;
    margin-top: 18px;
}

.stat-item {
    border-radius: 18px;
    padding: 16px 14px;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.10);
    text-align: center;
}

.stat-item strong {
    display: block;
    margin: 6px 0 2px;
    font-size: 1.35rem;
    color: #ffd93d;
}

.stat-item small {
    color: rgba(255,255,255,0.62);
    font-size: 0.76rem;
    line-height: 1.4;
}

.danger-card {
    border-color: rgba(255, 92, 108, 0.16);
}

.btn-delete {
    width: 100%;
    min-height: 50px;
    margin-top: 16px;
    border-radius: 16px;
    background: linear-gradient(135deg, #ff5c6c, #ff7a59);
    color: #fff;
    font-weight: 900;
    box-shadow: 0 12px 24px rgba(255, 92, 108, 0.18);
}

@media (max-width: 980px) {
    .profile-grid {
        grid-template-columns: 1fr;
    }

    .profile-hero-card {
        flex-direction: column;
        align-items: flex-start;
    }

    .profile-hero-right {
        width: 100%;
    }

    .profile-hero-right .action-btn {
        width: 100%;
    }
}

@media (max-width: 640px) {
    .profile-shell {
        width: min(100% - 14px, 100%);
        padding: 92px 0 32px;
    }

    .profile-hero-card,
    .profile-card {
        border-radius: 22px;
        padding: 18px;
    }

    .profile-top-actions {
        gap: 8px;
        justify-content: flex-end;
    }

    .header-link-btn {
        min-width: 0;
        padding: 0 12px;
        font-size: 0.88rem;
    }

    .input-wrapper {
        flex-direction: column;
        align-items: stretch;
    }

    .btn-edit {
        width: 100%;
    }

    .stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}
.logo {
    width: clamp(120px, 20vw, 220px);
    height: auto;
}