/**
 * FAQ Page Styles
 * Extrahiert aus faq.php für bessere Wartbarkeit
 */

/* FAQ Item */
.faq-item {
    background-color: var(--bg-section);
    border-radius: 10px;
    padding: 1.5rem;
    margin-bottom: 1rem;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.faq-item:hover {
    box-shadow: var(--shadow-hover);
}

/* FAQ Question */
.faq-question {
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.faq-question::after {
    content: "+";
    font-size: 1.5rem;
    color: var(--accent-color);
    transition: transform 0.3s ease;
}

.faq-item.active .faq-question::after {
    transform: rotate(45deg);
}

/* FAQ Answer */
.faq-answer {
    color: var(--text-secondary);
    line-height: 1.6;
    display: none;
    margin-top: 1rem;
}

.faq-item.active .faq-answer {
    display: block;
}

/* FAQ Category */
.faq-category {
    margin-bottom: 3rem;
}

.faq-category-title {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--accent-color);
    display: flex;
    align-items: center;
    gap: 1rem;
}

.faq-category-title i {
    color: var(--accent-color);
}

/* FAQ Search */
.faq-search {
    background-color: var(--bg-section);
    padding: 2rem;
    border-radius: 10px;
    margin-bottom: 3rem;
    text-align: center;
}

.faq-search h2 {
    margin-bottom: 1.5rem;
    color: var(--primary-color);
}

.faq-search input {
    width: 100%;
    max-width: 600px;
    padding: 1rem;
    font-size: 1.1rem;
    border: 2px solid var(--border-color);
    border-radius: 50px;
    transition: border-color 0.3s ease;
}

.faq-search input:focus {
    outline: none;
    border-color: var(--accent-color);
}

/* FAQ Helpful */
.faq-helpful {
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
    position: relative;
}

.faq-helpful button {
    background: none;
    border: 1px solid var(--border-color);
    padding: 0.5rem 1rem;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.faq-helpful button:hover:not(:disabled) {
    background-color: var(--accent-color);
    color: white;
    border-color: var(--accent-color);
}

.faq-helpful button:disabled {
    cursor: not-allowed;
    opacity: 0.6;
}

.faq-helpful button.voted {
    background-color: #e8e8e8;
    border-color: #d0d0d0;
}

.faq-helpful button.selected {
    background-color: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

/* Vote Success Message */
.vote-success {
    position: absolute;
    top: 50%;
    right: 0;
    transform: translateY(-50%);
    background-color: #4caf50;
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 5px;
    font-size: 0.85rem;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-50%) translateX(20px);
    }
    to {
        opacity: 1;
        transform: translateY(-50%) translateX(0);
    }
}

/* No Results */
.no-results {
    text-align: center;
    padding: 3rem;
    color: var(--text-secondary);
}

.no-results h3 {
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.no-results p {
    margin-bottom: 0;
}

.no-results a {
    color: var(--accent-color);
    text-decoration: none;
}

.no-results a:hover {
    text-decoration: underline;
}

/* Contact CTA */
.contact-cta {
    text-align: center;
    padding: 3rem 0;
}

.contact-cta h2 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.contact-cta p {
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

.contact-cta-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* Responsive Design */
@media (max-width: 768px) {
    .faq-search {
        padding: 1.5rem;
    }
    
    .faq-search input {
        font-size: 1rem;
        padding: 0.75rem;
    }
    
    .faq-item {
        padding: 1rem;
    }
    
    .faq-question {
        font-size: 0.95rem;
    }
    
    .faq-question::after {
        font-size: 1.25rem;
    }
    
    .faq-category-title {
        font-size: 1.25rem;
    }
    
    .faq-helpful {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .contact-cta-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .contact-cta-buttons .btn {
        width: 100%;
        max-width: 250px;
    }
}

/* Print Styles */
@media print {
    .faq-search,
    .faq-helpful,
    .contact-cta {
        display: none;
    }
    
    .faq-item {
        break-inside: avoid;
        box-shadow: none;
        border: 1px solid #ddd;
    }
    
    .faq-item.active .faq-answer,
    .faq-answer {
        display: block !important;
    }
    
    .faq-question::after {
        display: none;
    }
}

/* High Contrast Mode Support */
@media (prefers-contrast: high) {
    .faq-item {
        border: 2px solid #000;
    }
    
    .faq-helpful button {
        border: 2px solid #000;
    }
    
    .faq-helpful button.voted {
        background-color: #000;
        color: #fff;
    }
}

/* Reduced Motion Support */
@media (prefers-reduced-motion: reduce) {
    .faq-item,
    .faq-question::after,
    .faq-helpful button {
        transition: none;
    }
}