body {
    font-family: 'Arial', sans-serif;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    margin: 0;
    background: linear-gradient(135deg, #f3e5f5, #e1bee7);
    color: #4a148c;
}

h1 {
    text-align: center;
    width: 100%;
    display: block;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 20px;
    animation: fadeInDown 1s ease-out;
}

.container {
    display: flex;
    flex-direction: column;
    gap: 15px;
    background: rgba(255, 255, 255, 0.8);
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    margin-bottom: 20px;
    animation: slideInUp 0.8s ease-out;
    text-align: center;
}

input {
    padding: 10px;
    font-size: 16px;
    border: 2px solid #ce93d8;
    border-radius: 5px;
    outline: none;
    transition: border-color 0.3s;
    text-align: center;
}

input:focus {
    border-color: #8e24aa;
}

button {
    padding: 10px 20px;
    font-size: 16px;
    color: white;
    background: #8e24aa;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background 0.3s, transform 0.2s;
}

button:hover {
    background: #7b1fa2;
}

button:active {
    transform: scale(0.98);
}

canvas {
    display: none;
    max-width: 90%;
    border-radius: 10px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    margin-top: 20px;
}

#downloadBtn {
    display: none;
    margin-top: 15px;
    background-color: #3a0d48;
}

#downloadBtn:hover {
    background-color: #23002b;
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes cardPopIn {
    0% {
        opacity: 0;
        transform: scale(0.5);
    }

    80% {
        transform: scale(1.05);
    }

    100% {
        opacity: 1;
        transform: scale(1);
    }
}

.showCard {
    display: block !important;
    animation: cardPopIn 1s ease-out;
}

/* --- Footer --- */
.footer {
    width: 100%;
    padding: 24px;
    background: rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(4px);
    border-top: 1px solid rgba(255, 255, 255, 0.5);
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
}

@media (min-width: 640px) {
    .footer-content {
        flex-direction: row;
    }
}

.footer p {
    font-size: 14px;
    font-weight: 500;
}

.footer a {
    color: #ea580c;
    font-weight: 700;
    text-decoration: none;
    transition: color 0.3s;
}

.footer a:hover {
    color: #c2410c;
    text-decoration: underline;
}

@keyframes heartPulse {
    0% { transform: scale(1); }
    15% { transform: scale(1.3); }
    30% { transform: scale(1); }
    45% { transform: scale(1.3); }
    60% { transform: scale(1); }
    100% { transform: scale(1); }
}

.heart-pulse {
    display: inline-block;
    animation: heartPulse 1.2s infinite;
    transform-origin: center;
}

.btn-donate {
    padding: 6px 16px;
    background: linear-gradient(to right, #ffedd5, #fff7ed);
    border: 1px solid #fed7aa;
    color: #c2410c;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    font-family: 'Poppins', sans-serif;
}

.btn-donate:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

/* --- Modal (Popup) --- */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 50;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    padding: 16px;
}

.modal.show {
    opacity: 1;
    pointer-events: auto;
}

.modal-content {
    background: white;
    padding: 32px;
    border-radius: 24px;
    max-width: 384px;
    width: 100%;
    position: relative;
    transform: scale(0.95);
    transition: transform 0.3s ease;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.modal.show .modal-content {
    transform: scale(1);
}

.close-btn {
    position: absolute;
    top: 16px;
    right: 16px;
    background: none;
    border: none;
    font-size: 20px;
    color: #9ca3af;
    cursor: pointer;
    font-weight: bold;
    transition: color 0.3s;
}

.close-btn:hover {
    color: #ef4444;
}

.modal h3 {
    text-align: center;
    font-size: 24px;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 8px;
}

.modal-text {
    text-align: center;
    font-size: 14px;
    color: #4b5563;
    margin-bottom: 24px;
}

.qr-container {
    display: flex;
    justify-content: center;
    background: #fff7ed;
    border: 2px solid #ffedd5;
    border-radius: 16px;
    padding: 16px;
    margin-bottom: 16px;
}

.qr-container img {
    width: 192px;
    height: 192px;
    object-fit: contain;
    border-radius: 12px;
    mix-blend-mode: multiply;
}

.modal-footer-text {
    text-align: center;
    font-size: 12px;
    color: #6b7280;
    font-weight: 500;
}
