:root {
  --background: #0e0d0e;
  --text: #f8f6f1;
  --muted: #aaa6ad;
  --card: #181619;
  --card-alt: #232026;
  --line: #37323a;
  --violet-dark: #5b1c9f;
  --violet: #9146ff;
  --violet-line: #a78bfa;
  --violet-light: #d9c9ff;
  --orange: #ff812e;
  --orange-light: #ffb17d;
  --danger: #4a1f29;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { min-width: 320px; min-height: 100vh; margin: 0; background: linear-gradient(120deg, rgba(91, 28, 159, .16), transparent 32%), var(--background); color: var(--text); font-family: Arial, Helvetica, sans-serif; }
button, input { font: inherit; }
button { cursor: pointer; }
a { color: inherit; }
h1, h2, p { margin-top: 0; }

.page-shell { width: min(1280px, calc(100% - 64px)); margin: 0 auto; padding-bottom: 64px; }
.topbar { display: flex; min-height: 76px; align-items: center; justify-content: space-between; gap: 22px; padding: 0 16px; border-bottom: 1px solid var(--line); }
.brand-group, .brand-logo, .top-links { display: flex; align-items: center; }
.brand-group { min-width: 0; gap: 11px; }
.brand-logo { display: grid; flex: 0 0 auto; width: 43px; height: 43px; place-items: center; border-radius: 50%; }
.brand-logo:focus-visible { outline: 2px solid var(--orange-light); outline-offset: 3px; }
.brand-mark { width: 43px; height: 43px; border-radius: 50%; object-fit: cover; }
.brand-copy { display: grid; gap: 8px; line-height: 1; }
.brand-copy strong { color: var(--text); font-size: 17px; letter-spacing: -.35px; }
.brand-copy span { color: var(--orange-light); font-size: 11px; font-weight: 700; letter-spacing: .9px; }
.top-links { flex-wrap: wrap; justify-content: end; gap: 18px; color: var(--muted); font-size: 12px; font-weight: 700; }
.top-links a { text-decoration: none; }
.songlist-link { color: var(--violet-light); text-decoration: none; }
.songlist-button { min-height: 34px; margin-left: 10px; padding: 8px 11px; border: 1px solid #76538d; border-radius: 7px; background: #211226; font-size: 12px; font-weight: 700; transition: border-color .16s ease, color .16s ease; }
.songlist-button:hover, .songlist-button:focus-visible { border-color: var(--violet-line); color: white; outline: none; }
.imprint-link { color: var(--muted); }
.imprint-link:hover, .imprint-link:focus-visible { color: var(--text); outline: none; }
.top-links .login-link { display: inline-flex; align-items: center; gap: 7px; min-height: 34px; padding: 9px 12px; border: 0; border-radius: 7px; background: var(--violet); color: white; text-decoration: none; transition: background .16s ease; }
.twitch-login-icon { width: 15px; height: 15px; fill: currentColor; }
.top-links .login-link:hover, .top-links .login-link:focus-visible { background: #a661ff; outline: none; }
.top-links .logout-link { display: inline-flex; align-items: center; gap: 9px; min-height: 34px; padding: 0; color: #ff91a0; font-size: 13px; font-weight: 800; text-decoration: none; transition: color .16s ease; }
.top-links .logout-link:hover, .top-links .logout-link:focus-visible { color: #ffb0ba; outline: none; }
.logout-icon { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 2.25; }

.dashboard-grid { display: grid; grid-template-columns: minmax(290px, 470px); justify-content: center; padding-top: 34px; }
.info-column, .content-column { min-width: 0; }
.hero { padding: 10px 2px 24px; }
.eyebrow, .step { margin-bottom: 10px; color: var(--orange-light); font-size: 10px; font-weight: 800; letter-spacing: 1.35px; line-height: 1.2; }
h1 { margin-bottom: 12px; font-size: clamp(28px, 3vw, 31px); letter-spacing: -.045em; line-height: 1.08; }
h2 { letter-spacing: -.035em; }
.intro { max-width: 460px; margin-bottom: 0; color: var(--muted); font-size: 13px; line-height: 1.65; }

.donation-card, .activity-section, .dashboard-card, .stat-grid article { border: 1px solid var(--line); border-radius: 12px; background: var(--card); }
.donation-card { overflow: hidden; border-color: var(--violet-dark); background: linear-gradient(135deg, #211226, #191619 70%); }
.card-heading { padding: 21px 23px 16px; border-bottom: 1px solid rgba(217, 201, 255, .16); }
.card-heading h2 { margin: 0; font-size: 20px; }
.amount-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; padding: 19px 23px 15px; }
.amount { min-height: 40px; border: 1px solid #76538d; border-radius: 7px; background: #171219; color: var(--violet-light); font-size: 13px; font-weight: 700; transition: background .16s ease, border-color .16s ease, color .16s ease; }
.amount:hover, .amount:focus-visible { border-color: var(--orange-light); color: var(--orange-light); outline: none; }
.amount.is-selected { border-color: var(--orange-light); background: var(--orange); color: #24120a; box-shadow: 0 0 14px rgba(255, 129, 46, .16); }
.custom-amount { display: grid; gap: 7px; padding: 0 23px; color: var(--muted); font-size: 12px; }
.input-wrap { display: flex; align-items: center; border: 1px solid #76538d; border-radius: 7px; background: #121113; transition: border-color .16s ease; }
.input-wrap:focus-within { border-color: var(--orange); }
.input-wrap input { width: 100%; min-height: 39px; padding: 8px 11px; border: 0; outline: 0; background: transparent; color: var(--text); font-size: 16px; }
.input-wrap input::placeholder { color: #716b73; }
.input-wrap b { padding-right: 12px; color: var(--violet-light); font-size: 13px; }
.primary-button { display: flex; align-items: center; justify-content: space-between; width: fit-content; min-height: 42px; margin: 20px auto 0; padding: 10px 14px; border: 1px solid transparent; border-radius: 7px; background: var(--violet); color: white; font-size: 13px; font-weight: 700; transition: background .16s ease, transform .16s ease; }
.paypal-cta { display: inline-flex; align-items: center; gap: 6px; }
.paypal-wordmark { width: 74px; height: 20px; object-fit: contain; }
.primary-button:hover, .primary-button:focus-visible { background: #a661ff; outline: none; transform: translateY(-1px); }
.payment-note { margin: 11px 23px 20px; color: var(--muted); font-size: 10px; text-align: center; }

.content-column { display: flex; flex-direction: column; }
.activity-section { min-height: 100%; padding: 21px 23px; }
.section-heading { display: flex; align-items: start; justify-content: space-between; gap: 16px; padding-bottom: 16px; border-bottom: 1px solid var(--line); }
.section-heading .eyebrow { margin-bottom: 8px; }
.section-heading h2 { margin: 0; font-size: 22px; }
.live-badge { display: inline-flex; align-items: center; gap: 7px; min-height: 30px; padding: 7px 9px; border: 1px solid rgba(255, 129, 46, .5); border-radius: 7px; color: var(--orange-light); font-size: 10px; font-weight: 800; letter-spacing: .8px; }
.live-badge i { width: 6px; height: 6px; border-radius: 50%; background: var(--orange); }
.activity-list { border-bottom: 1px solid var(--line); }
.empty-activity { margin: 0; padding: 19px 0; color: var(--muted); font-size: 12px; line-height: 1.6; }
.activity-entry { display: grid; grid-template-columns: 72px 1fr auto; gap: 14px; align-items: center; padding: 16px 0; border-top: 1px solid var(--line); }
.activity-entry time { color: var(--muted); font-size: 11px; }.activity-entry strong { display: block; font-size: 13px; }.activity-entry span { color: var(--muted); font-size: 11px; }.activity-entry b { color: var(--violet-light); font-size: 12px; }

.notice { display: flex; gap: 11px; margin: 16px 0 0; padding: 13px 15px; border: 1px solid rgba(255, 129, 46, .35); border-radius: 10px; background: rgba(74, 31, 41, .36); color: var(--muted); font-size: 11px; line-height: 1.5; }
.notice span { display: grid; flex: 0 0 auto; width: 18px; height: 18px; place-items: center; border: 1px solid var(--orange); border-radius: 50%; color: var(--orange-light); font-size: 11px; font-weight: 700; }.notice p { margin: 0; }

.dashboard { padding: 42px 0 0; }
.dashboard > .intro { max-width: 560px; }
.period-controls { display: flex; align-items: end; flex-wrap: wrap; gap: 12px; margin-top: 21px; }
.period-picker { display: inline-grid; gap: 7px; color: var(--orange-light); font-size: 10px; font-weight: 800; letter-spacing: 1.35px; }
.period-picker select { min-width: 190px; min-height: 38px; padding: 8px 30px 8px 11px; border: 1px solid #76538d; border-radius: 7px; outline: none; background: #121113; color: var(--text); font-size: 13px; font-weight: 700; letter-spacing: 0; }
.period-picker select:focus { border-color: var(--orange); }
.custom-date-range { display: flex; gap: 8px; }
.custom-date-range[hidden] { display: none; }
.custom-date-range label { display: grid; gap: 7px; color: var(--orange-light); font-size: 10px; font-weight: 800; letter-spacing: 1.35px; }
.custom-date-range input { min-height: 38px; padding: 8px 10px; border: 1px solid #76538d; border-radius: 7px; outline: none; background: #121113; color: var(--text); font-family: Arial, Helvetica, sans-serif; font-size: 13px; font-weight: 700; }
.custom-date-range input:focus { border-color: var(--orange); }
.stat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 26px 0 24px; }
.stat-grid article { padding: 20px; }
.stat-grid span { display: block; min-height: 32px; color: var(--muted); font-size: 11px; line-height: 1.45; }
.stat-grid strong { display: block; margin-top: 13px; color: var(--violet-light); font-size: 25px; letter-spacing: -.07em; }
.dashboard-card { padding: 21px 23px; }
.export-link { min-height: 34px; padding: 9px 11px; border: 1px solid #76538d; border-radius: 7px; color: var(--violet-light); font-size: 11px; font-weight: 700; text-decoration: none; }
.export-link:hover { border-color: var(--orange-light); color: var(--orange-light); }
.export-period { margin: 17px 0 0; color: var(--orange-light); font-size: 11px; font-weight: 700; }
.dashboard-card .empty-activity { margin-top: 17px; border-top: 1px solid var(--line); }

@media (max-width: 850px) {
  .page-shell { width: min(100% - 32px, 760px); padding-bottom: 42px; }
  .dashboard-grid { grid-template-columns: 1fr; gap: 18px; padding-top: 24px; }
  .hero { padding-bottom: 4px; }
  .activity-section { min-height: 0; }
}

@media (max-width: 620px) {
  .page-shell { width: calc(100% - 24px); }
  .topbar { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: start; gap: 12px; min-height: 0; padding: 12px 4px; }
  .brand-group { flex-wrap: wrap; }
  .top-links { justify-content: end; gap: 10px; }
  .songlist-button { margin-left: 4px; }
  .dashboard-grid { gap: 16px; }
  .amount-grid { grid-template-columns: repeat(2, 1fr); }
  .section-heading { align-items: start; flex-direction: column; }
  .activity-entry { grid-template-columns: 1fr auto; gap: 5px 10px; }
  .activity-entry time { grid-column: 1 / -1; }
  .stat-grid { grid-template-columns: 1fr; }
  .stat-grid span { min-height: auto; }
  .custom-date-range { width: 100%; }
  .custom-date-range label { flex: 1; }
  .custom-date-range input { width: 100%; }
  footer { flex-direction: column; gap: 15px; }
}

@media (max-width: 380px) {
  .topbar { grid-template-columns: 1fr; }
  .top-links { justify-content: start; }
}
