/* =========================================================
   Nordvik Anlegg — porteføljeprosjekt av NordPair
   ========================================================= */

/* ---------- TOKENS ---------- */
:root {
  --orange: #ef7b1f;
  --orange-dark: #d96b14;
  --ink: #181818;
  --slate: #5a5d63;
  --line: #e5e6e8;
  --paper: #ffffff;
  --bg: #fafafa;
  --bg-band: #181818;

  --font: 'Inter', -apple-system, 'Segoe UI', Roboto, system-ui, sans-serif;
  --maxw: 1320px;
  --ease: cubic-bezier(.2, .65, .25, 1);
}

* { box-sizing: border-box; }
*::selection { background: var(--orange); color: #fff; }

html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.5;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img, svg { display: block; max-width: 100%; }

/* Ankerlenker (#tjenester osv.) hopper ikke under den faste headeren */
[id] { scroll-margin-top: 104px; }

.skip {
  position: absolute; left: -10000px; top: 0;
  background: var(--ink); color: #fff; padding: 10px 16px;
}
.skip:focus { left: 16px; top: 16px; z-index: 1000; }

.container {
  width: 100%; max-width: var(--maxw);
  margin: 0 auto; padding: 0 32px;
}

/* ---------- TYPOGRAPHY ---------- */
h1, h2, h3, h4 {
  font-family: var(--font);
  margin: 0;
  letter-spacing: -.025em;
  line-height: 1.05;
  font-weight: 800;
}

.eyebrow {
  display: inline-flex; align-items: center; gap: 16px;
  font-size: .82rem;
  font-weight: 600;
  letter-spacing: .12em;
  color: var(--ink);
  margin: 0 0 24px;
  text-transform: uppercase;
}
.eyebrow-dash {
  display: inline-block;
  width: 36px; height: 2px;
  background: var(--orange);
}
.eyebrow-light { color: rgba(255, 255, 255, .9); }
.eyebrow-dash-light { background: var(--orange); }

/* ---------- BUTTONS ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 13px 24px;
  font-family: var(--font); font-weight: 700; font-size: .85rem;
  letter-spacing: .08em; text-transform: uppercase;
  border: 2px solid transparent;
  cursor: pointer;
  transition: background .2s var(--ease), color .2s var(--ease),
              border-color .2s var(--ease), transform .15s var(--ease);
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn svg { width: 16px; height: 16px; }

.btn-primary {
  background: var(--orange);
  color: #fff;
  border-color: var(--orange);
}
.btn-primary:hover { background: var(--orange-dark); border-color: var(--orange-dark); }

.btn-outline {
  background: transparent;
  color: var(--ink);
  border-color: var(--ink);
}
.btn-outline:hover { background: var(--ink); color: #fff; }

.btn-outline-light {
  background: transparent;
  color: #fff;
  border-color: rgba(255, 255, 255, .3);
}
.btn-outline-light:hover { background: #fff; color: var(--ink); border-color: #fff; }

.btn-dark {
  background: var(--ink);
  color: #fff;
  border-color: var(--ink);
}
.btn-dark:hover { background: #000; }

.btn-lg { padding: 16px 32px; font-size: .9rem; }

/* ---------- HEADER ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, .96);
  backdrop-filter: saturate(140%) blur(10px);
  -webkit-backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex; align-items: center; gap: 32px;
  height: 88px;
}

.brand {
  display: inline-flex; align-items: center; gap: 12px;
  flex-shrink: 0;
}
.brand-mark { display: inline-block; }
.brand-mark svg { width: 42px; height: 42px; }
.brand-text {
  display: flex; flex-direction: column;
  line-height: 1; gap: 2px;
}
.brand-name {
  font-family: var(--font);
  font-weight: 800;
  font-size: 1.15rem;
  letter-spacing: -.01em;
  color: var(--ink);
}
.brand-sub {
  font-family: var(--font);
  font-weight: 600;
  font-size: .8rem;
  letter-spacing: .15em;
  color: var(--slate);
}

.site-nav { margin: 0 auto; }
.site-nav > ul {
  list-style: none; padding: 0; margin: 0;
  display: flex; gap: 36px;
}
.site-nav > ul > li { position: relative; }
.site-nav a {
  display: inline-flex; align-items: center; gap: 6px;
  font-weight: 600; font-size: .82rem;
  letter-spacing: .08em; text-transform: uppercase;
  color: var(--ink);
  padding: 32px 0;
  position: relative;
  transition: color .2s var(--ease);
}
.site-nav a:hover { color: var(--orange); }
.caret { width: 10px; height: 10px; }
.has-sub .sub {
  position: absolute; top: 100%; left: -16px;
  list-style: none; padding: 8px 0; margin: 0;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 4px;
  min-width: 200px;
  box-shadow: 0 12px 24px -8px rgba(0, 0, 0, .12);
  opacity: 0; visibility: hidden;
  transform: translateY(-4px);
  transition: opacity .2s var(--ease), visibility .2s var(--ease), transform .2s var(--ease);
}
.has-sub:hover .sub,
.has-sub:focus-within .sub {
  opacity: 1; visibility: visible; transform: translateY(0);
}
.sub a {
  padding: 10px 18px; font-size: .76rem;
  text-transform: uppercase; letter-spacing: .08em;
  color: var(--ink);
  display: block; line-height: 1.4;
}
.sub a:hover { background: var(--bg); color: var(--orange); }

.header-cta { flex-shrink: 0; }

.nav-toggle {
  display: none;
  width: 40px; height: 40px;
  border: 0; background: transparent;
  cursor: pointer;
  flex-direction: column; justify-content: center; align-items: center;
  gap: 5px;
}
.nav-toggle span {
  display: block; width: 22px; height: 2px;
  background: var(--ink); border-radius: 2px;
  transition: transform .2s var(--ease), opacity .2s var(--ease);
}

.mobile-nav {
  position: absolute; top: 100%; left: 0; right: 0;
  background: #fff;
  border-bottom: 1px solid var(--line);
  padding: 16px 32px 32px;
}
.mobile-nav nav { display: flex; flex-direction: column; gap: 4px; }
.mobile-nav a {
  padding: 14px 0;
  font-weight: 600; font-size: .9rem;
  text-transform: uppercase; letter-spacing: .08em;
  color: var(--ink);
  border-bottom: 1px solid var(--line);
}
.mobile-nav a.btn {
  border: 2px solid var(--orange); margin-top: 14px;
  justify-content: center;
}

/* ---------- HERO ---------- */
.hero {
  position: relative;
  min-height: clamp(560px, 78vh, 760px);
  overflow: hidden;
  background: #efefef;
}
.hero-image {
  position: absolute;
  top: 0; right: 0; bottom: 0;
  width: 62%;
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
}
.hero-fade {
  position: absolute; inset: 0;
  background: linear-gradient(
    to right,
    #ffffff 0%,
    #ffffff 38%,
    rgba(255, 255, 255, .85) 48%,
    rgba(255, 255, 255, .3) 58%,
    rgba(255, 255, 255, 0) 68%
  );
}
.hero-inner {
  position: relative;
  height: 100%;
  display: flex; align-items: center;
  min-height: clamp(560px, 78vh, 760px);
}
.hero-copy {
  max-width: 620px;
  padding: 80px 0;
}
.hero-copy h1 {
  font-size: clamp(2.4rem, 5.6vw, 4.5rem);
  font-weight: 900;
  letter-spacing: -.03em;
  line-height: .98;
  margin-bottom: 32px;
}
.hero-lead {
  font-size: 1.05rem;
  line-height: 1.65;
  color: var(--slate);
  max-width: 520px;
  margin-bottom: 40px;
}
.hero-cta {
  display: flex; gap: 14px; flex-wrap: wrap;
}

/* ---------- TRUSTBAR (godkjenninger) ---------- */
.trustbar {
  background: #fff;
  border-bottom: 1px solid var(--line);
  padding: 22px 0;
}
.trustbar-inner {
  display: flex; align-items: center;
  gap: 28px; flex-wrap: wrap;
}
.trustbar-lbl {
  font-size: .72rem; font-weight: 700;
  letter-spacing: .14em; text-transform: uppercase;
  color: var(--slate);
  flex-shrink: 0;
}
.trustbar-list {
  list-style: none; margin: 0; padding: 0;
  display: flex; flex-wrap: wrap; gap: 10px 12px;
}
.trustbar-list li {
  font-size: .76rem; font-weight: 600;
  letter-spacing: .04em; text-transform: uppercase;
  color: var(--ink);
  border: 1px solid var(--line);
  padding: 7px 14px; border-radius: 2px;
}

/* ---------- SERVICES ROW ---------- */
.services-row {
  background: var(--bg);
  padding: clamp(48px, 6vw, 72px) 0;
  border-bottom: 1px solid var(--line);
}
.services-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}
.srv {
  padding: 0 36px;
  border-left: 1px solid var(--line);
}
.srv:first-child { border-left: 0; padding-left: 0; }
.srv:last-child { padding-right: 0; }
.srv-ic {
  width: clamp(72px, 9vw, 110px);
  height: clamp(72px, 9vw, 110px);
  margin-bottom: 20px;
  display: grid;
  place-items: center;
}
.srv-ic svg { width: 44px; height: 44px; color: var(--orange); }
.srv-ic img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}
.srv h3 {
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -.012em;
  margin-bottom: 12px;
}
.srv p {
  color: var(--slate);
  font-size: .94rem;
  line-height: 1.6;
  margin: 0;
}

