/* For-hvem · scroll-tabs + editorial stage (prod) */

.for-hvem-tabs__source.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.section_tabs_default.for-hvem-tabs {
  --fh-gold: rgba(240, 237, 232, 0.92);
  --fh-gold-dim: rgba(240, 237, 232, 0.38);
  --fh-pad-xxxl: 120px;
  --fh-max-content: 560px;
  position: relative;
  height: 680vh;
  isolation: isolate;
  background: var(--bg);
}

.for-hvem-tabs__breath {
  /* Var 20vh/120px. Sammen med at manifestets pin fader ut, ga det en død
     sone på ca. to tredjedels skjerm mellom de fire punktene og de seks
     (CEO 03.09: «det er lige et gap der»). Halvert — pusten er der ennå. */
  height: 8vh;
  min-height: 56px;
  pointer-events: none;
}

.section_tabs_default_wrap.for-hvem-tabs__wrap {
  width: 100%;
  height: calc(100vh - 112px);
  padding-top: clamp(32px, 6vh, 72px);
  padding-bottom: clamp(32px, 6vh, 72px);
  background-color: var(--bg);
  display: flex;
  justify-content: center;
  align-items: center;
  position: sticky;
  top: 112px;
  z-index: 4;
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.55s ease, transform 0.55s ease;
}

.for-hvem-tabs--ready .for-hvem-tabs__wrap {
  opacity: 1;
  transform: none;
}

.for-hvem-tabs__grain {
  pointer-events: none;
  position: absolute;
  inset: 0;
  z-index: 5;
  opacity: 0.028;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  mix-blend-mode: soft-light;
}

.wrapper.tabs_default.for-hvem-tabs__container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding-left: clamp(20px, 4vw, 40px);
  padding-right: clamp(20px, 4vw, 40px);
}

.tabs_default_body.for-hvem-tabs__grid {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) minmax(320px, 1.05fr);
  gap: clamp(24px, 4vw, 48px);
  align-items: center;
  width: 100%;
}

.tabs_default_media.for-hvem-tabs__media {
  aspect-ratio: 1;
  width: 100%;
  min-width: 260px;
  min-height: 260px;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  overflow: visible;
  align-self: center;
  justify-self: center;
}

.for-hvem-tabs__beacon-bleed {
  position: absolute;
  inset: -12%;
  z-index: 0;
  pointer-events: none;
  background: radial-gradient(circle at 50% 50%,
    rgba(240, 237, 232, 0.14) 0%,
    rgba(244, 215, 175, 0.04) 28%,
    transparent 62%);
  opacity: 0;
  transition: opacity 0.85s ease;
}

.for-hvem-tabs--match .for-hvem-tabs__beacon-bleed,
.for-hvem-tabs--pivot .for-hvem-tabs__beacon-bleed {
  opacity: 1;
}

.for-hvem-tabs--filter .for-hvem-tabs__beacon-bleed {
  opacity: 0.15;
  background: radial-gradient(circle at 50% 50%,
    rgba(240, 237, 232, 0.06) 0%,
    transparent 55%);
}

