* {
    padding: 0;
    margin: 0;
    box-sizing: border-box;
}

:root {
    --users-bg: var(--bg, #f0f5f5);
    --users-surface: var(--surface, #fff);
    --users-text: var(--text, #111);
    --users-muted: var(--muted, #888);
    --users-border: var(--border, rgba(0, 0, 0, .12));
    --users-primary: var(--primary, #0066ff);
    --users-danger: #ff1515;
    --users-success: #009900;
    --users-input-bg: var(--users-surface);
    --users-input-shadow: 0 0 0 1px var(--users-border);
}

body {
    background-color: var(--users-bg);
    font-family: Arial, sans-serif;
    color: var(--users-text);
}

.container {
    position: absolute;
    top: calc(50% + -2.8rem);
    left: 50%;
    transform: translate(-50%, -50%);
    width: 22rem;
    height: 28rem;
    perspective: 1500px;
    -webkit-perspective: 1500px;
    -moz-perspective: 1500px;
}

.box {
    position: absolute;
    top: 0;
    left: 0;
    width: 22rem;
    height: 30rem;
    border-radius: 10px;
    backface-visibility: hidden;
    transition: all 0.5s;
    user-select: none;
}

.signup {
    /* background-color: blue; */
    transform: rotateY(-108deg);
}

.forgot {
    transform: rotateY(180deg);
}

.container .form-content {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    padding-top: 1.25rem;
    border-radius: 30px;
    background-color: var(--users-surface);
}

.container .form-content .avtar {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
}

.container .form-content .avtar .pic {
    width: 80px;
    height: 80px;
    overflow: hidden;
    border-radius: 50%;
    border: 2px solid var(--users-border);
}

.container .form-content .avtar .pic img {
    width: 100%;
    height: 100%;
}

.container .form-content h1 {
    font-size: 1.6rem;
}

.container .form {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
}

.container .form .form-group {
    position: relative;
    width: 100%;
    margin-top: 10px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.container .form .form-group label {
    display: flex;
    gap: 14px;
    align-items: center;
    font-weight: 400;
    margin-bottom: 0;
}

.container .form .form-group label span {
    display: flex;
    align-items: center;
    gap: 6px;
}

.container .form .form-group label span input[type="checkbox"] {
    width: 16px;
    height: 16px;
    margin: 0;
}

.container .form input {
    width: 16rem;
    padding: 0.8rem;
    padding-left: 3rem;
    outline: none;
    border: none;
    border-radius: 15px;
    background: var(--users-input-bg);
    color: var(--users-text);
    box-shadow: var(--users-input-shadow);
    margin: 5px;
}

.container .form input::placeholder {
    color: rgba(0, 0, 0, .45);
}

.container .form .relative {
    position: relative;
}

.container .form .relative .material-icons {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    left: 25px;
}

.container .form .relative .sendcode {
    position: absolute;
    right: 18px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--users-primary);
    font-size: 14px;
    cursor: pointer;
    user-select: none;
}

.container .form .relative .sendcode.countdown {
    color: var(--users-muted);
    cursor: default;
}


.form-message[data-type="error"] {
    color: var(--users-danger);
}

.form-message[data-type="success"] {
    color: var(--users-success);
}

.container .form .btn button[disabled] {
    opacity: 0.7;
    cursor: not-allowed;
}

.container .form .btn {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    margin-top: 14px;
    gap: 6px;
}

.container .form .btn button {
    text-transform: uppercase;
    padding: 12px;
    border: none;
    outline: none;
    background-color: var(--users-primary);
    color: #fff;
    width: 12rem;
    border-radius: 30px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    justify-content: center;
}

.container .btn-something {
    color: var(--users-muted);
    font-size: 14px;
    display: flex;
    gap: 8px;
    margin-bottom: .5rem;
}

.container .btn-something span {
    color: var(--users-primary);
    cursor: pointer;
    font-weight: 500;
}

.container .btn-something .forgot-password {
    color: var(--users-danger);
}

svg {
    position: absolute;
    bottom: 0;
    z-index: -1;
}

.user {
    position: absolute;
    top: 16rem;
    left: 5rem;
}

.user .material-icons {
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 5rem;
    color: var(--users-primary);
}

.user .head {
    font-size: 1.6rem;
    text-transform: uppercase;
    user-select: none;
    text-shadow: 1px 1px 1px rgba(16, 16, 16, 0.1), 1px 2px 1px rgba(16, 16, 16, 0.1), 1px 3px 1px rgba(16, 16, 16, 0.1), 1px 4px 1px rgba(16, 16, 16, 0.1), 1px 5px 1px rgba(16, 16, 16, 0.1), 1px 6px 1px rgba(16, 16, 16, 0.1), 1px 7px 1px rgba(16, 16, 16, 0.1), 1px 8px 1px rgba(16, 16, 16, 0.1);
}

/* =============================
   个人中心 / 编辑资料（复用样式）
   说明：全部写在 index.css 内，且使用 .wrap 作用域避免影响登录页的 .btn 等类名。
   ============================= */

.wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4px;
}

.wrap .page-title {
    padding: 16px 16px 0;
    font-size: 16px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.wrap .card {
    width: 100%;
    background-color: var(--users-surface);
    border-radius: 6px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.08);
    overflow: hidden;
}

.wrap .profile {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 18px 16px;
}

.wrap .profile-actions {
    margin-left: auto;
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

.wrap .profile-logout {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px;
    border-radius: 4px;
    background-color: var(--users-primary);
    color: #fff;
    white-space: nowrap;
}

.wrap .avatar {
    width: 60px;
    height: 60px;
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid var(--users-border);
}

.wrap .avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.wrap .meta .name {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 6px;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.wrap .meta .uid {
    font-size: 12px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 4px;
    color: #fff;
    background: rgb(90 179 255);
}

.wrap .meta .role-badge {
    font-size: 12px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 999px;
    border: 1px solid rgba(0, 102, 255, 0.35);
    color: var(--users-primary);
}

.wrap .meta .email {
    font-size: 13px;
    color: var(--users-muted);
    word-break: break-all;
}

.wrap .actions {
    padding: 0 16px 18px;
}


.wrap .message[data-type="error"] {
    color: var(--users-danger);
}

.wrap .message[data-type="success"] {
    color: var(--users-success);
}

.wrap .avatar-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px;
    gap: 14px;
}

.wrap .upload {
    gap: 6px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 14px;
    border-radius: 999px;
    background-color: var(--users-primary);
    color: #fff;
    border: 0;
    cursor: pointer;
    user-select: none;
    white-space: nowrap;
}

.wrap .upload input {
    display: none;
}

.wrap .form {
    padding: 0 16px 16px;
}

.wrap .field {
    margin-top: 12px;
}

.wrap .divider {
    height: 1px;
    width: 100%;
    margin-top: 14px;
    background: rgba(0, 0, 0, 0.06);
}

.wrap .label {
    font-size: 13px;
    color: var(--users-muted);
    margin-bottom: 6px;
}

.wrap input,
.wrap textarea {
    width: 100%;
    padding: 12px;
    outline: none;
    border: none;
    border-radius: 12px;
    background: var(--users-input-bg);
    color: var(--users-text);
    box-shadow: var(--users-input-shadow);
}

.wrap input::placeholder,
.wrap textarea::placeholder {
    color: rgba(0, 0, 0, .45);
}

.wrap textarea {
    resize: none;
}

.wrap .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    margin-top: 12px;
    padding: 12px;
    border: none;
    outline: none;
    background-color: var(--users-primary);
    color: #fff;
    border-radius: 999px;
    cursor: pointer;
    text-decoration: none;
    gap: 6px;
}

.wrap .btn[disabled] {
    opacity: 0.7;
    cursor: not-allowed;
}

.wrap .inline-row {
    position: relative;
}

.wrap .inline-row .upload {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    padding: 0;
    font-size: 14px;
    background: none;
    color: var(--users-primary);
}

.wrap .upload.countdown {
    opacity: 0.8;
    cursor: not-allowed;
}

@media (prefers-color-scheme: dark) {
    :root {
        --users-input-bg: rgba(0, 0, 0, .22);
        --users-input-shadow: 0 0 0 1px rgba(255, 255, 255, .14);
    }

    .user .head {
        text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.35), 1px 2px 1px rgba(0, 0, 0, 0.35), 1px 3px 1px rgba(0, 0, 0, 0.35), 1px 4px 1px rgba(0, 0, 0, 0.35), 1px 5px 1px rgba(0, 0, 0, 0.35), 1px 6px 1px rgba(0, 0, 0, 0.35), 1px 7px 1px rgba(0, 0, 0, 0.35), 1px 8px 1px rgba(0, 0, 0, 0.35);
    }

    .container .form input::placeholder,
    .wrap input::placeholder,
    .wrap textarea::placeholder {
        color: rgba(255, 255, 255, .55);
    }

    .wrap .divider {
        background: rgba(255, 255, 255, 0.10);
    }

    .wrap .card {
        box-shadow: 0 0 16px rgba(0, 0, 0, .35);
    }
}