/* FAQ Page Styles */

/* Page Title */
.page-title {
    padding: 60px 0;
    background: var(--light-gray);
    text-align: center;
}

.page-title h1 {
    font-size: 32px;
    font-weight: 700;
    color: var(--text-dark);
}

.faq-section {
    padding: 60px 0;
    background: #f8f9fa;
}

/* FAQ Intro */
.faq-intro {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 50px;
}

.faq-intro h2 {
    font-size: 32px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 15px;
}

.faq-intro p {
    font-size: 16px;
    color: #6c757d;
    line-height: 1.6;
}

/* FAQ Categories */
.faq-categories {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 40px;
}

.category-btn {
    padding: 12px 24px;
    border: 2px solid #e9ecef;
    background: white;
    color: #495057;
    border-radius: 25px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.category-btn:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
    background: #f8f9fa;
}

.category-btn.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

/* FAQ List */
.faq-list {
    max-width: 900px;
    margin: 0 auto;
}

/* FAQ Item */
.faq-item {
    background: white;
    border-radius: 12px;
    margin-bottom: 15px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
}

.faq-item:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.12);
}

.faq-item.hidden {
    display: none;
}

/* FAQ Question */
.faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 25px 30px;
    cursor: pointer;
    user-select: none;
}

.faq-question h3 {
    font-size: 18px;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0;
    flex: 1;
    padding-right: 20px;
}

.faq-question i {
    font-size: 16px;
    color: var(--primary-color);
    transition: transform 0.3s ease;
}

.faq-item.active .faq-question i {
    transform: rotate(180deg);
}

/* FAQ Answer */
.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    padding: 0 30px;
}

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

.faq-answer p {
    font-size: 15px;
    line-height: 1.8;
    color: #495057;
    margin-bottom: 15px;
}

.faq-answer p:last-child {
    margin-bottom: 0;
}

.faq-answer ul,
.faq-answer ol {
    padding-left: 20px;
    margin: 15px 0;
}

.faq-answer li {
    font-size: 15px;
    line-height: 1.8;
    color: #495057;
    margin-bottom: 10px;
}

.faq-answer li:last-child {
    margin-bottom: 0;
}

.faq-answer strong {
    color: #1a1a1a;
    font-weight: 600;
}

/* FAQ Contact Box */
.faq-contact {
    margin-top: 60px;
}

.faq-contact-box {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 16px;
    padding: 50px 40px;
    text-align: center;
    color: white;
    box-shadow: 0 8px 24px rgba(102, 126, 234, 0.3);
}

.faq-contact-box i {
    font-size: 48px;
    margin-bottom: 20px;
    opacity: 0.9;
}

.faq-contact-box h3 {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 15px;
}

.faq-contact-box p {
    font-size: 16px;
    opacity: 0.9;
    margin-bottom: 30px;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

/* Contact Buttons */
.contact-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
}

.contact-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 15px 30px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
}

.contact-btn.primary {
    background: white;
    color: var(--primary-color);
}

.contact-btn.primary:hover {
    background: #f8f9fa;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.contact-btn.secondary {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: 2px solid white;
}

.contact-btn.secondary:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

/* ===================================
   Pagination Styles
   =================================== */
.pagination-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    margin-top: 50px;
    padding: 30px 0;
}

.pagination-info {
    font-size: 14px;
    color: #6c757d;
}

.pagination-info strong {
    color: var(--primary-color);
    font-weight: 600;
}

.pagination-buttons {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: center;
}

.pagination-btn {
    min-width: 40px;
    height: 40px;
    padding: 0 12px;
    border: 1px solid #dee2e6;
    background: white;
    color: #495057;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
}

.pagination-btn:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
    background: #f8f9fa;
}

.pagination-btn.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
    font-weight: 600;
}

.pagination-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.pagination-ellipsis {
    padding: 0 5px;
    color: #6c757d;
    font-size: 14px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .page-title {
        padding: 40px 0;
    }

    .page-title h1 {
        font-size: 24px;
    }

    .faq-section {
        padding: 40px 0;
    }

    .faq-intro h2 {
        font-size: 24px;
    }

    .faq-intro p {
        font-size: 14px;
    }

    .faq-categories {
        gap: 8px;
    }

    .category-btn {
        padding: 10px 18px;
        font-size: 14px;
    }

    .faq-question {
        padding: 20px;
    }

    .faq-question h3 {
        font-size: 16px;
    }

    .faq-answer {
        padding: 0 20px;
    }

    .faq-item.active .faq-answer {
        padding: 0 20px 20px;
    }

    .faq-answer p,
    .faq-answer li {
        font-size: 14px;
    }

    .faq-contact-box {
        padding: 40px 25px;
    }

    .faq-contact-box i {
        font-size: 36px;
    }

    .faq-contact-box h3 {
        font-size: 22px;
    }

    .faq-contact-box p {
        font-size: 14px;
    }

    .contact-buttons {
        flex-direction: column;
        gap: 10px;
    }

    .contact-btn {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .faq-intro {
        margin-bottom: 30px;
    }

    .faq-intro h2 {
        font-size: 20px;
    }

    .faq-question {
        padding: 15px;
    }

    .faq-question h3 {
        font-size: 15px;
        padding-right: 10px;
    }

    .faq-contact-box {
        padding: 30px 20px;
    }
}

/* Animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.faq-item {
    animation: fadeIn 0.3s ease;
}

/* 로딩, 빈 상태, 오류 상태 */
.loading-state,
.empty-state,
.error-state {
    text-align: center;
    padding: 80px 20px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.08);
    margin: 20px 0;
}

.loading-state i {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 20px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.empty-state i {
    font-size: 4rem;
    color: #adb5bd;
    margin-bottom: 20px;
}

.error-state i {
    font-size: 4rem;
    color: #ef4444;
    margin-bottom: 20px;
}

.loading-state p,
.empty-state p,
.error-state p {
    color: #6c757d;
    font-size: 1.1rem;
    margin: 0;
}
