/* Site fjellform: colours from the customer's own shop www.fjellform.no (skin/class/c2/408080/colors.css): the green
   header (gradient #116F3F -> #1F9458) with the black mountain logo, green buttons, black text and links, the
   green footer with white text, and (from 1200 px) the old site's top area. Green #116F3F on white is 6.0:1 and white on it 6.0:1 (WCAG AA).
   Everything not set here is the standard theme (skin/class/theme.css). */

:root {
    --pr-primary:            #116f3f;
    --pr-primary-rgb:        17, 111, 63;
    --pr-primary-alt:        #116f3f;
    --pr-on-primary-alt:     #ffffff;
    --pr-link:               #116f3f;
    --pr-link-rgb:           17, 111, 63;
    --pr-link-hover:         #0b4f2c;
    --pr-primary-soft:       #e7f3ec;
    --pr-accent:             #116f3f;
    --pr-accent-rgb:         17, 111, 63;

    /* Green header with white text */
    --pr-header-bg:          #116f3f;
    --pr-header-border:      #0d5a33;
    --pr-header-text:        #ffffff;
    --pr-header-text-strong: #ffffff;
    --pr-header-muted:       #e3f1e9;
    --pr-header-deep:        #0d5a33;
    --pr-header-darker:      #0b4f2c;
    --pr-header-hover:       #1f9458;

    /* Green footer with white text */
    --pr-footer-bg:          #116f3f;
    --pr-footer-border:      #0d5a33;
    --pr-footer-text:        #ffffff;
    --pr-footer-link:        #ffffff;
    --pr-footer-heading:     #ffffff;

    --pr-surface-subtle:     #f4f6f4;
    --pr-text:               #000000;
    --pr-text-body:          #333333;
    --pr-text-heading:       #000000;
    --pr-dark:               #000000;
    --pr-edit-border:        #116f3f;
    --pr-edit-border-rgb:    17, 111, 63;

    /* Knapper: green as the site, darker green on hover */
    --btn-bg:                #116f3f;
    --btn-text:              #ffffff;
    --btn-hover-bg:          #0b4f2c;
    --btn-hover-text:        #ffffff;
}

/* The header's green gradient, as on fjellform.no */
.bg-fjord {
    background: linear-gradient(180deg, #116f3f 0%, #1f9458 100%) !important;
}

/* The black mountain logo, as on fjellform.no */
.site-logo img { height: 64px; width: auto; display: block; }
@media (max-width: 575px) { .site-logo img { height: 46px; } }

/* Footer text and links on the green */
footer.bg-fjord-dark { background: var(--pr-footer-bg) !important; color: var(--pr-footer-text); }
footer.bg-fjord-dark a { color: var(--pr-footer-link); }

/* ---------- The top area as on fjellform.no (from 1200 px; phones keep the standard menu) ----------
   Measured on www.fjellform.no at 1400 px: a green strip of 150 px (gradient #116f3f -> #1f9458) with the black logo
   (100 px) in the middle and Logg inn / the cart to the right; a dashed line; then a dark green menu bar (#116f3f, about
   70 px) with the menu items left-aligned in bold white, divided by #074a27 lines.
   PageHeader.razor has one row (logo, then #nordicNavbar > ul with the menu items, wishlist, cart and login): the
   collapse and its list get display: contents, so every li becomes an item of the header's container and is put in
   the right row with `order`. */
@media (min-width: 1200px) {
    /* Heights of the two rows; smaller once the page is scrolled (custom.js sets .is-scrolled on the header) */
    header.bg-fjord { --fj-top: 150px; --fj-logo: 100px; --fj-menu-pad: 1.35rem; }
    header.bg-fjord.is-scrolled { --fj-top: 64px; --fj-logo: 50px; --fj-menu-pad: 0.75rem; }
    header.bg-fjord {
        background: #116f3f !important;
        padding: 0 !important;
        border-bottom: 0 !important;
    }
    header.bg-fjord > .container-fluid {
        position: relative;
        flex-wrap: wrap !important;
        justify-content: flex-start !important;
        align-items: center !important;
        gap: 0 !important;
        padding: 0 1.5rem;
        background: linear-gradient(180deg, #116f3f 0%, #1f9458 100%) top left / 100% var(--fj-top) no-repeat, #116f3f;
    }
    /* Row 1: spacer (order 1) pushes the account items (order 2) to the right; the logo sits in the middle, out of the flow */
    header.bg-fjord > .container-fluid::after { content: ""; order: 1; flex: 1 1 auto; height: var(--fj-top); transition: height .25s ease; }
    /* Line break between the strip and the menu bar: the dashed line of the old site */
    header.bg-fjord > .container-fluid::before {
        content: ""; order: 3; flex: 0 0 100%; height: 0;
        border-top: 1px dashed rgba(255, 255, 255, 0.45);
    }

    header.bg-fjord .site-logo {
        position: absolute; left: 50%; top: 0; transform: translateX(-50%);
        height: var(--fj-top); transition: height .25s ease; display: flex; align-items: center;
    }
    header.bg-fjord .site-logo img { height: var(--fj-logo); transition: height .25s ease; }

    #nordicNavbar, #nordicNavbar > .navbar-nav { display: contents !important; }

    /* Row 2: the menu, left-aligned in bold white on the dark green, with dividers */
    #nordicNavbar > .navbar-nav > li { order: 4; }
    #nordicNavbar > .navbar-nav > li > .nordic-nav-item,
    #nordicNavbar > .navbar-nav > li > details > .nordic-nav-item {
        color: #ffffff !important;
        font-weight: 700 !important;
        font-size: 1.1rem !important;
        letter-spacing: -0.02em;
        padding: var(--fj-menu-pad) 1.5rem !important; transition: padding .25s ease;
        border-right: 1px solid #074a27;
    }
    #nordicNavbar > .navbar-nav > li > .nordic-nav-item:hover,
    #nordicNavbar > .navbar-nav > li > .nordic-nav-item.active,
    #nordicNavbar > .navbar-nav > li > details > .nordic-nav-item:hover {
        color: #ffffff !important;
        text-decoration: underline;
        text-underline-offset: 4px;
    }

    /* Row 1, right: wishlist, cart and Logg inn / the user's name, white on the green */
    #nordicNavbar > .navbar-nav > li:has(> a[href="/wishlist"]),
    #nordicNavbar > .navbar-nav > li:has(> a[title="Åpne Handlekurv"]),
    #nordicNavbar > .navbar-nav > li#header-user-dropdown-container,
    #nordicNavbar > .navbar-nav > li#header-anonymous-login-btn-container {
        order: 2;
        height: var(--fj-top); transition: height .25s ease;
        display: flex;
        align-items: center;
        margin: 0 !important;
    }
    #nordicNavbar > .navbar-nav > li:has(> a[href="/wishlist"]) > .nordic-nav-item,
    #nordicNavbar > .navbar-nav > li:has(> a[title="Åpne Handlekurv"]) > .nordic-nav-item,
    #nordicNavbar > .navbar-nav > li#header-user-dropdown-container > .nordic-nav-item {
        color: #ffffff !important;
        font-size: 1rem !important;
        font-weight: 600 !important;
        padding: 0.5rem 0.75rem !important;
        border-right: 0;
    }
    #nordicNavbar > .navbar-nav > li:has(> a[title="Åpne Handlekurv"]) svg,
    #nordicNavbar > .navbar-nav > li:has(> a[href="/wishlist"]) svg { width: 24px; height: 24px; }
    #header-user-dropdown-container #header-profile-name-text-node { color: #ffffff !important; }
    /* "Logg inn" as an underlined white link, as on the old site (not a button) */
    #nordicNavbar > .navbar-nav > li#header-anonymous-login-btn-container > a {
        background: transparent !important;
        border: 0 !important;
        box-shadow: none !important;
        color: #ffffff !important;
        text-decoration: underline !important;
        padding: 0.5rem 0.75rem !important;
    }

    /* The search field (when turned on) in the green strip, left of the account items */
    header.bg-fjord .header-search-container { order: 2; flex: 0 0 300px !important; margin: 0 2rem !important; }
}

