/* ==========================================================================
   SuperFrisk – stilmall
   Struktur: tokens → bas → layout → komponenter → globala lager → effektnivåer
             → responsivt (1200 / 1024 / 768 / 480)
   Namngivning: BEM (.block__element--modifier)
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. DESIGN-TOKENS
   -------------------------------------------------------------------------- */
:root {
  color-scheme: light;

  /* Färger – ljust tema */
  --bg: #f7f8f4;
  --surface: #fdfdfb;
  --surface-2: #eef4ea;
  --ink: #16201a;
  --ink-2: #46544b;
  --muted: #74817a;
  --line: #dfe7dc;
  --accent: #1f7a4c;
  --accent-strong: #165c39;
  --accent-soft: #e3f0e6;
  --accent-text: #1a6640;
  --on-accent: #f7f8f4;
  --dark-surface: #16201a;

  /* Skuggor – tonade i varumärkets grönt, aldrig platt svart */
  --shadow-sm: 0 1px 2px rgba(22, 32, 26, 0.04), 0 4px 12px rgba(31, 122, 76, 0.06);
  --shadow-md: 0 1px 2px rgba(22, 32, 26, 0.04), 0 12px 32px rgba(31, 122, 76, 0.09);
  --shadow-lg: 0 2px 4px rgba(22, 32, 26, 0.05), 0 24px 56px rgba(31, 122, 76, 0.14);

  /* Typografi */
  --font-display: "Fraunces", "Georgia", serif;
  --font-body: "DM Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --fs-xs: 0.78rem;
  --fs-sm: 0.9rem;
  --fs-md: 1.05rem;
  --fs-lg: clamp(1.1rem, 1rem + 0.4vw, 1.25rem);
  --fs-h3: clamp(1.35rem, 1.2rem + 0.6vw, 1.7rem);
  --fs-h2: clamp(1.9rem, 1.4rem + 1.8vw, 3rem);
  --fs-h1: clamp(2.5rem, 1.6rem + 3.4vw, 4.5rem);

  /* Form och rytm */
  --radius: 4px;
  --radius-sm: 2px;
  --container: 1180px;
  --gutter: clamp(1.25rem, 4vw, 2.5rem);
  --section-y: clamp(4.5rem, 6vw + 2rem, 8rem);
  --header-h: 5rem;

  /* Rörelse */
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --t-fast: 0.2s;
  --t-med: 0.4s;
}

:root[data-theme="dark"] {
  color-scheme: dark;

  --bg: #0f1613;
  --surface: #161f1a;
  --surface-2: #1b2620;
  --ink: #eef2ee;
  --ink-2: #b9c5bc;
  --muted: #86948a;
  --line: #27332b;
  --accent: #4cc389;
  --accent-strong: #3aa873;
  --accent-soft: #1d3327;
  --accent-text: #6fd6a1;
  --on-accent: #0f1613;
  --dark-surface: #0b110e;

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3), 0 4px 12px rgba(0, 0, 0, 0.35);
  --shadow-md: 0 1px 2px rgba(0, 0, 0, 0.35), 0 12px 32px rgba(0, 0, 0, 0.45);
  --shadow-lg: 0 2px 4px rgba(0, 0, 0, 0.4), 0 24px 56px rgba(0, 0, 0, 0.55);
}

/* --------------------------------------------------------------------------
   2. BAS
   -------------------------------------------------------------------------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  overflow-x: clip;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 1rem);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100dvh;
  overflow-x: clip;
  font-family: var(--font-body);
  font-size: var(--fs-md);
  line-height: 1.6;
  color: var(--ink-2);
  background-color: var(--bg);
  -webkit-font-smoothing: antialiased;
  transition: background-color var(--t-med) ease, color var(--t-med) ease;
}

h1,
h2,
h3,
h4 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 500;
  line-height: 1.12;
  letter-spacing: -0.015em;
  color: var(--ink);
  text-wrap: balance;
}

p {
  margin: 0;
}

ul,
ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

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

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

img {
  height: auto;
}

button {
  font: inherit;
  color: inherit;
  cursor: pointer;
}

strong {
  font-weight: 600;
  color: var(--ink);
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

[hidden] {
  display: none !important;
}

.icon {
  width: 1.25em;
  height: 1.25em;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.skip-link {
  position: absolute;
  top: -100%;
  left: 1rem;
  z-index: 1000;
  padding: 0.6rem 1rem;
  background: var(--accent);
  color: var(--on-accent);
  border-radius: var(--radius);
}

.skip-link:focus {
  top: 1rem;
}

/* --------------------------------------------------------------------------
   3. LAYOUT
   -------------------------------------------------------------------------- */
.container {
  width: min(100% - 2 * var(--gutter), var(--container));
  margin-inline: auto;
}

