/* Search Styles - SaaS Light */
.search-trigger {
    position: relative;
    z-index: 1000;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    font-size: 1.1rem;
    cursor: pointer;
    background: white;
    border: 1px solid rgba(0, 0, 0, 0.08);
    color: #64748b;
    border-radius: 12px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}

.search-trigger:hover {
    background: #f8fafc;
    color: #6366f1;
    border-color: rgba(99, 102, 241, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.08);
}

.search-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.2);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 1001;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.search-modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
}

.search-container {
    width: 90%;
    max-width: 650px;
    background: white;
    border-radius: 20px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.2);
    z-index: 1002;
    overflow: hidden;
    transform: translateY(20px);
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.search-modal.active .search-container {
    transform: translateY(0);
}

.search-header {
    padding: 24px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.04);
    display: flex;
    align-items: center;
    gap: 16px;
    background: #fafafa;
}

.search-input {
    flex: 1;
    padding: 12px 16px;
    border: 1px solid rgba(0, 0, 0, 0.05);
    border-radius: 12px;
    font-size: 1.1rem;
    font-family: 'Inter', sans-serif;
    background: white;
    transition: all 0.3s ease;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.02);
}

.search-input:focus {
    outline: none;
    border-color: #6366f1;
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1);
}

.search-close {
    background: rgba(0, 0, 0, 0.03);
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    cursor: pointer;
    color: #64748b;
    transition: all 0.2s ease;
}

.search-close:hover {
    background: #fee2e2;
    color: #ef4444;
}

.search-results {
    max-height: 60vh;
    overflow-y: auto;
    padding: 20px;
    background: white;
}

.search-results::-webkit-scrollbar {
    width: 6px;
}
.search-results::-webkit-scrollbar-track {
    background: transparent;
}
.search-results::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.05);
    border-radius: 10px;
}

.search-section {
    margin-bottom: 24px;
}

.search-section-title {
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #94a3b8;
    margin-bottom: 12px;
    padding-left: 8px;
}

.search-item {
    padding: 16px;
    border-radius: 14px;
    margin-bottom: 8px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid transparent;
    background: #f8fafc;
}

.search-item:hover {
    background: white;
    border-color: rgba(99, 102, 241, 0.2);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    transform: translateX(4px);
}

.search-item-title {
    font-weight: 600;
    font-family: 'Outfit', sans-serif;
    color: #1e293b;
    margin-bottom: 4px;
    font-size: 1rem;
}

.search-item-content {
    font-size: 0.9rem;
    color: #64748b;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Pulsing highlight for navigated results */
.search-highlight-pulse {
    animation: highlight-pulse 2s ease-out;
    border-radius: 8px;
}

@keyframes highlight-pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(99, 102, 241, 0.4);
        background-color: rgba(99, 102, 241, 0.1);
    }
    70% {
        box-shadow: 0 0 0 20px rgba(99, 102, 241, 0);
        background-color: rgba(99, 102, 241, 0.05);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(99, 102, 241, 0);
        background-color: transparent;
    }
}

/* Search Result Highlighting on Main Page */
.search-result-active {
    position: relative;
    border-radius: 20px;
    transition: all 0.5s ease;
    z-index: 10;
    box-shadow: 0 0 0 8px rgba(99, 102, 241, 0.1), 0 20px 40px rgba(0, 0, 0, 0.05) !important;
    background: white !important;
}

/* Floating Notice / Toast */
.search-notice {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: rgba(15, 23, 42, 0.9);
    backdrop-filter: blur(10px);
    color: white;
    padding: 12px 24px;
    border-radius: 100px;
    z-index: 10000;
    display: flex;
    align-items: center;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
    transition: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
    opacity: 0;
}

.search-notice.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

.search-notice-content {
    display: flex;
    align-items: center;
    gap: 12px;
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
}

.search-notice-content i {
    color: #818cf8;
    font-size: 1.2rem;
}

.search-notice-content strong {
    color: #818cf8;
}

.search-highlight {
    background: rgba(99, 102, 241, 0.15);
    color: #4f46e5;
    font-weight: 600;
    padding: 0 2px;
    border-radius: 3px;
}

@media (max-width: 768px) {
    .search-container {
        width: 95%;
        border-radius: 16px;
    }
    
    .search-header {
        padding: 16px;
    }
    
    .search-results {
        max-height: 70vh;
    }
} 