* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    height: 100%;
    width: 100%;
    margin: 0;
    padding: 0;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial;
    line-height: 1.6;
    color: #333;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: flex-start;
}

.container {
    width: 100%;
    min-height: 100vh;
    max-width: 100%;
    margin: 0;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
}

.content-wrapper {
    width: 100%;
    max-width: 1000px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 3rem;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    margin-bottom: 2rem;
}

/* 头部区域 */
.header-section {
    text-align: center;
    margin-bottom: 3rem;
}

.header-section h1 {
    font-size: 3rem;
    font-weight: 700;
    color: #1d1d1f;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.site-description {
    font-size: 1.2rem;
    color: #86868b;
    line-height: 1.6;
    max-width: 600px;
    margin: 0 auto;
}

/* 主要功能区域 */
.main-section {
    margin-bottom: 4rem;
}

.input-section {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 16px;
    border: 2px solid #e9ecef;
    transition: all 0.3s ease;
}

.input-section:focus-within {
    border-color: #667eea;
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
}

.rss-input {
    flex: 1;
    padding: 1rem 1.5rem;
    border: none;
    border-radius: 12px;
    font-size: 1rem;
    background: white;
    transition: all 0.2s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.rss-input:focus {
    outline: none;
    box-shadow: 0 4px 16px rgba(102, 126, 234, 0.2);
}

.load-btn, .download-btn {
    padding: 1rem 2rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
    font-size: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: 0 4px 16px rgba(102, 126, 234, 0.3);
}

.load-btn:hover, .download-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(102, 126, 234, 0.4);
}

.load-btn:active, .download-btn:active {
    transform: translateY(0);
}

.btn-icon {
    font-size: 1.2rem;
}

/* 支持的平台说明区域 */
.platforms-section {
    margin-bottom: 3rem;
}

.platforms-section h3 {
    font-size: 1.8rem;
    font-weight: 600;
    color: #1d1d1f;
    text-align: center;
    margin-bottom: 2rem;
}

.platforms-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.platform-item {
    background: white;
    padding: 2rem;
    border-radius: 16px;
    text-align: center;
    transition: all 0.3s ease;
    border: 1px solid #e9ecef;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05);
}

.platform-item:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.15);
    border-color: #667eea;
}

.platform-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    display: block;
}

.platform-item h4 {
    font-size: 1.2rem;
    font-weight: 600;
    color: #1d1d1f;
    margin-bottom: 0.5rem;
}

.platform-item p {
    color: #86868b;
    font-size: 0.9rem;
    line-height: 1.5;
}

/* 使用说明区域 */
.usage-section {
    margin-bottom: 2rem;
}

.usage-section h3 {
    font-size: 1.8rem;
    font-weight: 600;
    color: #1d1d1f;
    text-align: center;
    margin-bottom: 2rem;
}

.usage-steps {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.step-item {
    display: flex;
    align-items: flex-start;
    gap: 1.5rem;
    padding: 1.5rem;
    background: white;
    border-radius: 16px;
    border: 1px solid #e9ecef;
    transition: all 0.3s ease;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05);
}

.step-item:hover {
    transform: translateX(8px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    border-color: #667eea;
}

.step-number {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 1.1rem;
    flex-shrink: 0;
}

.step-content h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: #1d1d1f;
    margin-bottom: 0.5rem;
}

.step-content p {
    color: #86868b;
    line-height: 1.5;
}

/* 其他现有样式保持不变 */
.loading {
    text-align: center;
    margin: 2rem 0;
    color: #86868b;
}

.error {
    background: #fff2f2;
    border-radius: 12px;
    padding: 1.5rem;
    margin: 1rem 0;
    color: #ff3b30;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border: 1px solid #ffd6d6;
}

.retry-btn {
    background: #ff3b30;
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    margin-left: 1rem;
    transition: all 0.2s ease;
}

.retry-btn:hover {
    background: #ff2d55;
    transform: translateY(-1px);
}

.progress-item.error {
    background: #fff2f2;
}

.download-status {
    font-size: 0.9rem;
    color: #86868b;
    margin-top: 0.3rem;
}

.progress-item.error .download-status {
    color: #ff3b30;
}

.podcast-info {
    margin: 2rem 0;
    padding: 2rem;
    background: white;
    border-radius: 16px;
    border: 1px solid #e9ecef;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05);
}

.podcast-info h2 {
    font-size: 1.8rem;
    color: #1d1d1f;
    margin-bottom: 1rem;
}

.podcast-info p {
    color: #515154;
    line-height: 1.6;
}

