/* ============================================
   Oslo Byggdrift AS (built from the business-classic mold by Agentas)
   Colours from the logo: teal #4daaa7, deep teal #3f8f8b, charcoal #333333.
   The whole skin lives in :root.
   ============================================ */

:root {
    /* Brand */
    --teal-50: #eef6f5;
    --teal-200: #bfe3e1;
    --teal-300: #8fd3cf;
    --teal-400: #4daaa7;
    --teal-500: #3f8f8b;
    --teal-700: #276b67;
    --teal-800: #1d5450;
    --charcoal: #333333;
    --night-900: #142020;
    --night-800: #1a2e2d;
    --night-700: #1f4b48;

    /* Roles */
    --bg: #ffffff;
    --surface: #ffffff;
    --text: #1c2626;
    --text-muted: #4a5a59;
    --line: #dae6e5;
    --field-line: #7a9290;
    --field-bg: #f7fafa;
    --link: var(--teal-700);
    --focus: var(--teal-700);
    --on-dark: #ffffff;
    --on-dark-muted: #c6dbd9;
    --on-dark-accent: var(--teal-300);
    --btn-text: #0e2221;
    --btn-grad: linear-gradient(180deg, #6fc8c3, var(--teal-400));
    --btn-grad-hover: linear-gradient(180deg, #84d3ce, #5cb8b4);

    /* Type */
    --font-head: 'Saira', 'Barlow', system-ui, -apple-system, 'Segoe UI', sans-serif;
    --font-body: 'Barlow', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
    --fs-sm: 1rem;
    --fs-base: 1.125rem;
    --fs-lg: 1.3125rem;
    --fs-2xl: clamp(1.875rem, 1.45rem + 1.5vw, 2.5rem);
    --fs-3xl: clamp(2.25rem, 1.6rem + 2.4vw, 3.25rem);

    /* Space */
    --s-1: 4px;
    --s-2: 8px;
    --s-3: 12px;
    --s-4: 16px;
    --s-5: 24px;
    --s-6: 32px;
    --s-7: 48px;
    --s-8: 64px;
    --s-9: 96px;

    /* Shape */
    --r-sm: 10px;
    --r-md: 18px;
    --r-lg: 24px;
    --r-full: 999px;
    --shadow-card: 0 2px 6px rgb(20 32 32 / .05), 0 14px 36px rgb(20 32 32 / .09);
    --shadow-photo: 0 18px 44px rgb(0 0 0 / .34);
    --max-width: 1200px;
    --header-h: 76px;
}

/* Reset */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--header-h) + 12px);
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-body);
    font-size: var(--fs-base);
    line-height: 1.6;
    color: var(--text);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
}

/* Room for the fixed preview bar while it is there (production strips the bar) */
body:has(.agp-preview) { padding-bottom: 40px; }

img { max-width: 100%; display: block; }
a { color: var(--link); text-underline-offset: 3px; }

h1, h2, h3 {
    font-family: var(--font-head);
    line-height: 1.15;
    text-wrap: balance;
}

p { text-wrap: pretty; }

.nowrap { white-space: nowrap; }

:focus-visible {
    outline: 3px solid var(--focus);
    outline-offset: 3px;
    border-radius: 6px;
}

.on-dark :focus-visible { outline-color: var(--teal-300); }

.icon {
    width: 24px;
    height: 24px;
    flex: none;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.container {
    max-width: var(--max-width);
    margin-inline: auto;
    padding-inline: var(--s-5);
}

.skip-link {
    position: absolute;
    left: var(--s-4);
    top: -100px;
    z-index: 200;
    padding: var(--s-2) var(--s-4);
    background: var(--surface);
    color: var(--text);
    font-weight: 700;
    border-radius: var(--r-sm);
    box-shadow: var(--shadow-card);
}

.skip-link:focus { top: var(--s-4); }

/* ---- Header ---- */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgb(255 255 255 / .97);
    border-bottom: 1px solid var(--line);
    transition: box-shadow .25s ease;
}

.site-header.scrolled { box-shadow: 0 4px 18px rgb(20 32 32 / .08); }

.nav-container {
    max-width: var(--max-width);
    margin-inline: auto;
    padding-inline: var(--s-5);
    height: var(--header-h);
    display: flex;
    align-items: center;
    gap: var(--s-3);
}

.nav-logo {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    margin-right: auto;
    text-decoration: none;
    border-radius: var(--r-sm);
}

.nav-logo img { height: 46px; width: auto; }

.logo-text {
    font-family: var(--font-head);
    font-weight: 700;
    font-size: 1.3rem;
    letter-spacing: .06em;
    text-transform: uppercase;
    color: var(--charcoal);
    line-height: 1;
    white-space: nowrap;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: var(--s-1);
}

