/* Yazdan Bygg — stilark */

@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('../fonts/manrope.woff2') format('woff2');
}
@font-face {
  font-family: 'Instrument Serif';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/instrument-serif.woff2') format('woff2');
}
@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/plex-mono-400.woff2') format('woff2');
}
@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('../fonts/plex-mono-500.woff2') format('woff2');
}

:root {
  --bg: #F7F6F2;
  --ink: #16231C;
  --ink-2: #3C4A41;
  --muted: #4C5B51;
  --muted-2: #5E7466;
  --label: #6E8577;
  --green: #1D4032;
  --green-2: #254B40;
  --green-hover: #2E6650;
  --mint: #EDF1EC;
  --on-dark: #F2F4F0;
  --on-dark-2: #C3D0C6;
  --on-dark-3: #9FB3A6;
  --line: rgba(29, 64, 50, 0.10);
  --serif: 'Instrument Serif', Georgia, serif;
  --sans: 'Manrope', Helvetica, Arial, sans-serif;
  --mono: 'IBM Plex Mono', ui-monospace, monospace;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
a { color: var(--green); text-decoration: none; }
a:hover { color: var(--green-hover); }
h1, h2, h3 { margin: 0; font-weight: 400; font-family: var(--serif); text-wrap: pretty; }
p { margin: 0; }
img { display: block; max-width: 100%; }
figure { margin: 0; }
.icon { width: 1em; height: 1em; flex: none; }

.wrap { max-width: 1200px; margin: 0 auto; padding-left: 24px; padding-right: 24px; }
.eyebrow {
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--label);
}
.section-title { font-size: clamp(34px, 4vw, 50px); line-height: 1.08; margin-top: 14px; }

.skip-link {
  position: absolute; left: -9999px; top: 8px;
  background: var(--green); color: var(--on-dark); padding: 10px 16px; border-radius: 8px; z-index: 100;
}
.skip-link:focus { left: 8px; }
:focus-visible { outline: 2px solid var(--green-hover); outline-offset: 3px; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(247, 246, 242, 0.92);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding-top: 14px; padding-bottom: 14px;
}
.brand { display: flex; align-items: center; gap: 12px; color: var(--ink); }
.brand:hover { color: var(--ink); }
.brand-mark {
  width: 34px; height: 34px; border-radius: 8px;
  background: var(--green); color: var(--on-dark);
  display: flex; align-items: center; justify-content: center; font-size: 16px;
}
.brand-name { font-family: var(--serif); font-size: 22px; letter-spacing: 0.2px; }

.nav { display: flex; align-items: center; gap: 28px; font-size: 15px; font-weight: 500; }
.nav a:not(.btn-call) { color: var(--ink-2); }
.nav a:not(.btn-call):hover { color: var(--green); }
.btn-call {
  display: inline-flex; align-items: center; gap: 9px;
  padding: 11px 20px; border-radius: 999px;
  background: var(--green); color: var(--on-dark); font-weight: 600; white-space: nowrap;
}
.btn-call:hover { background: var(--green-hover); color: var(--on-dark); }
.btn-call .icon { font-size: 13px; }

.menu-toggle {
  display: none;
  width: 44px; height: 44px; border-radius: 10px;
  border: 1px solid rgba(29, 64, 50, 0.22); background: transparent; color: var(--ink);
  align-items: center; justify-content: center; font-size: 20px; cursor: pointer;
}

@media (max-width: 820px) {
  .header-inner { gap: 12px; }
  .menu-toggle { display: inline-flex; }
  .header-actions { display: flex; align-items: center; gap: 10px; }
  .nav {
    display: none;
    position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--bg); border-bottom: 1px solid var(--line);
    padding: 8px 24px 20px;
  }
  .nav.open { display: flex; }
  .nav a:not(.btn-call) { padding: 14px 0; border-bottom: 1px solid var(--line); font-size: 17px; }
  .nav .btn-call { display: none; }
}
@media (min-width: 821px) {
  .header-actions { display: none; }
}
@media (max-width: 380px) {
  .brand-name { font-size: 19px; }
  .header-actions .btn-call { padding: 10px 14px; font-size: 14px; }
}

