/* Główny kontener formularza */
.search-results__search {
    padding: 2.5rem 0;
    margin-bottom: 3rem;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

/* Pole wyszukiwania */
.megamenuSearch__field {
    max-width: 800px;
    margin: 0 auto;
    transform: translateY(0);
    transition: transform 0.3s ease;
}

.megamenuSearch__field:focus-within {
    transform: translateY(-5px);
}

/* Label */
.megamenuSearch__label {
    text-align: center;
    display: block;
    margin-bottom: 1.5rem;
    font-size: 1.75rem;
    font-weight: 600;
    background: linear-gradient(45deg, #2d3436 30%, #636e72 70%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: labelFade 0.5s ease-in;
}

.megamenuSearch__label-highlighted {
    color: #e30613;
    background: linear-gradient(45deg, #d63031 30%, #e84393 70%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Input wrapper */
.megamenuSearch__input-wrapper {
    position: relative;
    backdrop-filter: blur(8px);
}

/* Input */
.megamenuSearch__input {
    width: 100%;
    padding: 1.25rem 3.5rem 1.25rem 1.5rem;
    font-size: 1.125rem;
    border: 2px solid rgba(0, 0, 0, 0.1);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.9);
    transition: all 0.3s ease;
}

.megamenuSearch__input:focus {
    outline: none;
    border-color: #e30613;
    background: #fff;
    box-shadow: 0 0 0 4px rgba(227, 6, 19, 0.1);
}

/* Ikona wyszukiwania */
.megamenuSearch__input-wrapper-icon {
    position: absolute;
    right: 1.25rem;
    top: 50%;
    transform: translateY(-50%);
    width: 24px;
    height: 24px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23666' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='8'/%3E%3Cline x1='21' y1='21' x2='16.65' y2='16.65'/%3E%3C/svg%3E");
    background-size: contain;
    opacity: 0.5;
    transition: opacity 0.3s ease;
}

.megamenuSearch__input-wrapper:focus-within .megamenuSearch__input-wrapper-icon {
    opacity: 1;
}

/* Filtry */
.search-results__filters-wrapper {
    background: #fff;
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
}

/* Przyciski */
.button {
    padding: 0.875rem 2rem;
    border-radius: 0px;
    font-weight: 600;
    letter-spacing: 0.5px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.button--gray-white {
    background: #f8f9fa;
    color: #495057;
    border: 2px solid #e9ecef;
}

.button--gray-white:hover {
    background: #e9ecef;
    transform: translateY(-2px);
}

.button--red-white {
    background: #e30613;
    color: #fff;
    border: none;
}

.button--red-white:hover {
    background: #cc0510;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(227, 6, 19, 0.2);
}

/* Animacje */
@keyframes labelFade {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Dark mode */
@media (prefers-color-scheme: dark) {
    .megamenuSearch__input {
        background: rgba(45, 52, 54, 0.9);
        border-color: rgba(255, 255, 255, 0.1);
        color: #fff;
    }

    .megamenuSearch__input:focus {
        background: #2d3436;
    }

    .button--gray-white {
        background: #343a40;
        color: #f8f9fa;
        border-color: #495057;
    }

    .button--gray-white:hover {
        background: #495057;
    }
}

/* RWD */
@media (max-width: 768px) {
    .search-results__search {
        padding: 1.5rem 1rem;
        border-radius: 12px;
    }

    .megamenuSearch__label {
        font-size: 1.25rem;
    }

    .megamenuSearch__input {
        padding: 1rem 3rem 1rem 1rem;
        font-size: 1rem;
    }

    .button {
        width: 100%;
        margin-bottom: 0.5rem;
    }
}

/*#megamenuSearch {*/
/*    display: none;*/
/*}*/

/*#megamenuSearch.active {*/
/*    display: block;*/
/*}*/

.megamenuSearch__results {
    background-color: #fff;
    border-radius: 4px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    margin-top: 8px;
    max-height: 500px;
    overflow-y: auto;
    padding: 16px 0;
}

.megamenuSearch__results-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.megamenuSearch__results-item {
    padding: 8px 16px;
    transition: background-color 0.2s ease;
}

.megamenuSearch__results-item:hover {
    background-color: #f5f5f5;
}

.megamenuSearch__results-link {
    color: inherit;
    display: block;
    text-decoration: none;
}

.megamenuSearch__results-title {
    font-size: 16px;
    font-weight: 600;
    margin: 0 0 4px;
    line-height: 1.3;
}

.megamenuSearch__results-department {
    color: #666;
    font-size: 14px;
    margin: 0 0 4px;
}

.megamenuSearch__results-text {
    color: #333;
    font-size: 14px;
    line-height: 1.4;
    margin: 0;
}

.megamenuSearch__results-text b {
    background-color: rgba(229, 35, 27, 0.1);
    font-weight: 600;
}

.megamenuSearch-results-show-all {
    border-top: 1px solid #eee;
    margin-top: 8px;
    padding: 16px;
    text-align: center;
}

.megamenuSearch-results-show-all__link {
    color: #E5231B;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: color 0.2s ease;
}

.megamenuSearch-results-show-all__link:hover {
    color: #b31b15;
}

/* Scrollbar styling */
.megamenuSearch__results::-webkit-scrollbar {
    width: 6px;
}

.megamenuSearch__results::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.megamenuSearch__results::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 3px;
}

.megamenuSearch__results::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* Screen reader only */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0,0,0,0);
    border: 0;
}
