/* /donate/ — checkout с подписями к суммам */

.donate-page {
  max-width: var(--layout-narrow, 40rem);
  margin: 0 auto;
  padding: 0 clamp(0.75rem, 2vw, 1.5rem) 3rem;
}

.donate-page form input[type="number"],
.donate-page form input[type="text"],
.donate-page form input[type="email"] {
  width: auto;
  padding: 0;
  border: 0;
  border-radius: 0;
  margin-bottom: 0;
  background: transparent;
  color: inherit;
  font-size: inherit;
  box-shadow: none;
}

.donate-page pre {
  font-family: inherit;
}

.donate-flash {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  margin-bottom: 1.25rem;
  padding: 0.85rem 1rem;
  border-radius: var(--radius-card, 10px);
  font-size: 0.9rem;
  font-weight: 600;
}

.donate-flash--success {
  border: 1px solid var(--moner-border);
  background: var(--moner-bg-card);
  color: var(--moner-text);
}

body.wall-light .donate-flash--success {
  border-width: 2px;
}

.donate-flash-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.35rem;
  height: 1.35rem;
  border-radius: 999px;
  background: var(--moner-text-muted);
  color: var(--moner-bg);
  font-size: 0.75rem;
}

.donate-checkout {
  margin-bottom: 2rem;
  padding: 1.25rem 1.15rem;
  border: 1px solid var(--moner-border);
  border-radius: var(--radius-card, 10px);
  background: var(--moner-bg-card);
}

body.wall-light .donate-checkout {
  border-width: 2px;
  box-shadow: 4px 4px 0 #000;
}

.donate-social-proof {
  margin: 0 0 1rem;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--moner-text-muted);
}

.donate-pay-switch {
  display: flex;
  gap: 0.45rem;
  margin-bottom: 0.35rem;
}

.donate-pay-stars-note {
  margin: 0 0 1rem;
  font-size: 0.72rem;
  line-height: 1.35;
  color: var(--moner-text-muted, #888);
  font-weight: 500;
}

.donate-custom-currency-hint {
  font-size: 0.78em;
  font-weight: 600;
  color: var(--moner-text-muted, #888);
  text-transform: none;
  letter-spacing: 0;
}

.donate-pay-switch-btn,
.donate-fiat-tab span,
.donate-link-btn {
  border: 1px solid var(--moner-border);
  border-radius: var(--radius-card, 10px);
  background: var(--moner-bg);
  color: var(--moner-text);
  font-family: var(--font-sans);
  transition: border-color 0.15s ease, background 0.15s ease, color 0.15s ease;
}

body.wall-light .donate-pay-switch-btn,
body.wall-light .donate-fiat-tab span,
body.wall-light .donate-link-btn {
  border-width: 2px;
  background: #fff;
}

.donate-pay-switch-btn {
  flex: 1;
  min-height: 2.65rem;
  padding: 0.5rem 0.85rem;
  font-size: 0.84rem;
  font-weight: 700;
  cursor: pointer;
}

.donate-pay-switch-btn.is-active,
.donate-fiat-tab input:checked + span {
  border-color: var(--moner-text);
  background: var(--moner-bg-card);
  color: var(--moner-text);
}

body.wall-light .donate-pay-switch-btn.is-active,
body.wall-light .donate-fiat-tab input:checked + span {
  border-color: #000;
  box-shadow: 3px 3px 0 var(--moner-red);
}

.donate-checkout-panel {
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
}

.donate-checkout-block {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  min-width: 0;
}

.donate-checkout-block--amount {
  gap: 0.7rem;
}

.donate-field-label {
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--moner-text-muted);
}

.donate-fiat-tabs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.45rem;
  max-width: 20rem;
}

.donate-fiat-tab {
  display: flex;
  cursor: pointer;
}

.donate-fiat-tab input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.donate-fiat-tab span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 2.5rem;
  padding: 0.45rem 0.65rem;
  font-size: 0.82rem;
  font-weight: 700;
}

