/* Frontend styles for WooCommerce Installment & Credit Manager */

.wic-installment-info {
    margin: 15px 0;
    padding: 15px;
    background-color: #f5f5f5;
    border-left: 4px solid #333;
    border-radius: 4px;
}

.wic-payment-text {
    margin: 0;
    font-size: 16px;
    color: #333;
    display: flex;
    align-items: center;
    gap: 15px;
}

.wic-payment-text strong {
    color: #333;
    font-weight: bold;
}

.wic-installment-link {
    display: inline-block;
    padding: 6px 16px;
    background-color: #ffd216;
    color: black;
    text-decoration: none;
    border-radius: 4px;
    font-weight: 600;
    transition: background-color 0.3s ease;
}

.wic-installment-link:hover {
    background-color: #0b7dda;
    text-decoration: none;
}

/* Installment Tab Styles */
.wic-installment-tab {
    display: flex;
    gap: 30px;
    flex-wrap: wrap;
    padding: 20px 0;
}

.wic-installment-section,
.wic-credit-section {
    flex: 1;
    min-width: 300px;
    padding: 20px;
    background-color: #ffffff;
    border: 1px solid #ddd;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.wic-installment-section h3,
.wic-credit-section h3 {
    margin-top: 0;
    color: #333;
    font-size: 20px;
    margin-bottom: 10px;
}

.wic-offer {
    color: #2196F3;
    font-weight: 600;
    margin-bottom: 15px;
    font-size: 14px;
}

.wic-payment-details {
    margin: 20px 0;
    padding: 15px;
    background-color: #f9f9f9;
    border-radius: 4px;
}

.wic-payment-details p {
    margin: 10px 0;
    font-size: 14px;
    color: #555;
}

.wic-monthly-payment {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
    background-color: #e8f4f8;
    border-radius: 4px;
    margin-top: 15px !important;
}

.wic-monthly-payment strong {
    color: #2196F3;
}

.wic-price {
    color: #d9534f;
    font-weight: bold;
    font-size: 18px;
}

/* Schedule Table Styles */
.wic-schedule-table {
    width: 100%;
    margin-top: 20px;
    border-collapse: collapse;
    font-size: 14px;
}

.wic-schedule-table thead {
    background-color: #ffd216;
    color: black;
}

.wic-schedule-table th {
    padding: 12px;
    text-align: left;
    font-weight: 600;
}

.wic-schedule-table td {
    padding: 10px 12px;
    border-bottom: 1px solid #ddd;
}

.wic-schedule-table tbody tr:nth-child(odd) {
    background-color: #f9f9f9;
}

.wic-schedule-table tbody tr:hover {
    background-color: #f0f0f0;
}

.wic-schedule-table td:last-child {
    font-weight: 600;
    color: #2196F3;
}

@media (max-width: 768px) {
    .wic-installment-tab {
        flex-direction: column;
    }
    
    .wic-installment-section,
    .wic-credit-section {
        min-width: 100%;
    }
    
    .wic-payment-text {
        flex-direction: column;
        gap: 10px;
    }
    
    .wic-installment-info {
        padding: 12px;
    }
    
    .wic-schedule-table {
        font-size: 12px;
    }
    
    .wic-schedule-table th,
    .wic-schedule-table td {
        padding: 8px;
    }
}


/* ===== МОДАЛЬНОЕ ОКНО ===== */

.wic-popup-modal {
    display: none;
    position: fixed;
    z-index: 999999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(3px);
    animation: wicFadeIn 0.3s ease-in-out;
}

.wic-popup-content {
    background-color: #ffffff;
    margin: 5% auto;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    max-width: 550px;
    width: 90%;
    position: relative;
    animation: wicSlideDown 0.3s ease-out;
}

.wic-popup-content h3 {
    margin: 0 0 25px 0;
    font-size: 24px;
    font-weight: 600;
    color: #333;
    line-height: 1.3;
}

.wic-popup-content h4 {
    margin: 15px 0 10px 0;
    font-size: 16px;
    font-weight: 600;
    color: #333;
}

.wic-popup-close {
    position: absolute;
    right: 20px;
    top: 20px;
    font-size: 32px;
    font-weight: 300;
    color: #999;
    cursor: pointer;
    transition: all 0.2s ease;
    line-height: 1;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.wic-popup-close:hover {
    color: #333;
    transform: rotate(90deg);
}

.wic-popup-form-container {
    margin-top: 20px;
}

/* Варианты оплаты */
.wic-payment-options {
    display: flex;
    gap: 15px;
    margin-bottom: 25px;
}

.wic-payment-option {
    flex: 1;
    padding: 15px;
    border: 2px solid #f0f0f0;
    border-radius: 8px;
    text-align: center;
    transition: all 0.3s ease;
}

.wic-payment-option:hover {
    border-color: #2196F3;
    background-color: #f9fbff;
}

.wic-payment-option h4 {
    margin: 0 0 10px 0;
    font-size: 15px;
    color: #333;
}

.wic-option-price {
    font-size: 18px;
    color: #2196F3;
    font-weight: bold;
    margin: 8px 0;
}

.wic-option-desc {
    font-size: 12px;
    color: #999;
    margin: 0;
}

/* Стилизация CF7 в попапе */
.wic-popup-form-container input[type="text"],
.wic-popup-form-container input[type="tel"],
.wic-popup-form-container input[type="email"],
.wic-popup-form-container textarea {
    width: 100%;
    padding: 12px 15px;
    margin-bottom: 15px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 15px;
    transition: border-color 0.2s ease;
    box-sizing: border-box;
}

.wic-popup-form-container input:focus,
.wic-popup-form-container textarea:focus {
    outline: none;
    border-color: #2196F3;
    box-shadow: 0 0 0 3px rgba(33, 150, 243, 0.1);
}

.wic-popup-form-container input[type="submit"] {
    background-color: #ffd215; 
    color: white;
    padding: 14px 30px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    width: 100%;
    transition: all 0.3s ease;
}

.wic-popup-form-container input[type="submit"]:hover { 
    background-color: #ffd217;
	color: #000000;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(33, 150, 243, 0.3);
}

/* Сообщения */
.wic-popup-form-container .wpcf7-response-output {
    margin-top: 15px;
    padding: 12px;
    border-radius: 6px;
    font-size: 14px;
}

.wic-popup-form-container .wpcf7-mail-sent-ok {
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
}

.wic-popup-form-container .wpcf7-validation-errors,
.wic-popup-form-container .wpcf7-mail-sent-ng {
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}

body.wic-popup-open {
    overflow: hidden;
}

/* Анимации */
@keyframes wicFadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes wicSlideDown {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Адаптивность */
@media (max-width: 768px) {
    .wic-popup-content {
        margin: 10% auto;
        padding: 30px 20px;
        width: 95%;
    }
    
    .wic-popup-content h3 {
        font-size: 20px;
        margin-bottom: 20px;
    }
    
    .wic-payment-options {
        flex-direction: column;
        gap: 10px;
    }
    
    .wic-popup-close {
        right: 15px;
        top: 15px;
        font-size: 28px;
    }
}

@media (max-width: 480px) {
    .wic-popup-content {
        margin: 15% auto;
        padding: 25px 15px;
    }
    
    .wic-popup-content h3 {
        font-size: 18px;
    }
    
    .wic-payment-options {
        flex-direction: column;
    }
}


/******************************/



/* ===== МОДАЛЬНОЕ ОКНО ===== */

.wic-popup-modal {
    display: none;
    position: fixed;
    z-index: 999999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(3px);
    animation: wicFadeIn 0.3s ease-in-out;
}

.wic-popup-content {
    background-color: #ffffff;
    margin: 5% auto;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    max-width: 550px;
    width: 90%;
    position: relative;
    animation: wicSlideDown 0.3s ease-out;
}

.wic-popup-content h3 {
    margin: 0 0 25px 0;
    font-size: 24px;
    font-weight: 600;
    color: #333;
    line-height: 1.3;
}

.wic-popup-content h4 {
    margin: 15px 0 10px 0;
    font-size: 16px;
    font-weight: 600;
    color: #333;
}

.wic-popup-close {
    position: absolute;
    right: 20px;
    top: 20px;
    font-size: 32px;
    font-weight: 300;
    color: #999;
    cursor: pointer;
    transition: all 0.2s ease;
    line-height: 1;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.wic-popup-close:hover {
    color: #333;
    transform: rotate(90deg);
}

.wic-popup-form-container {
    margin-top: 20px;
}

/* Варианты оплаты */
.wic-payment-options {
    display: flex;
    gap: 15px;
    margin-bottom: 25px;
}

.wic-payment-option {
    flex: 1;
    padding: 15px;
    border: 2px solid #f0f0f0;
    border-radius: 8px;
    text-align: center;
    transition: all 0.3s ease;
}

.wic-payment-option:hover {
    border-color: #2196F3;
    background-color: #f9fbff;
}

.wic-payment-option h4 {
    margin: 0 0 10px 0;
    font-size: 15px;
    color: #333;
}

.wic-option-price {
    font-size: 18px;
    color: #2196F3;
    font-weight: bold;
    margin: 8px 0;
}

.wic-option-desc {
    font-size: 12px;
    color: #999;
    margin: 0;
}

/* Стилизация CF7 в попапе */
.wic-popup-form-container input[type="text"],
.wic-popup-form-container input[type="tel"],
.wic-popup-form-container input[type="email"],
.wic-popup-form-container textarea {
    width: 100%;
    padding: 12px 15px;
    margin-bottom: 15px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 15px;
    transition: border-color 0.2s ease;
    box-sizing: border-box;
}

.wic-popup-form-container input:focus,
.wic-popup-form-container textarea:focus {
    outline: none;
    border-color: #2196F3;
    box-shadow: 0 0 0 3px rgba(33, 150, 243, 0.1);
}

/* Сообщения */
.wic-popup-form-container .wpcf7-response-output {
    margin-top: 15px;
    padding: 12px;
    border-radius: 6px;
    font-size: 14px;
}

.wic-popup-form-container .wpcf7-mail-sent-ok {
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
}

.wic-popup-form-container .wpcf7-validation-errors,
.wic-popup-form-container .wpcf7-mail-sent-ng {
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}

body.wic-popup-open {
    overflow: hidden;
}

/* Анимации */
@keyframes wicFadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes wicSlideDown {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Адаптивность */
@media (max-width: 768px) {
    .wic-popup-content {
        margin: 10% auto;
        padding: 30px 20px;
        width: 95%;
    }
    
    .wic-popup-content h3 {
        font-size: 20px;
        margin-bottom: 20px;
    }
    
    .wic-payment-options {
        flex-direction: column;
        gap: 10px;
    }
    
    .wic-popup-close {
        right: 15px;
        top: 15px;
        font-size: 28px;
    }
}

@media (max-width: 480px) {
    .wic-popup-content {
        margin: 15% auto;
        padding: 25px 15px;
    }
    
    .wic-popup-content h3 {
        font-size: 18px;
    }
    
    .wic-payment-options {
        flex-direction: column;
    }
}



