/* Kenya Women Aid — aligned with Mio Dios (slate-950, violet, amber, stone) */
*,
*::before,
*::after {
  box-sizing: border-box;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

:root {
  --md-bg: #020617;
  --md-fg: #e7e5e4;
  --md-muted: #a8a29e;
  --md-dim: #78716c;
  --md-amber: #fde68a;
  --md-amber-bright: #fef3c7;
  --md-violet-border: rgb(139 92 246 / 0.15);
  --md-violet-glow: rgb(91 33 182 / 0.24);
  --md-card: rgb(15 23 42 / 0.35);
  --md-card-solid: rgb(15 23 42 / 0.8);
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Inter", ui-sans-serif, system-ui, -apple-system, sans-serif;
  font-size: 1rem;
  line-height: 1.6;
  color: var(--md-fg);
  background-color: var(--md-bg);
  background-image:
    radial-gradient(ellipse 100% 80% at 50% 12%, var(--md-violet-glow), transparent 55%),
    radial-gradient(ellipse 70% 50% at 92% 48%, rgb(49 46 129 / 0.16), transparent 50%),
    radial-gradient(ellipse 60% 45% at 8% 78%, rgb(76 29 149 / 0.12), transparent 45%);
  background-attachment: fixed;
  min-height: 100vh;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: rgb(253 230 138 / 0.9);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

a:hover {
  color: #fffbeb;
}

.container {
  width: 100%;
  max-width: 52rem;
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* Header / hero — app shell–like bar + hero */
.site-header {
  position: relative;
  color: var(--md-fg);
  padding: 2rem 0 2.5rem;
  border-bottom: 1px solid var(--md-violet-border);
  background: rgb(2 6 23 / 0.92);
  box-shadow: 0 4px 24px rgb(0 0 0 / 0.35);
}

.site-header .container {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.site-title {
  margin: 0;
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  font-weight: 600;
  letter-spacing: -0.02em;
  color: #fafaf9;
}

.site-title--logo {
  display: flex;
  justify-content: center;
  width: 100%;
  font-size: 0;
  line-height: 0;
  font-weight: inherit;
}

.site-logo {
  display: block;
  max-width: min(24rem, 92vw);
  width: auto;
  height: auto;
  max-height: 7.875rem;
  object-fit: contain;
  object-position: center;
}

.tagline {
  margin: 0;
  font-size: 1.05rem;
  color: var(--md-muted);
  max-width: 36rem;
  line-height: 1.55;
}

.hero-wrap {
  margin-top: 1.5rem;
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: 0 8px 32px rgb(0 0 0 / 0.45), 0 0 0 1px rgb(253 230 138 / 0.12);
}

.hero-banner-wrap img.hero-banner {
  width: 100%;
  height: auto;
  max-height: min(48vh, 28rem);
  object-fit: contain;
  object-position: center top;
  background: rgb(15 23 42 / 0.5);
}

/* Legacy hero ratio if needed */
.hero-wrap:not(.hero-banner-wrap) img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.changenow-callout {
  margin-top: 2rem;
  padding: 1.25rem 1.5rem;
  border-radius: 1rem;
  border: 1px solid var(--md-violet-border);
  background: var(--md-card);
  box-shadow: 0 4px 20px rgb(2 6 23 / 0.45);
}

.changenow-title {
  margin: 0 0 0.75rem;
  font-size: 1rem;
  font-weight: 600;
  color: rgb(254 243 199 / 0.95);
}

.changenow-text {
  margin: 0 0 1rem;
  font-size: 0.9rem;
  line-height: 1.6;
  color: var(--md-muted);
}

.changenow-text strong {
  color: rgb(231 229 228 / 0.95);
  font-weight: 600;
}

.changenow-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.6rem 1.15rem;
  border-radius: 0.75rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  text-decoration: none;
  border: 1px solid rgb(253 230 138 / 0.35);
  background: rgb(109 40 217 / 0.85);
  color: #fffbeb;
  transition: background 0.15s, border-color 0.15s;
}

.changenow-cta:hover {
  background: rgb(124 58 237 / 0.92);
  color: #fffbeb;
}

/* Sections */
section {
  padding: 2.5rem 0;
}

section.section-muted {
  background: rgb(15 23 42 / 0.35);
  border-top: 1px solid var(--md-violet-border);
  border-bottom: 1px solid var(--md-violet-border);
}

h2 {
  margin: 0 0 1rem;
  font-size: 1.35rem;
  font-weight: 600;
  color: rgb(254 243 199 / 0.95);
}

h3,
.network-heading {
  margin: 0 0 0.5rem;
  font-size: 1.05rem;
  font-weight: 600;
  color: rgb(196 181 253 / 0.9);
}

.network-heading {
  margin-top: 2rem;
}

.prose p {
  margin: 0 0 1rem;
  color: var(--md-muted);
}

.prose p:last-child {
  margin-bottom: 0;
}

.prose strong {
  color: rgb(231 229 228 / 0.95);
  font-weight: 600;
}

.prose-intro {
  margin-bottom: 1rem;
}

.prose-note {
  margin-top: 1rem;
  font-size: 0.9rem;
}

/* Crypto cards */
.network-grid {
  display: grid;
  gap: 1.25rem;
  margin-top: 1.5rem;
}

@media (min-width: 640px) {
  .network-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.network-card {
  background: var(--md-card);
  border-radius: 1rem;
  padding: 1.25rem;
  border: 1px solid var(--md-violet-border);
  box-shadow: 0 4px 20px rgb(2 6 23 / 0.5);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.network-head {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.network-head img {
  width: 28px;
  height: 28px;
  filter: invert(1) brightness(1.15);
  opacity: 0.9;
}

.network-name {
  font-weight: 600;
  font-size: 1rem;
  color: rgb(254 243 199 / 0.95);
}

.address-box {
  font-family: ui-monospace, SFMono-Regular, monospace;
  font-size: 0.7rem;
  word-break: break-all;
  background: var(--md-card-solid);
  padding: 0.65rem;
  border-radius: 0.5rem;
  border: 1px solid rgb(139 92 246 / 0.25);
  color: rgb(214 211 209 / 0.95);
}

.qr-thumb {
  margin: 0 auto;
  border-radius: 0.5rem;
  border: 1px solid rgb(139 92 246 / 0.2);
}

.card-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: auto;
}

.btn {
  font-family: inherit;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.55rem 1rem;
  border-radius: 0.75rem;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, transform 0.1s;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.btn:active {
  transform: scale(0.98);
}

.btn:focus-visible {
  outline: 2px solid rgb(253 230 138 / 0.65);
  outline-offset: 2px;
}

.btn-copy {
  border: 1px solid rgb(253 230 138 / 0.35);
  background: rgb(109 40 217 / 0.85);
  color: #fffbeb;
}

.btn-copy:hover {
  background: rgb(124 58 237 / 0.9);
}

.btn-copy.copied {
  border-color: rgb(52 211 153 / 0.45);
  background: rgb(5 150 105 / 0.55);
  color: rgb(209 250 229 / 0.98);
}

.btn-qr {
  border: 1px solid rgb(139 92 246 / 0.35);
  background: rgb(46 16 101 / 0.55);
  color: rgb(254 243 199 / 0.95);
}

.btn-qr:hover {
  background: rgb(76 29 149 / 0.45);
  border-color: rgb(167 139 250 / 0.35);
}

/* How to donate */
.steps {
  margin: 0;
  padding-left: 1.25rem;
  color: var(--md-muted);
}

.steps li {
  margin-bottom: 0.65rem;
}

.steps strong {
  color: rgb(231 229 228 / 0.9);
}

/* Updates */
.updates-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.updates-list li {
  padding: 1rem;
  background: var(--md-card);
  border-radius: 0.75rem;
  border: 1px dashed rgb(139 92 246 / 0.3);
  margin-bottom: 0.75rem;
  font-size: 0.9rem;
  color: var(--md-muted);
}

.updates-list strong {
  color: rgb(231 229 228 / 0.9);
}

.explorer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1rem;
}

.explorer-links a {
  font-size: 0.85rem;
  font-weight: 500;
}

.explorer-verify-intro {
  margin-top: 1.25rem;
  margin-bottom: 0.75rem;
}

.explorer-address-list {
  list-style: none;
  margin: 0 0 1rem;
  padding: 0;
}

.explorer-address-list li {
  padding: 1rem;
  background: var(--md-card);
  border-radius: 0.75rem;
  border: 1px solid rgb(139 92 246 / 0.22);
  margin-bottom: 0.75rem;
  font-size: 0.9rem;
  line-height: 1.55;
  color: var(--md-muted);
}

.explorer-address-list strong {
  color: rgb(254 243 199 / 0.95);
  font-weight: 600;
}

.explorer-address-list a {
  margin-left: 0.25rem;
  font-weight: 500;
}

.explorer-full-addr {
  display: block;
  margin-top: 0.5rem;
  font-family: ui-monospace, SFMono-Regular, monospace;
  font-size: 0.65rem;
  line-height: 1.45;
  word-break: break-all;
  color: rgb(168 162 158 / 0.88);
}

.explorer-verify-foot {
  margin-top: 0.5rem;
  margin-bottom: 0;
}

/* Footer */
.site-footer {
  background: rgb(2 6 23 / 0.97);
  color: var(--md-muted);
  padding: 2rem 0;
  margin-top: 0;
  border-top: 1px solid var(--md-violet-border);
}

.footer-contact {
  margin: 0 0 1.25rem;
  font-size: 0.9rem;
  color: var(--md-muted);
}

.footer-email {
  font-weight: 500;
  text-decoration: underline;
  text-decoration-color: rgb(253 230 138 / 0.35);
  text-underline-offset: 3px;
}

.footer-email:hover {
  text-decoration-color: rgb(253 230 138 / 0.65);
}

.footer-contact-hint {
  font-weight: 400;
  opacity: 0.85;
}

.disclaimer {
  margin: 0;
  font-size: 0.8rem;
  line-height: 1.5;
  opacity: 0.88;
  max-width: 40rem;
  color: var(--md-dim);
}

/* QR modal */
.modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s, visibility 0.2s;
}

.modal.is-open {
  opacity: 1;
  visibility: visible;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgb(0 0 0 / 0.65);
  backdrop-filter: blur(4px);
  cursor: pointer;
}

.modal-box {
  position: relative;
  z-index: 1;
  background: rgb(15 23 42 / 0.98);
  border: 1px solid var(--md-violet-border);
  border-radius: 1rem;
  padding: 1.5rem;
  max-width: 22rem;
  width: 100%;
  box-shadow: 0 24px 48px rgb(0 0 0 / 0.5);
  text-align: center;
}

.modal-close {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  width: 2.25rem;
  height: 2.25rem;
  border: 1px solid rgb(139 92 246 / 0.25);
  background: rgb(30 41 59 / 0.9);
  border-radius: 0.5rem;
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
  color: var(--md-muted);
}

.modal-close:hover {
  background: rgb(51 65 85 / 0.9);
  color: var(--md-fg);
}

.modal-close:focus-visible {
  outline: 2px solid rgb(253 230 138 / 0.7);
  outline-offset: 2px;
}

#qr-modal-title {
  margin: 0 0 1rem;
  font-size: 1.1rem;
  color: rgb(254 243 199 / 0.95);
}

#qr-modal-img {
  margin: 0 auto 1rem;
  border-radius: 0.5rem;
  border: 1px solid rgb(139 92 246 / 0.2);
}

#qr-modal-address {
  margin: 0;
  font-family: ui-monospace, SFMono-Regular, monospace;
  font-size: 0.65rem;
  word-break: break-all;
  color: var(--md-muted);
}

body.modal-open {
  overflow: hidden;
}
