/**
 * Стили для поиска
 */

.search-container {
    flex: 1;
    max-width: 600px;
    position: relative;
}

.search-form {
    display: flex;
    align-items: center;
    background: var(--color-bg-gray);
    border: 1px solid var(--color-border);
    border-radius: 9999px;
    overflow: visible;
    transition: var(--transition);
    position: relative;
}

.search-form:focus-within {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 4px rgba(86, 36, 208, 0.1);
}

.search-form .search-input {
    flex: 1 !important;
    padding: 0.75rem 1rem !important;
    border: none !important;
    background: transparent !important;
    font-size: 0.9375rem !important;
    outline: none;
    font-family: inherit;
    width: auto !important;
    height: auto !important;
    box-sizing: border-box;
    line-height: normal !important;
    font-weight: normal !important;
    border-radius: 0 !important;
    box-shadow: none !important;
}

.search-form .search-input::placeholder {
    color: var(--color-text-light) !important;
    opacity: 1 !important;
}

.search-form .search-button {
    padding: 0.75rem 1.25rem !important;
    border: none !important;
    background: transparent !important;
    cursor: pointer;
    color: var(--color-text-light);
    transition: var(--transition);
    display: flex !important;
    align-items: center;
    justify-content: center;
    position: static !important;
    width: auto !important;
    height: auto !important;
    transform: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    flex-shrink: 0;
}

.search-form .search-button:hover {
    color: var(--color-primary) !important;
    background: transparent !important;
    transform: none !important;
    box-shadow: none !important;
}

.search-form .search-button svg {
    width: 20px !important;
    height: 20px !important;
    fill: none !important;
    stroke: currentColor !important;
}

/* Кнопка фильтра */
.filter-toggle-btn {
    padding: 0.75rem 1rem !important;
    border: none !important;
    background: transparent !important;
    cursor: pointer;
    color: var(--color-text-light);
    transition: var(--transition);
    display: flex !important;
    align-items: center;
    justify-content: center;
    position: static !important;
    width: auto !important;
    height: auto !important;
    transform: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    flex-shrink: 0;
    border-left: 1px solid var(--color-border);
    margin-left: 0;
}

.filter-toggle-btn:hover {
    color: var(--color-primary) !important;
    background: transparent !important;
}

.filter-toggle-btn.active {
    color: var(--color-primary) !important;
    background: rgba(86, 36, 208, 0.1) !important;
}

/* Расширенный поиск */
.search-filters {
    position: absolute;
    top: calc(100% + 0.5rem);
    left: 0;
    right: 0;
    background: white;
    border: 1px solid var(--color-border);
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    z-index: 1000;
    padding: 1.25rem;
    opacity: 0;
    transform: translateY(-10px);
    pointer-events: none;
    transition: opacity 0.3s ease, transform 0.3s ease;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.search-filters.show {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.filters-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1rem;
    margin-bottom: 1rem;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.filter-group label {
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--color-text);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.filter-select,
.filter-input {
    padding: 0.625rem 0.75rem;
    border: 1px solid var(--color-border);
    border-radius: 6px;
    font-size: 0.9375rem;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: var(--color-text);
    background: white;
    transition: var(--transition);
}

.filter-select:focus,
.filter-input:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(86, 36, 208, 0.1);
}

.filter-actions {
    grid-column: 1 / -1;
    display: flex;
    gap: 0.75rem;
    justify-content: flex-end;
    padding-top: 0.75rem;
    border-top: 1px solid var(--color-border);
    margin-top: 0.25rem;
}

.btn-filter-apply {
    padding: 0.625rem 1.5rem;
    background: var(--color-primary);
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 0.9375rem;
    font-weight: 600;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    cursor: pointer;
    transition: var(--transition);
}

.btn-filter-apply:hover {
    background: var(--color-primary-dark);
}

.btn-filter-reset {
    padding: 0.625rem 1.5rem;
    background: transparent;
    color: var(--color-text);
    border: 1px solid var(--color-border);
    border-radius: 6px;
    font-size: 0.9375rem;
    font-weight: 600;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    cursor: pointer;
    transition: var(--transition);
}

.btn-filter-reset:hover {
    background: var(--color-bg-gray);
}

/* Красивый поиск с кнопкой внутри */
.search-wrapper {
    position: relative;
    display: block;
    width: 100%;
}

.search-wrapper .search-input {
    width: 100%;
    padding: 0.75rem 3.5rem 0.75rem 1.25rem;
    border: 2px solid #e2e8f0;
    border-radius: 22px;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    background: #ffffff;
    line-height: 1.5;
    height: 44px;
    box-sizing: border-box;
    color: #1e293b;
    font-weight: 400;
}

.search-wrapper .search-input:hover {
    border-color: #cbd5e1;
}

.search-wrapper .search-input:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.search-wrapper .search-input::placeholder {
    color: #94a3b8;
    opacity: 1;
}

.search-wrapper .search-button {
    position: absolute;
    right: 4px;
    top: 50%;
    transform: translateY(-50%);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--color-primary);
    border: none;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    padding: 0;
    box-shadow: 0 2px 4px rgba(37, 99, 235, 0.2);
    flex-shrink: 0;
}

.search-wrapper .search-button:hover {
    background: #1d4ed8;
    box-shadow: 0 3px 6px rgba(37, 99, 235, 0.3);
    transform: translateY(-50%) scale(1.05);
}

.search-wrapper .search-button:active {
    transform: translateY(-50%) scale(0.98);
}