.nav-links > a:not(.btn) {
    padding: 8px 12px;
    font-weight: 600;
    font-size: 1.0625rem;
    color: var(--text);
    text-decoration: none;
    border-radius: var(--r-sm);
}

.nav-links > a:not(.btn):hover {
    color: var(--teal-700);
    text-decoration: underline;
    text-decoration-color: var(--teal-400);
    text-decoration-thickness: 3px;
    text-underline-offset: 8px;
}

.nav-call { margin-left: var(--s-3); }

.nav-call-mobile,
.nav-hamburger { display: none; }

/* ---- Buttons ---- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 48px;
    padding: 11px 22px;
    border: 1px solid transparent;
    border-radius: var(--r-full);
    font-family: var(--font-body);
    font-size: 1.0625rem;
    font-weight: 700;
    line-height: 1.2;
    text-decoration: none;
    white-space: nowrap;
    cursor: pointer;
    transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}

.btn .icon { width: 20px; height: 20px; }

.btn-lg {
    min-height: 56px;
    padding: 14px 30px;
    font-size: 1.125rem;
}

.btn-primary {
    background: var(--btn-grad);
    color: var(--btn-text);
    border-color: var(--teal-500);
    box-shadow: 0 6px 18px rgb(77 170 167 / .35);
}

.btn-primary:hover {
    background: var(--btn-grad-hover);
    transform: translateY(-1px);
    box-shadow: 0 10px 24px rgb(77 170 167 / .42);
}

.btn-secondary {
    background: transparent;
    color: var(--text);
    border-color: var(--teal-700);
}

.btn-secondary:hover { background: rgb(77 170 167 / .12); }

.on-dark .btn-secondary {
    color: var(--on-dark);
    border-color: rgb(255 255 255 / .6);
}

.on-dark .btn-secondary:hover { background: rgb(255 255 255 / .1); }

.btn-full { width: 100%; }

/* ---- Hero ---- */
.hero {
    position: relative;
    overflow: hidden;
    color: var(--on-dark);
    padding-block: var(--s-8) calc(var(--s-8) + var(--s-2));
    background:
        radial-gradient(620px 480px at 78% 52%, rgb(77 170 167 / .30), transparent 65%),
        radial-gradient(900px 600px at 0% 0%, rgb(63 143 139 / .16), transparent 60%),
        linear-gradient(155deg, var(--night-900) 0%, var(--night-800) 45%, var(--night-700) 100%);
}

.hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
    gap: var(--s-8);
    align-items: center;
}

.eyebrow {
    font-size: var(--fs-sm);
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--on-dark-accent);
    margin-bottom: var(--s-4);
}

.hero h1 {
    font-size: var(--fs-3xl);
    font-weight: 700;
    letter-spacing: -0.005em;
}

.lead {
    margin-top: var(--s-5);
    max-width: 34em;
    font-size: 1.25rem;
    line-height: 1.6;
    color: var(--on-dark-muted);
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: var(--s-3);
    margin-top: var(--s-6);
}

.hero-photos {
    position: relative;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--s-4);
    padding-bottom: 28px;
}

.hero-photos img {
    width: 100%;
    height: auto;
    aspect-ratio: 1;
    object-fit: cover;
    border-radius: var(--r-md);
    box-shadow: var(--shadow-photo);
    outline: 1px solid rgb(255 255 255 / .08);
    outline-offset: -1px;
}

.hero-photos img:nth-child(even) { transform: translateY(28px); }

