/**
 * NCM FAQ Manager - Frontend Styles
 */

/* Auto Display Container */
.ncm-faq-auto-display {
    margin: 3rem 0;
    padding: 2rem 0;
}

.ncm-faq-auto-title {
    font-size: 2rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 3px solid #c54545;
}

/* FAQ Container */
.faq-container {
    margin: 3rem auto !important;
    padding: 2rem;
    max-width: 100%;
    margin-left: auto !important;
    margin-right: auto !important;
}

.faq-container.col-md-8 {
    width: 66.66666667%;
    margin-left: auto !important;
    margin-right: auto !important;
    float: none !important;
    display: block;
}

@media (max-width: 991px) {
    .faq-container.col-md-8 {
        width: 100%;
    }
}

.faq-container h1.faq-main-title {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: #c54545;
    text-align: center;
}

.faq-container h2 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: #2c3e50;
    text-align: center;
}

.faq-container .faq-subtitle {
    font-size: 1.4rem;
    color: #6c757d;
    margin-bottom: 2rem;
    text-align: center;
}

/* FAQ List */
.faq-list {
    margin: 2rem 0;
}

/* General FAQ Container */
.ncm-faq-list,
.ncm-faq-accordion,
.ncm-faq-toggle,
.ncm-faq-tabs,
.ncm-faq-grouped {
    margin: 2rem 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

/* FAQ Item */
.faq-item,
.ncm-faq-item {
    margin-bottom: 1.5rem;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
    transition: box-shadow 0.3s ease;
}

.faq-item:hover,
.ncm-faq-item:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* FAQ Question */
.faq-question {
    margin: 0;
}

.faq-toggle {
    width: 100%;
    padding: 1.25rem 1.5rem;
    background: #ece6e2;
    border: none;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    text-align: left;
    transition: background-color 0.3s ease;
}

.faq-toggle:hover {
    background: #e0d7d1;
}

.faq-toggle:focus {
    outline: 2px solid #c54545;
    outline-offset: -2px;
}

.faq-question-text {
    flex: 1;
    font-size: 19.2px;
    font-weight: 600;
    color: #2c3e50;
    margin: 0;
    font-family: 'Akrobat', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

.faq-icon {
    width: 24px;
    height: 24px;
    margin-left: 1rem;
    position: relative;
    flex-shrink: 0;
}

.faq-icon::before,
.faq-icon::after {
    content: '';
    position: absolute;
    background: #6c757d;
    transition: transform 0.3s ease;
}

.faq-icon::before {
    width: 14px;
    height: 2px;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.faq-icon::after {
    width: 2px;
    height: 14px;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.faq-toggle[aria-expanded="true"] .faq-icon::after {
    transform: translate(-50%, -50%) rotate(90deg);
    opacity: 0;
}

/* FAQ Question */
.ncm-faq-question {
    padding: 1.25rem 1.5rem;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #ece6e2;
    transition: background-color 0.3s ease;
}

.ncm-faq-question:hover {
    background: #e0d7d1;
}

.ncm-faq-question h3 {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 600;
    color: #2c3e50;
    flex: 1;
}

/* FAQ Toggle Icon */
.ncm-faq-toggle,
.ncm-faq-icon {
    font-size: 1.5rem;
    color: #6c757d;
    font-weight: bold;
    margin-left: 1rem;
    transition: transform 0.3s ease;
    flex-shrink: 0;
}

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

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

/* FAQ Answer */
.faq-answer,
.ncm-faq-answer {
    border-top: 1px solid #e0e0e0;
    background: #fff;
}

.faq-answer[hidden] {
    display: none;
}

.faq-answer-content {
    padding: 0px 40px 20px 40px;
    line-height: 1.7;
    color: #2a2a2a;
    font-family: 'Akrobat', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    font-size: 19.2px !important;
    -webkit-hyphens: auto;
    -moz-hyphens: auto;
    -ms-hyphens: auto;
    hyphens: auto;
    word-wrap: break-word;
}

.faq-answer-content p,
.ncm-faq-answer p {
    margin: 0 0 10px;
    font-family: 'Akrobat', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    font-size: 19.2px !important;
    line-height: 1.42857143;
    color: #2a2a2a;
    -webkit-hyphens: auto;
    -moz-hyphens: auto;
    -ms-hyphens: auto;
    hyphens: auto;
    word-wrap: break-word;
}

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

/* Footer Elements - Scoped to FAQ Container */
.faq-container .generatedBy {
    margin-top: 1.5rem;
    padding: 0.75rem 1rem;
    border-top: 1px solid #e0e0e0;
    background: #ffffff;
    font-size: 1.1rem;
    color: #6c757d;
    text-align: center;
}

.faq-container .generatedBy a {
    color: #c54545;
    text-decoration: none;
}

.faq-container .generatedBy a:hover {
    text-decoration: underline;
}

.faq-container .faqDSGVO {
    margin-top: 0.5rem;
    padding: 0.75rem 1rem;
    background: #ffffff;
    border-radius: 4px;
    font-size: 1rem;
    color: #6c757d;
    text-align: center;
}

.faq-container .faqDSGVO a {
    color: #c54545;
    text-decoration: none;
}

.faq-container .faqDSGVO a:hover {
    text-decoration: underline;
}

/* List Style (Always Visible) */
.ncm-faq-list .ncm-faq-question {
    cursor: default;
    background: #fff;
    border-bottom: 2px solid #c54545;
}

.ncm-faq-list .ncm-faq-question:hover {
    background: #fff;
}

.ncm-faq-list .ncm-faq-answer {
    border-top: none;
}

/* Accordion Style */
.ncm-faq-accordion .ncm-faq-answer {
    display: none;
    animation: fadeIn 0.3s ease;
}

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

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

/* Toggle Style */
.ncm-faq-toggle .ncm-faq-answer {
    display: none;
}

.ncm-faq-toggle .ncm-faq-item.active .ncm-faq-answer {
    display: block;
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        max-height: 0;
    }
    to {
        opacity: 1;
        max-height: 500px;
    }
}

/* Tabs Style */
.ncm-faq-tabs {
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
}

.ncm-faq-tabs-nav {
    display: flex;
    flex-wrap: wrap;
    background: #ece6e2;
    border-bottom: 2px solid #e0e0e0;
}

.ncm-faq-tab-button {
    flex: 1;
    min-width: 150px;
    padding: 1rem 1.5rem;
    border: none;
    background: transparent;
    cursor: pointer;
    font-size: 0.95rem;
    font-weight: 500;
    color: #6c757d;
    transition: all 0.3s ease;
    border-bottom: 3px solid transparent;
}

.ncm-faq-tab-button:hover {
    background: #e0d7d1;
    color: #2c3e50;
}

.ncm-faq-tab-button.active {
    background: #fff;
    color: #c54545;
    border-bottom-color: #c54545;
}

.ncm-faq-tabs-content {
    padding: 2rem;
    background: #fff;
}

.ncm-faq-tab-panel {
    display: none;
    animation: fadeIn 0.3s ease;
}

.ncm-faq-tab-panel.active {
    display: block;
}

/* Grouped FAQs */
.ncm-faq-group {
    margin-bottom: 3rem;
}

.ncm-faq-group-title {
    font-size: 1.75rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 3px solid #c54545;
}

/* Responsive Design */
@media (max-width: 768px) {
    .ncm-faq-question h3 {
        font-size: 1rem;
    }
    
    .ncm-faq-question,
    .ncm-faq-answer {
        padding: 1rem;
    }
    
    .ncm-faq-tab-button {
        min-width: 100%;
        text-align: left;
    }
    
    .ncm-faq-tabs-content {
        padding: 1rem;
    }
}

/* Print Styles */
@media print {
    .ncm-faq-answer {
        display: block !important;
    }
    
    .ncm-faq-toggle,
    .ncm-faq-icon,
    .ncm-faq-tabs-nav {
        display: none;
    }
    
    .ncm-faq-tab-panel {
        display: block !important;
        page-break-inside: avoid;
    }
}

/* Accessibility */
.ncm-faq-question:focus {
    outline: 2px solid #c54545;
    outline-offset: 2px;
}

.ncm-faq-tab-button:focus {
    outline: 2px solid #c54545;
    outline-offset: -2px;
}

/* Custom Styling Options */
.ncm-faq-item.ncm-faq-highlighted {
    border-color: #c54545;
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.1);
}

.ncm-faq-item.ncm-faq-featured .ncm-faq-question {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
}

.ncm-faq-item.ncm-faq-featured .ncm-faq-question h3 {
    color: #fff;
}

.ncm-faq-item.ncm-faq-featured .ncm-faq-toggle,
.ncm-faq-item.ncm-faq-featured .ncm-faq-icon {
    color: #fff;
}