/* ---------- STATS ---------- */
.stats {
  background: #fff;
  padding: clamp(56px, 7vw, 90px) 0;
  border-bottom: 1px solid var(--line);
}
.stats-grid {
  list-style: none; padding: 0; margin: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
}
.stats-grid li { text-align: left; }
.stats-grid strong {
  display: block;
  font-family: var(--font);
  font-weight: 900;
  font-size: clamp(2.8rem, 5.5vw, 4rem);
  letter-spacing: -.03em;
  line-height: .95;
  color: var(--ink);
  margin-bottom: 12px;
}
.stats-grid strong span {
  color: var(--orange);
  margin-left: 2px;
}
.stats-lbl {
  font-size: .9rem;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--slate);
}

/* ---------- DEEP (about + pillars) ---------- */
.deep {
  background: #fff;
  padding: clamp(60px, 8vw, 110px) 0;
}
.deep-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(40px, 6vw, 80px);
  align-items: start;
}
.deep-copy h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 800;
  letter-spacing: -.025em;
  line-height: 1.05;
  margin-bottom: 28px;
}
.deep-copy p {
  color: var(--slate);
  line-height: 1.7;
  margin: 0 0 18px;
  font-size: 1rem;
}
.deep-copy .btn { margin-top: 12px; }

.deep-pillars {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px 28px;
}
.pillar {
  padding-top: 24px;
  border-top: 2px solid var(--ink);
}
.pillar-num {
  display: block;
  font-weight: 700;
  font-size: .82rem;
  letter-spacing: .12em;
  color: var(--orange);
  margin-bottom: 12px;
}
.pillar h4 {
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: -.012em;
  margin-bottom: 8px;
}
.pillar p {
  color: var(--slate);
  font-size: .92rem;
  line-height: 1.55;
  margin: 0;
}

