:root {
  --bg: #020617;
  --bg-elevated: #020617;
  --card: #020617;
  --card-soft: #020718;
  --border-subtle: rgba(148, 163, 184, 0.55);
  --text-main: #f9fafb;
  --text-soft: #d1d5db;
  --accent: #f97316;

  --epoch-viking: #fb923c;
  --epoch-union: #818cf8;
  --epoch-nation: #22c55e;
  --epoch-oil: #eab308;
  --epoch-modern: #38bdf8;

  --radius-card: 18px;
  --radius-pill: 999px;
  --shadow-soft: 0 18px 45px rgba(15, 23, 42, 0.85);
  --shadow-subtle: 0 10px 30px rgba(15, 23, 42, 0.7);
  --transition-fast: 150ms ease-out;
  --transition-med: 220ms ease-out;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "SF Pro Text",
    "Segoe UI", sans-serif;
  background: radial-gradient(
      circle at top,
      #0b1120 0,
      #020617 40%,
      #020617 100%
    ),
    #020617;
  color: var(--text-main);
  min-height: 100vh;
}

/* HEADER */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(18px);
  background: linear-gradient(
    to bottom,
    rgba(15, 23, 42, 0.98),
    rgba(15, 23, 42, 0.9),
    rgba(2, 6, 23, 0.92),
    transparent
  );
  border-bottom: 1px solid rgba(30, 64, 175, 0.7);
}

.header-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0.7rem 1.5rem;
  display: flex;
  align-items: center;
  gap: 1.2rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-weight: 650;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-size: 0.8rem;
  color: #e5e7eb;
}

.brand-mark {
  font-size: 1.25rem;
}

.main-nav {
  display: flex;
  gap: 1rem;
  margin-left: 1rem;
  flex: 1;
}

.main-nav a {
  font-size: 0.85rem;
  color: var(--text-soft);
  text-decoration: none;
  padding: 0.28rem 0.9rem;
  border-radius: 999px;
  border: 1px solid transparent;
  transition: color var(--transition-fast), background var(--transition-fast),
    border-color var(--transition-fast), transform var(--transition-fast);
}

.main-nav a:hover {
  color: var(--text-main);
  border-color: rgba(191, 219, 254, 0.7);
  background: rgba(15, 23, 42, 0.95);
  transform: translateY(-1px);
}

/* LANGUAGE SWITCH */

.lang-switch-wrapper {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.75rem;
  color: var(--text-soft);
}

.lang-label {
  opacity: 0.8;
}

.toggle-switch {
  position: relative;
  display: inline-flex;
  align-items: center;
  cursor: pointer;
}

.toggle-switch input {
  display: none;
}

.toggle-slider {
  width: 50px;
  height: 24px;
  background: rgba(15, 23, 42, 0.96);
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.7);
  display: flex;
  align-items: center;
  padding: 0 2px;
  position: relative;
  transition: background var(--transition-med),
    border-color var(--transition-med), box-shadow var(--transition-med);
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.9);
}

.toggle-knob {
  width: 18px;
  height: 18px;
  border-radius: 999px;
  background: radial-gradient(
    circle at 30% 25%,
    #facc15 0,
    #f97316 40%,
    #ef4444 100%
  );
  box-shadow: 0 8px 20px rgba(248, 250, 252, 0.5);
  transform: translateX(1px);
  transition: transform var(--transition-med);
}

.toggle-switch input:checked + .toggle-slider {
  border-color: rgba(96, 165, 250, 0.9);
  box-shadow: 0 8px 30px rgba(59, 130, 246, 0.8);
}

.toggle-switch input:checked + .toggle-slider .toggle-knob {
  transform: translateX(24px);
}

/* HERO */

.hero {
  max-width: 1100px;
  margin: 1.6rem auto 2.6rem auto;
  padding: 1.6rem 1.5rem 2.2rem 1.5rem;
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  gap: 2.1rem;
}

