/* Farger og felles verdier */
:root {
  --ink: #0f2433;
  --muted: #567083;
  --line: #d9e5ec;
  --soft: #f5f9fb;
  --blue: #117f9c;
  --blue-dark: #07556d;
  --aqua: #36c5d7;
  --paper: #ffffff;
  --shadow: 0 16px 42px rgba(15, 36, 51, 0.12);
}

/* Grunnstil */
* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  display: block;
  max-width: 100%;
}

/* Toppbilde */
.top-image {
  width: 100%;
  height: clamp(160px, 27vw, 295px);
  object-fit: cover;
  object-position: center;
}

/* Toppmeny */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  width: 100%;
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(14px);
}

.nav {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  min-height: 65px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
  letter-spacing: 0;
}

.brand-mark {
  width: 50px;
  height: 50px;
  position: relative;
  top: -1px;
  object-fit: cover;
  border-radius: 50%;
  clip-path: circle(47% at 50% 50%);
  transform: scale(1.08);
}

.brand-name {
  position: relative;
  top: 1px;
  font-size: 30px;
}

.brand-tagline {
  position: relative;
  top: 6px;
  color: var(--aqua);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.menu-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  color: var(--blue-dark);
  background: #eaf8fb;
  border: 1px solid var(--line);
  border-radius: 7px;
  cursor: pointer;
}

.menu-toggle span,
.menu-toggle::before,
.menu-toggle::after {
  content: "";
  width: 20px;
  height: 2px;
  display: block;
  position: absolute;
  background: currentColor;
  transition: transform 180ms ease, opacity 180ms ease;
}

.menu-toggle {
  position: relative;
}

.menu-toggle::before {
  transform: translateY(-7px);
}

.menu-toggle::after {
  transform: translateY(7px);
}

.menu-toggle[aria-expanded="true"] span {
  opacity: 0;
}

.menu-toggle[aria-expanded="true"]::before {
  transform: rotate(45deg);
}

.menu-toggle[aria-expanded="true"]::after {
  transform: rotate(-45deg);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.nav-links a {
  padding: 10px 13px;
  border-radius: 7px;
  color: var(--muted);
  font-size: 15px;
  font-weight: 700;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--blue-dark);
}

/* Felles sideoppsett */
.hero,
.section,
.band {
  width: 100%;
}

.hero {
  background: var(--ink);
  color: #ffffff;
}

.hero-inner,
.section-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

/* Forside: hovedfelt */
.hero-inner {
  min-height: clamp(300px, 46vh, 430px);
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(280px, 0.9fr);
  align-items: center;
  gap: clamp(28px, 6vw, 72px);
  padding: clamp(24px, 3.5vw, 44px) 0;
}

.eyebrow {
  margin: 0 0 14px;
  color: var(--aqua);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 13px;
}

/* Overskrifter og tekst */
h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 760px;
  margin-bottom: 22px;
  font-size: 42px;
  line-height: 1.07;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 18px;
  font-size: 42px;
  line-height: 1.1;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 10px;
  font-size: 19px;
  line-height: 1.25;
}

.single-line-heading {
  white-space: nowrap;
}

.lead {
  max-width: 720px;
  color: rgba(255, 255, 255, 0.82);
  font-size: 20px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 12px 18px;
  border: 1px solid transparent;
  border-radius: 7px;
  font-weight: 800;
}

.button.primary {
  color: var(--blue-dark);
  background: var(--aqua);
}

.button.secondary {
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.38);
}

.button.full {
  width: 100%;
}

