/* Canonical QUESTS + DAILY_PLAN V2 surfaces (shell overlay host). */

.shell-placeholder-host:not([hidden]) {
  position: absolute;
  inset: 0;
  z-index: 40;
  overflow: auto;
  padding: 16px 20px 32px;
  background:
    radial-gradient(1200px 600px at 10% -10%, rgba(212, 175, 55, 0.12), transparent 55%),
    linear-gradient(180deg, #12141a 0%, #0c0e13 100%);
}

.friends-quests-surface,
.friends-daily-plan-surface {
  max-width: 960px;
  margin: 0 auto;
  color: #f3efe6;
}

.friends-quests-header,
.friends-daily-header {
  display: flex;
  gap: 16px;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 20px;
}

.friends-quests-kicker,
.friends-daily-kicker {
  margin: 0 0 4px;
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #c9b27a;
}

.friends-quests-title,
.friends-daily-title {
  margin: 0 0 8px;
  font-size: clamp(1.5rem, 2.4vw, 2rem);
  font-weight: 700;
}

.friends-quests-lead,
.friends-daily-explain,
.friends-daily-meta,
.friends-daily-points,
.friends-daily-streak,
.friends-daily-note,
.friends-quests-reward-sum {
  margin: 0 0 6px;
  color: #cfc6b4;
  line-height: 1.45;
}

.friends-quests-degraded,
.friends-quests-empty,
.friends-daily-empty {
  padding: 12px 14px;
  border: 1px solid rgba(255, 180, 80, 0.35);
  border-radius: 10px;
  background: rgba(255, 160, 60, 0.08);
  color: #ffd9a8;
}

.friends-quests-group {
  margin: 18px 0;
}

.friends-quests-group-title,
.friends-daily-path-title {
  margin: 0 0 10px;
  font-size: 1rem;
  color: #e8dfc8;
}

.friends-quests-grid,
.friends-daily-path {
  display: grid;
  gap: 12px;
}

.friends-quest-card,
.friends-daily-task {
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 14px 16px;
  background: rgba(255, 255, 255, 0.03);
}

.friends-quest-card.is-claimable {
  border-color: rgba(80, 200, 120, 0.45);
  background: rgba(40, 120, 70, 0.12);
}

.friends-quest-card.is-claimed,
.friends-daily-task.is-done {
  opacity: 0.72;
}

.friends-quest-card-head,
.friends-daily-task header {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-bottom: 6px;
}

.friends-quest-identity {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  min-width: 0;
}

.friends-quest-poster {
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  border-radius: 8px;
  object-fit: cover;
  background: rgba(255, 255, 255, 0.06);
}

.friends-quest-poster--fallback {
  display: grid;
  place-items: center;
  font-size: 1.1rem;
}

.friends-quest-game,
.friends-quest-badge,
.friends-daily-task-state {
  display: block;
  margin: 0 0 2px;
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  text-transform: none;
  color: #c9b27a;
}

.friends-quest-title,
.friends-daily-task h3 {
  margin: 0;
  font-size: 1.05rem;
}

.friends-quest-desc,
.friends-daily-task p {
  margin: 0 0 10px;
  color: #bdb3a1;
  font-size: 0.92rem;
}

.friends-quest-progress,
.friends-daily-task-progress {
  position: relative;
  height: 28px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  overflow: hidden;
  margin-bottom: 10px;
}

.friends-quest-progress::before,
.friends-daily-task-progress::before {
  content: '';
  position: absolute;
  inset: 0 auto 0 0;
  width: var(--pct, 0%);
  background: linear-gradient(90deg, #2f8f55, #d4af37);
}

.friends-quest-progress span,
.friends-daily-task-progress span,
.friends-daily-task-progress strong {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  height: 100%;
  padding: 0 12px;
  font-size: 0.85rem;
}

.friends-quest-footer {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  align-items: center;
  justify-content: space-between;
}

.friends-quest-reward {
  color: #d4af37;
  font-weight: 600;
}

.friends-quest-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.friends-quest-claimed {
  color: #8fdfaa;
  font-size: 0.9rem;
}

.friends-daily-task.is-current {
  border-color: rgba(212, 175, 55, 0.5);
}

.friends-daily-complete,
.friends-daily-tomorrow {
  margin-top: 18px;
  padding: 14px 16px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.04);
}

.friends-daily-complete h3,
.friends-daily-tomorrow h3 {
  margin: 0 0 6px;
}

@media (max-width: 720px) {
  .shell-placeholder-host:not([hidden]) {
    padding: 12px;
  }

  .friends-quests-header,
  .friends-daily-header {
    flex-direction: column;
  }

  .friends-quest-footer {
    align-items: stretch;
  }

  .friends-quest-actions {
    width: 100%;
  }

  .friends-quest-actions .shell-btn {
    flex: 1 1 auto;
  }
}
