/* ==========================================================================
   OPRANIC - FAQ (variant A v3: tabs-layout med sticky sidebar)
   --------------------------------------------------------------------------
   Renderas av shortcode [opr_faq] (registrerad i WPCode-snippet).
   Laddas dynamiskt nar shortcoden anvands pa en sida.

   Designspraket matchar:
     - opr-home.css (40x3px orange streck, 11px uppercase eyebrow)
     - opr-tier0.css (22px H2 weight 400, 36x2px accent, split-rows)
     - opr-guides.css (single-post brodtext-typografi)

   Native <details>/<summary> for tillganglighet och SEO.

   v3 (2026-05-09): Tabs-mode. Alla kategorier i DOM, JS vaxlar display.
                    SEO-vanligt (allt i HTML fran start).
   v2 (2026-05-09): Split-layout 280px sidebar + flexibel right column.
                    Stackad rendering per kategori.

   Version: 3.0 (2026-05-09)
   ========================================================================== */

/* ==========================================================================
   0. HERO (samma monster som .opr-guides-hero, scopad till FAQ)
   ========================================================================== */

.opr-faq-hero {
    position: relative;
    width: 100%;
    height: 480px;
    overflow: hidden;
    border-radius: 2px;
    margin-bottom: 60px;
}
.opr-faq-hero__bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
    z-index: 0;
}
.opr-faq-hero__overlay {
    position: absolute;
    inset: 0;
    background: rgba(10, 8, 5, 0.55);
    clip-path: polygon(0 0, 46% 0, 35% 100%, 0 100%);
    z-index: 1;
}
.opr-faq-hero__text {
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    z-index: 2;
    padding: 0 52px;
    max-width: 480px;
}
.opr-faq-hero__overline {
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: #EE9305;
    margin: 0 0 10px 0;
}
.opr-faq-hero__title {
    font-size: clamp(20px, 2vw, 32px);
    font-weight: 300;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #ffffff;
    margin: 0;
    line-height: 1.2;
    word-break: keep-all;
    overflow-wrap: normal;
    hyphens: none;
    white-space: normal;
}
.opr-faq-hero__accent {
    width: 48px;
    height: 3px;
    background: #EE9305;
    margin: 14px 0 16px;
}
.opr-faq-hero__sub {
    font-family: Georgia, 'Times New Roman', serif;
    font-style: italic;
    font-size: clamp(14px, 1.2vw, 18px);
    color: rgba(255, 255, 255, 0.82);
    margin: 0;
    line-height: 1.4;
}

@media (max-width: 1024px) {
    .opr-faq-hero { height: 360px; }
    .opr-faq-hero__overlay { clip-path: polygon(0 0, 54% 0, 38% 100%, 0 100%); }
    .opr-faq-hero__text { padding: 0 36px; }
    .opr-faq-hero__title {
        font-size: clamp(18px, 2.6vw, 26px);
        letter-spacing: 0.06em;
    }
}

@media (max-width: 768px) {
    .opr-faq-hero {
        height: 240px;
        margin-left: calc(50% - 50vw) !important;
        margin-right: calc(50% - 50vw) !important;
        width: 100vw !important;
        max-width: 100vw !important;
        border-radius: 0 !important;
    }
    .opr-faq-hero__overlay { clip-path: polygon(0 0, 58% 0, 40% 100%, 0 100%); }
    .opr-faq-hero__text { padding: 0 20px; max-width: 65%; }
    .opr-faq-hero__overline { font-size: 9px; letter-spacing: 2px; margin-bottom: 6px; }
    .opr-faq-hero__accent { width: 28px; height: 2px; margin: 8px 0 10px; }
    .opr-faq-hero__sub { font-size: 12px; }
    .opr-faq-hero__title {
        font-size: clamp(14px, 4.5vw, 20px);
        letter-spacing: 0.05em;
    }
}

/* ==========================================================================
   1. OUTER WRAPPER + HEADER
   ========================================================================== */

.opr-faq-section {
    max-width: 1500px;
    margin: 32px auto;
    padding: 0 15px;
}

.opr-faq-section__header {
    margin-bottom: 32px;
}

.opr-faq-section__accent {
    width: 40px;
    height: 3px;
    background: #EE9305;
    margin: 0 0 11px;
}

.opr-faq-section__overline {
    font-size: 11px;
    font-weight: 500;
    color: #EE9305;
    text-transform: uppercase;
    letter-spacing: 2.5px;
    margin: 0 0 10px;
}

.opr-faq-section__title {
    color: #262626;
    font-size: 20px;
    line-height: 26px;
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: normal;
    margin: 0 0 12px;
}

.opr-faq-section__intro {
    color: #444;
    font-size: 16px;
    line-height: 1.6;
    margin: 0;
    max-width: 690px;
}

/* ==========================================================================
   2. SPLIT LAYOUT (sidebar + content)
   ========================================================================== */

.opr-faq-split {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 64px;
    align-items: start;
}

