/* Activity (ActivityView.swift): dark summary card, filter chips, rows grouped by day on soft grey cards. */

.act-content {
  max-width: 620px;
  margin: 0 auto;
  padding: 24px 20px 48px;
  color: var(--act-ink);
}

/* Summary: total earned, with withdrawn and in review beside it */
.act-summary {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding: 20px;
  margin-bottom: 22px;
  border-radius: 24px;
  color: #fff;
  /* Deep emerald fading into the brand's green-black, lit by one soft mint glow top right (as on iOS). */
  background:
    radial-gradient(circle at calc(100% - 40px) 10px, var(--act-bal-glow), transparent 170px),
    linear-gradient(135deg, var(--act-bal-top) 0%, var(--act-bal-middle) 50%, var(--act-bal-bottom) 100%);
  box-shadow:
    0 12px 40px var(--act-bal-shadow),
    inset 0 1px 0 rgba(255, 255, 255, 0.14),  /* a faint top-lit edge */
    inset 0 0 0 1px rgba(255, 255, 255, 0.04);
}
.act-earned {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}
.act-earned-title {
  font-size: 13px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.62);
}
.act-earned-value {
  font-family: 'Outfit', sans-serif;
  font-size: clamp(22px, 8vw, 30px);
  font-weight: 600;
  letter-spacing: -0.8px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.act-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.act-stat {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.07);
}
.act-stat-icon {
  width: 30px;
  height: 30px;
  flex: none;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  background: rgba(255, 255, 255, 0.12);
}
.act-stat-text {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 1px;
}
.act-stat-title {
  font-size: 11px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.6);
}
.act-stat-value {
  font-family: 'Outfit', sans-serif;
  font-size: 15px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Filter chips: scroll sideways right to the screen edges */
.act-chips {
  display: flex;
  gap: 8px;
  margin: 0 -20px 8px;
  padding: 3px 20px;
  overflow-x: auto;
  scrollbar-width: none;
}
.act-chips::-webkit-scrollbar {
  display: none;
}
.act-chip {
  flex: none;
  height: 38px;
  margin: 3px 0;
  padding: 0 8px 0 14px;
  border-radius: 19px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  font-weight: 600;
  color: var(--act-ink);
  background: var(--act-chip);
  transition: background-color 0.2s, color 0.2s;
}
.act-chip-count {
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  background: var(--surface);
}
.act-chip.is-on {
  color: var(--act-chip-on-text);
  background: var(--act-chip-on);
}
.act-chip.is-on .act-chip-count {
  background: color-mix(in srgb, var(--act-chip-on-text) 16%, transparent);
}

/* Day groups */
.act-day-title {
  padding: 18px 0 10px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: var(--act-muted);
}
.act-day-card {
  overflow: hidden;
  border-radius: 20px;
  background: var(--act-card);
}
.act-row {
  position: relative;
  width: 100%;
  min-height: 66px;
  padding: 13px 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  text-align: left;
  color: var(--act-ink);
  transition: background-color 0.15s;
}
.act-row + .act-row::before {
  content: '';
  position: absolute;
  top: 0;
  left: 70px;
  right: 0;
  height: 1px;
  background: var(--act-line);
}
.act-row:hover,
.act-row:active {
  background: color-mix(in srgb, var(--act-line) 60%, transparent);
}
.act-row-text {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.act-row-title,
.act-row-detail {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.act-row-title {
  font-size: 15px;
  font-weight: 600;
}
.act-row-detail {
  font-size: 12px;
  color: var(--act-muted);
}
.act-row-time {
  font-size: 11px;
  color: color-mix(in srgb, var(--act-muted) 80%, transparent);
}
.act-row-end {
  flex: none;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 5px;
}
.act-row-amount {
  font-family: 'Outfit', sans-serif;
  font-size: 15px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.act-row-amount.is-declined,
.act-detail-amount.is-declined {
  color: var(--act-muted);
  text-decoration: line-through;
}

/* The icon at the start of a row */
.act-glyph {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: center;
}
.act-glyph.is-trade {
  color: var(--act-ink);
  background: var(--surface);
  border: 1px solid var(--act-line);
}
.act-glyph.is-withdrawal {
  color: var(--act-withdrawal);
  background: var(--act-withdrawal-fill);
}
.act-glyph.is-transfer {
  color: var(--act-transfer);
  background: var(--act-transfer-fill);
}
.act-glyph.is-crypto {
  color: #f7931a;
  background: rgba(247, 147, 26, 0.13);
}

/* Status: words as well as colour */
.act-status {
  padding: 3px 8px;
  border-radius: 10px;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}
.act-status.is-large {
  padding: 5px 12px;
  border-radius: 14px;
  font-size: 13px;
}
.act-status.is-pending {
  color: var(--act-pending);
  background: var(--act-pending-fill);
}
.act-status.is-approved {
  color: var(--act-approved);
  background: var(--act-approved-fill);
}
.act-status.is-declined {
  color: var(--act-declined);
  background: var(--act-declined-fill);
}

/* Nothing yet */
.act-empty {
  margin-top: 14px;
  padding: 44px 24px;
  border-radius: 22px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  background: var(--act-card);
}
.act-empty-icon {
  width: 52px;
  height: 52px;
  margin-bottom: 16px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  color: var(--purple);
  background: var(--purple-glow);
}
.act-empty-title {
  font-family: 'Outfit', sans-serif;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.4px;
}
.act-empty-text {
  max-width: 270px;
  padding: 7px 0 18px;
  font-size: 13px;
  line-height: 1.45;
  color: var(--act-muted);
}
.act-empty-button {
  min-height: 44px;
  padding: 0 18px;
  border-radius: 22px;
  font-size: 14px;
  font-weight: 700;
  color: #fff;
  background: var(--act-hero);
}

/* Details sheet */
.act-detail {
  padding: 0 20px 20px;
  color: var(--act-ink);
}
.act-detail-head {
  padding: 22px 0 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  text-align: center;
}
.act-detail-title {
  font-family: 'Outfit', sans-serif;
  font-size: 18px;
  font-weight: 600;
}
.act-detail-amount {
  font-family: 'Outfit', sans-serif;
  font-size: 30px;
  font-weight: 600;
  letter-spacing: -0.8px;
  font-variant-numeric: tabular-nums;
}
.act-detail-card {
  padding: 0 16px;
  border-radius: 18px;
  background: var(--act-card);
}
.act-detail-row {
  padding: 14px 0;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  font-size: 14px;
}
.act-detail-row + .act-detail-row {
  border-top: 1px solid var(--act-line);
}
.act-detail-label {
  flex: none;
  color: var(--act-muted);
}
.act-detail-value {
  min-width: 0;
  font-weight: 600;
  text-align: right;
  overflow-wrap: anywhere;
}
.act-detail-value.is-selectable {
  user-select: all;
  -webkit-user-select: all;
}
.act-primary,
.act-secondary {
  width: 100%;
  min-height: 52px;
  border-radius: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 15px;
  font-weight: 700;
}
.act-primary {
  margin-top: 18px;
  color: #fff;
  background: var(--act-hero);
}
.act-secondary {
  margin-top: 10px;
  color: var(--act-ink);
  border: 1px solid var(--act-line);
}
