/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    line-height: 1.6;
}

/* Container */
.container {
    width: 100%;
    max-width: 500px;
}

/* Donation Card */
.donation-card {
    background: white;
    border-radius: 16px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    transition: transform 0.3s ease;
}

.donation-card:hover {
    transform: translateY(-2px);
}

/* Header */
.donation-header {
    background: linear-gradient(135deg, #2196F3 0%, #21CBF3 100%);
    color: white;
    padding: 32px 24px;
    text-align: center;
}

.donation-header h1 {
    font-size: 28px;
    font-weight: 600;
    margin-bottom: 8px;
}

.donation-header p {
    font-size: 16px;
    opacity: 0.9;
}

/* Form */
.donation-form {
    padding: 32px 24px;
}

.form-section {
    margin-bottom: 32px;
}

.section-title {
    display: block;
    font-size: 18px;
    font-weight: 600;
    color: #333;
    margin-bottom: 16px;
}

/* Amount Display */
.amount-display {
    text-align: center;
    margin-bottom: 24px;
}

.currency {
    font-size: 24px;
    color: #666;
    font-weight: 500;
}

#amount-value {
    font-size: 48px;
    font-weight: 700;
    color: #2196F3;
    margin-left: 4px;
}

/* Slider */
.slider-container {
    margin-bottom: 20px;
}

.amount-slider {
    width: 100%;
    height: 8px;
    border-radius: 4px;
    background: #e0e0e0;
    outline: none;
    -webkit-appearance: none;
    appearance: none;
    cursor: pointer;
}

.amount-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #2196F3;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(33, 150, 243, 0.3);
    transition: all 0.2s ease;
}

.amount-slider::-webkit-slider-thumb:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(33, 150, 243, 0.4);
}

.amount-slider::-moz-range-thumb {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #2196F3;
    cursor: pointer;
    border: none;
    box-shadow: 0 2px 8px rgba(33, 150, 243, 0.3);
}

.slider-labels {
    display: flex;
    justify-content: space-between;
    margin-top: 8px;
    font-size: 14px;
    color: #666;
}

/* Custom Amount Input */
.custom-amount {
    margin-top: 20px;
}

.custom-amount label {
    display: block;
    font-size: 14px;
    color: #666;
    margin-bottom: 8px;
}

.custom-input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 16px;
    transition: border-color 0.2s ease;
}

.custom-input:focus {
    outline: none;
    border-color: #2196F3;
}

/* Frequency Options */
.frequency-options {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.frequency-option {
    position: relative;
}

.frequency-option input[type="radio"] {
    position: absolute;
    opacity: 0;
    cursor: pointer;
}

.frequency-label {
    display: flex;
    flex-direction: column;
    padding: 16px 20px;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    background: white;
}

.frequency-label:hover {
    border-color: #2196F3;
    background: #f8f9ff;
}

.frequency-option input[type="radio"]:checked + .frequency-label {
    border-color: #2196F3;
    background: #f8f9ff;
    box-shadow: 0 0 0 1px #2196F3;
}

.frequency-title {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin-bottom: 4px;
}

.frequency-description {
    font-size: 14px;
    color: #666;
}

/* Donation Summary */
.donation-summary {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 24px;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.summary-row:last-child {
    margin-bottom: 0;
    font-weight: 600;
    font-size: 16px;
}

.summary-row span:first-child {
    color: #666;
}

.summary-row span:last-child {
    color: #333;
    font-weight: 500;
}

/* Donate Button */
.donate-button {
    width: 100%;
    background: linear-gradient(135deg, #4CAF50 0%, #45a049 100%);
    color: white;
    border: none;
    padding: 16px 24px;
    border-radius: 12px;
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 56px;
}

.donate-button:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 20px rgba(76, 175, 80, 0.3);
}

.donate-button:active {
    transform: translateY(0);
}

.donate-button:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

/* Loading Spinner */
.loading-spinner {
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s ease-in-out infinite;
    margin-left: 8px;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Error Message */
.error-message {
    background: #ffebee;
    color: #c62828;
    padding: 12px 16px;
    border-radius: 8px;
    margin-top: 16px;
    font-size: 14px;
    border-left: 4px solid #c62828;
}

/* Responsive Design */
@media (max-width: 480px) {
    body {
        padding: 16px;
    }
    
    .donation-header {
        padding: 24px 20px;
    }
    
    .donation-header h1 {
        font-size: 24px;
    }
    
    .donation-form {
        padding: 24px 20px;
    }
    
    #amount-value {
        font-size: 40px;
    }
    
    .frequency-options {
        gap: 8px;
    }
    
    .frequency-label {
        padding: 12px 16px;
    }
}

/* Focus Styles for Accessibility */
.amount-slider:focus,
.custom-input:focus,
.frequency-option input[type="radio"]:focus + .frequency-label,
.donate-button:focus {
    outline: 2px solid #2196F3;
    outline-offset: 2px;
}
