/*
 * Main Search Component - Updated with Orange & Blue Brand Colors
 * Last Modified: September 11, 2025 at 11:15 PM
 * 
 * A beautiful, professional search interface with integrated filter controls.
 * This component is designed to be a prominent and engaging feature.
 * 
 * ⚠️  LAYOUT WARNING: Do not modify width, max-width, margin, or padding properties
 * on .main-search-component as it will cause left-shift issues due to parent 
 * container (.container) conflicts. Only modify visual properties like colors,
 * shadows, typography, and borders.
 */

.main-search-component {
    /* Rich dark blue background matching header/footer theme */
    background: linear-gradient(135deg, var(--blue-dark) 0%, var(--qk-accent-blue) 50%, #2563eb 100%);
    border-radius: var(--border-radius-xl);
    padding: var(--spacing-3xl) var(--spacing-2xl);
    margin: var(--spacing-3xl) auto;
    max-width: 800px;

    /* Enhanced shadow with brand colors */
    box-shadow: 
        0 20px 25px -5px rgb(11 79 156 / 40%),
        0 10px 10px -5px rgb(230 151 90 / 20%),
        0 0 0 1px rgb(255 255 255 / 10%) inset;
    border: 2px solid var(--qk-accent-orange);

    /* Subtle backdrop filter for modern glass effect */
    backdrop-filter: blur(1px);

    /* Add radial gradient overlay like footer */
    position: relative;
}

.main-search-component::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 18% 22%, rgb(255 255 255 / 9%), transparent 55%), 
                radial-gradient(circle at 82% 76%, rgb(255 255 255 / 7%), transparent 60%);
    pointer-events: none;
    border-radius: var(--border-radius-xl);
}

.main-search-container {
    max-width: 700px;
    margin: 0 auto;
    text-align: center;
}

.main-search-title {
    font-size: var(--font-size-4xl);
    font-weight: var(--font-weight-bold);
    color: #fff;
    margin-bottom: var(--spacing-lg);
    letter-spacing: -0.025em;
    line-height: 1.1;
    text-rendering: optimizelegibility;

    /* Enhanced text shadow for dark background */
    text-shadow: 0 2px 4px rgb(0 0 0 / 30%), 0 1px 2px rgb(0 0 0 / 20%);

    /* Add subtle glow effect */
    filter: drop-shadow(0 0 8px rgb(255 255 255 / 10%));
    position: relative;
    z-index: 1;
}

.main-search-title::before {
    content: '';
    position: absolute;
    inset: -10px -20px;
    background: radial-gradient(ellipse at center, rgb(11 79 156 / 3%) 0%, transparent 70%);
    border-radius: var(--border-radius-lg);
    z-index: -1;
}

.main-search-tagline {
    font-size: var(--font-size-lg);
    color: rgb(255 255 255 / 85%);
    margin-bottom: var(--spacing-xl);
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    line-height: var(--line-height-relaxed);
    font-weight: var(--font-weight-medium);
    text-shadow: 0 1px 2px rgb(0 0 0 / 20%);
    position: relative;
    z-index: 1;

    /* Improved text rendering */
    text-rendering: optimizelegibility;
    -webkit-font-smoothing: antialiased;
}

.main-search-description {
    margin-bottom: var(--spacing-2xl);
    max-width: 650px;
    margin-left: auto;
    margin-right: auto;
}

.company-story {
    font-size: var(--font-size-base);
    color: rgb(255 255 255 / 90%);
    margin-bottom: var(--spacing-md);
    line-height: var(--line-height-relaxed);
    font-weight: var(--font-weight-medium);
    text-shadow: 0 1px 2px rgb(0 0 0 / 20%);
}

.mission-statement {
    font-size: var(--font-size-base);
    color: rgb(255 255 255 / 80%);
    line-height: var(--line-height-relaxed);
    font-weight: var(--font-weight-normal);
    text-shadow: 0 1px 2px rgb(0 0 0 / 20%);
    font-style: italic;
}

.main-search .search-form {
    max-width: 100%;
}

.main-search .search-input-group {
    display: flex;
    align-items: center;
    background-color: rgb(255 255 255 / 95%);
    border-radius: var(--border-radius-full);
    padding: var(--spacing-sm) var(--spacing-sm) var(--spacing-sm) var(--spacing-lg);

    /* Enhanced border with subtle #fff border */
    border: 2px solid rgb(255 255 255 / 20%);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 
        0 4px 6px -1px rgb(0 0 0 / 15%),
        0 2px 4px -1px rgb(0 0 0 / 10%),
        0 0 0 1px rgb(255 255 255 / 90%) inset;
    backdrop-filter: blur(8px);
    position: relative;
    z-index: 1;
}