/* ==========================================================================
   3. SIDEBAR (sticky vansterkolumn)
   ========================================================================== */

.opr-faq-sidebar {
    position: sticky;
    top: 24px;
}

.opr-faq-sidebar__counter {
    font-size: 10px;
    font-weight: 500;
    color: #EE9305;
    text-transform: uppercase;
    letter-spacing: 2.5px;
    margin: 0 0 10px;
}

.opr-faq-sidebar__title {
    color: #222222;
    font-size: 22px;
    font-weight: 400;
    line-height: 1.25;
    margin: 0 0 6px;
    transition: color 0.2s ease;
}

.opr-faq-sidebar__accent {
    width: 36px;
    height: 2px;
    background: #EE9305;
    margin: 10px 0 18px;
}

.opr-faq-sidebar__desc {
    color: #666666;
    font-size: 14px;
    line-height: 1.6;
    margin: 0 0 24px;
}

.opr-faq-sidebar__nav-label {
    font-size: 11px;
    font-weight: 500;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin: 0 0 10px;
}

.opr-faq-sidebar__nav {
    display: flex;
    flex-direction: column;
    gap: 0;
    border-top: 0.5px solid #ECE8E0;
    padding-top: 16px;
}

.opr-faq-sidebar__nav-item {
    font-size: 15px;
    font-weight: 500;
    color: #444;
    text-decoration: none;
    padding: 12px 0;
    border-bottom: 0.5px solid #F0EBE0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    transition: color 0.2s ease, padding-left 0.2s ease;
    cursor: pointer;
}

.opr-faq-sidebar__nav-item:last-child {
    border-bottom: none;
}

.opr-faq-sidebar__nav-item:hover {
    color: #EE9305;
    padding-left: 4px;
}

.opr-faq-sidebar__nav-item--active {
    color: #EE9305;
    font-weight: 600;
    padding-left: 4px;
    border-left: 2px solid #EE9305;
    margin-left: -8px;
    padding-left: 6px;
}

.opr-faq-sidebar__nav-count {
    color: #aaa;
    font-size: 12px;
    font-weight: 400;
}

.opr-faq-sidebar__nav-item--active .opr-faq-sidebar__nav-count {
    color: #EE9305;
}

/* ==========================================================================
   4. PANELS (varje kategori = en panel, JS vaxlar display)
   ========================================================================== */

.opr-faq-panels {
    position: relative;
}

.opr-faq-panel {
    display: none;
    animation: oprFaqPanelFade 0.3s ease;
}

.opr-faq-panel--active {
    display: block;
}

