/**
 * 基础样式
 */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Arial', 'Microsoft YaHei', sans-serif;
    background-image: url(../images/bg_home.png);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    color: #ecf0f1;
    overflow: hidden;
    min-height: 100vh;
}

#app {
    width: 100%;
    max-width: 720px;  /* 竖屏宽度 */
    height: 100vh;
    margin: 0 auto;
    position: relative;
    overflow: hidden;
    background: transparent;
}

/* 页面容器通用样式 */
.page {
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.page.page-enter {
    opacity: 1;
    transform: translateY(0);
}

.page.page-exit {
    opacity: 0;
    transform: translateY(-20px);
}

/* 按钮通用样式 */
.btn {
    padding: 8px 20px;
    font-size: 12px;
    font-weight: bold;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.3);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

.btn:active {
    transform: translateY(0);
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.btn-primary {
    background: linear-gradient(135deg, #2ecc71, #27ae60);
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.btn-primary:hover {
    background: linear-gradient(135deg, #27ae60, #229954);
    border-color: rgba(255, 255, 255, 0.5);
}

.btn-secondary {
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.btn-secondary:hover {
    background: linear-gradient(135deg, #2980b9, #21618c);
    border-color: rgba(255, 255, 255, 0.5);
}

.btn-danger {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.btn-danger:hover {
    background: linear-gradient(135deg, #c0392b, #a93226);
    border-color: rgba(255, 255, 255, 0.5);
}

/* 页面标题 */
.page-title {
    text-align: center;
    padding: 12px 20px;
    background: rgba(0, 0, 0, 0.3);
    flex: 0 0 auto;
}

.page-title h2 {
    font-size: 18px;
    color: #f39c12;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

/* 加载动画 */
.loading {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top-color: #f39c12;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* 对话框通用样式 */
.dialog-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.dialog-content {
    background: linear-gradient(135deg, #34495e, #2c3e50);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.9);
    border: 3px solid rgba(243, 156, 18, 0.6);
    max-width: 500px;
    width: 90%;
}

.dialog-content h3 {
    color: #f39c12;
    margin-bottom: 20px;
    text-align: center;
}

/* 响应式 */
@media (max-width: 768px) {
    .btn {
        padding: 8px 16px;
        font-size: 11px;
    }
    
    .page-title h2 {
        font-size: 16px;
}
}
