/* =====================================================================
   Componentes compartilhados por TODOS os templates (carregado por
   renderTemplateHeadTags): pop-up de doação e selos de download do app.
   Estilo próprio e neutro (funciona sobre qualquer template, claro ou
   escuro); só a cor de destaque vem da paleta do admin (--secondary-color).
   ===================================================================== */

/* ---------- Pop-up de doação ---------- */
.rw-modal { position: fixed; inset: 0; z-index: 2147482000; display: grid; place-items: center; padding: 16px; }
.rw-modal[hidden] { display: none; }
.rw-modal-backdrop { position: absolute; inset: 0; background: rgba(8, 10, 20, 0.62); backdrop-filter: blur(4px); animation: rw-fade .2s ease; }
.rw-modal-card {
    position: relative; width: min(440px, 100%); max-height: calc(100vh - 32px); overflow-y: auto;
    padding: 26px 24px 20px; border-radius: 18px; background: #ffffff; color: #1f2937;
    font: 400 14.5px/1.55 system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
    box-shadow: 0 30px 70px -20px rgba(0, 0, 0, 0.55); animation: rw-pop .22s ease;
}
.rw-modal .rw-modal-card h2 { margin: 0; font: 700 20px/1.25 system-ui, -apple-system, 'Segoe UI', sans-serif; color: #111827; letter-spacing: -0.01em; }
.rw-modal .rw-modal-card h3 { display: flex; align-items: center; gap: 8px; margin: 0 0 10px; font: 700 14px/1.3 system-ui, sans-serif; color: #111827; }
.rw-modal-close { position: absolute; top: 12px; right: 12px; display: grid; place-items: center; width: 34px; height: 34px; border: 0; border-radius: 50%; background: #f3f4f6; color: #4b5563; cursor: pointer; font-size: 15px; }
.rw-modal-close:hover { background: #e5e7eb; color: #111827; }
.rw-modal-head { display: flex; align-items: center; gap: 12px; padding-right: 36px; margin-bottom: 12px; }
.rw-modal-icon { display: grid; place-items: center; width: 44px; height: 44px; flex: none; border-radius: 12px; background: color-mix(in srgb, var(--secondary-color, #2563eb) 14%, #fff); color: var(--secondary-color, #2563eb); font-size: 19px; }
.rw-modal .rw-modal-text { margin: 0 0 16px; color: #4b5563; }
.rw-pix, .rw-bank { margin-top: 14px; padding: 16px; border-radius: 14px; border: 1px solid #e5e7eb; background: #f9fafb; }
.rw-pix h3 i { color: #32bcad; }
.rw-pix-qr { display: block; width: 200px; height: 200px; margin: 0 auto 14px; padding: 8px; border-radius: 10px; background: #fff; border: 1px solid #e5e7eb; object-fit: contain; }
.rw-pix-qr svg { display: block; width: 100%; height: 100%; }
.rw-pix-row { display: grid; gap: 6px; }
.rw-pix-row span { color: #6b7280; font-size: 12.5px; }
.rw-pix-row code { display: block; padding: 10px 12px; border-radius: 10px; background: #fff; border: 1px dashed #d1d5db; color: #111827; font: 600 14px/1.35 ui-monospace, 'Cascadia Code', Menlo, monospace; word-break: break-all; }
.rw-copy {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 14px; border: 0; border-radius: 10px; cursor: pointer;
    background: var(--secondary-color, #2563eb); color: #fff; font: 600 13.5px/1 system-ui, sans-serif; transition: filter .2s;
}
.rw-copy:hover { filter: brightness(1.08); }
.rw-copy.is-done { background: #16a34a; }
.rw-copy-wide { width: 100%; margin-top: 10px; background: #111827; }
.rw-modal .rw-bank p { margin: 0; color: #374151; white-space: normal; }
.rw-modal-foot { margin: 16px 0 0; text-align: center; color: #6b7280; font-size: 13px; }
.rw-modal-foot i { color: #e11d48; }
body.rw-modal-open { overflow: hidden; }
@keyframes rw-fade { from { opacity: 0; } }
@keyframes rw-pop { from { opacity: 0; transform: translateY(12px) scale(.98); } }

/* ---------- Selos de download do app (estilo das lojas) ---------- */
.rw-app-badges { display: flex; flex-wrap: wrap; gap: 10px; }
.rw-app-badge {
    display: inline-flex; align-items: center; gap: 10px; min-width: 156px; padding: 8px 16px 8px 12px; border-radius: 10px;
    background: #000; color: #fff !important; text-decoration: none !important; border: 1px solid #3f3f46;
    font-family: system-ui, -apple-system, 'Segoe UI', sans-serif; transition: transform .15s, box-shadow .2s;
}
.rw-app-badge:hover { transform: translateY(-2px); box-shadow: 0 10px 22px -12px rgba(0, 0, 0, 0.7); }
.rw-app-badge i { font-size: 24px; width: 26px; text-align: center; }
.rw-app-badge[data-platform="android"] i { background: linear-gradient(135deg, #00d7fe, #00f076 40%, #ffce00 70%, #ff3a44); -webkit-background-clip: text; background-clip: text; color: transparent; }
.rw-app-badge span { display: grid; line-height: 1.1; }
.rw-app-badge small { font-size: 10px; letter-spacing: .02em; opacity: .85; }
.rw-app-badge strong { font-size: 17px; font-weight: 600; letter-spacing: -0.01em; }
.rw-app-badges.is-stacked { flex-direction: column; align-items: stretch; }
.rw-app-badges.is-stacked .rw-app-badge { min-width: 0; }
.rw-app-badge.is-mine { box-shadow: 0 0 0 3px color-mix(in srgb, var(--secondary-color, #2563eb) 45%, transparent); }
