/* ═══════════════════════════════════════════
   SPENDEN PLUGIN CSS v3.0
   Exact Figma: #0d0d0d bg + #F5D800 yellow
   Font: system → looks clean on all screens
═══════════════════════════════════════════ */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

/* ── RESET ── */
.sp-wrap *, .sp-dash * { box-sizing: border-box; margin: 0; padding: 0; }

/* ══════════════════════════════
   DONATION FORM
══════════════════════════════ */
.sp-wrap {
  font-family: 'Inter', system-ui, sans-serif;
  background: #0d0d0d;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 60px 20px 80px;
  color: #e0e0e0;
}

/* TOP */
.sp-top { text-align: center; margin-bottom: 32px; max-width: 600px; }
.sp-badge {
  display: inline-block;
  color: #F5D800;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 3px;
  margin-bottom: 16px;
}
.sp-heading {
  font-size: clamp(28px, 5vw, 52px);
  font-weight: 800;
  color: #fff;
  line-height: 1.1;
  margin-bottom: 12px;
  letter-spacing: -0.5px;
}
.sp-heading em { color: #F5D800; font-style: normal; }
.sp-sub { color: #777; font-size: 14px; }

/* TABS */
.sp-tabs {
  display: flex;
  gap: 6px;
  margin-bottom: 28px;
}
.sp-tab {
  padding: 8px 24px;
  border-radius: 999px;
  border: 1px solid #2a2a2a;
  background: transparent;
  color: #666;
  font: 600 13px 'Inter', sans-serif;
  cursor: default;
  transition: all .2s;
  display: flex;
  align-items: center;
  gap: 6px;
}
.sp-tab-active {
  background: #F5D800;
  color: #000;
  border-color: #F5D800;
}
.sp-tab-done {
  border-color: #2a2a2a;
  color: #555;
}
.sp-tab-done::before {
  content: '';
  display: inline-block;
  width: 14px; height: 14px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='%23555'%3E%3Cpath fill-rule='evenodd' d='M10 18a8 8 0 100-16 8 8 0 000 16zm3.707-9.293a1 1 0 00-1.414-1.414L9 10.586 7.707 9.293a1 1 0 00-1.414 1.414l2 2a1 1 0 001.414 0l4-4z'/%3E%3C/svg%3E") center/contain no-repeat;
}

/* SCREENS */
.sp-screen { display: none; width: 100%; max-width: 500px; }
.sp-screen-active { display: block; }
.sp-screen-success { display: none; text-align: center; max-width: 460px; }

/* CARD */
.sp-card {
  background: #161616;
  border: 1px solid #222;
  border-radius: 12px;
  padding: 28px;
}
.sp-card-title {
  font-size: 16px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 20px;
}

/* AMOUNT BUTTONS */
.sp-amounts {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 14px;
}
.sp-amt-btn {
  background: #1e1e1e;
  border: 1.5px solid #2a2a2a;
  color: #ccc;
  padding: 14px 8px;
  border-radius: 8px;
  font: 600 15px 'Inter', sans-serif;
  cursor: pointer;
  transition: all .15s;
}
.sp-amt-btn:hover { border-color: #F5D800; color: #F5D800; }
.sp-amt-selected {
  background: #F5D800 !important;
  color: #000 !important;
  border-color: #F5D800 !important;
}

/* CUSTOM INPUT */
.sp-custom-wrap { position: relative; margin-bottom: 16px; }
.sp-euro {
  position: absolute; left: 14px; top: 50%;
  transform: translateY(-50%);
  color: #555; font-size: 15px;
}
.sp-input {
  width: 100%;
  background: #1e1e1e;
  border: 1.5px solid #2a2a2a;
  border-radius: 8px;
  color: #e0e0e0;
  padding: 13px 14px;
  font: 400 14px 'Inter', sans-serif;
  outline: none;
  transition: border-color .2s;
}
.sp-custom-input { padding-left: 32px; }
.sp-input:focus { border-color: #F5D800; }
.sp-input::placeholder { color: #444; }
.sp-textarea { resize: vertical; min-height: 100px; }
input[type=number]::-webkit-inner-spin-button { -webkit-appearance: none; }

/* TRUST ROW */
.sp-trust-row {
  display: flex;
  gap: 12px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}
.sp-trust-row span {
  display: flex;
  align-items: center;
  gap: 5px;
  color: #666;
  font-size: 12px;
}
.sp-trust-icon {
  width: 14px; height: 14px;
  color: #F5D800;
  flex-shrink: 0;
}

/* BUTTONS */
.sp-btn-yellow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: #F5D800;
  color: #000;
  border: none;
  padding: 14px 24px;
  border-radius: 8px;
  font: 700 15px 'Inter', sans-serif;
  cursor: pointer;
  transition: background .15s, transform .1s;
  text-decoration: none;
}
.sp-btn-yellow:hover { background: #e0c700; transform: translateY(-1px); }
.sp-btn-full { width: 100%; }
.sp-btn-dark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #1e1e1e;
  border: 1.5px solid #2a2a2a;
  color: #ccc;
  padding: 14px 24px;
  border-radius: 8px;
  font: 600 14px 'Inter', sans-serif;
  cursor: pointer;
  transition: border-color .15s;
}
.sp-btn-dark:hover { border-color: #F5D800; color: #F5D800; }
.sp-btn-arrow { width: 16px; height: 16px; }
.sp-btn-row {
  display: flex;
  gap: 10px;
}
.sp-btn-row .sp-btn-yellow { flex: 1; }

/* FIELDS */
.sp-field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 12px;
}
.sp-field-group { display: flex; flex-direction: column; gap: 6px; margin-bottom: 12px; }
.sp-label { color: #777; font-size: 12px; font-weight: 500; }

/* PAYMENT LIST */
.sp-amount-display { color: #888; font-size: 13px; margin-bottom: 16px; }
.sp-yellow-text { color: #F5D800; }
.sp-payment-list { display: flex; flex-direction: column; gap: 8px; margin-bottom: 20px; }
.sp-pm {
  display: flex;
  align-items: center;
  gap: 14px;
  background: #1e1e1e;
  border: 1.5px solid #2a2a2a;
  border-radius: 10px;
  padding: 14px 16px;
  cursor: pointer;
  transition: border-color .15s, background .15s;
}
.sp-pm input[type=radio] { display: none; }
.sp-pm-selected {
  border-color: #F5D800;
  background: rgba(245, 216, 0, 0.06);
}
.sp-pm-icon {
  width: 38px; height: 38px;
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.sp-pm-icon svg { width: 20px; height: 20px; }
.sp-pm-icon-sepa    { background: #F5D800; color: #000; }
.sp-pm-icon-paypal  { background: #1a3a6b; color: #fff; }
.sp-pm-icon-card    { background: #2a2a2a; color: #aaa; }
.sp-pm-info { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.sp-pm-name { color: #e0e0e0; font-size: 14px; font-weight: 600; }
.sp-pm-desc { color: #666; font-size: 12px; }
.sp-pm-check {
  width: 20px; height: 20px;
  color: #F5D800;
  opacity: 0;
  transition: opacity .15s;
}
.sp-pm-check svg { width: 20px; height: 20px; }
.sp-pm-selected .sp-pm-check { opacity: 1; }
.sp-jetzt-btn { gap: 8px; }

/* ERROR */
.sp-error {
  color: #ff6b6b;
  font-size: 13px;
  margin-bottom: 14px;
  min-height: 0;
}

/* SUCCESS */
.sp-success-icon {
  width: 64px; height: 64px;
  background: rgba(245,216,0,.12);
  border: 2px solid rgba(245,216,0,.4);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 20px;
  color: #F5D800;
  animation: sp-pop .5s cubic-bezier(.34,1.56,.64,1);
}
.sp-success-icon svg { width: 30px; height: 30px; }
@keyframes sp-pop { from { transform: scale(0); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.sp-success-title {
  font-size: 32px; font-weight: 800; color: #fff;
  margin-bottom: 14px;
}
.sp-success-text {
  color: #888; font-size: 14px; line-height: 1.7;
  margin-bottom: 8px;
}
.sp-weiterspende-btn { margin-top: 24px; padding: 13px 32px; }

/* ══════════════════════════════
   FRONTEND DASHBOARD
══════════════════════════════ */
.sp-dash {
  font-family: 'Inter', system-ui, sans-serif;
  background: #0d0d0d;
  min-height: 100vh;
  padding: 40px 24px 80px;
  color: #e0e0e0;
  max-width: 1200px;
  margin: 0 auto;
}

/* HEADER */
.sp-dash-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 28px;
  padding-bottom: 20px;
  border-bottom: 1px solid #1e1e1e;
  flex-wrap: wrap;
  gap: 14px;
}
.sp-dash-title { font-size: 26px; font-weight: 800; color: #fff; margin-bottom: 4px; }
.sp-dash-subtitle { color: #555; font-size: 13px; }
.sp-dash-actions { display: flex; gap: 10px; }
.sp-dash-export-btn {
  display: inline-flex; align-items: center; gap: 6px;
  background: #1e1e1e; border: 1.5px solid #2a2a2a;
  color: #ccc; padding: 9px 18px; border-radius: 8px;
  font: 600 13px 'Inter', sans-serif; text-decoration: none;
  transition: border-color .15s, color .15s;
}
.sp-dash-export-btn:hover { border-color: #F5D800; color: #F5D800; }

/* TIME FILTER */
.sp-dash-filter {
  display: flex; gap: 6px; margin-bottom: 24px; flex-wrap: wrap;
}
.sp-filter-btn {
  padding: 8px 20px; border-radius: 999px;
  border: 1.5px solid #2a2a2a; background: transparent;
  color: #666; font: 600 13px 'Inter', sans-serif; cursor: pointer;
  transition: all .15s;
}
.sp-filter-btn:hover { border-color: #555; color: #aaa; }
.sp-filter-active { background: #F5D800; color: #000; border-color: #F5D800; }

/* KPI GRID */
.sp-dash-kpis {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 14px;
  margin-bottom: 22px;
}
.sp-kpi-card {
  background: #161616;
  border: 1px solid #222;
  border-radius: 12px;
  padding: 20px 18px;
  display: flex;
  align-items: center;
  gap: 14px;
  transition: border-color .2s;
}
.sp-kpi-card:hover { border-color: #333; }
.sp-kpi-icon {
  width: 42px; height: 42px;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 18px; font-weight: 700; flex-shrink: 0;
}
.sp-kpi-yellow { background: rgba(245,216,0,.12); color: #F5D800; }
.sp-kpi-green  { background: rgba(76,175,80,.12);  color: #4caf50; }
.sp-kpi-blue   { background: rgba(100,181,246,.12);color: #64b5f6; }
.sp-kpi-orange { background: rgba(255,152,0,.12);  color: #ff9800; }
.sp-kpi-purple { background: rgba(206,147,216,.12);color: #ce93d8; }
.sp-kpi-val { font-size: 20px; font-weight: 800; color: #fff; line-height: 1; margin-bottom: 4px; }
.sp-kpi-lbl { color: #555; font-size: 11px; }

/* CARDS */
.sp-dash-card {
  background: #161616;
  border: 1px solid #222;
  border-radius: 12px;
  padding: 22px;
  margin-bottom: 18px;
}
.sp-dash-card-head {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 18px; padding-bottom: 14px; border-bottom: 1px solid #1e1e1e;
}
.sp-dash-card-head h2 { font-size: 15px; font-weight: 700; color: #fff; }
.sp-dash-hint { color: #444; font-size: 11px; }

/* ROW LAYOUT */
.sp-dash-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-bottom: 18px; }
.sp-dash-card-half { margin-bottom: 0; }

/* PENDING LIST */
.sp-pending-badge {
  background: rgba(255,152,0,.15); color: #ff9800;
  padding: 3px 10px; border-radius: 20px; font-size: 12px; font-weight: 700;
}
.sp-pending-list { display: flex; flex-direction: column; gap: 8px; max-height: 240px; overflow-y: auto; }
.sp-pending-item {
  display: flex; justify-content: space-between; align-items: center;
  background: #1a1a1a; border-radius: 8px; padding: 10px 14px;
  font-size: 13px;
}
.sp-pending-name { color: #ccc; font-weight: 600; }
.sp-pending-amt  { color: #F5D800; font-weight: 700; }
.sp-pending-date { color: #555; font-size: 11px; }
.sp-dash-empty { color: #444; font-size: 13px; padding: 20px 0; text-align: center; }

/* TABLE */
.sp-dash-table-wrap { overflow-x: auto; }
.sp-dash-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.sp-dash-table thead th {
  text-align: left; padding: 9px 12px;
  font: 600 11px 'Inter', sans-serif; color: #444;
  border-bottom: 1px solid #1e1e1e;
  text-transform: uppercase; letter-spacing: 1px; white-space: nowrap;
}
.sp-dash-table tbody td {
  padding: 13px 12px;
  border-bottom: 1px solid #111;
  vertical-align: middle; color: #aaa;
}
.sp-dash-table tbody tr:hover td { background: #1a1a1a; }
.sp-dash-loading { text-align: center; padding: 30px; color: #444; }
.sp-amt-strong { color: #F5D800; font-weight: 700; }

/* STATUS SELECT */
.sp-status-sel {
  background: #1e1e1e; border: 1px solid #2a2a2a; color: #aaa;
  padding: 5px 8px; border-radius: 6px;
  font: 400 12px 'Inter', sans-serif; cursor: pointer; outline: none;
}
.sp-status-sel:focus { border-color: #F5D800; }

/* STATUS BADGES */
.sp-badge-p { display:inline-block;padding:3px 10px;border-radius:20px;font-size:11px;font-weight:700;background:#2a2000;color:#F5D800; }
.sp-badge-c { display:inline-block;padding:3px 10px;border-radius:20px;font-size:11px;font-weight:700;background:#0d2a0d;color:#4caf50; }
.sp-badge-f { display:inline-block;padding:3px 10px;border-radius:20px;font-size:11px;font-weight:700;background:#2a0000;color:#ff6b6b; }
.sp-badge-r { display:inline-block;padding:3px 10px;border-radius:20px;font-size:11px;font-weight:700;background:#0d1a2a;color:#64b5f6; }

/* NO ACCESS */
.sp-dash-noaccess { padding: 40px; text-align: center; color: #666; font-family: 'Inter', sans-serif; }

/* ══════════════════════════════
   RESPONSIVE
══════════════════════════════ */
@media (max-width: 768px) {
  .sp-wrap { padding: 40px 16px 60px; }
  .sp-heading { font-size: 28px; }
  .sp-amounts { grid-template-columns: repeat(3, 1fr); gap: 7px; }
  .sp-amt-btn { padding: 12px 6px; font-size: 13px; }
  .sp-field-row { grid-template-columns: 1fr; }
  .sp-tabs { gap: 4px; }
  .sp-tab { padding: 7px 16px; font-size: 12px; }
  .sp-dash { padding: 24px 16px 60px; }
  .sp-dash-kpis { grid-template-columns: repeat(2, 1fr); }
  .sp-dash-row { grid-template-columns: 1fr; }
  .sp-dash-header { flex-direction: column; }
}
@media (max-width: 420px) {
  .sp-amounts { grid-template-columns: repeat(2, 1fr); }
  .sp-dash-kpis { grid-template-columns: 1fr; }
}