/* ---------- PROJECTS ---------- */
.projects {
  background: var(--bg);
  padding: clamp(60px, 8vw, 110px) 0;
}
.section-head { margin-bottom: clamp(36px, 5vw, 56px); }
.section-head-row {
  display: flex; justify-content: space-between; align-items: end;
  gap: 32px;
}
.section-head h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 800;
  letter-spacing: -.025em;
  line-height: 1;
}
.link-arrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-weight: 700; font-size: .82rem;
  letter-spacing: .1em; text-transform: uppercase;
  color: var(--ink);
  border-bottom: 2px solid var(--orange);
  padding-bottom: 4px;
  transition: gap .2s var(--ease);
}
.link-arrow:hover { gap: 14px; color: var(--orange); }
.link-arrow svg { width: 16px; height: 16px; }

.proj-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.proj {
  background: #fff;
  border: 1px solid var(--line);
  overflow: hidden;
  transition: transform .25s var(--ease), box-shadow .25s var(--ease);
}
.proj:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 40px -20px rgba(0, 0, 0, .15);
}

/* Project media — bilder */
.proj-media {
  aspect-ratio: 16 / 10;
  position: relative;
  overflow: hidden;
  background: #2a2a2a;
}
.proj-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .4s var(--ease);
}
.proj:hover .proj-media img {
  transform: scale(1.04);
}

.proj-tag {
  position: absolute; top: 18px; left: 18px;
  background: var(--orange);
  color: #fff;
  font-weight: 700;
  font-size: .68rem;
  letter-spacing: .1em;
  padding: 6px 12px;
  z-index: 1;
}
.proj-body { padding: 24px 26px 28px; }
.proj-body h3 {
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -.015em;
  margin-bottom: 10px;
}
.proj-body p {
  color: var(--slate);
  font-size: .92rem;
  line-height: 1.55;
  margin: 0 0 16px;
}
.proj-meta {
  font-size: .8rem;
  font-weight: 600;
  letter-spacing: .04em;
  color: var(--slate);
  text-transform: uppercase;
}

