/*
 * Customer type (Privat / Företag / Kommun) — banner and switcher.
 *
 * Loaded site-wide; every rule is prefixed .sc-ct- so nothing bleeds into
 * Beaver Builder layouts. The banner ships hidden via the `hidden` attribute
 * and is revealed by customer-type.js, so it costs nothing until it is used.
 *
 * Brand tokens (mirrors checkout.css):
 *   --sc-dark:   #0E1B22
 *   --sc-blue:   #008CC6
 *   --sc-card:   #E0EEF9
 *   --sc-border: #c8dde8
 */

/* ── "You were redirected" banner ─────────────────────────────────────────── */

.sc-ct-banner {
    background: #E0EEF9;
    border-bottom: 1px solid #c8dde8;
    color: #0E1B22;
    font-size: 15px;
    line-height: 1.5;
}

.sc-ct-banner__inner {
    align-items: center;
    display: flex;
    gap: 16px;
    justify-content: space-between;
    margin: 0 auto;
    max-width: 1100px;
    padding: 12px 20px;
}

.sc-ct-banner__text {
    margin: 0;
}

.sc-ct-banner__link {
    color: #008CC6;
    text-decoration: underline;
    white-space: nowrap;
}

.sc-ct-banner__dismiss {
    background: none;
    border: 0;
    color: #0E1B22;
    cursor: pointer;
    font-size: 22px;
    line-height: 1;
    padding: 0 4px;
}

/* ── Switcher ─────────────────────────────────────────────────────────────── */

.sc-ct-switcher__list {
    display: flex;
    gap: 4px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.sc-ct-switcher__link {
    border-radius: 999px;
    color: #0E1B22;
    display: inline-block;
    font-size: 14px;
    line-height: 1;
    padding: 8px 14px;
    text-decoration: none;
}

.sc-ct-switcher__link:hover,
.sc-ct-switcher__link:focus-visible {
    background: #E0EEF9;
}

/*
 * The current item is the visitor's *preference*, published on <html> by the
 * head script — not the type of the page, which stays Privat while a Företag
 * visitor walks through pages that have no Företag version. A cached page
 * cannot know the preference, so nothing is marked current server-side.
 */
html[data-ct-pref="privat"]  .sc-ct-switcher__link[data-ct-set="privat"],
html[data-ct-pref="foretag"] .sc-ct-switcher__link[data-ct-set="foretag"],
html[data-ct-pref="kommun"]  .sc-ct-switcher__link[data-ct-set="kommun"] {
    background: #0E1B22;
    color: #ffffff;
}

@media (max-width: 600px) {
    .sc-ct-banner__inner {
        align-items: flex-start;
        gap: 8px;
        padding: 10px 16px;
    }
}

/*
 * The provisional `.sc-ct-bar` strip that used to sit above the header was
 * removed when the switcher moved into the site header itself (phase 2). Its
 * styling now lives in menu.css, scoped to `.sc-header`, because the design
 * calls for plain text with pipe separators there rather than these pills.
 */
