/* FAQ Page Specific Styles */

.faq-header {
    background-image: linear-gradient(135deg, #6366F1 0%, #8B5CF6 100%);
    padding: 80px 0 60px;
    text-align: center;
    color: white;
}

.faq-header h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
    font-weight: 700;
    animation: fadeInUp 1s ease-out;
}

.faq-header p {
    font-size: 1.2rem;
    max-width: 700px;
    margin: 0 auto 2rem;
    opacity: 0.9;
    animation: fadeInUp 1s ease-out 0.2s both;
}

.faq-search {
    max-width: 600px;
    margin: 0 auto;
    animation: fadeInUp 1s ease-out 0.4s both;
}

.search-container {
    position: relative;
    display: flex;
    align-items: center;
    background-color: white;
    border-radius: 30px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.search-container i {
    position: absolute;
    left: 20px;
    color: #6366F1;
    font-size: 1.2rem;
}

.search-container input {
    width: 100%;
    padding: 18px 20px 18px 55px;
    border: none;
    outline: none;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.search-container input:focus {
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.3);
}

/* FAQ Categories */
.faq-categories {
    padding: 40px 0;
    background-color: #f9fafb;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.category-tabs {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
}

.category-tab {
    padding: 10px 20px;
    border: 1px solid #e5e7eb;
    background-color: white;
    border-radius: 30px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.category-tab:hover {
    background-color: #f3f4f6;
}

.category-tab.active {
    background-color: #6366F1;
    color: white;
    border-color: #6366F1;
}

/* FAQ Content */
.faq-content {
    padding: 60px 0;
}

.faq-list {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    background-color: white;
    border-radius: 10px;
    margin-bottom: 20px;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    transition: all 0.3s ease;
}

.faq-item:hover {
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.08);
    transform: translateY(-2px);
}

.faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.faq-question h3 {
    font-size: 1.1rem;
    font-weight: 500;
    margin: 0;
    padding-right: 20px;
}

.toggle-icon {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s ease;
    flex-shrink: 0;
}

.faq-item.active .toggle-icon {
    transform: rotate(180deg);
}

.faq-answer {
    padding: 0 25px;
    max-height: 0;
    overflow: hidden;
    transition: all 0.5s ease;
}

.faq-item.active .faq-answer {
    padding: 0 25px 25px;
    max-height: 1000px;
}

.faq-answer p {
    margin: 0;
    line-height: 1.7;
    color: #4b5563;
}

/* No Results Message */
.no-results {
    text-align: center;
    padding: 40px 20px;
    display: none;
}

.no-results i {
    font-size: 3rem;
    color: #d1d5db;
    margin-bottom: 1rem;
}

.no-results p:first-of-type {
    font-size: 1.2rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.no-results p:last-of-type {
    color: #6b7280;
    margin-bottom: 2rem;
}

/* Submit Question Section */
.submit-question {
    background-color: #f3f4f6;
    padding: 60px 0;
}

.question-form-container {
    max-width: 600px;
    margin: 0 auto;
    text-align: center;
}

.question-form-container h2 {
    font-size: 2rem;
    margin-bottom: 1rem;
    font-weight: 600;
}

.question-form-container > p {
    color: #6b7280;
    margin-bottom: 2rem;
}

.question-form {
    text-align: left;
    background-color: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: #6366F1;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.2);
    outline: none;
}

.honeypot {
    display: none;
}

.captcha-group .captcha {
    display: flex;
    align-items: center;
    gap: 10px;
}

.captcha span {
    font-size: 1.2rem;
    font-weight: 500;
}

.captcha input {
    max-width: 100px;
}

.form-submit {
    text-align: center;
    margin-top: 30px;
}

.form-submit button {
    padding: 12px 30px;
    font-size: 1rem;
}

/* Success Message */
.question-success {
    text-align: center;
    padding: 40px;
    display: none;
    background: white;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.question-success i {
    font-size: 3rem;
    color: #10b981;
    margin-bottom: 1rem;
}

.question-success h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.question-success p {
    color: #6b7280;
}

/* Admin Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.6);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.modal.active {
    display: block;
    opacity: 1;
}

.modal-content {
    background-color: white;
    margin: 50px auto;
    padding: 30px;
    width: 90%;
    max-width: 600px;
    border-radius: 10px;
    box-shadow: 0 5px 30px rgba(0, 0, 0, 0.2);
    transform: translateY(-30px);
    transition: transform 0.3s ease;
    position: relative;
}

.modal.active .modal-content {
    transform: translateY(0);
}

.modal .close {
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 1.5rem;
    color: #9ca3af;
    cursor: pointer;
    transition: color 0.3s ease;
}

.modal .close:hover {
    color: #1f2937;
}

.modal h2 {
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    font-weight: 600;
}

/* Admin Form */
.admin-form .form-group {
    margin-bottom: 20px;
}

.admin-form label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
}

.admin-form input {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.admin-form input:focus {
    border-color: #6366F1;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.2);
    outline: none;
}

/* Admin Panel */
.admin-panel {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: white;
    z-index: 1000;
    overflow: auto;
    padding: 20px;
}

.admin-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 20px;
    margin-bottom: 20px;
    border-bottom: 1px solid #e5e7eb;
}

.admin-header h2 {
    font-size: 1.8rem;
    font-weight: 600;
    margin: 0;
}

.admin-tabs {
    display: flex;
    border-bottom: 1px solid #e5e7eb;
    margin-bottom: 20px;
}

.admin-tab {
    padding: 10px 20px;
    background: none;
    border: none;
    font-size: 1rem;
    font-weight: 500;
    color: #6b7280;
    cursor: pointer;
    position: relative;
    transition: color 0.3s ease;
}

.admin-tab:hover {
    color: #1f2937;
}

.admin-tab.active {
    color: #6366F1;
}

.admin-tab.active:after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: #6366F1;
}

.admin-tab-content {
    display: none;
}

.admin-tab-content.active {
    display: block;
}

.admin-section-title {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
}

.admin-section-title h3 {
    font-size: 1.2rem;
    font-weight: 600;
    margin: 0;
}

.badge {
    display: inline-block;
    padding: 3px 8px;
    background-color: #6366F1;
    color: white;
    border-radius: 30px;
    font-size: 0.8rem;
    margin-left: 10px;
}

.admin-list {
    background-color: #f9fafb;
    border-radius: 10px;
    padding: 20px;
    min-height: 300px;
}

.empty-state {
    text-align: center;
    padding: 40px 0;
    color: #9ca3af;
}

.empty-state i {
    font-size: 3rem;
    margin-bottom: 1rem;
}

/* Question Items in Admin Panel */
.question-item {
    background-color: white;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 15px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    cursor: pointer;
}

.question-item:hover {
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.question-item-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
}

.question-item-meta {
    font-size: 0.9rem;
    color: #6b7280;
}

.question-item-meta span {
    margin-right: 10px;
}

.question-item-actions {
    display: flex;
    gap: 10px;
}

.question-item-actions button {
    background: none;
    border: none;
    cursor: pointer;
    color: #6366F1;
    transition: color 0.3s ease;
}

.question-item-actions button:hover {
    color: #4f46e5;
}

.question-item-content {
    font-weight: 500;
}

/* Answer Modal */
.answer-modal {
    max-width: 800px;
}

.question-details {
    background-color: #f3f4f6;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.question-meta {
    display: flex;
    flex-wrap: wrap;
    margin-bottom: 10px;
    font-size: 0.9rem;
    color: #6b7280;
}

.question-meta span {
    margin-right: 15px;
}

.question-content {
    font-weight: 500;
    font-size: 1.1rem;
}

.answer-form .form-group {
    margin-bottom: 20px;
}

.answer-form label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
}

.answer-form textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.answer-form textarea:focus {
    border-color: #6366F1;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.2);
    outline: none;
}

.answer-form .form-group:last-of-type {
    display: flex;
    align-items: center;
}

.answer-form .form-group:last-of-type input {
    width: auto;
    margin-right: 10px;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .faq-header {
        padding: 60px 20px 40px;
    }

    .faq-header h1 {
        font-size: 2.2rem;
    }

    .category-tabs {
        justify-content: flex-start;
        overflow-x: auto;
        padding-bottom: 10px;
        white-space: nowrap;
        -webkit-overflow-scrolling: touch;
        scroll-behavior: smooth;
    }

    .category-tab {
        flex-shrink: 0;
    }

    .question-form {
        padding: 20px;
    }

    .modal-content {
        margin: 30px auto;
        padding: 20px;
        width: calc(100% - 30px);
    }

    .question-meta {
        flex-direction: column;
    }

    .question-meta span {
        margin-bottom: 5px;
    }
}

/* Animation Keyframes */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}