.episodes-section {
    margin-top: 2rem;
}

.episodes-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding: 1.5rem;
    background: white;
    border-radius: 16px;
    border: 1px solid #e9ecef;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05);
}

.episodes-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.episode-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem;
    background: white;
    border-radius: 16px;
    transition: all 0.3s ease;
    border: 1px solid #e9ecef;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05);
}

.episode-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    border-color: #667eea;
}

.episode-info {
    flex: 1;
}

.episode-title {
    font-weight: 600;
    color: #1d1d1f;
    margin-bottom: 0.3rem;
}

.episode-date {
    font-size: 0.9rem;
    color: #86868b;
}

.download-progress {
    margin-top: 2rem;
    padding: 2rem;
    background: white;
    border-radius: 16px;
    border: 1px solid #e9ecef;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05);
}

.progress-item {
    margin-bottom: 1rem;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: #e9ecef;
    border-radius: 4px;
    overflow: hidden;
    margin-top: 0.5rem;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    width: 0%;
    transition: width 0.3s ease;
}

.hidden {
    display: none;
}

/* 语言切换按钮 */
.language-switcher {
    position: absolute;
    top: 2rem;
    right: 2rem;
    display: flex;
    gap: 0.5rem;
    z-index: 100;
}

.lang-btn {
    padding: 0.5rem 1rem;
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 20px;
    cursor: pointer;


    font-size: 0.9rem;
    color: #1d1d1f;
    transition: all 0.2s ease;
    backdrop-filter: blur(10px);
}

.lang-btn:hover {
    background: rgba(255, 255, 255, 1);
    transform: translateY(-1px);
}

.lang-btn.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-color: transparent;
}

/* 加载动画 */
.spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid #e9ecef;
    border-top-color: #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-right: 0.5rem;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* 响应式设计 */
@media (max-width: 768px) {
    .container {
        padding: 1rem;
    }

    .content-wrapper {
        padding: 2rem;
    }

    .header-section h1 {
        font-size: 2.2rem;
    }

    .input-section {
        flex-direction: column;
        gap: 1rem;
    }

    .load-btn, .download-btn {
        width: 100%;
        justify-content: center;
    }

    .platforms-grid {
        grid-template-columns: 1fr;
    }

    .step-item {
        flex-direction: column;
        text-align: center;
    }

    .step-number {
        margin: 0 auto 1rem;
    }

    .language-switcher {
        position: static;
        margin-bottom: 1rem;
        align-self: flex-end;
    }
}

@media (max-width: 480px) {
    .content-wrapper {
        padding: 1.5rem;
    }

    .header-section h1 {
        font-size: 1.8rem;
    }

    .site-description {
        font-size: 1rem;
    }

    .platform-item {
        padding: 1.5rem;
    }

    .step-item {
        padding: 1rem;
    }
}

/* RSS信息显示区域 */
.extracted-rss-info {
    background: white;
    border-radius: 16px;
    padding: 2rem;
    margin: 2rem 0;
    border: 1px solid #e9ecef;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05);
}

.rss-info-content h3 {
    margin: 0 0 1rem 0;
    color: #1d1d1f;
    font-size: 1.2rem;
    font-weight: 600;
}

.rss-urls {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.url-item {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.url-item label {
    font-weight: 500;
    color: #666;
    font-size: 0.9rem;
}

.url-text {
    background: #f8f9fa;
    padding: 1rem;
    border-radius: 8px;
    border: 1px solid #e9ecef;
    font-family: monospace;
    font-size: 0.9rem;
    word-break: break-all;
    color: #333;
}

.copy-btn {
    align-self: flex-start;
    padding: 0.5rem 1rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.8rem;
    transition: all 0.2s ease;
}

.copy-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

/* 手动下载链接样式 */
.manual-download-container {
    margin-top: 1rem;
    padding: 1.5rem;
    background: #fff8f0;
    border: 1px solid #ffd6a5;
    border-radius: 12px;
    font-size: 0.9rem;
}

.manual-download-tip {
    margin-bottom: 1rem;
    line-height: 1.4;
}

.manual-download-tip span:first-child {
    font-weight: 600;
}

.manual-download-link {
    margin-top: 0.5rem;
}

.download-link-direct {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 1.5rem;
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    color: #0066cc;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s ease;
    word-break: break-word;
    max-width: 100%;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.download-link-direct:hover {
    background: #f8f9fa;
    border-color: #0066cc;
    color: #004499;
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(0, 102, 204, 0.2);
}

.download-link-direct:active {
    background: #dcdcde;
} 