/* UBA Frontend Styles */

/* Application Form Wrapper */
.uba-application-form-wrapper {
    max-width: 900px;
    margin: 40px auto;
    padding: 0 20px;
}

/* Form Header */
.uba-form-header {
    margin-bottom: 40px;
    padding-bottom: 30px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.uba-form-header h2 {
    font-size: 32px;
    margin-bottom: 15px;
    color: var(--text-color, #fff);
    text-transform: uppercase;
    font-weight: 700;
}

.uba-form-description {
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-color, #fff);
    opacity: 0.8;
    margin-bottom: 20px;
}

.uba-form-price {
    background: #f0f7ff;
    border-left: 4px solid #2271b1;
    padding: 15px 20px;
    font-size: 18px;
    font-weight: 600;
    color: #2271b1;
}

/* Form Fields */
.uba-form-fields {
    margin-bottom: 30px;
}

.uba-form-field {
    margin-bottom: 35px;
}

.uba-field-label {
    display: block;
    font-weight: 300;
    font-size: 18px;
    margin-bottom: 10px;
    color: var(--text-color, #fff);
}

.uba-field-label .required-mark {
    color: #d63638;
    margin-left: 3px;
}

.uba-field-help {
    font-size: 14px;
    color: var(--text-color, #fff);
    opacity: 0.6;
    margin-bottom: 10px;
    font-style: italic;
}

/* Input Fields */
.uba-input,
.uba-textarea {
    width: 100%;
    padding: 15px 20px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    font-size: 16px;
    font-family: inherit;
    color: var(--text-color, #fff);
    transition: all 0.3s;
}

.uba-input:focus,
.uba-textarea:focus {
    outline: none;
    border-color: var(--primary-color, #B4D63E);
    background: rgba(255, 255, 255, 0.1);
    box-shadow: none;
}

.uba-textarea {
    min-height: 120px;
    resize: vertical;
}

/* Character Counter */
.uba-char-counter {
    text-align: right;
    font-size: 13px;
    color: #666;
    margin-top: 5px;
}

/* File Upload */
.uba-file-upload-wrapper {
    margin-top: 10px;
}

.uba-upload-area {
    position: relative;
    border: 2px dashed rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    padding: 40px 20px;
    text-align: center;
    transition: all 0.3s;
    background: rgba(255, 255, 255, 0.02);
}

.uba-upload-area:hover,
.uba-upload-area.drag-over {
    border-color: var(--primary-color, #B4D63E);
    background: rgba(255, 255, 255, 0.08);
}

.uba-file-input {
    position: absolute;
    width: 0;
    height: 0;
    opacity: 0;
    overflow: hidden;
}

.uba-upload-label {
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.upload-icon {
    font-size: 48px;
    display: block;
}

.upload-text {
    font-size: 16px;
    font-weight: 500;
    color: var(--text-color, #fff);
}

.upload-hint {
    font-size: 13px;
    color: #666;
}

/* Upload Progress */
.uba-upload-progress {
    margin: 20px 0;
}

.progress-bar {
    height: 8px;
    background: #e5e5e5;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 8px;
}

.progress-fill {
    height: 100%;
    background: #2271b1;
    transition: width 0.3s;
}

.progress-text {
    font-size: 14px;
    color: #666;
    text-align: center;
    display: block;
}

/* Preview Grid (Gallery) */
.uba-preview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 15px;
    margin-top: 20px;
}

.uba-preview-item {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.1);
    aspect-ratio: 1;
}

.uba-preview-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.uba-file-remove {
    position: absolute;
    padding: 5px;
    top: 8px;
    right: 8px;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(214, 54, 56, 0.9);
    color: white;
    border: none;
    cursor: pointer;
    font-size: 20px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.uba-file-remove:hover {
    background: #d63638;
}

/* Preview List (Videos) */
.uba-preview-list {
    margin-top: 20px;
}

.uba-preview-list .uba-preview-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    margin-bottom: 10px;
    aspect-ratio: auto;
}

.uba-preview-list .file-icon {
    font-size: 24px;
}

.uba-preview-list .file-name {
    flex: 1;
    font-size: 14px;
    color: #1a1a1a;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.uba-preview-list .uba-file-remove {
    position: static;
    flex-shrink: 0;
}

/* Error Messages */
.uba-field-error {
    color: #d63638;
    font-size: 14px;
    margin-top: 8px;
}

.uba-form-messages {
    margin-bottom: 20px;
}

.uba-error {
    background: #fee;
    border-left: 4px solid #d63638;
    padding: 12px 16px;
    color: #d63638;
    border-radius: 4px;
    margin-bottom: 15px;
}

/* Submit Button */
.uba-form-actions {
    padding-top: 20px;
    border-top: 1px solid #e5e5e5;
}

.uba-submit-btn {
    background: var(--primary-color, #B4D63E);
    color: #000;
    padding: 16px 40px;
    border: none;
    border-radius: 30px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    text-transform: uppercase;
    min-width: 200px;
}

.uba-submit-btn:hover:not(:disabled) {
    background: #9ec230;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(180, 214, 62, 0.2);
}

.uba-submit-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    background: #888;
}

.uba-btn-loader .spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(0, 0, 0, 0.1);
    border-top-color: #000;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

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

/* Success Message */
.uba-success-message {
    text-align: center;
    padding: 60px 20px;
}

.uba-success-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: #00a32a;
    color: white;
    font-size: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 24px;
}

.uba-success-message h3 {
    font-size: 28px;
    margin-bottom: 16px;
    color: #1a1a1a;
}

.uba-success-message p {
    font-size: 16px;
    color: #666;
    line-height: 1.6;
    max-width: 600px;
    margin: 0 auto 12px;
}

/* ========================================
   PAYMENT UI STYLES (INLINE IN MODAL)
   ======================================== */

.uba-payment-section {
    padding: 30px 0;
    text-align: center;
}

.uba-payment-section h3 {
    font-size: 24px;
    margin-bottom: 10px;
    color: var(--text-color, #fff);
}

.uba-payment-section>p {
    margin-bottom: 30px;
    color: rgba(255, 255, 255, 0.7);
}

.uba-payment-tabs {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
    justify-content: center;
}

.uba-payment-tab {
    flex: 0 1 200px;
    padding: 15px 20px;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 16px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.7);
}

.uba-payment-tab:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.3);
}

.uba-payment-tab.active {
    background: var(--primary-color, #B4D63E);
    border-color: var(--primary-color, #B4D63E);
    color: #000;
}

.uba-payment-methods {
    max-width: 500px;
    margin: 0 auto;
}

.uba-payment-content {
    padding: 20px 0;
}

/* Stripe Elements */
.uba-stripe-element {
    padding: 15px;
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.05);
    margin-bottom: 20px;
    transition: border-color 0.3s ease;
    background: #fff;
}

.uba-stripe-element:focus-within {
    border-color: var(--primary-color, #B4D63E);
}

.uba-payment-errors {
    color: #d63638;
    margin-bottom: 15px;
    font-size: 14px;
    min-height: 20px;
    text-align: center;
}

.uba-payment-btn {
    width: 100%;
    padding: 18px 20px;
    background: var(--primary-color, #B4D63E);
    color: #000;
    border: none;
    border-radius: 30px;
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
}

.uba-payment-btn:hover {
    background: #9ec230;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(180, 214, 62, 0.3);
}

.uba-payment-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
}

/* PayPal Container */
#paypal-button-container-inline {
    min-height: 150px;
}

/* Processing State */
.uba-payment-processing {
    text-align: center;
    padding: 60px 20px;
}

.uba-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(255, 255, 255, 0.1);
    border-top: 4px solid var(--primary-color, #B4D63E);
    border-radius: 50%;
    animation: uba-spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes uba-spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

.uba-payment-processing p {
    font-size: 18px;
    color: rgba(255, 255, 255, 0.7);
}

/* Success State */
.uba-payment-success-inline {
    text-align: center;
    padding: 60px 20px;
}

.uba-payment-success-inline .uba-success-icon {
    width: 80px;
    height: 80px;
    background: #00a32a;
    color: #fff;
    font-size: 48px;
    line-height: 80px;
    border-radius: 50%;
    margin: 0 auto 20px;
}

.uba-payment-success-inline h3 {
    margin: 0 0 10px;
    color: var(--text-color, #fff);
    font-size: 24px;
}

.uba-payment-success-inline p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 16px;
}

/* Responsive */
@media (max-width: 768px) {
    .uba-application-form-wrapper {
        padding: 0 15px;
        margin: 20px auto;
    }

    .uba-form-header h2 {
        font-size: 24px;
    }

    .uba-upload-area {
        padding: 30px 15px;
    }

    .upload-icon {
        font-size: 36px;
    }

    .uba-preview-grid {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
        gap: 10px;
    }

    .uba-submit-btn {
        width: 100%;
        justify-content: center;
    }

    .uba-payment-tabs {
        flex-direction: column;
    }

    .uba-payment-tab {
        width: 100%;
    }
}

/* Modal Styles */
.uba-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 99999;
    overflow-y: hidden;
}

.uba-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(5px);
    z-index: 1;
}

.uba-modal-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
}

.uba-modal-content {
    position: relative;
    width: 90%;
    max-width: 900px;
    background: var(--dark-bg, #0d0d0d);
    border-radius: 20px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    pointer-events: auto;
    max-height: 90vh;
    display: flex;
    overflow: scroll;
    flex-direction: column;
    border: 1px solid rgba(255, 255, 255, 0.1);
    overflow-y: auto;
}

.uba-modal-close {
    position: absolute;
    background: transparent;
    border: none;
    width: 42px;
    height: 42px;
    font-size: 32px;
    cursor: pointer;
    color: #666;
    z-index: 10;
    line-height: 0.9;
    padding: 0 5px 10px;
    transition: all 0.3s;
}

.uba-modal-close:hover {
    color: #fff;
    transform: rotate(180deg);
    transition: all 0.3s;
}

#uba-modal-form-container {
    padding: 40px;
    max-height: 100%;
}

/* Loading State */
.uba-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 0;
    color: #666;
}

body.uba-modal-open {
    overflow: hidden;
}

/* Button override */
.nomination-apply-btn {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    padding: 12px 10px;
    background: transparent;
    border: none;
    text-align: left;
    cursor: pointer;
    font-size: 16px;
    color: inherit;
    transition: color 0.3s;
}

.nomination-apply-btn:hover {
    color: #fff;
}

.nomination-name {
    margin-right: 10px;
}

.apply-icon {
    opacity: 0;
    transform: translateX(-10px);
    transition: all 0.3s;
}

.nomination-apply-btn:hover .apply-icon {
    opacity: 1;
    transform: translateX(0);
}

@media (max-width: 768px) {
    #uba-modal-form-container {
        padding: 20px;
    }

    .uba-modal-close {
        top: 10px;
        right: 15px;
    }
}

/* Custom Scrollbar */
#uba-modal-form-container::-webkit-scrollbar {
    width: 6px;
}