/* ---------- Content, product cards and the category list (colours and finish only) ---------- */
/* Made-to-order is normal at Fjellform: "Lages på bestilling" in brown, not in the red of an error (5.2:1 on white) */
:root { --pr-stock-none: #8a4f00; }

/* Buttons in the old page content (btn-dark / btn-secondary, e.g. Katalog, Facebook) in the site's green */
.cms-rendered-content .btn-dark,
.cms-rendered-content .btn-secondary,
.cms-rendered-content .btn-primary {
    background-color: var(--btn-bg) !important;
    border-color: var(--btn-bg) !important;
    color: var(--btn-text) !important;
    border-radius: 4px;
    padding: 0.45rem 1.1rem;
}
.cms-rendered-content .btn-dark:hover,
.cms-rendered-content .btn-secondary:hover,
.cms-rendered-content .btn-primary:hover {
    background-color: var(--btn-hover-bg) !important;
    border-color: var(--btn-hover-bg) !important;
}
/* Pictures in the content: rounded, a light shadow, never wider than the column */
.cms-rendered-content img {
    max-width: 100%;
    height: auto;
    border-radius: 6px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.12);
}
/* The headings in the content in the dark green */
.cms-rendered-content h1, .cms-rendered-content h2, .cms-rendered-content h3 { color: #0b4f2c; }
/* The old contact form's iframe (now this shop's own form): full width, no float */
.cms-rendered-content iframe[src*="kontaktoss_frm"] { float: none !important; display: block; min-height: 520px; border: 0; }

/* Art nr on the product cards in the page's own font, small and grey (it was a typewriter font) */
.font-art-nr { font-family: inherit !important; font-size: 0.8rem; color: var(--pr-text-subtle) !important; letter-spacing: 0.02em; }

/* Category list: green on hover, the current group with a green bar */
.nordic-menu-list .menu-item-row:hover { background: #e7f3ec; }
.nordic-menu-list .menu-item-row:hover .menu-item-link { color: #0b4f2c !important; }
.nordic-menu-list .menu-item-link.active { color: #116f3f !important; font-weight: 700; }
.nordic-menu-list .menu-item-row:has(.menu-item-link.active) { background: #e7f3ec; box-shadow: inset 4px 0 0 #116f3f; }
