

/* extracted verbatim from user-accepted register.html */

/* ===== 全局重置 ===== */
body {
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%) !important;
    background-size: cover !important;
    min-height: 100vh !important;
    margin: 0 !important;
    padding: 0 !important;
    height: 100% !important;
    width: 100% !important;
    overflow-x: hidden !important;
}

.navbar {
    display: none !important;
}

.main-container {
    max-width: none !important;
    margin: 0 !important;
    padding: 20px 15px !important;
    min-height: 100vh !important;
    width: 100% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    animation: none !important;
    background: transparent !important;
    position: relative;
    box-sizing: border-box;
}

.register-wrapper {
    width: 100%;
    max-width: 520px;
    margin: 0 auto;
    position: relative;
    z-index: 10;
}

/* ===== 卡片样式 ===== */
.register-card {
    background: white;
    border-radius: 18px;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.1);
    padding: 2.5rem 2.8rem;
    border: 1px solid rgba(255, 255, 255, 0.3);
    position: relative;
    box-sizing: border-box;
    width: 100%;
    overflow: hidden;
}

/* 顶部装饰线条 */
.register-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--secondary-color, #3498db) 0%, var(--primary-color, #2c3e50) 100%);
}

/* ===== 成功页面样式 ===== */
.success-page {
    text-align: center;
    padding: 1.5rem 0 0.5rem;
}

.success-page .success-icon {
    font-size: 4.5rem;
    color: #22c55e;
    margin-bottom: 1rem;
    animation: successBounce 0.6s ease;
}

@keyframes successBounce {
    0% { transform: scale(0); opacity: 0; }
    50% { transform: scale(1.2); }
    70% { transform: scale(0.9); }
    100% { transform: scale(1); opacity: 1; }
}

.success-page .success-title {
    font-size: 1.8rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 0.5rem;
}

.success-page .success-message {
    color: #64748b;
    font-size: 1rem;
    margin-bottom: 0.5rem;
    line-height: 1.8;
}

