/* ========== ОСНОВНЫЕ СТИЛИ ========== */
.abook-booking-wrapper,
.abook-account-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* ========== ШАГИ ========== */
.abook-steps {
    display: flex;
    justify-content: space-between;
    margin-bottom: 40px;
    border-bottom: 2px solid #e0e0e0;
    padding-bottom: 20px;
}

.abook-step-item {
    flex: 1;
    text-align: center;
    cursor: pointer;
}

.abook-step-item .step-number {
    display: inline-block;
    width: 30px;
    height: 30px;
    line-height: 30px;
    border-radius: 50%;
    background: #e0e0e0;
    color: #666;
    margin-bottom: 5px;
}

.abook-step-item.active .step-number {
    background: #183c80;
    color: #fff;
}

.abook-step-item .step-label {
    font-size: 14px;
    color: #666;
}

.abook-step-item.active .step-label {
    color: #183c80;
    font-weight: bold;
}

/* ========== КАТЕГОРИИ ========== */
.abook-categories {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 30px;
}

.abook-cat-filter {
    padding: 8px 16px;
    border: 1px solid #ddd;
    background: #fff;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s;
	color: #183c80;
}

.abook-cat-filter:hover {
    border-color: #183c80;
}

.abook-cat-filter.active {
    background: #183c80;
    color: #fff;
    border-color: #183c80;
}

/* ========== СЕТКА УСЛУГ ========== */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.abook-service-card {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 20px;
    transition: all 0.2s;
}

.abook-service-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.service-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.service-name {
    margin: 0;
    font-size: 18px;
    color: #333;
}

.service-price {
    font-size: 20px;
    font-weight: bold;
    color: #183c80;
}

.service-duration,
.service-slots {
    display: flex;
    align-items: center;
    gap: 5px;
    color: #666;
    font-size: 14px;
    margin-bottom: 10px;
}

.abook-select-service {
    width: 100%;
    padding: 10px;
    background: #183c80;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    margin-top: 15px;
    font-size: 14px;
}

.abook-select-service:hover {
    background: #0f2a5a;
}

/* ========== ДАТА И ВРЕМЯ ========== */
.abook-datetime-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 30px;
}

.abook-datepicker {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
}

.time-slots-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    gap: 10px;
}

.time-slot {
    padding: 10px;
    text-align: center;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: #fff;
    cursor: pointer;
    transition: all 0.2s;
	position: relative;
	color: #183c80;
}

.time-slot:hover {
    background: #f0f0f0;
}

.time-slot.selected {
    background: #183c80;
    color: #fff;
    border-color: #183c80;
}

.time-slot .slots-count {
    font-size: 11px;
    color: #28a745;
    display: block;
}

.time-slot.selected .slots-count {
    color: #fff;
}

.time-slot.full .slots-count.full {
    color: #dc3545;
}

.slots-count {
    display: block;
    font-size: 11px;
    margin-top: 3px;
}

.time-slot.full {
    background: #f5f5f5;
    color: #ccc;
    cursor: not-allowed;
    border-color: #eee;
}

/* ========== ОПЦИИ ========== */
.abook-options-grid {
    display: flex;
    flex-direction: column;
    gap: 10px;
    background: #f9f9f9;
    padding: 15px;
    border-radius: 8px;
    margin: 15px 0;
}

.abook-option-label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    padding: 8px;
    border-radius: 4px;
    transition: background 0.2s;
}

.abook-option-label:hover {
    background: #f0f0f0;
}

.abook-option-label .option-price {
    color: #28a745;
    font-size: 12px;
    margin-left: auto;
}

/* ========== ФОРМА КЛИЕНТА ========== */
.abook-form-row {
    margin-bottom: 20px;
}

.abook-form-row label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #23282d;
}

.abook-form-row .required {
    color: #dc3545;
}

.abook-form-control {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    box-sizing: border-box;
}

.abook-form-control:focus {
    border-color: #183c80;
    outline: none;
    box-shadow: 0 0 0 1px #183c80;
}

/* ========== ИТОГОВАЯ СУММА ========== */
.abook-total-price {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    text-align: center;
    margin-top: 20px;
}

.abook-total-price strong {
    font-size: 16px;
}

#abook-total-amount {
    font-size: 24px;
    font-weight: bold;
    color: #183c80;
    margin-left: 10px;
}

/* ========== КНОПКИ ========== */
.abook-btn {
    padding: 12px 24px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s;
}