.container--narrow {
  max-width: 760px;
}

.section {
  padding-block: var(--section-y);
}

.section--tinted {
  background-color: var(--surface-2);
  transition: background-color var(--t-med) ease;
}

.section__head {
  max-width: 640px;
  margin-bottom: clamp(2.5rem, 4vw, 4rem);
}

.section__head--center {
  margin-inline: auto;
  text-align: center;
}

.section__head--center .eyebrow {
  justify-content: center;
}

.section__title {
  font-size: var(--fs-h2);
}

.section__lead {
  margin-top: 1rem;
  font-size: var(--fs-lg);
  color: var(--muted);
}

.section__more {
  margin-top: 2.5rem;
  text-align: center;
}

/* Eyebrow – liten versal etikett med flankerande linjer */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.85rem;
  margin-bottom: 1rem;
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent-text);
}

.eyebrow::before,
.eyebrow::after {
  content: "";
  width: clamp(1.5rem, 4vw, 2.5rem);
  height: 1px;
  background: var(--accent);
  opacity: 0.55;
}

.eyebrow--light {
  color: rgba(247, 248, 244, 0.85);
}

.eyebrow--light::before,
.eyebrow--light::after {
  background: currentColor;
}

/* --------------------------------------------------------------------------
   4. KNAPPAR & LÄNKAR
   -------------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 3rem;
  padding: 0.8rem 1.6rem;
  border: 1px solid transparent;
  border-radius: var(--radius);
  font-size: var(--fs-sm);
  font-weight: 600;
  letter-spacing: 0.02em;
  line-height: 1;
  white-space: nowrap;
  transition: background-color var(--t-fast) ease, color var(--t-fast) ease, border-color var(--t-fast) ease,
    transform var(--t-fast) var(--ease), box-shadow var(--t-fast) ease;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn--primary {
  background: var(--accent);
  color: var(--on-accent);
  box-shadow: var(--shadow-sm);
}

.btn--primary:hover {
  background: var(--accent-strong);
  box-shadow: var(--shadow-md);
}

.btn--ghost {
  border-color: var(--line);
  background: var(--surface);
  color: var(--ink);
}

.btn--ghost:hover {
  border-color: var(--accent);
  color: var(--accent-text);
}

.btn--dark {
  background: var(--dark-surface);
  color: #f7f8f4;
}

.btn--dark:hover {
  background: #0b110e;
}

.btn--text {
  min-height: 2.25rem;
  padding-inline: 0.75rem;
  color: var(--muted);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.btn--text:hover {
  color: var(--ink);
  transform: none;
}

.btn--sm {
  min-height: 2.5rem;
  padding: 0.55rem 1.1rem;
  font-size: var(--fs-xs);
}

.link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-weight: 600;
  color: var(--accent-text);
  border-bottom: 1px solid currentColor;
  padding-bottom: 1px;
  transition: gap var(--t-fast) ease, color var(--t-fast) ease;
}

.link:hover {
  gap: 0.6rem;
  color: var(--accent);
}

.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--surface);
  color: var(--ink);
  transition: border-color var(--t-fast) ease, background-color var(--t-fast) ease, color var(--t-fast) ease;
}

.icon-btn:hover {
  border-color: var(--accent);
  color: var(--accent-text);
}

/* --------------------------------------------------------------------------
   5. HEADER & NAVIGATION
   -------------------------------------------------------------------------- */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--header-h);
  background: var(--bg);
  transition: background-color var(--t-med) ease, box-shadow var(--t-med) ease;
}

.header.is-scrolled {
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  box-shadow: 0 1px 0 var(--line);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  height: 100%;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
}

.brand__mark {
  display: grid;
  place-items: center;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 50%;
  background: var(--accent);
  color: var(--on-accent);
}

.brand__mark .icon {
  width: 1.2rem;
  height: 1.2rem;
}

.brand__name {
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--ink);
}

.brand__name em {
  font-style: normal;
  color: var(--accent-text);
}

.nav__list {
  display: flex;
  gap: 2rem;
}

.nav__link {
  position: relative;
  padding-block: 0.4rem;
  font-size: var(--fs-sm);
  font-weight: 500;
  color: var(--ink-2);
  transition: color var(--t-fast) ease;
}

.nav__link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--t-fast) var(--ease);
}

.nav__link:hover,
.nav__link.is-active {
  color: var(--ink);
}

.nav__link:hover::after,
.nav__link.is-active::after {
  transform: scaleX(1);
}

