/* Professional RazorPay International Checkout - Brand Color: #005e4f */
.rpay-card {
    max-width: 440px;
    margin: 30px auto;
    background: #ffffff;
    border-radius: 16px;
    padding: 0;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
    border: 1px solid #e8ecef;
    overflow: hidden;
}

.rpay-card-header {
    background: linear-gradient(135deg, #005e4f 0%, #004a3f 100%);
    color: white;
    padding: 32px 28px 28px 28px;
    text-align: center;
    position: relative;
}

.rpay-card-header h2 {
    margin: 0 0 6px 0;
    font-size: 24px;
    font-weight: 700;
    letter-spacing: -0.3px;
}

.rpay-card-header p {
    margin: 0 0 20px 0;
    opacity: 0.9;
    font-size: 15px;
    font-weight: 400;
    line-height: 1.4;
}

.rpay-header-icon {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0 auto;
}

.rpay-header-icon img {
    width: 100%;
    height: 100%;
}

.rpay-card-body {
    padding: 28px;
}

/* Compact Form Styles */
.rpay-form-group {
    margin-bottom: 20px;
    position: relative;
}

.rpay-label {
    display: block;
    margin-bottom: 6px;
    color: #2d3748;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: -0.1px;
}

.rpay-input {
    width: 100%;
    padding: 12px 14px;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    font-size: 15px;
    font-family: inherit;
    transition: all 0.2s ease;
    background: #ffffff;
    box-sizing: border-box;
    line-height: 1.4;
}

.rpay-input:focus {
    outline: none;
    border-color: #005e4f;
    box-shadow: 0 0 0 3px rgba(0, 94, 79, 0.1);
}

.rpay-input::placeholder {
    color: #a0aec0;
    font-weight: 400;
}

.rpay-input.error {
    border-color: #e53e3e;
    box-shadow: 0 0 0 3px rgba(229, 62, 62, 0.1);
}

/* Field Error Messages */
.rpay-field-error {
    color: #e53e3e;
    font-size: 11px;
    margin-top: 4px;
    font-weight: 500;
    display: none;
}

.rpay-field-error.show {
    display: block;
    animation: slideDown 0.3s ease;
}

/* Compact Amount Row */
.rpay-amount-row {
    display: flex;
    gap: 10px;
    align-items: center;
}

.rpay-amount-box {
    flex: 1;
    position: relative;
}

.rpay-currency-symbol {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: #005e4f;
    font-weight: 600;
    font-size: 15px;
}

.rpay-amount-input {
    padding-left: 36px !important;
    font-weight: 500;
}

.rpay-currency-display {
    background: #f8f9fa;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    padding: 12px 14px;
    font-size: 13px;
    font-weight: 600;
    color: #2d3748;
    min-width: 70px;
    text-align: center;
    line-height: 1.4;
}

/* Compact Buttons */
.rpay-btn {
    width: 100%;
    padding: 14px;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
    display: block;
    text-decoration: none;
    box-sizing: border-box;
    line-height: 1.4;
}

.rpay-btn-primary {
    background: #005e4f;
    color: white;
}

.rpay-btn-primary:hover:not(:disabled) {
    background: #004a3f;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 94, 79, 0.25);
}

.rpay-btn-secondary {
    background: #f8f9fa;
    color: #4a5568;
    border: 1.5px solid #e2e8f0;
}

.rpay-btn-secondary:hover {
    background: #edf2f7;
    border-color: #cbd5e0;
    transform: translateY(-1px);
}

.rpay-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
}

/* Step 2 Styles */
.rpay-step-title {
    color: #2d3748;
    margin-bottom: 12px;
    font-weight: 600;
    font-size: 17px;
}

.rpay-step-description {
    color: #718096;
    margin-bottom: 20px;
    line-height: 1.5;
    font-size: 14px;
}

.rpay-summary-card {
    background: #f8f9fa;
    padding: 18px;
    border-radius: 8px;
    margin-bottom: 20px;
    border-left: 4px solid #005e4f;
}

.rpay-summary-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 6px;
    font-size: 14px;
}

.rpay-summary-row:last-child {
    margin-bottom: 0;
}

.rpay-summary-label {
    color: #718096;
    font-weight: 500;
}

.rpay-summary-value {
    color: #2d3748;
    font-weight: 600;
}

/* Success Page - Compact & Professional */
.rpay-success {
    text-align: center;
    padding: 20px 0;
    max-width: 100%;
    box-sizing: border-box;
}

.rpay-success-icon {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, #48bb78 0%, #38a169 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 12px;
    color: white;
    font-size: 20px;
    font-weight: bold;
    box-shadow: 0 4px 12px rgba(72, 187, 120, 0.3);
}

.rpay-success h3 {
    color: #2d3748;
    font-size: 18px;
    font-weight: 700;
    margin: 0 0 4px 0;
    line-height: 1.3;
}

.rpay-success p {
    color: #718096;
    margin: 0 0 16px 0;
    line-height: 1.4;
    font-size: 14px;
}

.rpay-transaction-details {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 16px;
    margin: 16px 0;
    text-align: left;
    border: 1px solid #e2e8f0;
}

.rpay-detail-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 6px 0;
    border-bottom: 1px solid #e2e8f0;
    flex-wrap: wrap;
    min-height: auto;
}

.rpay-detail-row:last-child {
    border-bottom: none;
}

.rpay-detail-label {
    color: #718096;
    font-size: 12px;
    font-weight: 500;
    min-width: 90px;
    margin-bottom: 1px;
}

