/**
 * FAQ Module - Frontend CSS
 * Yazı sayfasındaki sıkça sorulan sorular accordion stilleri
 */

/* ============================================
   ANA SECTION
   ============================================ */
.news-faq-section {
    margin: 30px 0;
    padding: 20px;
    background: #fff;
    border: 1px solid #e8e8e8;
    border-radius: 8px;
}

/* ============================================
   BAŞLIK
   ============================================ */
.news-faq-title {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 15px 0;
    padding-bottom: 12px;
    font-size: 18px;
    font-weight: 700;
    color: #1d2327;
    border-bottom: 2px solid #dc3545;
}

.news-faq-title .faq-icon {
    font-size: 20px;
    line-height: 1;
}

/* ============================================
   ACCORDION
   ============================================ */
.news-faq-accordion {
    display: flex;
    flex-direction: column;
    gap: 0;
    border: 1px solid #e5e5e5;
    border-radius: 6px;
    overflow: hidden;
}

/* ============================================
   ACCORDION ITEM
   ============================================ */
.faq-accordion-item {
    background: #fff;
    border: none;
    border-bottom: 1px solid #e5e5e5;
    border-radius: 0;
    overflow: hidden;
    transition: background 0.2s ease;
}

.faq-accordion-item:last-child {
    border-bottom: none;
}

.faq-accordion-item:hover {
    background: #fafafa;
}

.faq-accordion-item.active {
    background: #f8f9fa;
}

/* ============================================
   ACCORDION HEADER (SORU)
   ============================================ */
.faq-accordion-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 12px 15px;
    background: transparent;
    border: none;
    cursor: pointer;
    text-align: left;
    transition: background 0.2s ease;
}

.faq-accordion-header:hover {
    background: #f5f5f5;
}

.faq-accordion-item.active .faq-accordion-header {
    background: transparent;
    border-bottom: 1px solid #e0e0e0;
}

.faq-question {
    flex: 1;
    font-size: 14px;
    font-weight: 600;
    color: #1d2327;
    line-height: 1.4;
    padding-right: 10px;
}

.faq-accordion-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    background: #e9ecef;
    border-radius: 50%;
    color: #666;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.faq-accordion-item.active .faq-accordion-icon {
    background: #dc3545;
    color: #fff;
    transform: rotate(180deg);
}

.faq-accordion-icon svg {
    display: block;
    width: 14px;
    height: 14px;
}

/* ============================================
   ACCORDION CONTENT (CEVAP)
   ============================================ */
.faq-accordion-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.faq-accordion-item.active .faq-accordion-content {
    max-height: 1000px;
}

.faq-answer {
    padding: 12px 15px 15px 15px;
    font-size: 14px;
    line-height: 1.6;
    color: #555;
    background: #fafafa;
}

.faq-answer p {
    margin: 0 0 15px 0;
}

.faq-answer p:last-child {
    margin-bottom: 0;
}

.faq-answer ul,
.faq-answer ol {
    margin: 15px 0;
    padding-left: 25px;
}

.faq-answer li {
    margin-bottom: 8px;
}

.faq-answer a {
    color: #2271b1;
    text-decoration: none;
}

.faq-answer a:hover {
    text-decoration: underline;
}

.faq-answer strong {
    color: #1d2327;
}

/* ============================================
   SEPARATOR LINE
   ============================================ */
.faq-accordion-item.active .faq-accordion-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 20px;
    right: 20px;
    height: 1px;
    background: #e0e0e0;
}

.faq-accordion-header {
    position: relative;
}

/* ============================================
   RESPONSİVE
   ============================================ */
@media screen and (max-width: 768px) {
    .news-faq-section {
        margin: 30px 0;
        padding: 20px;
        border-radius: 8px;
    }
    
    .news-faq-title {
        font-size: 20px;
        gap: 10px;
    }
    
    .news-faq-title .faq-icon {
        font-size: 24px;
    }
    
    .faq-accordion-header {
        padding: 15px;
    }
    
    .faq-question {
        font-size: 15px;
    }
    
    .faq-accordion-icon {
        width: 28px;
        height: 28px;
    }
    
    .faq-accordion-icon svg {
        width: 16px;
        height: 16px;
    }
    
    .faq-answer {
        padding: 0 15px 15px 15px;
        font-size: 14px;
    }
}

/* ============================================
   PRINT STYLES
   ============================================ */
@media print {
    .news-faq-section {
        break-inside: avoid;
        box-shadow: none;
        border: 1px solid #ddd;
    }
    
    .faq-accordion-content {
        max-height: none !important;
    }
    
    .faq-accordion-icon {
        display: none;
    }
    
    .faq-accordion-header {
        cursor: default;
    }
    
    .faq-accordion-item.active .faq-accordion-header::after {
        display: none;
    }
}

/* ============================================
   DARK MODE
   ============================================ */
@media (prefers-color-scheme: dark) {
    .news-faq-section {
        background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
    }
    
    .news-faq-title {
        color: #e0e0e0;
        border-bottom-color: #444;
    }
    
    .faq-accordion-item {
        background: #2d2d2d;
        border-color: #444;
    }
    
    .faq-accordion-item:hover,
    .faq-accordion-item.active {
        border-color: #4d9de0;
    }
    
    .faq-accordion-header:hover {
        background: #333;
    }
    
    .faq-accordion-item.active .faq-accordion-header {
        background: #1a3a5c;
    }
    
    .faq-question {
        color: #e0e0e0;
    }
    
    .faq-accordion-icon {
        background: #444;
        color: #999;
    }
    
    .faq-accordion-item.active .faq-accordion-icon {
        background: #4d9de0;
        color: #fff;
    }
    
    .faq-answer {
        color: #bbb;
    }
    
    .faq-answer strong {
        color: #e0e0e0;
    }
    
    .faq-answer a {
        color: #4d9de0;
    }
}

/* ============================================
   ANİMASYONLAR
   ============================================ */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.news-faq-section {
    animation: fadeInUp 0.5s ease;
}

/* Staggered animation for items */
.faq-accordion-item:nth-child(1) { animation-delay: 0.1s; }
.faq-accordion-item:nth-child(2) { animation-delay: 0.15s; }
.faq-accordion-item:nth-child(3) { animation-delay: 0.2s; }
.faq-accordion-item:nth-child(4) { animation-delay: 0.25s; }
.faq-accordion-item:nth-child(5) { animation-delay: 0.3s; }