.header__actions {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.theme-toggle__sun,
:root[data-theme="dark"] .theme-toggle__moon {
  display: none;
}

:root[data-theme="dark"] .theme-toggle__sun {
  display: block;
}

.nav-toggle {
  display: none;
}

/* Mobilpanel (slide-in från höger) */
.nav-backdrop {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(15, 22, 19, 0.45);
  opacity: 0;
  transition: opacity var(--t-med) ease;
}

.nav-panel {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 210;
  width: min(22rem, 100%);
  height: 100dvh;
  display: flex;
  flex-direction: column;
  padding: 1.25rem var(--gutter) 2rem;
  background: var(--surface);
  box-shadow: var(--shadow-lg);
  transform: translateX(100%);
  transition: transform var(--t-med) var(--ease);
}

.nav-backdrop.is-open,
.nav-panel.is-open {
  opacity: 1;
  transform: none;
}

.nav-panel__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2rem;
}

.nav-panel__title {
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}

.nav-panel__list {
  display: grid;
  gap: 0.25rem;
}

.nav-panel__link {
  display: block;
  padding: 0.85rem 0;
  font-family: var(--font-display);
  font-size: 1.6rem;
  color: var(--ink);
  border-bottom: 1px solid var(--line);
}

.nav-panel__cta {
  margin-top: 2rem;
}

.nav-panel__foot {
  margin-top: auto;
  font-size: var(--fs-sm);
  color: var(--muted);
}

body.nav-locked {
  overflow: hidden;
}

/* --------------------------------------------------------------------------
   6. HERO
   -------------------------------------------------------------------------- */
.hero {
  padding-block: clamp(2rem, 4vw, 4rem) var(--section-y);
}

.hero__grid {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: clamp(2.5rem, 6vw, 6rem);
  align-items: center;
}

.hero__title {
  font-size: var(--fs-h1);
  margin-bottom: 1.5rem;
}

.hero__title-accent {
  font-style: italic;
  color: var(--accent-text);
}

.hero__lead {
  max-width: 34rem;
  font-size: var(--fs-lg);
  color: var(--ink-2);
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 2.25rem;
}

.hero__proof {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-top: 3rem;
}

.avatars {
  display: flex;
}

.avatars img {
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 50%;
  border: 2px solid var(--bg);
  object-fit: cover;
}

.avatars li + li {
  margin-left: -0.75rem;
}

.hero__proof-text {
  font-size: var(--fs-sm);
  color: var(--muted);
}

.hero__proof-text strong {
  color: var(--accent-text);
}

.hero__media {
  position: relative;
  margin: 0;
}

.hero__media::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: var(--radius);
  background: var(--accent-soft);
  transform: translate(1.25rem, 1.25rem);
}

.hero__img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
}

.hero__badge {
  position: absolute;
  left: -1.5rem;
  bottom: 2rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.9rem 1.1rem;
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-md);
  font-size: var(--fs-xs);
  line-height: 1.35;
  color: var(--muted);
}

.hero__badge .icon {
  width: 1.6rem;
  height: 1.6rem;
  color: var(--accent);
}

.hero__badge strong {
  display: block;
  font-size: var(--fs-sm);
}

/* --------------------------------------------------------------------------
   7. PELARE (ikonrad)
   -------------------------------------------------------------------------- */
.pillars {
  padding-block: 1rem var(--section-y);
}

.pillars__title {
  margin-bottom: 2rem;
  font-family: var(--font-body);
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-align: center;
  color: var(--muted);
}

.pillars__list {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 1rem;
}

.pillar {
  display: grid;
  justify-items: center;
  gap: 0.75rem;
}

.pillar__icon {
  position: relative;
  width: clamp(3.5rem, 6vw, 5rem);
  aspect-ratio: 1;
}

.pillar__icon img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  opacity: 0.55;
  transition: opacity var(--t-med) ease;
}

.pillar__icon-color {
  opacity: 0 !important;
}

.pillar:hover .pillar__icon img {
  opacity: 0;
}

.pillar:hover .pillar__icon-color {
  opacity: 1 !important;
}

:root[data-theme="dark"] .pillar__icon img:not(.pillar__icon-color) {
  filter: invert(1);
}

.pillar__label {
  font-size: var(--fs-sm);
  font-weight: 500;
  color: var(--ink-2);
}

/* --------------------------------------------------------------------------
   8. SÅ FUNKAR DET (steg)
   -------------------------------------------------------------------------- */
.steps {
  display: grid;
  gap: clamp(3rem, 6vw, 6rem);
}

.step {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 5vw, 5rem);
  align-items: center;
}

.step:nth-child(even) .step__text {
  order: 2;
}

.step__number {
  display: block;
  margin-bottom: 0.75rem;
  font-family: var(--font-display);
  font-size: 3.5rem;
  font-weight: 500;
  line-height: 1;
  color: var(--accent);
  opacity: 0.35;
}

.step__title {
  font-size: var(--fs-h3);
  margin-bottom: 1rem;
}

.step__text p {
  max-width: 30rem;
}

.step__media {
  margin: 0;
  overflow: hidden;
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
}

