/* 科技风格 CSS 设计 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', 'Microsoft YaHei', sans-serif;
    background: linear-gradient(135deg, #0a0a0a 0%, #1a1a2e 50%, #16213e 100%);
    color: #ffffff;
    min-height: 100vh;
    overflow-x: hidden;
}

/* 科技网格背景 */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(rgba(0, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 50px 50px;
    z-index: -1;
    animation: gridMove 20s linear infinite;
}

@keyframes gridMove {
    0% { transform: translate(0, 0); }
    100% { transform: translate(50px, 50px); }
}

/* 容器样式 */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    position: relative;
}

/* 头部样式 */
header {
    text-align: center;
    margin-bottom: 40px;
    padding: 30px 0;
    border-bottom: 2px solid rgba(0, 255, 255, 0.3);
    position: relative;
}

header::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 2px;
    background: linear-gradient(90deg, transparent, #00ffff, transparent);
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 0.5; }
    50% { opacity: 1; }
}

h1 {
    font-size: 2.5rem;
    font-weight: 300;
    color: #00ffff;
    text-shadow: 0 0 20px rgba(0, 255, 255, 0.5);
    margin-bottom: 10px;
    letter-spacing: 2px;
}

.subtitle {
    font-size: 1.1rem;
    color: #888;
    font-weight: 300;
}

/* 主要内容区域 */
.main-content {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
    margin-bottom: 40px;
}

/* 卡片样式 */
.card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(0, 255, 255, 0.2);
    border-radius: 12px;
    padding: 30px;
    backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent, #00ffff, transparent);
    transition: left 0.5s ease;
}

.card:hover::before {
    left: 100%;
}

.card:hover {
    border-color: rgba(0, 255, 255, 0.5);
    box-shadow: 0 10px 30px rgba(0, 255, 255, 0.1);
    transform: translateY(-2px);
}

/* 输入区域 */
.input-section {
    margin-bottom: 30px;
}

.input-group {
    margin-bottom: 20px;
}

.input-group label {
    display: block;
    margin-bottom: 8px;
    color: #00ffff;
    font-weight: 500;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.btn-guide {
    display: inline-block;
    margin-top: 10px;
    background: linear-gradient(45deg, #ff6b6b, #ffd93d);
    border: none;
    padding: 10px 20px;
    color: #fff;
    font-weight: 500;
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.3s ease;
    text-align: center;
    width: 100%;
}

.btn-guide:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 107, 107, 0.4);
}

.btn-guide i {
    margin-right: 8px;
}

.password-guide {
    font-size: 0.9em;
    color: #00ffff;
    text-decoration: none;
    margin-left: 8px;
    transition: color 0.3s ease;
}

.password-guide:hover {
    color: #4ecdc4;
    text-decoration: underline;
}

input[type="text"], input[type="password"] {
    width: 100%;
    padding: 15px 20px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(0, 255, 255, 0.3);
    border-radius: 8px;
    color: #ffffff;
    font-size: 1rem;
    transition: all 0.3s ease;
    outline: none;
}

input[type="text"]:focus, input[type="password"]:focus {
    border-color: #00ffff;
    box-shadow: 0 0 15px rgba(0, 255, 255, 0.3);
    background: rgba(0, 0, 0, 0.5);
}

input::placeholder {
    color: #666;
}

/* 升级提示样式 */
.upgrade-text {
    color: gold;
    font-weight: bold;
}