.donate-amount-picker {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.donate-amount-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0.55rem;
  overflow: visible;
  padding-top: 0.35rem;
}

@keyframes donate-chip-pulse {
  0% { box-shadow: 0 0 0 0 rgba(220, 38, 38, 0); }
  50% { box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.28); }
  100% { box-shadow: 0 0 0 1px rgba(220, 38, 38, 0.35); }
}

@keyframes donate-chip-intro {
  0% { box-shadow: 0 0 0 0 rgba(220, 38, 38, 0); }
  35% { box-shadow: 0 0 0 4px rgba(220, 38, 38, 0.32), 0 4px 14px rgba(220, 38, 38, 0.12); }
  70% { box-shadow: 0 0 0 2px rgba(220, 38, 38, 0.22); }
  100% { box-shadow: 0 0 0 1px rgba(220, 38, 38, 0.35); }
}

.donate-amount-chip {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: center;
  width: 100%;
  height: 3.35rem;
  min-height: 3.35rem;
  margin: 0;
  padding: 0.55rem 0.5rem;
  border: 1px solid var(--moner-border);
  border-radius: 12px;
  background: var(--moner-bg);
  color: var(--moner-text);
  font-family: var(--font-sans);
  font-size: inherit;
  line-height: inherit;
  text-align: center;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  box-sizing: border-box;
  overflow: visible;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
  transition:
    border-color 0.2s ease,
    background 0.2s ease,
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

body.wall-light .donate-amount-chip {
  border-width: 2px;
  background: #fff;
}

.donate-amount-chip-head {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  height: 100%;
}

.donate-amount-chip-price {
  font-family: var(--moner-font, var(--font-sans));
  font-size: 0.95rem;
  font-weight: 900;
  line-height: 1.2;
  color: var(--moner-text);
  white-space: nowrap;
}

.donate-amount-chip-badge {
  position: absolute;
  top: -0.42rem;
  right: 0.28rem;
  z-index: 2;
  max-width: calc(100% - 0.4rem);
  padding: 0.2rem 0.45rem;
  border-radius: 999px;
  background: var(--moner-red);
  color: #fff;
  font-size: 0.5rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  line-height: 1.2;
  white-space: nowrap;
  box-shadow: 0 2px 8px rgba(220, 38, 38, 0.35);
  opacity: 0;
  transform: translateY(5px) scale(0.9);
  pointer-events: none;
  transition:
    opacity 0.24s cubic-bezier(0.4, 0, 0.2, 1),
    transform 0.24s cubic-bezier(0.4, 0, 0.2, 1);
}

.donate-amount-chip.is-badge-visible .donate-amount-chip-badge {
  opacity: 1;
  transform: translateY(0) scale(1);
}

body.wall-light .donate-amount-chip-badge {
  border: 1px solid #000;
  box-shadow: 2px 2px 0 #000;
}

.donate-amount-caption {
  min-height: 2.35rem;
  padding: 0.45rem 0.65rem;
  border-radius: 10px;
  border: 1px dashed transparent;
  background: transparent;
  transition:
    border-color 0.24s ease,
    background 0.24s ease,
    opacity 0.24s ease;
}

.donate-amount-caption:not(.is-empty) {
  border-color: rgba(220, 38, 38, 0.22);
  background: rgba(220, 38, 38, 0.05);
}

body.wall-light .donate-amount-caption:not(.is-empty) {
  border-color: rgba(0, 0, 0, 0.14);
  background: rgba(0, 0, 0, 0.03);
}

.donate-amount-caption-text {
  margin: 0;
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1.45;
  color: var(--moner-text-muted);
  text-align: center;
  opacity: 0;
  transform: translateY(4px);
  transition:
    opacity 0.26s cubic-bezier(0.4, 0, 0.2, 1),
    transform 0.26s cubic-bezier(0.4, 0, 0.2, 1);
}

.donate-amount-caption:not(.is-empty) .donate-amount-caption-text {
  opacity: 1;
  transform: translateY(0);
}

.donate-amount-caption.is-empty .donate-amount-caption-text,
.donate-amount-caption.is-switching .donate-amount-caption-text {
  opacity: 0;
  transform: translateY(-3px);
}

.donate-amount-tap-hint {
  display: block;
  margin: -0.2rem 0 0;
  font-size: 0.72rem;
  line-height: 1.4;
  color: var(--moner-text-muted);
}

@media (hover: hover) and (pointer: fine) {
  .donate-amount-chip:hover {
    border-color: var(--moner-red);
    background: rgba(220, 38, 38, 0.08);
    transform: translateY(-1px);
  }

  .donate-pay-switch-btn:hover,
  .donate-link-btn:hover {
    border-color: var(--moner-text-muted);
  }
}

.donate-amount-chip.is-active {
  border-color: var(--moner-red);
  background: rgba(220, 38, 38, 0.08);
  transform: translateY(-1px);
  box-shadow: 0 0 0 1px rgba(220, 38, 38, 0.35);
}

.donate-amount-chip.is-pulse {
  animation: donate-chip-pulse 0.55s cubic-bezier(0.4, 0, 0.2, 1);
}

.donate-amount-chip.is-intro {
  animation: donate-chip-intro 1.1s cubic-bezier(0.4, 0, 0.2, 1);
}

body.wall-light .donate-amount-chip.is-active {
  border-color: #000;
  box-shadow: 3px 3px 0 #000;
}

body.wall-light .donate-amount-chip:hover {
  box-shadow: 4px 4px 0 #000;
}

.donate-amount-custom-wrap {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  margin-top: 0.15rem;
}

.donate-amount-custom {
  display: flex;
  align-items: stretch;
  width: 100%;
  max-width: 100%;
  min-height: 3rem;
  border: 1px solid var(--moner-border);
  border-radius: 12px;
  overflow: hidden;
  background: var(--moner-bg);
}

body.wall-light .donate-amount-custom {
  border-width: 2px;
  background: #fff;
}

.donate-amount-symbol {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 3rem;
  padding: 0 0.65rem;
  background: rgba(220, 38, 38, 0.08);
  color: var(--moner-red);
  font-size: 1rem;
  font-weight: 900;
  flex-shrink: 0;
}

.donate-checkout-form--stars .donate-amount-symbol {
  /* Keep fiat symbol visible in custom amount (not star count). */
  font-size: 1rem;
}

.donate-amount-input {
  flex: 1;
  min-width: 0;
  width: 100%;
  border: 0;
  background: transparent;
  color: var(--moner-text);
  font-family: inherit;
  font-size: 1.05rem;
  font-weight: 800;
  padding: 0.75rem 0.85rem;
}

.donate-amount-input:focus {
  outline: none;
}

.donate-amount-hint {
  margin: 0;
  font-size: 0.76rem;
  color: var(--moner-text-muted);
}

.donate-checkout-submit-wrap {
  padding-top: 0.5rem;
  border-top: 1px solid var(--moner-border);
}

body.wall-light .donate-checkout-submit-wrap {
  border-top-width: 2px;
}

.donate-pay-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 2.85rem;
  font-size: 0.92rem;
  font-weight: 800;
}