.rpay-detail-value {
    color: #2d3748;
    font-size: 12px;
    font-weight: 600;
    text-align: right;
    flex: 1;
    word-break: break-word;
    line-height: 1.2;
}

.rpay-amount-large {
    font-size: 24px;
    font-weight: 700;
    color: #005e4f;
    margin: 12px 0;
    line-height: 1.2;
}

.rpay-success-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 20px;
}

.rpay-success-actions .rpay-btn {
    flex: 1;
    margin: 0;
}

/* Message Styles */
.rpay-message {
    padding: 12px 14px;
    border-radius: 8px;
    margin: 16px 0;
    font-size: 13px;
    font-weight: 500;
    text-align: center;
    animation: slideDown 0.3s ease;
}

.rpay-message-error {
    background: #fed7d7;
    color: #c53030;
    border: 1px solid #feb2b2;
}

.rpay-message-success {
    background: #c6f6d5;
    color: #276749;
    border: 1px solid #9ae6b4;
}

/* Loading State */
.rpay-loading {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid #ffffff;
    border-radius: 50%;
    border-top-color: transparent;
    animation: rpay-spin 1s ease-in-out infinite;
    margin-right: 8px;
}

@keyframes rpay-spin {
    to { transform: rotate(360deg); }
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Select Input Styling */
.rpay-select {
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%234a5568' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 14px center;
    background-size: 14px;
    padding-right: 36px !important;
}

/* Focus states for accessibility */
.rpay-input:focus-visible,
.rpay-btn:focus-visible {
    outline: 2px solid #005e4f;
    outline-offset: 2px;
}

/* Compact Legal Links & Security Notice */
.rpay-legal-links {
    text-align: center;
    margin-top: 20px;
    padding: 16px;
    background: #f8fafc;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.rpay-secure-notice {
    color: #48bb78;
    font-size: 13px;
    font-weight: 600;
    margin: 0 0 8px 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.rpay-secure-icon {
    font-size: 14px;
}

.rpay-legal-text {
    color: #718096;
    font-size: 11px;
    line-height: 1.4;
    margin: 0 0 6px 0;
}

.rpay-trust-text {
    color: #718096 !important;
    font-size: 10px !important;
    line-height: 1.3;
    margin: 6px 0 0 0 !important;
    font-style: italic;
}

.rpay-legal-link {
    color: #005e4f;
    text-decoration: none;
    font-weight: 500;
}

.rpay-legal-link:hover {
    color: #004a3f;
    text-decoration: underline;
}

/* Mobile Responsive */
@media (max-width: 480px) {
    .rpay-card {
        margin: 16px;
        max-width: none;
        border-radius: 12px;
    }
    
    .rpay-card-header {
        padding: 24px 20px 20px 20px;
    }
    
    .rpay-card-body {
        padding: 20px;
    }
    
    .rpay-card-header h2 {
        font-size: 22px;
    }
    
    .rpay-card-header p {
        font-size: 14px;
    }
    
    .rpay-header-icon {
    width: 100%;
    height: 100%;
        margin-bottom: 14px;
    }
    
    .rpay-header-icon img {

    width: 100%;
    height: 100%;
    }
    
    .rpay-amount-row {
        flex-direction: column;
    }
    
    .rpay-currency-display {
        min-width: auto;
        width: 100%;
    }
    
    .rpay-success-actions {
        flex-direction: column;
    }
    
    .rpay-transaction-details {
        padding: 14px;
        margin: 14px 0;
        border-radius: 6px;
    }
    
    .rpay-amount-large {
        font-size: 22px;
    }
    
    /* Success Page Mobile */
    .rpay-success {
        padding: 15px 0;
    }
    
    .rpay-success-icon {
        width: 44px;
        height: 44px;
        font-size: 18px;
        margin-bottom: 10px;
    }
    
    .rpay-success h3 {
        font-size: 17px;
        margin-bottom: 3px;
    }
    
    .rpay-success p {
        font-size: 13px;
        margin-bottom: 14px;
    }
    
    .rpay-detail-row {
        padding: 5px 0;
        flex-direction: column;
        align-items: flex-start;
    }
    
    .rpay-detail-label {
        font-size: 11px;
        min-width: auto;
        margin-bottom: 0;
    }
    
    .rpay-detail-value {
        font-size: 11px;
        text-align: left;
        width: 100%;
    }
    
    .rpay-success-actions {
        gap: 8px;
        margin-top: 18px;
    }
    
    /* Legal Links Mobile */
    .rpay-legal-links {
        margin-top: 16px;
        padding: 14px;
    }
    
    .rpay-secure-notice {
        font-size: 12px;
        flex-direction: column;
        gap: 4px;
    }
}

/* Desktop fine-tuning */
@media (min-width: 769px) {
    .rpay-success {
        padding: 25px 0;
    }
}

/* Print styles */
@media print {
    .rpay-success-actions {
        display: none;
    }
    
    .rpay-card {
        box-shadow: none;
        border: 1px solid #ccc;
    }
}

/* Enhanced form animations */
.rpay-form-group {
    animation: fadeInUp 0.4s ease;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Step transitions */
#rpay-intl-form,
#rpay-card-step {
    transition: all 0.3s ease;
}

/* Trust badges */
.rpay-trust-badges {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-top: 12px;
    opacity: 0.7;
}

.rpay-trust-badge {
    font-size: 18px;
    color: #005e4f;
}


/* Fix button spacing in payment step */
#rpay-pay-now {
    margin-bottom: 16px !important;
}

#rpay-back {
    margin-top: 0 !important;
}