/*
 * Lagerboks – landingssiden for minilager ([lagerboks_minilager] på /minilager/).
 * Samme farger, skrift og knapper som forsideutkastet og veiviseren: mørkeblå til overskrifter,
 * handlingsblå #0077b6 til knapper og lenker (4,9:1 mot hvit), logoens blå bare som aksent.
 */
.lgbx-ml {
    --ml-navy: #0b2239;
    --ml-ink: #111827;
    --ml-muted: #4b5563;
    --ml-line: #e3e8ef;
    --ml-bg: #f4f7fb;
    --ml-blue: #0077b6;
    --ml-blue-dark: #005f93;
    --ml-blue-soft: #e8f3fa;
    --ml-cyan: #00b0f0;
    --ml-cyan-soft: #e3f5fd;
    --ml-green: #15803d;
    --ml-green-soft: #e7f6ec;
    --ml-radius: 16px;
    --ml-shadow: 0 10px 30px rgba(11, 34, 57, 0.08);
    /* Full bredde, selv om temaet legger innholdet i en ramme på 1140 px. */
    position: relative;
    left: 50%;
    width: 100vw;
    margin-left: -50vw;
    color: var(--ml-ink);
    font-size: 17px;
    line-height: 1.55;
    text-align: left;
    -webkit-font-smoothing: antialiased;
}

/* «Use Any Font» setter Open Sans med !important på overskrifter, p, li og a. */
.lgbx-ml,
.lgbx-ml * {
    font-family: Inter, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif !important;
    letter-spacing: normal;
}

.lgbx-ml *,
.lgbx-ml *::before,
.lgbx-ml *::after {
    box-sizing: border-box;
}

/* Temaets luft rundt innholdet tas bort på sider med landingssiden, og siden får ikke vannrett rulling. */
body.lgbx-har-landing {
    overflow-x: hidden;
}

body.lgbx-har-landing #theme-page .theme-content {
    padding-top: 0 !important;
    padding-bottom: 0 !important;
}

.lgbx-ml__wrap {
    width: min(1200px, 100% - 40px);
    margin: 0 auto;
}

/* grunn.css setter svart på «.refresh p» (regel fra det gamle refresh-stilarket); derfor body foran. */
body .lgbx-ml p {
    margin: 0;
    color: var(--ml-muted);
    font-size: inherit;
}

.lgbx-ml a {
    display: inline;
    margin: 0;
    font-size: inherit;
}

.lgbx-ml img {
    display: block;
    max-width: 100%;
    height: auto;
}

