/**
 * 夸克直链解析器样式
 */

/* 容器 */
.qlp-container {
    max-width: 800px;
    margin: 20px auto;
    padding: 25px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(102, 126, 234, 0.3);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.qlp-container[data-theme="dark"] {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
}

/* 头部 */
.qlp-header {
    text-align: center;
    color: #fff;
    margin-bottom: 25px;
}

.qlp-header h3 {
    margin: 0 0 10px 0;
    font-size: 24px;
    font-weight: 600;
}

.qlp-header p {
    margin: 0;
    opacity: 0.9;
    font-size: 14px;
}

/* 表单 */
.qlp-form {
    background: rgba(255, 255, 255, 0.95);
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.qlp-input-group {
    margin-bottom: 15px;
}

.qlp-input {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 15px;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.qlp-input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.2);
}

/* 按钮 */
.qlp-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    border: none;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
}

.qlp-btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    width: 100%;
}

.qlp-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

.qlp-btn-success {
    background: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
    color: #fff;
}

.qlp-btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(56, 239, 125, 0.4);
}

.qlp-btn-small {
    padding: 8px 16px;
    font-size: 13px;
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.qlp-btn-small:hover {
    background: rgba(255, 255, 255, 0.3);
}

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

/* 文件列表 */
.qlp-file-list {
    margin-top: 20px;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 12px;
    overflow: hidden;
}

.qlp-file-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
}

.qlp-file-header h4 {
    margin: 0;
    font-size: 16px;
}

.qlp-file-table {
    overflow-x: auto;
}

.qlp-file-table table {
    width: 100%;
    border-collapse: collapse;
}

.qlp-file-table th,
.qlp-file-table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

.qlp-file-table th {
    background: #f8f9fa;
    font-weight: 600;
    color: #333;
    font-size: 13px;
}

.qlp-file-table tr:hover {
    background: #f8f9ff;
}

.qlp-file-table .file-name {
    max-width: 300px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.qlp-file-table .folder-link {
    color: #667eea;
    cursor: pointer;
    text-decoration: none;
}

.qlp-file-table .folder-link:hover {
    text-decoration: underline;
}

.qlp-file-table .btn-get-link {
    padding: 6px 12px;
    font-size: 12px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.qlp-file-table .btn-get-link:hover {
    transform: scale(1.05);
}

.qlp-file-table .btn-get-link:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* 结果区 */
.qlp-result {
    margin-top: 20px;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 12px;
    overflow: hidden;
}

.qlp-result-header {
    padding: 15px 20px;
    background: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
    color: #fff;
}

.qlp-result-header h4 {
    margin: 0;
    font-size: 16px;
}

.qlp-result-info {
    padding: 15px 20px;
    border-bottom: 1px solid #eee;
}

.qlp-result-info p {
    margin: 5px 0;
    font-size: 14px;
    color: #333;
}

.qlp-result-url {
    padding: 20px;
}

.qlp-result-url textarea {
    width: 100%;
    height: 80px;
    padding: 12px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 13px;
    font-family: monospace;
    resize: none;
    box-sizing: border-box;
}

.qlp-result-actions {
    display: flex;
    gap: 10px;
    padding: 0 20px 20px;
}

.qlp-result-actions .qlp-btn {
    flex: 1;
}

/* 错误提示 */
.qlp-error {
    margin-top: 20px;
    padding: 15px 20px;
    background: linear-gradient(135deg, #ff416c 0%, #ff4b2b 100%);
    color: #fff;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.qlp-error-icon {
    font-size: 20px;
}

.qlp-error-text {
    font-size: 14px;
}

/* 状态信息 */
.qlp-status {
    margin-top: 20px;
    padding: 15px 20px;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 12px;
    text-align: center;
}

.qlp-status-text {
    color: #667eea;
    font-size: 14px;
}

/* 加载动画 */
.qlp-loading {
    animation: qlp-pulse 1.5s ease-in-out infinite;
}

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

/* 响应式 */
@media (max-width: 600px) {
    .qlp-container {
        margin: 10px;
        padding: 15px;
    }
    
    .qlp-header h3 {
        font-size: 20px;
    }
    
    .qlp-result-actions {
        flex-direction: column;
    }
    
    .qlp-file-table th:nth-child(2),
    .qlp-file-table td:nth-child(2),
    .qlp-file-table th:nth-child(3),
    .qlp-file-table td:nth-child(3) {
        display: none;
    }
}
