/**
 * 灵动积木 - 通用样式
 * 
 * @author 灵动积木开发团队
 * @link https://jimuie.com
 */

/* 重置样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* 移动端优化 */
html {
    -webkit-tap-highlight-color: transparent;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    font-size: 14px;
    line-height: 1.6;
    color: #333;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
}

/* 容器 */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 15px;
}

/* 按钮 */
.btn {
    display: inline-block;
    padding: 12px 24px;
    font-size: 14px;
    font-weight: 500;
    text-align: center;
    text-decoration: none;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    -webkit-user-select: none;
    user-select: none;
    min-height: 44px;
}

.btn:active {
    transform: scale(0.98);
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
}

.btn-primary:hover {
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.btn-block {
    display: block;
    width: 100%;
}

/* 表单组 */
.form-group {
    margin-bottom: 20px;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px 16px;
    font-size: 14px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    transition: all 0.3s ease;
    min-height: 44px;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

/* 复选框 */
.checkbox {
    display: flex;
    align-items: center;
    cursor: pointer;
    user-select: none;
}

.checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin-right: 8px;
    cursor: pointer;
}

.checkbox span {
    font-size: 14px;
}

/* 链接 */
a {
    color: #667eea;
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: #764ba2;
}

/* 消息提示 */
.message {
    padding: 12px 16px;
    margin: 15px 0;
    border-radius: 8px;
    font-size: 14px;
}

.message.error {
    background-color: #fee;
    border: 1px solid #fcc;
    color: #c33;
}

.message.success {
    background-color: #efe;
    border: 1px solid #cfc;
    color: #3c3;
}

.message.warning {
    background-color: #ffe;
    border: 1px solid #ffc;
    color: #cc3;
}

.message.info {
    background-color: #eef;
    border: 1px solid #ccf;
    color: #33c;
}

/* 加载中 */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 响应式 - 平板 */
@media screen and (min-width: 768px) {
    body {
        font-size: 15px;
    }
    
    .container {
        padding: 30px;
    }
    
    .btn {
        padding: 14px 28px;
        font-size: 15px;
    }
}

/* 响应式 - PC */
@media screen and (min-width: 1200px) {
    body {
        font-size: 16px;
    }
    
    .btn {
        padding: 16px 32px;
        font-size: 16px;
    }
}

