/* Quick Search Modal Stylings */
:root {
    --nt-search-bg: rgba(255, 255, 255, 0.98);
    --nt-search-border: #e2e8f0;
    --nt-search-text: #1a202c;
    --nt-search-accent: #6366f1;
    --nt-search-hover: #f7fafc;
}

.nt-search-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(8px);
    z-index: 100000;
    display: none;
    align-items: flex-start;
    justify-content: center;
    padding-top: 10vh;
    animation: ntFadeIn 0.2s ease;
}

.nt-search-modal {
    width: 100%;
    max-width: 650px;
    background: var(--nt-search-bg);
    border-radius: 24px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    overflow: hidden;
    transform: translateY(-20px);
    transition: transform 0.2s ease;
    border: 1px solid var(--nt-search-border);
}

.nt-search-overlay.active {
    display: flex;
}

.nt-search-overlay.active .nt-search-modal {
    transform: translateY(0);
}

.nt-search-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--nt-search-border);
    display: flex;
    align-items: center;
    gap: 15px;
}

.nt-search-icon {
    color: var(--nt-search-accent);
    flex-shrink: 0;
}

.nt-search-input {
    width: 100%;
    border: none !important;
    background: transparent !important;
    font-size: 18px !important;
    color: var(--nt-search-text) !important;
    padding: 0 !important;
    outline: none !important;
    box-shadow: none !important;
}

.nt-search-close {
    background: #edf2f7;
    border: none;
    border-radius: 8px;
    padding: 5px 10px;
    font-size: 12px;
    color: #a0aec0;
    cursor: pointer;
    transition: all 0.2s;
}

.nt-search-close:hover {
    background: #e2e8f0;
    color: #4a5568;
}

.nt-search-results {
    max-height: 450px;
    overflow-y: auto;
    padding: 10px 0;
}

.nt-search-item {
    padding: 12px 24px;
    display: flex;
    align-items: center;
    gap: 15px;
    text-decoration: none !important;
    color: var(--nt-search-text) !important;
    transition: background 0.1s;
    cursor: pointer;
}

.nt-search-item:hover, .nt-search-item.selected {
    background: var(--nt-search-hover);
}

.nt-search-item-thumb {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: #f8fafc;
    flex-shrink: 0;
    object-fit: cover;
    border: 1px solid #f1f5f9;
}

.nt-search-item-info {
    flex-grow: 1;
    overflow: hidden;
}

.nt-search-item-title {
    font-weight: 600;
    font-size: 15px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 4px;
}

.nt-search-item-meta {
    font-size: 13px;
    color: #718096;
    display: flex;
    gap: 10px;
}

.nt-search-item-type {
    text-transform: uppercase;
    font-size: 10px;
    background: #edf2f7;
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 700;
}

.nt-search-item-arrow {
    color: #cbd5e0;
    opacity: 0;
    transition: opacity 0.2s;
}

.nt-search-item:hover .nt-search-item-arrow, .nt-search-item.selected .nt-search-item-arrow {
    opacity: 1;
}

.nt-search-empty {
    padding: 40px 20px;
    text-align: center;
    color: #a0aec0;
}

.nt-search-empty svg {
    margin-bottom: 15px;
    opacity: 0.3;
}

/* Animations */
@keyframes ntFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Scrollbar */
.nt-search-results::-webkit-scrollbar {
    width: 6px;
}
.nt-search-results::-webkit-scrollbar-thumb {
    background: #e2e8f0;
    border-radius: 10px;
}

/* Floating Search Trigger */
.nt-search-trigger {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.5);
    padding: 8px 10px 8px 18px;
    border-radius: 50px;
    display: flex;
    align-items: center;
    gap: 30px;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    z-index: 9999;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    user-select: none;
}

.nt-search-trigger:hover {
    background: #fff;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.15);
    transform: translateX(-50%) translateY(-2px);
}

.nt-search-trigger-content {
    display: flex;
    align-items: center;
    gap: 12px;
}

.nt-search-trigger-text {
    color: #64748b;
    font-size: 14px;
    font-weight: 500;
}

.nt-search-trigger-hint {
    background: #f1f5f9;
    color: #94a3b8;
    font-size: 11px;
    font-weight: 700;
    padding: 4px 8px;
    border-radius: 6px;
    border: 1px solid #e2e8f0;
}

/* Dark mode support if site has it */
@media (prefers-color-scheme: dark) {
    .nt-search-trigger {
        background: rgba(30, 41, 59, 0.8);
        border-color: rgba(255, 255, 255, 0.1);
    }
    .nt-search-trigger-text { color: #94a3b8; }
    .nt-search-trigger-hint { background: #334155; border-color: #475569; color: #64748b; }
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .nt-search-trigger {
        width: calc(100% - 40px);
        max-width: 350px;
        padding: 10px 15px;
        bottom: 20px;
        gap: 10px;
        justify-content: center;
    }
    
    .nt-search-trigger-hint {
        display: none;
    }

    .nt-search-trigger-text {
        font-size: 15px;
    }

    .nt-search-overlay {
        padding: 0;
    }

    .nt-search-modal {
        max-width: 100%;
        height: 100%;
        border-radius: 0;
        transform: translateY(100%);
    }

    .nt-search-overlay.active .nt-search-modal {
        transform: translateY(0);
    }

    .nt-search-header {
        padding: 15px;
    }

    .nt-search-close {
        padding: 8px 12px;
    }

    .nt-search-results {
        max-height: calc(100vh - 80px);
    }

    .nt-search-item {
        padding: 15px;
    }

    .nt-search-item-thumb {
        width: 40px;
        height: 40px;
    }
}