.step__media img {
  width: 100%;
  aspect-ratio: 9 / 7;
  object-fit: cover;
  transition: transform 0.8s var(--ease);
}

.step:hover .step__media img {
  transform: scale(1.03);
}

/* --------------------------------------------------------------------------
   9. RECEPT
   -------------------------------------------------------------------------- */
.recipe-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.75rem;
}

.recipe {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  transition: transform var(--t-med) var(--ease), box-shadow var(--t-med) ease;
}

.recipe:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.recipe__media {
  position: relative;
  overflow: hidden;
}

.recipe__media img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  transition: transform 0.8s var(--ease);
}

.recipe:hover .recipe__media img {
  transform: scale(1.03);
}

.recipe__score {
  position: absolute;
  top: 0.9rem;
  left: 0.9rem;
  display: grid;
  place-items: center;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  background: #1f7a4c;
  color: #f7f8f4;
  font-size: var(--fs-sm);
  font-weight: 700;
}

.recipe__score--b {
  background: #7fb241;
  color: #16201a;
}

.recipe__body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 1.25rem 1.5rem 1.5rem;
}

.recipe__body .recipe__meta {
  margin-top: auto;
}

.recipe__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 0.75rem;
}

.tag {
  padding: 0.25rem 0.6rem;
  border-radius: var(--radius-sm);
  background: var(--accent-soft);
  color: var(--accent-text);
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.recipe__title {
  font-size: 1.25rem;
  margin-bottom: 1rem;
}

.recipe__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
  font-size: var(--fs-sm);
  color: var(--muted);
}

.recipe__meta li {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.recipe__meta .icon {
  color: var(--accent);
}

.recipe__count {
  color: var(--muted);
  opacity: 0.8;
}

/* --------------------------------------------------------------------------
   10. MEDLEMMAR + GALLERI
   -------------------------------------------------------------------------- */
.stories__grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: clamp(2.5rem, 5vw, 5rem);
  align-items: center;
}

.quotes {
  display: grid;
  gap: 1.5rem;
}

.quote {
  margin: 0;
  padding: 1.5rem 1.75rem;
  border-left: 2px solid var(--accent);
  background: var(--surface);
  border-radius: 0 var(--radius) var(--radius) 0;
  box-shadow: var(--shadow-sm);
}

.quote blockquote {
  margin: 0 0 1rem;
  font-family: var(--font-display);
  font-size: 1.15rem;
  line-height: 1.5;
  color: var(--ink);
}

.quote figcaption {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: var(--fs-sm);
  color: var(--muted);
}

.quote figcaption img {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  object-fit: cover;
}

.gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
}

.gallery li {
  overflow: hidden;
  border-radius: var(--radius);
}

.gallery img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  transition: transform 0.8s var(--ease);
}

.gallery li:hover img {
  transform: scale(1.04);
}

/* --------------------------------------------------------------------------
   11. TEAM + VETENSKAP
   -------------------------------------------------------------------------- */
.team__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  margin-bottom: clamp(3rem, 5vw, 5rem);
}

.member {
  text-align: center;
}

.member__photo {
  width: 7.5rem;
  height: 7.5rem;
  margin: 0 auto 1.25rem;
  border-radius: 50%;
  object-fit: cover;
  box-shadow: var(--shadow-md);
}

.member__name {
  font-size: 1.3rem;
}

.member__role {
  margin: 0.25rem 0 0.9rem;
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-text);
}

.member__bio {
  max-width: 20rem;
  margin-inline: auto;
  font-size: var(--fs-sm);
}