.hero-inner {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}

.hero-kicker {
  font-size: 0.8rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: #a5b4fc;
}

.hero-title {
  font-size: clamp(2.3rem, 3vw, 2.9rem);
  letter-spacing: -0.04em;
  margin: 0;
}

.hero-lead {
  margin: 0.2rem 0 0.4rem 0;
  color: var(--text-soft);
  max-width: 32rem;
  line-height: 1.65;
}

.hero-actions {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  margin-top: 0.6rem;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  align-self: flex-start;
  padding: 0.75rem 1.6rem;
  border-radius: 999px;
  border: none;
  background: radial-gradient(
    circle at 0 0,
    #f97316 0,
    #ec4899 40%,
    #6366f1 100%
  );
  color: #020617;
  font-weight: 600;
  font-size: 0.92rem;
  text-decoration: none;
  box-shadow: 0 16px 40px rgba(236, 72, 153, 0.8);
  transition: transform var(--transition-fast),
    box-shadow var(--transition-fast), filter var(--transition-fast);
}

.btn-primary:hover {
  transform: translateY(-1px) translateZ(0);
  box-shadow: 0 20px 55px rgba(236, 72, 153, 0.9);
  filter: brightness(1.03);
}

.hero-note {
  font-size: 0.8rem;
  color: #e5e7eb;
  opacity: 0.9;
}

.hero-illustration {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-circle {
  width: 280px;
  height: 280px;
  border-radius: 999px;
  background: conic-gradient(
    from 220deg,
    #0ea5e9,
    #6366f1,
    #f97316,
    #ec4899,
    #0ea5e9
  );
  box-shadow: 0 0 0 1px rgba(15, 23, 42, 0.9),
    0 32px 90px rgba(15, 23, 42, 0.95);
  opacity: 0.95;
}

.hero-mini-map {
  position: absolute;
  bottom: 18%;
  left: 10%;
  padding: 0.45rem 0.9rem;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.98);
  border: 1px solid rgba(148, 163, 184, 0.6);
  font-size: 0.75rem;
  color: #e5e7eb;
}

.hero-mini-label {
  white-space: nowrap;
}

/* TIDSLINJE */

.timeline-section {
  max-width: 1100px;
  margin: 0 auto 3.5rem auto;
  padding: 0 1.5rem 2.5rem 1.5rem;
}

.timeline-header h2 {
  font-size: 1.6rem;
  margin-bottom: 0.25rem;
}

.timeline-header p {
  margin: 0;
  color: var(--text-soft);
  max-width: 42rem;
  line-height: 1.7;
}

/* Epoke-tagger */