.abook-btn-back {
    background: #6c757d;
    color: #fff;
}

.abook-btn-next,
.abook-btn-submit {
    background: #28a745;
    color: #fff;
}

.abook-btn-next:disabled {
    background: #ccc;
    cursor: not-allowed;
}

.abook-btn-primary {
    background: #183c80;
    color: #fff;
}

.abook-btn-logout {
    background: #dc3545;
    color: #fff;
}

.abook-nav-buttons {
    display: flex;
    justify-content: space-between;
    margin-top: 30px;
}

/* ========== СООБЩЕНИЕ ОБ УСПЕХЕ ========== */
.abook-success-message {
    text-align: center;
    padding: 40px;
    background: #d4edda;
    border-radius: 8px;
    color: #155724;
}

.success-icon {
    font-size: 48px;
    margin-bottom: 20px;
}

.abook-new-booking {
    margin-top: 20px;
    background: #28a745;
}



/* ========== КАЛЕНДАРЬ ========== */
.abook-calendar-container {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 15px;
}

.abook-calendar {
    width: 100%;
}

.calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

.calendar-prev,
.calendar-next {
    background: none;
    border: none;
    font-size: 18px;
    cursor: pointer;
    padding: 5px 10px;
    color: #183c80;
}

.calendar-title {
    font-weight: bold;
    font-size: 16px;
}

.calendar-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    text-align: center;
    margin-bottom: 10px;
}

.calendar-weekdays span {
    font-weight: bold;
    font-size: 12px;
    color: #666;
    padding: 8px;
}

.calendar-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    text-align: center;
}

.calendar-day {
    padding: 10px 5px;
    cursor: pointer;
    border-radius: 4px;
    transition: all 0.2s;
}
.calendar-day.available {
    background: #fff;
    color: #333;
    cursor: pointer;
}

.calendar-day.available:hover {
    background: #e3f2fd;
}

.calendar-day.available.selected {
    background: #183c80;
    color: #fff;
}

.calendar-day.disabled {
    color: #ccc;
    cursor: not-allowed;
    background: #f5f5f5;
}

.calendar-day.disabled.past {
    color: #ccc;
    background: #f5f5f5;
}

.calendar-day.disabled.not-working {
    color: #ff9999;
    background: #fff5f5;
}

.calendar-day.disabled.not-working:hover {
    background: #ffe0e0;
}

.abook-datetime-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 30px;
}

.abook-time-container label,
.abook-calendar-container label {
    display: block;
    font-weight: bold;
    margin-bottom: 10px;
    color: #333;
}

.abook-time-slots {
    min-height: 300px;
}

/* ========== БЛОК ОПЦИЙ ========== */
.abook-options-section {
    margin: 20px 0;
    padding: 15px;
    background: #f9f9f9;
    border-radius: 8px;
}

.abook-options-title {
    font-weight: bold;
    margin-bottom: 15px;
    color: #333;
}

.abook-options-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.abook-option-label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    padding: 8px;
    border-radius: 4px;
    transition: background 0.2s;
}

.abook-option-label:hover {
    background: #f0f0f0;
}

.abook-option-label .option-price {
    color: #28a745;
    font-size: 12px;
    margin-left: auto;
}

/* ========== ИТОГОВАЯ СУММА ========== */
.abook-total-price-step2 {
    text-align: right;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    margin: 20px 0;
}

.abook-total-price-step2 strong {
    font-size: 16px;
}

#step2-total-amount {
    font-size: 20px;
    font-weight: bold;
    color: #183c80;
    margin-left: 10px;
}