.science {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 3rem;
  align-items: center;
  padding: clamp(1.75rem, 4vw, 3rem);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.science__title {
  font-size: var(--fs-h3);
  margin-bottom: 1rem;
}

.science__links {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-top: 1.5rem;
  font-size: var(--fs-sm);
}

.science__badges {
  display: grid;
  gap: 1rem;
}

.science__badges li {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-weight: 500;
  color: var(--ink);
}

.science__badges .icon {
  width: 1.6rem;
  height: 1.6rem;
  color: var(--accent);
}

/* --------------------------------------------------------------------------
   12. PRIS
   -------------------------------------------------------------------------- */
.plans {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  align-items: stretch;
}

.plan {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 2.25rem 2rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  transition: transform var(--t-med) var(--ease), box-shadow var(--t-med) ease;
}

.plan:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.plan--featured {
  border-color: var(--accent);
  box-shadow: var(--shadow-md);
}

.plan__badge {
  position: absolute;
  top: -0.8rem;
  left: 50%;
  transform: translateX(-50%);
  padding: 0.3rem 0.9rem;
  border-radius: var(--radius-sm);
  background: var(--accent);
  color: var(--on-accent);
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.plan__head {
  padding-bottom: 1.5rem;
  margin-bottom: 1.5rem;
  border-bottom: 1px solid var(--line);
}

.plan__name {
  font-family: var(--font-body);
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent-text);
}

.plan__price {
  display: flex;
  align-items: baseline;
  gap: 0.4rem;
  margin: 0.75rem 0 0.5rem;
  font-family: var(--font-display);
  font-size: 2.6rem;
  line-height: 1;
  color: var(--ink);
}

.plan__from,
.plan__unit {
  font-family: var(--font-body);
  font-size: var(--fs-sm);
  color: var(--muted);
}

.plan__desc {
  font-size: var(--fs-sm);
  color: var(--muted);
}

.plan__list {
  display: grid;
  gap: 0.8rem;
  flex: 1;
}

.plan__list li {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: var(--fs-sm);
}

.plan__list .icon {
  color: var(--accent);
}

.plan__item--off {
  color: var(--muted);
  opacity: 0.7;
}

.plan__item--off .icon {
  color: var(--muted);
}

.plan__cta {
  margin-top: 2rem;
  width: 100%;
}

.plans__note {
  margin-top: 1.5rem;
  text-align: center;
  font-size: var(--fs-sm);
  color: var(--muted);
}

.features {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
  margin-top: clamp(3.5rem, 6vw, 6rem);
}

.feature p {
  font-size: var(--fs-sm);
}

.feature__icon {
  display: grid;
  place-items: center;
  width: 3rem;
  height: 3rem;
  margin-bottom: 1.25rem;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent-text);
}

.feature__icon .icon {
  width: 1.4rem;
  height: 1.4rem;
}

.feature__title {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
}

/* --------------------------------------------------------------------------
   13. FAQ (nativ <details>)
   -------------------------------------------------------------------------- */
.accordion {
  display: grid;
  gap: 0.75rem;
}

.accordion__item {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  transition: box-shadow var(--t-fast) ease;
}

.accordion__item[open] {
  box-shadow: var(--shadow-sm);
}

.accordion__summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.15rem 1.4rem;
  font-weight: 500;
  color: var(--ink);
  cursor: pointer;
  list-style: none;
}

.accordion__summary::-webkit-details-marker {
  display: none;
}

.accordion__icon {
  color: var(--accent);
  transition: transform var(--t-med) var(--ease);
}

.accordion__item[open] .accordion__icon {
  transform: rotate(45deg);
}

.accordion__body {
  padding: 0 1.4rem 1.25rem;
  font-size: var(--fs-sm);
  animation: accordion-in var(--t-med) var(--ease);
}

@keyframes accordion-in {
  from {
    opacity: 0;
    translate: 0 -4px;
  }
}

/* --------------------------------------------------------------------------
   14. CTA + FORMULÄR
   -------------------------------------------------------------------------- */
.cta__card {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  overflow: hidden;
  border-radius: var(--radius);
  background: linear-gradient(135deg, var(--accent-strong), var(--accent));
  color: rgba(247, 248, 244, 0.9);
  box-shadow: var(--shadow-lg);
}

:root[data-theme="dark"] .cta__card {
  background: linear-gradient(135deg, #17583a, #1f7a4c);
}

.cta__text {
  padding: clamp(2rem, 4vw, 3.5rem);
}

.cta__title {
  color: #f7f8f4;
  font-size: var(--fs-h2);
  margin-bottom: 1rem;
}

.cta__lead {
  max-width: 32rem;
  margin-bottom: 2rem;
}

.cta__media {
  margin: 0;
}

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

.form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
}

.form__field label {
  display: block;
  margin-bottom: 0.4rem;
  font-size: var(--fs-sm);
  font-weight: 600;
  color: #f7f8f4;
}

.form__field input,
.form__field select {
  width: 100%;
  min-height: 3rem;
  padding: 0.7rem 0.9rem;
  border: 1px solid rgba(247, 248, 244, 0.25);
  border-radius: var(--radius);
  background: rgba(247, 248, 244, 0.95);
  color: #16201a;
  font: inherit;
  font-size: var(--fs-sm);
}

.form__field input::placeholder {
  color: #74817a;
}

.form__field input:focus-visible,
.form__field select:focus-visible {
  outline-color: #f7f8f4;
}

.form__field--submit {
  display: flex;
  align-items: end;
}

.form__field--submit .btn {
  width: 100%;
}

.form__note {
  grid-column: 1 / -1;
  font-size: var(--fs-xs);
  opacity: 0.75;
}

/* --------------------------------------------------------------------------
   15. FOOTER
   -------------------------------------------------------------------------- */
.footer {
  padding-block: var(--section-y) 2rem;
  border-top: 1px solid var(--line);
  font-size: var(--fs-sm);
}

