/**
 * 高级搜索页面（search）专用样式
 * 现代化、响应式的搜索界面设计
 */

/* 重置和基础样式 */
.advanced-search-page * {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

.advanced-search-page {
    min-height: 100vh;
    position: relative;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #520049 100%);
    overflow-x: hidden;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* 动态背景效果 */
.dynamic-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    background: linear-gradient(45deg, 
        rgba(102, 126, 234, 0.1) 0%, 
        rgba(118, 75, 162, 0.1) 25%,
        rgba(82, 0, 73, 0.1) 50%,
        rgba(102, 126, 234, 0.1) 75%,
        rgba(118, 75, 162, 0.1) 100%);
    background-size: 400% 400%;
    animation: gradientShift 10s ease infinite;
}

@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.bg-animation {
    position: absolute;
    width: 200%;
    height: 200%;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><circle cx="25" cy="25" r="2" fill="rgba(255,255,255,0.1)"/><circle cx="75" cy="75" r="1.5" fill="rgba(255,255,255,0.08)"/><circle cx="50" cy="10" r="1" fill="rgba(255,255,255,0.06)"/></svg>');
    animation: float 20s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateX(-50px) translateY(-50px) rotate(0deg); }
    25% { transform: translateX(-100px) translateY(-30px) rotate(90deg); }
    50% { transform: translateX(-80px) translateY(-100px) rotate(180deg); }
    75% { transform: translateX(-30px) translateY(-80px) rotate(270deg); }
}

.dna-helix {
    position: absolute;
    top: 50%;
    right: -100px;
    width: 200px;
    height: 400px;
    opacity: 0.1;
    transform: translateY(-50%);
    animation: rotate 30s linear infinite;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><path d="M10,50 Q30,10 50,50 Q70,90 90,50" stroke="white" stroke-width="2" fill="none"/><path d="M10,50 Q30,90 50,50 Q70,10 90,50" stroke="white" stroke-width="1" fill="none" opacity="0.5"/></svg>') no-repeat center;
    background-size: contain;
}

@keyframes rotate {
    0% { transform: translateY(-50%) rotate(0deg); }
    100% { transform: translateY(-50%) rotate(360deg); }
}