#uba-modal-form-container::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 3px;
}

#uba-modal-form-container::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 3px;
    transition: background 0.3s;
}

#uba-modal-form-container::-webkit-scrollbar-thumb:hover {
    background: var(--primary-color, #B4D63E);
}

#uba-modal-form-container {
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.2) rgba(255, 255, 255, 0.05);
}


.ElementsApp,
.ElementsApp .InputElement {
    font-size: 16px;
    color: #fff !important;
}

/* Update Payment Icons */
.uba-payment-icons {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 15px;
    opacity: 0.8;
}

.uba-payment-icons svg {
    height: 40px;
    width: auto;
}

/* Update Promo Code Section Styles */
.uba-promo-section {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.uba-promo-header {
    margin-bottom: 12px;
    font-size: 16px;
    color: var(--text-color, #fff);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    cursor: pointer;
}

.uba-promo-input-group {
    display: flex;
    max-width: 350px;
    margin: 0 auto;
    gap: 10px;
}

#uba-promo-code {
    flex: 1;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    padding: 10px 15px;
    color: #fff;
    font-size: 14px;
    transition: all 0.3s;
}

#uba-promo-code:focus {
    border-color: var(--primary-color, #B4D63E);
    background: rgba(255, 255, 255, 0.1);
    outline: none;
}

.uba-promo-btn {
    background: transparent;
    border: 1px solid var(--primary-color, #B4D63E);
    color: var(--primary-color, #B4D63E);
    border-radius: 8px;
    padding: 8px 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    text-transform: uppercase;
    font-size: 13px;
}

.uba-promo-btn:hover {
    background: var(--primary-color, #B4D63E);
    color: #000;
}

.uba-promo-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

#uba-promo-message {
    margin-top: 10px;
    font-size: 14px;
    min-height: 20px;
}