.rr-quests-page {
  display: grid;
  gap: 18px;
}

.rq-quests-hero__body {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(240px, 0.7fr);
  gap: 20px;
  align-items: start;
}

.rq-quests-hero__eyebrow,
.rq-quests-panel__eyebrow {
  margin: 0 0 8px;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--accent-2) 76%, var(--text) 24%);
}

.rq-quests-hero__main .section-sub {
  margin-bottom: 0;
  max-width: 38rem;
}

.rq-quests-hero__progress {
  margin-top: 18px;
  display: grid;
  gap: 10px;
}

.rq-quests-hero__progress-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 10px;
  flex-wrap: wrap;
}

.rq-quests-hero__progress-head strong {
  font-size: 1.06rem;
}

.rq-quests-hero__progress-head span,
.rq-quests-hero__progress-copy,
.rq-quests-hero__note {
  color: var(--muted);
}

.rq-progress {
  display: grid;
}

.rq-progress__track {
  width: 100%;
  height: 14px;
  border-radius: 999px;
  border: 1px solid color-mix(in srgb, var(--border) 76%, transparent 24%);
  background: color-mix(in srgb, var(--panel-2) 84%, transparent 16%);
  overflow: hidden;
}

.rq-progress__fill {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, rgba(255, 165, 102, 0.96), rgba(255, 214, 102, 0.94));
  transform-origin: left center;
  transform: scaleX(calc(var(--rq-progress, 0) / 100));
  transition: transform 700ms cubic-bezier(0.2, 0.8, 0.2, 1);
}

.rq-quests-hero__progress-copy {
  margin: 0;
  font-size: 0.98rem;
  line-height: 1.5;
}

.rq-quests-hero__links {
  margin-top: 16px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.rq-quests-hero__aside {
  display: grid;
  gap: 12px;
}

.rq-quests-hero__stat-card {
  padding: 16px;
  border-radius: 18px;
  border: 1px solid color-mix(in srgb, var(--border) 76%, transparent 24%);
  background: color-mix(in srgb, var(--panel-2) 82%, transparent 18%);
  box-shadow: 0 10px 24px rgba(8, 19, 37, 0.16);
  display: grid;
  gap: 6px;
}

.rq-quests-hero__stat-label {
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 700;
}

.rq-quests-hero__stat-value {
  font-size: clamp(1.9rem, 4vw, 2.5rem);
  line-height: 1;
}

.rq-quests-hero__note {
  margin: 0;
  padding: 0 4px;
  font-size: 0.92rem;
  line-height: 1.45;
}

.rq-quests-grid {
  align-items: start;
}

.rq-quests-side {
  display: grid;
  gap: 18px;
}

.rq-quests-panel {
  height: 100%;
}

.rq-quests-panel--ready {
  box-shadow: 0 16px 36px rgba(11, 30, 54, 0.2);
}

.rq-quests-panel__header {
  align-items: flex-start;
}

.rq-quest-list {
  display: grid;
  gap: 12px;
}

.rq-empty-state {
  padding: 8px 0;
}

.rq-empty-state--soft {
  opacity: 0.92;
}

.rq-quest-card {
  border: 1px solid color-mix(in srgb, var(--border) 76%, transparent 24%);
  border-radius: 20px;
  background: color-mix(in srgb, var(--panel) 84%, transparent 16%);
  box-shadow: 0 8px 20px rgba(6, 18, 36, 0.14);
  padding: 18px;
  display: grid;
  gap: 14px;
  transition: transform 170ms ease, box-shadow 170ms ease, border-color 170ms ease;
}

.rq-quest-card:hover {
  transform: translateY(-2px);
  border-color: color-mix(in srgb, rgba(255, 165, 102, 0.75) 50%, var(--border) 50%);
  box-shadow: 0 16px 28px rgba(10, 29, 56, 0.2);
}

.rq-quest-card--assigned {
  background: linear-gradient(180deg, color-mix(in srgb, var(--panel) 88%, transparent 12%), rgba(255, 165, 102, 0.08));
}

.rq-quest-card--submitted {
  background: linear-gradient(180deg, color-mix(in srgb, var(--panel) 86%, transparent 14%), rgba(255, 203, 102, 0.08));
}

.rq-quest-card--approved {
  background: linear-gradient(180deg, color-mix(in srgb, var(--panel) 84%, transparent 16%), rgba(84, 216, 156, 0.08));
}

.rq-quest-card__head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}