/* 按钮样式 */
.btn {
    padding: 12px 30px;
    background: linear-gradient(45deg, #0066cc, #00ffff);
    border: none;
    border-radius: 8px;
    color: #ffffff;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.btn:hover::before {
    left: 100%;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(0, 255, 255, 0.3);
}

.btn:active {
    transform: translateY(0);
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

/* 使用次数区域样式 */
.usage-actions {
    display: flex;
    gap: 10px;
    align-items: center;
}

.btn-upgrade {
    background: linear-gradient(45deg, #ffd700, #ff8c00);
    text-decoration: none;
    font-size: 0.9rem;
    padding: 8px 15px;
}

.btn-upgrade:hover {
    background: linear-gradient(45deg, #ff8c00, #ffd700);
}

.btn-secondary {
    background: linear-gradient(45deg, #333, #555);
    border: 1px solid rgba(0, 255, 255, 0.3);
}

.btn-small {
    padding: 8px 16px;
    font-size: 0.8rem;
    min-width: auto;
}

/* 使用次数显示样式 */
.usage-info {
    margin-bottom: 30px;
    background: rgba(0, 20, 40, 0.6);
    border: 1px solid rgba(0, 255, 255, 0.2);
}

.usage-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 20px;
    padding: 15px;
}

.usage-item {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #ffffff;
    font-size: 0.9rem;
}

.usage-item i {
    color: #00ffff;
    width: 16px;
    text-align: center;
}

.usage-label {
    color: #cccccc;
    font-weight: 500;
}

.usage-count {
    color: #00ffff;
    font-weight: bold;
    font-size: 1.1rem;
    min-width: 30px;
    text-align: center;
}

.usage-total {
    color: #888888;
    font-size: 0.9rem;
}

.usage-refresh {
    margin-left: auto;
}

@media (max-width: 768px) {
    .usage-content {
        flex-direction: column;
        align-items: stretch;
        gap: 15px;
    }
    
    .usage-item {
        justify-content: space-between;
    }
    
    .usage-refresh {
        margin-left: 0;
        align-self: center;
    }
}

/* 文件列表样式 */
.file-list {
    margin-top: 30px;
}

.file-list-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(0, 255, 255, 0.2);
}

.file-list-header h3 {
    color: #00ffff;
    font-size: 1.2rem;
    font-weight: 500;
    margin: 0;
}

.file-actions {
    display: flex;
    gap: 10px;
}

.file-actions .btn {
    padding: 8px 16px;
    font-size: 0.9rem;
}

/* 面包屑导航 */
.breadcrumb {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
    padding: 10px 15px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 6px;
    border: 1px solid rgba(0, 255, 255, 0.1);
}

.breadcrumb-item {
    color: #888;
    font-size: 0.9rem;
    cursor: pointer;
    transition: color 0.3s ease;
}

.breadcrumb-item:hover {
    color: #00ffff;
}

.breadcrumb-item.active {
    color: #00ffff;
    font-weight: 500;
}

.breadcrumb-separator {
    margin: 0 8px;
    color: #555;
}

/* 页面信息 */
.page-info {
    color: #888;
    font-size: 0.9rem;
    padding: 0 15px;
}

.file-item {
    display: flex;
    align-items: center;
    padding: 15px;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(0, 255, 255, 0.1);
    border-radius: 8px;
    margin-bottom: 10px;
    transition: all 0.3s ease;
}

.file-item:hover {
    background: rgba(0, 255, 255, 0.05);
    border-color: rgba(0, 255, 255, 0.3);
}

/* 文件复选框样式 */
.file-checkbox {
    width: 40px;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-right: 10px;
    flex-shrink: 0;
}

.file-checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: #00ffff;
    cursor: pointer;
}

.file-checkbox input[type="checkbox"]:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.file-checkbox label {
    display: none;
}

.file-icon {
    width: 24px;
    height: 24px;
    margin-right: 15px;
    color: #00ffff;
    flex-shrink: 0;
}

.file-info {
    flex: 1;
}

.file-name {
    font-weight: 500;
    margin-bottom: 5px;
}

.file-size {
    font-size: 0.9rem;
    color: #888;
}

/* 加载动画 */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid rgba(0, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #00ffff;
    animation: spin 1s ease-in-out infinite;
}

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

/* 消息提示 */
.message {
    padding: 15px 20px;
    border-radius: 8px;
    margin: 15px 0;
    border-left: 4px solid;
}

.message.success {
    background: rgba(0, 255, 0, 0.1);
    border-color: #00ff00;
    color: #00ff00;
}

.message.error {
    background: rgba(255, 0, 0, 0.1);
    border-color: #ff0000;
    color: #ff6666;
}

.message.info {
    background: rgba(0, 255, 255, 0.1);
    border-color: #00ffff;
    color: #00ffff;
}

/* 隐藏元素 */
.hidden {
    display: none !important;
}

/* 分页样式 */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    margin: 20px 0;
}

.pagination .btn {
    padding: 8px 16px;
    font-size: 0.9rem;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .container {
        padding: 15px;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    .card {
        padding: 20px;
    }
    
    .file-item {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .file-icon {
        margin-bottom: 10px;
    }
}

/* 下载弹窗样式 */
.download-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.download-modal-content {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(0, 255, 255, 0.3);
    border-radius: 12px;
    padding: 0;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow: hidden;
    backdrop-filter: blur(15px);
    box-shadow: 0 20px 40px rgba(0, 255, 255, 0.1);
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from { transform: translateY(-50px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.download-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    border-bottom: 1px solid rgba(0, 255, 255, 0.2);
    background: rgba(0, 255, 255, 0.05);
}

.download-modal-header h3 {
    margin: 0;
    color: #00ffff;
    font-size: 1.2rem;
    font-weight: 500;
}

.download-modal-close {
    background: none;
    border: none;
    color: #888;
    font-size: 1.2rem;
    cursor: pointer;
    padding: 5px;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.download-modal-close:hover {
    color: #00ffff;
    background: rgba(0, 255, 255, 0.1);
}

.download-modal-body {
    padding: 20px 25px;
    max-height: 60vh;
    overflow-y: auto;
}

.download-modal-body::-webkit-scrollbar {
    width: 6px;
}

.download-modal-body::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 3px;
}

.download-modal-body::-webkit-scrollbar-thumb {
    background: rgba(0, 255, 255, 0.3);
    border-radius: 3px;
}

.download-modal-body::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 255, 255, 0.5);
}

.download-modal .download-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(0, 255, 255, 0.1);
    border-radius: 8px;
    margin-bottom: 10px;
    transition: all 0.3s ease;
}

.download-modal .download-item:hover {
    background: rgba(0, 255, 255, 0.05);
    border-color: rgba(0, 255, 255, 0.3);
}

.download-modal .download-item:last-child {
    margin-bottom: 0;
}

.download-modal .download-info {
    flex: 1;
    margin-right: 15px;
}

.download-modal .download-name {
    font-weight: 500;
    margin-bottom: 5px;
    color: #ffffff;
    word-break: break-all;
}

.download-modal .download-size {
    font-size: 0.9rem;
    color: #888;
}

.download-modal .download-actions {
    display: flex;
    gap: 10px;
    flex-shrink: 0;
}

.download-modal .download-actions .btn {
    padding: 8px 16px;
    font-size: 0.9rem;
    white-space: nowrap;
}

/* 科技感装饰元素 */
.tech-decoration {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 100px;
    height: 100px;
    border: 1px solid rgba(0, 255, 255, 0.2);
    border-radius: 50%;
    z-index: -1;
    animation: rotate 10s linear infinite;
}

.tech-decoration::before {
    content: '';
    position: absolute;
    top: 10px;
    left: 10px;
    right: 10px;
    bottom: 10px;
    border: 1px solid rgba(0, 255, 255, 0.1);
    border-radius: 50%;
}

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

/* 悬浮框样式 */
.floating-alert {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10000;
    max-width: 500px;
    min-width: 300px;
    animation: floatingAlertShow 0.3s ease-out;
}

.floating-alert-content {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    border: 2px solid #ff6b6b;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 
        0 10px 30px rgba(255, 107, 107, 0.3),
        0 0 50px rgba(255, 107, 107, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    gap: 15px;
    position: relative;
    backdrop-filter: blur(10px);
}

.floating-alert.success .floating-alert-content {
    border-color: #4ecdc4;
    box-shadow: 
        0 10px 30px rgba(78, 205, 196, 0.3),
        0 0 50px rgba(78, 205, 196, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.floating-alert.info .floating-alert-content {
    border-color: #45b7d1;
    box-shadow: 
        0 10px 30px rgba(69, 183, 209, 0.3),
        0 0 50px rgba(69, 183, 209, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.floating-alert-content i {
    font-size: 24px;
    flex-shrink: 0;
}

.floating-alert.error .floating-alert-content i {
    color: #ff6b6b;
    text-shadow: 0 0 10px rgba(255, 107, 107, 0.5);
}

.floating-alert.success .floating-alert-content i {
    color: #4ecdc4;
    text-shadow: 0 0 10px rgba(78, 205, 196, 0.5);
}

.floating-alert.info .floating-alert-content i {
    color: #45b7d1;
    text-shadow: 0 0 10px rgba(69, 183, 209, 0.5);
}

.floating-alert-message {
    flex: 1;
    font-size: 16px;
    line-height: 1.5;
    color: #ffffff;
    font-weight: 500;
}

.floating-alert-close {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.6);
    font-size: 18px;
    cursor: pointer;
    padding: 5px;
    border-radius: 50%;
    transition: all 0.3s ease;
    flex-shrink: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.floating-alert-close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    transform: scale(1.1);
}

@keyframes floatingAlertShow {
    0% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.8);
    }
    100% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
}

/* 悬浮框脉冲动画 */
.floating-alert.error .floating-alert-content {
    animation: errorPulse 2s ease-in-out infinite;
}

@keyframes errorPulse {
    0%, 100% {
        box-shadow: 
            0 10px 30px rgba(255, 107, 107, 0.3),
            0 0 50px rgba(255, 107, 107, 0.1),
            inset 0 1px 0 rgba(255, 255, 255, 0.1);
    }
    50% {
        box-shadow: 
            0 10px 30px rgba(255, 107, 107, 0.5),
            0 0 50px rgba(255, 107, 107, 0.2),
            inset 0 1px 0 rgba(255, 255, 255, 0.1);
    }
}

/* 下载器推荐提示样式 */
.download-tip {
    background: linear-gradient(135deg, rgba(255, 193, 7, 0.1) 0%, rgba(255, 152, 0, 0.1) 100%);
    border: 1px solid rgba(255, 193, 7, 0.3);
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 20px;
    position: relative;
    overflow: hidden;
}

.download-tip::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 193, 7, 0.1), transparent);
    animation: tipShine 3s ease-in-out infinite;
}

.tip-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    font-weight: 600;
    color: #ffc107;
}

.tip-header i {
    font-size: 16px;
    animation: tipPulse 2s ease-in-out infinite;
}

.tip-content {
    color: rgba(255, 255, 255, 0.9);
    font-size: 14px;
    line-height: 1.5;
    position: relative;
    z-index: 1;
}

.tip-content strong {
    color: #ffc107;
    font-weight: 600;
}

@keyframes tipShine {
    0% {
        left: -100%;
    }
    50% {
        left: 100%;
    }
    100% {
        left: 100%;
    }
}

@keyframes tipPulse {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.1);
        opacity: 0.8;
    }
}