/* css/client_advances.css - Стили для модального окна авансов */

/* Модальное окно авансов */
.advance-modal {
    max-width: 550px;
    background: linear-gradient(145deg, #1e1f2a, #181922);
    border-radius: 16px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6);
    border: 1px solid #2a2b36;
    overflow: hidden;
}

/* Заголовок с балансом */
.advance-header {
    padding: 20px;
    background: linear-gradient(145deg, #232430, #1d1e28);
    border-bottom: 1px solid #2a2b36;
}

.balance-display {
    background: linear-gradient(145deg, #1a1b23, #14151c);
    border-radius: 12px;
    padding: 15px;
    border: 1px solid #4a90e2;
    margin-bottom: 10px;
}

.balance-label {
    color: #8c8e9a;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 5px;
}

.balance-amount {
    color: #34c759;
    font-size: 32px;
    font-weight: bold;
}

/* Форма добавления аванса */
.advance-form {
    padding: 20px;
}

.advance-input-group {
    margin-bottom: 20px;
}

.advance-input-label {
    color: #8c8e9a;
    font-size: 12px;
    margin-bottom: 8px;
    display: block;
}

.advance-amount-input {
    width: 100%;
    padding: 15px;
    background: rgba(12, 12, 14, 0.8);
    border: 1px solid #2a2b36;
    border-radius: 8px;
    color: #ffffff;
    font-size: 24px;
    font-weight: bold;
    text-align: center;
    outline: none;
    transition: all 0.2s;
}

.advance-amount-input:focus {
    border-color: #4a90e2;
    box-shadow: 0 0 0 2px rgba(74, 144, 226, 0.2);
}

/* Кнопки способов оплаты - УСИЛЕННЫЕ СТИЛИ */
.payment-methods {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-bottom: 20px;
}

.payment-method-btn {
    padding: 12px;
    background: linear-gradient(145deg, #1a1b23, #14151c) !important;
    border: 1px solid #2a2b36 !important;
    border-radius: 8px;
    color: #ffffff !important;
    font-size: 14px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    cursor: pointer;
    transition: all 0.2s ease !important;
}

/* Стили для активных кнопок - ОЧЕНЬ ЯРКИЕ */
.payment-method-btn.active {
    background: linear-gradient(145deg, #4a90e2, #357abd) !important;
    border-color: #4a90e2 !important;
    color: white !important;
    transform: scale(0.98);
    box-shadow: 0 0 15px rgba(74, 144, 226, 0.5) !important;
}

/* Индивидуальные цвета для активных кнопок */
.payment-method-btn.cash.active {
    background: linear-gradient(145deg, #34c759, #2db54d) !important;
    border-color: #34c759 !important;
    box-shadow: 0 0 15px rgba(52, 199, 89, 0.5) !important;
}

.payment-method-btn.card.active {
    background: linear-gradient(145deg, #4a90e2, #357abd) !important;
    border-color: #4a90e2 !important;
    box-shadow: 0 0 15px rgba(74, 144, 226, 0.5) !important;
}

.payment-method-btn.bank.active {
    background: linear-gradient(145deg, #ff9500, #e08600) !important;
    border-color: #ff9500 !important;
    box-shadow: 0 0 15px rgba(255, 149, 0, 0.5) !important;
}

/* Стили для иконок в активном состоянии */
.payment-method-btn.active .icon {
    color: white !important;
}

/* Эффект при наведении */
.payment-method-btn:hover:not(.active) {
    background: linear-gradient(145deg, #24252e, #1e1f28) !important;
    border-color: #3a3b45 !important;
}

/* Цифровая клавиатура */
.advance-keyboard {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-top: 20px;
}

.advance-key {
    padding: 20px;
    background: linear-gradient(145deg, #24252e, #1e1f28);
    border: 1px solid #2c2d37;
    border-radius: 8px;
    color: #ffffff;
    font-size: 24px;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
}

.advance-key:hover {
    background: #2a2b36;
    transform: translateY(-2px);
}

.advance-key:active {
    transform: translateY(0);
}

.advance-key.clear {
    background: linear-gradient(145deg, #ff3b30, #d63031);
    border-color: #ff453a;
}

.advance-key.backspace {
    background: linear-gradient(145deg, #4a4a4a, #3a3a3a);
    border-color: #5a5a5a;
}

/* История операций */
.advance-history {
    max-height: 200px;
    overflow-y: auto;
    margin-top: 20px;
    padding: 15px;
    background: rgba(12, 12, 14, 0.5);
    border-radius: 8px;
    border: 1px solid #2a2b36;
}

.history-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px;
    border-bottom: 1px solid #2a2b36;
    font-size: 12px;
}

.history-item:last-child {
    border-bottom: none;
}

.history-item.deposit .history-amount {
    color: #34c759;
}

.history-item.withdrawal .history-amount {
    color: #ff3b30;
}

.history-date {
    color: #8c8e9a;
}

.history-amount {
    font-weight: bold;
}

/* Кнопки действий */
.advance-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.advance-btn {
    flex: 1;
    padding: 15px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    cursor: pointer;
    transition: all 0.2s;
    border: none;
}

.advance-btn.cancel {
    background: #2a2b36;
    color: #ffffff;
}

.advance-btn.save {
    background: linear-gradient(145deg, #34c759, #2db54d);
    color: #ffffff;
}

.advance-btn.save:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}