/* ===== FAQ SECTION STYLES - MODERN, CLEAN & SLEEK ===== */
/* Designed to match the default template's modern aesthetic */

/* ===== FAQ PAGE & ARCHIVE LAYOUT ===== */

.ikbase-faq-page,
.ikbase-faq-archive {
    padding: 3rem 0;
    background: linear-gradient(180deg, #f8fafc 0%, #ffffff 100%);
    min-height: 100vh;
}

.ikbase-container {
    max-width: var(--ikbase-layout-shell-max);
    margin: 0 auto;
    padding: 0 var(--ikbase-layout-shell-pad-x);
    box-sizing: border-box;
}

/* ===== PAGE HEADER ===== */

.ikbase-page-header,
.ikbase-archive-header {
    text-align: center;
    margin-bottom: 4rem;
    animation: fadeInDown 0.8s ease-out;
}

.ikbase-page-title,
.ikbase-archive-title {
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 800;
    color: #0f172a;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #1e73be 0%, #0ea5e9 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.02em;
    line-height: 1.2;
}

.ikbase-page-description,
.ikbase-archive-description {
    font-size: 1.125rem;
    color: #64748b;
    max-width: 650px;
    margin: 0 auto;
    line-height: 1.6;
    font-weight: 400;
}

/* ===== SEARCH SECTION ===== */

.ikbase-faq-search {
    margin-bottom: 4rem;
    animation: fadeInUp 0.8s ease-out 0.2s both;
}

.ikbase-search-form {
    max-width: 600px;
    margin: 0 auto;
}

.ikbase-search-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(30, 115, 190, 0.08),
                0 1px 3px rgba(0, 0, 0, 0.05);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 2px solid transparent;
}

.ikbase-search-input-wrapper:hover {
    box-shadow: 0 8px 30px rgba(30, 115, 190, 0.12),
                0 2px 6px rgba(0, 0, 0, 0.08);
    transform: translateY(-2px);
}

.ikbase-search-input-wrapper:focus-within {
    border-color: #1e73be;
    box-shadow: 0 8px 30px rgba(30, 115, 190, 0.15),
                0 0 0 4px rgba(30, 115, 190, 0.08);
    transform: translateY(-2px);
}

.ikbase-search-input {
    width: 100%;
    padding: 1.125rem 4rem 1.125rem 1.5rem;
    border: none;
    border-radius: 16px;
    font-size: 1rem;
    color: #1e293b;
    background: transparent;
    outline: none;
    font-weight: 400;
    transition: all 0.2s ease;
}

.ikbase-search-input::placeholder {
    color: #94a3b8;
    font-weight: 400;
}

.ikbase-search-input:focus::placeholder {
    color: #cbd5e1;
}

