/*
Theme Name: CheerUp Child
Theme URI: http://theme-sphere.com/
Description: A child theme of CheerUp
Author: ThemeSphere
Author URI: http://theme-sphere.com
Template: cheerup
Version: 1.52
*/

/* Base Modal Styles */
.search-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0,0,0,0.8);
    z-index: 999999;
    backdrop-filter: blur(2px);
    transition: opacity 0.2s ease-in-out;
}

.modal-content {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: #fff;
    padding: 30px;
    width: 970px;
    max-width: 90vw;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.2);
    z-index: 1000000;
    max-height: 90vh;
    overflow-y: auto;
}

/* Search Input Styles */
#erkrankungen-search {
    width: 100%;
    padding: 15px;
    font-size: 16px;
    border: 2px solid #000;
    border-radius: 4px;
    margin: 20px 0;
    box-sizing: border-box;
    transition: border-color 0.2s ease;
}

#erkrankungen-search:focus {
    outline: none;
    border-color: #2271b1;
    box-shadow: 0 0 5px rgba(34, 113, 177, 0.2);
}

/* Search Results Styles */
#search-results {
    max-height: 400px;
    overflow-y: auto;
    padding-right: 5px;
    margin-top: 20px;
}

.search-result-item {
    padding: 10px 0;
    border-bottom: 1px solid #eee;
    transition: background-color 0.2s ease;
}

.search-result-item:last-child {
    border-bottom: none;
}

.search-result-item a {
    color: #333;
    text-decoration: none;
    display: block;
    padding: 8px 12px;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.search-result-item a:hover {
    background: #f5f5f5;
    transform: translateX(5px);
}

.search-result-item b {
    color: #2271b1;
    font-weight: 600;
}

/* Scrollbar Styling */
#search-results::-webkit-scrollbar {
    width: 6px;
}

#search-results::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

#search-results::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 3px;
}

#search-results::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* Status Messages */
.no-results {
    text-align: center;
    padding: 30px;
    color: #666;
    font-style: italic;
    background: #f9f9f9;
    border-radius: 4px;
}

.more-results {
    padding: 12px;
    text-align: center;
    color: #666;
    background: #f5f5f5;
    border-top: 1px solid #eee;
    font-size: 0.9em;
    margin-top: 15px;
}

/* Close Button */
.close-modal {
    position: absolute;
    right: 20px;
    top: 20px;
    font-size: 24px;
    cursor: pointer;
    color: #ffffff;
    width: 36px;
    height: 36px;
    line-height: 36px;
    text-align: center;
    background: #333333;
    border-radius: 50%;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.close-modal:hover {
    background: #000000;
    transform: scale(1.1) rotate(90deg);
}

/* Banner Styles */
.search-banner {
    margin: 20px 0;
    text-align: center;
    width: 100%;
    overflow: hidden;
}

.search-banner img {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 0 auto;
    border-radius: 4px;
}

/* Header Styles */
.search-header {
    font-size: 18px;
    color: #333;
    width: 100%;
    text-align: left;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

/* Search Trigger Icon */
.erkrankungen-search-trigger a::before {
    content: "\f002";
    font-family: 'ts-icons', sans-serif;
    margin-right: 8px;
    font-size: 14px;
    display: inline-block;
    vertical-align: middle;
}

/* Responsive Styles */
@media (max-width: 1024px) {
    .desktop-only {
        display: none !important;
    }
    
    .modal-content {
        width: 90vw;
        padding: 20px;
    }
}

@media (max-width: 767px) {
    .modal-content {
        padding: 15px;
        max-height: 85vh;
        width: 95vw;
    }

    #erkrankungen-search {
        padding: 12px;
        font-size: 15px;
    }

    .search-header {
        font-size: 16px;
    }

    .close-modal {
        width: 32px;
        height: 32px;
        right: 15px;
        top: 15px;
    }
}

/* Fix for body scroll when modal is open */
body.modal-open {
    overflow: hidden;
    padding-right: 0 !important;
}

/* Quiz Button Styles */
#wpforms-submit-4155 {
    cursor: pointer;
    width: 100%;
    padding: 15px 25px;
    background: #000;
    font-family: var(--ui-font);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.075em;
    transition: all 0.25s ease-in-out;
    text-transform: uppercase;
}

/* WPForms Poll Styles */
.wpforms-poll-answer-count,
div.wpforms-poll-answer-count {
    display: none !important;
}

.wpforms-poll-answer-label-wrap {
    display: flex;
    flex-direction: column-reverse;
    margin-bottom: 10px;
}

.wpforms-poll-answer-label {
    margin-bottom: 5px;
    margin-right: 0 !important;
}

.wpforms-poll-answer-percent {
    display: flex;
    align-items: center;
    gap: 5px;
}

.wpforms-poll-answer-bar-wrap {
    height: 10px !important;
}

div#wpforms-confirmation-4155 {
    background-color: white;
    border: 1px solid #ebebeb;
}