/* ============================================================
   RATI DESIGN TOKENS
   Base palette derived from brand green + lime.
   Every section/panel must reference these tokens - no ad-hoc hex.
   ============================================================ */
:root {
    /* Brand base */
    --deep: #18342a;          /* primary dark green: hero, bands, footer CTA context */
    --deep-2: #0f231c;        /* darker shade: hover/gradient depth */
    --lime: #d9f25f;          /* brand accent: primary CTA, highlights */
    --lime-strong: #b8d63e;   /* lime hover/pressed */
    --soft: #e7efdf;          /* light green surface tint */
    --paper: #f7f7f2;         /* page background */
    --surface: #ffffff;       /* panels, cards */

    /* Text contrast levels (on light surfaces) */
    --ink: #15231d;           /* headings, primary text */
    --text-body: #3c4a43;     /* body copy */
    --text-muted: #5b685f;    /* secondary/meta text */
    --text-faint: #65716a;    /* dates, least important */
    --on-deep: #ffffff;       /* text on deep green */
    --on-deep-soft: #ced9d4;  /* secondary text on deep green */

    /* Lines and shadows */
    --line: #dde4dc;          /* hairline borders on light */
    --line-strong: #c8d2c5;   /* scrollbar, stronger dividers */
    --shadow-sm: 0 1px 2px #06140d0a, 0 6px 18px #06140d0f;
    --shadow-md: 0 1px 2px #06140d0a, 0 12px 28px #06140d1c;

    /* Status accents (event types, badges) */
    --green: #55701a;         /* positive / new registrations */
    --green-bg: #e7efdf;      /* green tint surface */
    --green-line: #c9d9a9;

    --red: #a8422f;           /* bankruptcy / dissolution */
    --red-bg: #f6e3e0;
    --red-line: #e8c4bd;

    --amber: #96690f;         /* changes: name, address, form, industry */
    --amber-bg: #f5ecd4;
    --amber-line: #e6d5a8;

    --blue: #2d5f8f;          /* informational / other register changes */
    --blue-bg: #e3edf7;
    --blue-line: #c3d8ea;

    --grey: #66736d;          /* neutral status (deleted etc.) */
    --grey-bg: #eceee9;
    --grey-line: #d5dad2;

    /* Legacy aliases (used by original stylesheet) */
    --muted: var(--text-muted);
    --gold: #c9901f;

    /* Semantic aliases (use these in components) */
    --accent: var(--lime);
    --link: var(--green);
    --focus-ring: 0 0 0 3px #d9f25f66;
    --radius-sm: .6rem;
    --radius: 1rem;
    --radius-lg: 1.4rem;
    --radius-pill: 2rem;
}
* { box-sizing: border-box; }
body { margin: 0; color: var(--ink); background: var(--paper); font-family: Inter, ui-sans-serif, system-ui, sans-serif; line-height: 1.5; }
a { color: inherit; }
h1, h2, h3, p { margin-top: 0; }
h1, h2 { letter-spacing: -.05em; line-height: 1.05; }
h1 { font-size: clamp(2.5rem, 5vw, 4.8rem); }
h2 { font-size: 2rem; }
.eyebrow + h1, .eyebrow + h2 { margin-top: .4rem; }
h1 + .muted, h1 + .lede, h1 + .lead, h1 + p,
h2 + .muted, h2 + .lede, h2 + p,
.section-heading + p, .section-heading + .muted, .section-heading + .section-lede { margin-top: .65rem; }
.browse-page > h1, .form-page h1, .information-page h1, .not-found h1 { margin-bottom: 0; }
.container { width: min(1220px, calc(100% - 48px)); margin: 0 auto; }
.site-header { background: #fff; border-bottom: 1px solid var(--line); }.topbar { min-height: 70px; padding: 0 max(4vw, 24px); display: flex; align-items: center; gap: 1.5rem; border-bottom: 1px solid var(--line); }
.logo { font-size: 1.75rem; font-weight: 950; text-decoration: none; letter-spacing: -.09em; }.logo span { color: #77931c; }
nav { display: flex; gap: 1.5rem; margin-left: auto; font-size: .9rem; } nav a { text-decoration: none; }.mobile-menu { display: none; }.header-search { padding: .9rem 0; }.header-search .search-form { max-width: none; margin: 0; border: 1px solid var(--line); box-shadow: none; }.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.hero { padding: 5rem 0 4.5rem; background: var(--deep); color: #fff; }.hero h1 { margin: .6rem 0 1rem; }.hero .lede { color: #ced9d4; font-size: 1.2rem; }
.eyebrow { color: #c0dc4f; margin: 0; font-size: .7rem; font-weight: 900; letter-spacing: .15em; }.eyebrow.dark { color: #516a10; }
.search-form { display: grid; grid-template-columns: 1.4fr 1fr auto; max-width: 1000px; margin-top: 2rem; padding: .45rem; border-radius: 1rem; background: #fff; box-shadow: 0 18px 45px #06140d44; }
.search-page .search-form { margin: 1.5rem 0 3rem; box-shadow: none; border: 1px solid var(--line); }
.search-form label { padding: .55rem 1rem; border-right: 1px solid var(--line); }.search-form label span { display: block; color: var(--muted); font-size: .65rem; font-weight: 900; letter-spacing: .08em; }.search-form input { width: 100%; padding: .2rem 0; border: 0; outline: 0; font: inherit; }.button, button { display: inline-block; padding: .8rem 1.1rem; border: 0; border-radius: .7rem; color: var(--ink); background: var(--lime); font: inherit; font-weight: 800; text-decoration: none; cursor: pointer; }.secondary { border: 1px solid var(--line); background: #fff; }
.section { padding: 3.75rem 0; }.cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: .9rem; }.card, .panel, .review, .company-card { background: #fff; border: 1px solid var(--line); border-radius: 1rem; }.card { min-height: 155px; padding: 1.35rem; text-decoration: none; }.card b, .card span { display: block; }.card b { margin: .7rem 0 .25rem; font-size: 1.1rem; }.card span { color: var(--muted); }.trust { background: var(--soft); }
.footer { padding: 2.5rem 0; background: var(--deep); color: #fff; }.footer p { margin: .5rem 0 0; color: #ced9d4; }.footer-links a { color: #fff; }.information-page { min-height: calc(100vh - 250px); padding-top: 3rem; padding-bottom: 4rem; }.information-page .panel { max-width: 760px; font-size: 1.05rem; }
.search-page { min-height: calc(100vh - 190px); padding-bottom: 4rem; }.search-page h1 { margin-bottom: 1.5rem; }.result-layout { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(260px, .6fr); gap: 1.5rem; }.results { display: grid; gap: .8rem; align-content: start; }.company-card { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1.25rem; }.company-card h2 { margin-bottom: .35rem; font-size: 1.25rem; }.company-card h2 a { text-decoration: none; }.company-card p { margin-bottom: 0; }.map-placeholder { min-height: 280px; padding: 1.5rem; border-radius: 1rem; background: #dbe8d5; color: var(--muted); }
.filters { display: flex; flex-wrap: wrap; gap: .75rem; margin: 1.5rem 0 2rem; }.filters label { display: flex; align-items: center; gap: .4rem; color: var(--muted); font-size: .9rem; }.filters select { padding: .45rem; border: 1px solid var(--line); border-radius: .45rem; background: #fff; font: inherit; }
.muted { color: var(--muted); }.empty { padding: 1.5rem; border: 1px solid var(--line); border-radius: 1rem; background: #fff; }.rating { margin: .3rem 0; }.rating span { color: var(--gold); letter-spacing: .08em; }.rating.large { font-size: 1.1rem; }
.external-rating { margin: .75rem 0 0; color: var(--muted); font-size: .9rem; }.external-rating small { display: block; margin-top: .15rem; }
.map-links { display: flex; flex-wrap: wrap; gap: .6rem; margin-bottom: 0; }.map-links .button { padding: .55rem .75rem; font-size: .85rem; }.map-links .secondary { color: var(--deep); }
.company-map { height: 220px; border-radius: .65rem; overflow: hidden; background: #dbe8d5; }
.company-map-mobile { display: none; }
@media (max-width: 800px) { .company-map-mobile { display: block; } .company-layout aside .company-map-sidebar { display: none; } }
.company-facts { display: grid; grid-template-columns: repeat(2, 1fr); gap: .75rem; margin: 1rem 0 2.5rem; }.company-facts div { min-height: 92px; padding: 1rem; border: 1px solid var(--line); border-radius: .8rem; background: #fff; }.company-facts span, .company-facts b { display: block; }.company-facts span { color: var(--muted); font-size: .72rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }.company-facts b { margin-top: .4rem; }.empty-reviews { background: var(--soft); }.related-companies { display: grid; grid-template-columns: repeat(2, 1fr); gap: .75rem; }.related-companies > a, .related-companies > article { min-height: 110px; padding: 1rem; border: 1px solid var(--line); border-radius: .8rem; background: #fff; text-decoration: none; }.related-companies b, .related-companies span { display: block; }.related-companies span { margin-top: .4rem; color: var(--muted); font-size: .88rem; }.person-roles .role-card { display: flex; align-items: center; justify-content: space-between; gap: 1.25rem; min-height: 0; padding: .7rem 1rem; }.person-roles .role-main { min-width: 0; }.person-roles .role-main b { font-size: .98rem; }.person-roles .role-since { margin-top: .15rem; font-size: .76rem; color: var(--muted); }.person-roles .role-org { text-align: right; font-size: .92rem; font-weight: 700; flex-shrink: 0; max-width: 60%; }.person-roles .role-org a { display: inline-block; padding: .35rem .75rem; border-radius: 1rem; background: var(--lime); color: var(--deep); font-size: .88rem; font-weight: 800; text-decoration: none; transition: background .15s ease; }.person-roles .role-org a:hover { background: var(--lime-strong); }.person-roles .role-org small { display: block; margin-top: .25rem; color: var(--muted); font-size: .76rem; font-weight: 400; }.person-roles .role-card-past { background: var(--soft); }.group-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: .75rem; }.group-card { padding: 1rem; border: 1px solid var(--line); border-radius: .8rem; background: #fff; }.group-card > span { display: block; color: var(--muted); font-size: .72rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }.group-card > b { display: block; margin-top: .45rem; font-size: 1rem; }.group-card > b a { text-decoration: none; }.group-card > b a:hover { text-decoration: underline; }.group-card > small { display: block; margin-top: .2rem; color: var(--muted); font-size: .8rem; }.group-list { list-style: none; margin: .55rem 0 0; padding: 0; }.group-list li { display: flex; align-items: baseline; justify-content: space-between; gap: .75rem; padding: .45rem 0; border-top: 1px solid var(--line); font-size: .92rem; }.group-list li:first-child { border-top: 0; padding-top: 0; }.group-list li a { font-weight: 700; text-decoration: none; }.group-list li a:hover { text-decoration: underline; }.group-list li small { flex-shrink: 0; color: var(--muted); font-size: .8rem; }.group-card-wide { grid-column: 1 / -1; }.group-persons { list-style: none; margin: .45rem 0 0; padding: 0; }.group-persons li { display: flex; align-items: baseline; justify-content: space-between; gap: .5rem; padding: .25rem 0; font-size: .86rem; }.group-persons li a { font-weight: 700; text-decoration: none; }.group-persons li a:hover { text-decoration: underline; }.group-persons li small { color: var(--muted); font-size: .74rem; }
.result-map { position: sticky; top: 1rem; height: 420px; border-radius: 1rem; overflow: hidden; background: #dbe8d5; }

/* Sidekolonnen (kart + lead-boks) følger med ved scroll som én sticky-enhet;
   intern scroll hvis innholdet er høyere enn viewporten */
.result-layout aside { position: sticky; top: 1rem; align-self: start; max-height: calc(100vh - 2rem); overflow: auto; }
.result-layout aside .result-map { position: static; }
.company-hero { padding: 3.5rem 0 2.5rem; background: #fff; border-bottom: 1px solid var(--line); }.company-hero h1 { margin: .7rem 0 .5rem; }.company-layout { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(260px, .5fr); gap: 1.5rem; padding: 2rem 0 4rem; }.panel, .review { padding: 1.35rem; margin-bottom: 1rem; }.panel h2 { font-size: 1.25rem; }.claim { background: var(--soft); }.claim .button { width: 100%; text-align: center; }.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 1rem; margin: 2.5rem 0 1rem; }.review h3 { margin-bottom: .35rem; }.response { margin-top: 1rem; padding: 1rem; background: var(--paper); border-radius: .6rem; }.response p { margin: .4rem 0 0; }.badge { display: inline-block; padding: .2rem .5rem; border-radius: 1rem; background: var(--soft); color: var(--deep); font-weight: 800; }.not-found { min-height: calc(100vh - 190px); padding-top: 4rem; }
.form-page { max-width: 760px; min-height: calc(100vh - 190px); padding-top: 3rem; padding-bottom: 4rem; }.review-form { display: grid; gap: 1rem; }.review-form label { display: grid; gap: .35rem; font-weight: 700; }.review-form input, .review-form textarea, .review-form select { padding: .7rem; border: 1px solid var(--line); border-radius: .5rem; background: #fff; font: inherit; }.review-form .checkbox { display: block; font-weight: 400; }.review-form .checkbox input { margin-right: .4rem; }.errors { padding: .8rem 1rem; border-radius: .5rem; background: #f9e4e1; color: #742b25; }.errors p { margin: .25rem 0; }
.browse-page { min-height: calc(100vh - 190px); padding-top: 3rem; padding-bottom: 4rem; }.browse-list { display: grid; grid-template-columns: repeat(3, 1fr); gap: .7rem; margin-top: 2rem; }.browse-list a { padding: 1rem; border: 1px solid var(--line); border-radius: .7rem; background: #fff; text-decoration: none; }.browse-list b, .browse-list span { display: block; }.browse-list span, .breadcrumbs { color: var(--muted); font-size: .9rem; }.breadcrumbs a { color: var(--deep); }
.place-stats { margin: 1.75rem 0 2.25rem; }.place-stats h2 { margin-bottom: 1rem; font-size: 1.35rem; }.place-stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: .75rem; }.place-stats-grid article { min-height: 118px; padding: 1rem 1.05rem; border: 1px solid var(--line); border-radius: .9rem; background: #fff; }.place-stats-grid span, .place-stats-grid b, .place-stats-grid small { display: block; }.place-stats-grid span { color: var(--muted); font-size: .7rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }.place-stats-grid b { margin: .45rem 0 .2rem; font-size: 1.35rem; letter-spacing: -.04em; }.place-stats-grid small { color: var(--muted); font-size: .78rem; }
.stats-ranking-cols { display: grid; grid-template-columns: repeat(2, 1fr); gap: .75rem; }.stats-ranking-cols h3 { margin: 0 0 .6rem; font-size: 1.02rem; }.stats-ranking { list-style: none; margin: 0; padding: 0; counter-reset: rank; }.stats-ranking li { counter-increment: rank; display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; padding: .55rem .8rem; border: 1px solid var(--line); border-radius: .6rem; background: #fff; margin-bottom: .4rem; }.stats-ranking li::before { content: counter(rank); flex: 0 0 1.4rem; font-weight: 800; color: var(--muted); font-size: .85rem; }.stats-ranking li span { flex: 1; min-width: 0; }.stats-ranking li a { font-weight: 700; text-decoration: none; }.stats-ranking li a:hover { text-decoration: underline; }.stats-ranking li small { display: block; color: var(--muted); font-size: .78rem; }.stats-ranking li b { flex-shrink: 0; letter-spacing: -.02em; }
.hub-collapsible-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: .75rem; align-items: start; margin: 1.75rem 0 2.25rem; }.hub-collapsible { border: 1px solid var(--line); border-radius: .9rem; background: #fff; overflow: hidden; }.hub-collapsible > summary { display: flex; align-items: center; gap: .8rem; padding: 1rem 1.2rem; cursor: pointer; list-style: none; }.hub-collapsible > summary::-webkit-details-marker { display: none; }.hub-collapsible > summary:hover { background: #f6faf2; }.hub-collapsible .signal-chevron { margin-left: auto; color: var(--muted); transition: transform .15s ease; }.hub-collapsible[open] .signal-chevron { transform: rotate(180deg); }.hub-collapsible-body { padding: .25rem 1.2rem 1.2rem; }.hub-collapsible-body .place-stats-grid { grid-template-columns: 1fr 1fr; margin: 0 0 1rem; }.hub-collapsible-body .place-stats-grid article { min-height: 0; }
.hub-collapsible.hub-collapsible-offer { border-color: #cddda3; background: #fbfdf5; }.hub-collapsible.hub-collapsible-offer > summary:hover { background: #f2f8e4; }.hub-collapsible.hub-collapsible-offer .hub-collapsible-body .muted { color: #5a6b3a; }.hub-collapsible .leadfish-form-details > summary { display: none; }
.panel.leadfish-cta { background: #fbfdf5; border: 1px solid #cddda3; }
.admin-leads-actions { display: flex; gap: .5rem; flex-shrink: 0; align-items: flex-start; }.admin-leads-actions .button { padding: .55rem .85rem; font-size: .85rem; text-decoration: none; }.admin-leads-actions .button.secondary { background: #fff; }.admin-pagination { display: flex; align-items: center; gap: 1rem; margin-top: 1rem; }.admin-pagination .button { padding: .5rem .8rem; font-size: .85rem; text-decoration: none; }.admin-leads-actions a { text-decoration: none; }.table td.lead-desc { max-width: 320px; }.badge-ok { background: #e7f2d4; color: #3d4a12; }
.leadfish-form-details > summary.button { margin: 0 0 .75rem; cursor: pointer; list-style: none; }.leadfish-form-details > summary.button::-webkit-details-marker { display: none; }
.leadfish-form { display: grid; gap: .8rem; }.leadfish-form p { margin: 0; display: grid; gap: .8rem; }.leadfish-form label { display: grid; gap: .3rem; color: var(--text-body); font-size: .85rem; font-weight: 800; }.leadfish-form label br { display: none; }.leadfish-form input, .leadfish-form textarea, .leadfish-form select { width: 100%; box-sizing: border-box; padding: .7rem .85rem; border: 1.5px solid var(--line); border-radius: .7rem; background: #fff; font: inherit; }.leadfish-form input:focus, .leadfish-form textarea:focus, .leadfish-form select:focus { outline: 0; border-color: #8fae4c; box-shadow: 0 0 0 3px #d9f25f55; }.leadfish-form textarea { resize: vertical; min-height: 84px; }.leadfish-form label.leadfish-consent { display: flex; align-items: flex-start; gap: .55rem; font-weight: 400; font-size: .82rem; color: var(--muted); }.leadfish-form label.leadfish-consent input { width: 1.1rem; height: 1.1rem; margin-top: .15rem; padding: 0; border: 0; border-radius: 0; box-shadow: none; flex: none; accent-color: #77931c; cursor: pointer; }.leadfish-form .leadfish-submit { width: 100%; text-align: center; }.leadfish-form .leadfish-note { margin: 0; font-size: .8rem; }
.hub-collapsible-body .leadfish-form { padding-top: .25rem; }
@media (min-width: 801px) { .hub-collapsible-body .leadfish-form .leadfish-row { grid-template-columns: 1fr 1fr; } }
@media (max-width: 800px) { .site-header { display: contents; }.topbar { position: sticky; top: 0; z-index: 1000; background: #fff; }.desktop-nav { display: none; }.mobile-menu { position: relative; display: block; margin-left: auto; }.mobile-menu summary { padding: .55rem .8rem; border: 0; border-radius: .5rem; background: var(--lime); font-size: .9rem; font-weight: 800; cursor: pointer; list-style: none; }.mobile-menu summary::-webkit-details-marker { display: none; }.mobile-menu nav { position: absolute; top: calc(100% + .55rem); right: 0; display: grid; width: min(260px, calc(100vw - 32px)); margin: 0; padding: .5rem; border: 1px solid var(--line); border-radius: .7rem; background: #fff; box-shadow: 0 14px 35px #06140d22; }.mobile-menu nav a { padding: .75rem; border-radius: .45rem; }.mobile-menu nav a:hover { background: var(--soft); }.cards { grid-template-columns: 1fr 1fr; }.browse-list, .place-stats-grid { grid-template-columns: repeat(2, 1fr); }.stats-ranking-cols { grid-template-columns: 1fr; }.result-layout, .company-layout { grid-template-columns: 1fr; }.map-placeholder { min-height: 150px; }.result-map { position: static; height: 280px; }.result-layout aside { position: static; max-height: none; overflow: visible; }.search-form { grid-template-columns: 1fr; }.search-form label { border-right: 0; border-bottom: 1px solid var(--line); } }
@media (max-width: 520px) { .container { width: min(100% - 32px, 1220px); }.topbar { gap: 1rem; padding: .65rem 16px; }.logo { font-size: 1.5rem; }.hero { padding: 4rem 0; }.cards, .browse-list, .company-facts, .related-companies, .place-stats-grid { grid-template-columns: 1fr; }.company-card, .section-heading { align-items: flex-start; flex-direction: column; }.company-card .button { width: 100%; text-align: center; }.person-roles .role-card { flex-direction: column; align-items: flex-start; gap: .5rem; }.person-roles .role-org { text-align: left; max-width: none; } }

/* --- Header: dropdown + actions --- */
.topbar { justify-content: flex-start; }
.desktop-nav { align-items: center; gap: 1.1rem; display: flex; }
.desktop-nav > a, .nav-dropdown > a { text-decoration: none; font-weight: 700; font-size: .95rem; color: var(--ink); padding: .4rem .1rem; }
.desktop-nav > a:hover, .nav-dropdown > a:hover { color: #000; }
.nav-dropdown { position: relative; }
.nav-dropdown > a small { font-size: .6rem; color: var(--muted); }
.nav-menu { position: absolute; top: calc(100% + .6rem); left: -.75rem; display: none; grid-template-columns: repeat(2, minmax(220px, 1fr)); gap: .15rem; min-width: 460px; padding: .6rem; border: 1px solid var(--line); border-radius: .9rem; background: #fff; box-shadow: 0 22px 50px #06140d1f; z-index: 60; }
.nav-menu::before { content: ""; position: absolute; top: -0.7rem; left: 0; right: 0; height: 0.7rem; }
.nav-dropdown:hover .nav-menu, .nav-dropdown:focus-within .nav-menu { display: grid; }
.nav-menu a { display: grid; gap: .1rem; padding: .7rem .8rem; border-radius: .6rem; text-decoration: none; }
.nav-menu a:hover { background: var(--soft); }
.nav-menu a b { font-size: .93rem; }
.nav-menu a span { color: var(--muted); font-size: .8rem; }
.nav-sep { grid-column: 1 / -1; height: 1px; margin: .35rem 0; background: var(--line); }
.top-actions { display: flex; align-items: center; gap: .9rem; margin-left: auto; }
.login-link { text-decoration: none; font-weight: 700; font-size: .95rem; }
.pro-cta { padding: .6rem 1rem; font-size: .92rem; }
.mobile-group { display: block; margin: .5rem .55rem .15rem; color: var(--muted); font-size: .68rem; font-weight: 900; letter-spacing: .1em; text-transform: uppercase; }

/* --- Hero chips + section lede --- */
.hero-chips { display: flex; flex-wrap: wrap; gap: .6rem; margin-top: 1.6rem; }
.chip { display: inline-flex; align-items: center; gap: .45rem; padding: .45rem .85rem; border: 1px solid #ffffff2b; border-radius: 2rem; background: #ffffff14; color: #e4ece7; font-size: .85rem; font-weight: 600; }
.chip-dot { width: .5rem; height: .5rem; border-radius: 50%; }
.dot-lime { background: var(--lime); }.dot-green { background: #7fb069; }.dot-white { background: #fff; }
.section-lede { max-width: 640px; margin-top: .4rem; color: var(--muted); font-size: 1.05rem; }

/* --- Entrance cards --- */
.entrances { grid-template-columns: repeat(3, 1fr); }
.entrance { padding: 1.6rem; }
.entrance:hover { border-color: #b9c9a9; box-shadow: 0 16px 40px #06140d14; transition: box-shadow .15s ease; }
.entrance-icon { display: inline-flex; align-items: center; justify-content: center; width: 2.4rem; height: 2.4rem; border-radius: .7rem; background: var(--deep); color: var(--lime); font-size: 1.15rem; font-weight: 900; }
.entrance b { margin-top: 1rem; font-size: 1.25rem; }
.entrance em { display: block; margin-top: .8rem; color: #516a10; font-size: .9rem; font-style: normal; font-weight: 800; }

/* --- Fresh cards --- */
.fresh-grid { grid-template-columns: repeat(4, 1fr); }
.fresh-card { min-height: 130px; padding: 1.4rem; }
.fresh-card b { margin: .2rem 0; font-size: 2.4rem; letter-spacing: -.05em; }
.fresh-card .fresh-label { color: var(--muted); font-size: .95rem; }
.fresh-card .badge { margin-top: .8rem; }

/* --- Pro band --- */
.pro-band { background: var(--deep); color: #fff; }
.pro-band h2 { color: #fff; }
.pro-band .lede { color: #ced9d4; }
.pro-band-inner { display: flex; align-items: center; justify-content: space-between; gap: 2rem; }
.pro-band-actions { display: flex; flex-shrink: 0; gap: .8rem; }
.pro-band .button { background: var(--lime); color: var(--ink); }
.pro-band .button.ghost { border: 1px solid #ffffff3d; background: transparent; color: #fff; }

/* --- Footer columns --- */
.footer-grid { display: grid; grid-template-columns: 1.6fr repeat(4, 1fr); gap: 2rem; padding: 3rem 0 1.5rem; }
.footer-logo { font-size: 1.6rem; }
.footer h3 { margin: 0 0 .7rem; color: #a9bfb2; font-size: .75rem; font-weight: 900; letter-spacing: .12em; text-transform: uppercase; }
.footer-grid a { display: block; margin-bottom: .45rem; color: #e4ece7; font-size: .92rem; text-decoration: none; }
.footer-grid a:hover { color: #fff; text-decoration: underline; }
.footer-grid p { color: #ced9d4; max-width: 320px; }
.footer-base { padding: 1.25rem 0 2.5rem; border-top: 1px solid #ffffff1f; }
.footer-base p { margin: 0; color: #a9bfb2; font-size: .82rem; }

@media (max-width: 800px) {
  .top-actions { display: none; }
  .nav-menu { grid-template-columns: 1fr; min-width: 260px; }
  .entrances { grid-template-columns: 1fr; }
  .fresh-grid { grid-template-columns: 1fr 1fr; }
  .pro-band-inner { flex-direction: column; align-items: flex-start; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 1.25rem; }
}

/* --- Footer: black --- */
.footer { background: #000; }
.footer-base { border-top-color: #ffffff24; }

/* --- Airy sections + color coding (Byndle-inspired) --- */
.section.airy { padding: 4.5rem 0 5rem; }
.section.airy h2 { margin-bottom: .5rem; font-size: 2.2rem; }
.tools-band { background: #fff; }
.fresh-band { background: var(--soft); }

/* Entrance cards: borderless, soft shadow, accent icons */
.entrance { border: 1px solid transparent; border-radius: 1.4rem; box-shadow: 0 1px 2px #06140d0a, 0 6px 18px #06140d0f; }
.entrance-icon.icon-green { background: #e7efdf; color: #55701a; }
.entrance-icon.icon-blue { background: #e3edf7; color: #2d5f8f; }
.entrance-icon.icon-amber { background: #f7edd8; color: #9a6b10; }
.accent-green em { color: #55701a; } .accent-blue em { color: #2d5f8f; } .accent-amber em { color: #9a6b10; }

/* Fresh stat cards: full color tiles, no inner panels */
.fresh-card { display: flex; flex-direction: column; justify-content: center; gap: .35rem; min-height: 190px; padding: 2rem; border-radius: 1.4rem; text-decoration: none; }
.tint-green { background: #c7ddbe; color: #2c3d17; }
.tint-red { background: #f6e3e0; color: #6e2a20; }
.tint-amber { background: #f5ecd4; color: #6b4c0e; }
.tint-lime { background: #f2f8dc; color: #3d4a12; }
.fresh-count { font-size: 3rem; font-weight: 900; letter-spacing: -.06em; line-height: 1; }
.fresh-label { font-size: 1rem; font-weight: 600; }
.fresh-link { margin-top: 1rem; font-size: .88rem; font-weight: 800; color: var(--deep); }
.fresh-card:hover .fresh-link { text-decoration: underline; }

/* --- Home stats strip (nokkeltall) --- */
.stats-strip { background: var(--surface); border-bottom: 1px solid var(--line); }
.stats-strip-row { display: flex; align-items: stretch; flex-wrap: wrap; gap: .5rem 2.5rem; padding: 1.15rem 0 .5rem; }
.stat-item { display: grid; gap: .1rem; align-content: center; text-decoration: none; }
.stat-item b { font-size: 1.55rem; font-weight: 900; letter-spacing: -.04em; color: var(--ink); line-height: 1.1; }
.stat-item span { color: var(--text-muted); font-size: .85rem; }
.stat-item:hover b { color: var(--green); }
.stat-item-cta { align-content: center; margin-left: auto; color: #55701a; font-size: .92rem; font-weight: 800; }
.stat-item-cta:hover { text-decoration: underline; }
.stats-strip-meta { margin: .2rem 0 0; padding-bottom: 1.1rem; color: var(--text-faint); font-size: .78rem; }
.stats-strip-meta a { color: var(--text-muted); }
@media (max-width: 800px) {
  .stats-strip-row { gap: .9rem 1.5rem; }
  .stat-item-cta { margin-left: 0; }
}

/* Plain links instead of nested card panels */
.links-grid { grid-template-columns: repeat(4, 1fr); gap: 1.5rem; }
.plain-link { display: grid; gap: .45rem; padding: 1.25rem 1.25rem 1.35rem; border-radius: 1.1rem; text-decoration: none; transition: background .15s ease; }
.plain-link:not(.static):hover { background: #fff; }
.plain-link.static { background: #fff; border: 1px solid var(--line); border-radius: 1.2rem; }
.plain-link b { font-size: 1.05rem; }
.plain-link span { color: var(--muted); font-size: .92rem; }

/* Pro band points */
.pro-points { margin: 1.4rem 0 0; padding: 0; list-style: none; }
.pro-points li { position: relative; margin: .5rem 0; padding-left: 1.35rem; color: #ced9d4; font-size: .95rem; }
.pro-points li::before { content: ''; position: absolute; left: 0; top: .55em; width: .45rem; height: .45rem; border-radius: 50%; background: var(--lime); }

@media (max-width: 800px) {
  .links-grid { grid-template-columns: 1fr 1fr; gap: 1rem; }
  .section.airy { padding: 3.25rem 0 3.5rem; }
}
@media (max-width: 520px) {
  .links-grid { grid-template-columns: 1fr; }
}

/* --- Advanced search panel (Byndle-style rounded card) --- */
.browse-page .filters { display: grid; gap: 1rem; padding: 1.5rem 1.5rem 1.75rem; border: 1px solid var(--line); border-radius: 1.4rem; background: #fff; box-shadow: 0 1px 2px #06140d0a, 0 6px 18px #06140d0f; }
.browse-page .filters input[type="text"], .browse-page .filters input[type="number"] { min-width: 200px; padding: .7rem .9rem; border: 1.5px solid var(--line); border-radius: .7rem; background: #fff; font: inherit; }
.browse-page .filters input:focus { outline: 0; border-color: #8fae4c; box-shadow: 0 0 0 3px #d9f25f55; }
.browse-page .filters label { display: grid; gap: .3rem; color: var(--muted); font-size: .82rem; font-weight: 700; }
.browse-page .filters .filter-row { display: flex; flex-wrap: wrap; gap: .9rem; }
.browse-page .filters details { padding: 0; border: 0; background: transparent; }
.browse-page .filters summary { margin-bottom: .9rem; color: var(--deep); font-weight: 800; cursor: pointer; }
.browse-page .filters button { justify-self: start; padding: .75rem 1.4rem; border-radius: 2rem; }
.browse-page .filters a.button.secondary { border-radius: 2rem; }

/* --- Event preview slider (homepage) --- */
.event-preview { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(250px, 1fr); gap: 1rem; margin-top: 2rem; padding-bottom: .75rem; overflow-x: auto; scroll-snap-type: x mandatory; }
.event-preview::-webkit-scrollbar { height: 8px; }
.event-preview::-webkit-scrollbar-thumb { border-radius: 1rem; background: #c8d2c5; }
.event-tile { scroll-snap-align: start; display: grid; gap: .3rem; align-content: start; padding: 1.3rem; border: 1px solid transparent; border-radius: 1.2rem; background: #fff; box-shadow: 0 1px 2px #06140d0a, 0 6px 18px #06140d0f; text-decoration: none; }
.event-tile:hover { box-shadow: 0 1px 2px #06140d0a, 0 12px 28px #06140d1c; }
.event-type { display: inline-flex; align-items: center; gap: .45rem; color: var(--muted); font-size: .72rem; font-weight: 900; letter-spacing: .09em; text-transform: uppercase; }
.event-name { color: var(--ink); font-size: 1.02rem; }
.event-meta { color: var(--muted); font-size: .85rem; }
.event-date { margin-top: .5rem; color: var(--muted); font-size: .78rem; font-weight: 700; }
.dot-red { background: #c05445; } .dot-amber { background: #d09a2c; } .dot-blue { background: #3b7ab8; } .dot-grey { background: #8a958e; }
.preview-more { margin: 1.5rem 0 0; }
.preview-more a { color: #55701a; font-weight: 800; text-decoration: none; }
.preview-more a:hover { text-decoration: underline; }

/* --- Slider controls: arrows mandatory, scrollbar hidden --- */
.event-preview-header { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-top: 2rem; }
.event-preview-header h3 { margin: 0; font-size: 1.15rem; }
.slider-controls { display: flex; gap: .5rem; }
.slider-btn { display: inline-flex; align-items: center; justify-content: center; width: 2.6rem; height: 2.6rem; padding: 0; border: 1.5px solid var(--line-strong); border-radius: var(--radius-pill); background: var(--surface); color: var(--ink); font-size: 1.05rem; font-weight: 800; cursor: pointer; transition: background .15s ease, border-color .15s ease; }
.slider-btn:hover:not(:disabled) { border-color: var(--deep); background: var(--soft); }
.slider-btn:disabled { opacity: .35; cursor: default; }
.event-preview { scrollbar-width: none; -ms-overflow-style: none; padding-bottom: .25rem; mask-image: linear-gradient(to right, #000 0, #000 calc(100% - 2.5rem), transparent 100%); }
.event-preview::-webkit-scrollbar { display: none; }
.event-preview { margin-top: 1.25rem; }

/* --- Event tabs + feed (homepage freshness previews) --- */
.event-tabs { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: 2rem; margin-bottom: 1.75rem; }
.event-tab { padding: .65rem 1.15rem; border: 1.5px solid var(--line-strong); border-radius: var(--radius-pill); background: var(--surface); color: var(--text-body); font: inherit; font-size: .9rem; font-weight: 800; cursor: pointer; transition: background .12s ease, border-color .12s ease, color .12s ease; }
.event-tab:hover { border-color: var(--deep); background: var(--soft); }
.event-tab.active { border-color: var(--deep); background: var(--deep); color: #fff; }

/* --- Søkeresultat: lead-boks under kartet --- */
.search-page .hub-collapsible { margin-top: 2rem; }
.event-feed { display: none; margin-top: 1rem; padding: .35rem 1.25rem; border: 1px solid var(--line); border-radius: 1.4rem; background: #fff; box-shadow: 0 1px 2px #06140d0a, 0 6px 18px #06140d0f; }
.event-feed.active { display: block; }
.event-feed-row { display: grid; grid-template-columns: 9.5rem 1fr auto; gap: 1.1rem; align-items: center; padding: .95rem .25rem; border-bottom: 1px solid var(--line); text-decoration: none; }
.event-feed-row:last-of-type { border-bottom: 0; }
.event-feed-row:hover { background: var(--soft); }
.event-feed-when { color: var(--muted); font-size: .78rem; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; }
.event-feed-body { display: grid; gap: .15rem; }
.event-feed-name { color: var(--ink); font-size: 1rem; }
.event-feed-row:hover .event-feed-name { color: var(--deep); }
.event-feed-meta { color: var(--muted); font-size: .85rem; }
.event-feed-arrow { color: var(--muted); font-weight: 900; transition: transform .12s ease, color .12s ease; }
.event-feed-row:hover .event-feed-arrow { color: var(--deep); transform: translateX(4px); }
.event-feed-empty { margin: 1rem .25rem; color: var(--muted); }
@media (max-width: 620px) {
  .event-feed-row { grid-template-columns: 1fr auto; }
  .event-feed-when { grid-column: 1 / -1; }
}

/* --- Services band (Feit Fisk) --- */
.services-band { background: var(--paper); }
.services-band .section-lede a { color: var(--link); font-weight: 700; }
@media (max-width: 800px) { .footer-grid { grid-template-columns: 1fr 1fr; } }

/* --- Review reports + owner responses --- */
.report-details { margin-top: .6rem; }
.report-details summary { color: var(--muted); font-size: .82rem; font-weight: 700; cursor: pointer; }
.report-details summary:hover { color: var(--deep); }
.report-details form { display: grid; gap: .6rem; margin-top: .7rem; max-width: 420px; }
.report-details textarea, .report-details input, .report-details select { padding: .55rem .7rem; border: 1.5px solid var(--line); border-radius: .55rem; font: inherit; }

/* ============================================================
   V2 homepage: USP action cards, entrance CTAs, spesialtjenester,
   pro-pris, bedriftseier-kort, Rati AI.
   Samme tokens; lime reserveres primært til CTA.
   ============================================================ */

/* --- USP action cards (klikkbare, med tydelig CTA) --- */
.usp-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: .9rem; margin-top: 2rem; }
.usp { position: relative; display: flex; flex-direction: column; justify-content: flex-end; gap: .35rem; min-height: 190px; padding: 1.6rem; border-radius: 1.4rem; border: 1px solid transparent; text-decoration: none; transition: transform .1s ease, box-shadow .12s ease; }
.usp:hover { transform: translateY(-3px); box-shadow: 0 14px 34px #06140d1f; }
.usp::after { content: "→"; position: absolute; top: 1.3rem; right: 1.5rem; font-weight: 900; font-size: 1.15rem; opacity: .55; transition: transform .12s ease, opacity .12s ease; }
.usp:hover::after { transform: translateX(4px); opacity: 1; }
.usp.tint-green { background: #e2eedd; color: #2c3d17; border-color: #c9d9a9; }
.usp.tint-blue  { background: #e3edf7; color: #1e4266; border-color: #c3d8ea; }
.usp.tint-amber { background: #f5ecd4; color: #6b4c0e; border-color: #e6d5a8; }
.usp.tint-lime  { background: #f2f8dc; color: #3d4a12; border-color: #dbe8a8; }
.usp-num { font-size: clamp(1.9rem, 2.6vw, 2.8rem); font-weight: 900; letter-spacing: -.05em; line-height: 1; }
.usp-label { font-size: .95rem; font-weight: 600; line-height: 1.4; }
.usp-cta { margin-top: .55rem; font-size: .9rem; font-weight: 800; }

/* --- Inngangskort med ekte CTA-knapper --- */
.entrance .cta { display: inline-block; margin-top: 1.2rem; padding: .7rem 1rem; border-radius: .7rem; background: var(--lime); color: var(--ink); font-weight: 800; font-size: .95rem; text-decoration: none; transition: background .12s ease, transform .08s ease; }
.entrance .cta:hover { background: var(--lime-strong); }
.entrance .cta:active { transform: translateY(1px); }
.entrance em { display: none; } /* erstattes av ekte knapp */

/* --- Spesialtjenester: farget label i stedet for badge --- */
.service-grid { grid-template-columns: repeat(4, 1fr); }
.service { display: flex; flex-direction: column; padding: 1.5rem; }
.service-label { color: #516a10; font-size: .72rem; font-weight: 900; letter-spacing: .12em; text-transform: uppercase; }
.service b { margin-top: .5rem; font-size: 1.08rem; }
.service b.service-label { margin-top: 0; font-size: .72rem; }
.service span { flex: 1; margin: .35rem 0 1.1rem; color: var(--muted); font-size: .93rem; line-height: 1.5; }
.service .secondary { align-self: flex-start; text-decoration: none; font-size: .88rem; }
.service .secondary:hover { border-color: var(--lime-strong); background: var(--soft); }

/* --- Rati Pro: prisfremheving --- */
.pro-price { display: flex; flex-direction: column; align-items: flex-start; flex-shrink: 0; padding: 1.6rem 2rem; border-radius: 1.4rem; background: #ffffff12; border: 1px solid #ffffff2b; }
.pro-price-num { font-size: 3rem; font-weight: 900; letter-spacing: -.05em; color: var(--lime); line-height: 1; }
.pro-price-per { margin-top: .3rem; color: #ced9d4; font-size: .95rem; }
.pro-band .button { text-decoration: none; }

/* --- For bedriftseiere --- */
.owner-label { color: #516a10; font-size: .78rem; font-weight: 900; letter-spacing: .1em; text-transform: uppercase; }
.owner-cta { display: flex; flex-direction: column; gap: .5rem; background: var(--soft); border-color: #c9d9a9; }
.owner-cta .button { align-self: flex-start; margin-top: .6rem; background: var(--lime); text-decoration: none; font-size: .92rem; }
.owner-cta .button:hover { background: var(--lime-strong); }

/* --- Rati AI --- */
.ai-band { background: var(--deep-2); color: #fff; }
.ai-inner { display: flex; align-items: center; justify-content: space-between; gap: 2rem; }
.ai-inner h2 { color: #fff; margin-bottom: .5rem; }
.ai-inner .lede { max-width: 60ch; }
.ai-inner .ghost { flex-shrink: 0; border: 1px solid var(--lime); background: transparent; color: var(--lime); text-decoration: none; font-weight: 800; }
.ai-inner .ghost:hover { background: #ffffff14; }
.ai-band-actions { display: flex; flex-wrap: wrap; gap: .65rem; align-items: center; flex-shrink: 0; }
.company-ai .ai-example-links { display: flex; flex-wrap: wrap; gap: .55rem; margin-top: .85rem; }
.ai-landing { padding-block: 2rem 3.5rem; max-width: 48rem; }
.ai-landing .ai-hero { margin-bottom: 2rem; }
.ai-hero-actions { display: flex; flex-wrap: wrap; gap: .65rem; margin-top: 1.1rem; }
.ai-landing-block { margin: 2rem 0; }
.ai-landing-block h2 { margin-bottom: .75rem; }
.ai-feature-list, .ai-example-list, .ai-steps { margin: 0; padding-left: 1.2rem; display: grid; gap: .55rem; }
.ai-example-btn { background: none; border: 0; padding: 0; color: var(--deep); text-decoration: underline; text-align: left; cursor: pointer; font: inherit; }
.ai-example-btn:hover { color: var(--lime-strong); }
.ai-cta-band { padding: 1.25rem 1.35rem; background: var(--soft); border: 1.5px solid var(--line); }

@media (max-width: 960px) { .usp-grid { grid-template-columns: 1fr 1fr; } .service-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 800px) { .ai-inner { flex-direction: column; align-items: flex-start; } }
@media (max-width: 520px) { .usp-grid { grid-template-columns: 1fr; } .service-grid { grid-template-columns: 1fr; } }

/* --- Alfabetisk navigasjon i bransjer/steder --- */
.letter-nav { display: flex; flex-wrap: wrap; gap: .35rem; margin: 1.5rem 0 2rem; }
.letter-nav a { display: inline-flex; align-items: center; justify-content: center; min-width: 2.2rem; height: 2.2rem; padding: 0 .5rem; border: 1.5px solid var(--line); border-radius: .55rem; background: #fff; color: var(--ink); font-size: .85rem; font-weight: 800; text-decoration: none; transition: background .12s ease, border-color .12s ease; }
.letter-nav a:hover { border-color: var(--deep); background: var(--lime); }
.letter-group { margin-bottom: 2.25rem; }
.letter-heading { margin: 0 0 1rem; padding-bottom: .35rem; border-bottom: 2px solid var(--soft); font-size: 1.5rem; color: var(--deep); }

/* --- Ringelister: step-first flow --- */
.ringelister-steps { margin: 1.5rem 0 2rem; padding: 1.5rem 1.5rem 1.25rem; border: 1.5px solid var(--line-strong); border-left: 5px solid var(--lime); }
.ringelister-steps h2 { margin-bottom: .35rem; }
.ringelister-steps .step-form { display: grid; grid-template-columns: 2fr 2fr auto; gap: .9rem; align-items: end; margin-top: 1rem; }
.ringelister-steps .step-form label { display: grid; gap: .3rem; color: var(--muted); font-size: .82rem; font-weight: 700; }
.ringelister-steps .step-form select { padding: .7rem .9rem; border: 1.5px solid var(--line); border-radius: .7rem; background: #fff; font: inherit; }
.ringelister-steps .step-form select:focus { outline: 0; border-color: #8fae4c; box-shadow: 0 0 0 3px #d9f25f55; }
.ringelister-steps .step-hint { margin: .8rem 0 0; font-size: .82rem; }
@media (max-width: 800px) { .ringelister-steps .step-form { grid-template-columns: 1fr; } }

/* ============================================================
   Auth pages + Pro differentiation + kontrollpanel
   ============================================================ */

/* --- Auth: sentrert kort --- */
.auth-page { min-height: calc(100vh - 250px); display: grid; place-items: center; padding: 4rem 1.5rem; background: var(--paper); }
.auth-card { width: min(460px, 100%); padding: 2.25rem 2rem; border: 1px solid var(--line); border-top: 6px solid var(--lime); border-radius: 1.4rem; background: #fff; box-shadow: var(--shadow-md); }
.auth-card h1 { margin: .35rem 0 .5rem; }
.auth-form { display: grid; gap: 1rem; margin: 1.25rem 0 1rem; }
.auth-form label { display: grid; gap: .35rem; color: var(--text-body); font-size: .85rem; font-weight: 800; }
.auth-form input { padding: .75rem .9rem; border: 1.5px solid var(--line); border-radius: .7rem; background: #fff; font: inherit; }
.auth-form input:focus { outline: 0; border-color: #8fae4c; box-shadow: 0 0 0 3px #d9f25f55; }
.auth-form button { margin-top: .35rem; padding: .9rem 1.1rem; border-radius: .7rem; font-size: 1rem; }
.auth-alt { margin: 0; color: var(--muted); font-size: .92rem; }
.auth-alt a { color: var(--deep); font-weight: 800; }
.auth-privacy { margin: -.35rem 0 0; font-size: .78rem; }

/* --- Pro-status på database-/liste-sider --- */
.pro-status-band { display: flex; align-items: center; gap: 1rem; margin-bottom: 1.5rem; padding: .8rem 1.2rem; border: 1px solid #dbe8a8; border-left: 6px solid var(--lime); border-radius: 1rem; background: #f2f8dc; }
.pro-status-band span { color: var(--text-body); font-size: .92rem; }
.pro-status-link { margin-left: auto; color: var(--deep); font-weight: 800; font-size: .9rem; text-decoration: none; }
.pro-badge { display: inline-block; padding: .3rem .65rem; border-radius: .5rem; background: var(--deep); color: var(--lime); font-size: .7rem; font-weight: 900; letter-spacing: .12em; }

/* --- Laaste Pro-funksjoner (free-brukere) --- */
.pro-lock { display: flex; align-items: center; justify-content: space-between; gap: 1.25rem; margin: 1.5rem 0; padding: 1.25rem 1.4rem; border: 1.5px dashed var(--line-strong); border-radius: 1.2rem; background: var(--soft); }
.pro-lock.wide { border-style: solid; border-color: #dbe8a8; }
.pro-lock b { display: block; margin-bottom: .2rem; }
.pro-lock span { color: var(--muted); font-size: .92rem; }
.pro-lock .button { flex-shrink: 0; }

/* --- Kontrollpanel --- */
.panel-hero { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; margin-bottom: 1.75rem; padding: 2rem; border-radius: 1.4rem; background: #fff; border: 1px solid var(--line); border-left: 6px solid var(--line-strong); }
.panel-hero.is-pro { background: var(--deep); border-color: var(--deep-2); border-left-color: var(--lime); }
.panel-hero.is-pro h1 { color: #fff; }
.panel-hero.is-pro .eyebrow { color: var(--lime); }
.panel-hero.is-pro p { color: #ced9d4; }
.panel-hero-actions { display: flex; flex-shrink: 0; flex-wrap: wrap; gap: .7rem; }
.panel-hero .button, .panel-hero .ghost { text-decoration: none; }
.panel-hero .ghost { border: 1px solid #ffffff3d; background: transparent; color: #fff; }
.panel-hero:not(.is-pro) .ghost { border-color: var(--line); background: #fff; color: var(--ink); }
.panel-hero:not(.is-pro) .button { background: var(--lime); }

.panel-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: .9rem; margin-bottom: 2rem; }
.stat-card { display: grid; gap: .35rem; min-height: 110px; padding: 1.2rem 1.3rem; border: 1px solid var(--line); border-radius: 1.2rem; background: #fff; justify-content: start; align-content: center; }
.stat-card span { color: var(--muted); font-size: .7rem; font-weight: 900; letter-spacing: .1em; }
.stat-card b { font-size: 1.7rem; letter-spacing: -.04em; }

.panel-columns { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; align-items: start; }
.panel-section .company-card { margin-bottom: .7rem; }
.panel-section .company-card form { margin: 0; }
.new-list summary { cursor: pointer; color: var(--deep); font-weight: 800; }
.pro-upsell { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; margin-top: 2rem; padding: 1.75rem; border: 1px solid #dbe8a8; border-left: 6px solid var(--lime); border-radius: 1.4rem; background: var(--soft); }
.pro-upsell h2 { margin-bottom: .3rem; }
.pro-upsell .button { flex-shrink: 0; background: var(--lime); }

@media (max-width: 800px) {
  .panel-hero { flex-direction: column; align-items: flex-start; }
  .panel-stats { grid-template-columns: 1fr 1fr; }
  .panel-columns { grid-template-columns: 1fr; }
  .pro-lock, .pro-upsell { flex-direction: column; align-items: flex-start; }
}

/* ============================================================
   Rati Pro dashboard-shell (sidebar-struktur fra prototype)
   ============================================================ */
.dash { background: var(--paper); padding: 2.25rem 0 4rem; min-height: calc(100vh - 250px); }
.dash-grid { display: grid; grid-template-columns: 240px 1fr; gap: 2rem; align-items: start; }
.dash-sidebar { position: sticky; top: 1rem; display: grid; gap: 1.5rem; }
.side-group { display: grid; gap: .35rem; }
.side-label { color: var(--muted); font-size: .68rem; font-weight: 900; letter-spacing: .12em; text-transform: uppercase; padding: 0 .55rem .35rem; }
.side-nav { display: grid; gap: .15rem; }
.side-nav a { padding: .6rem .8rem; border-radius: .6rem; color: var(--text-body); font-size: .92rem; font-weight: 700; text-decoration: none; }
.side-nav a:hover { background: var(--soft); }
.side-nav a.active { background: var(--deep); color: #fff; }
.planbox { margin-top: .5rem; padding: 1.1rem 1.1rem 1.25rem; border: 1px solid var(--line); border-radius: 1rem; background: var(--deep); color: #fff; }
.planbox.locked { background: #fff; color: var(--ink); border-color: var(--line); }
.planbox.locked .side-label { color: var(--muted); }
.planbox p { margin: .45rem 0 .8rem; color: #ced9d4; font-size: .82rem; line-height: 1.45; }
.planbox.locked p { color: var(--muted); }
.planprice { font-size: 1.5rem; font-weight: 900; letter-spacing: -.04em; }
.planprice small { font-size: .85rem; font-weight: 700; letter-spacing: 0; }
.planbox .button { width: 100%; text-align: center; }

.dash-main { display: grid; gap: 1.25rem; }
.pagehead { margin-bottom: .5rem; }
.pagehead-row { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.pagehead h1 { margin: .35rem 0 .4rem; }
.pagehead .lead { margin: .15rem 0 0; }
.avatar { display: inline-flex; align-items: center; justify-content: center; width: 2.6rem; height: 2.6rem; border-radius: 50%; background: var(--deep); color: var(--lime); font-size: .85rem; font-weight: 900; flex-shrink: 0; }

/* Kort, tabeller og statlinjer (fra dashboard-prototypene) */
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: .9rem; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: .9rem; }
.card { padding: 1.35rem; border: 1px solid var(--line); border-radius: 1rem; background: #fff; box-shadow: 0 1px 2px #06140d0a, 0 6px 18px #06140d0f; }
.card h2 { font-size: 1.1rem; margin: 0 0 .2rem; }
.card h3 { font-size: 1.05rem; margin: 0 0 .6rem; }
.split-head { display: flex; align-items: start; justify-content: space-between; gap: 1rem; margin-bottom: 1rem; }
.split-head p { margin: 0; color: var(--muted); font-size: .88rem; }
.badge.green { background: var(--green-bg); color: var(--green); }
.badge.blue { background: var(--blue-bg); color: var(--blue); }
.badge.warn { background: var(--amber-bg); color: var(--amber); }
.kpi-num { font-size: 2.2rem; font-weight: 900; letter-spacing: -.05em; line-height: 1.1; }
.kpi-meta { color: var(--muted); font-size: .82rem; }
.statline { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .55rem 0; border-bottom: 1px solid var(--line); }
.statline:last-child { border-bottom: 0; }
.statline span { color: var(--muted); font-size: .88rem; }
.statline b { font-size: .95rem; }
.actionbar { display: flex; flex-wrap: wrap; gap: .6rem; }
.actionbar .btn { display: inline-block; padding: .65rem 1rem; border: 1.5px solid var(--line-strong); border-radius: .7rem; background: #fff; color: var(--ink); font-weight: 800; font-size: .9rem; text-decoration: none; }
.actionbar .btn:hover { border-color: var(--deep); background: var(--soft); }
.actionbar .btn.lime { background: var(--lime); border-color: var(--lime-strong); }
.actionbar .btn.dark { background: var(--deep); border-color: var(--deep); color: #fff; }
.btn { text-decoration: none; }
.table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.table th { text-align: left; padding: .5rem .5rem; color: var(--muted); font-size: .72rem; font-weight: 900; letter-spacing: .08em; text-transform: uppercase; border-bottom: 2px solid var(--line); }
.table td { padding: .65rem .5rem; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table tr:last-child td { border-bottom: 0; }
.table .row-title a { color: var(--ink); font-weight: 800; text-decoration: none; }
.table .row-title a:hover { color: var(--deep); text-decoration: underline; }
.table small { color: var(--muted); font-size: .78rem; }
.table .ta-r { text-align: right; }
.table .actions a { color: var(--deep); font-weight: 700; text-decoration: none; }
.table .actions a:hover { text-decoration: underline; }
.linklike { border: 0; background: none; padding: 0; color: #a8422f; font: inherit; font-size: .9rem; font-weight: 700; cursor: pointer; }
.linklike:hover { text-decoration: underline; }
.empty-state { display: grid; gap: .3rem; padding: 1.5rem; border: 1.5px dashed var(--line-strong); border-radius: 1rem; background: var(--paper); }
.empty-state b { font-size: 1rem; }
.empty-state span { color: var(--muted); font-size: .9rem; }
.note { padding: .9rem 1rem; border: 1px solid var(--line); border-left: 4px solid var(--lime); border-radius: .7rem; background: var(--paper); color: var(--text-body); font-size: .9rem; line-height: 1.5; }
.inline-form { max-width: 460px; }

@media (max-width: 960px) {
  .dash-grid { grid-template-columns: 1fr; }
  .dash-sidebar { position: static; }
  .grid-4 { grid-template-columns: 1fr 1fr; }
  .grid-2 { grid-template-columns: 1fr; }
}

/* --- Admin-dashbord --- */
.admin-sidebar .side-nav a.active { background: var(--lime); color: #000; }
.admin-sidebar .statusbox { padding: 1rem 1.1rem; border: 1px solid var(--line); border-left: 4px solid var(--green); border-radius: 1rem; background: #fff; }
.admin-sidebar .statusbox b { display: block; margin-bottom: .3rem; font-size: .9rem; }
.admin-sidebar .statusbox small { color: var(--muted); font-size: .78rem; line-height: 1.5; }
.kpi-label { color: var(--muted); font-size: .7rem; font-weight: 900; letter-spacing: .1em; text-transform: uppercase; }
.kpi { margin: .3rem 0 .2rem; font-size: 2.2rem; font-weight: 900; letter-spacing: -.05em; line-height: 1.1; }
.card .meta { color: var(--muted); font-size: .82rem; }

/* --- Admin side-statistikk --- */
.stats-row { display: grid; grid-template-columns: repeat(5, 1fr); gap: .8rem; margin: .75rem 0 1.25rem; }
.statbox { display: grid; gap: .2rem; padding: 1rem 1.1rem; border: 1px solid var(--line); border-radius: 1rem; background: var(--paper); }
.statbox b { font-size: 1.6rem; font-weight: 900; letter-spacing: -.04em; }
.statbox span { color: var(--muted); font-size: .78rem; }
@media (max-width: 960px) { .stats-row { grid-template-columns: 1fr 1fr; } }

/* --- Faktura-toggle i admin --- */
.billing-toggle { margin: 0; }
.billing-checkbox { display: inline-flex; align-items: center; gap: .5rem; cursor: pointer; }
.billing-checkbox input { width: 1.05rem; height: 1.05rem; accent-color: var(--deep); }
.billing-checkbox span { font-weight: 800; font-size: .85rem; display: grid; }
.billing-checkbox small { color: var(--muted); font-weight: 600; }

/* --- Prospektering: hurtigvalg med piler --- */
.quickstart { margin: 1.75rem 0 2.25rem; padding: 1.5rem 1.5rem 1.6rem; border: 1px solid var(--line); border-left: 6px solid var(--lime); border-radius: 1.4rem; background: #fff; }
.quickstart-head h2 { margin: .2rem 0 .3rem; font-size: 1.5rem; }
.quickstart-head .muted { margin: 0 0 1.1rem; font-size: .95rem; }
.quickstart-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: .8rem; }
.quickstart-card { display: flex; align-items: center; justify-content: space-between; gap: .8rem; padding: 1rem 1.1rem; border: 1.5px solid var(--line); border-radius: 1rem; background: var(--paper); text-decoration: none; transition: border-color .12s ease, background .12s ease, transform .1s ease, box-shadow .12s ease; }
.quickstart-card .qs-body { display: grid; gap: .2rem; }
.quickstart-card b { font-size: 1rem; color: var(--ink); }
.quickstart-card span { color: var(--muted); font-size: .82rem; line-height: 1.35; }
.quickstart-card .qs-arrow { flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center; width: 2.1rem; height: 2.1rem; border-radius: 50%; background: var(--lime); color: var(--ink); font-weight: 900; font-size: 1.05rem; transition: transform .12s ease, background .12s ease; }
.quickstart-card:hover { border-color: var(--deep); background: var(--soft); transform: translateY(-2px); box-shadow: 0 10px 26px #06140d14; }
.quickstart-card:hover .qs-arrow { background: var(--deep); color: var(--lime); transform: translateX(3px); }
@media (max-width: 1100px) { .quickstart-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 800px) { .quickstart-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .quickstart-grid { grid-template-columns: 1fr; } }

/* --- Ringelister: dropdown-brekkde + sorter-hyde --- */
/* Bransje + omrade: maks 40 % av raden, ingen overstikkende selects */
.ringelister-steps .step-form { grid-template-columns: minmax(0, 40%) minmax(0, 40%) auto; }
.ringelister-steps .step-form label { max-width: 100%; min-width: 0; }
.ringelister-steps .step-form select { width: 100%; min-width: 0; max-width: 100%; text-overflow: ellipsis; overflow: hidden; }

/* Sorter (og andre selects i filterpanelet): samme hoyde som input-feltene */
.browse-page .filters select {
  padding: .7rem .9rem;
  border: 1.5px solid var(--line);
  border-radius: .7rem;
  font: inherit;
  min-height: 48px;
  height: 48px;
  box-sizing: border-box;
  background: #fff;
  color: var(--ink);
}
.browse-page .filters select:focus { outline: 0; border-color: #8fae4c; box-shadow: 0 0 0 3px #d9f25f55; }
@media (max-width: 800px) {
  .ringelister-steps .step-form { grid-template-columns: 1fr; }
  .ringelister-steps .step-form label { max-width: 100%; }
  .browse-page .filters select { height: auto; min-height: 44px; }
}

/* --- Pro-sok: Sok/Nullstill i filterraden — samme hoyde som inputs --- */
.browse-page .filters .filter-row button,
.browse-page .filters .filter-row a.button,
.browse-page .filters > button,
.browse-page .filters > a.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 48px;
  padding: 0 1.25rem;
  border-radius: .7rem;
  font-size: .92rem;
  font-weight: 800;
  text-decoration: none;
  align-self: end;
}
.browse-page .filters .filter-row a.button,
.browse-page .filters > a.button {
  border: 1.5px solid var(--line);
  background: #fff;
  color: var(--ink);
}
.browse-page .filters .filter-row a.button:hover,
.browse-page .filters > a.button:hover {
  border-color: var(--deep);
  background: var(--soft);
}

/* --- Fast hoyde i px pa alle filterfelt (unngar nettleseravvik) --- */
.browse-page .filters input[type="text"],
.browse-page .filters input[type="number"],
.browse-page .filters input[type="email"],
.browse-page .filters select,
.browse-page .filters .filter-row button,
.browse-page .filters .filter-row a.button,
.browse-page .filters > button,
.browse-page .filters > a.button {
  height: 48px;
  min-height: 48px;
  max-height: 48px;
  box-sizing: border-box;
  line-height: 1;
}
.browse-page .filters textarea { min-height: 48px; }
@media (max-width: 800px) {
  .browse-page .filters input[type="text"],
  .browse-page .filters input[type="number"],
  .browse-page .filters input[type="email"],
  .browse-page .filters select,
  .browse-page .filters .filter-row button,
  .browse-page .filters .filter-row a.button,
  .browse-page .filters > button,
  .browse-page .filters > a.button {
    height: 44px;
    min-height: 44px;
    max-height: 44px;
  }
}

/* --- Finansanalyse-boks pa bedriftsprofilen --- */
.health-box { padding: 1.35rem; margin-bottom: 1rem; border-radius: 1rem; background: #fff; border: 1px solid var(--line); border-left: 6px solid var(--line-strong); }
.health-box.tone-red { border-left-color: #a8422f; background: #fdf6f5; }
.health-box.tone-amber { border-left-color: #9a6b10; background: #fdfaf1; }
.health-box.tone-green { border-left-color: #55701a; background: #f6faf2; }
.health-head { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; }
.health-head b { font-size: 1.15rem; letter-spacing: -.02em; }
.health-box.tone-red .health-head b { color: #742b25; }
.health-box.tone-amber .health-head b { color: #6b4c0e; }
.health-box.tone-green .health-head b { color: #3d4a12; }
.health-head small { color: var(--muted); font-weight: 700; white-space: nowrap; }
.health-summary { margin: .4rem 0 .8rem; color: var(--text-body); font-size: .95rem; line-height: 1.5; }
.health-points { margin: 0 0 .8rem; padding: 0; list-style: none; }
.health-points li { position: relative; padding: .4rem 0 .4rem 1.25rem; border-top: 1px solid var(--line); color: var(--text-body); font-size: .92rem; line-height: 1.5; }
.health-points li::before { content: ''; position: absolute; left: .2rem; top: .95em; width: .45rem; height: .45rem; border-radius: 50%; background: var(--muted); }
.health-box.tone-red .health-points li::before { background: #a8422f; }
.health-box.tone-amber .health-points li::before { background: #9a6b10; }
.health-box.tone-green .health-points li::before { background: #55701a; }
.health-disclaimer { margin: 0; color: var(--text-faint); font-size: .75rem; }

/* ============================================================
   Rati økonomiske signaler (expanderbar boks, financial-signals-v2.0)
   ============================================================ */
/* Økonomiske signaler — åpent panel i profildesignet (tones med venstre-aksent). */
.signal-panel { position: relative; }
.signal-panel.tone-red { border-left: 4px solid var(--red); }
.signal-panel.tone-amber { border-left: 4px solid var(--amber); }
.signal-panel.tone-green { border-left: 4px solid var(--green); }
.signal-panel .signal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; }
.signal-panel .signal-head h3 { margin: .15rem 0 0; font-size: 1.1rem; letter-spacing: -.01em; }
.signal-panel.tone-red .signal-head h3 { color: var(--red); }
.signal-panel.tone-amber .signal-head h3 { color: var(--amber); }
.signal-panel.tone-green .signal-head h3 { color: var(--green); }
.mini-badge { flex-shrink: 0; display: inline-block; padding: .25rem .55rem; border-radius: .5rem; background: var(--soft); color: var(--deep); font-size: .68rem; font-weight: 800; letter-spacing: .04em; }
.signal-summary-label { color: var(--muted); font-size: .62rem; font-weight: 900; letter-spacing: .12em; text-transform: uppercase; }
.signal-summary-heading { font-size: 1rem; font-weight: 900; letter-spacing: -.02em; }
.signal-summary-year { margin-left: auto; color: var(--muted); font-size: .8rem; font-weight: 700; }
.signal-chevron { color: var(--muted); font-size: .9rem; transition: transform .15s ease; }
.signal-text { margin: .65rem 0 0; color: var(--text-body); font-size: .88rem; line-height: 1.55; }
.signal-list { margin: .9rem 0 0; padding: 0; list-style: none; }
.signal-list li { display: flex; gap: .65rem; align-items: flex-start; padding: .5rem 0; border-top: 1px solid var(--line); font-size: .88rem; line-height: 1.5; color: var(--text-body); }
.signal-list li::before { flex-shrink: 0; width: 1.15rem; height: 1.15rem; margin-top: .1rem; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: .72rem; font-weight: 900; }
.signal-list li.signal-\+::before { content: '+'; background: #e7f2d4; color: #3d4a12; }
.signal-list li.signal--::before { content: '−'; background: var(--red-bg); color: var(--red); }
.signal-list li.signal-0::before { content: '•'; background: var(--paper); color: var(--muted); }
.signal-footer { border-top: 1px solid var(--line); margin-top: .9rem; padding-top: .7rem; }
.signal-footer p { margin: 0 0 .4rem; color: var(--text-faint); font-size: .7rem; line-height: 1.5; }
.signal-links a { color: var(--deep); font-weight: 700; font-size: .75rem; text-decoration: none; }
.signal-links a:hover { text-decoration: underline; }

/* --- For bedriftseiere: nummerering + animert pil --- */
.owner-card { position: relative; display: flex; flex-direction: column; align-items: flex-start; gap: .35rem; transition: border-color .12s ease, background .12s ease; }
.owner-num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 1.7rem; height: 1.7rem; margin-bottom: .2rem;
  border-radius: .45rem; background: var(--deep); color: var(--lime);
  font-size: .82rem; font-weight: 900;
}
.owner-card .owner-arrow {
  position: absolute; top: 1.1rem; right: 1.1rem;
  display: inline-flex; align-items: center; justify-content: center;
  width: 2.1rem; height: 2.1rem; border-radius: 50%;
  background: var(--soft); color: var(--deep);
  font-weight: 900; font-size: 1.05rem;
  transition: transform .14s ease, background .14s ease, color .14s ease;
}
.owner-card:hover { border-color: #c9d9a9; background: #fff; }
.owner-card:hover .owner-arrow { background: var(--lime); transform: translateX(4px); }
.owner-cta { background: var(--soft); border-color: #c9d9a9; }

/* --- Owner-kort v2: egne farger 1-4, piler midt mellom kortene --- */
.owner-grid .owner-card:nth-of-type(1) { background: #f2f8dc; }
.owner-grid .owner-card:nth-of-type(2) { background: #e7efdf; }
.owner-grid .owner-card:nth-of-type(3) { background: #c7ddbe; }
.owner-grid .owner-card.owner-cta:nth-of-type(4) { background: #fff; border-color: var(--line-strong); }
.owner-card .owner-num { background: #ffffffd9; color: var(--deep); border: 1px solid #00000014; }
.owner-card .owner-arrow {
  position: absolute; top: 50%; right: -1.5rem;
  transform: translateY(-50%);
  z-index: 2;
  background: var(--lime); color: var(--deep);
  box-shadow: 0 2px 8px #06140d1f;
  animation: ownerArrowDesktop 1.6s ease-in-out infinite;
}
@keyframes ownerArrowDesktop {
  0%, 100% { transform: translateY(-50%) translateX(0); }
  50% { transform: translateY(-50%) translateX(4px); }
}
.owner-grid .owner-card.owner-cta .button { background: var(--deep); color: #fff; }
.owner-grid .owner-card.owner-cta .button:hover { background: var(--deep-2); }
@media (max-width: 800px) {
  .owner-card .owner-arrow {
    top: auto; bottom: -1.45rem; right: 50%; left: auto;
    transform: translateX(50%) rotate(90deg);
    animation: ownerArrowMobile 1.6s ease-in-out infinite;
  }
  @keyframes ownerArrowMobile {
    0%, 100% { transform: translateX(50%) rotate(90deg) translateX(0); }
    50% { transform: translateX(50%) rotate(90deg) translateX(4px); }
  }
}

/* --- Info-sider: strukturerte seksjoner --- */
.information-page .panel h2 { margin-bottom: .5rem; }
.information-page .panel p, .information-page .panel ul { line-height: 1.6; color: var(--text-body); }
.information-page .panel ul { margin: .4rem 0 1rem; padding-left: 1.2rem; }
.information-page .panel ul li { margin: .3rem 0; }
.information-page .panel a { color: var(--deep); font-weight: 700; }
.information-page .panel:last-child { margin-bottom: 3rem; }

/* --- Info-side: steg-flyt med nummer og linje (fresh layout) --- */
.info-intro { border-left: 6px solid var(--lime); margin-bottom: 2rem; }
.info-steps { max-width: 860px; position: relative; margin-bottom: 3rem; }
.info-steps::before {
  content: '';
  position: absolute;
  left: 27px;
  top: 28px;
  bottom: 28px;
  width: 2px;
  background: var(--line-strong);
}
.info-step {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 1.4rem;
  padding: 1.4rem 0;
  position: relative;
}
.info-step-num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 56px; height: 56px; border-radius: 50%;
  background: var(--deep); color: var(--lime);
  font-size: 1.3rem; font-weight: 900;
  position: relative; z-index: 1;
  box-shadow: 0 0 0 6px var(--paper);
}
.info-step:nth-child(odd) .info-step-num { background: var(--deep); }
.info-step:nth-child(4n+2) .info-step-num { background: #2c5c3f; }
.info-step:nth-child(4n+3) .info-step-num { background: #55701a; }
.info-step:last-child .info-step-num { background: var(--lime); color: var(--ink); box-shadow: 0 0 0 6px var(--paper), 0 6px 18px #06140d22; }
.info-step-body h2 { margin: .35rem 0 .6rem; font-size: 1.35rem; letter-spacing: -.02em; }
.info-step-body p, .info-step-body ul { line-height: 1.65; color: var(--text-body); }
.info-step-body ul { margin: .4rem 0 .6rem; padding-left: 1.15rem; }
.info-step-body ul li { margin: .3rem 0; }
.info-step-body a { color: var(--deep); font-weight: 700; }
.info-step-body a:hover { text-decoration: underline; }
@media (max-width: 620px) {
  .info-step { grid-template-columns: 44px 1fr; gap: 1rem; }
  .info-steps::before { left: 21px; }
  .info-step-num { width: 44px; height: 44px; font-size: 1.05rem; }
}

/* --- Forside: SLIK FUNGERER RATI (explainer) --- */
.home-steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.4rem; margin-top: 2.25rem; position: relative; }
.home-steps::before { content: ''; position: absolute; top: 28px; left: calc(12.5% + 28px); right: calc(12.5% + 28px); height: 2px; background: var(--line-strong); }
.home-step { position: relative; text-align: center; padding: 0 .35rem; }
.home-step-num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 56px; height: 56px; border-radius: 50%;
  background: var(--deep); color: var(--lime);
  font-size: 1.3rem; font-weight: 900;
  position: relative; z-index: 1;
  box-shadow: 0 0 0 6px #fff;
}
.home-step:nth-child(2) .home-step-num { background: #2c5c3f; }
.home-step:nth-child(3) .home-step-num { background: #55701a; }
.home-step:nth-child(4) .home-step-num { background: var(--lime); color: var(--ink); box-shadow: 0 0 0 6px #fff, 0 8px 20px #06140d22; }
.home-step h3 { margin: .9rem 0 .35rem; font-size: 1.05rem; }
.home-step p { margin: 0; color: var(--muted); font-size: .9rem; line-height: 1.5; }
@media (max-width: 900px) {
  .home-steps { grid-template-columns: 1fr 1fr; }
  .home-steps::before { display: none; }
}
@media (max-width: 520px) {
  .home-steps { grid-template-columns: 1fr; }
}

/* --- Min bedrift (verifisert eier) --- */
.my-business { border-left: 6px solid var(--lime); margin-bottom: 1.5rem; }
.my-business .split-head { margin-bottom: .75rem; }
.my-business h2 { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; }
.business-status { display: flex; align-items: center; gap: .5rem; flex-shrink: 0; color: var(--muted); font-size: .88rem; }
.business-status b { display: inline-flex; align-items: center; justify-content: center; width: 2rem; height: 2rem; border-radius: 50%; font-size: 1rem; }
.business-status .business-ok { background: var(--green-bg); color: var(--green); }
.business-status .business-alert { background: var(--amber-bg); color: var(--amber); }
.business-fields { display: grid; grid-template-columns: repeat(3, 1fr); gap: .8rem; margin-bottom: .8rem; }
.business-fields label { display: grid; gap: .3rem; color: var(--muted); font-size: .8rem; font-weight: 700; }
.business-fields input, .business-form textarea { padding: .7rem .85rem; border: 1.5px solid var(--line); border-radius: .7rem; font: inherit; background: #fff; }
.business-fields input:focus, .business-form textarea:focus { outline: 0; border-color: #8fae4c; box-shadow: 0 0 0 3px #d9f25f55; }
.business-response-cta { margin: 1rem 0 0; }
@media (max-width: 800px) { .business-fields { grid-template-columns: 1fr; } }

/* --- Dashbord mobilmeny --- */
.dash-mobile-menu { display: none; margin-bottom: 1rem; }
.dash-mobile-menu summary { padding: .75rem 1rem; border: 1.5px solid var(--line); border-radius: .8rem; background: var(--deep); color: #fff; font-weight: 800; cursor: pointer; list-style: none; }
.dash-mobile-menu summary::-webkit-details-marker { display: none; }
.dash-mobile-menu nav { display: grid; gap: .15rem; padding: .5rem 0 0; }
@media (max-width: 800px) {
  .dash-mobile-menu { display: block; }
  .dash-grid { grid-template-columns: 1fr; }
  .dash-sidebar { display: none; }
}

/* --- Registrering: bedriftssøk --- */
.company-results { display: none; border: 1.5px solid var(--line); border-radius: .7rem; background: #fff; margin: -.4rem 0 .6rem; max-height: 260px; overflow: auto; }
.company-result { display: grid; gap: .1rem; width: 100%; text-align: left; padding: .6rem .8rem; border: 0; border-bottom: 1px solid var(--line); background: #fff; font: inherit; cursor: pointer; }
.company-result:last-child { border-bottom: 0; }
.company-result:hover { background: var(--soft); }
.company-result b { color: var(--ink); font-size: .92rem; }
.company-result span { color: var(--muted); font-size: .78rem; }

/* --- Tabeller på mobil: horisontal scroll i stedet for brutt layout --- */
@media (max-width: 800px) {
  .dash-main .table { display: block; overflow-x: auto; white-space: nowrap; }
  .dash-main .table td, .dash-main .table th { white-space: nowrap; }
}

/* ============================================================
   Cookie-samtykke (stedsikt-mønster)
   ============================================================ */
.cookie-settings-link {
  display: block; margin: 0 auto 1.5rem; padding: .3rem .8rem;
  border: 0; background: none; color: var(--text-muted);
  font-size: .78rem; font-weight: 700; text-decoration: underline; cursor: pointer;
}
.cookie-banner:not([hidden]) {
  position: fixed; left: 1rem; right: 1rem; bottom: 1rem; z-index: 3000;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem;
  max-width: calc(1220px - 2rem); margin: 0 auto;
  padding: 1.25rem 1.5rem;
  border: 1px solid var(--line); border-radius: 1.2rem;
  background: #fff; box-shadow: 0 22px 50px #06140d2e;
}
.cookie-banner .kicker { color: #516a10; margin: 0 0 .2rem; font-size: .68rem; font-weight: 900; letter-spacing: .14em; text-transform: uppercase; }
.cookie-banner h2 { margin: 0 0 .3rem; font-size: 1.15rem; letter-spacing: -.03em; }
.cookie-banner p { margin: 0; color: var(--text-body); font-size: .88rem; line-height: 1.5; }
.cookie-banner a { color: var(--deep); font-weight: 700; }
.cookie-actions { display: flex; flex-wrap: wrap; gap: .6rem; flex-shrink: 0; }
.cookie-actions .button { padding: .7rem 1.1rem; font-size: .9rem; }
.cookie-actions .button.secondary { border: 1.5px solid var(--line-strong); background: #fff; color: var(--ink); }
@media (max-width: 620px) {
  .cookie-banner { flex-direction: column; align-items: stretch; }
  .cookie-actions { flex-direction: column; }
  .cookie-actions .button { width: 100%; text-align: center; }
}

/* --- Mobilmeny: full bredde under toppbaren, tett, X for å lukke --- */
@media (max-width: 800px) {
  .mobile-menu { position: static; }
  .mobile-menu summary {
    display: flex; align-items: center; justify-content: center;
    width: 100%; box-sizing: border-box;
    padding: .7rem 1rem; border-radius: .6rem;
    background: var(--deep); color: #fff; font-weight: 800;
  }
  .mobile-menu .menu-close-label { display: none; }
  .mobile-menu.open .menu-open-label { display: none; }
  .mobile-menu.open .menu-close-label { display: inline; }
  /* Forankret til viewport (topbaren er sticky) — aldri utenfor skjermen */
  .mobile-menu nav {
    position: fixed;
    top: 70px;
    left: 12px;
    right: 12px;
    width: auto;
    max-width: none;
    padding: .3rem;
    box-shadow: 0 22px 50px #06140d33;
  }
  .mobile-menu nav a { padding: .55rem .7rem; }
  .mobile-menu nav .mobile-group { margin: .3rem .6rem .05rem; }
}

/* Mobil-header: desktop-nav skjules også på nettbrett */
@media (max-width: 960px) {
  .desktop-nav { display: none; }
  .top-actions { display: none; }
}

/* --- Mobilmeny v2: kompakt kolonner, hoved + under --- */
@media (max-width: 800px) {
  .mobile-menu nav {
    top: 64px;
    padding: .55rem;
    max-height: calc(100vh - 84px);
    overflow-y: auto;
  }
  .mobile-menu nav .menu-primary {
    background: var(--soft); color: var(--deep);
    font-weight: 800; border-radius: .45rem;
    margin-bottom: .35rem;
  }
  .mobile-menu nav .menu-columns {
    display: grid; grid-template-columns: 1fr 1fr;
    gap: 0 .8rem;
  }
  .mobile-menu nav .menu-col { display: grid; align-content: start; gap: 0; min-width: 0; }
  .mobile-menu nav .mobile-group {
    margin: .45rem .35rem .15rem;
    font-size: .58rem;
  }
  .mobile-menu nav a { padding: .4rem .35rem; font-size: .85rem; border-radius: .35rem; }
  .mobile-menu nav a:hover { background: var(--soft); }
}

/* --- Mobil søk: søkefelt i toppbaren, ekspanderer nedover ved trykk --- */
.mobile-search { display: none; }
@media (max-width: 800px) {
  .header-search { display: none; }
  .mobile-search {
    position: relative;
    display: block;
    flex: 1;
    min-width: 0;
  }
  .mobile-search summary {
    display: flex; align-items: center;
    width: 100%; box-sizing: border-box;
    padding: .6rem .8rem;
    border: 1px solid var(--line); border-radius: .6rem;
    background: var(--soft); color: var(--muted);
    font-size: .8rem; font-weight: 700;
    cursor: pointer; list-style: none;
  }
  .mobile-search summary::-webkit-details-marker { display: none; }
  .mobile-search summary .search-hint {
    flex: 1; min-width: 0;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
    text-align: left;
  }
  .mobile-search[open] summary { border-color: var(--deep); color: var(--deep); }
  .mobile-search .mobile-search-panel {
    position: fixed;
    top: 64px; left: 12px; right: 12px;
    padding: .3rem;
    border: 1px solid var(--line); border-radius: .7rem;
    background: #fff;
    box-shadow: 0 22px 50px #06140d33;
  }
  .mobile-search .search-form {
    margin: 0; max-width: none;
    border: 1px solid transparent; box-shadow: none;
  }
  .mobile-search .search-form label:last-of-type { border-bottom: 0; }
}

/* --- Populære kategorier (Hvorfor Rati) --- */
.category-links {
  display: flex; flex-wrap: wrap; align-items: center;
  gap: .45rem .55rem; margin-top: 1.5rem;
}
.category-links-label {
  color: var(--muted); font-size: .72rem; font-weight: 900;
  letter-spacing: .1em; text-transform: uppercase; margin-right: .2rem;
}
.category-links a {
  padding: .42rem .8rem; border: 1.5px solid var(--line);
  border-radius: 2rem; background: #fff;
  color: var(--ink); font-size: .85rem; font-weight: 700;
  text-decoration: none; transition: border-color .12s ease, background .12s ease, transform .1s ease;
}
.category-links a:hover { border-color: var(--deep); background: var(--lime); transform: translateY(-1px); }

/* --- Slider-knapper: på sidene av slideren, med tekst (ikke kun piler) --- */
.category-slider-wrap { display: flex; align-items: center; gap: .6rem; }
.category-slider-wrap .category-slider { flex: 1 1 auto; min-width: 0; }
.category-nav-btn {
  flex: 0 0 auto; white-space: nowrap;
  padding: .42rem .85rem; border: 1.5px solid var(--line-strong);
  border-radius: 2rem; background: #fff;
  color: var(--ink); font-size: .82rem; font-weight: 800;
  cursor: pointer; transition: border-color .12s ease, background .12s ease, opacity .12s ease;
}
.category-nav-btn:hover:not(:disabled) { border-color: var(--deep); background: var(--lime); }
.category-nav-btn:focus-visible { outline: 2px solid var(--deep); outline-offset: 2px; }
.category-nav-btn:disabled { opacity: .35; cursor: default; }

/* --- Kategorislider: 80 pills i horisontal scroll --- */
.category-slider {
  display: flex; flex-wrap: nowrap; gap: .5rem;
  overflow-x: auto; scroll-snap-type: x proximity;
  padding: .25rem .25rem .6rem;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
  mask-image: linear-gradient(to right, #000 0, #000 calc(100% - 2.5rem), transparent 100%);
}
.category-slider::-webkit-scrollbar { display: none; }
.category-slider a {
  flex: 0 0 auto; scroll-snap-align: start; white-space: nowrap;
  padding: .42rem .8rem; border: 1.5px solid var(--line);
  border-radius: 2rem; background: #fff;
  color: var(--ink); font-size: .85rem; font-weight: 700;
  text-decoration: none; transition: border-color .12s ease, background .12s ease;
}
.category-slider a:hover { border-color: var(--deep); background: var(--lime); }

@media (max-width: 520px) {
  .category-nav-btn { padding: .38rem .6rem; font-size: .78rem; }
}

/* --- Statisk kart-bilde på bedriftsprofil --- */
.company-static-map { display: block; width: 100%; border-radius: .65rem; background: #dbe8d5; }

/* Registrering — hensiktskort (radio + tekst på SAMME rad; overkjører .auth-form label/input) */
.auth-form .intent-cards { display: grid; gap: .5rem; border: 0; padding: 0; margin: 0 0 1.1rem; }
.auth-form .intent-cards legend { margin-bottom: .5rem; }
.auth-form label.intent-card { display: flex; flex-direction: row; align-items: center; gap: .7rem; padding: .7rem .85rem; border: 1.5px solid var(--line); border-radius: .7rem; background: #fff; cursor: pointer; color: var(--text-body); font-size: .95rem; font-weight: 700; transition: border-color .15s, background .15s; }
.auth-form label.intent-card:hover { border-color: #8fae4c; }
.auth-form label.intent-card input { width: 1.1rem; height: 1.1rem; padding: 0; margin: 0; border: 0; border-radius: 0; box-shadow: none; flex: none; accent-color: #77931c; cursor: pointer; }
.auth-form label.intent-card span { display: flex; flex-wrap: wrap; align-items: baseline; gap: .45rem; }
.auth-form label.intent-card small { color: var(--muted); font-size: .8rem; font-weight: 500; }
.auth-form label.intent-card:has(input:checked) { border-color: #77931c; background: var(--soft, #f4f8e8); box-shadow: inset 0 0 0 1px #77931c; }
.auth-optional { margin: .4rem 0 .6rem; }
.auth-optional summary { cursor: pointer; color: var(--muted); font-size: .9rem; }

/* Registrering — bredt todelt kort: valg til venstre, felter til høyre */
.auth-card--split { width: min(1020px, 100%); }
.auth-form--split { display: grid; grid-template-columns: minmax(0, .95fr) minmax(0, 1.05fr); gap: 1.6rem; align-items: start; }
.auth-form--split .intent-cards { margin: 0; align-content: start; }
.auth-form--split .register-fields { display: grid; gap: 1rem; }
@media (max-width: 780px) { .auth-form--split { grid-template-columns: 1fr; } }



/* ============================================================
   BEDRIFTSPROFIL (P0): seksjonsstruktur + lokal sticky meny
   Anchor-navigasjon (#oversikt, #okonomi, #eiere-roller,
   #hendelser, #om-bedriften). Alt innhold forblir server-renderet.
   ============================================================ */
.company-nav { position: sticky; top: 0; z-index: 950; background: #fff; border-bottom: 1px solid var(--line); }
.company-nav-wrap { position: relative; display: flex; align-items: center; gap: .25rem; }
.company-nav-inner { position: relative; display: flex; flex: 1; min-width: 0; gap: .5rem; overflow-x: auto; padding: .55rem 0; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.company-nav-inner::-webkit-scrollbar { display: none; }
.company-nav-inner a { flex: none; display: inline-block; padding: .8rem 1.1rem; border: 1px solid var(--line); border-radius: .7rem; background: #fff; color: var(--ink); font: inherit; font-size: .88rem; font-weight: 800; text-decoration: none; white-space: nowrap; }
.company-nav-inner a:hover { background: var(--soft); }
.company-nav-inner a.active { background: var(--soft); border-color: var(--green-line); color: var(--deep); }
.company-nav-arrow { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 2.1rem; height: 2.1rem; padding: 0; border: 1px solid var(--line); border-radius: 999px; background: #fff; color: var(--ink); font-size: 1.25rem; font-weight: 800; line-height: 1; cursor: pointer; box-shadow: 0 1px 4px #06140d14; z-index: 2; }
.company-nav-arrow:hover:not(:disabled) { background: var(--soft); }
.company-nav-arrow:disabled { opacity: .35; cursor: default; }
.company-nav-wrap::before, .company-nav-wrap::after { content: ""; position: absolute; top: 0; bottom: 0; width: 28px; pointer-events: none; opacity: 0; transition: opacity .15s ease; z-index: 1; }
.company-nav-wrap::before { left: 2.2rem; background: linear-gradient(90deg, #fff 30%, #ffffff00); }
.company-nav-wrap::after { right: 2.2rem; background: linear-gradient(270deg, #fff 30%, #ffffff00); }
.company-nav.nav-fade-left .company-nav-wrap::before { opacity: 1; }
.company-nav.nav-fade-right .company-nav-wrap::after { opacity: 1; }
.company-section { min-width: 0; }
.company-section + .company-section { margin-top: 2.75rem; padding-top: 2.25rem; border-top: 1px solid var(--line); }
.company-section, #regnskapstall, #oppdrag { scroll-margin-top: 5.5rem; }
@media (max-width: 800px) {
    .company-nav { top: 70px; }
    .company-nav-inner { padding: .45rem 0; gap: .4rem; }
    .company-nav-inner a { padding: .65rem .9rem; }
    .company-section, #regnskapstall, #oppdrag { scroll-margin-top: 8.25rem; }
}

/* ============================================================
   VERDI V1 — Estimert selskapsverdi (Bear/Base/Bull)
   Jf. prototype .valuation-panel + RATI_NACE_MULTIPLER_V1.md.
   ============================================================ */
.valuation-panel { display: grid; grid-template-columns: .8fr 1.2fr; gap: 2.5rem; align-items: center; margin-top: 1rem; }
.valuation-copy h3 { margin: .3rem 0 .5rem; font-size: 1.15rem; letter-spacing: -.01em; }
.valuation-copy p { font-size: .85rem; line-height: 1.55; color: var(--text-body); margin: 0 0 .5rem; }
.valuation-disclaimer { font-size: .72rem; color: var(--text-muted); border-top: 1px solid var(--line); padding-top: .6rem; margin-bottom: 0 !important; }
.valuation-labels, .valuation-values { display: grid; grid-template-columns: repeat(3, 1fr); text-align: center; }
.valuation-labels span { font-size: .62rem; text-transform: uppercase; letter-spacing: .12em; font-weight: 900; color: var(--text-muted); }
.valuation-track { position: relative; height: 10px; margin: .65rem 8%; background: linear-gradient(90deg, var(--soft), var(--green-bg), var(--soft)); border-radius: 99px; }
.valuation-track i, .valuation-track b, .valuation-track em { position: absolute; top: 50%; width: 11px; height: 11px; background: var(--deep); border: 3px solid #fff; border-radius: 50%; transform: translate(-50%, -50%); box-shadow: 0 0 0 1px var(--deep); }
.valuation-track i { left: 8%; }
.valuation-track b { left: 50%; background: var(--green); }
.valuation-track em { left: 92%; }
.valuation-values strong { font-size: 1.1rem; letter-spacing: -.02em; color: var(--ink); }
.valuation-values .valuation-base { font-size: 1.3rem; color: var(--green); }
.valuation-scale > small { display: block; text-align: center; font-size: .68rem; color: var(--text-muted); margin-top: .5rem; }
.valuation-signals { margin-top: .8rem; font-size: .72rem; }
.valuation-signals b { display: block; margin-top: .35rem; }
.valuation-signals b.valuation-signal-bear { color: var(--red); }
.valuation-signals b.valuation-signal-bull { color: var(--green); }
.valuation-signals ul { margin: .25rem 0 0; padding-left: 1rem; color: var(--text-muted); }
.valuation-signals li { margin: .15rem 0; }
.valuation-warnings { margin-top: .6rem; }
.valuation-warnings summary { cursor: pointer; font-size: .7rem; font-weight: 700; color: var(--text-muted); }
.valuation-warnings ul { margin: .45rem 0 0; padding-left: 1.1rem; font-size: .68rem; line-height: 1.5; color: var(--text-muted); }
@media (max-width: 820px) {
    .valuation-panel { grid-template-columns: 1fr; gap: 1.25rem; }
    .valuation-values strong { font-size: .95rem; }
    .valuation-values .valuation-base { font-size: 1.1rem; }
}

/* ============================================================
   PROTOTYPE-LAYOUT-SYNK: hero-grid, metrics-rad, hendelsestidslinje, FAQ
   ============================================================ */
.company-hero-grid { display: flex; align-items: flex-end; justify-content: space-between; gap: 2rem; }
.company-hero-actions { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; margin: 1.1rem 0 0; }
.company-hero-actions form { display: contents; }
.company-hero-actions > a { color: var(--text-muted); font-size: .85rem; }.company-hero-fact { flex-shrink: 0; padding-left: 1.6rem; border-left: 1px solid var(--line); display: flex; flex-direction: column; min-width: 180px; }
.company-hero-fact span, .company-hero-fact small { color: var(--text-muted); font-size: .72rem; }
.company-hero-fact b { font-size: 2rem; letter-spacing: -.03em; margin: .15rem 0; }
.company-metrics { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); margin: 0 0 1.5rem; }
.company-metrics div { padding: 1rem 1.2rem 1rem 0; }
.company-metrics div + div { border-left: 1px solid var(--line); padding-left: 1.2rem; }
.company-metrics span, .company-metrics small { display: block; color: var(--text-muted); font-size: .7rem; }
.company-metrics b { display: block; font-size: 1.5rem; letter-spacing: -.03em; margin: .2rem 0; }
.event-timeline { display: flex; flex-direction: column; }
.event-timeline-item { display: grid; grid-template-columns: 110px 1fr; gap: 1rem; padding: .9rem 0; border-top: 1px solid var(--line); font-size: .9rem; }
.event-timeline-item time { color: var(--text-muted); font-size: .78rem; font-weight: 800; letter-spacing: .04em; }
.event-timeline-item b { display: block; }
.event-timeline-item span { display: block; margin-top: .2rem; color: var(--text-muted); font-size: .78rem; }
.company-faq-section { padding-bottom: 3rem; }
.company-faq-section .hub-collapsible { margin-top: 1rem; }
@media (max-width: 800px) {
    .company-hero-grid { flex-direction: column; align-items: stretch; gap: 1rem; }
    .company-hero-fact { border-left: 0; border-top: 1px solid var(--line); padding: .8rem 0 0; flex-direction: row; align-items: baseline; gap: .6rem; min-width: 0; }
    .company-hero-fact b { margin: 0; }
    .company-metrics { grid-template-columns: 1fr 1fr; }
    .company-metrics div { padding: .75rem .75rem .75rem 0; }
    .company-metrics div + div { padding-left: .75rem; }
    .company-metrics div:nth-child(even) { border-left: 1px solid var(--line); padding-left: .75rem; }
    .company-metrics div:nth-child(n+3) { border-top: 1px solid var(--line); }
    .company-metrics b { font-size: 1.2rem; }
    .event-timeline-item { grid-template-columns: 84px 1fr; gap: .6rem; }
}

/* ============================================================
   Flerårig regnskap: graf + tabell + trendpiler (prototype-synk)
   ============================================================ */
.finance-history .section-heading { margin-bottom: .75rem; }
.data-source { color: var(--text-muted); font-size: .68rem; }
.chart-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.line-chart { width: 100%; min-width: 480px; height: auto; display: block; }
.line-chart .grid line { stroke: var(--line); stroke-width: 1; }
.line-chart .area { fill: rgba(85, 112, 26, .10); }
.line-chart .line { fill: none; stroke: var(--green); stroke-width: 2.5; }
.line-chart circle { fill: #fff; stroke: var(--green); stroke-width: 2.5; }
.line-chart .axis-labels text { font-size: 12px; fill: var(--text-muted); text-anchor: middle; }
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.finance-table { width: 100%; table-layout: fixed; border-collapse: collapse; margin-top: 1rem; font-size: .85rem; }
.finance-table th, .finance-table td { border-bottom: 1px solid var(--line); padding: .65rem .5rem; vertical-align: middle; }
.finance-table th { color: var(--text-muted); font-size: .72rem; font-weight: 800; letter-spacing: .04em; }
.finance-table th:first-child,
.finance-table td:first-child { width: 7.75rem; padding-right: 1rem; font-weight: 700; text-align: left; white-space: nowrap; }
.finance-table th:not(:first-child),
.finance-table td:not(:first-child) { text-align: center; }
.finance-table .finance-val { display: block; font-variant-numeric: tabular-nums; line-height: 1.25; }
.finance-table .trend { display: block; margin-top: .2rem; font-size: .72rem; font-weight: 800; }
.trend { font-size: .72rem; font-weight: 800; }
.trend.up { color: var(--green); }
.trend.down { color: var(--red); }
.finance-history > p.muted { font-size: .72rem; margin-bottom: 0; }

/* Benchmark-kort: stor tallverdi + kort kontekst (ren KPI-stil). */
.benchmark-grid { grid-template-columns: repeat(3, 1fr); }
.benchmark-grid .benchmark-card { min-height: 0; display: flex; flex-direction: column; }
.benchmark-grid .benchmark-card b { font-size: 1.75rem; margin: .35rem 0 .3rem; color: var(--deep); }
.benchmark-grid .benchmark-card small { font-size: .72rem; line-height: 1.4; }
@media (max-width: 800px) { .benchmark-grid { grid-template-columns: 1fr 1fr; } .benchmark-grid .benchmark-card b { font-size: 1.35rem; } }
@media (max-width: 520px) { .benchmark-grid { grid-template-columns: 1fr; } }

/* --- Rati AI floating widget (alle sider) --- */
.ai-widget {
  position: fixed; z-index: 90;
  right: max(1rem, env(safe-area-inset-right));
  bottom: max(1rem, env(safe-area-inset-bottom));
  display: flex; flex-direction: column; align-items: flex-end; gap: .65rem;
  pointer-events: none;
}
.ai-widget > * { pointer-events: auto; }
.ai-fab {
  display: inline-flex; align-items: center; gap: .55rem;
  padding: .7rem 1.05rem .7rem .75rem;
  border: 0; border-radius: 999px; cursor: pointer;
  background: linear-gradient(135deg, #1c3a2a 0%, #2f5a3c 100%);
  color: #fff; font: inherit; font-weight: 800; font-size: .92rem;
  box-shadow: 0 10px 28px rgba(28, 58, 42, .35), 0 0 0 3px rgba(184, 224, 74, .2);
  transition: transform .15s ease, box-shadow .15s ease;
}
.ai-fab:hover { transform: translateY(-2px); box-shadow: 0 14px 32px rgba(28, 58, 42, .4); }
.ai-fab-icon {
  width: 2.25rem; height: 2.25rem; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  background: #eef3ec; color: #1c3a2a; overflow: hidden;
  border: 1.5px solid rgba(28, 58, 42, .35);
}
.ai-fab-icon .rati-bot-face,
.ai-fab-icon .bob-face,
.ai-avatar .rati-bot-face,
.ai-avatar .bob-face { display: block; width: 100%; height: 100%; }
.ai-fab-open { opacity: .92; }
.ai-chat-float {
  width: min(24.5rem, calc(100vw - 1.5rem));
  max-height: min(34rem, calc(100vh - 6.5rem));
  margin: 0 !important;
  display: flex; flex-direction: column;
  box-shadow: 0 22px 55px rgba(28, 58, 42, .28) !important;
}
.ai-chat-float[hidden] { display: none !important; }
.ai-chat-float .ai-chat-log { flex: 1; height: auto; min-height: 12rem; max-height: 18rem; }
@media (max-width: 520px) {
  .ai-widget { right: .75rem; bottom: .75rem; }
  .ai-fab-label { display: none; }
  .ai-fab { padding: .75rem; border-radius: 50%; }
  .ai-chat-float {
    width: calc(100vw - 1.25rem);
    max-height: calc(100vh - 5.5rem);
    position: fixed; right: .6rem; bottom: 4.25rem; left: .6rem; width: auto;
  }
  .ai-chat-float .ai-chat-log { max-height: 45vh; }
}

/* --- Rati AI chat (premium) --- */
.ai-chat {
  max-width: 40rem; margin: -1.5rem auto 3rem;
  background: #fff; border: 1px solid #d5ddd3; border-radius: 18px;
  box-shadow: 0 18px 48px rgba(28, 58, 42, .12); overflow: hidden;
}
.ai-chat-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: .85rem 1.1rem; background: linear-gradient(135deg, #1c3a2a 0%, #2a5238 100%); color: #fff;
}
.ai-chat-brand { display: flex; align-items: center; gap: .75rem; }
.ai-chat-brand strong { display: block; font-size: 1rem; letter-spacing: .01em; }
.ai-chat-status { display: flex; align-items: center; gap: .35rem; font-size: .72rem; opacity: .85; font-weight: 500; }
.ai-dot { width: .45rem; height: .45rem; border-radius: 50%; background: #b8e04a; box-shadow: 0 0 0 3px rgba(184, 224, 74, .25); }
.ai-chat-close {
  flex-shrink: 0;
  width: 2rem; height: 2rem; padding: 0; margin: 0; border: 0; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  background: #ffffff18; color: #fff; font-size: 1.25rem; font-weight: 400;
  line-height: 1; cursor: pointer;
}
.ai-chat-close:hover { background: #ffffff28; }
.ai-avatar {
  flex-shrink: 0; width: 2.15rem; height: 2.15rem; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  background: #eef3ec; color: #1c3a2a; overflow: hidden;
  border: 1.5px solid rgba(28, 58, 42, .35);
}
.ai-avatar svg { display: block; }
.ai-avatar-lg { width: 2.5rem; height: 2.5rem; }
.ai-card-icon svg { color: var(--deep, #1c3a2a); }
.ai-msg-meta .ai-msg-time { display: none; }
.ai-chat-log {
  height: 26rem; overflow-y: auto; padding: 1.1rem 1rem 1.25rem;
  display: flex; flex-direction: column; gap: .9rem;
  background: linear-gradient(180deg, #f3f6f1 0%, #eef2eb 100%);
}
.ai-msg { display: flex; gap: .55rem; align-items: flex-end; max-width: 100%; }
.ai-user { justify-content: flex-end; }
.ai-bot { align-items: flex-start; }
.ai-msg-body { min-width: 0; flex: 1; max-width: calc(100% - 2.6rem); }
.ai-msg-meta {
  display: flex; gap: .5rem; align-items: baseline; margin: 0 0 .25rem .15rem;
  font-size: .7rem; color: #6a756c; font-weight: 600;
}
.ai-msg-time { font-weight: 500; opacity: .75; }
.ai-msg-inner {
  padding: .85rem 1rem; border-radius: 16px; font-size: .94rem; line-height: 1.5;
  word-break: break-word;
}
.ai-user .ai-msg-inner {
  max-width: 85%; background: var(--deep, #1c3a2a); color: #fff;
  border-bottom-right-radius: 5px; box-shadow: 0 4px 14px rgba(28, 58, 42, .18);
}
.ai-bot .ai-msg-inner {
  background: #fff; border: 1px solid #e4ebe1; border-bottom-left-radius: 5px;
  box-shadow: 0 6px 18px rgba(28, 58, 42, .06);
}
.ai-summary { margin: 0 0 .65rem; color: #1a2e22; }
.ai-summary:last-child { margin-bottom: 0; }
.ai-cards { display: flex; flex-direction: column; gap: .45rem; margin: .15rem 0 .55rem; }
.ai-card-row { display: flex; gap: .4rem; align-items: stretch; }
.ai-card {
  flex: 1; display: flex; align-items: center; gap: .65rem; padding: .55rem .7rem;
  border-radius: 12px; border: 1px solid #e2e9de; background: #f7faf5;
  text-decoration: none; color: inherit; transition: border-color .12s, background .12s, transform .12s;
  min-width: 0;
}
.ai-card:hover { border-color: #b7c9a0; background: #eef5e6; transform: translateY(-1px); }
.ai-card-call {
  flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center;
  padding: 0 .75rem; border-radius: 12px; border: 1px solid #d5e0c4; background: #eef5e0;
  color: var(--deep, #1c3a2a); font-size: .78rem; font-weight: 800; text-decoration: none;
}
.ai-card-call:hover { background: #e0eccc; }
.ai-card-icon {
  flex-shrink: 0; width: 2.1rem; height: 2.1rem; border-radius: 10px;
  display: inline-flex; align-items: center; justify-content: center;
  background: #e7f0d8; font-size: 1rem;
}
.ai-card-text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: .1rem; }
.ai-card-text strong { font-size: .9rem; color: var(--deep, #1c3a2a); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ai-card-text small { font-size: .72rem; color: #6a756c; }
.ai-card-go { color: #6f8a3a; font-weight: 800; font-size: 1.05rem; }
.ai-see-all {
  display: inline-flex; align-items: center; gap: .25rem; margin-top: .15rem;
  font-size: .82rem; font-weight: 800; color: var(--deep, #1c3a2a); text-decoration: none;
}
.ai-see-all:hover { text-decoration: underline; }
.ai-disclaimer {
  margin: .45rem 0 0; padding: 0;
  font-size: .68rem; line-height: 1.3; color: #8a9488; font-weight: 400;
}
.ai-typing { display: flex; gap: .28rem; padding: .15rem 0 .35rem; }
.ai-typing span {
  width: .42rem; height: .42rem; border-radius: 50%; background: #8aa06a;
  animation: ai-bounce 1.1s infinite ease-in-out;
}
.ai-typing span:nth-child(2) { animation-delay: .15s; }
.ai-typing span:nth-child(3) { animation-delay: .3s; }
@keyframes ai-bounce {
  0%, 80%, 100% { transform: translateY(0); opacity: .45; }
  40% { transform: translateY(-4px); opacity: 1; }
}
.ai-typing-label { margin: 0; font-size: .78rem; color: #6a756c; }
.ai-chips {
  display: flex; flex-wrap: wrap; gap: .4rem; padding: .55rem 1rem 0;
  background: #fff; border-top: 1px solid #eef1ec;
}
.ai-chip {
  border: 1px solid #d5dece; background: #f4f7f1; color: var(--deep, #1c3a2a);
  border-radius: 999px; padding: .35rem .7rem; font: inherit; font-size: .78rem; font-weight: 700;
  cursor: pointer; transition: background .12s, border-color .12s;
}
.ai-chip:hover { background: #e5efd6; border-color: #b7c9a0; }
.ai-chat-form {
  display: flex; gap: .5rem; padding: .75rem 1rem; border-top: 1px solid #e7ece6; background: #fff;
}
.ai-chat-form input {
  flex: 1; padding: .7rem .9rem; border: 1.5px solid #cfd8cf; border-radius: 12px;
  font: inherit; background: #fbfcfb;
}
.ai-chat-form input:focus { outline: none; border-color: #8fbc2a; background: #fff; box-shadow: 0 0 0 3px rgba(143, 188, 42, .18); }
.ai-send { border-radius: 12px; padding-inline: 1.1rem; font-weight: 800; }
.ai-busy .ai-send { opacity: .55; pointer-events: none; }
.ai-chat-note {
  margin: 0; padding: .45rem .9rem .65rem; font-size: .7rem; color: #7a857c;
  background: #fbfcfa; text-align: center;
}
@media (max-width: 520px) {
  .ai-chat { margin: -1rem .75rem 2rem; border-radius: 14px; }
  .ai-chat-log { height: 20rem; }
  .ai-msg-body { max-width: calc(100% - 2.4rem); }
}

/* --- Desktop: samme toppbar-søk som mobil vises ved scroll ned --- */
@media (min-width: 801px) {
  .site-header { display: contents; } /* toppbar + søke-stripen blir søsken — sticky topbar hefter til body-høyden */
  .topbar { position: sticky; top: 0; z-index: 1000; background: #fff; }
  .header-search { border-bottom: 1px solid var(--line); }
  .site-header.scrolled .header-search { display: none; }
  .site-header.scrolled .mobile-search {
    position: relative;
    display: block;
    flex: 0 0 320px;
    min-width: 0;
  }
  .site-header.scrolled .mobile-search summary {
    display: flex; align-items: center; justify-content: flex-start;
    width: 100%; box-sizing: border-box;
    padding: .55rem .75rem;
    border: 1px solid var(--line); border-radius: .6rem;
    background: var(--soft); color: var(--muted);
    font-size: .8rem; font-weight: 600;
    max-width: 460px;
    cursor: pointer; list-style: none;
  }
  .site-header.scrolled .mobile-search summary::-webkit-details-marker { display: none; }
  .site-header.scrolled .mobile-search summary .search-hint {
    flex: 1; min-width: 0;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
    text-align: left;
  }
  .site-header.scrolled .mobile-search[open] summary { border-color: var(--deep); color: var(--deep); }
  .site-header.scrolled .mobile-search .mobile-search-panel {
    position: fixed;
    top: 64px; left: max(4vw, 24px); right: max(4vw, 24px);
    padding: .3rem;
    border: 1px solid var(--line); border-radius: .7rem;
    background: #fff;
    box-shadow: 0 22px 50px #06140d33;
  }
  .site-header.scrolled .mobile-search .search-form {
    margin: 0; max-width: none;
    border: 1px solid transparent; box-shadow: none;
    grid-template-columns: 1.4fr 1fr auto;
  }
  .site-header.scrolled .mobile-search .search-form label { border-right: 1px solid var(--line); border-bottom: 0; }
}
  .header-search.in-topbar .search-form { max-width: none; margin: 0; border: 1px solid var(--line); box-shadow: none; padding: .35rem; min-width: 0; }
}

/* --- KPI-linje i person-rollekort (siste årsregnskap per bedrift) --- */
.role-card .role-kpi {
    display: flex; flex-wrap: wrap; gap: .15rem .9rem;
    margin-top: .5rem; padding-top: .5rem;
    border-top: 1px solid var(--line);
    font-size: .78rem; color: var(--muted);
}

/* --- Søkeforslag (dropdown, klikk = direkte til profil) --- */
.suggestion-wrap { position: relative; }
.suggestion-dropdown { position: absolute; top: 100%; left: 0; right: 0; z-index: 60; margin: .25rem 0 0; padding: .25rem; list-style: none; background: #fff; border: 1px solid #d7ded5; border-radius: 10px; box-shadow: 0 10px 24px rgba(0,0,0,.10); max-height: 18rem; overflow-y: auto; }
.suggestion-dropdown li + li { margin-top: 2px; }
.suggestion-dropdown button { display: flex; flex-direction: column; width: 100%; text-align: left; padding: .45rem .6rem; border: 0; border-radius: 8px; background: none; cursor: pointer; font: inherit; }
.suggestion-dropdown button strong { font-size: .92rem; color: var(--deep, #1c3a2a); }
.suggestion-dropdown button small { font-size: .74rem; color: #6a756c; }
.suggestion-dropdown button:hover, .suggestion-dropdown button.active { background: #eef3ec; }
/* Person-treff («Frank Sverre Rognli» → /person/…): annen ikon-farge + tydelig type */
.suggestion-dropdown button.person strong { color: #3a4a7a; }
.suggestion-dropdown button.person:hover, .suggestion-dropdown button.person.active { background: #eff1f8; }

/* --- Eierstruktur-fix: lange personnavn skal brytes, aldri flyte utenfor kortet (mobil) --- */
.group-grid > .group-card { min-width: 0; max-width: 100%; }
.group-list li { flex-wrap: wrap; }
.group-tree, .group-tree ul { list-style: none; margin: 0; padding-left: 1.25rem; border-left: 2px solid var(--line); }
.group-tree { padding-left: 0; border-left: 0; }
.group-tree li { margin: .3rem 0; font-size: .92rem; }
.group-tree li > span { display: block; }
.group-tree li b { font-weight: 700; }
.group-tree li small { color: var(--muted); font-size: .76rem; }
@media (max-width: 520px) { .group-tree, .group-tree ul { padding-left: .75rem; } }
.report-page { max-width: 46rem; }
.report-head h1 { margin-bottom: .4rem; }
.report-head button { font: inherit; cursor: pointer; padding: .35rem .8rem; border: 1px solid var(--line); border-radius: .5rem; background: #fff; }
.report-intro { margin: 1.25rem 0; font-size: .98rem; line-height: 1.55; }
.report-section { margin: 1.75rem 0; }
.report-section h2 { margin-bottom: .75rem; }
.report-footer { margin-top: 2.5rem; padding-top: 1rem; border-top: 1px solid var(--line); font-size: .78rem; }
@media print {
    .topbar, .desktop-nav, .mobile-menu, .mobile-search, footer, .cookie-banner, .follow-actions, button { display: none !important; }
    body { background: #fff; }
    .report-page { max-width: none; }
    .report-head button { display: none; }
    .finance-table, .company-facts { break-inside: avoid; }
}
.group-list li > span { min-width: 0; overflow-wrap: anywhere; }
.group-list li small { flex-shrink: 1; min-width: 0; overflow-wrap: anywhere; white-space: normal; }
.group-persons li { flex-wrap: wrap; }
.group-persons li > a { min-width: 0; overflow-wrap: anywhere; }
.group-persons li small { min-width: 0; overflow-wrap: anywhere; }

/* Eiertre (ownership tree) — eiere topp, enheten sentralt, datterselskaper nede. */
.ot { display: flex; flex-direction: column; align-items: stretch; margin: 0 0 1.25rem; padding: 1rem; border: 1px solid var(--line); border-radius: .8rem; background: var(--soft); }
.ot-eyebrow { margin: 0 0 .5rem; color: var(--muted); font-size: .72rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.ot-tier { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: .6rem; }
.ot-top { margin-bottom: .25rem; }
.ot-bottom { margin-top: 1rem; }
.ot-rail { width: 2px; height: 26px; background: var(--line-strong, #b8d63e); margin: 0 auto; }
.ot-rail-up { border-radius: 0 0 0 0; }
.ot-node { display: flex; flex-direction: column; align-items: center; gap: .25rem; min-height: 76px; padding: .7rem .6rem; border: 1px solid var(--line); border-radius: .8rem; background: #fff; text-align: center; text-decoration: none; color: var(--ink); transition: border-color .12s ease, transform .1s ease; }
.ot-node:hover { border-color: var(--lime-strong); text-decoration: none; }
.ot-node b { font-size: .92rem; line-height: 1.25; overflow-wrap: anywhere; }
.ot-node small, .ot-node .ot-badge { display: inline-block; margin-top: .15rem; padding: .2rem .55rem; border-radius: 1rem; background: var(--lime); color: var(--deep); font-size: .76rem; font-weight: 800; }
.ot-badge.ot-badge-person { background: #e9edf2; color: #33475b; }
.ot-badge.ot-badge-self { background: var(--deep); color: var(--lime); }
.ot-self { min-width: 240px; max-width: 420px; align-self: center; border-width: 2px; border-color: var(--deep); }
.ot-person { border-style: dashed; }
@media (max-width: 600px) { .ot-tier { grid-template-columns: 1fr; } .ot-self { min-width: 0; max-width: none; } }
.ot-others { margin-top: .35rem; color: var(--muted); font-size: .72rem; font-weight: 600; line-height: 1.3; }
#om-bedriften { scroll-margin-top: 5.5rem; }
@media (max-width: 800px) { #om-bedriften { scroll-margin-top: 8.25rem; } }

/* AKSJEEIERBOK-tabeller (.bluetooth Aksjonærer/Eierskap i andre selskaper). */
.akseier-table { width: 100%; margin: 0 0 1.25rem; border-collapse: collapse; background: #fff; border: 1px solid var(--line); border-radius: .8rem; overflow: hidden; }
.akseier-table caption { padding: .8rem 1rem; background: var(--soft); color: var(--muted); font-size: .72rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; text-align: left; }
.akseier-table th { padding: .55rem 1rem; border-bottom: 1px solid var(--line); color: var(--muted); font-size: .72rem; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; text-align: left; }
.akseier-table th:nth-child(2), .akseier-table th:nth-child(3), .akseier-table td:nth-child(2), .akseier-table td:nth-child(3) { text-align: right; white-space: nowrap; }
.akseier-table td { padding: .6rem 1rem; border-bottom: 1px solid var(--line); font-size: .92rem; }
.akseier-table tbody tr:last-child td { border-bottom: 0; }
.akseier-table .akseier-name { font-weight: 800; text-decoration: none; color: var(--ink); }
.akseier-table .akseier-name:hover { text-decoration: underline; }
.akseier-table .akseier-person { border-bottom: 1px dashed var(--line); }
.akseier-table td small { display: block; margin-top: .15rem; color: var(--muted); font-size: .74rem; font-weight: 600; }
.akseier-table .akseier-pct { font-weight: 800; color: var(--deep); }

/* Åpen eierhistorikk (ikke collapse) + panel-anmeldelser i sidebaren. */
.owner-history-open { background: #fff; border: 1px solid var(--line); border-radius: .8rem; padding: 1rem 1rem .5rem; }
.owner-history-open h3 { font-size: .95rem; margin: 0 0 .35rem; }
.reviews-aside { margin: 0 0 1rem; }
.reviews-aside .section-heading h2 { font-size: 1rem; }
.reviews-aside .section-heading .muted { display: none; }

/* ══ DESIGNBRIEF 22.09: én universell innholdskolonne + datarow-komponenter ══ */
:root { --page-bg:#f6f7f5; --surface:#ffffff; --surface-soft:#f2f4f1; --ink:#17201b; --muted-col:#647068; --border-col:#dfe4df; --radius-md:14px; }
.company-layout { display: block; max-width: 1000px; margin-inline: auto; padding: 0 16px 4rem; width: 100%; }
.company-layout > section { width: 100%; }
.company-section[id] { padding-block: clamp(32px, 5vw, 56px); border-bottom: 1px solid var(--border-col); }
.company-section[id]:last-child { border-bottom: 0; }
.company-section[id] > .section-heading { margin-top: 0; }
.company-content-grid { display: grid; grid-template-columns: 1fr; gap: .75rem; }
@media (min-width: 760px) { .company-content-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.data-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px 20px; align-items: center; padding-block: 16px; border-bottom: 1px solid var(--border-col); }
.data-row:last-of-type { border-bottom: 0; }
.data-row-main { min-width: 0; }
.data-row-title { font-weight: 800; text-decoration: none; color: var(--ink); overflow-wrap: anywhere; }
.data-row-title:hover { text-decoration: underline; }
.data-row-meta { display: block; margin-top: .15rem; color: var(--muted-col); font-size: .8rem; }
.data-row-value { white-space: nowrap; font-weight: 800; color: var(--deep); }
.disclosure { border: 1px solid var(--border-col); border-radius: var(--radius-md); background: var(--surface); padding: .35rem .8rem; }
.disclosure > summary { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .65rem .4rem; cursor: pointer; list-style: none; }
.disclosure > summary::-webkit-details-marker { display: none; }
.disclosure > summary small { display: block; color: var(--muted-col); font-size: .74rem; margin-top: .15rem; }
.disclosure[open] > summary span[aria-hidden]::after { content: '▾'; }
.disclosure > summary span[aria-hidden]::after { content: '›'; display: inline-block; transition: transform .12s ease; }
.disclosure-content { padding: .8rem .4rem 1rem; }
/* historikk lukket by default: klassen eierhistorikk er en <details class="disclosure ownership-history"> */

/* ══ Trinn 4: hero-kart + rolig signal-flate + related som data-rows ══ */
.company-hero { position: relative; isolation: isolate; overflow: hidden; background: var(--surface); }
.company-hero .hero-map { position: absolute; inset: 0; z-index: -2; pointer-events: none; filter: saturate(.65) contrast(.95) brightness(1.02); }
.company-hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(12,24,18,.92) 0%, rgba(12,24,18,.80) 46%, rgba(12,24,18,.38) 100%); }
@media (max-width: 759px) {
    .company-hero::before {
        background: linear-gradient(180deg, rgba(12,24,18,.28) 0%, rgba(12,24,18,.45) 42%, rgba(12,24,18,.88) 100%);
    }
    .hero-map-img { filter: saturate(.8) contrast(.95) brightness(1); }
}
.company-hero .company-hero-grid > div { position: relative; z-index: 1; }
.company-hero .company-hero-grid > div p.muted, .company-hero .company-hero-grid > div p.breadcrumbs, .company-hero .company-hero-grid > div h1 { color: #fff; }
.company-hero .company-hero-grid > div p.muted { color: rgba(255,255,255,.82); }
.company-hero .company-hero-grid > div small.badge { background: rgba(255,255,255,.16); color: #fff; }
.company-hero .company-hero-grid > div p.rating { color: #fff; }
.company-hero .company-hero-actions a[href^="http"] { background: rgba(255,255,255,.94); color: #17201b; }
/* signal-panel rolgjort */
.signal-panel { background: var(--surface-soft, #f2f4f1) !important; border: 1px solid var(--border-col, #dfe4df) !important; box-shadow: none !important; }
.signal-panel.tone-red { border-left: 3px solid #d84848; }
.signal-panel.tone-amber { border-left: 3px solid #e0a83f; }
.signal-panel.tone-green { border-left: 3px solid #2ea777; }
.signal-panel .signal-text, .signal-panel .signal-list { color: #33423a; }
/* roller/underenheter/lignende i data-row-stil */
.data-list { display: block; }
.data-list .data-row:last-of-type { border-bottom: 0; }
@media (min-width: 760px) {
  .data-list.related-cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 32px; }
  .data-list.related-cols .data-row:nth-last-of-type(-n+2) { border-bottom: 0; }
}
.osm-embed { width: 100%; height: 300px; border: 0; border-radius: 12px; }

/* ══ Fargekodede seksjonsbakgrunner (rolige, nøytrale tintes — designbrief §8.2) ══ */
/* #oversikt = lys grønn · #okonomi = nær hvit · #eierskap = lys gråblå · #roller = lys sand
   #hendelser = lys grønn-soft · #anmeldelser = lys fellesskaps-tone · #kontakt = lys varm grå
   #bedriftseiere = uspecified · #om-bedriften-mer = lys grønn-grå */
.company-section#oversikt      { background: #eef3ec; }
.company-section#okonomi       { background: #f7f9f7; }
.company-section#eierskap      { background: #eef1f4; }
.company-section#roller        { background: #f3f1ec; }
.company-section#hendelser     { background: #f0f4f0; }
.company-section#anmeldelser   { background: #f2f4f1; }
.company-section#lokasjon      { background: #f4f3f1; }
.company-section#bedriftseiere { background: #f5f4f2; }
.company-section#om-bedriften-mer { background: #eff2ee; }

/* Stylede bokser for alt innhold (§7.2): ingen løse tekstblokker */
.metric-card { display: block; padding: 18px; border: 1px solid var(--border-col, #dfe4df); border-radius: 14px; background: var(--surface-soft, #ffffff); }
.data-row.stone { padding-inline: 16px; border: 1px solid var(--border-col, #dfe4df); border-radius: var(--radius-md, 14px); background: var(--surface-soft, #ffffff); margin-bottom: .75rem; }

/* alt i eierskapsseksjonen inn i rolig boks */
#eierskap .ownership-box    { background: #ffffff; border: 1px solid var(--border-col); border-radius: var(--radius-md); padding: 1.25rem; margin-bottom: 1rem; }
#eierskap .ownership-box h3 { margin: 0 0 .6rem; }
#eierskap .ownership-box .data-row { padding-inline: 0; }

/* contacts + bedriftseiere: layout i én stiling */
#kontakt .company-facts div, #bedriftseiere .company-facts div { background: var(--surface-soft, #f2f4f1); border: 1px solid var(--border-col); border-radius: 12px; padding: 14px; }

/* FAQ: samme sentrerte container som resten av sidene */
.company-faq-section { max-width: 1000px; margin-inline: auto; width: 100%; padding: 0 16px 3rem; }
.company-faq-section .hub-collapsible { margin-top: 0; }

/* Bedriftsprofiler: redaksjonell datafortelling med tydelige fakta og rolige databaand. */
.company-hero { min-height: 430px; display: flex; align-items: flex-end; padding: clamp(56px, 9vw, 112px) 0 clamp(40px, 6vw, 72px); background: #17201b; }
.company-hero .container { width: min(100% - 32px, 1000px); }
.hero-map-img { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; object-position: center; filter: saturate(.64) contrast(.9) brightness(.8); }
.company-hero::before { background: linear-gradient(90deg, rgba(12, 24, 18, .94) 0%, rgba(12, 24, 18, .83) 52%, rgba(12, 24, 18, .36) 100%); }
.company-hero-grid { width: 100%; }
.hero-kicker { margin: 0 0 .65rem; color: #c9d2c9; font-size: .72rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.company-hero h1 { max-width: 760px; font-size: clamp(2.25rem, 6vw, 4.6rem); line-height: .98; letter-spacing: -.055em; }
.company-hero .breadcrumbs { margin-top: 1rem; font-size: .82rem; }
.company-hero .breadcrumbs a { color: #dce8dc; }
.company-hero .company-hero-fact { padding: 1rem 0 0 1.6rem; border-color: rgba(255, 255, 255, .28); color: #fff; }
.company-hero .company-hero-fact span, .company-hero .company-hero-fact small { color: #d3ddd3; }
.company-hero .company-hero-actions .button { border-color: transparent; }
.company-hero .company-hero-actions .button:not(.secondary) { background: #d8ec64; color: #17201b; }
.company-hero .company-hero-actions .hero-claim-button { border-color: rgba(216, 236, 100, .75); background: transparent; color: #f4f9db; }
.company-hero .company-hero-actions .hero-claim-button:hover { background: rgba(216, 236, 100, .12); }

.company-nav { background: rgba(255, 255, 255, .96); backdrop-filter: blur(10px); }
.company-nav-wrap { gap: .35rem; }
.company-nav-inner { gap: 1.25rem; padding: .15rem 0; }
.company-nav-inner a { padding: .9rem 0 .75rem; border: 0; border-radius: 0; background: transparent; color: var(--muted-col); font-size: .78rem; letter-spacing: .02em; }
.company-nav-inner a:hover { background: transparent; color: var(--ink); }
.company-nav-inner a.active { border: 0; border-bottom: 2px solid var(--ink); background: transparent; color: var(--ink); }
.company-nav-divider { flex: 0 0 1px; align-self: center; height: 20px; background: var(--border-col); }
.company-nav-inner a.company-nav-action { padding: .9rem 0 .75rem; border: 0; border-radius: 0; background: transparent; color: #55721d; font-size: .78rem; font-weight: 800; letter-spacing: .02em; }
.company-nav-inner a.company-nav-action:hover, .company-nav-inner a.company-nav-action:focus-visible { background: transparent; color: #55721d; }
.company-nav-inner a.company-nav-action.active { border-bottom: 2px solid #55721d; background: transparent; color: #3f5a12; }
.company-nav-arrow { width: 1.85rem; height: 1.85rem; border-color: rgba(23, 32, 27, .14); background: #fff; color: var(--ink); font-size: 1.15rem; }
.company-nav-wrap::before { left: 2rem; }
.company-nav-wrap::after { right: 2rem; }

.company-layout { max-width: 1000px; padding-bottom: 0; }
.company-section[id] { position: relative; isolation: isolate; margin-inline: -16px; padding-inline: 16px; border-bottom: 0; }
.company-section[id]::before { content: ""; position: absolute; z-index: -2; inset: 0 calc(50% - 50vw); background: inherit; }
.company-section[id]::after { content: ""; position: absolute; z-index: -1; inset: 24px 16px; border: 1px solid rgba(23, 32, 27, .1); border-radius: 18px; background: rgba(255, 255, 255, .6); box-shadow: 0 14px 35px rgba(23, 32, 27, .04); }
.company-section[id] + .company-section[id] { margin-top: 0; border-top: 0; }
.section-heading { margin: 0 0 1.5rem; }
.section-heading h2 { max-width: 720px; font-size: clamp(1.6rem, 3vw, 2.45rem); line-height: 1.08; letter-spacing: -.035em; }
.section-heading .muted { max-width: 660px; margin-top: .5rem; }
.company-overview-heading { margin-bottom: 1.25rem; }
.company-summary-panel { max-width: none; padding: 15px; border: 0; border-radius: 0; background: transparent; box-shadow: none; }
.company-summary { margin: 0; font-size: clamp(1.1rem, 2vw, 1.35rem); line-height: 1.55; }
.data-provenance { margin: 1.25rem 0 0; color: var(--muted-col); font-size: .78rem; }
.company-metrics { margin: 0 0 1.5rem; border-color: rgba(23, 32, 27, .16); }
.company-metrics div { padding: 1rem 1.2rem 1rem 0; }
.company-metrics b { font-size: clamp(1.35rem, 2.3vw, 1.85rem); }
.company-facts { gap: .6rem; margin-bottom: 0; }
.company-facts div { min-height: 0; border: 0; border-radius: 0; background: rgba(255, 255, 255, .68); }
.panel, .review { border-color: rgba(23, 32, 27, .12); border-radius: 12px; box-shadow: none; }
.reviews.company-section { margin-top: 0; }
.company-section#oversikt { background: #eef3ec; }
.company-section#okonomi { background: #f8f8f4; }
.company-section#eierskap { background: #eff2f5; }
.company-section#roller { background: #f5f1e9; }
.company-section#hendelser { background: #edf4ee; }
.company-section#anmeldelser { background: #f4f0e8; }
.company-section#lokasjon { background: #f1f3ee; }
.company-section#bedriftseiere { background: #f6f5f1; }
.company-section#om-bedriften-mer { background: #eef3ec; }

@media (max-width: 759px) {
    .company-hero { min-height: 0; padding: 4rem 0 3rem; }
    .company-hero::before {
        background: linear-gradient(180deg, rgba(12, 24, 18, .28) 0%, rgba(12, 24, 18, .45) 42%, rgba(12, 24, 18, .88) 100%);
    }
    .company-hero .company-hero-fact { padding-left: 0; }
    .company-section[id] { padding-inline: 16px; }
    .company-nav-inner { gap: 1rem; }
}

/* Felles kortflate: informasjon skal alltid ligge tydelig over seksjonsfargen. */
.company-section .panel,
.company-section .company-facts > div,
.company-section .related-companies > a,
.company-section .related-companies > article,
.company-section .data-list > a,
.company-section .data-list > article,
.company-section .data-list .data-row,
.company-section .disclosure,
.company-section .hub-collapsible,
.company-faq-section .hub-collapsible {
    background: rgba(255, 255, 255, .94);
    border: 1px solid rgba(23, 32, 27, .14);
    border-radius: 14px;
    box-shadow: 0 8px 22px rgba(23, 32, 27, .06);
}
.company-section .company-summary-panel { max-width: none; padding: 15px; }
.company-section .company-facts { grid-template-columns: repeat(auto-fit, minmax(185px, 1fr)); gap: .75rem; }
.company-section .company-facts > div { min-height: 104px; padding: 1.1rem; }
.company-section .company-metrics { gap: .75rem; border: 0; }
.company-section .company-metrics > div,
.company-section .company-metrics > div + div {
    min-height: 104px;
    padding: 1.1rem;
    border: 1px solid rgba(23, 32, 27, .14);
    border-radius: 14px;
    background: rgba(255, 255, 255, .94);
    box-shadow: 0 8px 22px rgba(23, 32, 27, .06);
}
.company-section .related-companies > a,
.company-section .related-companies > article { min-height: 0; }
.company-section .data-list { display: grid; gap: .65rem; }
.company-section .data-list > a,
.company-section .data-list > article,
.company-section .data-list .data-row { padding: 1rem 1.1rem; margin: 0; }
.company-section .data-list .data-row:last-of-type { border-bottom: 1px solid rgba(23, 32, 27, .14); }
.company-section .data-list.related-cols { column-gap: .65rem; row-gap: .65rem; }
.company-section .signal-panel { background: rgba(255, 255, 255, .94) !important; }
.company-section .signal-panel, .company-section .credit-cta-panel { margin-top: 1rem; }
.company-owner-actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1rem; }
.company-section .disclosure[open], .company-section .hub-collapsible[open] { box-shadow: 0 12px 28px rgba(23, 32, 27, .09); }

/* Det store seksjonspanelet skiller nivåene; innholdet inni er bevisst uten avrundede hjørner. */
.company-section > .section-heading,
.company-section > section,
.company-section > article,
.company-section > .data-list,
.company-section > .company-facts { margin-inline: 8px; }
.company-section .panel,
.company-section .company-facts > div,
.company-section .related-companies > a,
.company-section .related-companies > article,
.company-section .data-list > a,
.company-section .data-list > article,
.company-section .data-list .data-row,
.company-section .disclosure,
.company-section .hub-collapsible,
.company-section .company-metrics > div,
.company-section .company-metrics > div + div { border-radius: 0; }
.company-section .ownership-box,
.company-section .place-stats-grid article,
.company-section .browse-list a,
.company-section .event-timeline,
.company-section .event-timeline-item,
.company-section .signal-panel,
.company-section .finance-history,
.company-section .valuation-panel,
.company-section .credit-cta-panel,
.company-section .empty-reviews,
.company-section .review,
.company-section .response,
.company-section .report-details,
.company-section .specialist-panel,
.company-section .owner-history-open,
.company-section .map-placeholder { border-radius: 0 !important; }

@media (max-width: 759px) { .company-nav-divider { display: none; } }

/* Én enkel seksjonsflate: innholdet løftes fra siden uten egne fargetemaer. */
.company-section[id] {
    margin: 20px 0;
    padding: 20px;
    background: #fff !important;
    border: 1px solid rgba(23, 32, 27, .16);
    border-radius: 0;
    box-shadow: 0 5px 14px rgba(23, 32, 27, .06);
}
.company-section[id]::before,
.company-section[id]::after { display: none; }
.company-section[id] + .company-section[id] { margin-top: 20px; }
.company-section > .section-heading,
.company-section > section,
.company-section > article,
.company-section > .data-list,
.company-section > .company-facts { margin-inline: 0; }
@media (max-width: 759px) { .company-section[id] { margin: 12px 0; padding: 20px; } }

/* Seksjonen er kortet. Innholdet inni skal ikke få en ny kortflate. */
.company-section .panel,
.company-section .company-facts > div,
.company-section .related-companies > a,
.company-section .related-companies > article,
.company-section .data-list > a,
.company-section .data-list > article,
.company-section .data-list .data-row,
.company-section .disclosure,
.company-section .hub-collapsible,
.company-section .ownership-box,
.company-section .place-stats-grid article,
.company-section .company-metrics > div,
.company-section .company-metrics > div + div {
    background: transparent !important;
    border: 0;
    box-shadow: none;
}
.company-section .company-facts > div { min-height: 0; padding: .55rem 0; }
.company-section .company-metrics > div,
.company-section .company-metrics > div + div { min-height: 0; padding: .55rem 0; }
.company-section .data-list { gap: 0; }
.company-section .data-list > a,
.company-section .data-list > article,
.company-section .data-list .data-row { padding: 1rem 0; border-bottom: 1px solid rgba(23, 32, 27, .14); }
.company-section .data-list > :last-child { border-bottom: 0; }
.company-owner-badge { margin-top: 1.5rem; }
.company-owner-badge h3 { margin-bottom: .5rem; }
/* Samme ytre bredde som .company-layout (1000) minus layout-padding (16+16). */
.container.company-faq-section,
.company-faq-section {
    box-sizing: border-box;
    width: min(100% - 32px, 968px);
    max-width: 968px;
    margin: 20px auto;
    padding: 20px;
    background: #fff;
    border: 1px solid rgba(23, 32, 27, .16);
    border-radius: 0;
    box-shadow: 0 5px 14px rgba(23, 32, 27, .06);
}
.company-faq-content dt { margin-top: 1.25rem; }
.company-faq-content dt:first-child { margin-top: 0; }
.company-faq-content dd { margin: .35rem 0 0; }

/* Flat avgrensning av viktige datagrupper, uten å gå tilbake til kortsystemet. */
.company-section .company-metrics,
.company-section .company-summary-panel,
.company-section .company-facts,
.company-section .data-list,
.company-section .ownership-box,
.company-section .signal-panel,
.company-section .finance-history,
.company-section .valuation-panel,
.company-section .credit-cta-panel,
.company-section .disclosure,
.company-section .hub-collapsible,
.company-section .company-owner-badge,
.company-faq-content {
    border: 1px solid rgba(23, 32, 27, .18);
    border-radius: 0;
    box-shadow: none;
}
.company-section .company-facts,
.company-section .data-list,
.company-section .company-owner-badge,
.company-faq-content { padding: 0 16px; }
.company-section .company-owner-badge,
.company-faq-content { padding-block: 16px; }

/* Nøkkeltall markeres per verdi, ikke med én ramme rundt hele gruppen. */
.company-section .company-metrics,
.company-section .company-facts { padding: 0; border: 0; }
.company-section .company-metrics > div,
.company-section .company-metrics > div + div,
.company-section .company-facts > div {
    padding: 16px;
    border: 1px solid rgba(23, 32, 27, .18);
    border-radius: 0;
}
/* Kontaktinformasjon trenger én rolig gruppe, ikke et kort rundt hver opplysning. */
#kontakt .company-facts { padding: 16px; border: 1px solid rgba(23, 32, 27, .18); }
#kontakt .company-facts > div { padding: .4rem 0; border: 0; border-radius: 0; background: transparent; box-shadow: none; }

/* Lignende bedrifter avslutter profilsiden med samme bredde som øvrige seksjoner. */
.container.company-related-section,
.company-related-section {
    box-sizing: border-box;
    width: min(100% - 32px, 968px);
    max-width: 968px;
    margin: 20px auto !important;
}
.company-related-section .data-list > a,
.company-section .data-list > a {
    display: block;
    text-decoration: none;
    color: inherit;
}
.company-related-section .data-list > a b,
.company-section .data-list > a b {
    display: block;
    margin: 0;
    line-height: 1.3;
}
.company-related-section .data-list > a span,
.company-section .data-list > a span {
    display: block;
    margin-top: .35rem;
    color: var(--muted);
    font-size: .84rem;
    line-height: 1.35;
    font-weight: 500;
}

/* Bransje-benchmark: ramme per nøkkeltall, samme språk som øvrige KPI-ruter. */
.company-section .place-stats-grid .benchmark-card,
.company-section .place-stats-grid article {
    min-height: 0;
    padding: 16px;
    border: 1px solid rgba(23, 32, 27, .18) !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
}

/* Bedriftsprofil-typografi: strammere skala så mer innhold får plass. */
.company-hero h1 { font-size: clamp(1.7rem, 3.4vw, 2.55rem); line-height: 1.08; letter-spacing: -.03em; }
.company-hero .muted,
.company-hero .breadcrumbs,
.company-hero .external-rating { font-size: .88rem; }
.company-hero .rating.large { font-size: .95rem; }
.company-hero .company-hero-fact b { font-size: 1.45rem; }
.company-section,
.company-faq-section,
.company-related-section { font-size: .95rem; line-height: 1.5; }
.company-section .section-heading h2,
.company-faq-section .section-heading h2,
.company-related-section .section-heading h2,
.company-section h2 { font-size: clamp(1.2rem, 1.8vw, 1.45rem); line-height: 1.2; letter-spacing: -.02em; }
.company-section .section-heading .muted,
.company-faq-section .section-heading .muted { font-size: .88rem; }
.company-section .eyebrow,
.company-faq-section .eyebrow { font-size: .68rem; }
.company-summary { font-size: 1rem; line-height: 1.5; }
.company-section .company-summary-panel { max-width: none; padding: 15px; }
.company-section .company-metrics b { font-size: clamp(1.15rem, 1.8vw, 1.4rem); }
.company-section .company-facts b,
.company-section .place-stats-grid b,
.company-section .benchmark-grid .benchmark-card b {
    font-size: 1.15rem;
    overflow-wrap: break-word;
}
.company-section .company-facts span,
.company-section .company-metrics span,
.company-section .place-stats-grid span { font-size: .68rem; }
.company-section .place-stats-grid small,
.company-section .company-metrics small { font-size: .74rem; }
.company-section .place-stats h2 { font-size: 1.15rem; }
.company-section .panel h2,
.company-section .panel h3,
.company-section h3 { font-size: 1.05rem; }
.company-section .data-row-title,
.company-section .data-list b { font-size: .95rem; }
.company-section .data-row-meta,
.company-section .data-list span,
.company-section .muted { font-size: .84rem; }
.company-section .data-row-value { font-size: .95rem; }
.company-faq-content dt { font-size: .95rem; }
.company-faq-content dd { font-size: .88rem; }

/* ============================================================
   REGNSKAP V2 — årsvelger + detaljert resultat/balanse
   (RATI_REGNSKAP_V2 §7.2/§7.4/§7.5/§7.6) — kompakt, i eksisterende designspråk
   ============================================================ */
.fin-year-tabs { display: flex; flex-wrap: wrap; gap: .35rem; margin-top: .5rem; }
.fin-year-tab { display: inline-flex; align-items: baseline; gap: .35rem;
  padding: .28rem .6rem; border: 1px solid var(--line); border-radius: 999px; background: transparent;
  color: var(--text-muted); font: inherit; font-size: .78rem; line-height: 1.3; cursor: pointer;
  transition: border-color .15s ease, background .15s ease, color .15s ease; }
.fin-year-tab b { font-size: .78rem; font-weight: 800; color: var(--ink); }
.fin-year-tab small { font-size: .7rem; color: var(--text-muted); }
.fin-year-tab:hover { border-color: var(--lime-strong); }
.fin-year-tab.active { border-color: var(--lime-strong); background: var(--soft); }
.fin-year-tab.active small { color: var(--ink); }
.fin-year-tab.is-pending, .fin-year-tab.is-no-detail { opacity: .45; cursor: default; border-style: dashed; }
.fin-detail { display: none; }
.fin-detail.fin-detail-ready { margin-top: .85rem; border: 0; border-top: 1px solid var(--line); background: transparent; border-radius: 0; display: block; }
.fin-detail + .fin-detail { margin-top: 0; border-top: 0; }
.fin-detail summary { cursor: pointer; font-size: .78rem; font-weight: 800; letter-spacing: .04em;
  color: var(--ink); padding: .55rem 0 .15rem; }
.fin-detail summary::marker { color: var(--text-muted); }
.fin-detail[open] summary { border-bottom: 0; }
.fin-detail-table { margin-top: .35rem; }
/* sum-rader: tydelig men rolig */
.finance-table .fin-sum td { font-weight: 800; color: var(--ink); border-top: 1.5px solid var(--line-strong); }

/* §7.6 mobil: sticky første kolonne i detaljtabellene, årene sveipes */
@media (max-width: 800px) {
  .fin-detail-table th:first-child,
  .fin-detail-table td:first-child { position: sticky; left: 0; z-index: 1; background: var(--surface); width: 8rem; min-width: 8rem; }
  .fin-detail-table .fin-sum td:first-child { background: var(--paper); }
}

/* ==== Rati CRM («HubSpot Light») ==== */
.crm-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: .9rem; margin-bottom: 1.5rem; }
.crm-kpis .kpi { min-height: 0; padding: .9rem 1.1rem; }
.crm-kpis .kpi-num { font-size: 1.25rem; font-weight: 900; }
.crm-kpis .kpi-meta { color: var(--muted); font-size: .74rem; font-weight: 700; }
.kanban { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(240px, 1fr); gap: .9rem; overflow-x: auto; padding-bottom: 1rem; align-items: start; }
.kanban-col { background: var(--surface); border: 1px solid var(--line); border-radius: .9rem; padding: .8rem; min-height: 8rem; }
.kanban-col-head { display: flex; align-items: baseline; justify-content: space-between; gap: .5rem; padding: .1rem .2rem .55rem; border-bottom: 1px solid var(--line); margin-bottom: .6rem; }
.kanban-col-head h2 { margin: 0; font-size: .82rem; font-weight: 900; letter-spacing: .02em; }
.kanban-count { display: inline-block; margin-left: .3rem; padding: .05rem .45rem; border-radius: 1rem; background: var(--soft); color: var(--ink); font-size: .72rem; font-weight: 800; }
.kanban-prob { color: var(--muted); font-size: .72rem; font-weight: 700; }
.kanban-empty { color: var(--muted); font-size: .78rem; margin: .4rem 0; }
.deal-card { display: grid; gap: .15rem; margin-bottom: .6rem; padding: .7rem .8rem; border: 1px solid var(--line); border-radius: .7rem; background: var(--paper); font-size: .84rem; }
.deal-card:target-within, .deal-card:hover { border-color: var(--line-strong); }
.deal-company { font-size: .72rem; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); text-decoration: none; }
.deal-company:hover { text-decoration: underline; }
.deal-title { margin: .1rem 0; font-weight: 800; }
.deal-value { margin: 0; font-weight: 700; color: var(--ink); }
.deal-meta { margin: 0; color: var(--muted); font-size: .76rem; }
.deal-foot { display: flex; align-items: center; justify-content: space-between; gap: .5rem; margin-top: .35rem; }
.deal-owner { color: var(--muted); font-size: .74rem; }
.deal-move { display: flex; align-items: center; gap: .3rem; }
.deal-move select { max-width: 9.5rem; padding: .2rem .35rem; font-size: .76rem; }
.link-btn { background: none; border: 0; padding: 0; color: var(--ink); font: inherit; font-size: .78rem; font-weight: 800; text-decoration: underline; cursor: pointer; }
.crm-table { width: 100%; border-collapse: collapse; font-size: .88rem; }
.crm-table th { text-align: left; color: var(--muted); font-size: .7rem; font-weight: 900; letter-spacing: .06em; text-transform: uppercase; padding: .5rem .6rem; border-bottom: 1.5px solid var(--line-strong); }
.crm-table td { padding: .6rem; border-bottom: 1px solid var(--line); vertical-align: top; }
.crm-table tr:last-child td { border-bottom: 0; }
.crm-table .muted { display: block; font-size: .76rem; }
.task-overdue td:first-child { border-left: 3px solid #c0392b; }
.task-done td { opacity: .55; }
.crm-search { display: flex; gap: .5rem; margin-bottom: 1rem; }
.crm-search input { flex: 1; }
.crm-add { display: flex; gap: .5rem; margin: .8rem 0 1.2rem; }
.crm-add input { max-width: 16rem; }
.crm-form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr)); gap: .7rem; align-items: end; margin: .5rem 0 1rem; }
.crm-form-grid label { display: grid; gap: .25rem; color: var(--muted); font-size: .74rem; font-weight: 800; }
.crm-form-grid input, .crm-form-grid select, .crm-form-grid textarea { padding: .5rem .6rem; border: 1.5px solid var(--line); border-radius: .55rem; font: inherit; background: #fff; }
.crm-form-grid .crm-wide { grid-column: 1 / -1; }
.crm-profile-head { display: flex; justify-content: space-between; gap: 1rem; align-items: flex-start; margin-bottom: 1.25rem; }
.crm-status-form { display: grid; gap: .4rem; min-width: 11rem; }
.crm-status-form label { display: grid; gap: .25rem; color: var(--muted); font-size: .74rem; font-weight: 800; }
.crm-status-form select { padding: .45rem .55rem; border: 1.5px solid var(--line); border-radius: .55rem; font: inherit; }
.crm-close-details { margin-top: .3rem; }
.crm-close-details summary { list-style: none; cursor: pointer; }
.crm-close-details summary::-webkit-details-marker { display: none; }
.crm-close-details form { margin-top: .5rem; }
.crm-timeline { list-style: none; margin: .5rem 0 0; padding: 0; }
.crm-timeline li { display: flex; gap: .9rem; padding: .6rem 0; border-top: 1px solid var(--line); font-size: .88rem; }
.crm-timeline li:first-child { border-top: 0; }
.crm-timeline li p { margin: .2rem 0; color: var(--ink); }
.crm-timeline-time { flex-shrink: 0; width: 8.2rem; color: var(--muted); font-size: .76rem; font-variant-numeric: tabular-nums; }
.activity-system { opacity: .72; }
.activity-system b { font-weight: 700; }
@media (max-width: 800px) {
  .crm-kpis { grid-template-columns: repeat(2, 1fr); }
  .kanban { grid-auto-flow: row; grid-auto-columns: unset; }
  .kanban-col { min-height: 0; }
  .crm-profile-head { flex-direction: column; }
  .crm-timeline-time { width: 5.5rem; }
}

/* CRM runde 2: filtre, neste aktivitet, DnD-tilstander, kontakter */
.crm-filters { display: flex; align-items: center; gap: .6rem; margin-bottom: 1.1rem; }
.crm-filters input[type="search"] { max-width: 18rem; padding: .45rem .6rem; border: 1.5px solid var(--line); border-radius: .55rem; font: inherit; background: #fff; }
.crm-filter-check { display: flex; align-items: center; gap: .3rem; font-size: .8rem; font-weight: 700; }
.deal-next-task { margin: .1rem 0 0; font-size: .74rem; color: var(--muted); }
.deal-next-task b { font-weight: 800; }
.deal-next-task.is-overdue { color: #c0392b; }
.deal-card[draggable="true"] { cursor: grab; }
.deal-card.is-dragging { opacity: .45; border-style: dashed; }
.kanban-col.is-drop-target { border-color: var(--lime-strong); background: var(--soft); }
.crm-dnd-error { margin: .4rem 0; padding: .5rem .8rem; border: 1px solid #c0392b; border-radius: .55rem; color: #c0392b; font-size: .8rem; font-weight: 700; background: #fff5f4; }
@media (max-width: 800px) { .deal-card[draggable="true"] { cursor: default; } }
/* hidden-attributt skal ALLTID vinne — ellers vises skjulte elementer når
   author-CSS setter display (funnet live 21.09: .company-hero-actions form
   { display:contents } avslørte det skjulte CRM-skjemaet → dobbel knapp). */
[hidden] { display: none !important; }

/* ==== Rati CRM — UX-spec tokens (§5) ==== */
.crm {
  --crm-bg: #f5f7fa;
  --crm-surface: #ffffff;
  --crm-surface-muted: #f0f3f6;
  --crm-text: #17202a;
  --crm-text-muted: #667085;
  --crm-border: #dde3ea;
  --crm-primary: var(--deep, #15231d);
  --crm-primary-soft: var(--soft, #e7efdf);
  --crm-success: #168a5b;
  --crm-warning: #b66a00;
  --crm-danger: #c43d4b;
  --crm-info: #2563b8;
  background: var(--crm-bg);
}

/* ==== Shell (§6): arbeidsområdevelger, tellemerke, bruksmåler ==== */
.crm-workspace { position: relative; }
.crm-workspace summary { display: flex; align-items: center; gap: .45rem; padding: .55rem .65rem; border: 1px solid var(--crm-border); border-radius: .55rem; background: var(--crm-surface); cursor: pointer; list-style: none; font-size: .84rem; font-weight: 800; }
.crm-workspace summary::-webkit-details-marker { display: none; }
.crm-workspace-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.crm-workspace-plan { padding: .1rem .45rem; border-radius: 999px; background: var(--crm-primary-soft); font-size: .66rem; font-weight: 900; letter-spacing: .04em; text-transform: uppercase; }
.crm-workspace-caret { color: var(--crm-text-muted); }
.crm-workspace-menu { margin-top: .35rem; padding: .4rem; border: 1px solid var(--crm-border); border-radius: .55rem; background: var(--crm-surface); }
.crm-nav-badge { display: inline-block; margin-left: .35rem; padding: .02rem .42rem; border-radius: 999px; background: var(--crm-surface-muted); color: var(--crm-text-muted); font-size: .68rem; font-weight: 800; }
.crm-nav-badge.is-overdue { background: var(--crm-danger); color: #fff; }
.crm-usage { display: grid; gap: .3rem; margin: .35rem 0 .7rem; }
.crm-usage-label { font-size: .74rem; font-weight: 800; color: var(--crm-text-muted); }
.crm-usage-bar { height: .45rem; border-radius: 999px; background: var(--crm-surface-muted); overflow: hidden; }
.crm-usage-bar span { display: block; height: 100%; border-radius: 999px; background: var(--crm-primary); }
.crm-usage-bar span.is-warning { background: var(--crm-warning); }
.crm-usage-bar span.is-critical { background: var(--crm-danger); }
.crm-usage-note { font-size: .72rem; font-weight: 700; }
.crm-usage-note.is-warning { color: var(--crm-warning); }
.crm-usage-note.is-critical { color: var(--crm-danger); }

/* ==== KPI (§8): hovedverdi + sekundærtekst + klikkhandling ==== */
.crm-kpi-link { text-decoration: none; color: inherit; display: grid; gap: .1rem; transition: border-color .12s ease, box-shadow .12s ease; }
.crm-kpi-link:hover { border-color: var(--crm-border); box-shadow: 0 1px 4px rgba(23, 32, 42, .07); }
.crm-kpi-link .kpi-sub { color: var(--crm-text-muted); font-size: .72rem; font-weight: 700; }
.crm-kpi-link.is-critical .kpi-num, .crm-kpi-link.is-critical .kpi-sub { color: var(--crm-danger); }

/* ==== Board-hode og kolonner (§8) ==== */
.crm-board-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.1rem; }
.kanban-col { background: var(--crm-surface-muted); border-color: var(--crm-border); border-radius: 10px; padding: 8px; }
.kanban-col-head { position: sticky; top: 0; z-index: 2; background: var(--crm-surface-muted); border-bottom: 1px solid var(--crm-border); padding: .45rem .45rem .5rem; }
.kanban-col-head h2 { font-size: .84rem; }
.kanban-col-value { color: var(--crm-text-muted); font-size: .72rem; font-weight: 800; font-variant-numeric: tabular-nums; }
.kanban-add { display: inline-grid; place-items: center; width: 26px; height: 26px; margin-left: .45rem; border: 1px solid var(--crm-border); border-radius: .45rem; background: var(--crm-surface); color: var(--crm-text); font-weight: 900; text-decoration: none; line-height: 1; }
.kanban-add:hover { background: var(--crm-primary-soft); }

/* ==== Deal-kort (§9): tilstander ==== */
.deal-card { background: var(--crm-surface); border: 1px solid var(--crm-border); border-radius: 10px; padding: 10px 12px; font-size: .84rem; }
.deal-card:hover { border-color: #b9c4cf; box-shadow: 0 2px 6px rgba(23, 32, 42, .08); }
.deal-card.is-dragging { opacity: .9; box-shadow: 0 10px 22px rgba(23, 32, 42, .18); transform: rotate(-1deg); }
.kanban-col.is-drop-target { border: 1.5px dashed var(--crm-primary); background: var(--crm-primary-soft); }
.deal-card--is-overdue { border-left: 3px solid var(--crm-danger); }
.deal-card--is-today { border-left: 3px solid var(--crm-warning); }
.deal-next-task { display: flex; align-items: baseline; gap: .25rem; flex-wrap: wrap; }
.deal-next-task b { font-weight: 800; }
.deal-next-task.is-overdue { color: var(--crm-danger); }
.deal-next-task.is-today { color: var(--crm-warning); }
.deal-next-task.is-none { color: var(--crm-text-muted); font-style: italic; font-weight: 600; }

/* ==== Kortmeny (§9) ==== */
.deal-topline { display: flex; align-items: flex-start; justify-content: space-between; gap: .4rem; }
.crm-card-menu { position: relative; flex-shrink: 0; }
.crm-card-menu summary { display: grid; place-items: center; width: 24px; height: 24px; border-radius: .4rem; cursor: pointer; list-style: none; color: var(--crm-text-muted); font-weight: 900; }
.crm-card-menu summary::-webkit-details-marker { display: none; }
.crm-card-menu summary:hover { background: var(--crm-surface-muted); color: var(--crm-text); }
.crm-card-menu-body { position: absolute; right: 0; top: 26px; z-index: 20; min-width: 190px; padding: .4rem; border: 1px solid var(--crm-border); border-radius: .55rem; background: var(--crm-surface); box-shadow: 0 8px 22px rgba(23, 32, 42, .14); display: grid; gap: .15rem; }
.crm-card-menu-body a { padding: .35rem .5rem; border-radius: .4rem; color: var(--crm-text); font-size: .8rem; font-weight: 700; text-decoration: none; }
.crm-card-menu-body a:hover { background: var(--crm-surface-muted); }
.crm-card-menu-body hr { border: 0; border-top: 1px solid var(--crm-border); margin: .25rem 0; }
.crm-card-close { display: grid; gap: .25rem; padding: .35rem .5rem .15rem; }
.crm-card-close label { display: grid; gap: .15rem; color: var(--crm-text-muted); font-size: .68rem; font-weight: 800; }
.crm-card-close input { padding: .3rem .4rem; border: 1px solid var(--crm-border); border-radius: .4rem; font: inherit; font-size: .78rem; }
.crm-card-close button { padding: .35rem .5rem; border: 0; border-radius: .4rem; font: inherit; font-size: .74rem; font-weight: 800; cursor: pointer; background: var(--crm-surface-muted); }
.crm-card-close button.is-won { background: #e3f3ea; color: var(--crm-success); }
.crm-card-close button.is-lost { background: #fbe9eb; color: var(--crm-danger); }

/* ==== Toast med Angre (§10/§21) ==== */
.crm-toast-stack { position: fixed; right: 16px; bottom: 16px; z-index: 200; display: grid; gap: .5rem; max-width: 340px; }
.crm-toast { display: flex; align-items: center; justify-content: space-between; gap: .8rem; padding: .65rem .9rem; border: 1px solid var(--crm-border); border-left: 3px solid var(--crm-success); border-radius: .55rem; background: var(--crm-surface); box-shadow: 0 8px 22px rgba(23, 32, 42, .16); font-size: .82rem; font-weight: 700; }
.crm-toast.is-error { border-left-color: var(--crm-danger); }
.crm-toast .crm-toast-undo { border: 0; background: none; padding: 0; font: inherit; font-weight: 900; color: var(--crm-info); text-decoration: underline; cursor: pointer; }

/* ==== Annet (§13/§14/§17) ==== */
.crm-pick-note { margin: 0 0 .9rem; padding: .6rem .9rem; border: 1px solid var(--crm-border); border-left: 3px solid var(--crm-info); border-radius: .55rem; background: var(--crm-surface); font-size: .82rem; font-weight: 700; }
.crm-notice { margin: 0 0 1rem; padding: .6rem .9rem; border: 1px solid var(--crm-border); border-left: 3px solid var(--crm-success); border-radius: .55rem; background: var(--crm-surface); font-size: .84rem; font-weight: 700; }
.crm-kpis { gap: 12px; }
.crm-kpis .kpi { min-height: 80px; padding: 12px 16px; border-color: var(--crm-border); border-radius: 10px; }
.crm-kpis .kpi-num { font-size: 20px; font-weight: 700; }