/* ---- Sections ---- */
.section {
    padding-block: var(--s-9);
    background: linear-gradient(180deg, #ffffff 0%, #f6faf9 100%);
}

.section--alt { background: linear-gradient(180deg, #f0f7f6 0%, #e5f0ef 100%); }

.section-head { margin-bottom: var(--s-7); }

.section-label {
    font-size: var(--fs-sm);
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--teal-700);
    margin-bottom: var(--s-3);
}

.section h2 {
    font-size: var(--fs-2xl);
    font-weight: 700;
    letter-spacing: -0.005em;
}

.section-head p:not(.section-label) {
    margin-top: var(--s-4);
    max-width: 44rem;
    font-size: 1.1875rem;
    color: var(--text-muted);
}

/* ---- Cards ---- */
.cards {
    list-style: none;
    display: grid;
    gap: var(--s-5);
}

.cards--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }

.card {
    background: var(--surface);
    border-radius: var(--r-md);
    padding: var(--s-6);
    box-shadow: var(--shadow-card);
}

.card--row {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: var(--s-5);
    align-items: start;
}

.card-icon {
    display: grid;
    place-items: center;
    width: 60px;
    height: 60px;
    border-radius: 16px;
    background: linear-gradient(135deg, #e4f4f3, var(--teal-200));
    color: var(--teal-800);
}

.card-icon .icon { width: 30px; height: 30px; }

.card h3 {
    font-size: var(--fs-lg);
    font-weight: 700;
    margin-top: 2px;
}

.card p {
    margin-top: var(--s-2);
    color: var(--text-muted);
}

/* ---- Steps ---- */
.steps {
    position: relative;
    list-style: none;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: var(--s-6);
    counter-reset: step;
}

.steps::before {
    content: "";
    position: absolute;
    top: 27px;
    left: 27px;
    right: calc((100% - 2 * var(--s-6)) / 3 - 27px);
    border-top: 3px dashed var(--teal-400);
}

.steps li {
    position: relative;
    counter-increment: step;
}

.steps li::before {
    content: counter(step);
    position: relative;
    display: grid;
    place-items: center;
    width: 54px;
    height: 54px;
    margin-bottom: var(--s-5);
    border-radius: 50%;
    background: linear-gradient(135deg, var(--night-800), var(--teal-700));
    color: #ffffff;
    font-family: var(--font-head);
    font-size: 1.375rem;
    font-weight: 700;
    box-shadow: 0 0 0 8px #ffffff, 0 8px 18px rgb(20 32 32 / .22);
}

.steps h3 {
    font-size: var(--fs-lg);
    font-weight: 700;
}

.steps p {
    margin-top: var(--s-2);
    color: var(--text-muted);
    max-width: 22em;
}

/* ---- Contact ---- */
.contact {
    color: var(--on-dark);
    background:
        radial-gradient(700px 420px at 10% 15%, rgb(77 170 167 / .22), transparent 60%),
        linear-gradient(160deg, var(--night-900), var(--night-700));
}

.contact .section-label { color: var(--on-dark-accent); }

.contact-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: var(--s-8);
    align-items: start;
}

.contact-info > p:not(.section-label) {
    margin-top: var(--s-4);
    max-width: 30em;
    font-size: 1.1875rem;
    color: var(--on-dark-muted);
}

.contact-phone {
    display: inline-flex;
    align-items: center;
    gap: var(--s-4);
    margin-top: var(--s-6);
    padding: 14px 30px 14px 22px;
    border: 1px solid var(--teal-500);
    border-radius: var(--r-md);
    background: var(--btn-grad);
    color: var(--btn-text);
    text-decoration: none;
    box-shadow: 0 10px 26px rgb(77 170 167 / .30);
    transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}

.contact-phone:hover {
    background: var(--btn-grad-hover);
    transform: translateY(-1px);
}

.contact-phone .icon { width: 30px; height: 30px; }

.contact-phone-label {
    display: block;
    font-size: .9375rem;
    font-weight: 600;
}

.contact-phone-num {
    display: block;
    font-family: var(--font-head);
    font-size: 1.75rem;
    font-weight: 700;
    line-height: 1.1;
    font-variant-numeric: tabular-nums;
}

.contact-details {
    list-style: none;
    margin-top: var(--s-6);
    display: grid;
    gap: var(--s-4);
}

.contact-details li {
    display: flex;
    align-items: flex-start;
    gap: var(--s-4);
}

.contact-details .icon {
    color: var(--on-dark-accent);
    margin-top: 4px;
}

.contact-label {
    display: block;
    font-size: .9375rem;
    font-weight: 600;
    color: var(--on-dark-muted);
}

.contact-details a {
    color: var(--on-dark);
    font-weight: 600;
    overflow-wrap: anywhere;
}

.contact-form-wrap {
    background: var(--surface);
    color: var(--text);
    border-radius: var(--r-lg);
    padding: var(--s-7);
    box-shadow: 0 24px 60px rgb(0 0 0 / .30);
}

.contact-form-wrap :focus-visible { outline-color: var(--focus); }

.form-group { margin-bottom: var(--s-5); }

.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: var(--s-2);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 13px 16px;
    font: inherit;
    font-size: 1.0625rem;
    color: var(--text);
    background: var(--field-bg);
    border: 1px solid var(--field-line);
    border-radius: var(--r-sm);
}

.form-group input:focus-visible,
.form-group textarea:focus-visible {
    outline-offset: 1px;
    border-color: var(--teal-700);
    background: #ffffff;
}

.form-group textarea {
    resize: vertical;
    min-height: 140px;
}

.form-status {
    margin-top: var(--s-4);
    padding: 14px 16px;
    border-left: 4px solid var(--teal-500);
    border-radius: var(--r-sm);
    background: var(--teal-50);
    color: var(--text);
    font-weight: 600;
    line-height: 1.5;
}

.form-status:empty { display: none; }

.form-note {
    margin-top: var(--s-4);
    text-align: center;
    font-size: var(--fs-sm);
    color: var(--text-muted);
}

/* ---- Footer ---- */
.site-footer {
    background: #f0f6f5;
    border-top: 1px solid var(--line);
    padding-block: var(--s-7) var(--s-6);
    font-size: var(--fs-sm);
    color: var(--text-muted);
}

