/* ==========================================================================
   ساز و داستان | Saz o Dastan - Minimalist Crypto Donation
   Aesthetic: Dark Persian Luxury, Warm Amber & Sunset Gold, Glassmorphism
   ========================================================================== */

:root {
  --bg-primary: #0a0706;
  --bg-card: rgba(22, 16, 12, 0.78);
  --bg-item: rgba(0, 0, 0, 0.38);
  --bg-item-hover: rgba(245, 158, 11, 0.08);
  
  --gold-glow: #e5a93c;
  --gold-primary: #f59e0b;
  --gold-light: #fef3c7;
  --gold-gradient: linear-gradient(135deg, #f59e0b 0%, #d97706 50%, #b45309 100%);
  --gold-border: rgba(229, 169, 60, 0.28);
  --gold-border-highlight: rgba(245, 158, 11, 0.65);
  
  --text-main: #fdfaf6;
  --text-muted: #c4b5a5;
  --text-subtle: #8a7b6c;
  
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-full: 9999px;
  
  --shadow-card: 0 16px 36px -8px rgba(0, 0, 0, 0.75), 0 0 25px -4px rgba(229, 169, 60, 0.1);
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

body {
  font-family: 'Vazirmatn', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background-color: var(--bg-primary);
  color: var(--text-main);
  min-height: 100vh;
  line-height: 1.6;
  overflow-x: hidden;
  position: relative;
  direction: rtl;
  padding: 16px 12px 30px 12px;
}

/* Ambient glow background layers */
.ambient-glow {
  position: fixed;
  border-radius: 50%;
  filter: blur(120px);
  pointer-events: none;
  z-index: 0;
  opacity: 0.25;
}

.glow-top {
  width: 480px;
  height: 480px;
  background: radial-gradient(circle, #f59e0b 0%, rgba(217, 119, 6, 0) 70%);
  top: -120px;
  right: -100px;
}

.glow-bottom {
  width: 550px;
  height: 550px;
  background: radial-gradient(circle, #b45309 0%, rgba(180, 83, 9, 0) 70%);
  bottom: 0;
  left: -150px;
}

/* Page Container */
.page-container {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 600px;
  margin: 0 auto;
}

/* Single Unified Main Card */
.main-unified-card {
  background: var(--bg-card);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--gold-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  transition: border-color 0.3s ease;
}

.main-unified-card:hover {
  border-color: var(--gold-border-highlight);
}

/* Hero Image Banner */
.hero-image-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background-color: #0d0806;
}

.hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(10, 7, 6, 0.1) 0%,
    rgba(10, 7, 6, 0.45) 50%,
    rgba(22, 16, 12, 0.98) 100%
  );
}

/* Card Body Content */
.card-body {
  padding: 18px 18px 24px 18px;
  text-align: center;
  position: relative;
  margin-top: -24px;
}

.badge-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 14px;
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.35);
  border-radius: var(--radius-full);
  color: var(--gold-primary);
  font-size: 0.82rem;
  font-weight: 600;
  margin-bottom: 12px;
}

.pulse-icon {
  color: #ef4444;
  animation: heartPulse 1.8s infinite;
}

@keyframes heartPulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.25); }
}

.main-title {
  font-size: 2rem;
  font-weight: 900;
  background: linear-gradient(135deg, #ffffff 20%, #fef3c7 60%, #f59e0b 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 8px;
  letter-spacing: -0.5px;
}

.subtitle {
  color: var(--text-muted);
  font-size: 0.92rem;
  line-height: 1.7;
  max-width: 480px;
  margin: 0 auto 22px auto;
  font-weight: 400;
}

/* Wallets Vertical List */
.wallets-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 20px;
  text-align: right;
}

.wallet-row-item {
  background: var(--bg-item);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  transition: all 0.25s ease;
}

.wallet-row-item:hover {
  background: var(--bg-item-hover);
  border-color: rgba(245, 158, 11, 0.4);
  transform: translateY(-1px);
}