.main-search .search-input-group:hover {
    border-color: transparent;
    background-image: 
        linear-gradient(var(--white), var(--white)),
        linear-gradient(135deg, var(--qk-accent-blue) 0%, rgb(11 79 156 / 80%) 50%, #3b82f6 100%);
    transform: translateY(-1px);
    box-shadow: 
        0 8px 12px -3px rgb(11 79 156 / 15%),
        0 4px 6px -2px rgb(11 79 156 / 8%),
        0 0 0 1px rgb(255 255 255 / 95%) inset,
        0 0 20px rgb(11 79 156 / 10%);
}

.main-search .search-input-group:focus-within {
    background-color: var(--white);
    border-color: transparent;
    background-image: 
        linear-gradient(var(--white), var(--white)),
        linear-gradient(135deg, var(--qk-accent-orange) 0%, rgb(230 151 90 / 90%) 50%, #f97316 100%);
    box-shadow: 
        0 0 0 4px rgb(230 151 90 / 20%),
        0 8px 12px -3px rgb(230 151 90 / 15%),
        0 4px 6px -2px rgb(230 151 90 / 8%),
        0 0 0 1px rgb(255 255 255 / 95%) inset,
        0 0 30px rgb(230 151 90 / 10%);
    transform: translateY(-1px);
}

.main-search .search-icon {
    width: 22px;
    height: 22px;
    fill: var(--qk-accent-orange);
    margin-right: var(--spacing-md);
    flex-shrink: 0;
    transition: all 0.3s ease;

    /* Add orange glow effect */
    filter: drop-shadow(0 0 4px rgb(230 151 90 / 30%));
}

.main-search .search-input-group:focus-within .search-icon {
    transform: scale(1.1);
    fill: var(--qk-accent-orange);
    filter: drop-shadow(0 2px 4px rgb(230 151 90 / 30%));
}

.main-search .search-input-group:hover .search-icon {
    fill: var(--blue-dark);
    transform: scale(1.05);
}

.main-search .search-input {
    flex-grow: 1;
    border: none;
    outline: none;
    font-size: 1.05rem;
    background: transparent;
    color: var(--dark-gray);
    padding: var(--spacing-sm) 0;
}

.main-search .search-input:focus {
    outline: none;
}

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

.main-search .search-button {
    background: linear-gradient(135deg, var(--qk-accent-orange) 0%, #f97316 100%);
    color: var(--white);
    border: none;
    padding: 12px 32px;
    border-radius: var(--border-radius-full);
    font-weight: var(--font-weight-bold);
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 
        0 4px 6px -1px rgb(249 115 22 / 40%),
        0 2px 4px -1px rgb(0 0 0 / 6%),
        0 0 0 1px rgb(255 255 255 / 10%) inset;
    white-space: nowrap;

    /* Enhanced typography */
    letter-spacing: 0.025em;
    text-shadow: 0 1px 2px rgb(0 0 0 / 10%);
}

.main-search .search-button:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 
        0 8px 16px -4px rgb(249 115 22 / 50%),
        0 4px 8px -2px rgb(0 0 0 / 10%),
        0 0 0 1px rgb(255 255 255 / 15%) inset;
    background: linear-gradient(135deg, #f97316 0%, #ea580c 100%);
}

.main-search .search-button:active {
    transform: translateY(-1px) scale(1.01);
    box-shadow: 
        0 4px 8px -2px rgb(249 115 22 / 40%),
        0 2px 4px -1px rgb(0 0 0 / 6%),
        0 0 0 1px rgb(255 255 255 / 10%) inset;
}

.main-search .search-button:focus {
    outline: none;
    box-shadow: 
        0 0 0 4px rgb(249 115 22 / 20%),
        0 4px 6px -1px rgb(249 115 22 / 40%),
        0 2px 4px -1px rgb(0 0 0 / 6%),
        0 0 0 1px rgb(255 255 255 / 10%) inset;
}

.main-search .search-hint {
    font-size: var(--font-size-sm);
    color: var(--qk-accent-orange);
    margin-top: var(--spacing-md);
    text-transform: none;
    letter-spacing: 0.03em;
    font-weight: 600;
    opacity: 0.95;
    position: relative;
    text-shadow: 0 0 4px rgb(230 151 90 / 35%);
}

.main-search .search-hint::before {
    content: '💡';
    margin-right: var(--spacing-xs);
    color: var(--qk-accent-orange);
    filter: drop-shadow(0 1px 2px rgb(230 151 90 / 30%));
}

/* Filters Section */
.filter-section {
    padding-top: var(--spacing-xl);
    margin-top: var(--spacing-xl);
    border-top: 2px solid rgb(230 151 90 / 20%);

    /* Add orange and blue gradient background to filters area */
    background: linear-gradient(180deg, 
        rgb(230 151 90 / 5%) 0%, 
        rgb(11 79 156 / 5%) 50%,
        transparent 100%);
    border-radius: 0 0 var(--border-radius-xl) var(--border-radius-xl);
}

.filter-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, var(--qk-accent-blue) 0%, var(--qk-accent-orange) 100%);
    border-radius: var(--border-radius-full);
    opacity: 0.6;
}

.filter-bar {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: var(--spacing-lg);
}

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

.filter-label {
    font-size: var(--font-size-sm);
    font-weight: var(--font-weight-semibold);
    color: rgb(255 255 255 / 90%);
    margin-bottom: var(--spacing-sm);

    /* Add #fff text shadow for dark background */
    text-shadow: 0 1px 2px rgb(0 0 0 / 30%);
    position: relative;
    z-index: 1;
}

.filter-label::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 20px;
    height: 2px;
    background: linear-gradient(90deg, var(--qk-accent-orange) 0%, transparent 100%);
    border-radius: var(--border-radius-full);
    opacity: 0.7;
}