.ikbase-search-submit {
    position: absolute;
    right: 0.75rem;
    background: linear-gradient(135deg, #1e73be 0%, #0ea5e9 100%);
    border: none;
    color: #ffffff;
    cursor: pointer;
    padding: 0.75rem 1.25rem;
    border-radius: 12px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(30, 115, 190, 0.25);
}

.ikbase-search-submit:hover {
    background: linear-gradient(135deg, #0056b3 0%, #0284c7 100%);
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(30, 115, 190, 0.35);
}

.ikbase-search-submit:active {
    transform: scale(0.98);
}

.ikbase-search-submit .dashicons {
    font-size: 20px;
    width: 20px;
    height: 20px;
}

/* ===== FAQ CONTENT AREA ===== */

.ikbase-faq-content {
    animation: fadeIn 0.8s ease-out 0.4s both;
}

/* ===== TOPIC SECTIONS ===== */

.ikbase-faq-topic-section {
    margin-bottom: 4rem;
    animation: fadeInUp 0.6s ease-out both;
}

.ikbase-faq-topic-section:nth-child(1) { animation-delay: 0.1s; }
.ikbase-faq-topic-section:nth-child(2) { animation-delay: 0.2s; }
.ikbase-faq-topic-section:nth-child(3) { animation-delay: 0.3s; }
.ikbase-faq-topic-section:nth-child(4) { animation-delay: 0.4s; }

.ikbase-topic-header {
    margin-bottom: 2rem;
    padding-bottom: 1.25rem;
    border-bottom: 3px solid #e2e8f0;
    position: relative;
}

.ikbase-topic-header::after {
    content: '';
    position: absolute;
    bottom: -3px;
    left: 0;
    width: 80px;
    height: 3px;
    background: linear-gradient(135deg, #1e73be 0%, #0ea5e9 100%);
    border-radius: 2px;
}

.ikbase-topic-title {
    font-size: 1.875rem;
    font-weight: 700;
    color: #0f172a;
    margin-bottom: 0.75rem;
    letter-spacing: -0.01em;
    line-height: 1.3;
}

.ikbase-topic-description {
    color: #64748b;
    font-size: 1rem;
    margin-bottom: 1rem;
    line-height: 1.6;
}

.ikbase-topic-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-top: 0.75rem;
}

.ikbase-faq-count {
    background: linear-gradient(135deg, #1e73be 0%, #0ea5e9 100%);
    color: white;
    padding: 0.375rem 1rem;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(30, 115, 190, 0.25);
    letter-spacing: 0.01em;
}

/* ===== FAQ LIST & ITEMS ===== */

.ikbase-faq-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.ikbase-faq-item {
    background: #ffffff;
    border: 2px solid #e2e8f0;
    border-radius: 16px;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.ikbase-faq-item:hover {
    border-color: #cbd5e1;
    box-shadow: 0 8px 24px rgba(30, 115, 190, 0.12);
    transform: translateY(-2px);
}

.ikbase-faq-item.active {
    border-color: #1e73be;
    box-shadow: 0 8px 32px rgba(30, 115, 190, 0.15);
}

/* ===== FAQ QUESTION (ACCORDION HEADER) ===== */

.ikbase-faq-question {
    padding: 1.5rem 2rem;
    background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1.5rem;
    transition: all 0.3s ease;
    position: relative;
}

.ikbase-faq-item:hover .ikbase-faq-question {
    background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 100%);
}

.ikbase-faq-item.active .ikbase-faq-question {
    background: linear-gradient(135deg, #1e73be 0%, #0ea5e9 100%);
}

.ikbase-faq-question h3 {
    margin: 0;
    font-size: 1.125rem;
    font-weight: 600;
    color: #1e293b;
    flex: 1;
    line-height: 1.5;
    transition: color 0.3s ease;
}

.ikbase-faq-item.active .ikbase-faq-question h3 {
    color: #ffffff;
}

/* ===== FAQ TOGGLE ICON ===== */

.ikbase-faq-toggle {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #e2e8f0;
    color: #64748b;
    border-radius: 8px;
    font-size: 1.5rem;
    font-weight: 600;
    line-height: 1;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    flex-shrink: 0;
}

.ikbase-faq-item:hover .ikbase-faq-toggle {
    background: #cbd5e1;
    color: #475569;
}

.ikbase-faq-item.active .ikbase-faq-toggle {
    background: rgba(255, 255, 255, 0.25);
    color: #ffffff;
    transform: rotate(45deg);
}

/* ===== FAQ ANSWER (ACCORDION CONTENT) ===== */

.ikbase-faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                padding 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                opacity 0.3s ease;
    opacity: 0;
    border-top: 1px solid transparent;
}

.ikbase-faq-item.active .ikbase-faq-answer {
    max-height: 2000px;
    padding: 2rem;
    opacity: 1;
    border-top-color: #e2e8f0;
}

.ikbase-faq-content {
    color: #475569;
    line-height: 1.75;
    font-size: 1rem;
}

.ikbase-faq-content p {
    margin-bottom: 1rem;
}

.ikbase-faq-content p:last-child {
    margin-bottom: 0;
}

.ikbase-faq-content ul,
.ikbase-faq-content ol {
    margin: 1rem 0;
    padding-left: 1.5rem;
}

.ikbase-faq-content li {
    margin-bottom: 0.5rem;
}

.ikbase-faq-content strong {
    color: #1e293b;
    font-weight: 600;
}

.ikbase-faq-content a {
    color: #1e73be;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

.ikbase-faq-content a:hover {
    color: #0056b3;
    text-decoration: underline;
}

/* ===== FAQ TOPIC LABEL (IN SEARCH RESULTS) ===== */

.ikbase-faq-topic {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e2e8f0;
    font-size: 0.875rem;
    color: #64748b;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.ikbase-faq-topic-label {
    font-weight: 600;
    color: #475569;
}

.ikbase-faq-topic a {
    color: #1e73be;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

.ikbase-faq-topic a:hover {
    color: #0056b3;
    text-decoration: underline;
}

/* ===== SEARCH RESULTS & NO RESULTS ===== */

.ikbase-search-results,
.ikbase-no-results,
.ikbase-no-faqs {
    margin-bottom: 3rem;
    padding: 2rem;
    background: #ffffff;
    border-radius: 16px;
    border: 2px solid #e2e8f0;
}

.ikbase-search-results h2,
.ikbase-no-results h2,
.ikbase-no-faqs h2 {
    font-size: 1.75rem;
    font-weight: 700;
    color: #0f172a;
    margin-bottom: 1rem;
}

.ikbase-no-results p,
.ikbase-no-faqs p {
    color: #64748b;
    font-size: 1rem;
    line-height: 1.6;
}

/* ===== CTA SECTION ===== */

.ikbase-faq-cta {
    margin-top: 5rem;
    padding: 3.5rem 2rem;
    background: linear-gradient(135deg, #1e73be 0%, #0ea5e9 100%);
    border-radius: 24px;
    text-align: center;
    color: white;
    box-shadow: 0 12px 40px rgba(30, 115, 190, 0.25);
    position: relative;
    overflow: hidden;
}

.ikbase-faq-cta::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(14, 165, 233, 0.3) 0%, transparent 50%);
    pointer-events: none;
}

.ikbase-cta-content {
    position: relative;
    z-index: 1;
}

.ikbase-cta-content h3 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: #ffffff;
    letter-spacing: -0.01em;
}

.ikbase-cta-content p {
    margin-bottom: 2rem;
    opacity: 0.95;
    font-size: 1.125rem;
    line-height: 1.6;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.ikbase-cta-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.ikbase-cta-button {
    padding: 1rem 2rem;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.ikbase-cta-button:hover {
    transform: translateY(-3px);
    text-decoration: none;
}

.ikbase-primary-button {
    background: #ffffff;
    color: #1e73be;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.ikbase-primary-button:hover {
    background: #f8fafc;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
    color: #1e73be;
}

.ikbase-secondary-button {
    background: rgba(255, 255, 255, 0.15);
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(10px);
}

.ikbase-secondary-button:hover {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.6);
    color: white;
}

/* ===== ANIMATIONS ===== */

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===== RESPONSIVE DESIGN ===== */

@media (max-width: 768px) {
    .ikbase-faq-page,
    .ikbase-faq-archive {
        padding: 2rem 0;
    }

    .ikbase-page-header,
    .ikbase-archive-header {
        margin-bottom: 3rem;
    }

    .ikbase-page-title,
    .ikbase-archive-title {
        font-size: 2rem;
    }

    .ikbase-page-description,
    .ikbase-archive-description {
        font-size: 1rem;
    }

    .ikbase-faq-search {
        margin-bottom: 3rem;
    }

    .ikbase-search-input {
        padding: 1rem 3.5rem 1rem 1.25rem;
        font-size: 0.9375rem;
    }

    .ikbase-search-submit {
        padding: 0.625rem 1rem;
    }

    .ikbase-topic-title {
        font-size: 1.5rem;
    }

    .ikbase-faq-question {
        padding: 1.25rem 1.5rem;
    }

    .ikbase-faq-question h3 {
        font-size: 1rem;
    }

    .ikbase-faq-toggle {
        width: 28px;
        height: 28px;
        font-size: 1.25rem;
    }

    .ikbase-faq-item.active .ikbase-faq-answer {
        padding: 1.5rem;
    }

    .ikbase-faq-cta {
        padding: 2.5rem 1.5rem;
        margin-top: 4rem;
    }

    .ikbase-cta-content h3 {
        font-size: 1.5rem;
    }

    .ikbase-cta-content p {
        font-size: 1rem;
    }

    .ikbase-cta-buttons {
        flex-direction: column;
        align-items: center;
    }

    .ikbase-cta-button {
        width: 100%;
        max-width: 300px;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .ikbase-page-title,
    .ikbase-archive-title {
        font-size: 1.75rem;
    }

    .ikbase-topic-title {
        font-size: 1.25rem;
    }

    .ikbase-faq-question {
        padding: 1rem 1.25rem;
    }

    .ikbase-faq-question h3 {
        font-size: 0.9375rem;
    }

    .ikbase-faq-item.active .ikbase-faq-answer {
        padding: 1.25rem;
    }

    .ikbase-search-input {
        padding: 0.875rem 3rem 0.875rem 1rem;
        font-size: 0.875rem;
    }

    .ikbase-search-submit {
        padding: 0.5rem 0.875rem;
    }

    .ikbase-search-submit .dashicons {
        font-size: 18px;
        width: 18px;
        height: 18px;
    }
}

/* ===== ACCESSIBILITY ===== */

.ikbase-faq-question:focus {
    outline: 2px solid #1e73be;
    outline-offset: 2px;
}

.ikbase-faq-question:focus:not(:focus-visible) {
    outline: none;
}

/* ===== PRINT STYLES ===== */

@media print {
    .ikbase-faq-search,
    .ikbase-faq-cta {
        display: none;
    }

    .ikbase-faq-item {
        page-break-inside: avoid;
        border: 1px solid #e2e8f0;
        box-shadow: none;
    }

    .ikbase-faq-answer {
        max-height: none !important;
        opacity: 1 !important;
        padding: 1rem !important;
    }

    .ikbase-faq-toggle {
        display: none;
    }
}