.rq-quest-card h3 {
  margin: 0;
  font-size: 1.18rem;
  line-height: 1.3;
}

.rq-quest-badge {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 0.84rem;
  font-weight: 700;
  border: 1px solid transparent;
}

.rq-quest-badge--assigned {
  color: rgba(255, 245, 231, 0.96);
  border-color: rgba(255, 165, 102, 0.42);
  background: rgba(255, 140, 76, 0.24);
}

.rq-quest-badge--submitted {
  color: rgba(255, 241, 211, 0.95);
  border-color: rgba(255, 197, 95, 0.5);
  background: rgba(230, 159, 43, 0.24);
}

.rq-quest-badge--approved {
  color: rgba(226, 255, 240, 0.95);
  border-color: rgba(88, 230, 170, 0.48);
  background: rgba(43, 177, 121, 0.24);
}

.rq-quest-card__points {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-height: 36px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid rgba(63, 214, 200, 0.34);
  background: linear-gradient(90deg, rgba(63, 214, 200, 0.18), rgba(255, 214, 102, 0.14));
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text);
  white-space: nowrap;
}

.rq-quest-card__points strong {
  line-height: 1;
}

.rq-quest-card__copy {
  margin: 0;
  color: var(--muted);
  font-size: 0.97rem;
  line-height: 1.5;
}

.rq-quest-card__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.rq-quest-card__button {
  width: 100%;
  min-height: 54px;
  font-size: 1rem;
  font-weight: 800;
}

[data-display-mode="light"] .rq-quests-hero__stat-card,
[data-display-mode="light"] .rq-quests-panel--ready,
[data-display-mode="light"] .rq-quests-panel--waiting,
[data-display-mode="light"] .rq-quests-panel--done {
  background: linear-gradient(165deg, rgba(255, 255, 255, 0.97), rgba(238, 248, 255, 0.92));
}

[data-display-mode="light"] .rq-quest-card--assigned {
  background: linear-gradient(165deg, rgba(255, 255, 255, 0.97), rgba(255, 243, 225, 0.95));
}

[data-display-mode="light"] .rq-quest-card--submitted {
  background: linear-gradient(165deg, rgba(255, 255, 255, 0.97), rgba(255, 244, 214, 0.95));
}

[data-display-mode="light"] .rq-quest-card--approved {
  background: linear-gradient(165deg, rgba(255, 255, 255, 0.97), rgba(234, 251, 241, 0.94));
}

[data-display-mode="light"] .rq-quest-badge--assigned {
  color: rgba(120, 58, 8, 0.96);
  background: rgba(255, 172, 97, 0.26);
  border-color: rgba(220, 122, 42, 0.42);
}

[data-display-mode="light"] .rq-quest-badge--submitted {
  color: rgba(111, 73, 16, 0.96);
  background: rgba(255, 202, 106, 0.28);
  border-color: rgba(223, 155, 44, 0.44);
}

[data-display-mode="light"] .rq-quest-badge--approved {
  color: rgba(9, 84, 56, 0.95);
  background: rgba(90, 220, 161, 0.28);
  border-color: rgba(35, 157, 111, 0.44);
}

@media (max-width: 979px) {
  .rq-quests-hero__body,
  .rq-quests-grid {
    grid-template-columns: 1fr;
  }

  .rq-quest-card,
  .rq-quests-hero__stat-card {
    padding: 16px;
  }

  .rq-quests-hero__progress-head,
  .rq-quest-card__head {
    align-items: flex-start;
    flex-direction: column;
  }

  .rq-quest-card__points {
    white-space: normal;
  }
}

@media (prefers-reduced-motion: reduce) {
  .rq-progress__fill,
  .rq-quest-card {
    transition: none !important;
  }
}