/* ---------- CTA BAND ---------- */
.cta-band {
  background: var(--bg-band);
  color: #fff;
  padding: clamp(56px, 7vw, 90px) 0;
}
.cta-inner {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 48px;
  align-items: center;
}
.cta-copy h2 {
  font-size: clamp(1.8rem, 3.6vw, 2.6rem);
  font-weight: 800;
  letter-spacing: -.025em;
  line-height: 1.05;
  color: #fff;
  margin-bottom: 16px;
}
.cta-copy p {
  color: rgba(255, 255, 255, .7);
  font-size: 1rem;
  line-height: 1.6;
  margin: 0;
  max-width: 50ch;
}
.cta-actions {
  display: flex; flex-direction: column; gap: 12px;
}

/* ---------- FOOTER ---------- */
.site-footer {
  background: #0d0d0d;
  color: #fff;
  padding: clamp(56px, 7vw, 80px) 0 0;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
  padding-bottom: 56px;
}
.footer-brand .brand-mark svg { width: 42px; height: 42px; }
.brand-name-light { color: #fff; }
.brand-sub-light { color: rgba(255, 255, 255, .5); }
.footer-brand p {
  color: rgba(255, 255, 255, .55);
  font-size: .92rem;
  line-height: 1.6;
  margin: 18px 0 0;
  max-width: 32ch;
}
.footer-col h4 {
  font-weight: 700;
  font-size: .76rem;
  letter-spacing: .14em;
  color: rgba(255, 255, 255, .5);
  margin-bottom: 18px;
}
.footer-col a, .footer-col .addr {
  display: block;
  color: rgba(255, 255, 255, .85);
  font-size: .92rem;
  margin-bottom: 12px;
  transition: color .2s var(--ease);
}
.footer-col a:hover { color: var(--orange); }
.addr { color: rgba(255, 255, 255, .6); font-size: .88rem; }

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, .1);
  padding: 24px 32px;
  display: flex; justify-content: space-between;
  font-size: .82rem;
  color: rgba(255, 255, 255, .5);
}
.footer-bottom .credit a {
  color: rgba(255, 255, 255, .85);
  border-bottom: 1px solid var(--orange);
}
.footer-bottom .credit a:hover { color: var(--orange); }

/* ---------- RESPONSIVE ---------- */
@media (max-width: 1100px) {
  .site-nav > ul { gap: 22px; }
  .site-nav a { font-size: .76rem; padding: 32px 0; }
  .container { padding: 0 24px; }
}
@media (max-width: 920px) {
  .site-nav, .header-cta { display: none; }
  .nav-toggle { display: inline-flex; margin-left: auto; }
  .hero-image { width: 100%; }
  .hero-fade {
    background: linear-gradient(
      to bottom,
      rgba(255, 255, 255, .95) 0%,
      rgba(255, 255, 255, .92) 55%,
      rgba(255, 255, 255, .78) 100%
    );
  }
  .hero-copy { max-width: 100%; }
  .services-grid { grid-template-columns: 1fr 1fr; gap: 36px 0; }
  .srv { padding: 0 24px; border-left: 1px solid var(--line); }
  .srv:nth-child(2n+1) { border-left: 0; padding-left: 0; }
  .stats-grid { grid-template-columns: 1fr 1fr; gap: 36px 24px; }
  .deep-grid { grid-template-columns: 1fr; }
  .proj-grid { grid-template-columns: 1fr 1fr; }
  .cta-inner { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 600px) {
  .header-inner { height: 72px; }
  .brand-mark svg { width: 36px; height: 36px; }
  .brand-name { font-size: 1rem; }
  .brand-sub { font-size: .7rem; }
  [id] { scroll-margin-top: 84px; }
  /* Mobil-hero: tekst på rent hvitt, bildet som skarpt bånd under */
  .hero { min-height: 0; display: flex; flex-direction: column; background: #fff; }
  .hero-fade { display: none; }
  .hero-inner { order: 1; min-height: 0; align-items: flex-start; }
  .hero-copy { padding: 36px 0 28px; max-width: 100%; }
  .hero-image {
    order: 2; position: relative; inset: auto;
    width: 100%; height: 240px;
  }
  .trustbar-inner { gap: 14px; }
  .trustbar-list { gap: 8px; }
  .services-grid { grid-template-columns: 1fr; }
  .srv { border-left: 0; padding: 0; padding-bottom: 28px; border-bottom: 1px solid var(--line); }
  .srv:last-child { border-bottom: 0; padding-bottom: 0; }
  .stats-grid { grid-template-columns: 1fr; }
  .deep-pillars { grid-template-columns: 1fr; }
  .proj-grid { grid-template-columns: 1fr; }
  .section-head-row { flex-direction: column; align-items: flex-start; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; gap: 8px; align-items: flex-start; }
  .hero-cta .btn, .cta-actions .btn { width: 100%; justify-content: center; }
}