.success-page .success-message strong {
    color: var(--secondary-color, #3498db);
    font-weight: 700;
}

.success-page .success-sub-message {
    color: #94a3b8;
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
}

.success-page .countdown {
    color: #94a3b8;
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
}

.success-page .countdown span {
    font-weight: 700;
    color: var(--secondary-color, #3498db);
    font-size: 1.2rem;
}

.success-page .btn-login-now {
    display: inline-block;
    padding: 0.7rem 2.2rem;
    background: linear-gradient(135deg, var(--secondary-color, #3498db) 0%, var(--primary-color, #2c3e50) 100%);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 3px 12px rgba(102, 126, 234, 0.3);
}

.success-page .btn-login-now:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.4);
}

.success-page .btn-login-now i {
    margin-right: 0.5rem;
}

/* ===== 头部 ===== */
.register-header {
    text-align: center;
    margin-bottom: 1.8rem;
}

.register-header .icon-wrapper {
    width: 72px;
    height: 72px;
    background: linear-gradient(135deg, var(--secondary-color, #3498db) 0%, var(--primary-color, #2c3e50) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.35);
    transition: transform 0.3s ease;
}

.register-header .icon-wrapper:hover {
    transform: scale(1.05);
}

.register-header .icon-wrapper i {
    font-size: 2rem;
    color: white;
}

.register-header h2 {
    color: #1e293b;
    font-size: 1.6rem;
    font-weight: 700;
    margin-bottom: 0.3rem;
    letter-spacing: -0.3px;
}

.register-header p {
    color: #64748b;
    font-size: 0.95rem;
    margin: 0;
}

/* ===== Flash消息 ===== */
.alert {
    padding: 0.8rem 1rem;
    border-radius: 10px;
    margin-bottom: 1rem;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    animation: slideDown 0.4s ease;
}

.alert-danger {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #dc2626;
}

.alert-success {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    color: #16a34a;
}

.alert-warning {
    background: #fffbeb;
    border: 1px solid #fde68a;
    color: #92400e;
}

.alert-info {
    background: #eff6ff;
    border: 1px solid #bfdbfe;
    color: #1e40af;
}

.alert i {
    font-size: 1.1rem;
}

/* ===== 表单样式 ===== */
.register-form {
    text-align: left;
}

.form-group {
    margin-bottom: 1.1rem;
}

.form-label {
    display: flex;
    align-items: center;
    margin-bottom: 0.4rem;
    font-weight: 600;
    color: #475569;
    font-size: 0.9rem;
}

.form-label i {
    margin-right: 0.6rem;
    color: var(--secondary-color, #3498db);
    font-size: 0.95rem;
    width: 18px;
    text-align: center;
    flex-shrink: 0;
}

.input-wrapper {
    position: relative;
}

.form-control {
    width: 100%;
    padding: 0.8rem 1rem 0.8rem 2.7rem;
    border: 1.5px solid #e2e8f0;
    border-radius: 10px;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    background: #f8fafc;
    color: #475569;
    font-weight: 500;
    box-sizing: border-box;
    max-width: 100%;
}

.form-control:focus {
    outline: none;
    border-color: var(--secondary-color, #3498db);
    background: white;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.12);
}

.form-control.input-code {
    text-transform: uppercase;
    font-size: 0.95rem;
    letter-spacing: 3px;
    padding: 0.8rem 1rem 0.8rem 2.7rem;
    font-weight: 500;
    color: #1e293b;
}

.form-control.input-code:focus {
    border-color: var(--primary-color, #2c3e50);
    box-shadow: 0 0 0 3px rgba(118, 75, 162, 0.12);
}

.input-icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
    font-size: 0.95rem;
    transition: color 0.3s ease;
    pointer-events: none;
}

.form-control:focus ~ .input-icon,
.input-wrapper.focused .input-icon {
    color: var(--secondary-color, #3498db);
}

.form-control.input-code:focus ~ .input-icon {
    color: var(--primary-color, #2c3e50);
}

/* ===== 输入框状态 ===== */
.form-control.error {
    border-color: #ef4444 !important;
    background: #fef2f2 !important;
}

.form-control.error ~ .input-icon {
    color: #ef4444 !important;
}

.form-control.success {
    border-color: #22c55e !important;
    background: #f0fdf4 !important;
}

.form-control.success ~ .input-icon {
    color: #22c55e !important;
}

/* ===== 帮助文字 ===== */
.help-text {
    display: block;
    margin-top: 0.3rem;
    font-size: 0.78rem;
    color: #94a3b8;
}

.help-text i {
    margin-right: 0.3rem;
}

/* ===== 错误提示 ===== */
.error-text {
    display: none;
    margin-top: 0.3rem;
    font-size: 0.78rem;
    color: #ef4444;
    animation: slideDown 0.3s ease;
}

.error-text.show {
    display: block;
}

.error-text i {
    margin-right: 0.3rem;
}

/* ===== 密码强度 ===== */
.password-strength {
    margin-top: 0.5rem;
    display: none;
}

.password-strength.show {
    display: block;
}

.strength-bars {
    display: flex;
    gap: 4px;
    align-items: center;
}

.strength-bar {
    flex: 1;
    height: 4px;
    background: #e2e8f0;
    border-radius: 2px;
    transition: all 0.4s ease;
    overflow: hidden;
}

.strength-bar .fill {
    height: 100%;
    width: 0%;
    border-radius: 2px;
    transition: width 0.4s ease, background 0.4s ease;
}

.strength-text {
    font-size: 0.7rem;
    margin-top: 0.2rem;
    display: block;
    color: #94a3b8;
    transition: color 0.3s ease;
}

/* ===== 提交按钮 ===== */
.register-btn {
    width: 100%;
    padding: 0.72rem;
    background: linear-gradient(135deg, var(--secondary-color, #3498db) 0%, var(--primary-color, #2c3e50) 100%);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 0.5rem;
    box-shadow: 0 3px 12px rgba(102, 126, 234, 0.3);
    letter-spacing: 0.3px;
    box-sizing: border-box;
    min-height: 44px;
    position: relative;
    overflow: hidden;
    z-index: 1;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.register-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.25),
        transparent
    );
    transition: left 0.6s ease;
    z-index: -1;
}

.register-btn:hover::before {
    left: 100%;
}

.register-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.4);
}

.register-btn:active {
    transform: translateY(0);
}

.register-btn i {
    margin-right: 0.5rem;
}

.register-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none !important;
}

.register-btn:disabled::before {
    display: none;
}

/* ===== 分隔线 ===== */
.divider {
    display: flex;
    align-items: center;
    margin: 1.5rem 0 1.2rem;
}

.divider::before,
.divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: linear-gradient(to right, transparent, #e2e8f0, transparent);
}

.divider span {
    padding: 0 1rem;
    color: #94a3b8;
    font-size: 0.8rem;
}

/* ===== 登录链接 ===== */
.login-link {
    text-align: center;
    font-size: 0.9rem;
    color: #64748b;
}

.login-link a {
    color: var(--secondary-color, #3498db);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.2s ease;
}

.login-link a:hover {
    color: var(--primary-color, #2c3e50);
    text-decoration: underline;
}

.login-link a i {
    margin-right: 0.3rem;
}

/* ===== 底部提示 ===== */
.footer-note {
    text-align: center;
    margin-top: 1.2rem;
    padding-top: 1rem;
    border-top: 1px solid #f1f5f9;
    font-size: 0.75rem;
    color: #94a3b8;
}

.footer-note i {
    margin-right: 0.3rem;
    color: var(--secondary-color, #3498db);
}

/* ===== 动画 ===== */
@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.fa-spin {
    animation: spin 1s linear infinite;
}

/* ===== 响应式 ===== */
@media (max-width: 768px) {
    .register-card {
        padding: 1.8rem 1.8rem;
        border-radius: 14px;
    }

    .register-header h2 {
        font-size: 1.3rem;
    }

    .register-header .icon-wrapper {
        width: 60px;
        height: 60px;
    }

    .register-header .icon-wrapper i {
        font-size: 1.6rem;
    }

    .success-page .success-icon {
        font-size: 3.5rem;
    }

    .success-page .success-title {
        font-size: 1.5rem;
    }
}

@media (max-width: 480px) {
    .register-card {
        padding: 1.4rem 1.2rem;
        border-radius: 12px;
    }

    .register-header h2 {
        font-size: 1.2rem;
    }

    .register-header p {
        font-size: 0.85rem;
    }

    .form-control {
        padding: 0.7rem 0.8rem 0.7rem 2.3rem;
        font-size: 0.85rem;
    }

    .register-btn {
        padding: 0.75rem;
        font-size: 0.9rem;
        min-height: 44px;
    }

    .success-page .success-icon {
        font-size: 3rem;
    }

    .success-page .success-title {
        font-size: 1.3rem;
    }

    .success-page .btn-login-now {
        padding: 0.75rem 1.8rem;
        font-size: 0.9rem;
    }
}
