/**
 * 公共样式文件
 * 包含项目中通用的CSS样式
 */

/* 基础样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: #4a5568;
    background: transparent;
}

/* 表单样式 */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #718096;
    font-weight: 500;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-size: 16px;
    transition: border-color 0.3s ease;
    box-sizing: border-box;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #a0aec0;
}

/* 按钮样式 */
.btn {
    background: #f7fafc;
    color: #4a5568;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
    box-sizing: border-box;
}

.btn:hover {
    transform: translateY(-1px);
    background: #edf2f7;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.btn-primary {
    background: #f7fafc;
    color: #4a5568;
    border: 1px solid #e2e8f0;
}

.btn-secondary {
    background: #edf2f7;
    color: #4a5568;
}

.btn-secondary:hover {
    background: #e2e8f0;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.btn-full {
    width: 100%;
}

.login-btn {
    width: 100%;
    background: #f7fafc;
    color: #4a5568;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 12px 24px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-sizing: border-box;
    position: relative;
    overflow: hidden;
}

.login-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.login-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    background: #edf2f7;
}

.login-btn:hover::before {
    left: 100%;
}

.login-btn:active {
    transform: translateY(0);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06);
}

/* 消息提示样式 */
.alert {
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.alert-success {
    background: #f0fff4;
    color: #22543d;
    border: 1px solid #c6f6d5;
}

.alert-danger,
.error {
    background: #fed7d7;
    color: #742a2a;
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 20px;
    border: 1px solid #feb2b2;
}

.alert-warning {
    background: #fefcbf;
    color: #744210;
    border: 1px solid #f6e05e;
}

.alert-info {
    background: #e6fffa;
    color: #234e52;
    border: 1px solid #81e6d9;
}

/* 卡片样式 */
.card {
    background: #fafafa;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    margin-bottom: 20px;
    border: 1px solid #f0f0f0;
}

.card-header {
    background: #f7fafc;
    padding: 15px 20px;
    border-bottom: 1px solid #e2e8f0;
    font-weight: 600;
    border-radius: 12px 12px 0 0;
    margin: -20px -20px 20px -20px;
}

/* 状态标签样式 */
.status {
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
    text-align: center;
}

.status.paid {
    background: #f0fff4;
    color: #22543d;
}

.status.pending {
    background: #fefcbf;
    color: #744210;
}

.status.processing {
    background: #e6fffa;
    color: #234e52;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    .card {
        padding: 15px;
    }
    
    .btn {
        padding: 8px 16px;
        font-size: 13px;
    }
}

/* 容器样式 */
.container {
    background: transparent;
    border-radius: 20px;
    padding: 40px;
    box-shadow: none;
    max-width: 600px;
    width: 100%;
}

.install-container,
.result-container,
.error-container {
    background: transparent;
    border-radius: 20px;
    padding: 40px;
    text-align: center;
    box-shadow: none;
    max-width: 500px;
    width: 100%;
}

/* 标题样式 */
.install-title,
.result-title {
    font-size: 28px;
    font-weight: 600;
    color: #4a5568;
    margin-bottom: 10px;
}

.install-subtitle {
    color: #718096;
    font-size: 16px;
}

.section-title {
    font-size: 18px;
    font-weight: 600;
    color: #212529;
    margin: 30px 0 15px 0;
    padding-bottom: 10px;
    border-bottom: 2px solid #e2e8f0;
}

/* 图标样式 */
.result-icon,
.error-icon {
    font-size: 64px;
    margin-bottom: 20px;
}

/* 消息样式 */
.result-message,
.error-message {
    color: #6c757d;
    margin-bottom: 30px;
    line-height: 1.6;
}

/* 订单信息样式 */
.order-info {
    background: #f7fafc;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 30px;
    text-align: left;
    border: 1px solid #e2e8f0;
}

/* 帮助文本 */
.help-text {
    font-size: 12px;
    color: #6c757d;
    margin-top: 5px;
}

/* 表单行 */
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

/* 工具类 */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }
.d-none { display: none; }
.d-block { display: block; }
.d-flex { display: flex; }
.justify-center { justify-content: center; }
.align-center { align-items: center; }
.mt-10 { margin-top: 10px; }
.mt-20 { margin-top: 20px; }
.mb-10 { margin-bottom: 10px; }
.mb-20 { margin-bottom: 20px; }

/* 响应式设计 */
@media (max-width: 768px) {
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .container,
    .install-container,
    .result-container,
    .error-container {
        padding: 20px;
        margin: 10px;
    }
}