/* =========================================================================
   QuizOrd – eget lager ovanpå Bootstrap.
   Designmål: stort, tydligt, lekfullt och lugnt nog för att kunna fokusera.
   ====================================================================== */

:root {
  --qo-indigo: #4f46e5;
  --qo-indigo-dark: #3730a3;
  --qo-green: #10b981;
  --qo-green-dark: #047857;
  --qo-orange: #f59e0b;
  --qo-red: #ef4444;
  --qo-blue: #38bdf8;
  --qo-purple: #a855f7;
  --qo-ink: #1e1b4b;
  --qo-bg: #f5f4ff;
  --qo-card: #ffffff;
  --qo-radius: 18px;
  --qo-shadow: 0 10px 30px rgba(30, 27, 75, .08);
}

body.qo-body {
  background:
    radial-gradient(1200px 600px at 10% -10%, #e0e7ff 0%, transparent 60%),
    radial-gradient(900px 500px at 100% 0%, #fae8ff 0%, transparent 55%),
    var(--qo-bg);
  color: var(--qo-ink);
  font-size: 1.02rem;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.qo-main { flex: 1 0 auto; }

.qo-footer {
  padding: 1.5rem 0 2rem;
  text-align: center;
  color: #6b7280;
  font-size: .85rem;
}

/* ---------------------------------------------------------------- Navbar */

.qo-navbar {
  background: rgba(255, 255, 255, .88);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(79, 70, 229, .12);
}

.qo-navbar .navbar-brand { color: var(--qo-indigo-dark); font-size: 1.35rem; }
.qo-logo { font-size: 1.4rem; }
.qo-navbar .nav-link { font-weight: 600; color: #4b5563; }
.qo-navbar .nav-link:hover { color: var(--qo-indigo); }

.qo-navpoints {
  background: linear-gradient(135deg, #fef3c7, #fde68a);
  border-radius: 999px;
  padding: .35rem .9rem;
  font-size: .95rem;
  color: #92400e;
  white-space: nowrap;
}
.qo-navpoints-icon { margin-right: .2rem; }

.qo-navlevel { min-width: 110px; }
.qo-levelbadge {
  display: inline-block;
  font-size: .75rem;
  font-weight: 700;
  color: var(--qo-indigo-dark);
}
.qo-levelbar {
  height: 6px;
  background: #e5e7eb;
  border-radius: 999px;
  overflow: hidden;
  margin-top: 2px;
}
.qo-levelbar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--qo-indigo), var(--qo-purple));
  border-radius: 999px;
  transition: width .5s ease;
}

.qo-userbtn {
  background: #eef2ff;
  border-radius: 999px;
  font-weight: 600;
  color: var(--qo-indigo-dark);
  padding: .35rem .8rem;
}
.qo-avatar { font-size: 1.2rem; }

/* ------------------------------------------------------------------ Kort */

.qo-card {
  border: none;
  border-radius: var(--qo-radius);
  box-shadow: var(--qo-shadow);
  background: var(--qo-card);
}

.qo-card-play {
  background: linear-gradient(160deg, #ffffff 0%, #f5f3ff 100%);
  border: 2px solid rgba(79, 70, 229, .1);
}

.qo-btn-play {
  border-radius: 999px;
  font-weight: 700;
  padding-inline: 1.6rem;
  box-shadow: 0 6px 0 rgba(0, 0, 0, .12);
  transition: transform .08s ease, box-shadow .08s ease;
}
.qo-btn-play:active {
  transform: translateY(4px);
  box-shadow: 0 2px 0 rgba(0, 0, 0, .12);
}

.qo-mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .95rem; }

/* --------------------------------------------------------- Inloggningen */

.qo-hero-logo { font-size: 4rem; line-height: 1; }

.qo-accountbtn {
  border: 2px solid #e0e7ff;
  background: #fff;
  border-radius: 14px;
  padding: .6rem .9rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  transition: all .12s ease;
}
.qo-accountbtn:hover { border-color: var(--qo-indigo); transform: translateY(-2px); }
.qo-accountbtn-avatar { font-size: 1.5rem; }

.qo-avatarpick {
  cursor: pointer;
  border: 2px solid #e5e7eb;
  border-radius: 14px;
  width: 52px;
  height: 52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  transition: all .12s ease;
}
.qo-avatarpick input { display: none; }
.qo-avatarpick:hover { border-color: #a5b4fc; }
.qo-avatarpick.is-active {
  border-color: var(--qo-indigo);
  background: #eef2ff;
  transform: scale(1.06);
}

/* Symbolväljare för gloslistor – många symboler i en rullbar ruta */
.qo-iconpicker {
  max-height: 260px;
  overflow-y: auto;
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  padding: .75rem;
  background: #fcfcff;
}
.qo-iconpicker-group + .qo-iconpicker-group { margin-top: .9rem; }
.qo-iconpicker-label {
  font-size: .72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: #6b7280;
  margin-bottom: .35rem;
}
.qo-iconpicker-icons { display: flex; flex-wrap: wrap; gap: .4rem; }
.qo-iconpicker .qo-avatarpick { width: 44px; height: 44px; font-size: 1.35rem; }
.qo-iconcustom { margin-top: .75rem; max-width: 280px; }
.qo-iconcustom-input { font-size: 1.3rem; text-align: center; }
.qo-iconcustom-input.is-active { border-color: var(--qo-indigo); background: #eef2ff; }

/* --------------------------------------------------------- Startsidan */

.qo-greeting {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}
.qo-greeting-avatar {
  font-size: 3rem;
  background: #fff;
  border-radius: 20px;
  width: 72px;
  height: 72px;
  display: grid;
  place-items: center;
  box-shadow: var(--qo-shadow);
}
.qo-greeting-points { text-align: right; }
.qo-greeting-points-value { font-size: 1.7rem; font-weight: 800; color: #b45309; }
.qo-greeting-points-label { font-size: .8rem; color: #6b7280; }

.qo-lvl-chip {
  background: var(--qo-indigo);
  color: #fff;
  border-radius: 999px;
  padding: .1rem .6rem;
  font-weight: 700;
  font-size: .8rem;
}

.qo-xpwrap {
  background: #fff;
  border-radius: var(--qo-radius);
  padding: .9rem 1.1rem;
  box-shadow: var(--qo-shadow);
}
.qo-xpbar {
  height: 14px;
  background: #e5e7eb;
  border-radius: 999px;
  overflow: hidden;
}
.qo-xpbar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--qo-indigo), var(--qo-purple), #ec4899);
  border-radius: 999px;
  transition: width .6s cubic-bezier(.2, .9, .3, 1);
}

.qo-tile {
  border-radius: var(--qo-radius);
  padding: 1rem;
  color: #fff;
  box-shadow: var(--qo-shadow);
  height: 100%;
}
.qo-tile-value { font-size: 1.9rem; font-weight: 800; line-height: 1.1; }
.qo-tile-label { font-size: .82rem; opacity: .95; }
.qo-tile-green { background: linear-gradient(150deg, #34d399, var(--qo-green-dark)); }
.qo-tile-orange { background: linear-gradient(150deg, #fbbf24, #b45309); }
.qo-tile-blue { background: linear-gradient(150deg, #38bdf8, #0369a1); }
.qo-tile-purple { background: linear-gradient(150deg, #c084fc, #6d28d9); }

.qo-modegrid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: .6rem;
}
.qo-mode input { position: absolute; opacity: 0; pointer-events: none; }
.qo-mode { cursor: pointer; }
.qo-mode-inner {
  display: block;
  border: 2px solid #e5e7eb;
  border-radius: 14px;
  padding: .7rem .8rem;
  height: 100%;
  transition: all .12s ease;
  background: #fff;
}
.qo-mode:hover .qo-mode-inner { border-color: #a5b4fc; }
.qo-mode input:checked + .qo-mode-inner {
  border-color: var(--qo-indigo);
  background: #eef2ff;
  box-shadow: 0 0 0 3px rgba(79, 70, 229, .12);
}
.qo-mode-icon { font-size: 1.5rem; display: block; }
.qo-mode-label { font-weight: 700; display: block; }
.qo-mode-desc { font-size: .75rem; color: #6b7280; display: block; margin-top: .15rem; }

.qo-countgroup .btn { min-width: 68px; font-weight: 700; }

.qo-badge {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  background: #fef9c3;
  border: 1px solid #fde047;
  border-radius: 999px;
  padding: .25rem .7rem;
  font-size: .82rem;
  font-weight: 600;
  color: #713f12;
}
.qo-badge-icon { font-size: 1.1rem; }
.qo-badge.is-locked {
  background: #f3f4f6;
  border-color: #e5e7eb;
  color: #9ca3af;
  filter: grayscale(1);
}

.qo-sessionlist li {
  display: flex;
  align-items: center;
  gap: .7rem;
  padding: .5rem 0;
  border-bottom: 1px solid #f3f4f6;
}
.qo-sessionlist li:last-child { border-bottom: none; }
.qo-sessionlist-icon { font-size: 1.4rem; }
.qo-sessionlist-points { font-weight: 800; color: #b45309; }

/* ------------------------------------------------------------ Gloslistor */

.qo-listcard-icon {
  font-size: 2.2rem;
  background: #eef2ff;
  border-radius: 14px;
  width: 56px;
  height: 56px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}
.qo-listcard { transition: transform .12s ease; }
.qo-listcard:hover { transform: translateY(-3px); }
.qo-archived { opacity: .65; }

.qo-progress {
  height: 10px;
  background: #e5e7eb;
  border-radius: 999px;
  overflow: hidden;
}
.qo-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--qo-green), #34d399);
  border-radius: 999px;
  transition: width .4s ease;
}

.qo-wordtable th { font-size: .78rem; text-transform: uppercase; color: #6b7280; }
.qo-wordtable td { font-size: 1rem; }
.qo-inactive { opacity: .5; }

.qo-mastery { display: inline-flex; gap: 3px; }
.qo-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #e5e7eb;
  display: inline-block;
}
.qo-dot.is-on { background: var(--qo-green); }

/* =========================================================================
   Förhöret
   ====================================================================== */

.qo-quiz {
  position: relative;
  max-width: 760px;
  margin: 0 auto;
  padding: 0 .25rem 3rem;
}

.qo-quizbar {
  display: flex;
  align-items: center;
  gap: .75rem;
  background: #fff;
  border-radius: 999px;
  padding: .5rem .8rem;
  box-shadow: var(--qo-shadow);
  margin-bottom: 1.5rem;
}
.qo-quizbar-exit,
.qo-quizbar-sound {
  border: none;
  background: #f3f4f6;
  color: #6b7280;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  text-decoration: none;
}
.qo-quizbar-exit:hover { background: #fee2e2; color: var(--qo-red); }
.qo-quizbar-sound.is-off { opacity: .5; }
.qo-quizbar-progress { flex: 1 1 auto; min-width: 0; }
.qo-quizbar-progress .small { color: #6b7280; flex-wrap: nowrap; gap: .5rem; }
/* Listnamnet kortas av i stället för att radbrytas – räknaren ska alltid få plats. */
.qo-quizbar-progress .small > span:first-child {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  min-width: 0;
}
.qo-quizbar-progress .small > span:last-child { white-space: nowrap; flex: 0 0 auto; }
.qo-quizbar-score { text-align: right; flex: 0 0 auto; }
.qo-quizbar-points { font-weight: 800; font-size: 1.15rem; color: #b45309; white-space: nowrap; }
.qo-combo { font-size: .72rem; font-weight: 700; color: #6b7280; white-space: nowrap; }
.qo-combo.is-hot { color: var(--qo-red); animation: qo-pulse 1s infinite; }

@keyframes qo-pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.08); }
}

.qo-stage { position: relative; }

.qo-loading { text-align: center; padding: 4rem 1rem; }

.qo-question {
  background: #fff;
  border-radius: 24px;
  padding: 1.5rem 1.25rem 1.25rem;
  box-shadow: var(--qo-shadow);
}
.qo-pop { animation: qo-pop .28s cubic-bezier(.2, .9, .3, 1.2); }
@keyframes qo-pop {
  from { opacity: 0; transform: translateY(12px) scale(.98); }
  to { opacity: 1; transform: none; }
}

.qo-question-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: .5rem;
  margin-bottom: 1.25rem;
}
.qo-exercise-chip {
  background: #eef2ff;
  color: var(--qo-indigo-dark);
  border-radius: 999px;
  padding: .3rem .85rem;
  font-weight: 700;
  font-size: .9rem;
}
.qo-exercise-icon { font-size: 1.05rem; }
.qo-points-chip {
  background: #fef3c7;
  color: #92400e;
  border-radius: 999px;
  padding: .3rem .8rem;
  font-weight: 700;
  font-size: .85rem;
  white-space: nowrap;
}

.qo-question-body { text-align: center; }

.qo-prompt-label { color: #6b7280; font-size: .9rem; margin-bottom: .4rem; }
.qo-prompt {
  font-size: clamp(1.9rem, 7vw, 2.9rem);
  font-weight: 800;
  line-height: 1.15;
  color: var(--qo-ink);
  word-break: break-word;
}
.qo-prompt-sub { color: #6b7280; font-size: .95rem; margin-top: .3rem; }
.qo-hint {
  margin-top: .6rem;
  display: inline-block;
  background: #fffbeb;
  border: 1px dashed #fcd34d;
  border-radius: 12px;
  padding: .3rem .75rem;
  font-size: .9rem;
  color: #92400e;
}

.qo-showword {
  font-size: clamp(2rem, 8vw, 3.2rem);
  font-weight: 800;
  letter-spacing: .04em;
  color: var(--qo-indigo-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  flex-wrap: wrap;
}
.qo-speak {
  border: none;
  background: #eef2ff;
  border-radius: 50%;
  width: 44px;
  height: 44px;
  font-size: 1.2rem;
  line-height: 1;
}

.qo-answerwrap { margin-top: 1.5rem; }
.qo-answerinput {
  width: 100%;
  max-width: 460px;
  font-size: clamp(1.5rem, 6vw, 2.2rem);
  font-weight: 700;
  text-align: center;
  border: 3px solid #e0e7ff;
  border-radius: 16px;
  padding: .6rem .8rem;
  outline: none;
  transition: border-color .15s ease, box-shadow .15s ease;
  letter-spacing: .03em;
}
.qo-answerinput:focus {
  border-color: var(--qo-indigo);
  box-shadow: 0 0 0 4px rgba(79, 70, 229, .14);
}
.qo-lengthhint { color: #9ca3af; font-size: .82rem; margin-top: .4rem; }

/* Rutor för luckor och hänga gubben */
.qo-cells {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: .4rem;
  margin: 1.5rem 0 .5rem;
}
.qo-cell {
  width: 46px;
  height: 56px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  font-size: 1.7rem;
  font-weight: 800;
  text-transform: lowercase;
  background: #f3f4f6;
  border: 2px solid transparent;
  color: var(--qo-ink);
}
.qo-cell.is-fixed { background: #e0e7ff; color: var(--qo-indigo-dark); }
.qo-cell.is-found {
  background: #d1fae5;
  color: var(--qo-green-dark);
  border-color: #6ee7b7;
  animation: qo-pop .25s ease;
}
.qo-cell.is-blank { background: #fff; border-bottom: 4px solid #c7d2fe; border-radius: 6px; }
.qo-cell.is-space { background: transparent; width: 22px; }
.qo-cell.is-input {
  background: #fff;
  border: 3px solid #c7d2fe;
  text-align: center;
  font-size: 1.6rem;
  font-weight: 800;
  padding: 0;
}
.qo-cell.is-input:focus {
  outline: none;
  border-color: var(--qo-indigo);
  box-shadow: 0 0 0 4px rgba(79, 70, 229, .14);
}

@media (max-width: 480px) {
  .qo-cell { width: 36px; height: 46px; font-size: 1.3rem; }
  .qo-cell.is-input { font-size: 1.25rem; }
}

/* Flervalsalternativ */
.qo-options {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: .7rem;
  margin-top: 1.5rem;
}
.qo-option {
  border: 3px solid #e0e7ff;
  background: #fff;
  border-radius: 16px;
  padding: .9rem 1rem;
  font-size: 1.3rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: .6rem;
  transition: all .12s ease;
}
.qo-option:hover { border-color: var(--qo-indigo); transform: translateY(-2px); }
.qo-option-key {
  background: #eef2ff;
  color: var(--qo-indigo-dark);
  border-radius: 8px;
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  font-size: .9rem;
  flex: 0 0 auto;
}
.qo-option.is-dim { opacity: .4; }
.qo-option.is-picked { border-color: var(--qo-indigo); background: #eef2ff; }

/* Bokstavstangentbord */
.qo-keyboard {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: .35rem;
  margin-top: 1.2rem;
}
.qo-key {
  width: 44px;
  height: 46px;
  border-radius: 10px;
  border: 2px solid #e0e7ff;
  background: #fff;
  font-weight: 800;
  font-size: 1.05rem;
  color: var(--qo-ink);
  transition: all .1s ease;
}
.qo-key:hover:not(:disabled) { border-color: var(--qo-indigo); background: #eef2ff; }
.qo-key:disabled { cursor: default; }
.qo-key.is-hit { background: #d1fae5; border-color: #6ee7b7; color: var(--qo-green-dark); }
.qo-key.is-miss { background: #fee2e2; border-color: #fca5a5; color: #b91c1c; text-decoration: line-through; }

@media (max-width: 480px) {
  .qo-key { width: 34px; height: 40px; font-size: .95rem; }
}

.qo-wronglist { margin-top: .8rem; font-size: .9rem; color: #6b7280; min-height: 1.6rem; }
.qo-wronglist-label { font-weight: 600; }
.qo-wronglist-clean { color: var(--qo-green-dark); }
.qo-wrongletter {
  display: inline-block;
  background: #fee2e2;
  color: #b91c1c;
  border-radius: 6px;
  padding: 0 .35rem;
  margin-right: .2rem;
  font-weight: 800;
}

.qo-question-foot { margin-top: 1.5rem; }
.qo-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

/* ------------------------------------------------------------- Facit */

.qo-feedback { padding: 1rem 0; }
.qo-fb {
  border-radius: 24px;
  padding: 2rem 1.25rem;
  text-align: center;
  box-shadow: var(--qo-shadow);
  animation: qo-pop .3s cubic-bezier(.2, .9, .3, 1.2);
}
.qo-fb-ok { background: linear-gradient(160deg, #ecfdf5, #d1fae5); border: 3px solid #6ee7b7; }
.qo-fb-no { background: linear-gradient(160deg, #fff7ed, #ffedd5); border: 3px solid #fdba74; }
.qo-fb-icon { font-size: 3.2rem; line-height: 1; }
.qo-fb-title { font-size: 1.5rem; font-weight: 800; margin-top: .3rem; }
.qo-fb-word {
  font-size: clamp(1.8rem, 7vw, 2.6rem);
  font-weight: 800;
  letter-spacing: .05em;
  margin: .5rem 0;
  word-break: break-word;
}
.qo-fb-points { font-size: 1.4rem; font-weight: 800; color: #b45309; }
.qo-fb-mult {
  background: var(--qo-red);
  color: #fff;
  border-radius: 999px;
  padding: .1rem .6rem;
  font-size: .8rem;
  vertical-align: middle;
}
.qo-fb-master {
  margin-top: .6rem;
  font-weight: 800;
  color: var(--qo-green-dark);
  font-size: 1.1rem;
}
.qo-fb-progress { margin-top: .5rem; color: #4b5563; font-size: .92rem; }
.qo-fb-your { color: #7c2d12; font-size: .95rem; }
.qo-fb-note { color: #78350f; font-size: .9rem; margin-top: .7rem; }
.qo-fb-meaning { margin-top: .5rem; font-weight: 600; color: #431407; }
.qo-fb-listen { margin-top: .8rem; border-radius: 999px; }

.qo-diff-ok { color: var(--qo-green-dark); }
.qo-diff-bad {
  color: #b91c1c;
  background: #fee2e2;
  border-radius: 6px;
  padding: 0 .12em;
}

.qo-newbadges { margin-top: 1rem; }
.qo-newbadge {
  background: #fef9c3;
  border: 2px solid #fde047;
  border-radius: 14px;
  padding: .6rem 1rem;
  margin-top: .5rem;
  font-size: 1rem;
  text-align: center;
}
.qo-newbadge span { font-size: 1.3rem; }
.qo-levelup {
  margin-top: 1rem;
  text-align: center;
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--qo-purple);
}

/* --------------------------------------------------------- Slutresultat */

.qo-summary-card {
  background: #fff;
  border-radius: 24px;
  padding: 2rem 1.25rem;
  text-align: center;
  box-shadow: var(--qo-shadow);
}
.qo-summary-stars { font-size: 3rem; line-height: 1; }
.qo-star { color: #e5e7eb; }
.qo-star.is-on { color: var(--qo-orange); animation: qo-pop .4s ease; }
.qo-summary-title { font-size: 1.6rem; font-weight: 800; margin: .5rem 0; }
.qo-summary-points { font-size: 2.2rem; font-weight: 800; color: #b45309; }

.qo-summary-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: .5rem;
  margin: 1.5rem 0;
}
.qo-summary-grid > div {
  background: #f5f3ff;
  border-radius: 14px;
  padding: .8rem .4rem;
  display: flex;
  flex-direction: column;
}
.qo-summary-value { font-size: 1.5rem; font-weight: 800; color: var(--qo-indigo-dark); }
.qo-summary-grid span:last-child { font-size: .75rem; color: #6b7280; }

.qo-summary-level {
  background: #f9fafb;
  border-radius: 14px;
  padding: .8rem 1rem;
  text-align: left;
}
.qo-summary-mastered {
  margin-top: 1rem;
  background: #ecfdf5;
  border-radius: 14px;
  padding: .7rem 1rem;
  color: var(--qo-green-dark);
}
.qo-summary-details { margin-top: 1.2rem; text-align: left; }
.qo-summary-details summary { cursor: pointer; font-weight: 600; color: var(--qo-indigo); }
.qo-summary-details ul { list-style: none; padding: .5rem 0 0; margin: 0; }
.qo-summary-details li { padding: .3rem 0; border-bottom: 1px solid #f3f4f6; }
.qo-summary-details li.is-no { color: #b45309; }

.qo-summary-actions {
  margin-top: 1.5rem;
  display: flex;
  gap: .75rem;
  justify-content: center;
  flex-wrap: wrap;
}

.qo-confetti {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1080;
  display: none;
}
.qo-confetti.is-active { display: block; }

/* ------------------------------------------------------------ Statistik */

.qo-statgrid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: .75rem;
}
.qo-badgegrid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: .75rem;
}
.qo-badgecard {
  background: #fff;
  border-radius: 16px;
  padding: 1rem;
  text-align: center;
  box-shadow: var(--qo-shadow);
  border: 2px solid transparent;
}
.qo-badgecard.is-earned { border-color: #fde047; background: linear-gradient(160deg, #fffbeb, #fef9c3); }
.qo-badgecard.is-locked { opacity: .55; filter: grayscale(.8); }
.qo-badgecard-icon { font-size: 2.2rem; line-height: 1; }
.qo-badgecard-label { font-weight: 700; margin-top: .3rem; }
.qo-badgecard-desc { font-size: .78rem; color: #6b7280; }

/* Respektera användare som inte vill ha rörelse */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}