/* Hero */
.hero { background: var(--green-2); color: var(--on-dark); }
.hero-inner {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr));
  gap: 56px; align-items: center;
  padding-top: 96px; padding-bottom: 104px;
}
.hero-copy { max-width: 560px; }
.pill {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 7px 14px; border-radius: 999px;
  border: 1px solid rgba(242, 244, 240, 0.22);
  font-family: var(--mono); font-size: 11.5px; letter-spacing: 0.14em; text-transform: uppercase;
  color: #B8C9BE;
}
.hero h1 { font-size: clamp(44px, 6vw, 76px); line-height: 1.02; letter-spacing: -0.02em; margin-top: 26px; }
.hero-lead { margin-top: 24px; font-size: 18.5px; line-height: 1.6; color: var(--on-dark-2); max-width: 480px; }
.hero-ctas { margin-top: 38px; display: flex; flex-wrap: wrap; gap: 14px; }
.btn {
  display: inline-flex; align-items: center; gap: 11px;
  padding: 16px 28px; border-radius: 999px; font-size: 16px;
}
.btn-light { background: var(--on-dark); color: var(--ink); font-weight: 700; }
.btn-light:hover { background: #fff; color: var(--ink); }
.btn-ghost { border: 1px solid rgba(242, 244, 240, 0.3); color: var(--on-dark); font-weight: 600; }
.btn-ghost:hover { border-color: var(--on-dark); color: var(--on-dark); }
.btn .icon { font-size: 14px; }

.stats {
  margin-top: 52px; display: grid; grid-template-columns: repeat(auto-fit, minmax(96px, 1fr));
  gap: 28px; border-top: 1px solid rgba(242, 244, 240, 0.16); padding-top: 28px; max-width: 520px;
}
.stat-value { font-family: var(--serif); font-size: 34px; color: var(--on-dark); }
.stat-label { font-size: 13.5px; color: var(--on-dark-3); margin-top: 4px; }

.hero-figure {
  position: relative; border-radius: 16px; overflow: hidden;
  border: 1px solid rgba(242, 244, 240, 0.16);
}
.hero-figure img { width: 100%; height: 100%; min-height: 420px; object-fit: cover; }
.hero-figure figcaption {
  position: absolute; left: 16px; bottom: 16px;
  background: rgba(22, 35, 28, 0.82); color: var(--on-dark);
  padding: 9px 14px; border-radius: 8px;
  font-family: var(--mono); font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase;
}

@media (max-width: 600px) {
  .hero-inner { padding-top: 56px; padding-bottom: 64px; gap: 40px; }
  .hero-figure img { min-height: 300px; }
}

/* Tjenester */
.services { padding-top: 104px; padding-bottom: 104px; }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 32px; flex-wrap: wrap; }
.section-head .section-title { max-width: 620px; }
.section-head > p { max-width: 320px; font-size: 16px; line-height: 1.6; color: var(--muted); }
.cards { margin-top: 56px; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(290px, 100%), 1fr)); gap: 24px; }
.card {
  background: #fff; border: 1px solid var(--line); border-radius: 14px;
  padding: 34px 30px 32px; display: flex; flex-direction: column; gap: 16px;
  transition: border-color 0.15s;
}
.card:hover { border-color: rgba(29, 64, 50, 0.30); }
.card-icon {
  width: 48px; height: 48px; border-radius: 12px; background: var(--mint); color: var(--green);
  display: flex; align-items: center; justify-content: center; font-size: 21px;
}
.card h3 { font-size: 27px; }
.card p { font-size: 15.5px; line-height: 1.65; color: var(--muted); }
.checklist {
  margin: 6px 0 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 9px;
  font-size: 14.5px; color: var(--ink-2);
}
.checklist li { display: flex; gap: 10px; align-items: flex-start; }
.checklist .icon { color: var(--green-hover); font-size: 13px; margin-top: 3px; }

@media (max-width: 600px) {
  .services, .portfolio { padding-top: 72px; padding-bottom: 72px; }
}

/* Prosess */
.process { background: var(--mint); border-top: 1px solid rgba(29, 64, 50, 0.08); border-bottom: 1px solid rgba(29, 64, 50, 0.08); }
.process-inner {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr)); gap: 40px;
  padding-top: 72px; padding-bottom: 72px;
}
.process h3 { font-size: 25px; margin-top: 12px; }
.process p { font-size: 15.5px; line-height: 1.6; color: var(--muted); margin-top: 10px; }

/* Utførte arbeid */
.portfolio { padding-top: 104px; padding-bottom: 104px; }
.portfolio .section-title { max-width: 560px; }
.link-arrow {
  display: inline-flex; align-items: center; gap: 10px; font-weight: 600; font-size: 15.5px;
  color: var(--green); border-bottom: 1px solid rgba(29, 64, 50, 0.3); padding-bottom: 4px;
}
.link-arrow .icon { font-size: 13px; }