.wallet-top-info {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

.coin-icon {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.95rem;
  flex-shrink: 0;
}

.coin-icon.usdt { background: linear-gradient(135deg, #26A17B 0%, #16604a 100%); color: #fff; }
.coin-icon.ton { background: linear-gradient(135deg, #0098EA 0%, #006eb0 100%); color: #fff; }
.coin-icon.bnb { background: linear-gradient(135deg, #F3BA2F 0%, #b88612 100%); color: #120a04; }
.coin-icon.btc { background: linear-gradient(135deg, #F7931A 0%, #b86405 100%); color: #fff; }
.coin-icon.sol { background: linear-gradient(135deg, #9945FF 0%, #14F195 100%); color: #fff; }
.coin-icon.eth { background: linear-gradient(135deg, #627EEA 0%, #3e58b8 100%); color: #fff; }

.coin-details {
  flex: 1;
}

.coin-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
}

.coin-label {
  font-size: 0.95rem;
  font-weight: 700;
  color: #fff;
}

.net-tag {
  font-size: 0.72rem;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.net-tag.trc20 { color: #f87171; border-color: rgba(239, 68, 68, 0.25); }
.net-tag.ton-net { color: #38bdf8; border-color: rgba(56, 189, 248, 0.25); }
.net-tag.bep20 { color: #facc15; border-color: rgba(250, 204, 21, 0.25); }
.net-tag.btc-net { color: #fb923c; border-color: rgba(251, 146, 60, 0.25); }
.net-tag.sol-net { color: #c084fc; border-color: rgba(192, 132, 252, 0.25); }
.net-tag.eth-net { color: #818cf8; border-color: rgba(129, 140, 248, 0.25); }

/* Address & Action Buttons */
.wallet-action-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  background: rgba(0, 0, 0, 0.45);
  border: 1px dashed rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-sm);
  padding: 8px 10px;
}

.address-text {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.78rem;
  color: #f3f4f6;
  direction: ltr;
  text-align: left;
  user-select: all;
  letter-spacing: 0.3px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  flex: 1;
}

.action-buttons {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #fff;
  font-family: inherit;
  font-size: 0.76rem;
  font-weight: 600;
  padding: 6px 11px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: all 0.2s ease;
}

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

.copy-btn {
  background: var(--gold-gradient);
  border-color: var(--gold-primary);
  color: #120a04;
  font-weight: 700;
}

.copy-btn:hover {
  filter: brightness(1.1);
}

.copy-btn.copied {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%) !important;
  border-color: #10b981 !important;
  color: #fff !important;
}

.qr-btn:hover {
  background: rgba(245, 158, 11, 0.2);
  border-color: rgba(245, 158, 11, 0.5);
  color: var(--gold-light);
}

/* Subtle Notice */
.card-notice {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 0.78rem;
  color: var(--text-subtle);
  margin-bottom: 20px;
  padding: 0 8px;
}

.card-notice i {
  color: var(--gold-primary);
  font-size: 0.85rem;
}

/* Social Media Icons */
.card-socials {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding-top: 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.social-icon-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-muted);
  text-decoration: none;
  font-size: 1.05rem;
  transition: all 0.25s ease;
}

.social-icon-btn:hover {
  transform: translateY(-2px);
  color: #fff;
}

.social-icon-btn.instagram:hover {
  background: linear-gradient(45deg, #f09433 0%, #dc2743 50%, #bc1888 100%);
  border-color: transparent;
}

.social-icon-btn.telegram:hover {
  background: #229ED9;
  border-color: #229ED9;
}

.social-icon-btn.youtube:hover {
  background: #FF0000;
  border-color: #FF0000;
}

.social-icon-btn.podcast:hover {
  background: #F55B23;
  border-color: #F55B23;
}

/* Page Footer */
.page-footer {
  text-align: center;
  color: var(--text-subtle);
  font-size: 0.8rem;
  padding: 16px 8px 0 8px;
}

/* Modal for QR Code */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.modal-backdrop.active {
  opacity: 1;
  visibility: visible;
}

.modal-box {
  background: #18110c;
  border: 1px solid var(--gold-border-highlight);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.8), 0 0 30px rgba(245, 158, 11, 0.2);
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 360px;
  padding: 24px;
  text-align: center;
  position: relative;
  transform: scale(0.92);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-backdrop.active .modal-box {
  transform: scale(1);
}

.modal-close-btn {
  position: absolute;
  top: 14px;
  left: 14px;
  background: rgba(255, 255, 255, 0.08);
  border: none;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  color: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
}

.modal-close-btn:hover {
  background: rgba(239, 68, 68, 0.8);
}

.modal-header {
  margin-bottom: 14px;
}

.modal-header h3 {
  font-size: 1.15rem;
  color: #fff;
  font-weight: 700;
}

.modal-network {
  display: inline-block;
  margin-top: 4px;
  font-size: 0.74rem;
  padding: 2px 10px;
  border-radius: var(--radius-full);
  background: rgba(245, 158, 11, 0.15);
  color: var(--gold-primary);
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.qr-canvas-wrapper {
  background: #ffffff;
  padding: 14px;
  border-radius: var(--radius-md);
  display: inline-block;
  margin: 8px auto 14px auto;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
  min-width: 190px;
  min-height: 190px;
}

.qr-canvas-wrapper img, .qr-canvas-wrapper canvas {
  display: block !important;
  margin: 0 auto;
}

.modal-address-block {
  background: rgba(0, 0, 0, 0.4);
  border: 1px dashed rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-sm);
  padding: 8px 10px;
  margin-bottom: 14px;
}

.modal-address-label {
  font-size: 0.72rem;
  color: var(--text-subtle);
  margin-bottom: 3px;
}

.modal-address-text {
  font-family: ui-monospace, SFMono-Regular, monospace;
  font-size: 0.76rem;
  color: #fff;
  direction: ltr;
  word-break: break-all;
}

.modal-copy-btn {
  width: 100%;
  background: var(--gold-gradient);
  border: none;
  color: #120a04;
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 800;
  padding: 11px;
  border-radius: var(--radius-md);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.2s ease;
  box-shadow: 0 4px 15px rgba(245, 158, 11, 0.35);
}

.modal-copy-btn:hover {
  filter: brightness(1.1);
}

/* Toast Notification */
.toast-notification {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(100px);
  background: #10b981;
  color: #fff;
  font-weight: 700;
  font-size: 0.88rem;
  padding: 10px 20px;
  border-radius: var(--radius-full);
  box-shadow: 0 10px 25px rgba(16, 185, 129, 0.45);
  display: flex;
  align-items: center;
  gap: 8px;
  z-index: 2000;
  opacity: 0;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.35s ease;
  pointer-events: none;
}

.toast-notification.show {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}
