/* ---------------------------------------------------------------
   Lekseboka – lys, moderne og pastell. Hvert fag har sin egen farge.
   Fagfargen sendes inn som --sc, og bakgrunner lages av den med
   color-mix, slik at det virker i både lyst og mørkt tema.
   --------------------------------------------------------------- */

:root {
  --bg: #fcfbff;
  --card: #ffffff;
  --text: #2c2837;
  --muted: #9a95a8;
  --line: #f1eef8;

  --accent: #ff8a70;
  --accent-ink: #ee6a4d;

  /* Pastellfargene er lyse, så tekst i fagfargen blandes mot denne for å
     holde seg lesbar. I mørkt tema blandes den motsatt vei. */
  --ink: #2c2837;

  --radius: 20px;
  --shadow: 0 1px 3px rgba(44, 40, 55, .03), 0 10px 26px rgba(44, 40, 55, .045);
  --shadow-lift: 0 8px 22px rgba(255, 138, 112, .32);

  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, sans-serif;
  --tabbar-h: 76px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #121116;
    --card: #1c1b22;
    --text: #f1eff5;
    --muted: #97939f;
    --line: #2a2831;

    --accent: #ff8a70;
    --accent-ink: #ffa088;

    --ink: #ffffff;

    --shadow: 0 2px 6px rgba(0, 0, 0, .35), 0 12px 28px rgba(0, 0, 0, .3);
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  padding: 0 0 calc(var(--tabbar-h) + env(safe-area-inset-bottom) + 24px);
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}

h1, h2, h3 { margin: 0; font-weight: 700; letter-spacing: -.02em; }

/* ---------------------------------------------------------- topp */
.topbar {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  padding: max(18px, env(safe-area-inset-top)) 20px 16px;
  max-width: 640px;
  margin: 0 auto;
}

.topbar h1 { font-size: 1.75rem; line-height: 1.1; }

.today-line {
  font-size: .72rem;
  color: var(--muted);
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
  margin-bottom: 4px;
}

main { max-width: 640px; margin: 0 auto; padding: 0 20px; }

.view { display: none; }
.view.active { display: block; }

.section-title {
  font-size: .78rem;
  font-weight: 700;
  color: var(--muted);
  letter-spacing: .1em;
  text-transform: uppercase;
  margin: 22px 0 10px 4px;
}

.section-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 22px 0 12px; }
.section-row .section-title { margin: 0 0 0 4px; }

/* ---------------------------------------------------------- kort */
.card {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 18px;
  margin-bottom: 14px;
}

/* ---------------------------------------------------------- knapper */
.pill-btn, .ghost-btn, .nav-btn, .link-btn, .back-btn, .round-btn, .start-big {
  font: inherit;
  cursor: pointer;
  border: 0;
  border-radius: 999px;
}

.pill-btn {
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  font-size: .92rem;
  padding: 11px 20px;
}
.pill-btn:active { transform: scale(.97); }
.pill-btn.small { padding: 8px 15px; font-size: .84rem; }
.pill-btn.wide { width: 100%; margin-top: 4px; }

.ghost-btn {
  background: transparent;
  color: var(--muted);
  border: 1.5px solid var(--line);
  padding: 10px 18px;
  font-size: .9rem;
  font-weight: 600;
}
.ghost-btn.wide { width: 100%; margin-top: 12px; }
.ghost-btn:active { transform: scale(.97); }

.round-btn {
  background: var(--card);
  color: var(--text);
  box-shadow: var(--shadow);
  width: 42px; height: 42px;
  font-size: 1.3rem;
  line-height: 1;
}

.nav-btn { background: transparent; color: var(--muted); font-size: 1.4rem; line-height: 1; padding: 4px 12px; }
.nav-btn:active { color: var(--accent); }

.link-btn {
  background: transparent; color: var(--accent); font-size: .78rem;
  font-weight: 700; letter-spacing: .05em; text-transform: uppercase; padding: 3px 8px;
}

.back-btn {
  background: transparent; color: var(--muted);
  font-size: .9rem; font-weight: 600; padding: 4px 2px; margin-bottom: 10px;
}

/* ---------------------------------------------------------- bunnmeny */
.tabbar {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  height: calc(var(--tabbar-h) + env(safe-area-inset-bottom));
  padding-bottom: env(safe-area-inset-bottom);
  background: color-mix(in srgb, var(--card) 88%, transparent);
  backdrop-filter: blur(18px);
  border-top: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-around;
  z-index: 40;
}

.tabbar .tab {
  flex: 1;
  border: 0;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: .64rem;
  font-weight: 600;
  letter-spacing: .02em;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 8px 0;
}