/* ========== АДАПТИВ ========== */
@media (max-width: 768px) {
    .abook-datetime-wrapper {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .calendar-day {
        padding: 8px 2px;
        font-size: 12px;
    }
}



/* ========== ЛИЧНЫЙ КАБИНЕТ ========== */
.abook-account-container {
    max-width: 800px;
    margin: 0 auto;
}

.abook-login-form {
    background: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.abook-account-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.abook-bookings-table {
    overflow-x: auto;
}

.abook-table {
    width: 100%;
    border-collapse: collapse;
}

.abook-table th,
.abook-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #e0e0e0;
}

.abook-table th {
    background: #f8f9fa;
    font-weight: bold;
}

.abook-cancel-booking {
    padding: 5px 10px;
    background: #dc3545;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
}

/* ========== СТАТУСЫ ========== */
.status-pending { background: #ffc107; color: #856404; padding: 3px 8px; border-radius: 4px; display: inline-block; }
.status-confirmed { background: #28a745; color: #fff; padding: 3px 8px; border-radius: 4px; display: inline-block; }
.status-completed { background: #17a2b8; color: #fff; padding: 3px 8px; border-radius: 4px; display: inline-block; }
.status-cancelled { background: #dc3545; color: #fff; padding: 3px 8px; border-radius: 4px; display: inline-block; }

/* ========== АДАПТИВ ========== */
@media (max-width: 768px) {
    .abook-steps {
        margin-bottom: 20px;
    }
    
    .abook-step-item .step-label {
        font-size: 12px;
    }
    
    .abook-datetime-container {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .services-grid {
        grid-template-columns: 1fr;
    }
    
    .abook-categories {
        gap: 8px;
    }
    
    .abook-cat-filter {
        padding: 6px 12px;
        font-size: 12px;
    }
    
    .abook-nav-buttons {
        flex-direction: column;
        gap: 10px;
    }
    
    .abook-btn {
        text-align: center;
    }
    
    .abook-table {
        font-size: 12px;
    }
    
    .abook-table th,
    .abook-table td {
        padding: 8px;
    }
}

/* ========== ЗАГРУЗКА ========== */
.abook-loading {
    text-align: center;
    padding: 20px;
}

.abook-loading::after {
    content: '';
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #183c80;
    border-radius: 50%;
    animation: abook-spin 1s linear infinite;
}

@keyframes abook-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.abook-error {
    color: #dc3545;
    text-align: center;
    padding: 10px;
}

.abook-hint {
    color: #666;
    text-align: center;
    padding: 10px;
}
/* ========== ЛИЧНЫЙ КАБИНЕТ - ТАБЛИЦА ========== */
.abook-bookings-list {
    overflow-x: auto;
    margin-top: 20px;
}

.abook-bookings-table {
    width: 100%;
    overflow-x: auto;
    background: #fff;
    border-radius: 8px;
    border: 1px solid #e0e0e0;
}

.abook-bookings-table table {
    width: 100%;
    min-width: 600px;
    border-collapse: collapse;
    font-size: 14px;
}

.abook-bookings-table th,
.abook-bookings-table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #e0e0e0;
}

.abook-bookings-table th {
    background: #f8f9fa;
    font-weight: 600;
    color: #333;
}

.abook-bookings-table tr:last-child td {
    border-bottom: none;
}

.abook-bookings-table tr:hover {
    background: #f5f5f5;
}

/* Статусы в личном кабинете */
.abook-bookings-table .status-pending,
.abook-bookings-table .status-confirmed,
.abook-bookings-table .status-completed,
.abook-bookings-table .status-cancelled {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
}

.abook-bookings-table .status-pending {
    background: #fff3cd;
    color: #856404;
}

.abook-bookings-table .status-confirmed {
    background: #d4edda;
    color: #155724;
}

.abook-bookings-table .status-completed {
    background: #d1ecf1;
    color: #0c5460;
}

.abook-bookings-table .status-cancelled {
    background: #f8d7da;
    color: #721c24;
}

/* Кнопка отмены в таблице */
.abook-cancel-booking {
    padding: 5px 12px;
    background: #dc3545;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
    transition: background 0.2s;
}

.abook-cancel-booking:hover {
    background: #c82333;
}

/* Пустое состояние */
.abook-empty {
    text-align: center;
    padding: 40px;
    color: #666;
    background: #f9f9f9;
    border-radius: 8px;
}

/* Адаптив для таблицы */
@media (max-width: 768px) {
    .abook-bookings-table th,
    .abook-bookings-table td {
        padding: 8px 10px;
        font-size: 12px;
    }
    
    .abook-cancel-booking {
        padding: 3px 8px;
        font-size: 11px;
    }
}
/* Telegram кнопка */
.abook-telegram-btn {
    background: #0088cc;
    color: #fff;
    margin-right: 10px;
}

.abook-telegram-btn:hover {
    background: #006699;
}

.abook-telegram-section {
    margin: 20px 0;
    padding: 15px;
    background: #e8f4fd;
    border-radius: 8px;
    text-align: center;
}

.abook-telegram-section p {
    margin-bottom: 10px;
    color: #333;
}

.calendar-loading {
    text-align: center;
    padding: 40px;
    color: #666;
}

.calendar-loading::after {
    content: '';
    display: inline-block;
    width: 20px;
    height: 20px;
    margin-left: 10px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #183c80;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    vertical-align: middle;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}