/* =========================================================
   Bondebuda – enkel, moderne stil
   Palett henta frå bygget: lys trekledning, sort taktrim/vindaugsramme
   ========================================================= */

:root {
  --color-bg: #f7f4ee;
  --color-surface: #ffffff;
  --color-surface-alt: #efebe1;
  --color-text: #26241f;
  --color-text-soft: #5c584e;
  --color-ink: #201f1c;        /* sort taktrim/vindauge */
  --color-wood: #cdbfa2;       /* lys trekledning */
  --color-wood-soft: #e4dac2;
  --color-line: #e1dbcb;

  --radius: 14px;
  --radius-sm: 8px;
  --max-width: 1120px;
  --max-width-narrow: 760px;

  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  --shadow-sm: 0 1px 2px rgba(32, 31, 28, 0.06);
  --shadow-md: 0 10px 30px -12px rgba(32, 31, 28, 0.25);
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font);
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

a {
  color: inherit;
}

h1, h2, h3 {
  font-weight: 700;
  line-height: 1.15;
  margin: 0 0 0.5em;
  letter-spacing: -0.01em;
}

h1 { font-size: clamp(2rem, 4vw, 2.9rem); }
h2 { font-size: clamp(1.5rem, 2.6vw, 2rem); }
h3 { font-size: 1.05rem; }

p { margin: 0 0 1em; color: var(--color-text-soft); }

.wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.wrap-narrow {
  max-width: var(--max-width-narrow);
}

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(247, 244, 238, 0.92);
  backdrop-filter: saturate(150%) blur(6px);
  border-bottom: 1px solid var(--color-line);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
}

.logo {
  font-weight: 800;
  font-size: 1.4rem;
  text-decoration: none;
  color: var(--color-ink);
  letter-spacing: -0.02em;
}

.site-nav {
  display: flex;
  gap: 28px;
}

.site-nav a {
  text-decoration: none;
  color: var(--color-text);
  font-size: 0.95rem;
  font-weight: 600;
  padding: 6px 2px;
  border-bottom: 2px solid transparent;
  transition: border-color 0.15s ease;
}

.site-nav a:hover {
  border-color: var(--color-ink);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
}

.nav-toggle span {
  display: block;
  height: 2px;
  background: var(--color-ink);
  border-radius: 2px;
}

/* ---------- Hero ---------- */

.hero {
  padding: 56px 0 48px;
}

.hero-inner {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 48px;
  align-items: center;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--color-text-soft);
  margin-bottom: 12px;
}

.lead {
  font-size: 1.05rem;
  max-width: 46ch;
}

.hero-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 8px;
}

.btn {
  display: inline-block;
  padding: 13px 22px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.95rem;
  text-decoration: none;
  transition: transform 0.15s ease, opacity 0.15s ease;
}

.btn:hover { transform: translateY(-1px); }

.btn-primary {
  background: var(--color-ink);
  color: #fff;
}

.btn-ghost {
  background: transparent;
  color: var(--color-ink);
  border: 1.5px solid var(--color-ink);
}

.hero-media img {
  width: 100%;
  height: 420px;
  object-fit: cover;
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  border: 6px solid var(--color-surface);
}

.hero-media figcaption {
  margin-top: 10px;
  font-size: 0.82rem;
  color: var(--color-text-soft);
  text-align: center;
}

/* ---------- Sections ---------- */

.section {
  padding: 48px 0;
}

.section-tight {
  padding: 40px 0 56px;
}

.section-alt {
  background: var(--color-surface-alt);
}

.section-lead {
  max-width: 60ch;
  margin-bottom: 32px;
  text-wrap: pretty;
}

/* Steps */

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.step {
  background: var(--color-surface);
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  padding: 24px;
}

.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--color-ink);
  color: #fff;
  font-weight: 700;
  font-size: 0.9rem;
  margin-bottom: 14px;
}

.step h3 { margin-bottom: 6px; }
.step p { margin: 0; }

.steps-more {
  margin-top: 16px;
  font-size: 0.9rem;
}

.steps-more a {
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* Vynk widget wrapper */

.vynk-widget-wrap {
  background: var(--color-surface);
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  padding: 24px;
  min-height: 160px;
}

/* Suppliers */

.supplier-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.supplier-card {
  background: var(--color-surface);
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  overflow: hidden;
  padding: 0 0 20px;
}

.supplier-photo {
  height: 140px;
  background: linear-gradient(135deg, var(--color-wood-soft), var(--color-wood));
}

.supplier-card h3 {
  margin: 18px 20px 6px;
}

.supplier-card p {
  margin: 0 20px;
}

/* Contact */

.contact-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.contact-block {
  background: var(--color-surface);
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  padding: 20px;
}

.contact-block h3 {
  margin-bottom: 8px;
  color: var(--color-ink);
}

.contact-block a {
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* ---------- Footer ---------- */

.site-footer {
  border-top: 1px solid var(--color-line);
  padding: 28px 0;
  background: var(--color-ink);
  color: #efece3;
}

.site-footer a {
  color: #efece3;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 0.85rem;
}

.footer-inner p { margin: 0; color: inherit; }

/* ---------- Responsive ---------- */

@media (max-width: 860px) {
  .hero-inner {
    grid-template-columns: 1fr;
  }

  /* Når hero-teksten blir fullbreidde (stabla layout), skal ikkje
     lengda på avsnittet bli låst til smal desktop-breidde (46ch) -
     elles ser teksten ut som ho ikkje går heilt til høgre, medan
     biletet under strekk seg over heile breidda. */
  .lead {
    max-width: none;
  }

  .hero-media img { height: 320px; }

  .steps,
  .supplier-grid {
    grid-template-columns: 1fr 1fr;
  }

  .contact-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 620px) {
  /* Vynk-widgetane sine grid (vareutval/leverandørliste) krev sjølv minst
     ca. 316px tilgjengeleg breidd for å vise 2 kolonner. Vi kan ikkje styre
     det grensesnittet, men vi kan gi widgeten meir albogerom ved å redusere
     vår eiga doble padding (.wrap + .vynk-widget-wrap) på smale skjermar. */
  .wrap { padding: 0 16px; }
  .vynk-widget-wrap { padding: 4px; }

  .nav-toggle { display: flex; }

  .site-nav {
    position: absolute;
    top: 68px;
    left: 0;
    right: 0;
    background: var(--color-bg);
    border-bottom: 1px solid var(--color-line);
    flex-direction: column;
    gap: 0;
    display: none;
    padding: 8px 24px 16px;
  }

  .site-nav.is-open { display: flex; }

  .site-nav a {
    padding: 12px 0;
    border-bottom: 1px solid var(--color-line);
  }

  .steps,
  .supplier-grid,
  .contact-grid {
    grid-template-columns: 1fr;
  }
}
