* {
  font-family: 'Noto Sans', sans-serif;
  font-size: 13px;
  box-sizing: border-box;
}

body {
  margin: 0;
  padding: 0;
}

/* ============================================================
   TIMEGLASS (loading spinner)
   ============================================================ */
.timeglass {
  position: absolute;
  width: 100px;
  height: 100px;
  left: calc(50% - 50px);
  top: calc(50% - 50px);
  border: 16px solid #f3f3f3;
  border-top: 16px solid #FF9900;    /* H9-oransje */
  border-bottom: 16px solid #4A85E9; /* H9-blå */
  border-radius: 50%;
  animation: spin 3s linear infinite;
  display: none;
  z-index: 9999;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* ============================================================
   HEADER
   ============================================================ */
.header {
  position: fixed;
  left: 0;
  top: 0;
  width: 100%;
  height: 40px;
  background: url('https://lh3.googleusercontent.com/g-kWMwn7bn7z7QfwUcqL4otLdZdu9ceALKJ8ogt6o_yub5T4Ss0DLbY7jAk8Q7X64TmwfZxEoctU8RjiECLMp3qPTFun_8k3Nn7FPSzo0i80nZD0yMXGbBSK0EYo5t8ixEl0-0mQ');
  background-repeat: no-repeat;
  background-size: 100% 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 10px;
  font-size: 15px;
  z-index: 100;
}

#headerText {
  font-size: 28px;
  font-family: 'Indie Flower', cursive;
  text-shadow: 1px 0.2px 3px #4a85e9;
  color: #fff;
  transform: translateY(2px);
}
.header-hoyre {
  display: flex;
  align-items: baseline;
  gap: 6px;
}
.header-version {
  font-size: 11px;
  opacity: 0.7;
}

/* ============================================================
   LOGIN
   ============================================================ */
.loginPage {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100vh;
}

.loginButton {
  padding: 15px 40px;
  font-size: 16px;
  background-color: #4A85E9;
  color: white;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-family: 'Noto Sans', sans-serif;
}

.loginButton:hover {
  background-color: #3a6fd8;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

/* ============================================================
   INNHOLD
   ============================================================ */
.innhold {
  position: relative;
  top: 40px;
  padding: 0 14px;
  box-sizing: border-box;
}

/* ============================================================
   ARKFANER (TABS)
   ============================================================ */
.tabs {
  display: flex;
  gap: 0;
  margin-bottom: 20px;
  border-bottom: 2px solid #e0e0e0;
}

.tab {
  padding: 10px 24px;
  font-size: 14px;
  font-family: 'Noto Sans', sans-serif;
  font-weight: 600;
  background: none;
  border: none;
  border-bottom: 3px solid transparent;
  color: #888;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
  margin-bottom: -2px;
}

.tab:hover {
  color: #444;
}

.tab-active {
  color: #4A85E9;
  border-bottom-color: #4A85E9;
}

.tab-panel {
  padding-top: 10px;
}

/* ============================================================
   ROM-KNAPPER
   ============================================================ */
.knappAlle {
  border: 1px solid white;
  border-radius: 2em;
  color: white;
  padding: 15px 32px;
  text-align: center;
  text-decoration: none;
  display: inline-block;
  font-size: 16px;
  margin: 4px 2px;
  font-family: 'Noto Sans', sans-serif;
}

.knapp1 { background-color: purple; }
.knapp2 { background-color: SlateBlue; }
.knapp3 { background-color: royalblue; }
.knapp4 { background-color: DarkCyan; }
.knapp5 { background-color: MediumSeaGreen; }
.knapp6 { background-color: orange; }
.knapp7 { background-color: tomato; }

.knappInaktiv { opacity: 0.3; }

.knappAktiv:hover {
  box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19);
  border: 1px solid black;
  cursor: pointer;
}

/* ============================================================
   INNSATSGRAF
   ============================================================ */
.studentProfilePage {
  position: relative;
  top: 0;
}

.studentProfileContainer {
  display: flex;
  flex-direction: column;
}

.studentProfileContent1 {
  position: relative;
  top: 40px;
  display: flex;
  justify-content: space-between;
}

.studentProfileContent2 {
  margin-top: 60px;
  display: flex;
}

.studentEffortGraph {
  position: relative;
  width: 700px;
  height: 300px;
}

.chartContainer {
  width: 100%;
  height: 100%;
}

.checkbox-container {
  position: absolute;
  bottom: 3px;
  right: 15px;
  background: rgba(255, 255, 255, 0.8);
  padding: 5px;
  border-radius: 5px;
}

/* ============================================================
   INNSATSSIRKLER
   ============================================================ */
.circle {
  width: 46px;
  height: 46px;
  margin: 4px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  text-align: center;
  line-height: 1.2;
  word-wrap: break-word;
  color: #000;
  box-shadow: 3px 3px 6px rgba(0, 0, 0, 0.3);
}