.search-wrapper .search-button:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.2);
}

.search-wrapper .search-button svg {
    width: 16px;
    height: 16px;
    fill: white;
    stroke: white;
    display: block;
}

.search-wrapper-with-label {
    width: 100%;
}

.search-wrapper-with-label label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #475569;
    font-size: 0.875rem;
    line-height: 1.4;
    letter-spacing: 0.01em;
}

.search-wrapper-with-label label svg {
    width: 16px;
    height: 16px;
    opacity: 0.6;
    flex-shrink: 0;
}

/* Поиск в стиле Google */
.google-search-container {
    width: 100%;
    margin: 0 auto;
}

.google-search-form {
    width: 100%;
}

.google-search-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
    background: transparent;
    border: 1px solid #dfe1e5;
    border-radius: 28px;
    box-shadow: 0 2px 5px 1px rgba(64, 60, 67, 0.16);
    transition: all 0.2s ease;
    padding: 0 20px;
    height: 56px;
}

.google-search-wrapper:hover {
    box-shadow: 0 2px 8px 1px rgba(64, 60, 67, 0.24);
}

.google-search-wrapper:focus-within,
.google-search-wrapper.focused {
    box-shadow: 0 2px 8px 1px rgba(64, 60, 67, 0.24);
    border-color: transparent;
}

.google-search-input {
    flex: 1;
    border: none;
    outline: none;
    font-size: 18px;
    color: #202124;
    background: transparent;
    padding: 0;
    height: 100%;
    line-height: 24px;
    padding-right: 12px;
}

.google-search-input::placeholder {
    color: #9aa0a6;
}

.google-search-button {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border: none;
    background: transparent;
    cursor: pointer;
    padding: 0;
    margin-right: -12px;
    border-radius: 50%;
    transition: background-color 0.2s ease;
    flex-shrink: 0;
}

.google-search-button:hover {
    background-color: #f1f3f4;
}

.google-search-button:active {
    background-color: #e8eaed;
}

.google-search-button svg {
    width: 22px;
    height: 22px;
    stroke: #4285f4;
    fill: none;
}

.google-search-wrapper:focus-within .google-search-button,
.google-search-wrapper.focused .google-search-button {
    background-color: #4285f4;
}

.google-search-wrapper:focus-within .google-search-button svg,
.google-search-wrapper.focused .google-search-button svg {
    stroke: white;
}

.search-suggestions {
    margin-top: 1.5rem;
    text-align: center;
}

.suggestions-tags {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
}

.suggestion-tag {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: #f1f3f4;
    color: #3c4043;
    text-decoration: none;
    border-radius: 16px;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.2s ease;
    border: 1px solid transparent;
}

.suggestion-tag:hover {
    background: #e8eaed;
    border-color: #dadce0;
    color: #202124;
    box-shadow: 0 1px 2px rgba(60, 64, 67, 0.1);
    transform: translateY(-1px);
}

.suggestion-tag:active {
    transform: translateY(0);
    box-shadow: none;
}

/* Пустое состояние */
.empty-state-message {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 3rem 2rem;
    text-align: center;
    margin-top: 2rem;
}

.empty-state-icon-large {
    margin-bottom: 1rem;
    opacity: 0.4;
}

.empty-state-icon-large svg {
    width: 64px;
    height: 64px;
}

.empty-state-message h3 {
    margin: 0 0 0.5rem 0;
    font-size: 1.25rem;
    color: #1e293b;
    font-weight: 600;
}

.empty-state-message p {
    margin: 0;
    color: #64748b;
    font-size: 0.95rem;
}

@media (max-width: 768px) {
    .search-filters {
        left: -20px;
        right: -20px;
        padding: 1rem;
        max-width: none;
    }
    
    .filters-content {
        grid-template-columns: 1fr;
        gap: 0.875rem;
    }
    
    .filter-group {
        gap: 0.4rem;
    }
    
    .filter-group label {
        font-size: 0.75rem;
    }
    
    .filter-select,
    .filter-input {
        font-size: 0.875rem;
        padding: 0.5rem 0.625rem;
    }
    
    .filter-actions {
        flex-direction: column;
        gap: 0.5rem;
        padding-top: 0.75rem;
    }
    
    .btn-filter-apply,
    .btn-filter-reset {
        width: 100%;
        padding: 0.625rem 1.25rem;
        font-size: 0.875rem;
    }
    
    .search-wrapper .search-input {
        font-size: 16px;
        padding: 0.7rem 3.25rem 0.7rem 1rem;
    }
    
    .search-wrapper .search-button {
        width: 34px;
        height: 34px;
        right: 3px;
    }
    
    .search-wrapper .search-button svg {
        width: 15px;
        height: 15px;
    }
    
    .google-search-container {
        max-width: 100%;
        margin: 1.5rem auto 1rem;
        padding: 0 1rem;
    }
    
    .google-search-wrapper {
        height: 50px;
        padding: 0 16px;
        border-radius: 25px;
    }
    
    .google-search-input {
        font-size: 16px;
    }
    
    .google-search-button {
        width: 44px;
        height: 44px;
        margin-right: -8px;
    }
    
    .google-search-button svg {
        width: 20px;
        height: 20px;
    }
    
    .suggestions-tags {
        gap: 0.375rem;
    }
    
    .suggestion-tag {
        padding: 0.4rem 0.875rem;
        font-size: 0.8125rem;
    }
    
    .suggestions-label {
        font-size: 0.8125rem;
    }
}