.tabs { margin-top: 44px; display: flex; flex-wrap: wrap; gap: 10px; }
.tab {
  display: inline-flex; align-items: center; padding: 11px 20px; border-radius: 999px;
  font-family: var(--sans); font-size: 14.5px; font-weight: 600; cursor: pointer; white-space: nowrap;
  background: transparent; color: var(--ink-2); border: 1px solid rgba(29, 64, 50, 0.22);
}
.tab:hover { border-color: var(--green-2); }
.tab[aria-selected="true"] { background: var(--green-2); color: var(--on-dark); border-color: var(--green-2); }

.project { margin-top: 26px; }
.project + .project { margin-top: 80px; }
.js .project + .project { margin-top: 26px; }
.project[hidden] { display: none; }
.project-head {
  display: flex; align-items: baseline; gap: 16px; flex-wrap: wrap;
  border-top: 1px solid rgba(29, 64, 50, 0.14); padding-top: 26px;
}
.project-head h3 { font-size: 32px; color: var(--ink); }
.project-head span { font-size: 15px; color: var(--muted-2); }

.compare { margin-top: 32px; display: grid; gap: 34px; }
.pair { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr)); gap: 16px; }
.photo { position: relative; border-radius: 12px; overflow: hidden; background: #E4E9E3; }
.photo img { width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; }
.photo figcaption {
  position: absolute; top: 12px; left: 12px;
  background: rgba(22, 35, 28, 0.78); color: var(--on-dark);
  padding: 6px 11px; border-radius: 6px;
  font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.14em; text-transform: uppercase; white-space: nowrap;
}
.photo figcaption.after { background: var(--green-2); }

.gallery-block { margin-top: 56px; }
.gallery { margin-top: 18px; display: grid; gap: 16px; }
.gallery.work { grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr)); }
.gallery.done { grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)); }
.gallery.done .photo img { aspect-ratio: 3 / 4; }
.photo.wide { margin-top: 16px; }
.photo.wide img { aspect-ratio: 16 / 9; }

/* Kontakt */
.contact { background: var(--green); color: var(--on-dark); }
.contact-inner {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr));
  gap: 56px; align-items: start; padding-top: 96px; padding-bottom: 96px;
}
.contact .eyebrow { color: var(--on-dark-3); }
.contact-copy { max-width: 480px; }
.contact-copy p { margin-top: 20px; font-size: 17px; line-height: 1.6; color: var(--on-dark-2); }
.contact-links { display: flex; flex-direction: column; gap: 14px; }
.contact-link {
  display: flex; align-items: center; gap: 18px; padding: 22px 24px; border-radius: 12px;
  background: rgba(242, 244, 240, 0.07); border: 1px solid rgba(242, 244, 240, 0.16); color: var(--on-dark);
  min-width: 0;
}
.contact-link:hover { background: rgba(242, 244, 240, 0.13); color: var(--on-dark); }
.contact-icon {
  width: 44px; height: 44px; border-radius: 10px; background: rgba(242, 244, 240, 0.12);
  display: flex; align-items: center; justify-content: center; font-size: 18px; flex: none;
}
.contact-label {
  display: block; font-family: var(--mono); font-size: 11px; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--on-dark-3);
}
.contact-value { display: block; font-size: 18px; font-weight: 600; margin-top: 4px; overflow-wrap: anywhere; }

@media (max-width: 600px) {
  .contact-inner { padding-top: 72px; padding-bottom: 72px; gap: 40px; }
  .contact-link { padding: 18px; gap: 14px; }
  .contact-value { font-size: 16.5px; }
}

/* Bunntekst */
.site-footer { background: var(--ink); color: #8FA99B; }
.footer-inner {
  display: flex; flex-wrap: wrap; gap: 16px; align-items: center; justify-content: space-between;
  padding-top: 32px; padding-bottom: 32px; font-size: 14px;
}
.footer-brand { display: flex; align-items: center; gap: 11px; color: var(--on-dark-2); }
.footer-brand .brand-mark { width: 26px; height: 26px; border-radius: 6px; font-size: 12px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.footer-links a { color: #8FA99B; }
.footer-links a:hover { color: var(--on-dark); }

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

/* Fanene trenger JavaScript; uten JS vises alle prosjektene under hverandre */
.tabs { display: none; }
.js .tabs { display: flex; }