.for-hvem-tabs__canvas,
.tabs_default_img.for-hvem-tabs__spotlight {
  aspect-ratio: 1;
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.for-hvem-tabs__canvas {
  display: block;
  z-index: 0;
  background: var(--bg);
}

.tabs_default_img.for-hvem-tabs__spotlight {
  z-index: 1;
  pointer-events: none;
  background-image: radial-gradient(circle, rgba(11, 13, 18, 0) 0%, rgba(11, 13, 18, 0.97) 20%);
  background-position: center center;
  background-size: cover;
}

.for-hvem-tabs__drift {
  aspect-ratio: 1;
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 2;
  pointer-events: none;
  display: block;
}

.tabs_default_counter.heading-counter {
  position: relative;
  z-index: 3;
  font-family: var(--font-display);
  font-size: clamp(1.35rem, 2.2vw, 1.75rem);
  font-weight: 300;
  letter-spacing: 0.02em;
  line-height: 1;
  color: var(--fg);
  pointer-events: none;
}

.tabs_default_content.for-hvem-tabs__content {
  display: flex;
  flex-flow: column;
  gap: clamp(20px, 3vh, 32px);
  width: 100%;
  max-width: var(--fh-max-content);
  min-height: min(420px, 62vh);
  justify-content: center;
}

.for-hvem-tabs__intro {
  display: flex;
  flex-flow: column;
  gap: 10px;
  transition: gap 0.5s ease, opacity 0.5s ease;
}

.for-hvem-tabs--intro-collapsed .for-hvem-tabs__intro {
  gap: 6px;
}

.for-hvem-tabs--intro-collapsed .for-hvem-tabs__eyebrow {
  font-size: 9px;
  color: var(--fg-dim);
}

.for-hvem-tabs__headline {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 2.6vw, 2rem);
  font-weight: 300;
  line-height: 1.1;
  letter-spacing: -0.01em;
  color: var(--fg);
  max-width: 14ch;
  transition: font-size 0.55s ease, opacity 0.55s ease, max-width 0.55s ease;
}

.for-hvem-tabs__lede {
  font-size: 14px;
  line-height: 1.58;
  color: var(--fg-mid);
  max-width: 38ch;
  opacity: 1;
  max-height: 4.5em;
  overflow: hidden;
  transition: opacity 0.45s ease, max-height 0.45s ease, margin 0.45s ease;
}

.for-hvem-tabs--lede-hidden .for-hvem-tabs__lede {
  opacity: 0;
  max-height: 0;
  margin-top: -6px;
}

.for-hvem-tabs--intro-collapsed .for-hvem-tabs__headline {
  font-size: clamp(1rem, 1.6vw, 1.15rem);
  opacity: 0.55;
  max-width: 22ch;
}

.for-hvem-tabs__editorial {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: clamp(20px, 3vw, 32px);
  align-items: stretch;
  min-height: clamp(200px, 28vh, 280px);
}

.for-hvem-tabs__rail {
  display: flex;
  flex-direction: column;
  gap: 0;
  padding-top: 2px;
}

.for-hvem-tabs__rail-track {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  position: relative;
  padding-bottom: 4px;
}

.for-hvem-tabs__rail-track::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 4px;
  bottom: 4px;
  width: 1px;
  transform: translateX(-50%);
  background: linear-gradient(to bottom, rgba(255,255,255,0.08), rgba(255,255,255,0.04));
  pointer-events: none;
}

.for-hvem-tabs__rail-track.is-active::before {
  background: linear-gradient(to bottom, rgba(240,237,232,0.22), rgba(255,255,255,0.06));
}

.for-hvem-tabs__rail-track--filter::before {
  background: linear-gradient(to bottom, rgba(255,255,255,0.05), rgba(255,255,255,0.03));
}

.for-hvem-tabs__rail-track--filter.is-active::before {
  background: linear-gradient(to bottom, rgba(255,255,255,0.12), rgba(255,255,255,0.04));
}

.for-hvem-tabs__rail-break {
  width: 1px;
  height: 18px;
  margin: 6px auto;
  background: rgba(255, 255, 255, 0.1);
}

.for-hvem-tabs--pivot .for-hvem-tabs__rail-break {
  background: rgba(240, 237, 232, 0.35);
}

.for-hvem-tabs__rail-dot {
  position: relative;
  z-index: 1;
  display: block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  transition: background 0.35s ease, box-shadow 0.35s ease, transform 0.35s ease;
}

.for-hvem-tabs__rail-dot.is-active {
  background: rgba(255, 252, 248, 0.38);
}

.for-hvem-tabs__rail-dot.is-current {
  background: var(--fh-gold);
  transform: scale(1.35);
}

.for-hvem-tabs--filter .for-hvem-tabs__rail-track--filter .for-hvem-tabs__rail-dot.is-current {
  background: rgba(240, 237, 232, 0.88);
  box-shadow: 0 0 10px rgba(240, 237, 232, 0.15);
}

