/* 以下为 index.html 和 index_video.html 合并后的样式 */
:root {
    --primary-color: #6366f1;
    --secondary-color: #4f46e5;
    --background-color: #f8fafc;
    --card-background: #ffffff;
    --text-color: #1e293b;
    --border-color: #e2e8f0;
    --text-secondary-color: #64748b;
    --hover-color: #f1f5f9;
}
body {
    background-color: var(--background-color);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color: var(--text-color);
    line-height: 1.6;
}
.main-container {
    max-width: 1100px;
    margin: 1rem auto;
    padding: 0.5rem;
}
.header {
    text-align: center;
    margin-bottom: 1.5rem;
}
.header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-top: 1.5rem;
    margin-bottom: 0.5rem;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}
.header p {
    font-size: 1.1rem;
    color: var(--text-secondary-color);
    max-width: 600px;
    margin: 0 auto;
}
.expiry-notice {
    font-size: 0.9rem;
    color: var(--text-secondary-color);
    margin-top: 0.5rem;
    padding: 0.5rem 1rem;
    background-color: rgba(99, 102, 241, 0.1);
    border-radius: 8px;
    display: inline-block;
}
.generation-container {
    background: var(--card-background);
    border-radius: 20px;
    padding: 1.5rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    margin-bottom: 1.5rem;
}
.prompt-input {
    width: 100%;
    padding: 0.8rem;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    resize: none;
}
.prompt-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}
.controls-container {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 0.8rem;
    margin-bottom: 1rem;
}
.tasks-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-top: 2rem;
    margin-bottom: 2rem;
}
@media (max-width: 1200px) {
    .controls-container {
        grid-template-columns: repeat(4, 1fr);
    }
}
@media (max-width: 992px) {
    .controls-container {
        grid-template-columns: repeat(3, 1fr);
    }
    .tasks-container {
        grid-template-columns: repeat(2, 1fr);
    }
}
@media (max-width: 768px) {
    .controls-container {
        grid-template-columns: repeat(2, 1fr);
    }
    .tasks-container {
        grid-template-columns: repeat(1, 1fr);
    }
    .example-item img, .example-item video {
        height: auto;
        max-height: 300px;
        object-fit: contain;
    }
    .examples-container {
        column-count: 2;
    }
}
@media (max-width: 576px) {
    .controls-container {
        grid-template-columns: 1fr;
    }
    .examples-container {
        column-count: 1;
    }
}
.control-group {
    min-width: 0;
    position: relative;
}
.control-group label {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    margin-bottom: 0.3rem;
    font-weight: 500;
    color: var(--text-secondary-color);
    font-size: 0.9rem;
}
.info-tooltip {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background-color: var(--text-secondary-color);
    color: white;
    font-size: 0.7rem;
    cursor: help;
    transition: all 0.2s ease;
}
.info-tooltip:hover {
    background-color: var(--primary-color);
}
.info-tooltip .tooltip-text {
    visibility: hidden;
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    padding: 0.5rem 0.8rem;
    background-color: var(--text-color);
    color: white;
    text-align: center;
    border-radius: 6px;
    font-size: 0.8rem;
    white-space: nowrap;
    z-index: 100;
    opacity: 0;
    transition: opacity 0.2s ease;
    margin-bottom: 0.5rem;
}
.info-tooltip .tooltip-text::after {
    content: "";
    position: absolute;
    top: 100%;
    left: 50%;
    margin-left: -5px;
    border-width: 5px;
    border-style: solid;
    border-color: var(--text-color) transparent transparent transparent;
}
.info-tooltip:hover .tooltip-text {
    visibility: visible;
    opacity: 1;
}
/* Custom Dropdown Styles */
.custom-dropdown {
    position: relative;
    width: 100%;
}
.dropdown-header {
    display: flex;
    align-items: center;
    padding: 0.5rem 0.7rem;
    background: var(--background-color);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    justify-content: space-between;
    height: 32px;
    box-sizing: border-box;
}
.dropdown-header:hover {
     border-color: var(--primary-color);
}
.dropdown-header .selected-value {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    font-size: 0.85rem;
    color: var(--text-color);
    height: 20px;
    line-height: 1;
}
.dropdown-header .selected-value svg {
    width: 14px;
    height: 14px;
    flex-shrink: 0;
    display: block;
}
.dropdown-header .arrow-icon {
    transition: transform 0.3s ease;
}
.dropdown-header.open .arrow-icon {
    transform: rotate(180deg);
}
/* Icon Styles */
.dropdown-item i.bi, .selected-value i.bi {
    font-size: 1.2rem;
    color: var(--text-color);
    flex-shrink: 0;
}
/* Aspect Ratio Icon Styles (different size) */
.aspect-ratio-dropdown .dropdown-item i.bi,
.aspect-ratio-dropdown .selected-value i.bi {
    font-size: 1.5rem;
}
.dropdown-list {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--card-background);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    margin-top: 0.5rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    z-index: 10;
    overflow: hidden;
    display: none;
}
.dropdown-list .dropdown-item {
    display: flex;
    align-items: center;
    padding: 0.4rem 0.8rem;
    gap: 0.6rem;
    cursor: pointer;
    transition: background-color 0.2s ease;
    height: 32px;
    box-sizing: border-box;
}
.dropdown-list .dropdown-item svg {
    width: 14px;
    height: 14px;
    flex-shrink: 0;
    display: block;
}
.dropdown-list .dropdown-item span {
    line-height: 1;
    font-size: 0.85rem;
}
.dropdown-list .dropdown-item:hover {
    background-color: var(--hover-color);
}
.generate-btn {
    width: 100%;
    padding: 0.8rem;
    font-size: 1.1rem;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border: none;
    border-radius: 12px;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}
