/* VOUCHER BOX — 09-28 redesign, per reference mockup: label line (icon +
   "Få X% med rabatkoden") on its own row on top, "Rabatkode: {code}" + copy
   button on its own row below — was a single row that only wrapped to two
   lines when cramped (mobile), with the code/button pinned to the right
   edge via justify-content:space-between. Recolored from the old
   orange/amber "ticket stub" look to the site's teal, matching every other
   CTA/accent this session's redesign has unified onto. Sits directly under
   .ttpc-offer-row inside the same <li> (or the equivalent merchant row in
   .tt-compare-hero / .featured-price-panel), so its side margins match that
   row's own horizontal padding. */

.product-voucher-box {
    background: #fff;
    border: 1px solid rgba(0, 150, 136, .25);
    border-radius: 8px;
    margin: 0 16px 10px;
    padding: 10px 12px;
    position: relative;
    z-index: 2;
}

.voucher-body {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
}

/* MAIN LINE */

.voucher-main-line {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: #111827;
}

.voucher-tag-icon {
    width: 14px;
    height: 14px;
    fill: #0f6b63;
    flex-shrink: 0;
}

/* CODE */

.voucher-code-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
}

.voucher-code-label {
    font-size: 13px;
    color: #6b7280;
}

.voucher-code {
    background: #eaf6f4;
    border: 1px solid rgba(0, 150, 136, .3);
    color: #0f6b63;
    font-weight: 700;
    font-size: 13px;
    padding: 5px 10px;
    border-radius: 6px;
    white-space: nowrap;
}

.voucher-copy-btn {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    background: #0f6b63;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    flex-shrink: 0;
    padding: 0;
    transition: background-color .2s;
}

.voucher-copy-btn:hover {
    background: #0c554e;
}

.voucher-copy-btn svg {
    width: 14px;
    height: 14px;
    fill: #fff;
}

.voucher-copy-btn.copied {
    background: #15803d;
    color: #fff;
    font-size: 13px;
    font-weight: 700;
}

/* EXPIRY */

.voucher-expiry-countdown {
    font-size: 11px;
    color: #9a3412;
    margin-top: 2px;
    width: 100%;
}

@media (max-width: 600px) {
    .product-voucher-box {
        margin: 0 12px 10px;
        padding: 8px 10px;
    }
    .voucher-main-line {
        font-size: 12px;
    }
    .voucher-code {
        font-size: 12px;
        padding: 4px 8px;
    }
}

/* 09-28: "Alle forhandlere" list rows revert to the ORIGINAL inline/orange
   look (label left, code+copy-button right, one row) — per direct request,
   after seeing the 09-28 redesign (stacked, teal) applied there too. Scoped
   to .ttpc-full-panel specifically so .tt-compare-hero and
   .featured-price-panel — which don't use .voucher-body at all; their split
   layout builds .voucher-main-line/.voucher-code-wrap directly, see
   buildVoucherLabelBox()/buildVoucherCodeBox() in product-voucher.js — keep
   today's teal split treatment untouched regardless of what happens here. */
.product-template .ttpc-full-panel .product-voucher-box {
    border-color: #fed7aa;
}
.product-template .ttpc-full-panel .voucher-body {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
}
.product-template .ttpc-full-panel .voucher-tag-icon {
    fill: #f97316;
}
.product-template .ttpc-full-panel .voucher-code-label {
    display: none;
}
.product-template .ttpc-full-panel .voucher-code {
    background: #fff7ed;
    border-color: #fed7aa;
    color: #9a3412;
}
.product-template .ttpc-full-panel .voucher-copy-btn {
    background: #f97316;
}
.product-template .ttpc-full-panel .voucher-copy-btn:hover {
    background: #ea6c0a;
}
@media (max-width: 600px) {
    /* Same "stay on one line, truncate the label instead of wrapping"
       handling the pre-09-28 version had — reverting to row layout above
       brings this exact issue back on narrow widths (label + code + copy
       button don't all fit), so it needs to come back too. */
    .product-template .ttpc-full-panel .voucher-body {
        flex-wrap: nowrap;
    }
    .product-template .ttpc-full-panel .voucher-main-line {
        min-width: 0;
        flex: 1 1 auto;
    }
    .product-template .ttpc-full-panel .voucher-main-line span {
        min-width: 0;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
        display: block;
    }
    .product-template .ttpc-full-panel .voucher-code-wrap {
        flex: 0 0 auto;
    }
}