.for-hvem-tabs__stage-wrap {
  position: relative;
  min-height: clamp(200px, 28vh, 280px);
  border-left: 1px solid rgba(255, 255, 255, 0.06);
  padding-left: clamp(20px, 3vw, 28px);
}

.for-hvem-tabs__stage {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: clamp(14px, 2vh, 20px);
  padding-top: 4px;
  min-height: inherit;
  transition: opacity 0.5s ease;
}

.for-hvem-tabs--pivot .for-hvem-tabs__stage-wrap {
  border-left-color: rgba(240, 237, 232, 0.18);
}

.for-hvem-tabs__stage-eyebrow {
  font-size: 10px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--fg-dim);
  transition: color 0.4s ease;
}

.for-hvem-tabs--match .for-hvem-tabs__stage-eyebrow {
  color: var(--fh-gold-dim);
}

.for-hvem-tabs--filter .for-hvem-tabs__stage-eyebrow {
  color: rgba(240, 237, 232, 0.38);
}

.for-hvem-tabs__stage-title {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 3.2vw, 2.35rem);
  font-weight: 300;
  line-height: 1.08;
  letter-spacing: -0.015em;
  color: var(--fg);
  max-width: 16ch;
}

.for-hvem-tabs--filter .for-hvem-tabs__stage-title {
  opacity: 0.88;
  letter-spacing: 0;
}

.for-hvem-tabs__stage-body {
  font-size: clamp(14px, 1.5vw, 16px);
  line-height: 1.62;
  color: var(--fg-mid);
  max-width: 36ch;
}

.for-hvem-tabs__eyebrow {
  font-size: 10px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--fg-mid);
}

@media (max-width: 991px) {
  .section_tabs_default.for-hvem-tabs {
    height: 620vh;
  }

  .section_tabs_default_wrap.for-hvem-tabs__wrap {
    top: 56px;
    height: calc(100vh - 56px);
    padding-top: 24px;
    padding-bottom: 24px;
  }

  .for-hvem-tabs__breath {
    height: 14vh;
    min-height: 88px;
  }

  .tabs_default_body.for-hvem-tabs__grid {
    grid-template-columns: 1fr;
    display: flex;
    flex-direction: column-reverse;
    justify-content: space-between;
    gap: 20px;
    min-height: calc(100vh - 112px);
  }

  .tabs_default_media.for-hvem-tabs__media {
    width: min(68vw, 320px);
    margin-inline: auto;
    flex-shrink: 0;
  }

  .tabs_default_content.for-hvem-tabs__content {
    min-height: 0;
    flex: 1;
    justify-content: flex-start;
    gap: 16px;
  }

  .for-hvem-tabs__headline {
    max-width: none;
    font-size: 1.45rem;
  }

  .for-hvem-tabs__editorial {
    min-height: 0;
    flex: 1;
  }

  .for-hvem-tabs__stage-wrap {
    border-left: none;
    padding-left: 0;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    padding-top: 16px;
  }

  .for-hvem-tabs__stage {
    border-left: none;
    padding-left: 0;
  }

  .for-hvem-tabs__stage-title {
    max-width: none;
    font-size: 1.55rem;
  }

  .for-hvem-tabs__stage-body {
    max-width: none;
  }

  .for-hvem-tabs__lede {
    max-width: none;
    font-size: 13px;
  }

  .for-hvem-tabs__rail {
    flex-direction: row;
    align-items: flex-start;
    gap: 16px;
  }

  .for-hvem-tabs__rail-track {
    flex-direction: row;
    align-items: center;
    gap: 8px;
    padding-bottom: 0;
  }

  .for-hvem-tabs__rail-track::before {
    display: none;
  }

  .for-hvem-tabs__rail-break {
    width: 12px;
    height: 1px;
    margin: 12px 0 0;
  }

  .for-hvem-tabs__editorial {
    grid-template-columns: 1fr;
    grid-template-rows: auto 1fr;
    gap: 12px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .for-hvem-tabs__rail-dot {
    transition: none;
  }

  .for-hvem-tabs__wrap,
  .for-hvem-tabs--ready .for-hvem-tabs__wrap {
    opacity: 1;
    transform: none;
    transition: none;
  }
}