.green  { background-color: #90ee90; } /* Grønn for "OPP" */
.orange { background-color: #ffd580; } /* Oransje for "NED" */
.red    { background-color: #f08080; } /* Rød for "BLANK" og "ILVRT" */

.studentEffortCircles {
  display: flex;
  flex-direction: row-reverse;
  justify-content: flex-start;
  width: max-content;
}

/* ============================================================
   SHAKE-ANIMASJON
   ============================================================ */
@keyframes shake {
  0%   { transform: translate(1px, 1px) rotate(0deg); }
  10%  { transform: translate(-1px, -2px) rotate(-1deg); }
  20%  { transform: translate(-3px, 0px) rotate(1deg); }
  30%  { transform: translate(3px, 2px) rotate(0deg); }
  40%  { transform: translate(1px, -1px) rotate(1deg); }
  50%  { transform: translate(-1px, 2px) rotate(-1deg); }
  60%  { transform: translate(-3px, 1px) rotate(0deg); }
  70%  { transform: translate(3px, 1px) rotate(-1deg); }
  80%  { transform: translate(-1px, -1px) rotate(1deg); }
  90%  { transform: translate(1px, 2px) rotate(0deg); }
  100% { transform: translate(1px, -2px) rotate(-1deg); }
}

/* ============================================================
   RESPONSIVT
   ============================================================ */
@media only screen and (max-width: 768px) {
  .studentEffortGraph {
    width: 100%;
    max-width: 700px;
  }
}

/* ============================================================
   TOAST-VARSLING
   ============================================================ */
.toast {
  position: fixed;
  top: 50px;
  left: 50%;
  transform: translateX(-50%) translateY(-20px);
  background-color: #2e7d32;
  color: white;
  padding: 14px 28px;
  border-radius: 12px;
  font-size: 15px;
  font-family: 'Noto Sans', sans-serif;
  font-weight: 600;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease, transform 0.3s ease;
  z-index: 1000;
  text-align: center;
  max-width: 90%;
}

.toast.toast-visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.toast.toast-error {
  background-color: #c62828;
}

/* ============================================================
   OPPDATERINGS-OVERLAY
   ============================================================ */
.update-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.update-overlay-box {
  background-color: #fff;
  border-radius: 16px;
  padding: 40px;
  text-align: center;
  max-width: 360px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.3);
}

.update-overlay-title {
  font-size: 18px;
  font-weight: 700;
  font-family: 'Noto Sans', sans-serif;
  margin-bottom: 12px;
  color: #222;
}

.update-overlay-text {
  font-size: 14px;
  font-family: 'Noto Sans', sans-serif;
  color: #555;
  margin-bottom: 24px;
}

.update-overlay-button {
  padding: 12px 32px;
  background-color: #4A85E9;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 15px;
  font-family: 'Noto Sans', sans-serif;
  font-weight: 600;
  cursor: pointer;
}

.update-overlay-button:hover {
  background-color: #3a6fd8;
}

/* ============================================================
   GRUNNPAKKA
   ============================================================ */
.gp-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 5px;
  max-width: 630px;
  margin: 16px 0;
}

.gp-cell {
  border: 1px solid #bbb;
  border-radius: 6px;
  padding: 8px 4px 6px;
  text-align: center;
  min-height: 58px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  user-select: none;
}

.gp-cell-top {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2px;
  margin-bottom: 4px;
}

.gp-nr {
  font-weight: 700;
  font-size: 13px;
  color: #222;
}

.gp-star {
  font-size: 10px;
  color: #cc0000;
  line-height: 1;
  margin-top: 1px;
}

.gp-status {
  font-size: 11px;
  color: #444;
  line-height: 1.3;
}

/* Popup */
.gp-popup {
  position: absolute;
  background: #fff;
  border: 1px solid #ccc;
  border-radius: 8px;
  padding: 10px 14px;
  min-width: 180px;
  max-width: 240px;
  box-shadow: 0 4px 14px rgba(0,0,0,0.15);
  z-index: 500;
}

.gp-popup-tittel {
  font-weight: 700;
  font-size: 13px;
  margin-bottom: 6px;
  color: #111;
}

.gp-popup-notat {
  font-size: 12px;
  font-style: italic;
  color: #555;
  margin-bottom: 8px;
  padding-bottom: 8px;
  border-bottom: 1px solid #eee;
}

.gp-popup-datoer {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.gp-popup-bestatt {
  font-size: 12px;
  color: #2e7d32;
  font-weight: 600;
}

.gp-popup-ikke-bestatt {
  font-size: 12px;
  color: #999;
}

.gp-wrapper {
  padding-left: 28px;
}

.gp-forklaring {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 16px 0 8px;
  max-width: 630px;
  font-size: 12px;
  color: #444;
  flex-wrap: wrap;
  row-gap: 6px;
}

.gp-fk-boks {
  display: inline-block;
  width: 14px;
  height: 14px;
  border-radius: 2px;
  flex-shrink: 0;
}

.gp-fk-star {
  font-size: 12px;
  color: #cc0000;
  margin-left: 6px;
}

/* Mobilvisning: 4 per rad */
@media only screen and (max-width: 500px) {
  .gp-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}
/* ============================================================
   HUMHOOT — elev-banner og spill-overlay
   ============================================================ */

.humhoot-banner {
  background: linear-gradient(135deg, #7c4dff 0%, #4a148c 100%);
  color: white;
  padding: 14px 18px;
  margin: 12px 16px 0;
  border-radius: 12px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: 0 4px 14px rgba(124, 77, 255, 0.4);
  animation: humhoot-banner-pulse 2s ease-in-out infinite;
  user-select: none;
  font-family: inherit;
}
@keyframes humhoot-banner-pulse {
  0%, 100% { box-shadow: 0 4px 14px rgba(124, 77, 255, 0.4); }
  50%      { box-shadow: 0 6px 24px rgba(124, 77, 255, 0.7); }
}
.humhoot-banner-ikon {
  font-size: 28px;
}
.humhoot-banner-tekst {
  flex: 1;
  font-size: 15px;
}
.humhoot-banner-tekst strong { font-weight: 700; display: block; font-size: 17px; }

/* ============================================================
   Overlay (full-screen)
   ============================================================ */

.humhoot-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: linear-gradient(135deg, #4a148c 0%, #1a237e 100%);
  z-index: 10000;
  display: flex;
  align-items: stretch;
  justify-content: center;
  font-family: inherit;
}

.hh-elev-side {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px;
  box-sizing: border-box;
  position: relative;
  color: white;
  text-align: center;
  gap: 14px;
}

.hh-elev-venter {
  margin: auto;
  font-size: 22px;
  color: white;
  opacity: 0.85;
}

.hh-elev-privat {
  position: absolute;
  top: 16px;
  right: 16px;
  background: rgba(255,255,255,0.2);
  border: none;
  border-radius: 50%;
  width: 44px;
  height: 44px;
  font-size: 20px;
  cursor: pointer;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}
.hh-elev-privat:hover {
  background: rgba(255,255,255,0.35);
}
.hh-elev-privat-ikon {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}
/* Diagonal strek over øyet når personvern-modus er aktivt */
.hh-elev-privat-skjult .hh-elev-privat-ikon::after {
  content: '';
  position: absolute;
  left: -3px;
  right: -3px;
  top: 50%;
  height: 2.5px;
  background: white;
  transform: rotate(-30deg);
  border-radius: 2px;
  box-shadow: 0 0 0 1px rgba(0,0,0,0.4);
  pointer-events: none;
}

/* Lobby */
.hh-elev-lobby .hh-elev-tittel {
  font-size: 32px;
  font-weight: 800;
  text-shadow: 0 2px 8px rgba(0,0,0,0.3);
}
.hh-elev-undertittel {
  font-size: 18px;
  opacity: 0.85;
}
.hh-elev-min-foto {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  object-position: 50% 25%;
  border: 4px solid white;
  box-shadow: 0 6px 20px rgba(0,0,0,0.3);
  margin-top: 14px;
}
.hh-elev-min-navn {
  font-size: 22px;
  font-weight: 700;
  margin-top: 4px;
}

/* Spille — knapper med tekst */
.hh-elev-spille {
  justify-content: stretch;
  padding: 16px;
  gap: 10px;
}
.hh-elev-sp-info {
  font-size: 16px;
  background: rgba(255,255,255,0.2);
  padding: 6px 16px;
  border-radius: 14px;
  align-self: center;
}
.hh-elev-knapper {
  flex: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  width: 100%;
  max-width: 900px;
  margin: 0 auto;
}
.hh-elev-svar-knapp {
  border: none;
  border-radius: 16px;
  padding: 24px 18px;
  font-size: 22px;
  font-weight: 700;
  color: white;
  cursor: pointer;
  text-shadow: 0 2px 4px rgba(0,0,0,0.25);
  box-shadow: 0 6px 14px rgba(0,0,0,0.25);
  transition: transform 0.1s, box-shadow 0.1s;
  font-family: inherit;
  min-height: 100px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.hh-elev-svar-knapp:hover {
  transform: scale(1.03);
}
.hh-elev-svar-knapp:active {
  transform: scale(0.97);
  box-shadow: 0 2px 6px rgba(0,0,0,0.25);
}
.hh-elev-svar-tekst {
  word-break: break-word;
}
.hh-elev-spille-fot {
  font-size: 13px;
  opacity: 0.7;
  font-style: italic;
}

/* Etter svar — pulserende spørsmålstegn signaliserer venting */
.hh-elev-svart .hh-elev-svart-ikon {
  font-size: 90px;
  background: white;
  color: #7c4dff;
  border-radius: 50%;
  width: 140px;
  height: 140px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  animation: hh-elev-vent-pulse 1.4s ease-in-out infinite;
}
@keyframes hh-elev-pop {
  0%   { transform: scale(0); }
  100% { transform: scale(1); }
}
@keyframes hh-elev-vent-pulse {
  0%, 100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(255,255,255,0.4); }
  50%      { transform: scale(1.06); box-shadow: 0 0 0 18px rgba(255,255,255,0); }
}
.hh-elev-svart-tekst {
  font-size: 24px;
  font-weight: 700;
}
.hh-elev-svart-undertekst {
  font-size: 16px;
  opacity: 0.8;
}

/* Fasit */
.hh-elev-fasit-riktig { background: linear-gradient(135deg, #2e7d32 0%, #1b5e20 100%); }
.hh-elev-fasit-feil { background: linear-gradient(135deg, #c62828 0%, #b71c1c 100%); }
.hh-elev-fasit-tom { background: linear-gradient(135deg, #6a1b9a 0%, #311b92 100%); }
.hh-elev-fasit-riktig,
.hh-elev-fasit-feil,
.hh-elev-fasit-tom {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
}
.hh-elev-fasit-ikon {
  font-size: 100px;
  animation: hh-elev-pop 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.hh-elev-fasit-tekst {
  font-size: 36px;
  font-weight: 800;
}
.hh-elev-fasit-svar {
  padding: 14px 22px;
  border-radius: 14px;
  font-size: 18px;
  font-weight: 600;
  box-shadow: 0 4px 14px rgba(0,0,0,0.3);
  max-width: 90%;
}
.hh-elev-fasit-poeng-pluss {
  font-size: 36px;
  font-weight: 800;
  color: #ffeb3b;
}
.hh-elev-fasit-poeng {
  font-size: 18px;
  opacity: 0.9;
  background: rgba(255,255,255,0.2);
  padding: 6px 16px;
  border-radius: 14px;
}

/* Mellomstatus */
.hh-elev-mellom-tittel {
  font-size: 24px;
  font-weight: 700;
}
.hh-elev-min-plass {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}
.hh-elev-plass-tall {
  font-size: 80px;
  font-weight: 800;
  color: #ffeb3b;
  line-height: 1;
}
.hh-elev-plass-tekst {
  font-size: 16px;
  opacity: 0.9;
}
.hh-elev-min-score {
  font-size: 28px;
  font-weight: 700;
  background: rgba(255,255,255,0.2);
  padding: 8px 22px;
  border-radius: 14px;
}

/* Ferdig */
.hh-elev-ferdig-tittel {
  font-size: 32px;
  font-weight: 800;
}
.hh-elev-ferdig-medalje {
  font-size: 100px;
  animation: hh-elev-medalje 1.2s ease-in-out infinite;
}
@keyframes hh-elev-medalje {
  0%, 100% { transform: translateY(0) rotate(-5deg); }
  50%      { transform: translateY(-10px) rotate(5deg); }
}
.hh-elev-ferdig-plass {
  font-size: 22px;
  font-weight: 700;
}
.hh-elev-ferdig-stats {
  display: flex;
  gap: 24px;
  margin-top: 12px;
}
.hh-elev-stat {
  background: rgba(255,255,255,0.2);
  padding: 14px 22px;
  border-radius: 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.hh-elev-stat-tall {
  font-size: 32px;
  font-weight: 800;
  color: #ffeb3b;
}
.hh-elev-stat-tekst {
  font-size: 14px;
  opacity: 0.9;
}
.hh-elev-lukk-knapp {
  margin-top: 18px;
  background: white;
  color: #4a148c;
  border: none;
  border-radius: 28px;
  padding: 12px 32px;
  font-size: 17px;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
  box-shadow: 0 4px 14px rgba(0,0,0,0.25);
}
.hh-elev-lukk-knapp:hover {
  transform: scale(1.04);
}

.hh-elev-tid-ute {
  background: linear-gradient(135deg, #6a1b9a 0%, #311b92 100%);
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
}
.hh-elev-tid-ute-ikon {
  font-size: 100px;
  animation: hh-elev-pop 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* ============================================================
   FLEKSITID-FANEN
   ============================================================ */
.fleks-toppbokser { display: flex; gap: 12px; margin: 8px 0 16px; }
.fleks-boks {
  flex: 1; border-radius: 16px; padding: 18px 16px; text-align: center;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}
.fleks-boks-tid { background: #e8f5e9; }
.fleks-boks-fravaer { background: #ffebee; }
.fleks-boks-label { font-size: 13px; font-weight: 600; opacity: 0.8; }
.fleks-boks-tid .fleks-boks-label { color: #2e7d32; }
.fleks-boks-fravaer .fleks-boks-label { color: #c62828; }
.fleks-boks-tall { font-size: 34px; font-weight: 700; line-height: 1.1; margin-top: 4px; }
.fleks-boks-tid .fleks-boks-tall { color: #2e7d32; }
.fleks-boks-tid .fleks-boks-tall.fleks-boks-tall-minus { color: #c62828; }
.fleks-boks-fravaer .fleks-boks-tall { color: #c62828; }
.fleks-humanna { font-size: 15px; font-weight: 600; color: #5e35b1; margin-bottom: 6px; display: flex; align-items: center; justify-content: center; gap: 5px; }
.fleks-humanna-mynt { display: inline-flex; }
.fleks-humanna-mynt svg { width: 20px; height: 20px; display: block; }
.fleks-feil { font-size: 13px; color: #c62828; text-align: center; min-height: 0; }
.fleks-tom { color: #888; font-size: 14px; padding: 12px 0; text-align: center; }

/* Kort (tidsbot · tidslinje · godskrevet) */
.fleks-kort {
  display: flex; align-items: center; gap: 12px;
  background: #fff; border: 1px solid #e6e0f2; border-radius: 12px;
  padding: 12px 14px; margin-bottom: 6px;
}
.fleks-kort-tidslinje, .fleks-kort-bot { cursor: pointer; }
.fleks-kort-tidslinje:hover, .fleks-kort-bot:hover { background: #faf8ff; }
.fleks-kort-bot { border-left: 4px solid #ef5350; }
.fleks-kort-gods { border-left: 4px solid #66bb6a; }
.fleks-kort-dato { font-size: 13px; font-weight: 600; color: #888; min-width: 42px; }
.fleks-kort-tittel { flex: 1; font-size: 14px; color: #444; }
.fleks-kort-netto { font-size: 22px; font-weight: 700; white-space: nowrap; }
.fleks-kort-netto.pluss { color: #2e7d32; }
.fleks-kort-netto.minus { color: #c62828; }
.fleks-kort-netto.noytral { color: #888; }

/* Øktene side om side med fast mellomrom */
.fleks-okter { flex: 1; display: flex; gap: 14px; min-width: 0; }
.fleks-okt { flex: 1; min-width: 0; }
.fleks-okt-bar { position: relative; height: 22px; }
.fleks-okt-segs {
  display: flex; height: 100%; border-radius: 5px; overflow: hidden;
  background: #eceff1; border: 1px solid #e0e0e0;
}
.fleks-okt-naa {
  position: absolute; top: -5px; bottom: -5px; width: 2px;
  background: #263238; transform: translateX(-1px); z-index: 1;
  border-radius: 2px;
  animation: fleks-naa-puls 2s ease-in-out infinite;
}
@keyframes fleks-naa-puls {
  0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(38,50,56,0.35); }
  50% { opacity: 0.55; box-shadow: 0 0 4px 1px rgba(38,50,56,0.25); }
}
.fleks-seg { height: 100%; }
.fleks-seg-bla { background: #42a5f5; }
.fleks-seg-gronn { background: #66bb6a; }
.fleks-seg-rod { background: #ef5350; }
.fleks-seg-gra { background: #cfd8dc; }
.fleks-seg-lysrod { background: #ffcdd2; }   /* fremtidig: gjenstående obligatorisk */
.fleks-seg-lysgra { background: #f0f3f5; }   /* fremtidig: frivillig rest */
.fleks-okt-tid { display: flex; justify-content: space-between; font-size: 10px; color: #999; margin-top: 2px; }

/* Stemplingsknapper + status-linje */
.lv-knapper { margin-bottom: 6px; }
.lv-status { font-size: 14px; font-weight: 600; min-height: 18px; margin: 10px 2px 28px; }
.lv-status-inne { color: #2e7d32; }
.lv-status-pause { color: #777; }

/* Diskret «Vis mer …»-lenke */
.fleks-vis-mer {
  text-align: center; color: #5e35b1; font-size: 13px;
  cursor: pointer; padding: 8px; text-decoration: underline;
}
.fleks-vis-mer:hover { color: #7c4dff; }

/* Stemplingsdetaljer-modal */
.fleks-modal {
  position: fixed; inset: 0; background: rgba(0,0,0,0.45);
  display: flex; align-items: center; justify-content: center; z-index: 10004; padding: 20px;
}
.fleks-modal-boks {
  background: #fff; border-radius: 14px; padding: 20px; max-width: 360px; width: 100%;
  max-height: 80vh; overflow-y: auto;
}
.fleks-modal-tittel { font-size: 16px; font-weight: 700; margin-bottom: 12px; text-transform: capitalize; }
.fleks-modal-tabell { width: 100%; border-collapse: collapse; }
.fleks-modal-tabell th { text-align: left; font-size: 12px; color: #888; padding: 4px 8px; border-bottom: 1px solid #eee; }
.fleks-modal-tabell td { font-size: 14px; padding: 6px 8px; border-bottom: 1px solid #f3f3f3; }
.fleks-modal-lukk {
  margin-top: 14px; width: 100%; padding: 10px; border: none; border-radius: 8px;
  background: #7c4dff; color: #fff; font-size: 14px; cursor: pointer;
}

/* ==================== NAVNELEK (elevapp — portet fra larerapp) ==================== */
.nt-modul { max-width: 900px; margin: 0 auto; padding: 20px 16px 60px; }
.nt-tomt { max-width: 900px; margin: 40px auto; text-align: center; color: #888; }
.nt-tomt-liten { color: #999; font-size: 13px; padding: 8px; }
.nt-topp { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; margin-bottom: 18px; }
.nt-tittel { font-size: 22px; font-weight: 700; color: #333; }
.nt-stripe { display: flex; gap: 8px; flex-wrap: wrap; }
.nt-pille { background: #eee; color: #555; border-radius: 14px; padding: 4px 12px; font-size: 13px; font-weight: 600; }
.nt-pille-gronn { background: #e8f5e9; color: #2e7d32; }
.nt-pille-roed { background: #ffebee; color: #c62828; }

.nt-knapper { display: flex; flex-wrap: wrap; gap: 12px; align-items: stretch; margin-bottom: 24px; }
.nt-knapper-rad { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; margin-top: 16px; }
.nt-stor-knapp { grid-column: 1 / -1; background: #7c4dff; color: #fff; border: none; border-radius: 12px; padding: 18px; font-size: 18px; font-weight: 700; cursor: pointer; display: flex; flex-direction: column; align-items: center; gap: 2px; }
.nt-stor-knapp small { font-weight: 400; font-size: 12px; opacity: 0.85; }
.nt-stor-knapp:hover { filter: brightness(1.05); }
.nt-knapp { background: #fff; border: 1.5px solid #d1c4e9; border-radius: 12px; padding: 16px 12px; font-size: 15px; font-weight: 600; color: #4a148c; cursor: pointer; }
.nt-knapp:hover { background: #f3eeff; }
.nt-knapp-sek { border-color: #ccc; color: #555; }

/* Mosaikk */
.nt-mosaikk-mini { margin-top: 8px; }
.nt-mosaikk { display: grid; grid-template-columns: repeat(auto-fill, minmax(46px, 1fr)); gap: 6px; }
.nt-mos-rute { position: relative; aspect-ratio: 1; border-radius: 8px; overflow: hidden; background: #f0f0f0; border: 2px solid transparent; }
.nt-tip { position: fixed; z-index: 10050; background: #333; color: #fff; padding: 4px 9px; border-radius: 6px; font-size: 12px; font-weight: 600; pointer-events: none; white-space: nowrap; display: none; box-shadow: 0 2px 8px rgba(0,0,0,0.3); }
.nt-mos-rute img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 25%; transition: filter 0.4s, opacity 0.4s; }
.nt-mos-laast img { filter: grayscale(100%) blur(2px); opacity: 0.22; }
.nt-mos-mentee { border-color: #7c4dff; }
.nt-mos-vansk { position: absolute; top: 1px; right: 2px; font-size: 12px; color: #e53935; text-shadow: 0 0 2px rgba(255,255,255,0.8), 0 0 3px rgba(0,0,0,0.5); pointer-events: none; }

/* Økt */
.nt-okt { max-width: 720px; margin: 0 auto; padding: 16px; text-align: center; }
.nt-prog-rad { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 0 auto 14px; max-width: 688px; }
.nt-avslutt-btn { background: none; border: 1px solid #ccc; border-radius: 8px; padding: 5px 12px; font-size: 13px; color: #666; cursor: pointer; white-space: nowrap; }
.nt-avslutt-btn:hover { background: #f5f5f5; }
.nt-sprint-tid-rad { text-align: center; font-size: 22px; font-weight: 800; color: #5e35b1; margin: 8px 0 14px; }
.nt-kortfoto { position: relative; display: inline-block; line-height: 0; }
.nt-vansk-btn { position: absolute; top: 6px; right: 6px; width: 30px; height: 30px; border-radius: 50%; border: none; background: rgba(0,0,0,0.45); color: #f0f0f0; font-size: 15px; line-height: 1; cursor: pointer; display: flex; align-items: center; justify-content: center; padding: 0; transition: background 0.15s; }
.nt-vansk-btn:hover { background: rgba(0,0,0,0.6); }
.nt-vansk-btn.nt-vansk-pa { background: #e53935; color: #fff; box-shadow: 0 0 0 2px rgba(229,57,53,0.35); }
.nt-vansk-prog { flex: 1; font-size: 14px; font-weight: 700; color: #e53935; }
.nt-vansk-hint { background: #fff8e1; border: 1px solid #ffe082; border-radius: 10px; padding: 8px 12px; font-size: 12.5px; color: #6b5300; margin: 0 auto 14px; max-width: 360px; text-align: center; }
/* Leken poenglinje (per økt, nivå-basert) */
.nt-prog-rad .nt-poenglinje { flex: 1; }
.nt-poenglinje { display: flex; align-items: center; gap: 10px; }
.nt-poeng-niva { font-size: 13px; font-weight: 800; color: #7c4dff; white-space: nowrap; display: inline-block; }
.nt-poeng-spor { position: relative; flex: 1; height: 17px; background: #ede7f6; border-radius: 10px; overflow: hidden; box-shadow: inset 0 1px 2px rgba(0,0,0,0.12); }
.nt-poeng-fyll { position: relative; overflow: hidden; height: 100%; border-radius: 10px; background: linear-gradient(90deg, #b388ff, #7c4dff 60%, #5e35b1); transition: width 0.4s cubic-bezier(.2,.8,.2,1); box-shadow: 0 0 8px rgba(124,77,255,0.5); }
.nt-poeng-fyll::after { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 100%; background: linear-gradient(90deg, transparent, rgba(255,255,255,0.5), transparent); background-size: 55px 100%; background-repeat: no-repeat; animation: ntPoengGlim 6s ease-in-out infinite; pointer-events: none; }
@keyframes ntPoengGlim { 0% { background-position: -55px 0; } 28% { background-position: 120% 0; } 100% { background-position: 120% 0; } }
.nt-poeng-iniva { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 700; color: #fff; text-shadow: -1px -1px 0 #311b92, 1px -1px 0 #311b92, -1px 1px 0 #311b92, 1px 1px 0 #311b92, 0 0 3px #311b92; }
.nt-poeng-tall { font-size: 15px; font-weight: 800; color: #5e35b1; white-space: nowrap; }
.nt-niva-opp { animation: ntNivaPop 0.6s ease; }
@keyframes ntNivaPop { 0% { transform: scale(1); } 30% { transform: scale(1.45); } 100% { transform: scale(1); } }
.nt-fyll-opp { animation: ntFyllOpp 0.6s ease; }
@keyframes ntFyllOpp { 0%, 100% { filter: brightness(1); } 40% { filter: brightness(1.7); } }
.nt-sporsmal { font-size: 18px; color: #444; min-height: 34px; margin-bottom: 12px; display: flex; align-items: center; justify-content: center; }
.nt-sporsmal strong { font-size: inherit; font-weight: 700; }
.nt-hint strong { font-size: inherit; font-weight: 700; }
.nt-bilde-stor { display: flex; justify-content: center; margin: 0 auto 16px; }
.nt-foto-wrap { border-radius: 14px; overflow: hidden; box-shadow: 0 2px 10px rgba(0,0,0,0.12); background: #f0f0f0; }
.nt-foto { width: 100%; height: 100%; object-fit: cover; object-position: 50% 25%; display: block; }
.nt-foto-graa { filter: grayscale(100%); }
.nt-foto-halv-v { object-position: 0% 25%; transform: scale(1.6); }
.nt-foto-laast { filter: grayscale(100%) blur(2px); opacity: 0.3; }

.nt-valg-navn { display: flex; flex-direction: column; gap: 10px; max-width: 340px; margin: 0 auto; }
.nt-valg-btn { background: #fff; border: 1.5px solid #d1c4e9; border-radius: 10px; padding: 14px; font-size: 16px; font-weight: 600; color: #333; cursor: pointer; }
.nt-valg-btn:hover { background: #f3eeff; }
.nt-valg-rett { background: #c8e6c9 !important; border-color: #66bb6a !important; color: #2e7d32 !important; }
.nt-valg-feil { background: #ffcdd2 !important; border-color: #ef5350 !important; color: #c62828 !important; }
.nt-valg-bilde.nt-valg-rett { background: none !important; box-shadow: 0 0 0 3px #66bb6a; }
.nt-valg-bilde.nt-valg-feil { background: none !important; box-shadow: 0 0 0 3px #ef5350; }
.nt-flervalg-fot { min-height: 8px; margin-top: 10px; }
.nt-valg-bilder { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 12px; max-width: 480px; margin: 0 auto; justify-items: center; }
.nt-valg-bilde { display: flex; line-height: 0; background: none; border: 2px solid transparent; border-radius: 14px; padding: 0; cursor: pointer; }
.nt-valg-bilde:hover { border-color: #7c4dff; }

.nt-feedback { font-size: 20px; font-weight: 700; min-height: 34px; margin-bottom: 12px; display: flex; align-items: center; justify-content: center; }
.nt-fb-rett { color: #2e7d32; }
.nt-fb-feil { color: #c62828; }
.nt-fasit { font-size: 22px; font-weight: 700; color: #333; margin-bottom: 6px; }
.nt-feil-valg { color: #c62828; font-size: 14px; margin-bottom: 10px; }
.nt-neste-btn { margin-top: 16px; background: #7c4dff; color: #fff; border: none; border-radius: 10px; padding: 12px 28px; font-size: 16px; font-weight: 600; cursor: pointer; }
.nt-hint { font-size: 17px; color: #7c4dff; margin-bottom: 8px; }

/* Gjenkalling: stemme + skriving */
.nt-recall-status { font-size: 17px; color: #555; min-height: 26px; margin: 8px 0; font-weight: 600; }
.nt-recall-status.nt-lytter { color: #7c4dff; animation: nt-lytt-puls 1s ease infinite alternate; }
@keyframes nt-lytt-puls { from { opacity: 0.55; } to { opacity: 1; } }
.nt-mic-knapp { display: inline-flex; width: auto; font-size: 18px; }
.nt-recall-rad { display: flex; gap: 8px; max-width: 360px; margin: 4px auto 0; }
.nt-recall-input { flex: 1; border: 1.5px solid #d1c4e9; border-radius: 10px; padding: 12px 14px; font-size: 17px; font-family: inherit; }
.nt-recall-input:focus { outline: none; border-color: #7c4dff; }
.nt-recall-rad .nt-neste-btn { margin-top: 0; }
.nt-recall-rett { border-color: #66bb6a !important; background: #e8f5e9; color: #2e7d32; }
.nt-recall-feil { border-color: #ef5350 !important; background: #ffebee; color: #c62828; }
.nt-recall-bytt { background: none; border: none; color: #888; font-size: 13px; cursor: pointer; margin-top: 12px; text-decoration: underline; }
.nt-recall-bytt:hover { color: #7c4dff; }
.nt-hint-btn { margin-top: 14px; background: #fff3e0; border: 1.5px solid #ffcc80; border-radius: 10px; padding: 9px 20px; font-size: 14px; font-weight: 600; color: #8a5a00; cursor: pointer; }
.nt-hint-btn:hover { background: #ffe0b2; }

/* Oppsummering */
.nt-oppsummering { text-align: center; padding: 40px 16px; }
.nt-opp-tall { font-size: 18px; color: #444; margin: 12px 0; }
.nt-opp-merker { margin: 10px 0; }
.nt-merker { display: flex; gap: 14px; flex-wrap: wrap; }
.nt-merke { background: #fff3e0; color: #e65100; border-radius: 12px; padding: 4px 12px; font-size: 13px; font-weight: 600; }
.nt-medalje { width: 92px; height: 92px; border-radius: 50%; box-shadow: 0 2px 6px rgba(0,0,0,0.28), inset 0 0 0 4px rgba(255,255,255,0.4), inset 0 0 0 5px rgba(0,0,0,0.08); }
.nt-medalje svg { width: 100%; height: 100%; display: block; }
.nt-medalje-buet { font-size: 11px; font-weight: 700; letter-spacing: 0.4px; text-transform: uppercase; }
.nt-medalje-tall { font-weight: 800; }
.nt-medalje-gull { background: radial-gradient(circle at 35% 28%, #ffe082, #f4b400 68%, #c98f00); }
.nt-medalje-solv { background: radial-gradient(circle at 35% 28%, #fafafa, #c2c7cc 68%, #969ba1); }
.nt-medalje-bronse { background: radial-gradient(circle at 35% 28%, #f0c19b, #cd7f32 68%, #9c5520); }
.nt-medalje-gronn { background: radial-gradient(circle at 35% 28%, #b9f6ca, #4caf50 68%, #2e7d32); }
.nt-medalje-lilla { background: radial-gradient(circle at 35% 28%, #e1bee7, #ab47bc 68%, #7b1fa2); }
.nt-medalje-poeng { background: radial-gradient(circle at 35% 28%, #b3e5fc, #039be5 66%, #01579b); }
.nt-medalje-poeng text { fill: #fff; }
.nt-medalje-lyn { background: radial-gradient(circle at 35% 28%, #ffe0b2, #fb8c00 64%, #e65100); }
.nt-medalje-lyn text { fill: #fff; }
.nt-medalje-gull text { fill: #6b4e00; }
.nt-medalje-solv text { fill: #37474f; }
.nt-medalje-bronse text, .nt-medalje-gronn text, .nt-medalje-lilla text { fill: #fff; }

/* Zoom */
.nt-zoom-info { color: #888; font-size: 13px; margin: 8px 0; }
.nt-zoom-knapp { display: inline-flex; align-items: center; gap: 10px; background: #fff; border: 1.5px solid #d1c4e9; border-radius: 12px; padding: 8px 18px; cursor: pointer; margin: 4px 0 14px; }
.nt-zoom-knapp:hover:not(:disabled) { background: #f3eeff; }
.nt-zoom-knapp:disabled { opacity: 0.5; cursor: default; }
.nt-zoom-soyler { display: inline-flex; align-items: flex-end; gap: 3px; height: 26px; }
.nt-zs { width: 6px; background: #ddd; border-radius: 2px; }
.nt-zs-lit { background: #7c4dff; }
.nt-zoom-tekst { font-size: 14px; font-weight: 600; color: #4a148c; }

/* Par-spill */
.nt-par-info, .nt-par-navn { margin: 12px 0; }
.nt-par-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; max-width: 380px; margin: 0 auto; justify-items: center; }
.nt-par-celle { display: flex; flex-direction: column; align-items: center; gap: 5px; }
.nt-par-bilde { display: flex; line-height: 0; border: 3px solid transparent; border-radius: 14px; }
.nt-par-over { box-shadow: 0 0 0 3px rgba(124, 77, 255, 0.45); border-radius: 14px; }
.nt-par-over .nt-par-slot { border-color: #7c4dff; border-style: solid; color: #7c4dff; }
.nt-par-feil { border-color: #ef5350 !important; box-shadow: 0 0 0 3px rgba(239, 83, 80, 0.4); }
.nt-par-slot { min-height: 22px; min-width: 86px; border: 1.5px dashed #d1c4e9; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 13px; color: #888; padding: 3px 8px; }
.nt-par-slot-fylt { border-style: solid; border-color: #66bb6a; background: #e8f5e9; color: #2e7d32; font-weight: 600; }
.nt-par-navn { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }
.nt-par-navn-btn { background: #fff; border: 1.5px solid #d1c4e9; border-radius: 18px; padding: 8px 16px; font-size: 14px; font-weight: 600; cursor: grab; touch-action: none; }
.nt-par-drar { opacity: 0.35; }
.nt-par-klon { position: fixed; z-index: 11000; pointer-events: none; transform: translate(-50%, -50%); background: #fff; border: 1.5px solid #7c4dff; border-radius: 18px; padding: 8px 16px; font-size: 14px; font-weight: 600; box-shadow: 0 6px 16px rgba(0, 0, 0, 0.25); }
.nt-par-lost { opacity: 0.35; }

/* Bokstavsalat */
.nt-salat-ruter { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin: 14px auto 4px; max-width: 688px; }
.nt-salat-rute { min-width: 30px; height: 42px; padding: 0 4px; border-bottom: 3px solid #d1c4e9; display: inline-flex; align-items: center; justify-content: center; font-size: 26px; font-weight: 700; color: #4a148c; }
.nt-salat-rute.nt-salat-rett { color: #2e7d32; border-bottom-color: #66bb6a; }
.nt-salat-rute.nt-salat-graa { color: #9e9e9e; border-bottom-color: #bdbdbd; }
.nt-salat-brikker { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin: 18px auto 0; max-width: 688px; }
.nt-salat-brikker.nt-salat-ferdig .nt-salat-brikke:not(.nt-salat-rett):not(.nt-salat-feil) { opacity: 0.3; }
.nt-salat-brikke { width: 46px; height: 54px; background: #fff; border: 1.5px solid #d1c4e9; border-radius: 12px; font-size: 26px; font-weight: 700; color: #4a148c; cursor: pointer; }
.nt-salat-brikke.nt-salat-rett { background: #c8e6c9; border-color: #66bb6a; color: #2e7d32; }
.nt-salat-brikke.nt-salat-feil { background: #ffcdd2; border-color: #ef5350; color: #c62828; }
.nt-salat-brikke.nt-salat-brukt { visibility: hidden; }
.nt-salat-klon { position: fixed; z-index: 11000; pointer-events: none; transform: translate(-50%, -50%); width: 46px; height: 54px; display: flex; align-items: center; justify-content: center; background: #c8e6c9; border: 1.5px solid #66bb6a; border-radius: 12px; font-size: 26px; font-weight: 700; color: #2e7d32; transition: left 0.35s cubic-bezier(.22,.61,.36,1), top 0.35s cubic-bezier(.22,.61,.36,1); }

/* Navnebingo */
.nt-bingo-oppkall { display: flex; flex-direction: column; align-items: center; gap: 8px; margin-bottom: 16px; }
.nt-bingo-oppkall-tekst { font-size: 15px; color: #555; }
.nt-bingo-oppkall-navn { font-size: 28px; font-weight: 800; color: #4a148c; }
.nt-bingo-brett { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; max-width: 320px; margin: 0 auto; }
.nt-bingo-rute { position: relative; aspect-ratio: 1; background: #fff; border: 1.5px solid #d1c4e9; border-radius: 12px; display: flex; align-items: center; justify-content: center; cursor: pointer; padding: 4px; overflow: hidden; }
.nt-bingo-navn { font-size: 14px; font-weight: 700; color: #4a148c; text-align: center; line-height: 1.1; }
.nt-bingo-markert { background: #c8e6c9; border-color: #66bb6a; }
.nt-bingo-feil { background: #ffcdd2; border-color: #ef5350; animation: nt-bingo-blink 0.45s ease; }
@keyframes nt-bingo-blink { 0%, 100% { background: #ffcdd2; } 50% { background: #ef9a9a; } }
.nt-bingo-hake { position: absolute; top: 2px; right: 5px; color: #2e7d32; font-weight: 800; font-size: 16px; }
.nt-bingo-vinner { animation: nt-bingo-vinner-blink 0.5s ease-in-out infinite alternate; }
@keyframes nt-bingo-vinner-blink { from { background: #c8e6c9; box-shadow: 0 0 0 0 rgba(102, 187, 106, 0); } to { background: #a5d6a7; box-shadow: 0 0 0 4px rgba(102, 187, 106, 0.55); } }

/* Vendespill (memory) */
.nt-vende-brett { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; max-width: 420px; margin: 0 auto; }
.nt-vende-kort { aspect-ratio: 1; background: #7c4dff; border: 1.5px solid #7c4dff; border-radius: 12px; display: flex; align-items: center; justify-content: center; cursor: pointer; padding: 4px; overflow: hidden; }
.nt-vende-bak { font-size: 30px; font-weight: 800; color: rgba(255, 255, 255, 0.85); }
.nt-vende-aapen { background: #fff; border-color: #d1c4e9; }
.nt-vende-navn { font-size: 13px; font-weight: 700; color: #4a148c; text-align: center; line-height: 1.1; }
.nt-vende-matchet { background: #e8f5e9; border-color: #66bb6a; opacity: 0.85; }

/* Overlay */

/* Statistikk */
.nt-stat-tall { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 12px; margin-bottom: 20px; }
.nt-stat-kort { background: #f7f5fb; border-radius: 12px; padding: 16px; text-align: center; }
.nt-stat-stor { font-size: 26px; font-weight: 700; color: #4a148c; }
.nt-stat-label { font-size: 12px; color: #777; margin-top: 2px; }
.nt-stat-seksjon { margin-bottom: 24px; }
.nt-stat-seksjon h3 { font-size: 15px; color: #555; margin: 0 0 10px; }
.nt-stolpe-rad { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.nt-stolpe-label { width: 90px; font-size: 13px; color: #555; }
.nt-stolpe-bar { flex: 1; height: 18px; background: #eee; border-radius: 9px; overflow: hidden; }
.nt-stolpe-fyll { height: 100%; border-radius: 9px; transition: width 0.4s; }
.nt-stolpe-tall { width: 50px; text-align: right; font-size: 13px; color: #777; }
.nt-nivabar { display: flex; width: 100%; height: 26px; border-radius: 6px; overflow: hidden; border: 1px solid rgba(0,0,0,0.1); }
.nt-nivabar-seg { height: 100%; transition: width 0.3s; }
.nt-nivabar-tegn { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 8px; font-size: 12px; color: #555; }
.nt-nivabar-tegn span { display: inline-flex; align-items: center; gap: 4px; }
.nt-nivabar-tegn i { width: 12px; height: 12px; border-radius: 3px; display: inline-block; }

/* Mellom-etappe-skjerm */
.nt-interstitial { text-align: center; padding: 48px 16px; }
.nt-int-emoji { font-size: 52px; margin-bottom: 8px; }
.nt-int-under { font-size: 16px; color: #555; margin: 8px 0 4px; }

/* Milepæl-feiring (konfetti) */
.nt-feiring { position: fixed; inset: 0; z-index: 11000; display: flex; align-items: center; justify-content: center; background: rgba(0,0,0,0.35); overflow: hidden; }
.nt-konf-lag { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
.nt-konf { position: absolute; top: -24px; opacity: 0.92; animation-name: nt-konf-fall; animation-timing-function: linear; animation-iteration-count: infinite; }
@keyframes nt-konf-fall { 0% { top: -24px; } 100% { top: 110%; } }
.nt-feir-kort { position: relative; background: #fff; border-radius: 20px; padding: 32px 40px; text-align: center; box-shadow: 0 12px 40px rgba(0,0,0,0.3); animation: nt-feir-inn 0.5s cubic-bezier(.18,.89,.32,1.28); max-width: 90%; }
@keyframes nt-feir-inn { 0% { transform: scale(0.3); opacity: 0; } 100% { transform: scale(1); opacity: 1; } }
.nt-feir-emoji { font-size: 58px; animation: nt-feir-sprett 0.9s ease infinite alternate; }
@keyframes nt-feir-sprett { from { transform: translateY(0); } to { transform: translateY(-9px); } }
.nt-feir-tittel { font-size: 24px; font-weight: 800; color: #4a148c; margin: 8px 0 14px; }
.nt-feir-merker { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; margin-bottom: 20px; }
.nt-merke-stor { font-size: 16px; padding: 8px 18px; }
.nt-feir-ok { display: inline-flex; }

/* ============================================================
   HOTELL-SPILLET (fase 1 — kun testeleven «thomas»)
   ============================================================ */
.hotell-wrap {
  position: relative;
  width: 100%;
  border-radius: 12px;
  overflow: hidden;
  background: #dfeaf2;
  touch-action: none;           /* fingeren styrer joystick/pinch, ikke sidescroll */
  user-select: none;
  -webkit-user-select: none;
}
.hotell-wrap canvas { display: block; width: 100%; }
/* Vises mens Three.js hentes (dynamisk import — først når fanen faktisk åpnes) */
.hotell-laster {
  display: flex; align-items: center; justify-content: center;
  min-height: 380px; color: #78909c; font-size: 14px; font-weight: 600;
  background: #dfeaf2; border-radius: 12px;
}

.hotell-hud {
  position: absolute;
  top: 10px; left: 10px; right: 10px;
  display: flex;
  gap: 8px;
  align-items: center;
  pointer-events: none;         /* HUD skygger ikke for joystick … */
}
.hotell-hud-boks {
  background: rgba(255,255,255,0.92);
  border-radius: 18px;
  padding: 6px 14px;
  font-size: 15px;
  font-weight: 700;
  color: #37474f;
  box-shadow: 0 1px 4px rgba(0,0,0,0.15);
}
.hotell-hud-dagstak { font-size: 12px; font-weight: 600; color: #78909c; }
.hotell-hud-dagstak:empty { display: none; }
.hotell-dev-knapp {
  pointer-events: auto;         /* … men dev-knappen må kunne klikkes */
  margin-left: auto;
  border: 1px dashed #90a4ae;
  background: rgba(255,255,255,0.75);
  border-radius: 14px;
  padding: 4px 10px;
  font-size: 11px;
  color: #607d8b;
  cursor: pointer;
}

.hotell-melding {
  position: absolute;
  top: 54px; left: 50%;
  transform: translateX(-50%);
  background: rgba(55,71,79,0.9);
  color: #fff;
  border-radius: 18px;
  padding: 7px 18px;
  font-size: 15px;
  font-weight: 700;
  opacity: 0;
  transition: opacity 0.25s;
  pointer-events: none;
  white-space: nowrap;
}
.hotell-melding.vis { opacity: 1; }

/* Engangs-melding første gang eleven går inn i reklame-boksen — sentrert kort som må leses */
.hotell-reklame-info {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%) scale(0.94);
  max-width: 300px;
  background: rgba(55, 71, 79, 0.96);
  color: #fff;
  border-radius: 16px;
  padding: 16px 22px;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.4;
  text-align: center;
  opacity: 0;
  transition: opacity 0.3s, transform 0.3s;
  pointer-events: none;
  z-index: 30;
}
.hotell-reklame-info.vis { opacity: 1; transform: translate(-50%, -50%) scale(1); }
/* Hvile-banner (tomt hotell) — vedvarende nederst mens spilleren står på arbeids-feltet */
.hotell-hvile-info {
  position: absolute;
  bottom: 84px; left: 50%;
  transform: translateX(-50%);
  max-width: 320px;
  background: rgba(55, 71, 79, 0.94);
  color: #fff;
  border-radius: 14px;
  padding: 12px 20px;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.4;
  text-align: center;
  opacity: 0;
  transition: opacity 0.3s;
  pointer-events: none;
  z-index: 29;
}
.hotell-hvile-info.vis { opacity: 1; }
.hotell-reklame-info strong { color: #ffd54f; font-weight: 800; font-size: inherit; }   /* inherit slår global * { font-size:13px } → «humanna» like stor som resten */
/* Humanna-mynt i HUD (samme gullmynt som Læringsverksted-fanen) */
.hotell-hud-mynt { display: inline-flex; align-items: center; gap: 5px; }
.hotell-mynt-ikon { display: inline-flex; width: 18px; height: 18px; }
.hotell-mynt-ikon svg { width: 18px; height: 18px; display: block; }
.hotell-mynt-inline { width: 15px; height: 15px; vertical-align: -2px; margin: 0 1px; }

/* Etasje-indikator (heis §9) — vises når heisen er bygd, alltid synlig deretter */
.hotell-etasje {
  position: absolute;
  top: 54px; right: 12px;
  background: rgba(38,50,56,0.9);
  color: #fff;
  border-radius: 14px;
  padding: 6px 14px;
  font-size: 15px;
  font-weight: 800;
  pointer-events: none;
  z-index: 12;
}
/* Fade-gardin rundt etasje-bytte (heisen «kjører») — opacity drives per frame av synkHud */
.hotell-fade {
  position: absolute;
  inset: 0;
  background: #10161c;
  opacity: 0;
  pointer-events: none;
  z-index: 40;
}

.hotell-joystick {
  position: absolute;
  width: 90px; height: 90px;
  border-radius: 50%;
  border: 2px solid rgba(255,255,255,0.7);
  background: rgba(255,255,255,0.15);
  pointer-events: none;
}
.hotell-joystick-knott {
  position: absolute;
  left: 25px; top: 25px;
  width: 40px; height: 40px;
  border-radius: 50%;
  background: rgba(255,255,255,0.8);
  box-shadow: 0 1px 4px rgba(0,0,0,0.25);
}

.hotell-zoom {
  position: absolute;
  right: 12px; bottom: 12px;
  width: 48px; height: 48px;
  border-radius: 50%;
  border: none;
  background: rgba(255,255,255,0.92);
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
  font-size: 20px;
  cursor: pointer;
  pointer-events: auto;         /* over canvas — tap starter ikke joystick */
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}
.hotell-zoom:active { background: rgba(230,230,230,0.95); }

/* Avatar-bytte-knapp (over zoom-knappen) + velger-overlay */
.hotell-avatar-btn {
  position: absolute;
  right: 12px; bottom: 68px;
  width: 48px; height: 48px;
  border-radius: 50%;
  border: none;
  background: rgba(255,255,255,0.92);
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
  font-size: 22px;
  cursor: pointer;
  pointer-events: auto;
  display: flex; align-items: center; justify-content: center; line-height: 1;
}
.hotell-avatar-btn:active { background: rgba(230,230,230,0.95); }
.hotell-avatar-velger {
  position: absolute;
  inset: 0;
  background: rgba(20,25,35,0.55);
  display: flex; align-items: center; justify-content: center;
  pointer-events: auto;
  z-index: 20;
}
.hotell-avatar-boks {
  background: #fff;
  border-radius: 16px;
  padding: 22px 24px;
  box-shadow: 0 8px 30px rgba(0,0,0,0.35);
  display: flex; flex-direction: column; align-items: center; gap: 16px;
  max-width: 92%;
}
.hotell-avatar-tittel { font-size: 19px; font-weight: 800; color: #263238; }
.hotell-avatar-valg { display: flex; gap: 14px; flex-wrap: wrap; justify-content: center; }
.hotell-avatar-knapp {
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  width: 96px; padding: 14px 8px;
  border: 2px solid #cfd8dc; border-radius: 12px;
  background: #f7f9fa; cursor: pointer;
  font-size: 14px; font-weight: 700; color: #37474f;
}
.hotell-avatar-knapp:active { background: #eceff1; }
.hotell-avatar-knapp.valgt { border-color: #7c4dff; background: #f2ecff; }
.hotell-avatar-ikon { font-size: 40px; line-height: 1; }
.hotell-avatar-lukk {
  border: none; background: #eceff1; color: #37474f;
  padding: 8px 20px; border-radius: 20px; font-size: 14px; font-weight: 700; cursor: pointer;
}

.hotell-omd-panel {
  position: absolute;
  right: 12px; top: 54px;
  width: 244px;
  background: rgba(255,255,255,0.9);
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.18);
  padding: 10px 12px;
  pointer-events: none;         /* alltid synlig display — skal ikke stjele touch/drag */
  z-index: 5;
}
.hotell-omd-tittel { font-size: 15px; font-weight: 800; color: #37474f; margin-bottom: 8px; }
.hotell-omd-rad { display: flex; align-items: center; gap: 7px; padding: 5px 0; }
.hotell-omd-ikon { font-size: 17px; width: 20px; text-align: center; }
.hotell-omd-navn { font-size: 12px; font-weight: 700; color: #455a64; width: 78px; flex: none; white-space: nowrap; }
.hotell-omd-bar { flex: 1; height: 9px; background: #eceff1; border-radius: 5px; overflow: hidden; }
.hotell-omd-fyll { display: block; height: 100%; border-radius: 5px; transition: width 0.3s, background 0.3s; }
.hotell-omd-tall { font-size: 11px; font-weight: 700; color: #607d8b; width: 22px; text-align: right; }
.hotell-omd-fot { font-size: 10px; color: #90a4ae; margin-top: 8px; line-height: 1.3; }

/* ============================================================
   PIZZA-LYKKEHJUL (testelev-gated)
   ============================================================ */
#pizzaContent { max-width: 480px; margin: 0 auto; padding: 4px 10px 40px; }
.pz-overlay-venstre { position: absolute; top: 6px; left: 8px; z-index: 4; }
.pz-overlay-hoyre { position: absolute; top: 6px; right: 8px; z-index: 4; }
.pz-saldo { display: flex; align-items: center; justify-content: center; gap: 5px; width: 152px; height: 44px; box-sizing: border-box; background: #fff8e1; border: 1px solid #ffe082; border-radius: 22px; padding: 0 12px; font-weight: 700; color: #8d6e00; box-shadow: 0 1px 4px rgba(0,0,0,.08); }
.pz-saldo-tall { font-size: 20px; }
.pz-mynt { width: 22px; height: 22px; display: inline-block; }
.pz-mynt-liten { width: 15px; height: 15px; vertical-align: -2px; }

.pz-klippekort { background: #fff; border: 2px solid #e0e0e0; border-radius: 12px; padding: 8px 10px; text-align: center; transition: box-shadow .3s, border-color .3s; }
.pz-klippekort-klar { border-color: #ffb300; box-shadow: 0 0 0 3px rgba(255,179,0,.25); cursor: pointer; }
.pz-kort-tittel { font-size: 11px; font-weight: 700; color: #757575; margin-bottom: 5px; }
.pz-kort-ruter { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; }
.pz-rute { width: 22px; height: 22px; border: 1.5px solid #e0e0e0; border-radius: 5px; display: flex; align-items: center; justify-content: center; font-size: 13px; color: #ffc107; background: #fafafa; }
.pz-rute-fylt { background: #fff8e1; border-color: #ffca28; }
.pz-overflow { font-size: 10px; font-weight: 800; color: #f57f17; }
.pz-kort-hint { font-size: 10px; color: #f57f17; font-weight: 700; margin-top: 5px; }
.pz-puls { animation: pz-puls .5s ease; }
@keyframes pz-puls { 0%,100% { transform: scale(1); } 50% { transform: scale(1.08); } }

.pz-scene { position: relative; width: 100vw; margin-left: calc(50% - 50vw); margin-top: 0; margin-bottom: 8px; overflow: hidden; background: #ffffff; }
.pz-svg { display: block; width: 100%; height: auto; }
.pz-glyf { font-size: 22px; fill: #fff; font-weight: 800; paint-order: stroke; stroke: rgba(0,0,0,.28); stroke-width: .7px; }
.pz-glyf-pil { font-size: 30px; }
.pz-glyf-pizza { font-size: 40px; stroke-width: 0; }
.pz-stjerne-glyf { font-size: 16px; fill: #ffd21a; paint-order: stroke; stroke: #7a5a00; stroke-width: .7px; }
/* Stjerne-gevinst: alle felt gråtones unntatt vinnerfeltet → vinneren popper. */
.pz-felt { transition: filter .45s ease, opacity .45s ease; }
.pz-felt.pz-gra { filter: grayscale(1) brightness(.74); opacity: .85; }
.pz-ring { fill: none; stroke: #e03131; stroke-width: 11; filter: drop-shadow(0 3px 5px rgba(0,0,0,.35)); }
.pz-ring-blink { animation: pz-ring-blink .26s ease-in-out 5; }
@keyframes pz-ring-blink { 0%,100% { stroke: #e03131; } 50% { stroke: #ffd43b; } }
#pzPizzaMidt { transform-box: view-box; transform-origin: 450px 560px; --pz-heis: -190px; }
/* Ved gevinst: pizzaen stiger opp (og dekker hjulene, siden JS løfter den foran dem), gløder, og blir stående hevet. */
.pz-pizza-vinn { animation: pz-pizza-vinn 2.6s ease forwards; }
@keyframes pz-pizza-vinn {
  0%   { transform: translateY(0);                           filter: none; }
  22%  { transform: translateY(calc(var(--pz-heis) - 20px)); filter: drop-shadow(0 0 18px #ffd24a) brightness(1.13); }
  36%  { transform: translateY(var(--pz-heis));              filter: drop-shadow(0 0 14px #ffd24a) brightness(1.10); }
  72%  { transform: translateY(var(--pz-heis));              filter: drop-shadow(0 0 8px #ffd24a) brightness(1.05); }
  100% { transform: translateY(var(--pz-heis));              filter: none; }
}

.pz-melding { position: absolute; left: 0; right: 0; top: 10px; text-align: center; font-size: 18px; font-weight: 800; color: #37474f; text-shadow: 0 1px 2px #fff; pointer-events: none; }
.pz-fly-lag { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
.pz-fly-stjerne { position: absolute; font-size: 30px; transition: transform .68s cubic-bezier(.34,.1,.3,1), opacity .6s; will-change: transform; }
.pz-konfetti { position: absolute; top: -12px; width: 9px; height: 14px; border-radius: 2px; animation: pz-konfetti-fall 2.6s ease-in forwards; }
@keyframes pz-konfetti-fall { 0% { opacity: 1; } 82% { opacity: 1; } to { transform: translateY(440px) rotate(640deg); opacity: 0; } }
.pz-vinn-pizza { position: absolute; left: 50%; top: 40%; transform: translate(-50%,-50%) scale(0); font-size: 90px; animation: pz-pizza-pop 1.5s ease forwards; pointer-events: none; }
@keyframes pz-pizza-pop { 0% { transform: translate(-50%,-50%) scale(0) rotate(-30deg); } 40% { transform: translate(-50%,-50%) scale(1.2) rotate(10deg); } 60% { transform: translate(-50%,-50%) scale(1) rotate(0); } 100% { transform: translate(-50%,-50%) scale(1); opacity: 0; } }

.pz-knapper { position: absolute; top: 60px; left: 8px; z-index: 4; display: flex; flex-direction: column; align-items: flex-start; gap: 8px; }
.pz-knapp { border: none; border-radius: 22px; width: 152px; height: 44px; box-sizing: border-box; padding: 0 12px; font-size: 16px; font-weight: 800; color: #fff; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 6px; transition: filter .15s, transform .05s; }
.pz-knapp:active:not(:disabled) { transform: scale(.97); }
.pz-knapp:disabled { opacity: .45; cursor: not-allowed; }
.pz-knapp-kjop { background: linear-gradient(#ff8a3d, #f4681f); }
.pz-knapp-gratis { background: linear-gradient(#ffb300, #ff9800); }
.pz-pris { font-size: 13px; font-weight: 700; opacity: .95; }
.pz-test-knapp { display: block; margin: 6px auto 0; background: none; border: 1px dashed #b0bec5; color: #90a4ae; border-radius: 14px; padding: 5px 12px; font-size: 11px; cursor: pointer; }

.pz-bestillinger { margin-top: 16px; }
.pz-best-tittel { font-size: 14px; color: #37474f; margin: 0 0 8px; }
.pz-best-kort { display: flex; justify-content: space-between; align-items: center; gap: 10px; background: #fff; border: 1px solid #e0e0e0; border-radius: 10px; padding: 10px 12px; margin-bottom: 8px; }
.pz-best-frossen { background: #f5f5f5; color: #757575; }
.pz-best-tekst { font-size: 13px; font-weight: 600; }
.pz-best-rediger { border: 1px solid #ff8a3d; background: #fff; color: #f4681f; border-radius: 16px; padding: 6px 14px; font-weight: 700; cursor: pointer; }
.pz-best-status { font-size: 12px; font-weight: 700; color: #2e7d32; }

.pz-modal-overlay { position: fixed; inset: 0; background: rgba(0,0,0,.45); display: flex; align-items: center; justify-content: center; z-index: 10000; padding: 16px; }
.pz-modal { background: #fff; border-radius: 16px; padding: 18px 18px 16px; width: 100%; max-width: 380px; max-height: 88vh; overflow-y: auto; box-shadow: 0 10px 40px rgba(0,0,0,.3); }
.pz-modal-tittel { margin: 0 0 12px; font-size: 18px; }
.pz-modal-label { font-size: 12px; font-weight: 700; color: #607d8b; margin: 10px 0 4px; }
.pz-modal-select { width: 100%; padding: 10px; border: 1px solid #cfd8dc; border-radius: 8px; font-size: 15px; }
.pz-ingr-liste { display: flex; flex-direction: column; gap: 2px; }
.pz-ingr { display: flex; align-items: center; gap: 8px; padding: 7px 4px; font-size: 14px; border-bottom: 1px solid #f0f0f0; cursor: pointer; }
.pz-ingr input { width: 18px; height: 18px; }
.pz-ingr-tom { font-size: 13px; color: #90a4ae; padding: 8px 0; }
/* Bunn-valg: to sidestilte radioknapper. Bevisst et annet widget enn ingrediens-
   avkryssingsboksene under — det er et enten/eller-valg, ikke en fjern-liste. */
.pz-bunn { display: flex; gap: 10px; }
.pz-bunn-valg { flex: 1; display: flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 8px; border: 1px solid #cfd8dc; border-radius: 8px; font-size: 14px; font-weight: 600; color: #546e7a; cursor: pointer; }
.pz-bunn-valg input { width: 18px; height: 18px; }
.pz-bunn-valg:has(input:checked) { border-color: #ff8a3d; background: #fff4ec; color: #e65100; }
.pz-modal-knapper { display: flex; justify-content: flex-end; gap: 10px; margin-top: 16px; }
.pz-modal-avbryt { border: 1px solid #cfd8dc; background: #fff; color: #546e7a; border-radius: 18px; padding: 9px 18px; font-weight: 700; cursor: pointer; }
.pz-modal-lagre { border: none; background: linear-gradient(#ff8a3d, #f4681f); color: #fff; border-radius: 18px; padding: 9px 22px; font-weight: 800; cursor: pointer; }
.pz-modal-lagre:disabled { opacity: .5; cursor: not-allowed; }