.footer__grid {
  display: grid;
  grid-template-columns: 1.6fr repeat(4, 1fr);
  gap: 2.5rem;
}

.footer__tagline {
  max-width: 20rem;
  margin: 1.25rem 0 1.5rem;
  color: var(--muted);
}

.social {
  display: flex;
  gap: 0.75rem;
}

.social a {
  display: grid;
  place-items: center;
  width: 2.5rem;
  height: 2.5rem;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--muted);
  transition: color var(--t-fast) ease, border-color var(--t-fast) ease;
}

.social a:hover {
  color: var(--accent-text);
  border-color: var(--accent);
}

.footer__heading {
  margin-bottom: 1.25rem;
  font-family: var(--font-body);
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink);
}

.footer__col ul {
  display: grid;
  gap: 0.7rem;
}

.footer__col a,
.footer__address {
  color: var(--muted);
  font-style: normal;
  line-height: 1.8;
  transition: color var(--t-fast) ease;
}

.footer__col a:hover {
  color: var(--accent-text);
}

.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem;
  margin-top: 3.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--line);
  font-size: var(--fs-xs);
  color: var(--muted);
}

/* --------------------------------------------------------------------------
   16. GLOBALA LAGER: toast, cookies, effektnivå, prestandatips
   -------------------------------------------------------------------------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: 1.5rem;
  z-index: 1000;
  max-width: calc(100% - 2rem);
  padding: 0.9rem 1.4rem;
  border-radius: var(--radius);
  background: var(--ink);
  color: var(--bg);
  font-size: var(--fs-sm);
  font-weight: 500;
  text-align: center;
  box-shadow: var(--shadow-lg);
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 1rem);
  transition: opacity var(--t-med) ease, transform var(--t-med) var(--ease);
}

.toast.is-visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

.cookie,
.perf-hint {
  position: fixed;
  left: 50%;
  bottom: 1.25rem;
  z-index: 900;
  width: min(30rem, calc(100% - 2rem));
  padding: 1.25rem 1.5rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
  font-size: var(--fs-sm);
  transform: translate(-50%, 1rem);
  opacity: 0;
  transition: opacity var(--t-med) ease, transform var(--t-med) var(--ease);
}

.cookie.is-visible,
.perf-hint.is-visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

.cookie__actions,
.perf-hint__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  margin-top: 1rem;
}

/* Effektväljare – nere till vänster (chatten äger högerhörnet) */
.fx {
  position: fixed;
  left: 1.25rem;
  bottom: 1.25rem;
  z-index: 850;
}

.fx__toggle {
  display: grid;
  place-items: center;
  width: 3.25rem;
  height: 3.25rem;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow-md);
  transition: border-color var(--t-fast) ease, color var(--t-fast) ease, transform var(--t-fast) var(--ease);
}

.fx__toggle:hover {
  border-color: var(--accent);
  color: var(--accent-text);
  transform: translateY(-2px);
}

.fx__toggle .icon {
  width: 1.3rem;
  height: 1.3rem;
}

.fx__menu {
  position: absolute;
  left: 0;
  bottom: calc(100% + 0.75rem);
  width: 18rem;
  padding: 0.75rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
  display: grid;
  gap: 0.25rem;
}

.fx__title {
  padding: 0.25rem 0.6rem 0.6rem;
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}

.fx__option {
  display: grid;
  gap: 0.15rem;
  padding: 0.65rem 0.75rem;
  border: 1px solid transparent;
  border-radius: var(--radius);
  background: none;
  text-align: left;
  transition: background-color var(--t-fast) ease, border-color var(--t-fast) ease;
}

.fx__option:hover {
  background: var(--surface-2);
}

.fx__option[aria-checked="true"] {
  border-color: var(--accent);
  background: var(--accent-soft);
}

.fx__name {
  display: flex;
  justify-content: space-between;
  font-weight: 600;
  color: var(--ink);
}

.fx__option[aria-checked="true"] .fx__name::after {
  content: "✓";
  color: var(--accent-text);
}

.fx__desc {
  font-size: var(--fs-xs);
  color: var(--muted);
}

.fx__auto {
  margin-top: 0.25rem;
  padding: 0.5rem 0.75rem;
  border: none;
  background: none;
  font-size: var(--fs-xs);
  color: var(--muted);
  text-align: left;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.fx__auto:hover {
  color: var(--ink);
}

/* --------------------------------------------------------------------------
   17. CHATT – VERA (hälsoguide)
   -------------------------------------------------------------------------- */
.chat-fab {
  position: fixed;
  right: 1.25rem;
  bottom: 1.25rem;
  z-index: 850;
  display: grid;
  place-items: center;
  width: 3.5rem;
  height: 3.5rem;
  border: none;
  border-radius: 50%;
  background: var(--accent);
  color: var(--on-accent);
  box-shadow: var(--shadow-lg);
  transition: transform var(--t-fast) var(--ease), background-color var(--t-fast) ease;
}

.chat-fab:hover {
  background: var(--accent-strong);
  transform: translateY(-2px);
}

.chat-fab .icon {
  width: 1.4rem;
  height: 1.4rem;
}

.chat-fab__tip {
  position: absolute;
  right: calc(100% + 0.75rem);
  top: 50%;
  transform: translateY(-50%);
  padding: 0.4rem 0.75rem;
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink);
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
  box-shadow: var(--shadow-md);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--t-fast) ease;
}