.donate-pay-note {
  margin: 0.5rem 0 0;
  font-size: 0.76rem;
  line-height: 1.45;
  text-align: center;
  color: var(--moner-text-muted);
}

.donate-section-heading {
  margin: 0 0 0.85rem;
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--moner-text-muted);
}

.donate-uses {
  margin-bottom: 1.75rem;
}

.donate-uses-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.65rem;
}

.donate-use-tile {
  padding: 1rem 0.9rem;
  border: 1px solid var(--moner-border);
  border-radius: var(--radius-card, 10px);
  background: var(--moner-bg-card);
}

body.wall-light .donate-use-tile {
  border-width: 2px;
  background: #fff;
}

.donate-use-tile h3 {
  margin: 0 0 0.3rem;
  font-size: 0.92rem;
  font-weight: 800;
  color: var(--moner-text);
}

.donate-use-tile p {
  margin: 0;
  font-size: 0.8rem;
  line-height: 1.45;
  color: var(--moner-text-muted);
}

.donate-secondary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.65rem;
}

.donate-secondary-card {
  padding: 1rem 0.95rem;
  border: 1px solid var(--moner-border);
  border-radius: var(--radius-card, 10px);
  background: var(--moner-bg-card);
}

body.wall-light .donate-secondary-card {
  border-width: 2px;
  background: #fff;
}