/* MERGED LAYOUT — .tt-compare-hero / .featured-price-panel only. Both build
   TWO separate .product-voucher-box pieces (see
   buildVoucherLabelBox()/buildVoucherCodeBox() in product-voucher.js) but
   place them ADJACENT, below the trust row, styled to read as one
   continuous card (see the label/code radius split further down). Neither
   piece needs the base rule's card border/background/side-margin — both
   contexts already provide their own padding and centered layout, so these
   start out as plain, borderless, centered lines before the card styling
   below is layered on. */
.tt-compare-hero .product-voucher-box,
.featured-price-panel .product-voucher-box {
    background: none;
    border: none;
    margin: 0;
    padding: 0;
}

/* Label sits directly above the code box (both placed together right after
   the trust row — see injectVouchers() in product-voucher.js), merged into
   ONE continuous bordered box instead of plain text sitting above a
   separately-boxed code line: label gets the box's top half (rounded top
   corners, no bottom border so it joins seamlessly with the code piece
   below), code gets the bottom half (see its own adjacent-sibling override
   further down). Same treatment for both panels — they're visually
   identical now. */
.tt-compare-hero .voucher-label-only,
.featured-price-panel .voucher-label-only {
    margin: 10px 0 0;
    background: #fdf3e0;
    border: 1px solid rgba(184, 134, 58, .35);
    border-bottom: none;
    border-radius: 8px 8px 0 0;
    padding: 8px 12px 4px;
}

.tt-compare-hero .voucher-label-only .voucher-main-line,
.featured-price-panel .voucher-label-only .voucher-main-line {
    justify-content: center;
}

/* 09-28: recolored orange to match the "Alle forhandlere" offer-list's own
   voucher (see the scoped .ttpc-full-panel revert further up) — was teal,
   inherited from the base (still-teal) .voucher-code/.voucher-copy-btn
   rules. Also boxed in a light bordered callout (was borderless, just text)
   so it reads as more noticeable without going back to a heavy/loud look —
   "modern but noticeable" per request. */
.tt-compare-hero .voucher-code-only,
.featured-price-panel .voucher-code-only {
    margin: 10px 0 0;
    background: #fff7ed;
    border: 1px solid #fed7aa;
    border-radius: 8px;
    padding: 8px 12px;
}
/* Directly preceded by its own label (see above) — forms the bottom half
   of the same merged box: no top margin (the label already supplies the
   gap above the whole box), no top border/radius (joins seamlessly with
   the label piece), tighter top padding since the label's own bottom
   padding already provides some breathing room above the code line. */
.tt-compare-hero .voucher-label-only + .voucher-code-only,
.featured-price-panel .voucher-label-only + .voucher-code-only {
    margin-top: 0;
    border-top: none;
    border-radius: 0 0 8px 8px;
    padding-top: 4px;
}
/* 09-29: featured box's voucher box recolored gold to match its own "VI
   ANBEFALER" ribbon (tt-hero.css) — same #fdf3e0/#92670f/
   rgba(184,134,58,.35)/#b8863a palette already shared across the ribbon,
   .product-highlight, and .featured-sticky-badge. 09-30: .tt-compare-hero's
   own voucher box joins the same palette — the two panels are meant to
   look identical now, so there's no reason left for hero to stay orange
   here (it still has no ribbon of its own, but that's no longer the
   deciding factor). */
.tt-compare-hero .voucher-code-only,
.featured-price-panel .voucher-code-only {
    background: #fdf3e0;
    border-color: rgba(184, 134, 58, .35);
}
.tt-compare-hero .voucher-code-only .voucher-code,
.featured-price-panel .voucher-code-only .voucher-code {
    border-color: rgba(184, 134, 58, .35);
    color: #92670f;
}
.tt-compare-hero .voucher-code-only .voucher-copy-btn,
.featured-price-panel .voucher-code-only .voucher-copy-btn {
    background: #b8863a;
}
.tt-compare-hero .voucher-code-only .voucher-copy-btn:hover,
.featured-price-panel .voucher-code-only .voucher-copy-btn:hover {
    background: #9c7530;
}
.tt-compare-hero .voucher-label-only .voucher-tag-icon,
.featured-price-panel .voucher-label-only .voucher-tag-icon {
    fill: #b8863a;
}