.generate-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.2);
}
.generate-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}
.task-item {
    background: var(--card-background);
    border-radius: 16px;
    padding: 1.25rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}
.task-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 12px -1px rgba(0, 0, 0, 0.1);
}
.task-prompt {
    margin-bottom: 0.75rem;
    font-style: italic;
    color: var(--text-secondary-color);
    font-size: 0.9rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}
.status-badge {
    font-size: 0.85rem;
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-weight: 500;
    color: white;
}
.status-badge.bg-success {
    background-color: #059669 !important;
}
.status-badge.bg-warning {
    background-color: #d97706 !important;
    color: white !important;
}
.status-badge.bg-primary {
    background-color: #2563eb !important;
}
.status-badge.bg-danger {
    background-color: #dc2626 !important;
}
.task-link {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
}
.task-link:hover {
    color: var(--secondary-color);
}
.loading {
    display: none;
    text-align: center;
    padding: 2rem;
}
.loading-spinner {
    width: 3rem;
    height: 3rem;
    color: var(--primary-color);
}
/* 添加浮窗样式 */
.turnstile-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    z-index: 1000;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}
.turnstile-modal.active {
    display: flex;
    opacity: 1;
}
.turnstile-container {
    background: var(--card-background);
    padding: 2.5rem;
    border-radius: 1.5rem;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    text-align: center;
    transform: translateY(20px);
    transition: transform 0.3s ease;
    max-width: 90%;
    width: 400px;
}
.turnstile-modal.active .turnstile-container {
    transform: translateY(0);
}
.turnstile-container h4 {
    margin-bottom: 1.5rem;
    color: var(--text-color);
    font-size: 1.25rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}
.turnstile-container h4::before {
    content: '';
    display: inline-block;
    width: 8px;
    height: 8px;
    background-color: var(--primary-color);
    border-radius: 50%;
    animation: pulse 1.5s infinite;
}
.turnstile-container .cf-turnstile {
    margin: 1rem 0;
    display: flex;
    justify-content: center;
}
@keyframes pulse {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.5);
        opacity: 0.5;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}
/* 广告提示浮窗样式 */
.ad-notice-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    z-index: 1000;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}
.ad-notice-modal.active {
    display: flex;
    opacity: 1;
}
.ad-notice-container {
    background: var(--card-background);
    padding: 2rem;
    border-radius: 1.5rem;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    text-align: center;
    transform: translateY(20px);
    transition: transform 0.3s ease;
    max-width: 90%;
    width: 400px;
}
.ad-notice-modal.active .ad-notice-container {
    transform: translateY(0);
}
.ad-notice-container h4 {
    margin-bottom: 1rem;
    color: var(--text-color);
    font-size: 1.25rem;
    font-weight: 600;
}
.ad-notice-container p {
    color: var(--text-secondary-color);
    margin-bottom: 1.5rem;
    line-height: 1.6;
}
.ad-notice-container .btn {
    padding: 0.8rem 1.5rem;
    font-size: 1rem;
    border-radius: 8px;
    transition: all 0.3s ease;
}
.ad-notice-container .btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border: none;
}
.ad-notice-container .btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.2);
}

.important-notice {
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    color: #92400e;
    font-size: 0.9rem;
    margin-top: 0.5rem;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    display: inline-block;
}
/* 示例展示区域样式 */
.examples-container {
    margin-bottom: 0.5rem;
    column-count: 3;
    column-gap: 1rem;
}
.examples-container h2 {
    color: var(--text-color);
    font-weight: 600;
    margin-bottom: 2rem;
}
.example-item {
    background: var(--card-background);
    border-radius: 16px;
    padding: 1rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    display: inline-block;
    width: 100%;
    margin-bottom: 1rem;
    break-inside: avoid;
}
.example-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 12px -1px rgba(0, 0, 0, 0.1);
}
.example-item img {
    width: 100%;
    height: auto;
    object-fit: contain;
    border-radius: 12px;
    margin-bottom: 1rem;
}
.example-item video {
    width: 100%;
    height: auto;
    border-radius: 12px;
    margin-bottom: 1rem;
}
.example-prompt {
    color: var(--text-secondary-color);
    font-size: 0.9rem;
    line-height: 1.5;
    flex-grow: 1;
    padding: 0.5rem;
    background: var(--background-color);
    border-radius: 8px;
    text-align: center;
}
@media (max-width: 768px) {
    .examples-container {
        column-count: 2;
    }
}
@media (max-width: 576px) {
    .examples-container {
        column-count: 1;
    }
}
.copyright-notice {
    text-align: center;
    margin-bottom: 2rem;
    margin-top: 0.5rem;
}
/* 导航栏样式 */
.nav-tabs {
    border-bottom: 2px solid var(--border-color);
    margin-bottom: 0.5rem;
}
.nav-tabs .nav-link {
    border: none;
    color: var(--text-secondary-color);
    font-weight: 500;
    padding: 1rem 1.5rem;
    border-radius: 12px 12px 0 0;
    transition: all 0.3s ease;
}
.nav-tabs .nav-link:hover {
    color: var(--primary-color);
    background-color: var(--hover-color);
}
.nav-tabs .nav-link.active {
    color: var(--primary-color);
    background-color: var(--card-background);
    border-bottom: 3px solid var(--primary-color);
}
.task-error {
    color: #dc2626;
    background: #fee2e2;
    border-radius: 8px;
    padding: 0.5rem 0.8rem;
    margin-top: 0.5rem;
    font-size: 0.92rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    word-break: break-all;
}
.task-error i {
    font-size: 1.2rem;
    margin-right: 0.3rem;
} 