.footer-inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: var(--s-5);
}

.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
}

.footer-brand img { height: 40px; width: auto; }
.footer-brand .logo-text { font-size: 1.15rem; }

.footer-legal {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 6px 24px;
}

.footer-legal a {
    color: var(--text);
    font-weight: 600;
}

.footer-bottom {
    margin-top: var(--s-5);
    padding-top: var(--s-5);
    border-top: 1px solid var(--line);
}

.footer-bottom p { font-size: .9375rem; }

/* ---- Responsive ---- */
@media (max-width: 1080px) {
    .nav-call-mobile {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 46px;
        height: 46px;
        border: 1px solid var(--teal-500);
        border-radius: 50%;
        background: var(--btn-grad);
        color: var(--btn-text);
    }

    .nav-call-mobile .icon { width: 21px; height: 21px; }

    .nav-hamburger {
        position: relative;
        z-index: 110;
        display: inline-flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 5px;
        width: 46px;
        height: 46px;
        background: transparent;
        border: 1px solid var(--field-line);
        border-radius: var(--r-sm);
        cursor: pointer;
    }

    .nav-hamburger span {
        display: block;
        width: 22px;
        height: 2px;
        background: var(--text);
        border-radius: 2px;
        transition: transform .25s ease, opacity .25s ease;
    }

    .nav-hamburger.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
    .nav-hamburger.active span:nth-child(2) { opacity: 0; }
    .nav-hamburger.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

    .nav-links {
        position: fixed;
        top: 0;
        right: 0;
        bottom: 0;
        z-index: 105;
        width: min(340px, 88vw);
        flex-direction: column;
        align-items: stretch;
        gap: var(--s-1);
        padding: calc(var(--header-h) + var(--s-4)) var(--s-5) var(--s-6);
        background: var(--surface);
        box-shadow: -20px 0 50px rgb(20 32 32 / .18);
        transform: translateX(100%);
        visibility: hidden;
        transition: transform .3s ease, visibility 0s linear .3s;
    }

    .nav-links.open {
        transform: none;
        visibility: visible;
        transition: transform .3s ease;
    }

    .nav-links > a:not(.btn) {
        padding: 12px 10px;
        font-size: 1.25rem;
    }

    .nav-call { margin: var(--s-4) 0 0; }
}

@media (max-width: 1000px) {
    .hero-grid {
        grid-template-columns: minmax(0, 1fr);
        gap: var(--s-7);
    }

    .hero-photos { max-width: 600px; }

    .contact-grid {
        grid-template-columns: minmax(0, 1fr);
        gap: var(--s-7);
    }
}

@media (max-width: 760px) {
    .section { padding-block: var(--s-8); }
    .hero { padding-block: var(--s-7) var(--s-8); }
    .section-head { margin-bottom: var(--s-6); }

    .cards--2 { grid-template-columns: minmax(0, 1fr); }

    .hero-actions .btn { flex: 1 1 100%; }

    .hero-photos { gap: var(--s-3); padding-bottom: 16px; }
    .hero-photos img:nth-child(even) { transform: translateY(16px); }

    /* Steps run down the page: numbers on the left, a dashed line between them */
    .steps {
        grid-template-columns: minmax(0, 1fr);
        gap: var(--s-6);
    }

    .steps::before {
        top: 27px;
        bottom: 27px;
        left: 26px;
        right: auto;
        border-top: 0;
        border-left: 3px dashed var(--teal-400);
    }

    .steps li {
        padding-left: 78px;
        min-height: 54px;
    }

    .steps li::before {
        position: absolute;
        left: 0;
        top: 0;
        margin: 0;
    }

    .contact-phone { width: 100%; }
    .contact-form-wrap { padding: var(--s-6) var(--s-5); }

    .footer-inner {
        flex-direction: column;
        align-items: flex-start;
    }

    .footer-legal {
        flex-direction: column;
        gap: 4px;
    }
}

@media (max-width: 480px) {
    :root { --header-h: 68px; }

    .container,
    .nav-container { padding-inline: var(--s-4); }

    .nav-logo { gap: 9px; }
    .nav-logo img { height: 38px; }
    .logo-text { font-size: 1.05rem; letter-spacing: .04em; }

    .card { padding: var(--s-5); }

    .card--row {
        grid-template-columns: minmax(0, 1fr);
        gap: var(--s-4);
    }

    .card-icon {
        width: 52px;
        height: 52px;
        border-radius: 14px;
    }

    .card-icon .icon { width: 26px; height: 26px; }

    .contact-phone-num { font-size: 1.5rem; }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }

    *, *::before, *::after {
        transition-duration: .01ms !important;
        animation-duration: .01ms !important;
    }
}
