/* Student campaign picker modal */

.student-campaign-picker-overlay {
  position: fixed;
  inset: 0;
  z-index: 11000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.student-campaign-picker-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.35);
}

.student-campaign-picker-panel {
  position: relative;
  z-index: 1;
  width: min(960px, 100%);
  max-height: min(90dvh, 860px);
  display: flex;
  flex-direction: column;
  background: var(--color-surface);
  border: 1px solid #e5e7eb;
  border-radius: 16px;
  box-shadow: 0 20px 48px rgba(15, 23, 42, 0.12);
  color: #1f2937;
  overflow: hidden;
}

.student-campaign-picker-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 20px;
  border-bottom: 1px solid #e5e7eb;
  background: var(--color-background-alt);
}

.student-campaign-picker-header h2 {
  margin: 0;
  font-family: Cinzel, serif;
  font-size: 1.15rem;
  color: #1d4ed8;
}

.student-campaign-picker-close {
  background: transparent;
  border: none;
  color: #6b7280;
  font-size: 1.25rem;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 8px;
}

.student-campaign-picker-close:hover {
  color: var(--color-text);
  background: #f3f4f6;
}

.student-campaign-picker-sub {
  margin: 0;
  padding: 12px 20px 0;
  color: #6b7280;
  font-size: 0.9rem;
}

.student-campaign-picker-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 12px 20px;
}

.student-campaign-picker-tab {
  background: #f9fafb;
  border: 1px solid #e5e7eb;
  color: var(--color-text-secondary);
  border-radius: 999px;
  padding: 8px 16px;
  cursor: pointer;
  font-size: 0.85rem;
}

.student-campaign-picker-tab:hover {
  background: #eff6ff;
  border-color: #93c5fd;
  color: #1d4ed8;
}

.student-campaign-picker-tab.active {
  background: #dbeafe;
  border-color: #3b82f6;
  color: #1e40af;
  font-weight: 600;
}

.student-campaign-picker-loading,
.student-campaign-picker-empty {
  padding: 32px 20px;
  text-align: center;
  color: #6b7280;
}

.student-campaign-picker-loading--hidden,
.student-campaign-picker-empty--hidden,
.student-campaign-picker-list--hidden {
  display: none;
}

.student-campaign-picker-list {
  flex: 1;
  overflow: auto;
  padding: 0 20px 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.student-campaign-card {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 16px;
  padding: 14px;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  background: var(--color-background-alt);
}

.student-campaign-card__map {
  border-radius: 10px;
  overflow: hidden;
  background: #e5e7eb;
  min-height: 120px;
}

.student-campaign-card__map img {
  width: 100%;
  height: 100%;
  min-height: 120px;
  object-fit: cover;
  display: block;
}

.student-campaign-card__body {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
}

.student-campaign-card__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.student-campaign-card__title {
  margin: 0;
  font-size: 1.05rem;
  color: var(--color-text);
  line-height: 1.3;
}

.student-campaign-card__status {
  flex-shrink: 0;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 4px 8px;
  border-radius: 999px;
}

.student-campaign-card__status--new {
  background: #e0e7ff;
  color: #3730a3;
}

.student-campaign-card__status--active {
  background: #fef3c7;
  color: #92400e;
}

.student-campaign-card__status--passed {
  background: #dcfce7;
  color: #166534;
}

.student-campaign-card__status--finished {
  background: #f3f4f6;
  color: var(--color-text-secondary);
}

.student-campaign-card__story {
  margin: 0;
  color: #6b7280;
  font-size: 0.88rem;
  line-height: 1.45;
}

.student-campaign-card__stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.student-campaign-card__stat-label {
  display: block;
  font-size: 0.72rem;
  color: #6b7280;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  margin-bottom: 2px;
}

.student-campaign-card__stat-value {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--color-text);
}

.student-campaign-card__bar {
  margin-top: 6px;
  height: 6px;
  border-radius: 999px;
  background: #e5e7eb;
  overflow: hidden;
}

.student-campaign-card__bar span {
  display: block;
  height: 100%;
  background: #3b82f6;
  border-radius: 999px;
}

.student-campaign-card__bar--pass span {
  background: #22c55e;
}

.student-campaign-card__rewards,
.student-campaign-card__meta {
  margin: 0;
  font-size: 0.8rem;
  color: #6b7280;
}

.student-campaign-card__rewards {
  color: #b45309;
  font-weight: 600;
}

.student-campaign-card__blocked {
  margin: 0;
  font-size: 0.78rem;
  line-height: 1.4;
  color: #b45309;
}

.student-campaign-card__action {
  align-self: flex-start;
  margin-top: 4px;
}

@media (max-width: 640px) {
  .student-campaign-card {
    grid-template-columns: 1fr;
  }

  .student-campaign-card__map {
    max-height: 160px;
  }

  .student-campaign-card__stats {
    grid-template-columns: 1fr;
  }
}
