/* 基础重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* 根部样式 - 扁平化设计 */
:root {
    --primary-color: #2563eb;
    --secondary-color: #1e40af;
    --accent-color: #3b82f6;
    --success-color: #059669;
    --warning-color: #d97706;
    --danger-color: #dc2626;
    --text-color: #1f2937;
    --text-muted: #6b7280;
    --bg-color: #ffffff;
    --bg-secondary: #f8fafc;
    --bg-tertiary: #f1f5f9;
    --border-color: #e2e8f0;
    --shadow-sm: none;
    --shadow-md: 0 1px 3px rgba(0,0,0,0.1);
    --shadow-lg: 0 2px 6px rgba(0,0,0,0.15);
    --radius: 0.25rem;
    --radius-lg: 0.375rem;
}

/* 基础字体 - 扁平化设计 */
body {
    font-family: 'Microsoft YaHei', 'PingFang SC', 'Hiragino Sans GB', sans-serif;
    line-height: 1.5;
    color: var(--text-color);
    background-color: var(--bg-color);
    min-height: 100vh;
}

/* 容器 - 减少垂直间距 */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 15px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* 头部样式 - 扁平化 */
.header {
    text-align: center;
    margin-bottom: 1.5rem;
    padding: 1.5rem 0;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
}

.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 0.25rem;
}

.logo .icon {
    font-size: 2rem;
}

.header h1 {
    font-size: 2rem;
    font-weight: 600;
    color: var(--primary-color);
}

.subtitle {
    font-size: 1.125rem;
    color: var(--text-muted);
    margin-top: 0.5rem;
}

/* 收藏提醒 - 扁平化 */
.bookmark-notice {
    background: #fef3c7;
    border: 1px solid #f59e0b;
    border-radius: var(--radius);
    padding: 1rem;
    margin-bottom: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.notice-content {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex: 1;
}

.bookmark-icon {
    font-size: 1.5rem;
}

.notice-text h3 {
    font-size: 1.25rem;
    color: #92400e;
    margin-bottom: 0.25rem;
}

.notice-text p {
    color: #a16207;
    font-weight: 500;
}

.bookmark-btn {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: var(--radius);
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.bookmark-btn:hover {
    background: var(--secondary-color);
}

/* 网址区域 - 紧凑布局 */
.urls-section {
    margin-bottom: 1.5rem;
}

.urls-section h2 {
    font-size: 1.5rem;
    color: var(--text-color);
    margin-bottom: 0.75rem;
    text-align: center;
}

.update-time {
    text-align: center;
    color: var(--text-muted);
    margin-bottom: 1rem;
    font-size: 0.875rem;
}

.urls-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.url-card {
    background: var(--bg-color);
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    padding: 1rem;
    transition: border-color 0.2s ease;
    position: relative;
    display: block;
    text-decoration: none;
    color: inherit;
}

.url-card:hover {
    border-color: var(--primary-color);
}

.url-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.5rem;
}

.url-title {
    font-weight: 500;
    color: var(--text-color);
    font-size: 1rem;
}

.url-actions {
    display: flex;
    gap: 0.5rem;
}

.url-action-btn {
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    padding: 0.25rem 0.5rem;
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    color: var(--text-color);
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
}

.url-action-btn:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.copy-btn {
    background: #f0f9ff;
    border-color: #0ea5e9;
    color: #0ea5e9;
}

.copy-btn:hover {
    background: #0ea5e9;
    color: white;
}

.copy-btn.copied {
    background: #059669;
    color: white;
    border-color: #059669;
}

.url-status {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.75rem;
    font-weight: 500;
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--success-color);
}

.url-address {
    font-family: 'Consolas', 'Monaco', monospace;
    background: var(--bg-tertiary);
    padding: 0.5rem;
    border-radius: var(--radius);
    margin-bottom: 0.5rem;
    font-size: 0.8rem;
    color: var(--primary-color);
    word-break: break-all;
}

.url-description {
    color: var(--text-muted);
    font-size: 0.8rem;
    line-height: 1.4;
}

/* 使用说明 - 紧凑布局 */
.instructions {
    background: var(--bg-secondary);
    border-radius: var(--radius);
    padding: 1.25rem;
    margin-bottom: 1.5rem;
    border: 1px solid var(--border-color);
}

.instructions h3 {
    font-size: 1.25rem;
    color: var(--text-color);
    margin-bottom: 0.75rem;
}

.instructions ul {
    list-style: none;
    padding: 0;
}

.instructions li {
    padding: 0.5rem 0;
    color: var(--text-color);
    position: relative;
    padding-left: 1.5rem;
}

.instructions li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--success-color);
    font-weight: bold;
}

/* 状态区域 - 紧凑布局 */
.status-section {
    margin-bottom: 1.5rem;
}

.status-section h3 {
    font-size: 1.25rem;
    color: var(--text-color);
    margin-bottom: 0.75rem;
    text-align: center;
}

.status-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 0.75rem;
}

.status-item {
    background: var(--bg-color);
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    padding: 0.75rem;
    text-align: center;
}

.status-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 0.25rem;
}

.status-label {
    color: var(--text-muted);
    font-size: 0.875rem;
}

/* 底部 */
.footer {
    margin-top: auto;
    text-align: center;
    padding: 2rem 0;
    border-top: 1px solid var(--border-color);
    color: var(--text-muted);
}

.status-indicator {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

/* 弹窗样式 */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    backdrop-filter: blur(4px);
}

.modal.show {
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-content {
    background: var(--bg-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    max-width: 500px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from { transform: translateY(20px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.modal-header h3 {
    color: var(--text-color);
}

.close-btn {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-muted);
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s ease;
}

.close-btn:hover {
    background: var(--bg-tertiary);
    color: var(--text-color);
}

.modal-body {
    padding: 1.5rem;
}

.guide-step {
    margin-bottom: 1.5rem;
    padding: 1rem;
    background: var(--bg-secondary);
    border-radius: var(--radius);
}

.guide-step h4 {
    color: var(--text-color);
    margin-bottom: 0.5rem;
}

.guide-step p {
    color: var(--text-muted);
    line-height: 1.5;
}

kbd {
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 3px;
    box-shadow: 0 1px 0 var(--border-color);
    color: var(--text-color);
    display: inline-block;
    font-size: 0.8em;
    font-weight: 700;
    line-height: 1;
    padding: 2px 4px;
    white-space: nowrap;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    .header h1 {
        font-size: 1.75rem;
    }
    
    .bookmark-notice {
        flex-direction: column;
        text-align: center;
        gap: 0.75rem;
        padding: 0.75rem;
    }
    
    .notice-content {
        justify-content: center;
    }
    
    .urls-grid {
        grid-template-columns: 1fr;
    }
    
    .status-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .modal-content {
        margin: 1rem;
        width: calc(100% - 2rem);
    }
    
    .url-actions {
        flex-direction: column;
        gap: 0.25rem;
    }
    
    .url-action-btn {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .header {
        padding: 1rem;
    }
    
    .header h1 {
        font-size: 1.5rem;
    }
    
    .logo {
        gap: 0.25rem;
    }
    
    .url-card {
        padding: 0.75rem;
    }
    
    .instructions {
        padding: 1rem;
    }
    
    .status-grid {
        grid-template-columns: 1fr;
    }
}

/* 加载动画 */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid var(--border-color);
    border-radius: 50%;
    border-top-color: var(--primary-color);
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* 滚动条样式 */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-tertiary);
}

::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--text-muted);
} 