.tt-compare-hero .voucher-code-only .voucher-code-wrap,
.featured-price-panel .voucher-code-only .voucher-code-wrap {
    justify-content: center;
}

.tt-compare-hero .voucher-code-only .voucher-code,
.featured-price-panel .voucher-code-only .voucher-code {
    background: #fff;
    border-color: #fed7aa;
    color: #9a3412;
}
.tt-compare-hero .voucher-code-only .voucher-copy-btn,
.featured-price-panel .voucher-code-only .voucher-copy-btn {
    background: #f97316;
}
.tt-compare-hero .voucher-code-only .voucher-copy-btn:hover,
.featured-price-panel .voucher-code-only .voucher-copy-btn:hover {
    background: #ea6c0a;
}
/* 09-29: fixes the copy button doing nothing (actually falling through to
   the full-card affiliate link instead) inside .tt-compare-hero
   specifically. Root cause: the copy button lives INSIDE .ttpc-offer-row
   here (inserted as a sibling of .ttpc-col-cta, see buildVoucherCodeBox()'s
   insertion point in product-voucher.js), and tt-price-compare's own
   base CSS sets `.ttpc-offer-row { pointer-events: none }` so its full-row
   .ttpc-offer-link overlay (position:absolute;inset:0, covering the whole
   .tt-compare-hero — see product-compare-redesign.css's comment on
   .tt-compare-hero itself) is clickable everywhere except the specific
   elements the base plugin re-enables (`.ttpc-offer-row a`/`.ttpc-cta`/
   `.ttpc-restore-btn`, same rule, `pointer-events:auto; position:relative;
   z-index:2`). .voucher-copy-btn is none of those, so it silently inherited
   `pointer-events:none` and was invisible to clicks — the offer-link
   underneath caught them instead, navigating to the merchant rather than
   copying the code. .featured-price-panel never had this problem: it has
   no .ttpc-offer-link at all (a plain .featured-merchant-name anchor
   instead), so its copy button was never blocked in the first place — this
   is a .tt-compare-hero-only fix, same 3-property pattern the base plugin
   already uses for its own buttons/links in this exact situation. */
.tt-compare-hero .voucher-copy-btn {
    pointer-events: auto;
    position: relative;
    z-index: 2;
}
.tt-compare-hero .voucher-label-only .voucher-tag-icon,
.featured-price-panel .voucher-label-only .voucher-tag-icon {
    fill: #f97316;
}

/* 09-30: .tt-compare-hero's order sequence is now trust-line(0) ->
   price(1) -> cta(2) -> price-trust-row(3, merchant included, see
   product-compare-redesign.css) -> voucher label+code(4, here) — matching
   [featured_product_box]'s own top-to-bottom order. Both voucher pieces
   share order 4 (tied): they're inserted adjacent in the DOM (label right
   before code, see injectVouchers() in product-voucher.js), and equal-order
   flex items keep their DOM order as the tiebreak, so label still renders
   above code. .featured-price-panel has no `order` system at all (its
   children just follow plain DOM order), so no equivalent rule is needed
   there. */
.tt-compare-hero .voucher-label-only,
.tt-compare-hero .voucher-code-only {
    order: 4;
}


.expert-guide-accordion {
    margin-top: 16px;
    margin-bottom: 0;
    border-bottom: 1px solid #009688;

}

.expert-guide-header {
    width: 100%;
    background: none;
    border: 0;
    padding: 14px 0;
    font-weight: bold;
    font-size: 22px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
}

.expert-guide-accordion p {
    color: #3F3F3F;
    line-height: 30px;
}

.accordion-icon {
    font-size: 20px;
    line-height: 1;
}

/* Chevron icon */
.expert-guide-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    cursor: pointer;
}

.expert-guide-header .chevron {
    width: 10px;
    height: 10px;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(45deg); /* points down-right */
    transition: transform 0.3s ease;
    margin-left: 10px;
}

/* Rotate when open */
.expert-guide-header[aria-expanded="true"] .chevron {
    transform: rotate(-135deg); /* points up */
}