.tabbar .tab svg {
  width: 23px; height: 23px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.tabbar .tab.active { color: var(--accent); }

.record {
  flex: none;
  width: 66px; height: 66px;
  margin-top: -26px;
  border: 0;
  border-radius: 50%;
  background: linear-gradient(150deg, #ffa88f, var(--accent));
  box-shadow: var(--shadow-lift);
  color: #fff;
  cursor: pointer;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.record:active { transform: scale(.95); }

.record-inner {
  font-family: var(--font);
  font-size: .82rem;
  font-weight: 800;
  letter-spacing: .02em;
  font-variant-numeric: tabular-nums;
}

.record.running { animation: pulse 2s ease-in-out infinite; }

@keyframes pulse {
  0%, 100% { box-shadow: 0 8px 22px rgba(255, 138, 112, .32); }
  50%      { box-shadow: 0 8px 32px rgba(255, 138, 112, .6); }
}

/* ---------------------------------------------------------- hjem */
.hero { padding: 20px; }
.hero-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; margin-bottom: 18px; }
.hero-label { font-size: .72rem; font-weight: 700; color: var(--muted); letter-spacing: .1em; text-transform: uppercase; }
.hero-value { font-size: 2.4rem; font-weight: 800; letter-spacing: -.035em; line-height: 1.1; margin-top: 2px; }

.streak {
  background: color-mix(in srgb, var(--accent) 14%, transparent);
  color: var(--accent-ink);
  border-radius: 14px;
  padding: 8px 12px;
  font-size: .78rem;
  font-weight: 700;
  text-align: center;
  white-space: nowrap;
}

/* neste prøve */
.next-test {
  --sc: var(--accent);
  background: color-mix(in srgb, var(--sc) 16%, var(--card));
  border-radius: var(--radius);
  padding: 18px;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 16px;
  cursor: pointer;
  text-align: left;
  font: inherit;
  color: var(--text);
  border: 0;
  width: 100%;
}
.next-test .countdown {
  background: var(--card);
  border-radius: 15px;
  padding: 10px 14px;
  text-align: center;
  flex: none;
  min-width: 62px;
}
.next-test .countdown b { display: block; font-size: 1.45rem; font-weight: 800; line-height: 1.1; letter-spacing: -.03em; }
.next-test .countdown span { font-size: .62rem; font-weight: 700; color: var(--muted); letter-spacing: .08em; text-transform: uppercase; }
.next-test .nt-label { font-size: .68rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: color-mix(in srgb, var(--sc) 72%, var(--ink)); }
.next-test .nt-title { font-weight: 700; margin: 2px 0; }
.next-test .nt-meta { font-size: .82rem; color: var(--muted); }

/* ---------------------------------------------------------- fagbrikker */
.chip {
  --sc: var(--muted);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: color-mix(in srgb, var(--sc) 18%, transparent);
  color: color-mix(in srgb, var(--sc) 72%, var(--ink));
  border-radius: 999px;
  padding: 3px 11px;
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .01em;
  max-width: 100%;
}
.chip.big { font-size: 1.05rem; padding: 8px 18px; border-radius: 16px; margin-bottom: 16px; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-bottom: 22px; }

.chip-btn {
  --sc: var(--muted);
  border: 1.5px solid transparent;
  background: color-mix(in srgb, var(--sc) 15%, transparent);
  color: color-mix(in srgb, var(--sc) 72%, var(--ink));
  font: inherit;
  font-size: .84rem;
  font-weight: 700;
  border-radius: 999px;
  padding: 8px 15px;
  cursor: pointer;
}
.chip-btn.on { border-color: color-mix(in srgb, var(--sc) 72%, var(--ink)); background: color-mix(in srgb, var(--sc) 26%, transparent); }
.chip-btn:disabled { opacity: .35; cursor: default; }

/* ---------------------------------------------------------- kalender */
.cal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.cal-title { display: flex; align-items: center; gap: 8px; }
.cal-title strong { font-size: 1.1rem; font-weight: 700; letter-spacing: -.02em; text-transform: capitalize; }

.weekdays, .calendar { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; }

.weekdays span {
  text-align: center; font-size: .66rem; color: var(--muted);
  font-weight: 700; text-transform: uppercase; letter-spacing: .1em; padding-bottom: 8px;
}

.day {
  aspect-ratio: 1 / 1;
  border: 0; background: transparent;
  border-radius: 14px;
  color: var(--text); font: inherit; font-size: .92rem; font-weight: 500;
  cursor: pointer;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  padding: 0;
}

.day.other { color: var(--muted); opacity: .35; }
.day.today { color: var(--accent); font-weight: 800; }
.day.selected { background: var(--text); color: var(--card); font-weight: 700; }

.dots { display: flex; gap: 3px; height: 6px; align-items: center; }
.dot { width: 6px; height: 6px; border-radius: 50%; display: inline-block; background: var(--muted); }
.day.selected .dot { box-shadow: 0 0 0 1.5px color-mix(in srgb, var(--card) 70%, transparent); }
.dot.hollow { background: transparent; box-shadow: inset 0 0 0 2px currentColor; }

.day-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 14px; }
.day-head h2 { font-size: 1.05rem; }
.day-head .pill-btn { white-space: nowrap; }

/* ---------------------------------------------------------- lister */
.list { display: flex; flex-direction: column; }

.item {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 13px 0;
  border-top: 1px solid var(--line);
}
.list > .item:first-child { border-top: 0; padding-top: 1px; }
.list > .item:last-child { padding-bottom: 1px; }

.item-body { flex: 1; min-width: 0; }
.item-title { font-weight: 600; word-break: break-word; }
.item-meta { font-size: .8rem; color: var(--muted); margin-top: 3px; display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.item-notes { font-size: .85rem; color: var(--muted); margin-top: 6px; white-space: pre-wrap; }

.item.done .item-title { text-decoration: line-through; opacity: .45; }

.check {
  width: 24px; height: 24px; border-radius: 50%;
  border: 2px solid var(--line);
  background: transparent; cursor: pointer; flex: none; margin-top: 1px;
  color: #fff; font-size: .75rem; line-height: 1;
  display: flex; align-items: center; justify-content: center; padding: 0;
}
.check.on { background: #4fb783; border-color: #4fb783; }

/* liten rund ikonflate foran økter i feeden */
.avatar {
  width: 38px; height: 38px; border-radius: 13px; flex: none;
  display: flex; align-items: center; justify-content: center;
  font-size: .95rem;
  background: color-mix(in srgb, var(--sc, var(--accent)) 18%, transparent);
  color: var(--sc, var(--accent));
}

.empty { color: var(--muted); font-size: .9rem; padding: 6px 2px; }

.trash { border: 0; background: transparent; cursor: pointer; color: var(--line); font-size: 1rem; padding: 2px 6px; flex: none; }
.trash:active { color: var(--accent); }

.timeline-date {
  font-size: .68rem; color: var(--muted); font-weight: 700;
  letter-spacing: .1em; text-transform: uppercase;
  padding: 16px 0 5px; border-top: 1px solid var(--line); margin-top: 3px;
}
.list > .timeline-date:first-child { border-top: 0; padding-top: 0; margin-top: 0; }

/* ---------------------------------------------------------- felt */
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.field > span { font-size: .7rem; color: var(--muted); font-weight: 700; letter-spacing: .09em; text-transform: uppercase; }
.field.grow { flex: 1; }

input, select, textarea {
  font: inherit; font-size: .95rem;
  color: var(--text);
  background: var(--bg);
  border: 1.5px solid transparent;
  border-radius: 14px;
  padding: 11px 14px;
  width: 100%;
  resize: vertical;
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--accent); }

.row { display: flex; gap: 10px; align-items: flex-end; }
.row .field { min-width: 0; margin-bottom: 14px; }
.row > .pill-btn { margin-bottom: 14px; white-space: nowrap; }
#manualMinutes { width: 112px; }

/* ---------------------------------------------------------- opptak */
.record-card { text-align: center; padding: 30px 18px 26px; }

.record-label {
  font-size: .72rem; font-weight: 700; color: var(--muted);
  letter-spacing: .12em; text-transform: uppercase;
}

.record-time {
  font-size: 3.6rem; font-weight: 800;
  font-variant-numeric: tabular-nums;
  letter-spacing: -.045em; line-height: 1.05;
  margin: 8px 0 22px;
}

.record-card.running .record-time { color: var(--accent); }

.record-actions { display: flex; gap: 10px; justify-content: center; align-items: center; }

.start-big {
  background: linear-gradient(150deg, #ffa88f, var(--accent));
  color: #fff;
  font-size: 1.02rem;
  font-weight: 800;
  letter-spacing: .01em;
  padding: 15px 46px;
  box-shadow: var(--shadow-lift);
}
.start-big:active { transform: scale(.97); }
.start-big.stop { background: var(--text); box-shadow: none; }

/* ---------------------------------------------------------- statistikk */
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 20px; }
.stat { background: var(--bg); border-radius: 15px; padding: 13px 6px; text-align: center; }
.stat b { display: block; font-size: 1.15rem; font-weight: 800; letter-spacing: -.03em; line-height: 1.2; }
.stat span { display: block; font-size: .6rem; color: var(--muted); font-weight: 700; letter-spacing: .06em; text-transform: uppercase; margin-top: 3px; }

.chart { display: grid; gap: 7px; align-items: end; height: 102px; }
#weekChart { grid-template-columns: repeat(7, 1fr); }

.bar-wrap { display: flex; flex-direction: column; align-items: center; justify-content: flex-end; height: 100%; gap: 6px; }
.bar-stack { width: 100%; max-width: 34px; display: flex; flex-direction: column-reverse; border-radius: 8px; overflow: hidden; min-height: 4px; }
.bar-seg { width: 100%; min-height: 3px; }
.bar-stack.zero { background: var(--line); height: 4px; }
.bar-label { font-size: .66rem; color: var(--muted); font-weight: 600; }
.bar-label.now { color: var(--accent); font-weight: 800; }
.bar-val { font-size: .62rem; color: var(--muted); height: 12px; font-weight: 600; }

/* ---------------------------------------------------------- fagkort */
.subject-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
@media (max-width: 330px) { .subject-grid { grid-template-columns: 1fr; } }

.subject-card {
  --sc: var(--accent);
  text-align: left; font: inherit; cursor: pointer;
  background: color-mix(in srgb, var(--sc) 15%, var(--card));
  border: 0; border-radius: 18px;
  padding: 15px;
  color: var(--text);
  display: block;
  box-shadow: var(--shadow);
}
.subject-card:active { transform: scale(.98); }

.subject-card .sc-name {
  font-size: 1rem; font-weight: 700; letter-spacing: -.02em; margin-bottom: 8px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.subject-card .sc-time { font-size: .82rem; font-weight: 600; color: color-mix(in srgb, var(--sc) 72%, var(--ink)); }
.subject-card .sc-note { font-size: .75rem; color: var(--muted); margin-top: 3px; }
.subject-card .sc-note.alert { color: color-mix(in srgb, var(--sc) 72%, var(--ink)); font-weight: 700; }

.subject-hero { --sc: var(--accent); }

.swatches { display: flex; flex-wrap: wrap; gap: 10px; }
.swatch {
  width: 34px; height: 34px; border-radius: 50%;
  border: 2.5px solid transparent; cursor: pointer; padding: 0;
}
.swatch.on { border-color: var(--text); }

/* ---------------------------------------------------------- prøvekort */
.test-list { display: flex; flex-direction: column; gap: 12px; }

.test-card {
  --sc: var(--accent);
  display: flex; align-items: center; gap: 14px;
  background: var(--card);
  border-radius: 18px;
  box-shadow: var(--shadow);
  padding: 14px 16px;
  border: 0; width: 100%;
  text-align: left; font: inherit; color: var(--text); cursor: pointer;
}
.test-card:active { transform: scale(.99); }

.test-date {
  flex: none; width: 54px; text-align: center;
  background: color-mix(in srgb, var(--sc) 18%, transparent);
  color: color-mix(in srgb, var(--sc) 72%, var(--ink));
  border-radius: 14px; padding: 8px 0;
}
.test-date b { display: block; font-size: 1.25rem; font-weight: 800; line-height: 1; letter-spacing: -.03em; }
.test-date span { font-size: .62rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }

.test-body { flex: 1; min-width: 0; }
.test-body .t-title { font-weight: 700; letter-spacing: -.01em; word-break: break-word; }
.test-body .t-meta { font-size: .78rem; color: var(--muted); margin-top: 3px; }
.test-when { flex: none; font-size: .74rem; font-weight: 700; color: var(--muted); text-align: right; }
.test-when.soon { color: var(--accent); }

/* ---------------------------------------------------------- modal */
.overlay {
  position: fixed; inset: 0;
  background: rgba(29, 27, 35, .45);
  backdrop-filter: blur(3px);
  display: flex; align-items: flex-end; justify-content: center;
  padding: 0; z-index: 60; overflow-y: auto;
}
.overlay[hidden] { display: none; }

.modal {
  background: var(--card);
  border-radius: 26px 26px 0 0;
  padding: 24px 20px calc(24px + env(safe-area-inset-bottom));
  width: 100%; max-width: 480px; margin: auto 0 0;
}
.modal > h2 { margin-bottom: 18px; font-size: 1.35rem; }

@media (min-width: 560px) {
  .overlay { align-items: center; padding: 16px; }
  .modal { margin: auto; border-radius: 26px; padding-bottom: 24px; }
}

.seg { display: flex; gap: 6px; background: var(--bg); padding: 4px; border-radius: 999px; margin-bottom: 18px; }
.seg button {
  flex: 1; border: 0; background: transparent; font: inherit; font-weight: 700; font-size: .9rem;
  color: var(--muted); padding: 9px; border-radius: 999px; cursor: pointer;
}
.seg button.active { background: var(--card); color: var(--text); box-shadow: var(--shadow); }

.modal-actions { display: flex; gap: 8px; align-items: center; margin-top: 8px; }
.spacer { flex: 1; }

/* ---------------------------------------------------------- konto */
.account-box { background: var(--bg); border-radius: 16px; padding: 16px; margin-bottom: 16px; }
.account-email { font-weight: 700; word-break: break-all; }
.account-sync { font-size: .82rem; color: var(--muted); margin-top: 4px; }
.account-sync.feil { color: var(--accent-ink); }

#headerAction {
  background: linear-gradient(150deg, #ffa88f, var(--accent));
  color: #fff;
  font-weight: 800;
  font-size: 1rem;
  text-transform: uppercase;
  box-shadow: var(--shadow-lift);
}

/* ---------------------------------------------------------- innlogging */
.auth-screen {
  position: fixed;
  inset: 0;
  z-index: 80;
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  overflow-y: auto;
}
.auth-screen[hidden] { display: none; }

.auth-box { width: 100%; max-width: 380px; margin: auto; }

.auth-logo {
  width: 62px; height: 62px;
  border-radius: 20px;
  background: linear-gradient(150deg, #ffa88f, var(--accent));
  box-shadow: var(--shadow-lift);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.7rem;
  margin-bottom: 18px;
}

.auth-box h1 { font-size: 2rem; margin-bottom: 6px; }
.auth-sub { color: var(--muted); font-size: .92rem; margin: 0 0 26px; }

.auth-box input { background: var(--card); }

.auth-msg {
  background: color-mix(in srgb, var(--accent) 13%, transparent);
  color: var(--accent-ink);
  border-radius: 13px;
  padding: 11px 14px;
  font-size: .86rem;
  font-weight: 600;
  margin-bottom: 14px;
}
.auth-msg.ok { background: color-mix(in srgb, #4fb783 16%, transparent); color: #2f8560; }

.link-btn.block {
  display: block;
  width: 100%;
  text-align: center;
  margin-top: 14px;
  padding: 8px;
}
.link-btn.subtle { color: var(--muted); }

/* ---------------------------------------------------------- feiring
   Pølsehunden som trasker over skjermen når du har fullført en økt. */
.feiring {
  position: fixed;
  inset: 0;
  z-index: 60;
  pointer-events: none;
  overflow: hidden;
}

.feiring-scene {
  position: absolute;
  bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom) + 18px);
  left: 0;
  width: 230px;
  animation: trask 3.6s linear forwards;
}

@keyframes trask {
  from { transform: translateX(-250px); }
  to   { transform: translateX(100vw); }
}

.polse { display: block; width: 100%; height: auto; }

.polse .kropp, .polse .ben, .polse .snute { fill: #e3a76f; }
.polse .ore  { fill: #b9793d; }
.polse .nese { fill: #4a3a33; }
.polse .oye  { fill: #3d3129; }
.polse .hale {
  fill: none; stroke: #e3a76f; stroke-width: 9; stroke-linecap: round;
}

.polse .ben {
  transform-box: fill-box;
  transform-origin: 50% 6%;
  animation: trippe .28s ease-in-out infinite alternate;
}
.polse .ben-2, .polse .ben-3 { animation-delay: -.14s; }

@keyframes trippe {
  from { transform: rotate(-19deg); }
  to   { transform: rotate(19deg); }
}

.feiring-boble {
  position: absolute;
  left: 96px;
  bottom: 104px;
  background: var(--card);
  color: var(--text);
  box-shadow: var(--shadow);
  border-radius: 16px;
  padding: 9px 15px;
  font-size: .95rem;
  font-weight: 800;
  letter-spacing: -.01em;
  white-space: nowrap;
  animation: boble .45s cubic-bezier(.2, 1.5, .4, 1) both;
}

.feiring-boble::after {
  content: '';
  position: absolute;
  left: 26px; bottom: -7px;
  border: 8px solid transparent;
  border-top-color: var(--card);
  border-bottom: 0;
}

@keyframes boble {
  from { opacity: 0; transform: translateY(8px) scale(.7); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

/* Rolig variant for de som har slått av bevegelse i systeminnstillingene. */
@media (prefers-reduced-motion: reduce) {
  .feiring-scene {
    left: 50%;
    animation: none;
    transform: translateX(-50%);
  }
  .polse .ben { animation: none; }
  .feiring-boble { animation: boble .3s ease-out both; }
}