.lgbx-ml svg {
    flex: none;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.lgbx-ml__skjult {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

/* ── Overskrifter ───────────────────────────────── */

.lgbx-ml .lgbx-ml__h1,
.lgbx-ml .lgbx-ml__h2,
.lgbx-ml .lgbx-ml__h3 {
    margin: 0;
    padding: 0;
    color: var(--ml-navy);
    line-height: 1.15;
    letter-spacing: -0.02em;
    text-transform: none;
}

.lgbx-ml .lgbx-ml__h1 {
    max-width: 14ch;
    font-size: clamp(34px, 4.4vw, 56px) !important;
    font-weight: 800 !important;
    text-wrap: balance;
}

.lgbx-ml .lgbx-ml__h2 {
    font-size: clamp(26px, 3vw, 38px) !important;
    font-weight: 800 !important;
}

.lgbx-ml .lgbx-ml__h3 {
    font-size: 20px !important;
    font-weight: 700 !important;
    letter-spacing: -0.01em;
}

.lgbx-ml__merke {
    display: inline-block;
    margin-bottom: 14px;
    color: var(--ml-blue);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.lgbx-ml .lgbx-ml__ingress {
    max-width: 60ch;
    font-size: 19px;
    text-wrap: pretty;
}

.lgbx-ml__hode .lgbx-ml__ingress {
    max-width: none;
}

/* ── Knapper og lenker ──────────────────────────── */

.lgbx-ml a.lgbx-ml__knapp {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 54px;
    padding: 0 28px;
    border: 2px solid transparent;
    border-radius: 10px;
    background: var(--ml-blue);
    box-shadow: 0 8px 20px rgba(0, 119, 182, 0.25);
    color: #fff;
    font-size: 17px;
    font-weight: 600;
    line-height: 1.2;
    text-align: center;
    text-decoration: none;
    transition: background-color 0.15s ease, transform 0.15s ease;
}

.lgbx-ml a.lgbx-ml__knapp:hover {
    background: var(--ml-blue-dark);
    color: #fff;
    transform: translateY(-1px);
}

.lgbx-ml a.lgbx-ml__knapp:focus-visible,
.lgbx-ml a.lgbx-ml__lenke:focus-visible,
.lgbx-ml a.lgbx-ml__telefon:focus-visible {
    outline: 3px solid var(--ml-cyan);
    outline-offset: 3px;
}

.lgbx-ml a.lgbx-ml__knapp--bred {
    width: 100%;
}

.lgbx-ml a.lgbx-ml__knapp--lys {
    background: #fff;
    box-shadow: none;
    color: var(--ml-navy);
}

.lgbx-ml a.lgbx-ml__knapp--lys:hover {
    background: var(--ml-cyan-soft);
    color: var(--ml-navy);
}

.lgbx-ml a.lgbx-ml__lenke {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--ml-blue);
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
}

.lgbx-ml a.lgbx-ml__lenke:hover {
    color: var(--ml-blue-dark);
    text-decoration: underline;
}

.lgbx-ml a.lgbx-ml__lenke svg {
    width: 18px;
    height: 18px;
}

.lgbx-ml a.lgbx-ml__lenke--lys,
.lgbx-ml a.lgbx-ml__lenke--lys:hover {
    color: #fff;
}

/* ── Hero ───────────────────────────────────────── */

.lgbx-ml__hero {
    padding: 64px 0 56px;
    background: linear-gradient(180deg, #f7fafd 0%, #fff 100%);
}

.lgbx-ml__hero-rute {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
    gap: 56px;
    align-items: center;
}

.lgbx-ml__hero .lgbx-ml__h1 {
    margin-bottom: 18px;
}

.lgbx-ml__hero .lgbx-ml__ingress {
    margin-bottom: 28px;
}

.lgbx-ml__knapper {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 14px 24px;
    margin-bottom: 28px;
}

.lgbx-ml ul.lgbx-ml__haker,
.lgbx-ml ul.lgbx-ml__punkter {
    display: grid;
    gap: 10px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.lgbx-ml ul.lgbx-ml__haker li,
.lgbx-ml ul.lgbx-ml__punkter li {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin: 0;
    padding: 0;
    color: var(--ml-muted);
    font-size: 15.5px;
    line-height: 1.45;
    list-style: none;
}

.lgbx-ml ul.lgbx-ml__haker svg,
.lgbx-ml ul.lgbx-ml__punkter svg {
    width: 22px;
    height: 22px;
    padding: 4px;
    border-radius: 50%;
    background: var(--ml-green-soft);
    color: var(--ml-green);
    stroke-width: 3;
}

.lgbx-ml__hero-bilde {
    overflow: hidden;
    border-radius: 24px;
    box-shadow: 0 24px 60px rgba(11, 34, 57, 0.16);
}

.lgbx-ml__hero-bilde img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
}

/* ── Seksjoner ──────────────────────────────────── */

.lgbx-ml__seksjon {
    padding: 80px 0;
}

.lgbx-ml__seksjon--lys {
    background: var(--ml-bg);
}

.lgbx-ml__seksjon--mork {
    padding: 64px 0;
    background: var(--ml-navy);
}

.lgbx-ml__hode {
    max-width: 760px;
    margin-bottom: 40px;
}

.lgbx-ml__hode .lgbx-ml__h2 {
    margin-bottom: 12px;
}

.lgbx-ml__midt {
    margin-top: 36px;
    text-align: center;
}

/* ── Avdelingskortene ───────────────────────────── */

.lgbx-ml__kort-rute {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
}

.lgbx-ml__kort {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid var(--ml-line);
    border-radius: var(--ml-radius);
    background: #fff;
    box-shadow: var(--ml-shadow);
}

.lgbx-ml a.lgbx-ml__kort-bilde {
    display: block;
    background: var(--ml-bg);
}

.lgbx-ml__kort-bilde img {
    width: 100%;
    aspect-ratio: 16 / 10;
    object-fit: cover;
}

.lgbx-ml__kort-innhold {
    display: flex;
    flex: 1;
    flex-direction: column;
    padding: 24px 24px 26px;
}

.lgbx-ml__kort .lgbx-ml__h3 {
    font-size: 24px !important;
}

.lgbx-ml__kort .lgbx-ml__h3 span {
    margin-left: 10px;
    color: var(--ml-muted);
    font-size: 15px;
    font-weight: 500;
    letter-spacing: 0;
}

.lgbx-ml p.lgbx-ml__adresse {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 8px 0 18px;
    color: var(--ml-muted);
    font-size: 15px;
}

.lgbx-ml__adresse svg {
    width: 18px;
    height: 18px;
    color: var(--ml-blue);
}

.lgbx-ml p.lgbx-ml__ledig {
    display: flex;
    flex-direction: column;
    gap: 2px;
    margin: 20px 0 18px;
    padding: 12px 14px;
    border-radius: 10px;
    background: var(--ml-green-soft);
    color: #14532d;
    font-size: 15px;
    line-height: 1.4;
}

.lgbx-ml__ledig strong {
    font-weight: 700;
}

.lgbx-ml p.lgbx-ml__ledig--tom {
    background: #fff4d6;
    color: #6b4500;
}

.lgbx-ml__kort-knapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    margin-top: auto;
}

/* ── Fordeler ───────────────────────────────────── */

.lgbx-ml__fordeler {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 24px;
}

.lgbx-ml__fordel {
    padding: 26px 24px;
    border: 1px solid var(--ml-line);
    border-radius: var(--ml-radius);
    background: #fff;
}

.lgbx-ml__ikon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    margin-bottom: 16px;
    border-radius: 12px;
    background: var(--ml-cyan-soft);
    color: var(--ml-blue);
}

.lgbx-ml__ikon svg {
    width: 26px;
    height: 26px;
}

.lgbx-ml__fordel .lgbx-ml__h3 {
    margin-bottom: 8px;
}

.lgbx-ml .lgbx-ml__fordel p {
    font-size: 16px;
}

/* ── Tre steg ───────────────────────────────────── */

.lgbx-ml ol.lgbx-ml__steg {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.lgbx-ml ol.lgbx-ml__steg li {
    margin: 0;
    padding: 26px 24px;
    border: 1px solid var(--ml-line);
    border-radius: var(--ml-radius);
    background: #fff;
    list-style: none;
}

.lgbx-ml__nr {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    margin-bottom: 14px;
    border-radius: 50%;
    background: var(--ml-navy);
    color: #fff;
    font-size: 15px;
    font-weight: 800;
}

.lgbx-ml__steg .lgbx-ml__h3 {
    margin-bottom: 8px;
}

.lgbx-ml .lgbx-ml__steg p {
    font-size: 16px;
}

.lgbx-ml__steg p a {
    color: var(--ml-blue);
    font-weight: 600;
    text-decoration: underline;
}

.lgbx-ml p.lgbx-ml__merknad {
    margin-top: 28px;
    padding: 16px 20px;
    border-radius: 12px;
    background: var(--ml-blue-soft);
    color: var(--ml-navy);
    font-size: 16px;
    text-align: center;
}

/* ── Mørkt bånd: mobilt minilager og kontakt ────── */

.lgbx-ml__to {
    display: grid;
    grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
    gap: 56px;
    align-items: start;
}

.lgbx-ml__seksjon--mork .lgbx-ml__h2 {
    margin-bottom: 14px;
    color: #fff;
    font-size: clamp(24px, 2.4vw, 30px) !important;
}

body .lgbx-ml .lgbx-ml__seksjon--mork p {
    max-width: 52ch;
    margin-bottom: 24px;
    color: #c8d3e0;
}

.lgbx-ml__kontakt {
    padding-left: 56px;
    border-left: 1px solid rgba(255, 255, 255, 0.18);
}

.lgbx-ml a.lgbx-ml__telefon {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
    color: #fff;
    font-size: 30px;
    font-weight: 800;
    letter-spacing: -0.01em;
    text-decoration: none;
}

.lgbx-ml__telefon svg {
    width: 28px;
    height: 28px;
    color: var(--ml-cyan);
}

/* ── Tilbudsmerke (2.21.0) ──────────────────────────
   Lite merke med navnet på tilbudet og en kort tekst (views/sider/deler/tilbudsmerke.php). Står der
   prisene står: i priskortene, på romkortene og på avdelingskortene. Fargen følger sesongen som i den
   store brikken under bildet: grønn uten sesong, varm om høsten, blå i jula og gul i påsken.
   --bilde ligger oppå et bilde, --mork står på mørk bakgrunn, og --tekst er uten flate (i løpende tekst). */

.lgbx-ml .lgbx-ml__tilbudsmerke {
    --tm-aksent: #166534;
    --tm-flate: var(--ml-green-soft);
    display: inline-flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 1px 8px;
    max-width: 100%;
    padding: 6px 12px;
    border-radius: 10px;
    background: var(--tm-flate);
    color: var(--ml-navy);
    font-size: 15px;
    font-weight: 600;
    line-height: 1.35;
    text-align: left;
    vertical-align: baseline;
}

.lgbx-ml .lgbx-ml__tilbudsmerke > b {
    color: var(--tm-aksent);
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    white-space: nowrap;
}

.lgbx-ml .lgbx-ml__tilbudsmerke > b::before {
    display: none;
    width: 13px;
    height: 13px;
    margin-right: 5px;
    background: center / contain no-repeat;
    vertical-align: -1px;
    content: "";
}

.lgbx-ml .lgbx-ml__tilbudsmerke--host {
    --tm-aksent: #9a3412;
    --tm-flate: #fdf0e1;
}

.lgbx-ml .lgbx-ml__tilbudsmerke--jul {
    --tm-aksent: #1d4f80;
    --tm-flate: #e6f0fa;
}

.lgbx-ml .lgbx-ml__tilbudsmerke--paske {
    --tm-aksent: #854d0e;
    --tm-flate: #fdf5d3;
}

.lgbx-ml .lgbx-ml__tilbudsmerke--host > b::before,
.lgbx-ml .lgbx-ml__tilbudsmerke--jul > b::before,
.lgbx-ml .lgbx-ml__tilbudsmerke--paske > b::before {
    display: inline-block;
}

.lgbx-ml .lgbx-ml__tilbudsmerke--host > b::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23c2571a' d='M12 1.5c4.6 3.4 7 7.500 7 11.500 0 4.200-3 7.400-7 7.400s-7-3.200-7-7.400c0-4 2.400-8.100 7-11.500z'/%3E%3Cpath fill='none' stroke='%238a3a0d' stroke-width='1.200' stroke-linecap='round' d='M12 6v16.500M12 11l3.200-2.600M12 14.500l-3.400-2.700M12 17.500l2.800-2.200'/%3E%3C/svg%3E");
}

.lgbx-ml .lgbx-ml__tilbudsmerke--jul > b::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='none' stroke='%232f6fa8' stroke-width='2' stroke-linecap='round' d='M12 2v20M3.300 7l17.400 10M3.300 17 20.700 7M12 6l-2.500-2M12 6l2.500-2M12 18l-2.500 2M12 18l2.500 2'/%3E%3C/svg%3E");
}