/* Forside: infopanel */
.hero-panel {
  padding: clamp(22px, 4vw, 34px);
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.hero-panel ul {
  display: grid;
  gap: 16px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.hero-panel li {
  padding-left: 24px;
  position: relative;
  color: rgba(255, 255, 255, 0.86);
}

.hero-panel li::before {
  content: "";
  position: absolute;
  top: calc(0.7em - 2px);
  left: 0;
  width: 9px;
  height: 9px;
  background: #ffffff;
  border-radius: 50%;
}

/* Seksjoner og kort */
.section {
  padding: clamp(28px, 3.5vw, 48px) 0;
}

.section.alt {
  background: var(--soft);
}

.section-header {
  max-width: 760px;
  margin-bottom: 34px;
}

.section-header p,
.muted {
  color: var(--muted);
}

.grid {
  display: grid;
  gap: 18px;
}

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

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

.card {
  min-height: 100%;
  padding: 26px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 10px 28px rgba(15, 36, 51, 0.06);
}

.card strong {
  color: var(--blue-dark);
}

/* Bildekarusell */
.image-carousel {
  width: 100%;
  height: 360px;
  position: relative;
  margin: 34px 0;
  overflow: hidden;
  background: var(--ink);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.carousel-track,
.carousel-slide {
  width: 100%;
  height: 100%;
}

.carousel-slide {
  position: absolute;
  inset: 0;
  object-fit: cover;
  opacity: 0;
  transition: opacity 600ms ease;
}

.carousel-slide.active {
  opacity: 1;
}

/* Finn riktig hjelp */
.tool-panel {
  margin-top: 34px;
  padding: clamp(22px, 4vw, 32px);
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 10px 28px rgba(15, 36, 51, 0.06);
}

.help-finder {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: end;
}

.help-finder select {
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  color: var(--ink);
  background: #ffffff;
  border: 1px solid #c8d7df;
  border-radius: 7px;
  font: inherit;
}

.result-box {
  margin-top: 18px;
  padding: 18px;
  color: var(--ink);
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.result-box:empty {
  display: none;
}

/* Fullbredde bilde */
.wide-image {
  width: 100%;
  height: 360px;
  overflow: hidden;
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.wide-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.after-image {
  margin-top: 34px;
}

/* Bilde med tekstfelt */
.feature-image {
  width: 100%;
  min-height: clamp(260px, 42vw, 520px);
  position: relative;
  overflow: hidden;
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.feature-image img {
  width: 100%;
  height: 100%;
  min-height: clamp(260px, 42vw, 520px);
  object-fit: cover;
}

.feature-caption {
  position: absolute;
  left: clamp(18px, 4vw, 42px);
  bottom: clamp(18px, 4vw, 42px);
  max-width: 520px;
  padding: clamp(18px, 3vw, 26px);
  color: #ffffff;
  background: rgba(8, 25, 35, 0.82);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 8px;
  backdrop-filter: blur(10px);
}

.feature-caption h2 {
  margin-bottom: 10px;
  font-size: 34px;
}

.feature-caption p {
  margin-bottom: 0;
  color: rgba(255, 255, 255, 0.82);
}

/* Delte innholdsfelt */
.split {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  gap: clamp(28px, 6vw, 72px);
  align-items: start;
}

.check-list {
  display: grid;
  gap: 12px;
  margin: 22px 0 0;
  padding: 0;
  list-style: none;
}

.check-list li {
  padding-left: 28px;
  position: relative;
}

.check-list li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--blue);
  font-weight: 900;
}

.quote {
  margin-top: 25px;
  padding: clamp(28px, 5vw, 44px);
  color: #ffffff;
  background: var(--blue-dark);
  border-radius: 8px;
}

.quote p {
  font-size: 26px;
  line-height: 1.25;
}

/* Sidetittel på undersider */
.page-title {
  padding: clamp(24px, 3.5vw, 42px) 0;
  color: #ffffff;
  background: var(--ink);
}

.page-title .section-inner {
  max-width: 1180px;
}

.page-title p {
  max-width: 760px;
  color: rgba(255, 255, 255, 0.8);
  font-size: 18px;
}

/* Tjenesteside */
.service-list {
  display: grid;
  gap: 18px;
}

.service-item {
  display: grid;
  grid-template-columns: 84px minmax(0, 1fr);
  gap: 22px;
  align-items: start;
  padding: clamp(22px, 4vw, 32px);
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 8px;
  scroll-margin-top: 100px;
}

#tjenester {
  scroll-margin-top: 84px;
}

.service-symbol {
  width: 64px;
  height: 64px;
  object-fit: cover;
  border-radius: 50%;
}

.service-item > div {
  position: relative;
  top: 8px;
}

/* Kontaktside */
.contact-panel {
  padding: clamp(26px, 5vw, 42px);
  color: #ffffff;
  background: var(--ink);
  border-radius: 8px;
}

.contact-panel a {
  color: #ffffff;
  font-weight: 800;
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}

.contact-details {
  display: grid;
  gap: 16px;
  margin-top: 24px;
}

.detail {
  padding: 18px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
}

/* Skjema */
.form {
  display: grid;
  gap: 14px;
}

.form-status {
  min-height: 0;
  padding: 0;
  color: var(--blue-dark);
  font-weight: 800;
}

.form-status:not(:empty) {
  padding: 14px;
  background: #eaf8fb;
  border: 1px solid #bceaf0;
  border-radius: 8px;
}

/* Ofte stilte spørsmål */
.faq {
  display: grid;
  gap: 12px;
}

.faq-item {
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
}

.faq-question {
  width: 100%;
  min-height: 58px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 16px 18px;
  color: var(--ink);
  background: #ffffff;
  border: 0;
  font: inherit;
  font-weight: 850;
  text-align: left;
  cursor: pointer;
}

.faq-question::after {
  content: "+";
  color: var(--blue);
  font-size: 24px;
  line-height: 1;
}

.faq-question[aria-expanded="true"]::after {
  content: "-";
}

.faq-answer {
  display: none;
  padding: 0 18px 18px;
  color: var(--muted);
}

.faq-question[aria-expanded="true"] + .faq-answer {
  display: block;
}

/* Skjemafelt */
label {
  display: grid;
  gap: 7px;
  color: var(--ink);
  font-weight: 800;
}

input,
textarea,
select {
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  color: var(--ink);
  background: #ffffff;
  border: 1px solid #c8d7df;
  border-radius: 7px;
  font: inherit;
}

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

/* Bunnfelt */
.site-footer {
  width: 100%;
  padding: 15px 0;
  color: rgba(255, 255, 255, 0.78);
  background: var(--blue-dark);
}

.footer-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
}

.footer-inner a {
  color: #ffffff;
  font-weight: 700;
}

/* Mobil og nettbrett */
@media (max-width: 980px) {
  .quiz-shell {
    grid-template-columns: 1fr;
  }

  .quiz-sidebar {
    position: static;
  }

  .quiz-form-grid,
  .option-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 860px) {
  h1 {
    font-size: 42px;
  }

  h2 {
    font-size: 34px;
  }

  .nav {
    align-items: center;
    flex-direction: row;
    padding: 14px 0;
    gap: 12px;
    flex-wrap: wrap;
  }

  .brand {
    display: grid;
    grid-template-columns: 54px minmax(0, 1fr);
    column-gap: 10px;
    row-gap: 0;
    flex: 1 1 calc(100% - 70px);
  }

  .brand-mark {
    grid-row: 1 / span 2;
  }

  .brand-name {
    top: 0;
    line-height: 1.05;
  }

  .brand-tagline {
    top: 0;
    max-width: 260px;
    line-height: 1.35;
  }

  .menu-toggle {
    display: inline-flex;
  }

  .nav-links {
    width: 100%;
    display: none;
    justify-content: flex-start;
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links a {
    padding: 8px 10px;
  }

  .hero-inner,
  .split,
  .grid.two {
    grid-template-columns: 1fr;
  }

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

  .help-finder {
    grid-template-columns: 1fr;
  }

  .hero-inner {
    min-height: auto;
  }
}

/* Små mobilskjermer */
@media (max-width: 560px) {
  h1 {
    font-size: 34px;
  }

  h2 {
    font-size: 29px;
  }

  .single-line-heading {
    white-space: normal;
  }

  .lead {
    font-size: 18px;
  }

  .feature-caption h2 {
    font-size: 28px;
  }

  .quote p {
    font-size: 22px;
  }

  .top-image {
    height: 170px;
  }

  .nav,
  .hero-inner,
  .section-inner,
  .footer-inner {
    width: min(100% - 24px, 1180px);
  }

  .brand {
    grid-template-columns: 54px minmax(0, 1fr);
  }

  .brand-name {
    font-size: 28px;
  }

  .brand-tagline {
    max-width: 230px;
    font-size: 12px;
  }

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

  .nav-links:not(.open) {
    display: none;
  }

  .nav-links a {
    text-align: center;
  }

  .grid.three {
    grid-template-columns: 1fr;
  }

  .feature-caption {
    position: static;
    max-width: none;
    background: var(--blue-dark);
    border-radius: 0;
  }

  .service-item {
    grid-template-columns: 1fr;
  }

  .service-symbol {
    width: 54px;
    height: 54px;
  }

}


/* Quizside */
.quiz-shell {
  display: grid;
  grid-template-columns: 330px minmax(0, 1fr);
  gap: 22px;
  align-items: start;
}

.quiz-sidebar,
.quiz-workspace {
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 10px 28px rgba(15, 36, 51, 0.06);
}

.quiz-sidebar {
  position: sticky;
  top: 88px;
  padding: 20px;
}

.quiz-sidebar-header,
.quiz-editor-head,
.question-builder-head,
.quiz-save-row,
.runner-top,
.runner-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.quiz-sidebar-header h2,
.quiz-editor-head h2,
.runner-top h2 {
  margin-bottom: 0;
  font-size: 28px;
}

.quiz-toolbar {
  display: grid;
  gap: 12px;
  margin: 18px 0;
}

.quiz-list {
  display: grid;
  gap: 10px;
}

.quiz-list button {
  width: 100%;
  padding: 14px;
  color: var(--ink);
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: 8px;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.quiz-list button.active,
.quiz-list button:hover {
  color: #ffffff;
  background: var(--blue-dark);
  border-color: var(--blue-dark);
}

.quiz-list strong,
.quiz-list span {
  display: block;
}

.quiz-list span {
  margin-top: 4px;
  font-size: 13px;
  opacity: 0.78;
}

.quiz-workspace {
  min-height: 620px;
  padding: clamp(22px, 4vw, 34px);
}

.quiz-empty {
  max-width: 680px;
}

.quiz-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 14px;
}

.quiz-actions,
.quiz-save-row {
  flex-wrap: wrap;
}

.button.secondary.ink {
  color: var(--blue-dark);
  border-color: var(--line);
  background: #ffffff;
}

.button.danger {
  color: #ffffff;
  background: #9f2d2d;
}

.question-builder {
  margin-top: 24px;
}

.question-card {
  display: grid;
  gap: 14px;
  margin-top: 14px;
  padding: 18px;
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.question-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.question-top h4 {
  margin: 0;
  font-size: 18px;
}

.option-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.option-row {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr);
  gap: 10px;
  align-items: end;
}

.option-row input[type="radio"] {
  min-height: 22px;
  width: 22px;
  margin: 0 0 13px;
}

.quiz-save-row {
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.runner-meta {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.runner-meta span {
  padding: 8px 10px;
  color: var(--blue-dark);
  background: #eaf8fb;
  border-radius: 7px;
  font-size: 14px;
  font-weight: 800;
}

.runner-progress {
  height: 10px;
  margin: 20px 0;
  overflow: hidden;
  background: var(--soft);
  border-radius: 99px;
}

.runner-progress span {
  width: 0;
  height: 100%;
  display: block;
  background: var(--aqua);
  transition: width 220ms ease;
}

.runner-question {
  margin: 0;
  padding: 0;
  border: 0;
}

.runner-question legend {
  margin-bottom: 18px;
  font-size: 28px;
  font-weight: 850;
  line-height: 1.2;
}

.answer-grid {
  display: grid;
  gap: 12px;
}

.answer-option {
  width: 100%;
  padding: 16px;
  color: var(--ink);
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 8px;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.answer-option.selected {
  color: #ffffff;
  background: var(--blue-dark);
  border-color: var(--blue-dark);
}

.runner-actions {
  margin-top: 22px;
}

.result-card {
  padding: 24px;
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.result-score {
  margin: 8px 0 18px;
  font-size: 42px;
  font-weight: 900;
  line-height: 1;
}

.review-list {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}

.review-item {
  padding: 16px;
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.review-item.correct {
  border-color: #7fcda5;
}

.review-item.wrong {
  border-color: #e0a1a1;
}

.admin-login {
  max-width: 460px;
  margin: 0 auto;
}

.publish-toggle {
  display: flex;
  grid-template-columns: none;
  align-items: center;
  gap: 10px;
  margin: 0 0 14px;
}

.publish-toggle input {
  width: 20px;
  min-height: 20px;
}

.public-quiz-intro {
  display: grid;
  gap: 18px;
  max-width: 720px;
}

.public-meta {
  justify-content: flex-start;
}