/* 搜索界面主体 */
.search-interface {
    position: relative;
    z-index: 10;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* 头部区域 */
.search-header {
    text-align: center;
    margin-bottom: 40px;
    padding: 40px 0;
    position: relative;
}

.logo-section {
    color: white;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.logo-icon {
    font-size: 60px;
    margin-bottom: 20px;
    color: rgba(255, 255, 255, 0.9);
    animation: pulse 2s ease-in-out infinite, glow 3s ease-in-out infinite alternate;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

@keyframes glow {
    0% { 
        filter: drop-shadow(0 0 5px rgba(255, 255, 255, 0.3));
    }
    100% { 
        filter: drop-shadow(0 0 20px rgba(255, 255, 255, 0.6)) drop-shadow(0 0 30px rgba(102, 126, 234, 0.4));
    }
}

.search-title {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 15px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    background: linear-gradient(45deg, #ffffff, #e0e7ff, #ffffff);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: titleShimmer 4s ease-in-out infinite;
}

@keyframes titleShimmer {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.search-subtitle {
    font-size: 1.2rem;
    opacity: 0.9;
    font-weight: 300;
    margin-bottom: 0;
}

/* 搜索工具栏 */
.search-toolbar {
    margin-bottom: 30px;
}

.main-search-container {
    position: relative;
    margin-bottom: 20px;
}

.search-input-outer {
    margin-bottom: 25px;
    background: none !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    padding: 0 !important;
}

.search-input-wrapper {
    position: relative;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 50px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    padding: 0 20px;
    backdrop-filter: blur(10px);
    border: 2px solid transparent;
}

.search-input-wrapper:focus-within {
    background: rgba(255, 255, 255, 1);
    border-color: rgba(102, 126, 234, 0.5);
}

.search-icon {
    color: #666;
    font-size: 20px;
    margin-right: 15px;
}

.search-input-wrapper:focus-within .search-icon {
    color: #520049;
}

.main-search-input {
    flex: 1;
    border: none;
    outline: none;
    padding: 20px 0;
    font-size: 18px;
    background: transparent;
    color: #333;
}

.main-search-input::placeholder {
    color: #999;
}

.search-clear-btn {
    background: none;
    border: none;
    color: #666;
    font-size: 18px;
    cursor: pointer;
    padding: 5px;
    opacity: 0;
    transition: all 0.3s ease;
    border-radius: 50%;
}

.search-clear-btn.visible {
    opacity: 1;
}

.search-clear-btn:hover {
    color: #520049;
    background: rgba(82, 0, 73, 0.1);
    transform: scale(1.1);
}

/* 搜索建议 */
.search-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
    display: none;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.suggestion-item {
    padding: 15px 20px;
    cursor: pointer;
    transition: all 0.2s ease;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.suggestion-item:hover {
    background: linear-gradient(90deg, rgba(102, 126, 234, 0.1), rgba(118, 75, 162, 0.1));
    transform: translateX(5px);
}

.suggestion-item:last-child {
    border-bottom: none;
    border-radius: 0 0 20px 20px;
}

.suggestion-item:first-child {
    border-radius: 20px 20px 0 0;
}

/* 快速搜索类型 */
.quick-search-types {
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}

.search-type-btn {
    background: rgba(255, 255, 255, 0.15);
    border: 2px solid rgba(255, 255, 255, 0.3);
    color: white;
    padding: 12px 20px;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
    backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
}

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

.search-type-btn:hover::before,
.search-type-btn.active::before {
    left: 100%;
}

.search-type-btn:hover,
.search-type-btn.active {
    background: rgba(255, 255, 255, 0.95);
    color: #520049;
    border-color: rgba(255, 255, 255, 0.8);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.search-type-btn i {
    transition: transform 0.3s ease;
}

.search-type-btn:hover i {
    transform: scale(1.2) rotate(5deg);
}

/* 高级筛选面板 */
.advanced-filters {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    margin-bottom: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    overflow: hidden;
}

.filters-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    background: linear-gradient(90deg, rgba(102, 126, 234, 0.05), rgba(118, 75, 162, 0.05));
}

.filters-header h3 {
    color: #333;
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0;
    font-size: 18px;
    font-weight: 600;
}

.filters-header h3 i {
    color: #520049;
}

.toggle-filters-btn {
    background: none;
    border: none;
    color: #666;
    font-size: 18px;
    cursor: pointer;
    padding: 8px;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.toggle-filters-btn:hover {
    color: #520049;
    background: rgba(82, 0, 73, 0.1);
    transform: scale(1.1);
}

.filter-content.collapsed {
    max-height: 0 !important;
    padding: 0 !important;
    opacity: 0;
    display: none !important;
    transition: all 0.3s;
}
.filter-content {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    transition: max-height 0.3s, opacity 0.3s;
}

.filter-groups {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 25px;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.filter-label {
    font-weight: 600;
    color: #333;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
}

.filter-label i {
    color: #520049;
    width: 16px;
}

.range-inputs {
    display: flex;
    align-items: center;
    gap: 10px;
}

.range-inputs input {
    flex: 1;
    padding: 10px 12px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.8);
}

.range-inputs input:focus {
    outline: none;
    border-color: #520049;
    box-shadow: 0 0 0 3px rgba(82, 0, 73, 0.1);
    background: rgba(255, 255, 255, 1);
}

.range-separator {
    color: #666;
    font-weight: 500;
    padding: 0 5px;
}

.filter-select {
    padding: 10px 12px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    background: rgba(255, 255, 255, 0.8);
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-select:focus {
    outline: none;
    border-color: #520049;
    box-shadow: 0 0 0 3px rgba(82, 0, 73, 0.1);
    background: rgba(255, 255, 255, 1);
}

.filter-actions {
    display: flex;
    justify-content: center;
    gap: 15px;
    padding-top: 20px;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
}

.btn-primary,
.btn-secondary {
    padding: 12px 25px;
    border: none;
    border-radius: 25px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 500;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: linear-gradient(45deg, #520049, #667eea);
    color: white;
    box-shadow: 0 4px 15px rgba(82, 0, 73, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(82, 0, 73, 0.4);
}

.btn-secondary {
    background: linear-gradient(45deg, #6c757d, #8a92a3);
    color: white;
    box-shadow: 0 4px 15px rgba(108, 117, 125, 0.3);
}

.btn-secondary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(108, 117, 125, 0.4);
}

/* 搜索结果区域 */
.search-results-area {
    flex: 1;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.results-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    flex-wrap: wrap;
    gap: 15px;
    background: linear-gradient(90deg, rgba(102, 126, 234, 0.05), rgba(118, 75, 162, 0.05));
}

.results-stats {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.results-count {
    font-weight: 600;
    color: #333;
    font-size: 16px;
}

.search-time {
    font-size: 12px;
    color: #666;
}

.results-controls {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.sort-options {
    display: flex;
    align-items: center;
    gap: 10px;
}

.sort-options label {
    font-weight: 500;
    color: #666;
    font-size: 14px;
}

.sort-select {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    background: white;
    transition: all 0.3s ease;
}

.sort-select:focus {
    outline: none;
    border-color: #520049;
    box-shadow: 0 0 0 2px rgba(82, 0, 73, 0.1);
}

.view-options {
    display: flex;
    gap: 5px;
    background: rgba(0, 0, 0, 0.05);
    border-radius: 8px;
    padding: 4px;
}

.view-btn {
    background: transparent;
    border: none;
    color: #666;
    padding: 8px 10px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.view-btn.active,
.view-btn:hover {
    background: white;
    color: #520049;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transform: translateY(-1px);
}

.export-btn {
    background: linear-gradient(45deg, #28a745, #34ce57);
    color: white;
    border: none;
    padding: 8px 15px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 14px;
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.3);
}

.export-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(40, 167, 69, 0.4);
}

/* 搜索占位符 */
.search-placeholder {
    text-align: center;
    padding: 80px 20px;
    color: #666;
}

.placeholder-content {
    max-width: 500px;
    margin: 0 auto;
}

.placeholder-icon {
    font-size: 80px;
    color: #ddd;
    margin-bottom: 30px;
    animation: float-gentle 3s ease-in-out infinite;
}

@keyframes float-gentle {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

.placeholder-content h3 {
    font-size: 24px;
    margin-bottom: 15px;
    color: #333;
    font-weight: 600;
}

.placeholder-content p {
    font-size: 16px;
    margin-bottom: 30px;
    line-height: 1.6;
    color: #666;
}

.search-examples h4 {
    font-size: 16px;
    margin-bottom: 15px;
    color: #333;
    font-weight: 600;
}

.example-tags {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
}

.example-tag {
    background: linear-gradient(45deg, #f8f9fa, #e9ecef);
    color: #520049;
    padding: 8px 15px;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    font-size: 14px;
    font-weight: 500;
}

.example-tag:hover {
    background: linear-gradient(45deg, #520049, #667eea);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(82, 0, 73, 0.3);
    border-color: rgba(255, 255, 255, 0.2);
}

/* 加载状态 */
.loading-state {
    text-align: center;
    padding: 80px 20px;
}

.loading-spinner {
    display: inline-block;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #520049;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loading-spinner p {
    color: #666;
    font-size: 16px;
    margin: 0;
}

/* 结果列表样式 */
.results-container {
    min-height: 400px;
}

.results-list {
    padding: 25px;
}

/* 分页样式 */
.pagination-container {
    padding: 20px 25px;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    background: rgba(0, 0, 0, 0.02);
}

.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
}

.page-btn {
    background: white;
    border: 2px solid #ddd;
    color: #666;
    padding: 10px 15px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 5px;
    font-weight: 500;
}

.page-btn:hover:not(:disabled) {
    border-color: #520049;
    color: #520049;
    background: rgba(82, 0, 73, 0.05);
    transform: translateY(-1px);
}

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

.page-numbers {
    display: flex;
    gap: 5px;
}

.page-number {
    background: white;
    border: 2px solid #ddd;
    color: #666;
    padding: 10px 15px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 40px;
    text-align: center;
    font-weight: 500;
}

.page-number.active {
    background: linear-gradient(45deg, #520049, #667eea);
    border-color: #520049;
    color: white;
    box-shadow: 0 4px 15px rgba(82, 0, 73, 0.3);
}

.page-number:hover:not(.active) {
    border-color: #520049;
    color: #520049;
    background: rgba(82, 0, 73, 0.05);
    transform: translateY(-1px);
}

.page-ellipsis {
    padding: 10px 15px;
    color: #666;
    font-weight: 500;
}

/* 浮动操作按钮 */
.floating-actions {
    position: fixed;
    bottom: 30px;
    right: 30px;
    display: flex;
    flex-direction: column;
    gap: 15px;
    z-index: 1000;
}

.fab-btn {
    width: 50px;
    height: 50px;
    background: linear-gradient(45deg, #520049, #667eea);
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(82, 0, 73, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.fab-btn:hover {
    transform: translateY(-3px) scale(1.1);
    box-shadow: 0 8px 25px rgba(82, 0, 73, 0.6);
    background: linear-gradient(45deg, #3d0037, #520049);
}

/* 响应式设计 */
@media (max-width: 1024px) {
    .search-interface {
        padding: 15px;
    }
    
    .filter-groups {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    }
}

@media (max-width: 768px) {
    .search-title {
        font-size: 2rem;
    }

    .search-subtitle {
        font-size: 1rem;
    }

    .main-search-input {
        font-size: 16px;
        padding: 15px 0;
    }

    .filter-groups {
        grid-template-columns: 1fr;
    }

    .results-header {
        flex-direction: column;
        align-items: stretch;
    }

    .results-controls {
        justify-content: center;
    }

    .quick-search-types {
        justify-content: center;
    }

    .search-type-btn {
        font-size: 12px;
        padding: 10px 16px;
    }

    .floating-actions {
        bottom: 20px;
        right: 20px;
    }

    .pagination {
        flex-wrap: wrap;
    }

    .filter-actions {
        flex-direction: column;
    }

    .btn-primary,
    .btn-secondary {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .search-header {
        padding: 20px 0;
    }

    .logo-icon {
        font-size: 40px;
    }

    .search-title {
        font-size: 1.5rem;
    }

    .search-subtitle {
        font-size: 0.9rem;
    }

    .example-tags {
        flex-direction: column;
        align-items: center;
    }

    .example-tag {
        width: 100%;
        max-width: 200px;
        text-align: center;
    }

    .search-input-wrapper {
        padding: 0 15px;
    }

    .main-search-input {
        font-size: 14px;
    }

    .results-controls {
        flex-direction: column;
        gap: 10px;
    }

    .view-options {
        order: -1;
        align-self: center;
    }
}

/* 深色模式支持 */
@media (prefers-color-scheme: dark) {
    .search-input-wrapper {
        background: rgba(30, 30, 30, 0.95);
        color: #e0e0e0;
    }

    .advanced-filters {
        background: rgba(30, 30, 30, 0.95);
    }

    .search-results-area {
        background: rgba(30, 30, 30, 0.95);
        color: #e0e0e0;
    }
}

/* 打印样式 */
@media print {
    .floating-actions,
    .dynamic-background,
    .search-toolbar,
    .filters-header {
        display: none !important;
    }

    .search-results-area {
        box-shadow: none;
        background: white;
    }

    .advanced-search-page {
        background: white;
    }

    .dynamic-background {
        display: none;
    }
}

/* 高对比度模式 */
@media (prefers-contrast: high) {
    .search-input-wrapper {
        border: 3px solid #000;
        background: #fff;
    }

    .btn-primary {
        background: #000;
        border: 2px solid #000;
    }

    .search-type-btn.active {
        background: #000;
        color: #fff;
        border: 2px solid #000;
    }
}

/* 减少动画效果 */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .logo-icon,
    .placeholder-icon,
    .bg-animation {
        animation: none;
    }
}

/* 关键词高亮样式 */
.keyword-highlight {
    background-color: #fff3cd;
    color: #856404;
    font-weight: bold;
    padding: 2px 1px;
    border-radius: 2px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

/* 序列内容样式 */
.sequence-content {
    margin-top: 6px;
    max-width: 100%;
    overflow-wrap: break-word;
    word-break: break-all;
    line-height: 1.5;
}

.sequence-text {
    font-family: 'Courier New', monospace;
    letter-spacing: 0.5px;
    background-color: rgba(255, 255, 255, 0.7);
    padding: 2px 6px;
    border-radius: 3px;
    display: inline-block;
    margin: 0 4px 0 0;
    max-width: 100%;
    overflow-x: auto;
    white-space: normal;
    word-break: break-all;
    line-height: inherit;
    vertical-align: baseline;
    border: 1px solid rgba(82, 0, 73, 0.1);
}

.btn-toggle-sequence {
    background: #520049;
    color: white;
    border: none;
    padding: 2px 8px;
    border-radius: 3px;
    font-size: 11px;
    cursor: pointer;
    margin-left: 8px;
    transition: all 0.2s;
    vertical-align: baseline;
    line-height: inherit;
}

.btn-toggle-sequence:hover {
    background: #6c006c;
}

/* Result description with highlighted content */
.result-description {
    color: #444;
    line-height: 1.5;
    margin: 8px 0 0 0;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
}

.result-description strong {
    color: #222;
}

/* Enhanced tag styles */
.tag.tag-type {
    background: #520049;
    padding: 5px 10px;
    border-radius: 12px;
    font-size: 12px;
    color: white;
    font-weight: 500;
}

/* 结果类型样式 */
.result-item-list.result-sequence {
    border-left: 4px solid #0066cc; /* 蓝色边框表示序列 */
}

.result-item-list.result-page {
    border-left: 4px solid #520049; /* 紫色边框表示页面 */
}

.result-type {
    font-weight: 600;
}

/* 结果类型标识 */
.type-badge {
    display: inline-flex;
    align-items: center;
    margin-bottom: 12px;
    padding: 5px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
    color: white;
}

.type-badge.sequence {
    background: linear-gradient(135deg, #0066cc, #3a89e6);
}

.type-badge.page {
    background: linear-gradient(135deg, #520049, #8a3b7f);
}

.type-badge i {
    margin-right: 5px;
}

/* 表格结果类型样式 */
.result-type-badge {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 500;
    color: white;
}

.result-type-badge.sequence {
    background: #0066cc;
}

.result-type-badge.page {
    background: #520049;
}

/* 表格行样式 */
.sequence-row {
    background-color: #f0f7ff !important;
}

.sequence-row:hover {
    background-color: #e6f2ff !important;
}

.page-row {
    background-color: #faf5fa !important;
}

.page-row:hover {
    background-color: #f5ebf5 !important;
}

/* 瀑布流项目样式 */
.masonry-sequence .masonry-card {
    border-top: 4px solid #0066cc;
}

.masonry-page .masonry-card {
    border-top: 4px solid #520049;
}

/* Particles Container */
.particles-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    overflow: hidden;
}

/* Flying Elements */
.flying-elements {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

/* Mouse Trail Canvas */
.mouse-trail-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    pointer-events: none;
    z-index: 0;
    opacity: 0.8;
}

/* Search Interface Main Content */
.gradient-main {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #520049 100%) !important;
    color: #fff;
}

.gradient-filter {
    background: linear-gradient(135deg, #fffbe6 0%, #ffd6e0 100%) !important;
    color: #520049;
}

.gradient-results {
    background: linear-gradient(135deg, #f8fafc 0%, #e9e9f3 100%) !important;
    color: #222;
}

.gradient-card {
    box-shadow: 0 8px 32px rgba(60,60,60,0.08), 0 1.5px 4px rgba(0,0,0,0.03);
    border-radius: 28px;
}

.search-card {
    background: linear-gradient(135deg, #e9e6ff 0%, #e0c6ff 100%) !important;
    z-index: -1;
    position: relative;
}

/* 水滴效果动画 */
@keyframes waterDrop {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.02);
        opacity: 0.8;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

.search-card.water-drop {
    animation: waterDrop 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* 吸顶效果 */
.search-card.sticky {
    position: sticky;
    top: 20px;
    margin-top: 20px;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* 过滤器卡片样式优化 */
.filter-card {
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    z-index: -1;
    transform-origin: center top;
    background: linear-gradient(135deg, #fffbe6 0%, #ffd6e0 100%) !important;
}

.filter-card .filter-header {
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    padding: 0 40px;
    height: 40px; /* 固定高度确保垂直居中 */
}

.filter-card .filter-header span {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.filter-card .filter-header button {
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 0.8;
}

.filter-card .filter-header button:hover {
    transform: translateY(-50%) scale(1.1);
    opacity: 1;
}

.filter-content {
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    max-height: 1000px;
    overflow: hidden;
    opacity: 1;
    transform: translateY(0);
}

.filter-content.collapsed {
    max-height: 0;
    padding-top: 0;
    padding-bottom: 0;
    margin-top: 0;
    margin-bottom: 0;
    opacity: 0;
    transform: translateY(-20px);
}

/* 滑动效果 */
@keyframes slideToLeft {
    0% {
        transform: translateX(0);
        opacity: 1;
    }
    100% {
        transform: translateX(-100%);
        opacity: 0;
    }
}

.search-card.slide-left,
.filter-card.slide-left {
    animation: slideToLeft 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.filter-card:not(.collapsed)::after {
    opacity: 1;
}

/* 水润效果 */
@keyframes waterRipple {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.02);
        opacity: 0.8;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

.search-card.water-ripple,
.filter-card.water-ripple {
    animation: waterRipple 1.2s cubic-bezier(0.4, 0, 0.2, 1);
}

/* 结果卡片动画 */
.results-card {
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.results-card.sticky {
    position: sticky;
    top: 20px;
    margin-top: 20px;
}

/* 选中特效已移除 */

/* 退出动画 */
.search-card.exit {
    animation: exitAnimation 0.5s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes exitAnimation {
    0% {
        transform: translateY(0);
        opacity: 1;
    }
    100% {
        transform: translateY(-100%);
        opacity: 0;
    }
}

.card-slide-left {
    transition: transform 0.6s cubic-bezier(0.4,0,0.2,1);
    transform: translateX(-120%) !important;
    opacity: 0.2;
    pointer-events: none;
}

.card-shrink-left {
    transition: transform 0.5s linear;
    transform: scale(0.7) translateX(-20%);
    opacity: 1;
    z-index: 10;
}

.results-masonry {
    column-count: 3;
    column-gap: 24px;
    width: 100%;
    margin: 0 auto;
    padding-bottom: 80px;
}
@media (max-width: 900px) {
    .results-masonry { column-count: 2; }
}
@media (max-width: 600px) {
    .results-masonry { column-count: 1; }
}
.result-item-masonry {
    break-inside: avoid;
    margin-bottom: 24px;
}
.masonry-card {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: box-shadow 0.2s;
}
.masonry-card:hover {
    box-shadow: 0 8px 32px rgba(60,60,60,0.16);
}
.card-header-masonry {
    background: linear-gradient(135deg, #520049 0%, #a084e8 100%);
    color: #fff;
    padding: 18px 20px 10px 20px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}
.card-title-masonry {
    margin: 0;
    font-size: 18px;
    font-weight: 700;
    color: #fff !important;
    text-shadow: 0 2px 8px rgba(82,0,73,0.10), 0 1px 0 #333;
}

/* BackToTop按钮优化 */
.bento-fab.bento-fab-top {
    background: #520049 !important;
    color: #fff;
    border: none;
    box-shadow: 0 6px 24px 0 #a084e855;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.4em;
    transition: background 0.2s, box-shadow 0.2s, color 0.2s;
    position: relative;
}
.bento-fab.bento-fab-top:hover {
    background: #a084e8 !important;
    color: #fff;
    box-shadow: 0 12px 32px 0 #52004999;
}
.bento-fab.bento-fab-top i {
    font-size: 1em;
    margin: 0;
    line-height: 1;
}

/* back to top按钮悬浮气泡提示 */
.bento-fab-top .fab-tooltip {
    display: none;
    position: absolute;
    bottom: 70px;
    left: 50%;
    transform: translateX(-50%);
    background: #fff;
    color: #520049;
    padding: 7px 18px;
    border-radius: 8px;
    font-size: 1em;
    box-shadow: 0 2px 12px #a084e855;
    white-space: nowrap;
    z-index: 10000;
    pointer-events: none;
    opacity: 0.95;
}
.bento-fab-top:hover .fab-tooltip {
    display: block;
}

/* 线性增长、无斑马纹的竖直进度条 */
.masonry-progress-bar-apple {
    position: fixed;
    left: 32px;
    top: 120px;
    width: 16px;
    height: 320px;
    background: #f3eaff;
    border-radius: 10px;
    box-shadow: 0 2px 16px 0 #52004933;
    z-index: 99999;
    pointer-events: none;
    opacity: 0.98;
    display: flex;
    flex-direction: column;
    align-items: center;
    border: 2px solid #520049;
}
.masonry-progress-inner {
    width: 100%;
    background: linear-gradient(180deg, #a084e8 0%, #520049 100%);
    border-radius: 10px;
    transition: height 0.5s cubic-bezier(.4,0,.2,1);
    box-shadow: 0 0 8px #a084e855;
    position: absolute;
    left: 0;
    bottom: 0;
}

/* Result item styles */
.result-item-list {
    background: white;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    border-left: 4px solid #520049;
    overflow: hidden;
    word-wrap: break-word;
    word-break: break-word;
}

/* Enhanced sequence preview container */
.sequence-preview, .sequence-full {
    max-width: 100%;
    position: relative;
}

/* Sequence matches highlight */
.sequence-match {
    background-color: #ffecb3;
    color: #856404;
    font-weight: bold;
    padding: 0 1px;
    border-radius: 2px;
} 