/* Customer Form Styles */

/* Form Elements */
input[type="text"],
input[type="tel"],
textarea,
select,
button {
    font-family: inherit;
}

/* Modal Overlay */
.fc-modal-overlay {
    position: fixed;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 9998;
}

/* Success Modal */
.fc-success-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.fc-success-box {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: #00b894;
    color: #ffffff;
    padding: 24px;
    border-radius: 10px;
    text-align: center;
    max-width: 720px !important;
    width: 90%;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    z-index: 9999;
}

.fc-success-icon {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 20px;
}

.fc-success-icon svg {
    color: white;
}

.fc-success-box h3 {
    margin-bottom: 20px;
    font-size: 24px;
}

.fc-success-box p {
    margin-bottom: 25px;
    font-size: 16px;
    line-height: 1.7;
}

.fc-phone {
    background-color: #01a383;
    color: #ffffff;
    padding: 0 8px;
    border-radius: 5px;
    text-decoration: none;
}

.fc-success-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 25px;
    flex-wrap: wrap;
}

.fc-success-btn {
    background-color: #ffffff !important;
    color: #00b894 !important;
    border: none !important;
    padding: 12px 25px !important;
    border-radius: 5px !important;
    cursor: pointer !important;
    font-size: 16px !important;
    font-weight: bold !important;
    transition: background-color 0.3s !important;
}

.fc-success-btn:hover {
    background-color: #039377 !important;
    color: #ffffff !important;
}

/* Form Layout */
.form-row {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 15px;
}

.form-row > div {
    flex: 1;
    min-width: 200px;
}

.form-row input[type="text"],
.form-row input[type="tel"],
.form-row select {
    width: 100%;
}

/* Plan Card */
.fc-plan-card {
    background: #f0f4f8;
    max-width: 700px;
    border-radius: 10px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
    padding: 24px;
    margin: 16px auto;
}

.fc-plan-header {
    text-align: right;
    margin-bottom: 16px;
}

.fc-plan-header h3 {
    color: #2c3e50;
    margin: 0;
    font-size: 1.5em;
}

.fc-plan-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 10px;
}

.fc-detail-item {
    background: #f9f9f9;
    padding: 8px 16px;
    border-radius: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.fc-detail-item strong {
    color: #212121;
    font-size: 0.9em;
    margin-left: 10px;
    white-space: nowrap;
}

.fc-detail-item span {
    color: #2c3e50;
    font-size: 1.1em;
    font-weight: 500;
    text-align: left;
    display: inline-block;
}

/* Installments */
.fc-installments {
    grid-column: 1 / -1;
    margin-top: 10px;
}

.fc-installments-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-top: 15px;
}

.fc-installment-item {
    background: linear-gradient(135deg, #f8fbff 0%, #e8f4ff 100%);
    border: 1px solid #d4e9ff;
    border-radius: 12px;
    padding: 15px;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(52, 152, 219, 0.1);
}

.fc-installment-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(52, 152, 219, 0.15);
}

.fc-installment-item::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(180deg, #3498db 0%, #2980b9 100%);
}

.fc-installment-date {
    color: #2c3e50;
    font-weight: 600;
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
}

.fc-installment-amount {
    color: #00b894;
    font-weight: bold;
    font-size: 1em;
    display: block;
}

.text-black {
    color: #212121;
}

/* Rules Section */
.fc-rules {
    border-radius: 10px;
    max-height: 300px;
    overflow-y: auto;
    font-size: 14px;
    background: #f9f9f9;
    padding: 10px;
    border: 1px solid #ccc;
    margin-bottom: 16px;
}

/* Custom Scrollbar */
.fc-rules::-webkit-scrollbar {
    width: 10px;
}

.fc-rules::-webkit-scrollbar-track {
    border-radius: 10px;
    border-left: 8px solid transparent;
}

.fc-rules::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 10px;
    border: 2px solid transparent;
    border-left: 8px solid transparent;
    border-right: 2px solid transparent;
}

.fc-rules::-webkit-scrollbar-thumb:hover {
    background: #b5b5b5;
}

.rules-list {
    list-style: none;
    counter-reset: rule-counter;
}

.rules-list li {
    counter-increment: rule-counter;
    position: relative;
    padding-right: 18px;
}

.rules-list li::before {
    content: counter(rule-counter) ")";
    position: absolute;
    right: 0;
    font-weight: bold;
}

/* Submit Button */
.submit-btn {
    background-color: #00b894 !important;
    color: white !important;
    padding: 8px 16px !important;
    border: none !important;
    border-radius: 6px !important;
    margin-bottom: 10px !important;
    display: block !important;
    margin-right: auto !important;
    margin-left: 0 !important;
    width: auto !important;
}

.submit-btn:hover {
    background-color: #00967a !important;
}

.submit-btn.loading {
    opacity: 0.7;
    cursor: not-allowed;
}

/* Spinner */
.spinner {
    display: none !important;
    width: 16px;
    height: 16px;
    border: 2px solid #ffffff;
    border-radius: 50%;
    border-top-color: transparent;
    animation: spin 0.8s linear infinite;
    margin-right: 8px;
    vertical-align: middle;
}

.spinner.show {
    display: inline-block !important;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Validation */
.validation-error {
    color: #ff4444;
    font-size: 0.8em;
    display: none;
}

input.error {
    border-color: #ff4444 !important;
    box-shadow: 0 0 0 1px #ff4444;
}

/* Form Elements */
.select-form {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 1em;
}

/* Responsive Design */
@media (max-width: 768px) {
    .fc-installments-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .fc-success-box {
        padding: 30px 20px;
        margin: 20px;
    }
    
    .fc-success-buttons {
        flex-direction: column;
        gap: 10px;
    }
    
    .fc-success-btn {
        width: 100%;
    }
    
    .fc-plan-details {
        grid-template-columns: 1fr;
    }
    
    .fc-detail-item {
        padding: 10px 12px;
    }
}