@keyframes oprFaqPanelFade {
    from {
        opacity: 0;
        transform: translateY(6px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ==========================================================================
   5. ACCORDION
   ========================================================================== */

.opr-faq {
    border-top: 0.5px solid #ECE8E0;
}

.opr-faq__item {
    border-bottom: 0.5px solid #ECE8E0;
}

.opr-faq__item[open] .opr-faq__icon {
    transform: rotate(180deg);
    color: #EE9305;
}

/* ==========================================================================
   6. SUMMARY (klickbar rad)
   ========================================================================== */

.opr-faq__summary {
    list-style: none;
    cursor: pointer;
    padding: 24px 4px;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
    transition: color 0.2s ease;
}

.opr-faq__summary::-webkit-details-marker {
    display: none;
}
.opr-faq__summary::marker {
    display: none;
}

.opr-faq__summary:hover .opr-faq__question {
    color: #EE9305;
}

.opr-faq__summary:hover .opr-faq__icon {
    color: #EE9305;
}

.opr-faq__summary:focus-visible {
    outline: 2px solid #EE9305;
    outline-offset: 2px;
    border-radius: 2px;
}

/* ==========================================================================
   7. QUESTION
   ========================================================================== */

.opr-faq__question {
    font-size: 17px;
    font-weight: 500;
    color: #222222;
    line-height: 1.4;
    transition: color 0.2s ease;
}

/* ==========================================================================
   8. ICON (chevron)
   ========================================================================== */

.opr-faq__icon {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #888888;
    margin-top: 2px;
    transition: transform 0.25s ease, color 0.2s ease;
}

/* ==========================================================================
   9. ANSWER
   ========================================================================== */

.opr-faq__answer {
    padding: 0 4px 28px;
    font-size: 15px;
    line-height: 1.7;
    color: #444444;
}

.opr-faq__answer p {
    margin: 0 0 14px;
    font-size: 15px;
    line-height: 1.7;
    color: #444444;
}

.opr-faq__answer p:last-child {
    margin-bottom: 0;
}

.opr-faq__answer ul,
.opr-faq__answer ol {
    margin: 0 0 14px;
    padding-left: 22px;
}

.opr-faq__answer li {
    font-size: 15px;
    line-height: 1.7;
    color: #444444;
    margin-bottom: 6px;
}

.opr-faq__answer strong {
    color: #222222;
    font-weight: 600;
}

.opr-faq__answer a {
    color: #EE9305;
    text-decoration: none;
    border-bottom: 0.5px solid rgba(238, 147, 5, 0.4);
    transition: border-color 0.2s ease;
}

.opr-faq__answer a:hover {
    border-bottom-color: #EE9305;
}

/* ==========================================================================
   10. READ MORE-LANK
   ========================================================================== */

.opr-faq__readmore {
    margin-top: 18px !important;
    margin-bottom: 0 !important;
}

.opr-faq__readmore a {
    display: inline-block;
    font-size: 13px;
    font-weight: 500;
    color: #EE9305;
    text-decoration: none;
    letter-spacing: 0.02em;
    border-bottom: none;
}

.opr-faq__readmore a:hover {
    color: #d4820a;
    border-bottom: none;
}

/* ==========================================================================
   11. ANSWER-ANIMATION
   ========================================================================== */

@media (prefers-reduced-motion: no-preference) {
    .opr-faq__answer {
        animation: oprFaqSlide 0.25s ease-out;
    }

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

/* ==========================================================================
   12. NOSCRIPT FALLBACK (visa allt content om JS ar av)
   ========================================================================== */

.opr-faq-noscript-section {
    margin-bottom: 48px;
}

.opr-faq-noscript-section__title {
    color: #222;
    font-size: 22px;
    font-weight: 400;
    line-height: 1.25;
    margin: 0 0 6px;
}

.opr-faq-noscript-section__accent {
    width: 36px;
    height: 2px;
    background: #EE9305;
    margin: 10px 0 24px;
}

/* Nar JS aktiveras visas tabs istallet och fallback dolds */
.js-enabled .opr-faq-noscript-fallback {
    display: none;
}

/* ==========================================================================
   13. RESPONSIVT - tablet (stackar sidebar ovanpa, blir horisontellt nav)
   ========================================================================== */

@media (max-width: 960px) {
    .opr-faq-split {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .opr-faq-sidebar {
        position: static;
    }

    .opr-faq-sidebar__counter,
    .opr-faq-sidebar__accent,
    .opr-faq-sidebar__desc,
    .opr-faq-sidebar__nav-label {
        display: none;
    }

    .opr-faq-sidebar__title {
        font-size: 18px;
        margin-bottom: 14px;
    }

    .opr-faq-sidebar__nav {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 8px;
        padding-top: 0;
        border-top: none;
        margin-top: 4px;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .opr-faq-sidebar__nav-item {
        padding: 7px 14px;
        background: #F8F6F2;
        border: 0.5px solid #ECE8E0;
        border-radius: 20px;
        font-size: 12px;
        white-space: nowrap;
        border-bottom: 0.5px solid #ECE8E0;
    }

    .opr-faq-sidebar__nav-item:hover {
        padding-left: 14px;
    }

    .opr-faq-sidebar__nav-item--active {
        background: #EE9305;
        color: #fff;
        border-color: #EE9305;
        margin-left: 0;
        padding-left: 14px;
        border-left: 0.5px solid #EE9305;
    }

    .opr-faq-sidebar__nav-item--active:hover {
        color: #fff;
        padding-left: 14px;
    }

    .opr-faq-sidebar__nav-item--active .opr-faq-sidebar__nav-count {
        color: rgba(255, 255, 255, 0.7);
    }
}

/* ==========================================================================
   14. RESPONSIVT - mobil
   ========================================================================== */

@media (max-width: 640px) {
    .opr-faq-section {
        margin: 24px auto;
    }

    .opr-faq-section__title {
        font-size: 18px;
        line-height: 24px;
    }

    .opr-faq-section__intro {
        font-size: 15px;
    }

    .opr-faq__summary {
        padding: 20px 2px;
        gap: 16px;
    }

    .opr-faq__question {
        font-size: 16px;
    }

    .opr-faq__answer {
        padding: 0 2px 24px;
        font-size: 14.5px;
    }

    .opr-faq__answer p,
    .opr-faq__answer li {
        font-size: 14.5px;
    }
}
/* ==========================================================================
   16. INTRO-RAD (vanster orange linje, matchar tier0 .opr-intro-row)
   --------------------------------------------------------------------------
   Ersatter den gamla section-headern (eyebrow + uppercase title + intro).
   ========================================================================== */

.opr-faq-section__intro-row {
    margin: 0 auto 48px;
    max-width: 1500px;
    padding: 0 15px;
}

.opr-faq-section__intro-inner {
    padding: 36px 15px 36px 24px;
    border-left: 3px solid #EE9305;
}

.opr-faq-section__intro-text,
.opr-faq-section__intro-text p {
    font-size: 17px;
    line-height: 1.75;
    color: #262626;
    margin: 0;
}

@media (max-width: 768px) {
    .opr-faq-section__intro-inner {
        padding: 24px 12px 24px 18px;
    }
    .opr-faq-section__intro-text,
    .opr-faq-section__intro-text p {
        font-size: 15px;
        line-height: 1.65;
    }
}
/* === SLUT pa opr-faq CSS ================================================ */