.timeline-epoch-tags {
  margin-top: 1.3rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.epoch-tag {
  border-radius: 999px;
  padding: 0.4rem 0.95rem;
  font-size: 0.8rem;
  border: 1px solid rgba(148, 163, 184, 0.7);
  background: radial-gradient(circle at 0 0, rgba(15, 23, 42, 0.98), #020617);
  color: var(--text-soft);
  cursor: pointer;
  transition: background var(--transition-fast),
    border-color var(--transition-fast), color var(--transition-fast),
    transform var(--transition-fast), box-shadow var(--transition-fast);
  box-shadow: 0 10px 20px rgba(15, 23, 42, 0.75);
}

.epoch-tag:hover {
  color: var(--text-main);
  border-color: rgba(248, 250, 252, 0.9);
  background: radial-gradient(circle at 0 0, #1d4ed8, #020617);
  transform: translateY(-1px);
  box-shadow: 0 16px 40px rgba(15, 23, 42, 0.95);
}

.epoch-tag-viking {
  border-color: rgba(248, 113, 113, 0.9);
}

.epoch-tag-union {
  border-color: rgba(129, 140, 248, 0.9);
}

.epoch-tag-nation {
  border-color: rgba(34, 197, 94, 0.9);
}

.epoch-tag-oil {
  border-color: rgba(234, 179, 8, 0.9);
}

.epoch-tag-modern {
  border-color: rgba(56, 189, 248, 0.9);
}

.timeline-wrapper {
  position: relative;
  margin-top: 2.4rem;
  padding-left: 2.9rem;
}

/* Vei / linje */

.timeline-road {
  position: absolute;
  left: 1.45rem;
  top: 0;
  bottom: 0;
  width: 3px;
  border-radius: 999px;
  background: linear-gradient(
    to bottom,
    rgba(148, 163, 184, 0.2),
    rgba(129, 140, 248, 0.7),
    rgba(248, 113, 113, 0.8),
    rgba(45, 212, 191, 0.7),
    rgba(148, 163, 184, 0.2)
  );
  box-shadow: 0 0 30px rgba(59, 130, 246, 0.5);
}

/* Vikingskip langs veien */

.timeline-ship {
  position: absolute;
  left: 0.85rem;
  top: 0.3rem;
  font-size: 1.4rem;
  filter: drop-shadow(0 6px 10px rgba(15, 23, 42, 0.9));
  transition: transform 120ms linear, opacity 160ms ease-out;
  opacity: 0;
  pointer-events: none;
}

/* Epoch-bannere */

.timeline-epoch-banner {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.3rem 0.8rem;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 500;
  margin-bottom: 1rem;
  backdrop-filter: blur(12px);
  border: 1px solid rgba(148, 163, 184, 0.35);
}

.epoch-banner-icon {
  font-size: 0.9rem;
}

.epoch-banner-viking {
  background: radial-gradient(
    circle at 0 0,
    rgba(248, 113, 113, 0.35),
    transparent 60%
  );
  color: #ffedd5;
}

.epoch-banner-union {
  background: radial-gradient(
    circle at 0 0,
    rgba(129, 140, 248, 0.35),
    transparent 60%
  );
  color: #e0e7ff;
}

.epoch-banner-nation {
  background: radial-gradient(
    circle at 0 0,
    rgba(34, 197, 94, 0.35),
    transparent 60%
  );
  color: #bbf7d0;
}

.epoch-banner-oil {
  background: radial-gradient(
    circle at 0 0,
    rgba(234, 179, 8, 0.35),
    transparent 60%
  );
  color: #fef9c3;
}

.epoch-banner-modern {
  background: radial-gradient(
    circle at 0 0,
    rgba(56, 189, 248, 0.35),
    transparent 60%
  );
  color: #cffafe;
}

/* Timeline-items */

.timeline-item {
  position: relative;
  margin-bottom: 3.8rem;
}

.timeline-marker {
  position: absolute;
  left: -1.05rem;
  top: 0.3rem;
  width: 14px;
  height: 14px;
  border-radius: 999px;
  background: #020617;
  border: 3px solid #e5e7eb;
  box-shadow: 0 0 0 4px rgba(248, 250, 252, 0.14),
    0 0 25px rgba(129, 140, 248, 0.85);
}

.timeline-card {
  background: radial-gradient(circle at 0 0, #0b1120, #020617);
  border-radius: var(--radius-card);
  padding: 1.1rem 1.2rem 1rem 1.2rem;
  border: 1px solid rgba(148, 163, 184, 0.75);
  box-shadow: var(--shadow-soft);
  position: relative;
}

.timeline-card::before {
  content: "";
  position: absolute;
  left: -0.5rem;
  top: 0.9rem;
  width: 0.8rem;
  height: 2px;
  background: rgba(148, 163, 184, 0.7);
  border-radius: 999px;
}

.timeline-title {
  margin: 0 0 0.3rem 0;
  font-size: 1.02rem;
}

.timeline-year {
  margin: 0 0 0.55rem 0;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: #e5e7eb;
}

.timeline-body {
  margin: 0 0 0.55rem 0;
  color: var(--text-main);
  font-size: 0.92rem;
  line-height: 1.7;
}

.timeline-sources {
  margin: 0;
  font-size: 0.8rem;
  color: #e5e7eb;
}

.timeline-sources a {
  color: #bfdbfe;
  text-decoration: none;
}

.timeline-sources a:hover {
  text-decoration: underline;
}

/* Epochfarger på kort */

.epoch-viking .timeline-card {
  border-left: 3px solid var(--epoch-viking);
}

.epoch-union .timeline-card {
  border-left: 3px solid var(--epoch-union);
}

.epoch-nation .timeline-card {
  border-left: 3px solid var(--epoch-nation);
}

.epoch-oil .timeline-card {
  border-left: 3px solid var(--epoch-oil);
}

.epoch-modern .timeline-card {
  border-left: 3px solid var(--epoch-modern);
}

/* Navigasjon mellom hendelser – sticky */

.event-nav {
  margin-top: 0.9rem;
  display: flex;
  justify-content: flex-end;
  gap: 0.6rem;
  position: sticky;
  bottom: 1.4rem;
  padding-right: 0.2rem;
  z-index: 40;
}

.event-nav-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.45rem 1rem;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.7);
  background: rgba(15, 23, 42, 0.98);
  color: var(--text-soft);
  font-size: 0.8rem;
  cursor: pointer;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.9);
  transition: background var(--transition-fast),
    border-color var(--transition-fast), transform var(--transition-fast),
    color var(--transition-fast), box-shadow var(--transition-fast);
}

.event-nav-btn:hover {
  background: rgba(15, 23, 42, 1);
  border-color: rgba(248, 250, 252, 0.6);
  color: var(--text-main);
  transform: translateY(-1px);
  box-shadow: 0 18px 45px rgba(15, 23, 42, 1);
}

.event-nav-icon {
  font-size: 0.9rem;
}

/* PERSON-SEKSJON */

.people-section {
  max-width: 1100px;
  margin: 0 auto 3.5rem auto;
  padding: 0 1.5rem 3rem 1.5rem;
}

.people-heading h2 {
  margin-bottom: 0.3rem;
}

.people-heading p {
  margin: 0;
  color: var(--text-soft);
  max-width: 42rem;
  line-height: 1.7;
}

.people-epoch-group {
  margin-top: 2.2rem;
}

.people-epoch-header {
  margin-bottom: 0.7rem;
}

.people-epoch-pill {
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.3rem 0.9rem;
  border-radius: var(--radius-pill);
  font-size: 0.76rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.epoch-pill-viking {
  background: rgba(248, 113, 113, 0.18);
  color: #ffedd5;
}

.epoch-pill-union {
  background: rgba(129, 140, 248, 0.2);
  color: #e0e7ff;
}

.epoch-pill-nation {
  background: rgba(34, 197, 94, 0.2);
  color: #bbf7d0;
}

.epoch-pill-oil {
  background: rgba(234, 179, 8, 0.2);
  color: #fef9c3;
}

.epoch-pill-modern {
  background: rgba(56, 189, 248, 0.2);
  color: #cffafe;
}

.people-grid {
  margin-top: 0.7rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.4rem;
}

.person-card {
  background: radial-gradient(circle at 0 0, #020617, #020617);
  border-radius: var(--radius-card);
  border: 1px solid var(--border-subtle);
  padding: 0.9rem 1rem 0.9rem 1rem;
  box-shadow: var(--shadow-subtle);
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.person-main {
  display: flex;
  gap: 0.8rem;
}

.person-avatar {
  width: 58px;
  height: 58px;
  border-radius: 999px;
  overflow: hidden;
  flex-shrink: 0;
  box-shadow: 0 14px 32px rgba(15, 23, 42, 0.9);
  background: #e5e7eb;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  font-weight: 600;
  color: #020617;
}

.person-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Placeholder-avatar */

.person-avatar.placeholder {
  background: radial-gradient(circle at 0 0, #1f2937, #020617);
  color: #e5e7eb;
}

.avatar-viking {
  background: radial-gradient(circle at 0 0, rgba(248, 113, 113, 0.7), #020617);
}

.avatar-union {
  background: radial-gradient(
    circle at 0 0,
    rgba(129, 140, 248, 0.75),
    #020617
  );
}

.avatar-nation {
  background: radial-gradient(circle at 0 0, rgba(34, 197, 94, 0.8), #020617);
}

.avatar-oil {
  background: radial-gradient(circle at 0 0, rgba(234, 179, 8, 0.9), #020617);
}

.avatar-modern {
  background: radial-gradient(circle at 0 0, rgba(56, 189, 248, 0.9), #020617);
}

.person-initials {
  letter-spacing: 0.06em;
}

.person-name {
  margin: 0 0 0.15rem 0;
  font-size: 0.98rem;
}

.person-dates {
  margin: 0;
  font-size: 0.8rem;
  color: #e5e7eb;
}

.person-bio {
  margin: 0.3rem 0 0 0;
  font-size: 0.86rem;
  color: var(--text-soft);
  line-height: 1.7;
}

/* KART-SEKSJON */

.map-section {
  max-width: 1100px;
  margin: 0 auto 3.5rem auto;
  padding: 0 1.5rem 3rem 1.5rem;
}

.map-heading h2 {
  margin-bottom: 0.3rem;
}

.map-heading p {
  margin: 0;
  color: var(--text-soft);
  max-width: 42rem;
  line-height: 1.7;
}

.map-layout {
  margin-top: 1.8rem;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 2rem;
  align-items: flex-start;
}

.map-wrapper {
  position: relative;
  border-radius: 24px;
  padding: 1.2rem;
  background: radial-gradient(circle at top left, #020617, #020617 60%);
  border: 1px solid rgba(148, 163, 184, 0.7);
  box-shadow: 0 22px 60px rgba(15, 23, 42, 0.95);
  overflow: visible; /* viktig: lar popupen stikke utenfor rammen */
}

.map-glow {
  position: absolute;
  inset: 0;
  background: radial-gradient(
    circle at 10% 0,
    rgba(56, 189, 248, 0.3),
    transparent 55%
  );
  opacity: 0.8;
  pointer-events: none;
}

/* Selve kartet */

.map-inner {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  background: #020617;
}

.norway-map-img {
  width: 100%;
  height: auto;
  display: block;
}

/* Markører som ligger over kartet */

.map-marker {
  position: absolute;
  transform: translate(-50%, -50%);
  width: 24px;
  height: 24px;
  border-radius: 999px;
  background: transparent;
  border: none;
  padding: 0;
  cursor: pointer;
}

.map-marker-halo {
  position: absolute;
  inset: 0;
  border-radius: 999px;
  border: 2px solid rgba(148, 163, 184, 0.9);
  opacity: 0.6;
  transition: opacity 150ms ease-out, transform 150ms ease-out;
}

.map-marker-dot {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: #e5e7eb;
  border: 1px solid #020617;
  transform: translate(-50%, -50%);
}

/* Farger per epoke på dot */

.map-marker.epoch-viking .map-marker-dot {
  background: var(--epoch-viking);
}

.map-marker.epoch-union .map-marker-dot {
  background: var(--epoch-union);
}

.map-marker.epoch-nation .map-marker-dot {
  background: var(--epoch-nation);
}

.map-marker.epoch-oil .map-marker-dot {
  background: var(--epoch-oil);
}

.map-marker.epoch-modern .map-marker-dot {
  background: var(--epoch-modern);
}

.map-marker:hover .map-marker-halo,
.map-marker:focus-visible .map-marker-halo {
  opacity: 1;
  transform: scale(1.1);
}

.map-marker:focus-visible {
  outline: none;
}

/* Popup på kart */

.map-popup {
  position: absolute;
  min-width: 230px;
  max-width: 280px;
  background: #020617;
  border-radius: var(--radius-card);
  border: 1px solid rgba(148, 163, 184, 0.85);
  box-shadow: var(--shadow-soft);
  padding: 0.8rem 0.9rem 0.85rem 0.9rem;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, -110%) scale(0.96);
  transition: opacity 180ms ease-out, transform 180ms ease-out;
  z-index: 20;
}

.map-popup::after {
  content: "";
  position: absolute;
  bottom: -7px;
  left: 50%;
  transform: translateX(-50%);
  border-width: 7px 7px 0 7px;
  border-style: solid;
  border-color: rgba(148, 163, 184, 0.85) transparent transparent transparent;
}

.map-popup-visible {
  opacity: 1;
  pointer-events: auto;
  transform: translate(-50%, -112%) scale(1);
}

.map-popup-close {
  position: absolute;
  right: 0.4rem;
  top: 0.25rem;
  background: transparent;
  border: none;
  color: #9ca3af;
  font-size: 1rem;
  cursor: pointer;
}

.map-popup-epoch {
  margin: 0 0 0.1rem 0;
  font-size: 0.73rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #a5b4fc;
}

.map-popup-title {
  margin: 0 0 0.15rem 0;
  font-size: 0.98rem;
}

.map-popup-year {
  margin: 0 0 0.35rem 0;
  font-size: 0.8rem;
  color: #e5e7eb;
}

.map-popup-body {
  margin: 0 0 0.55rem 0;
  font-size: 0.84rem;
  color: var(--text-soft);
  line-height: 1.6;
}

.map-popup-timeline-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.35rem 0.9rem;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.9);
  background: rgba(15, 23, 42, 0.98);
  color: var(--text-main);
  font-size: 0.78rem;
  cursor: pointer;
}

.map-popup-timeline-btn:hover {
  border-color: rgba(248, 250, 252, 0.8);
}

/* Sidepanel ved kart */

.map-side h3 {
  margin: 0 0 0.4rem 0;
  font-size: 1rem;
}

.map-side p {
  margin: 0 0 0.9rem 0;
  font-size: 0.9rem;
  color: var(--text-soft);
  line-height: 1.7;
}

.map-legend-title {
  margin: 0 0 0.3rem 0;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: #9ca3af;
}

.map-legend {
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 0.86rem;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.map-legend li {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.legend-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  flex-shrink: 0;
}

.legend-viking {
  background: var(--epoch-viking);
}

.legend-union {
  background: var(--epoch-union);
}

.legend-nation {
  background: var(--epoch-nation);
}

.legend-oil {
  background: var(--epoch-oil);
}

.legend-modern {
  background: var(--epoch-modern);
}

/* FOOTER */

.site-footer {
  border-top: 1px solid rgba(15, 23, 42, 0.95);
  padding: 1.4rem 1.5rem 1.9rem 1.5rem;
  margin-top: 1.7rem;
  background: radial-gradient(circle at top, rgba(15, 23, 42, 0.95), #020617);
}

.site-footer p {
  max-width: 1100px;
  margin: 0 auto;
  font-size: 0.8rem;
  color: #9ca3af;
}

/* RESPONSIVITET */

@media (max-width: 840px) {
  .hero {
    grid-template-columns: minmax(0, 1fr);
    gap: 1.6rem;
  }

  .hero-illustration {
    order: -1;
  }

  .hero-circle {
    width: 230px;
    height: 230px;
  }

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

@media (max-width: 700px) {
  .header-inner {
    flex-wrap: wrap;
    justify-content: space-between;
  }

  .main-nav {
    order: 3;
    width: 100%;
    margin-left: 0;
    justify-content: flex-start;
  }

  .timeline-wrapper {
    padding-left: 2.4rem;
  }

  .timeline-item {
    margin-bottom: 3.2rem;
  }

  .event-nav {
    justify-content: flex-start;
    flex-wrap: wrap;
  }

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

/* QUIZ-SEKSJON */

.quiz-section {
  max-width: 900px;
  margin: 0 auto 3.5rem auto;
  padding: 0 1.5rem;
}

.quiz-inner {
  background: radial-gradient(circle at top left, #020617, #020617 65%);
  border-radius: 20px;
  border: 1px solid rgba(148, 163, 184, 0.85);
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.9);
  padding: 1.8rem 1.7rem 1.6rem 1.7rem;
  position: relative;
  overflow: hidden;
}

.quiz-inner::before {
  content: "";
  position: absolute;
  inset: -40%;
  background: radial-gradient(
    circle at -10% 0,
    rgba(56, 189, 248, 0.2),
    transparent 55%
  );
  opacity: 0.9;
  pointer-events: none;
}

.quiz-header {
  position: relative;
  z-index: 1;
  margin-bottom: 1.4rem;
}

.quiz-header h2 {
  margin: 0 0 0.3rem 0;
}

.quiz-header p {
  margin: 0;
  color: var(--text-soft, #9ca3af);
  max-width: 40rem;
  line-height: 1.7;
  font-size: 0.95rem;
}

.quiz-body {
  position: relative;
  z-index: 1;
}

.quiz-status {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 0.7rem;
  font-size: 0.83rem;
  color: var(--text-soft, #9ca3af);
}

.quiz-status span {
  opacity: 0.95;
}

#quiz-question-text {
  margin: 0 0 0.9rem 0;
  font-size: 1.05rem;
}

.quiz-options {
  list-style: none;
  margin: 0 0 0.9rem 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.quiz-option-btn {
  width: 100%;
  text-align: left;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.8);
  background: rgba(15, 23, 42, 0.96);
  padding: 0.6rem 0.9rem;
  font-size: 0.9rem;
  color: var(--text-main, #e5e7eb);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.7rem;
  transition: background 140ms ease-out, border-color 140ms ease-out,
    transform 80ms ease-out, box-shadow 80ms ease-out;
}

.quiz-option-btn span {
  flex: 1;
}

.quiz-option-btn:hover {
  background: rgba(30, 64, 175, 0.4);
  border-color: rgba(191, 219, 254, 0.9);
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(15, 23, 42, 0.7);
}

.quiz-option-btn:disabled {
  cursor: default;
  opacity: 0.92;
  transform: none;
  box-shadow: none;
}

.quiz-option-correct {
  border-color: rgba(34, 197, 94, 0.95) !important;
  background: radial-gradient(
    circle at top left,
    rgba(22, 163, 74, 0.6),
    rgba(15, 23, 42, 0.98)
  );
}

.quiz-option-wrong {
  border-color: rgba(239, 68, 68, 0.95) !important;
  background: radial-gradient(
    circle at top left,
    rgba(153, 27, 27, 0.6),
    rgba(15, 23, 42, 0.98)
  );
}

.quiz-feedback {
  min-height: 1.3rem;
  font-size: 0.86rem;
  color: var(--text-soft, #9ca3af);
  margin-bottom: 0.8rem;
}

.quiz-feedback-positiv {
  color: #22c55e;
}

.quiz-feedback-negativ {
  color: #f97373;
}

.quiz-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.6rem;
}

.quiz-nav-btn {
  font-size: 0.85rem;
  padding-inline: 0.9rem;
  border-radius: 999px;
  border-width: 1px;
}

.quiz-primary {
  background: linear-gradient(135deg, #22c55e, #16a34a);
  border-color: transparent;
  color: #020617;
}

.quiz-primary:hover {
  background: linear-gradient(135deg, #4ade80, #22c55e);
}

/* Responsiv tilpasning */

@media (max-width: 640px) {
  .quiz-inner {
    padding: 1.4rem 1.2rem 1.4rem 1.2rem;
  }

  .quiz-actions {
    flex-wrap: wrap;
    justify-content: flex-start;
  }
}
