/**
 * Order Cycle Modal Styles - TeslaServer Theme
 * استایل پاپ‌آپ انتخاب دوره پرداخت
 */

/* Modal Dialog - Smaller Size */
#orderCycleModal .modal-dialog {
    max-width: 480px;
}

/* Modal Header */
#orderCycleModal .modal-header {
    background: linear-gradient(135deg, #0080FF 0%, #0066CC 100%);
    color: white;
    border-bottom: none;
    padding: 1rem 1.25rem;
}

#orderCycleModal .modal-header .modal-title {
    font-size: 1.1rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

#orderCycleModal .modal-header .modal-title i {
    font-size: 1.3rem;
}

#orderCycleModal .modal-header .close {
    color: white;
    opacity: 0.8;
    text-shadow: none;
    font-size: 1.75rem;
    font-weight: 300;
}

#orderCycleModal .modal-header .close:hover {
    opacity: 1;
}

/* Gift Notice Banner */
.gift-notice {
    background: linear-gradient(135deg, #0080FF 0%, #0066CC 100%);
    color: white;
    padding: 0.75rem 1rem;
    text-align: center;
    font-size: 0.9rem;
    border-bottom: 2px solid rgba(255, 255, 255, 0.3);
}

.gift-notice i {
    margin-left: 0.5rem;
    animation: bounce 2s infinite;
}

.gift-notice a {
    color: white;
    font-weight: bold;
    text-decoration: underline;
    margin-right: 0.25rem;
}

.gift-notice a:hover {
    color: #fff;
    text-decoration: none;
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-3px); }
}

/* Modal Body */
#orderCycleModal .modal-body {
    padding: 1rem;
    background: #f8f9fa;
}

#orderCycleModal .modal-body > p {
    font-size: 0.9rem;
    margin-bottom: 0.75rem;
}

/* Cycle Options Container */
.cycle-options {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

/* Individual Cycle Option */
.cycle-option {
    background: white;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    padding: 0;
    cursor: pointer;
    transition: all 0.3s ease;
    overflow: hidden;
}

.cycle-option:hover {
    border-color: #0080FF;
    transform: translateX(-3px);
    box-shadow: 0 3px 10px rgba(0, 128, 255, 0.15);
}

.cycle-option.selected {
    border-color: #28a745;
    background: #f0fff4;
    transform: scale(0.98);
}

.cycle-option-inner {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    align-items: center;
}

/* Cycle Icon */
.cycle-option .cycle-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, #0080FF 0%, #0066CC 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.cycle-option:hover .cycle-icon {
    transform: scale(1.1) rotate(5deg);
    transition: transform 0.3s ease;
}

.cycle-option.selected .cycle-icon {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
}

/* Cycle Details */
.cycle-option .cycle-details {
    text-align: right;
}

.cycle-option .cycle-label {
    font-size: 1rem;
    font-weight: 600;
    color: #333;
    margin: 0 0 0.15rem 0;
}

.cycle-option .cycle-price {
    font-size: 1.1rem;
    font-weight: 700;
    color: #0080FF;
    direction: rtl;
}

.cycle-option.selected .cycle-price {
    color: #28a745;
}

.cycle-option .cycle-setup {
    display: block;
    font-size: 0.75rem;
    color: #6c757d;
    margin-top: 0.15rem;
}

/* Cycle Arrow */
.cycle-option .cycle-arrow {
    color: #ccc;
    font-size: 1.1rem;
    transition: all 0.3s ease;
}

.cycle-option:hover .cycle-arrow {
    color: #0080FF;
    transform: translateX(-5px);
}

.cycle-option.selected .cycle-arrow {
    color: #28a745;
}

/* Modal Footer */
#orderCycleModal .modal-footer {
    border-top: none;
    padding: 0.75rem 1rem 1rem;
    background: #f8f9fa;
}

/* Responsive */
@media (max-width: 576px) {
    #orderCycleModal .modal-dialog {
        margin: 0.5rem;
    }

    .cycle-option-inner {
        grid-template-columns: auto 1fr;
        gap: 0.75rem;
        padding: 0.875rem 1rem;
    }

    .cycle-option .cycle-icon {
        width: 40px;
        height: 40px;
        font-size: 1.25rem;
    }

    .cycle-option .cycle-label {
        font-size: 1rem;
    }

    .cycle-option .cycle-price {
        font-size: 1.1rem;
    }

    .cycle-option .cycle-arrow {
        display: none;
    }
}

/* RTL Support */
[dir="rtl"] .cycle-option-inner {
    text-align: right;
}

[dir="rtl"] .cycle-option .cycle-arrow i {
    transform: rotate(180deg);
}

[dir="rtl"] .cycle-option:hover .cycle-arrow {
    transform: translateX(5px) rotate(180deg);
}

/* Animation */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.cycle-option {
    animation: fadeInUp 0.4s ease forwards;
}

.cycle-option:nth-child(1) { animation-delay: 0.05s; }
.cycle-option:nth-child(2) { animation-delay: 0.1s; }
.cycle-option:nth-child(3) { animation-delay: 0.15s; }
.cycle-option:nth-child(4) { animation-delay: 0.2s; }
.cycle-option:nth-child(5) { animation-delay: 0.25s; }
.cycle-option:nth-child(6) { animation-delay: 0.3s; }
.cycle-option:nth-child(7) { animation-delay: 0.35s; }

/* Loading State */
.cycle-option.loading {
    pointer-events: none;
    opacity: 0.6;
}

.cycle-option.loading .cycle-icon {
    animation: spin 1s linear infinite;
}

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

/* Success State */
.cycle-option.selected .cycle-icon i::before {
    content: "\f00c";  /* FontAwesome check icon */
}