.lgbx-ml .lgbx-ml__tilbudsmerke--paske > b::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23f4c542' d='M12 2c4 0 7.500 6 7.500 11.500 0 5-3.300 8.500-7.500 8.500s-7.500-3.500-7.500-8.500C4.500 8 8 2 12 2z'/%3E%3Cpath fill='none' stroke='%23fff' stroke-width='1.600' stroke-linecap='round' stroke-linejoin='round' d='m5.500 12.500 2.200 2 2.200-2 2.100 2 2.100-2 2.200 2 2.200-2'/%3E%3C/svg%3E");
}

.lgbx-ml .lgbx-ml__tilbudsmerke--bilde {
    padding: 6px 11px;
    background: #fff;
    box-shadow: 0 4px 12px rgba(11, 34, 57, 0.2);
    font-size: 14px;
}

.lgbx-ml .lgbx-ml__tilbudsmerke--tekst {
    display: inline;
    padding: 0;
    background: none;
}

.lgbx-ml .lgbx-ml__tilbudsmerke--tekst > b {
    margin-right: 6px;
}

.lgbx-ml .lgbx-ml__tilbudsmerke--mork {
    --tm-aksent: #86efac;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.lgbx-ml .lgbx-ml__tilbudsmerke--mork.lgbx-ml__tilbudsmerke--host {
    --tm-aksent: #fdba74;
}