.chat-fab:hover .chat-fab__tip {
  opacity: 1;
}

.chat {
  position: fixed;
  right: 1.25rem;
  bottom: 1.25rem;
  z-index: 950;
  display: flex;
  flex-direction: column;
  width: min(24rem, calc(100vw - 2rem));
  height: min(36rem, calc(100dvh - 3rem));
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
}

.chat__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.9rem 1rem;
  background: var(--dark-surface);
  color: #f7f8f4;
}

.chat__id {
  display: flex;
  align-items: center;
  gap: 0.7rem;
}

.chat__orb {
  display: grid;
  place-items: center;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 50%;
  background: var(--accent);
  color: var(--on-accent);
}

.chat__orb .icon {
  width: 1.1rem;
  height: 1.1rem;
}

.chat__name {
  font-family: var(--font-display);
  font-size: 1.1rem;
  color: #f7f8f4;
}

.chat__status {
  font-size: var(--fs-xs);
  letter-spacing: 0.06em;
  opacity: 0.65;
}

.chat__actions {
  display: flex;
}

.chat__iconbtn {
  display: grid;
  place-items: center;
  width: 2.25rem;
  height: 2.25rem;
  border: none;
  border-radius: var(--radius);
  background: none;
  color: rgba(247, 248, 244, 0.7);
  transition: color var(--t-fast) ease;
}

.chat__iconbtn:hover {
  color: #f7f8f4;
}

.chat__box {
  flex: 1;
  overflow-y: auto;
  padding: 1rem;
  scroll-behavior: smooth;
}

.chat__welcome {
  padding: 1.5rem 0.75rem;
  text-align: center;
}

.chat__welcome .chat__orb {
  width: 3rem;
  height: 3rem;
  margin: 0 auto 0.75rem;
}

.chat__welcome h4 {
  font-size: 1.2rem;
  margin-bottom: 0.4rem;
}

.chat__welcome p {
  font-size: var(--fs-sm);
  color: var(--muted);
}

.chat__msg {
  display: flex;
  margin-bottom: 0.7rem;
}

.chat__msg--user {
  justify-content: flex-end;
}

.chat__bubble {
  max-width: 85%;
  padding: 0.65rem 0.9rem;
  border-radius: var(--radius);
  font-size: var(--fs-sm);
  line-height: 1.55;
}

.chat__msg--user .chat__bubble {
  background: var(--accent);
  color: var(--on-accent);
}

.chat__msg--bot .chat__bubble {
  background: var(--surface-2);
  color: var(--ink);
}

.chat__bubble strong {
  color: var(--accent-text);
}

.chat__msg--user .chat__bubble strong {
  color: inherit;
}

.chat__typing {
  display: flex;
  gap: 4px;
  padding: 0.5rem 0.4rem;
}

.chat__typing span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  animation: typing 1.2s ease-in-out infinite;
}

.chat__typing span:nth-child(2) {
  animation-delay: 0.18s;
}

.chat__typing span:nth-child(3) {
  animation-delay: 0.36s;
}

@keyframes typing {
  0%,
  60%,
  100% {
    transform: translateY(0);
    opacity: 0.4;
  }
  30% {
    transform: translateY(-5px);
    opacity: 1;
  }
}

.chat__suggest {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  padding: 0 1rem 0.75rem;
}

.chat__chip {
  padding: 0.4rem 0.75rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: none;
  font-size: var(--fs-xs);
  color: var(--ink);
  transition: border-color var(--t-fast) ease, background-color var(--t-fast) ease;
}

.chat__chip:hover {
  border-color: var(--accent);
  background: var(--accent-soft);
}

.chat__inputrow {
  display: flex;
  align-items: flex-end;
  gap: 0.5rem;
  padding: 0.7rem;
  border-top: 1px solid var(--line);
}

.chat__inputrow textarea {
  flex: 1;
  max-height: 6rem;
  padding: 0.5rem 0.4rem;
  border: none;
  background: none;
  color: var(--ink);
  font: inherit;
  font-size: var(--fs-sm);
  resize: none;
}

.chat__inputrow textarea:focus-visible {
  outline: none;
}

