/* ============================================
    STRIPE ELEMENTS STYLING (Compact Override)
    ============================================ */

/* Stripe Payment Section */
.stripe-section {
    background: rgba(30, 30, 30, 0.6) !important;
    border: 1px solid rgba(51, 161, 181, 0.3) !important;
    border-radius: 12px !important;
    padding: 18px !important;
    margin-top: 12px !important;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.05) !important;
}

.stripe-title {
    color: #f0f0f0 !important;
    font-size: 17px !important;
    font-weight: 600 !important;
    margin: 0 0 4px 0 !important;
    letter-spacing: 0.3px !important;
}

.stripe-subtitle {
    color: #888 !important;
    font-size: 12px !important;
    margin: 0 0 12px 0 !important;
}

/* Card Element Container */
.card-element-container {
    margin-bottom: 10px !important;
}

.card-element {
    padding: 12px 14px !important;
    background: #333 !important;
    border: 2px solid rgba(255, 255, 255, 0.1) !important;
    border-radius: 10px !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    position: relative !important;
}

.card-element:hover {
    border-color: rgba(255, 255, 255, 0.2) !important;
    background: #3a3a3a !important;
}

.card-element:focus-within {
    border-color: #33a1b5 !important;
    box-shadow: 0 0 0 3px rgba(51, 161, 181, 0.1), 0 6px 20px rgba(51, 161, 181, 0.12) !important;
    transform: translateY(-1px) !important;
}

/* Stripe Elements iframe styling */
.card-element .StripeElement {
    padding: 0 !important;
    margin: 0 !important;
}

.card-element .StripeElement--focus {
    outline: none !important;
}

.card-element .StripeElement--invalid {
    border-color: #ff6b6b !important;
}

/* Card Errors */
.card-errors {
    color: #ff6b6b !important;
    font-size: 12px !important;
    margin-top: 8px !important;
    padding: 8px 12px !important;
    background: rgba(255, 107, 107, 0.1) !important;
    border: 1px solid rgba(255, 107, 107, 0.3) !important;
    border-radius: 6px !important;
    display: none !important;
    animation: shake 0.4s ease-in-out !important;
}

.card-errors.visible {
    display: block !important;
}

/* Payment Summary */
.payment-summary {
    background: rgba(20, 20, 20, 0.8) !important;
    border-radius: 10px !important;
    padding: 12px !important;
    margin: 12px 0 !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
}

.payment-row {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    padding: 6px 0 !important;
    color: #ccc !important;
    font-size: 13px !important;
}

.payment-row:not(:last-child) {
    border-bottom: 1px solid rgba(255, 255, 255, 0.06) !important;
}

.payment-row.payment-total {
    border-top: 2px solid rgba(51, 161, 181, 0.3) !important;
    margin-top: 8px !important;
    padding-top: 10px !important;
    color: #f0f0f0 !important;
}

.payment-row.payment-total span:last-child {
    font-size: 18px !important;
    font-weight: 700 !important;
    color: #33a1b5 !important;
}

/* Submit Button */
.submit-button {
    width: 100% !important;
    padding: 14px 24px !important;
    background: linear-gradient(135deg, #ed5611, #ff6a1e) !important;
    color: white !important;
    border: none !important;
    border-radius: 10px !important;
    font-size: 15px !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    text-transform: none !important;
    letter-spacing: 0.3px !important;
    position: relative !important;
    overflow: hidden !important;
    box-shadow: 0 3px 10px rgba(237, 86, 17, 0.25) !important;
}

.submit-button:hover:not(:disabled) {
    background: linear-gradient(135deg, #ff6a1e, #ff7d33) !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 5px 15px rgba(237, 86, 17, 0.35) !important;
}

.submit-button:active:not(:disabled) {
    transform: translateY(-1px) !important;
    box-shadow: 0 3px 10px rgba(237, 86, 17, 0.25) !important;
}

.submit-button:disabled {
    background: #555 !important;
    cursor: not-allowed !important;
    box-shadow: none !important;
    opacity: 0.7 !important;
}

.submit-button.processing {
    pointer-events: none !important;
}

.submit-button.success {
    background: linear-gradient(135deg, #33a1b5, #2a8a9e) !important;
    box-shadow: 0 3px 10px rgba(51, 161, 181, 0.25) !important;
}

/* Spinner */
.spinner {
    display: inline-block;
    width: 16px !important;
    height: 16px !important;
    border: 3px solid rgba(255, 255, 255, 0.3) !important;
    border-radius: 50% !important;
    border-top-color: white !important;
    animation: spin 0.8s linear infinite !important;
    margin-left: 8px !important;
    vertical-align: middle !important;
}

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

/* Payment Messages */
.payment-message {
    margin-top: 12px !important;
    padding: 14px !important;
    border-radius: 10px !important;
    text-align: center !important;
    animation: fadeIn 0.4s ease-in-out !important;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.payment-message.success {
    background: linear-gradient(135deg, rgba(51, 161, 181, 0.15), rgba(42, 138, 158, 0.1)) !important;
    border: 1px solid rgba(51, 161, 181, 0.4) !important;
}

.payment-message.error {
    background: linear-gradient(135deg, rgba(255, 107, 107, 0.15), rgba(255, 107, 107, 0.1)) !important;
    border: 1px solid rgba(255, 107, 107, 0.4) !important;
}

.payment-success h3,
.payment-error h3 {
    margin: 0 0 6px 0 !important;
    font-size: 16px !important;
    font-weight: 600 !important;
}

.payment-success h3 {
    color: #33a1b5 !important;
}

.payment-error h3 {
    color: #ff6b6b !important;
}

.payment-success p,
.payment-error p {
    margin: 0 !important;
    color: #ccc !important;
    font-size: 13px !important;
    line-height: 1.5 !important;
}

.success-icon,
.error-icon {
    width: 36px !important;
    height: 36px !important;
    margin-bottom: 10px !important;
}

.success-icon {
    color: #33a1b5 !important;
}

.error-icon {
    color: #ff6b6b !important;
}

/* Responsive */
@media (max-width: 768px) {
    .stripe-section {
        padding: 14px !important;
    }
    
    .stripe-title {
        font-size: 15px !important;
    }
    
    .stripe-subtitle {
        font-size: 11px !important;
    }
    
    .payment-row.payment-total span:last-child {
        font-size: 16px !important;
    }
    
    .submit-button {
        padding: 12px 20px !important;
        font-size: 14px !important;
    }
}

@media (max-width: 480px) {
    .stripe-section {
        padding: 12px !important;
    }
    
    .payment-summary {
        padding: 10px !important;
    }
    
    .card-element {
        padding: 10px 12px !important;
    }
}