.lgbx-ml .lgbx-ml__tilbudsmerke--mork.lgbx-ml__tilbudsmerke--jul {
    --tm-aksent: #bfdbfe;
}

.lgbx-ml .lgbx-ml__tilbudsmerke--mork.lgbx-ml__tilbudsmerke--paske {
    --tm-aksent: #fde68a;
}

/* På avdelingskortet ligger merket oppå bildet, øverst til venstre. */
.lgbx-ml__kort {
    position: relative;
}

body .lgbx-ml p.lgbx-ml__kort-tilbud {
    position: absolute;
    top: 14px;
    left: 14px;
    z-index: 1;
    max-width: calc(100% - 28px);
    margin: 0;
    pointer-events: none;
}

/* Navnet over teksten, så merket er like høyt på alle kortene uansett hvor lang teksten er. */
.lgbx-ml .lgbx-ml__kort-tilbud .lgbx-ml__tilbudsmerke {
    flex-direction: column;
    align-items: flex-start;
}

/* Nettbrett: kortet ligger på tvers, med bildet til venstre (38 % av bredden). */
@media (min-width: 761px) and (max-width: 1000px) {
    body .lgbx-ml p.lgbx-ml__kort-tilbud {
        max-width: calc(38% - 28px);
    }
}

/* ── Nettbrett og mobil ─────────────────────────── */