.chat__send {
  display: grid;
  place-items: center;
  width: 2.5rem;
  height: 2.5rem;
  flex: none;
  border: none;
  border-radius: var(--radius);
  background: var(--accent);
  color: var(--on-accent);
  transition: opacity var(--t-fast) ease;
}

.chat__send:disabled {
  opacity: 0.35;
  cursor: default;
}

.chat__disclaimer {
  padding: 0 0.9rem 0.6rem;
  font-size: 0.7rem;
  color: var(--muted);
  text-align: center;
}

/* --------------------------------------------------------------------------
   18. EFFEKTNIVÅER (data-perf på <html>)
   Essential = nästan statisk · Balanced = mjuka reveals · Cinematic = allt
   -------------------------------------------------------------------------- */
:root[data-perf="essential"] {
  scroll-behavior: auto;
}

:root[data-perf="essential"] [data-aos] {
  opacity: 1 !important;
  transform: none !important;
  transition: none !important;
}

:root[data-perf="essential"] .header.is-scrolled {
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
  background: var(--bg);
}

:root[data-perf="essential"] .step__media img,
:root[data-perf="essential"] .recipe__media img,
:root[data-perf="essential"] .gallery img,
:root[data-perf="essential"] .recipe,
:root[data-perf="essential"] .plan,
:root[data-perf="essential"] .btn,
:root[data-perf="essential"] .pillar__icon img {
  transition: none;
}

:root[data-perf="essential"] .step:hover .step__media img,
:root[data-perf="essential"] .recipe:hover .recipe__media img,
:root[data-perf="essential"] .gallery li:hover img,
:root[data-perf="essential"] .recipe:hover,
:root[data-perf="essential"] .plan:hover,
:root[data-perf="essential"] .btn:hover {
  transform: none;
}

:root[data-perf="essential"] .chat__typing span {
  animation: none;
  opacity: 0.7;
}

/* Cinematic: hero-bilden svävar lätt (parallax sköts i JS) */
:root[data-perf="cinematic"] .hero__media {
  will-change: transform;
}

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

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

/* --------------------------------------------------------------------------
   19. RESPONSIVT – 1200 / 1024 / 768 / 480
   -------------------------------------------------------------------------- */
@media (max-width: 1200px) {
  .pillars__list {
    grid-template-columns: repeat(3, 1fr);
    row-gap: 2rem;
  }

  .footer__grid {
    grid-template-columns: 1.4fr repeat(2, 1fr);
  }

  .footer__grid .footer__col:nth-child(4),
  .footer__grid .footer__col:nth-child(5) {
    grid-column: auto;
  }
}

@media (max-width: 1024px) {
  .nav,
  .header__cta {
    display: none;
  }

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

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

  .hero__media {
    max-width: 30rem;
    margin-inline: auto;
  }

  .hero__badge {
    left: 1rem;
  }

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

  .recipe-grid,
  .team__grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .recipe-grid .recipe:last-child {
    grid-column: 1 / -1;
    max-width: 50%;
    margin-inline: auto;
  }

  .plans {
    grid-template-columns: 1fr;
    max-width: 30rem;
    margin-inline: auto;
  }

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

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

  .science__badges {
    grid-template-columns: repeat(3, auto);
  }

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

  .cta__media {
    order: -1;
    max-height: 18rem;
  }
}

@media (max-width: 768px) {
  :root {
    --header-h: 4.25rem;
  }

  .step {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .step:nth-child(even) .step__text {
    order: 0;
  }

  .step__media {
    order: -1;
  }

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

  .recipe-grid .recipe:last-child {
    max-width: none;
  }

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

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

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

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

  .footer__brand {
    grid-column: 1 / -1;
  }

  .fx,
  .chat-fab {
    bottom: 1rem;
  }

  .fx {
    left: 1rem;
  }

  .chat-fab {
    right: 1rem;
  }

  .chat {
    right: 0.75rem;
    bottom: 0.75rem;
    width: calc(100vw - 1.5rem);
    height: min(34rem, calc(100dvh - 1.5rem));
  }
}

@media (max-width: 480px) {
  .hero__actions .btn {
    flex: 1 1 100%;
  }

  .hero__proof {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
  }

  .hero__badge {
    left: 0.75rem;
    right: 0.75rem;
    bottom: 0.75rem;
  }

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

  .features,
  .footer__grid {
    grid-template-columns: 1fr;
  }

  .gallery {
    gap: 0.5rem;
  }

  .fx__menu {
    width: min(18rem, calc(100vw - 2rem));
  }
}

/* Hover-effekter ska inte fastna på pekskärm */
@media (hover: none) {
  .pillar .pillar__icon img {
    opacity: 0.85;
  }

  .step:hover .step__media img,
  .recipe:hover .recipe__media img,
  .gallery li:hover img {
    transform: none;
  }
}