.donate-secondary-title {
  margin: 0 0 0.45rem;
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--moner-text);
}

.donate-secondary-text,
.donate-secondary-empty {
  margin: 0 0 0.85rem;
  font-size: 0.82rem;
  line-height: 1.45;
  color: var(--moner-text-muted);
}

.donate-secondary-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.donate-link-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.4rem;
  padding: 0.45rem 0.85rem;
  font-size: 0.82rem;
  font-weight: 700;
  text-decoration: none;
}

.donate-payment-note {
  margin: 0.75rem 0 0;
  padding: 0.65rem 0.75rem;
  border: 1px solid var(--moner-border);
  border-radius: var(--radius-card, 10px);
  background: var(--moner-bg);
  font-family: ui-monospace, monospace;
  font-size: 0.76rem;
  line-height: 1.45;
  white-space: pre-wrap;
  word-break: break-word;
  color: var(--moner-text-muted);
}

@media (max-width: 1024px) {
  .donate-amount-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 768px) {
  .donate-page {
    padding-bottom: calc(5rem + env(safe-area-inset-bottom, 0px));
  }

  .donate-uses-grid,
  .donate-secondary {
    grid-template-columns: 1fr;
  }

  .donate-fiat-tabs {
    max-width: none;
  }

  .donate-amount-grid {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding: 0;
  }

  .donate-amount-chip {
    width: 100%;
    height: 3.5rem;
    min-height: 3.5rem;
    padding: 0.7rem 0.85rem;
    border-radius: 10px;
  }

  .donate-amount-chip-price {
    font-size: 1.05rem;
  }

  .donate-amount-chip-badge {
    top: -0.48rem;
    right: 0.55rem;
    font-size: 0.54rem;
    padding: 0.22rem 0.5rem;
  }

  .donate-amount-caption {
    min-height: 2.5rem;
    padding: 0.55rem 0.75rem;
  }

  .donate-amount-caption-text {
    font-size: 0.84rem;
  }

  .donate-amount-custom {
    min-height: 3.15rem;
  }

  .donate-amount-input {
    font-size: 16px;
    padding: 0.85rem 0.9rem;
  }

  .donate-checkout-submit-wrap {
    position: sticky;
    bottom: 0;
    z-index: 30;
    margin: 0.5rem -1.15rem 0;
    padding: 0.85rem 1.15rem calc(0.9rem + env(safe-area-inset-bottom, 0px));
    background: linear-gradient(
      to top,
      var(--moner-bg-card) 72%,
      rgba(36, 36, 40, 0.97) 88%,
      transparent
    );
    border-top: 1px solid var(--moner-border);
    box-shadow: 0 -10px 28px rgba(0, 0, 0, 0.28);
  }

  body.wall-light .donate-checkout-submit-wrap {
    background: linear-gradient(
      to top,
      #ffffff 72%,
      rgba(255, 255, 255, 0.97) 88%,
      transparent
    );
    border-top-width: 2px;
    box-shadow: 0 -8px 0 #000;
  }

  .donate-pay-btn {
    min-height: 3.15rem;
    font-size: 1rem;
  }
}

@media (max-width: 480px) {
  .donate-page {
    padding-left: 0.65rem;
    padding-right: 0.65rem;
  }
}