@media (max-width: 1000px) {
    .lgbx-ml__kort-rute,
    .lgbx-ml ol.lgbx-ml__steg {
        grid-template-columns: minmax(0, 1fr);
    }

    .lgbx-ml__kort {
        flex-direction: row;
    }

    /* Bildet fyller venstre del av kortet. Før 2.21.0 ble kortene på /minilager/ 1 500 px høye her (samme
       feil som #229 rettet i stegene og tjenestekortene): «aspect-ratio: auto» tok bort forholdet fra
       bildets width og height, grunn.css («.theme-content img», lastes senere) satte høyden til auto, og
       bilder som lastes sent med sizes="auto", får da nettleserens reservehøyde på 1 500 px. Derfor står
       bildet absolutt i lenka, og velgeren er tyngre enn den i grunn.css. */
    .lgbx-ml a.lgbx-ml__kort-bilde {
        position: relative;
        flex: 0 0 38%;
        min-height: 220px;
    }

    .lgbx-ml a.lgbx-ml__kort-bilde img {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        aspect-ratio: auto;
    }

    .lgbx-ml__kort-knapper {
        flex-direction: row;
        gap: 20px;
    }

    .lgbx-ml a.lgbx-ml__knapp--bred {
        width: auto;
    }

    .lgbx-ml__fordeler {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 760px) {
    .lgbx-ml {
        font-size: 16px;
    }

    .lgbx-ml__hero {
        padding: 36px 0 40px;
    }

    .lgbx-ml__hero-rute,
    .lgbx-ml__to {
        grid-template-columns: minmax(0, 1fr);
        gap: 32px;
    }

    .lgbx-ml .lgbx-ml__h1 {
        max-width: none;
    }

    .lgbx-ml .lgbx-ml__ingress {
        font-size: 17px;
    }

    .lgbx-ml__knapper {
        flex-direction: column;
        align-items: stretch;
    }

    .lgbx-ml__knapper .lgbx-ml__lenke {
        justify-content: center;
    }

    .lgbx-ml__seksjon {
        padding: 52px 0;
    }

    .lgbx-ml__hode {
        margin-bottom: 28px;
    }

    .lgbx-ml__kort {
        flex-direction: column;
    }

    .lgbx-ml a.lgbx-ml__kort-bilde {
        position: static;
        flex: none;
        min-height: 0;
    }

    .lgbx-ml a.lgbx-ml__kort-bilde img {
        position: static;
        height: auto;
        aspect-ratio: 16 / 10;
    }

    .lgbx-ml__kort-knapper {
        flex-direction: column;
        gap: 14px;
    }

    .lgbx-ml a.lgbx-ml__knapp--bred,
    .lgbx-ml__midt a.lgbx-ml__knapp,
    .lgbx-ml__seksjon--mork a.lgbx-ml__knapp {
        width: 100%;
    }

    .lgbx-ml__fordeler {
        grid-template-columns: minmax(0, 1fr);
        gap: 14px;
    }

    .lgbx-ml__fordel {
        display: grid;
        grid-template-columns: 48px minmax(0, 1fr);
        column-gap: 16px;
        padding: 18px;
    }

    .lgbx-ml__fordel .lgbx-ml__ikon {
        grid-row: span 2;
        margin: 0;
    }

    .lgbx-ml__kontakt {
        padding: 28px 0 0;
        border-top: 1px solid rgba(255, 255, 255, 0.18);
        border-left: 0;
    }
}

@media (prefers-reduced-motion: reduce) {
    .lgbx-ml * {
        transition: none !important;
    }
}