/* Redesigned filter "cards" */
.filter-select-wrapper {
    position: relative;
}

.filter-select {
    width: 100%;
    padding: 16px 18px;
    border: 2px solid rgb(255 255 255 / 20%);
    border-radius: var(--border-radius-lg);
    font-size: var(--font-size-base);
    font-weight: 600;
    background-color: rgb(255 255 255 / 95%);
    color: var(--dark-gray);
    appearance: none;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 
        0 4px 6px -1px rgb(0 0 0 / 15%),
        0 2px 4px -1px rgb(0 0 0 / 10%);
    backdrop-filter: blur(8px);
    position: relative;
    z-index: 1;
}

.filter-select:hover {
    background-color: rgb(255 255 255 / 100%);
    border-color: var(--qk-accent-orange);
    transform: translateY(-1px);
    box-shadow: 
        0 8px 12px -3px rgb(0 0 0 / 15%),
        0 4px 6px -2px rgb(0 0 0 / 10%),
        0 0 0 3px rgb(230 151 90 / 20%);
}

.filter-select:focus {
    outline: none;
    background-image: 
        linear-gradient(var(--white), var(--white)),
        linear-gradient(135deg, var(--qk-accent-orange), #f97316);
    box-shadow: 
        0 0 0 4px rgb(230 151 90 / 15%),
        0 4px 6px -1px rgb(0 0 0 / 8%),
        0 2px 4px -1px rgb(0 0 0 / 4%);
}

/* Custom dropdown arrow */
.filter-select-wrapper::after {
    content: '';
    position: absolute;
    top: 50%;
    right: 16px;
    width: 8px;
    height: 8px;
    border-style: solid;
    border-color: var(--qk-accent-orange);
    border-width: 0 2px 2px 0;
    transform: translateY(-70%) rotate(45deg);
    pointer-events: none;
    transition: transform 0.2s ease;
}

.filter-select-wrapper:hover::after {
    transform: translateY(-70%) rotate(225deg);
}

@media (width <= 768px) {
    .main-search-component {
        padding: var(--spacing-2xl) var(--spacing-lg);
        margin: var(--spacing-2xl) auto;
    }
    
    .main-search-title {
        font-size: var(--font-size-3xl);
    }
    
    .filter-bar {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing-md);
    }
}

@media (width <= 640px) {
    .main-search-component {
        padding: var(--spacing-xl) var(--spacing-md);
        margin: var(--spacing-xl) auto;
    }
    
    .main-search-title {
        font-size: var(--font-size-2xl);
    }
    
    .main-search-tagline {
        font-size: var(--font-size-base);
    }
}

@media (width <= 500px) {
    .main-search-component {
        padding: var(--spacing-lg) var(--spacing-sm);
        margin: var(--spacing-lg) auto;
    }
    
    .main-search .search-input-group {
        flex-direction: column;
        border-radius: var(--border-radius-lg);
        padding: var(--spacing-md);
        background-color: #f1f3f5;
        border: none;
        box-shadow: none;
    }
    
    .main-search .search-input-group:focus-within {
        box-shadow: none;
    }

    .main-search .search-input {
        width: 100%;
        text-align: center;
        margin-bottom: var(--spacing-md);
        background-color: var(--white);
        padding: var(--spacing-md);
        border-radius: var(--border-radius-md);
        border: 2px solid var(--medium-gray);
    }
    
    .main-search-title {
        font-size: var(--font-size-xl);
    }
    
    .main-search-tagline {
        font-size: var(--font-size-sm);
    }

    .main-search .search-button {
        width: 100%;
    }

    .main-search .search-icon {
        display: none;
    }

    .filter-bar {
        grid-template-columns: 1fr;
        gap: var(--spacing-sm);
    }
    
    .filter-select {
        padding: var(--spacing-md);
        font-size: var(--font-size-sm);
    }
}

