/* @charset "UTF-8";





.week-view {
  display: grid;
  grid-template-columns: 0.8fr repeat(7, 1fr);
  gap: 0;
  padding: 10px;
  background-color: #f8f9fa;
  border-radius: 8px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.week-view__head,
.week-view__body,
.week-view__row {
  display: contents;
}

.week-view__head-cell,
.week-view__cell,
.week-view__time-slot {
  text-align: center;
  border-right: 1px solid #ffffff;
  background-color: #ffffff;
}

.week-view__head-cell {
  font-weight: bold;
  background-color: #343a40;
  color: white;
  border-radius: 8px;
}

.week-view__cell {
  position: relative;
  padding: 20px;
  transition: background-color 0.3s ease, transform 0.2s ease;
  cursor: pointer;
  border: 1px solid #ccc;
}

.week-view__cell:last-child {
  border-right: none;
}

.week-view__cell.blocked {
  pointer-events: none;
  opacity: 0.5;
}

.week-view__cell.booked {
  background-color: #ff4d4f;
  color: white;
  pointer-events: none;
}

.week-view__cell.selected {
  background-color: #28a745;
  color: white;
}

.week-view__cell.highlighted {
  background-color: #17a2b8;
  color: white;
}

.week-view__cell.available {
  background-color: #f1f3f5;
}

.week-view__cell:hover {
  transform: scale(1.05);
}

.week-view__time-slot {
  font-size: 14px;
  color: #000000;
  font-weight: bold;
}

.blocked {
  opacity: 0.5;
  pointer-events: none;
} */


/* * {
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
} */

/* .booking-summary {
  margin-top: 20px;
  padding: 15px;
  background-color: #fff;
  border: 1px solid #dee2e6;
  border-radius: 8px;
  text-align: center;
}

.booking-summary h3 {
  margin-bottom: 15px;
  font-size: 24px;
}

.booking-summary button {
  background-color: #007bff;
  color: white;
  padding: 10px 20px;
  border: none;
  border-radius: 5px;
  font-size: 16px;
  cursor: pointer;
}

.booking-summary button:disabled {
  background-color: #6c757d;
  cursor: not-allowed;
}

.booking-form {
  padding: 20px;
  background-color: #fff;
  border-radius: 8px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.booking-form__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.booking-form__title {
  font-size: 24px;
  font-weight: bold;
}

.booking-form__back-button {
  background-color: transparent;
  border: none;
  color: #007bff;
  cursor: pointer;
}

.booking-form__details {
  margin-top: 20px;
}

.booking-form__studio,
.booking-form__hall {
  font-size: 18px;
  margin-bottom: 10px;
}

.booking-form__date-block {
  display: flex;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px solid #dee2e6;
}

.booking-form__input,
.booking-form__textarea {
  width: 100%;
  padding: 10px;
  margin-top: 10px;
  margin-bottom: 15px;
  border: 1px solid #ced4da;
  border-radius: 4px;
  font-size: 16px;
}

.booking-form__submit {
  text-align: center;
}

.booking-form__submit-button {
  background-color: #28a745;
  color: white;
  padding: 10px 20px;
  border: none;
  border-radius: 5px;
  font-size: 18px;
  cursor: pointer;
}

.booking-form__submit-button:hover {
  background-color: #218838;
}

.week-view {
  display: flex;
  flex-direction: column;
  border: 1px solid #ccc;
  border-radius: 8px;
  overflow: hidden;
  position: relative;
}

.week-view__head {
  display: flex;
  background-color: #f9f9f9;
}

.week-view__head-cell {
  flex: 1;
  text-align: center;
  padding: 10px;
  font-weight: bold;
  background-color: #e0e0e0;
  position: relative;
}

.week-view__time-head {
  width: 80px;
  background-color: #f9f9f9;
}

.week-view__body {
  display: flex;
  flex-direction: column;
  position: relative;
}

.week-view__row {
  display: flex;
  position: relative;
}

.week-view__time-slot {
  width: 80px;
  padding: 10px;
  text-align: center;
  background-color: #f0f0f0;
  position: relative;
}

.week-view__cell {
  flex: 1;
  padding: 10px;
  border: 1px solid #ddd;
  position: relative;
  cursor: pointer;
  background-color: white;
  transition: background-color 0.3s ease;
}

.week-view__cell.booked {
  background-color: red;
}

.week-view__cell.blocked {
  pointer-events: none;
  background-color: #f0f0f0;
}

.range-block {
  position: absolute;
  z-index: 1;
  background-color: yellow;
  opacity: 0.6;
  text-align: center;
  font-weight: bold;
  padding-top: 8px;
}
 */

 .week-view {
  display: grid;
  grid-template-columns: 80px repeat(7, 1fr);
  gap: 1px;
  background: #e0e0e0;
  border-radius: 8px;
  overflow: hidden;
  margin: 20px 0;
  font-family: 'Inter', sans-serif;
}

.week-view__head {
  display: contents;
}

.week-view__head-cell {
  padding: 12px 8px;
  background: #2c3e50;
  color: white;
  text-align: center;
  font-weight: 500;
}

.week-view__time-head {
  background: #2c3e50;
}

.week-view__body {
  display: contents;
}

.week-view__row {
  display: contents;
}

.week-view__time-slot {
  padding: 12px 8px;
  background: #f8f9fa;
  text-align: center;
  font-size: 14px;
  color: #495057;
}

.week-view__cell {
  padding: 12px;
  background: white;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.week-view__cell:hover {
  background: #f1f3f5;
}

.week-view__cell.booked {
  background: #ff6b6b;
  color: white;
  cursor: not-allowed;
}

.week-view__cell.selected {
  background: #40c057;
  color: white;
}

@media (max-width: 768px) {
  .week-view {
    grid-template-columns: 60px repeat(7, 1fr);
    font-size: 14px;
  }

  .week-view__head-cell,
  .week-view__time-slot,
  .week-view__cell {
    padding: 8px 4px;
  }
}

@media (max-width: 480px) {
  .week-view {
    grid-template-columns: 50px repeat(7, 1fr);
    font-size: 12px;
  }
}

/* ___________________________________________________________ */

.booking-summary {
  background: white;
  padding: 2rem;
  border-radius: 10px;
  margin-top: 2rem;
  box-shadow: 0 2px 15px rgba(0, 0, 0, 0.05);
  font-family: 'Helvetica Neue', Arial, sans-serif;
}

.booking-ranges {
  margin-bottom: 1.5rem;
}

.booking-summary h3 {
  font-size: 1.5rem;
  font-weight: 300;
  color: #444;
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid #f0f0f0;
}

.booking-summary p {
  font-size: 1.1rem;
  color: #666;
  margin-bottom: 1.5rem;
}

.booking-date-group {
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid #f5f5f5;
}

.booking-date-group:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.booking-date-group h4 {
  font-size: 1.2rem;
  font-weight: 400;
  color: #444;
  margin-bottom: 0.8rem;
  padding-left: 0.5rem;
  border-left: 3px solid #d4af37; /* Золотой акцент */
}

.booking-date-group ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.booking-date-group li {
  padding: 0.8rem 1rem;
  margin-bottom: 0.5rem;
  background-color: #fafafa;
  border-radius: 6px;
  font-size: 1rem;
  color: #555;
  border-left: 2px solid #d4af37;
  transition: all 0.2s ease;
}

.booking-date-group li:hover {
  background-color: #f5f5f5;
  transform: translateX(3px);
}

.booking-summary > h3:last-of-type {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid #eee;
  text-align: right;
  font-size: 1.3rem;
  font-weight: 500;
  color: #333;
}

.booking-summary button {
  background-color: #d4af37;
  color: white;
  border: none;
  padding: 1rem 2rem;
  font-size: 1.1rem;
  border-radius: 50px;
  cursor: pointer;
  transition: all 0.3s ease;
  width: 100%;
  max-width: 300px;
  font-weight: 500;
  letter-spacing: 0.5px;
  box-shadow: 0 4px 15px rgba(212, 175, 55, 0.3);
  margin-top: 1.5rem;
  display: block;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

.booking-summary button:hover:not(:disabled) {
  background-color: #c9a227;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(212, 175, 55, 0.4);
}

.booking-summary button:disabled {
  background-color: #ccc;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.booking-summary .logo__link {
  color: white;
  text-decoration: none;
  display: block;
}

/* Адаптивные стили */
@media (max-width: 768px) {
  .booking-summary {
    padding: 1.5rem;
  }

  .booking-summary h3 {
    font-size: 1.3rem;
  }

  .booking-date-group h4 {
    font-size: 1.1rem;
  }

  .booking-date-group li {
    padding: 0.7rem 0.9rem;
    font-size: 0.95rem;
  }
}

@media (max-width: 480px) {
  .booking-summary {
    padding: 1.2rem;
  }

  .booking-summary button {
    padding: 0.9rem 1.5rem;
    font-size: 1rem;
    max-width: 100%;
  }
}


.hall-switcher {
  display: flex;
  gap: 10px;
  margin-bottom: 20px;
}

.hall-switcher__button {
  padding: 8px 16px;
  border: 1px solid #ccc;
  background: white;
  cursor: pointer;
  border-radius: 4px;
}

.hall-switcher__button.active {
  background: #007bff;
  color: white;
  border-color: #007bff;
}


/* Обновленные стили для верхней части с кнопками выбора зала */
.booking-header {
  margin-bottom: 30px;
  padding: 20px;
  background: white;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.booking-header__title {
  font-size: 1.8rem;
  font-weight: 600;
  color: #2c3e50;
  margin-bottom: 15px;
  text-align: center;
}

.booking-header__subtitle {
  font-size: 1.1rem;
  color: #7f8c8d;
  text-align: center;
  margin-bottom: 25px;
}

.hall-switcher {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin-top: 20px;
}

.hall-switcher__button {
  padding: 12px 24px;
  border: none;
  background: #f8f9fa;
  color: #2c3e50;
  cursor: pointer;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 500;
  transition: all 0.3s ease;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  position: relative;
  overflow: hidden;
}

.hall-switcher__button::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, rgba(255,255,255,0.2), rgba(255,255,255,0));
  opacity: 0;
  transition: opacity 0.3s ease;
}

.hall-switcher__button:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
  background: #e9ecef;
}

.hall-switcher__button:hover::before {
  opacity: 1;
}

.hall-switcher__button.active {
  background: linear-gradient(135deg, #3498db, #2c3e50);
  color: white;
  box-shadow: 0 4px 15px rgba(52, 152, 219, 0.4);
}

.hall-switcher__button.active:hover {
  background: linear-gradient(135deg, #2980b9, #1a252f);
  transform: translateY(-2px);
}

/* Адаптивность */
@media (max-width: 768px) {
  .booking-header {
    padding: 15px;
  }

  .booking-header__title {
    font-size: 1.5rem;
  }

  .booking-header__subtitle {
    font-size: 1rem;
  }

  .hall-switcher {
    flex-wrap: wrap;
  }

  .hall-switcher__button {
    padding: 10px 16px;
    font-size: 0.9rem;
  }
}

@media (max-width: 480px) {
  .booking-header {
    padding: 12px;
  }

  .booking-header__title {
    font-size: 1.3rem;
  }

  .hall-switcher {
    gap: 8px;
  }

  .hall-switcher__button {
    padding: 8px 12px;
    font-size: 0.85rem;
  }
}

.visually-hidden {
  display: none;
  }

/* ------------------------------------- */
.week-view {
  display: grid;
  grid-template-columns: 80px repeat(7, 1fr);
  gap: 1px;
  background: white; /* Изменено с #e0e0e0 на white */
  border-radius: 8px;
  overflow: hidden;
  margin: 20px 0;
  font-family: 'Inter', sans-serif;
  border: 1px solid #f0f0f0; /* Добавляем легкую границу вокруг всей таблицы */
}

.week-view__head-cell {
  padding: 12px 8px;
  background: #f8f9fa; /* Светлый фон вместо #2c3e50 */
  color: #495057; /* Темно-серый текст вместо белого */
  text-align: center;
  font-weight: 500;
  border-bottom: 1px solid #e9ecef; /* Легкая разделительная линия */
}

.week-view__time-slot {
  padding: 12px 8px;
  background: #f8f9fa; /* Светлый фон для колонки времени */
  text-align: center;
  font-size: 14px;
  color: #495057;
  border-right: 1px solid #e9ecef; /* Легкая вертикальная линия */
}

.week-view__cell {
  padding: 12px;
  background: white;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  border-bottom: 1px solid #f5f5f5; /* Легкие горизонтальные линии */
  border-right: 1px solid #f5f5f5; /* Легкие вертикальные линии */
}

/* Убираем границу у последней ячейки в ряду */
.week-view__cell:last-child {
  border-right: none;
}

/* Стили для состояний ячеек */
.week-view__cell.booked {
  background: #fff5f5; /* Светло-красный для занятых */
  color: #ff6b6b;
}

.week-view__cell.selected {
  background: #f0fff4; /* Светло-зеленый для выбранных */
  color: #40c057;
}

.week-view__cell:hover {
  background: #f8f9fa; /* Легкий hover-эффект */
}

.hall-switcher__button {
  padding: 10px 20px;
  background: white;
  color: #495057;
  border: 1px solid #e9ecef;
  border-radius: 6px;
  transition: all 0.2s;
}

.hall-switcher__button.active {
  background: #495057;
  color: white;
  border-color: #495057;
}

.booking-header {
  background: white;
  padding: 20px;
  border-radius: 8px;
  margin-bottom: 20px;
}

.week-hall-name {
  color: white;
  display: flex;
  justify-content: center;
  align-items: center;
}

/* Стили для админского попапа */
.booking-popup-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.7);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 10000;
  padding: 20px;
  backdrop-filter: blur(5px);
}

.booking-popup {
  background: white;
  border-radius: 16px;
  padding: 24px;
  width: 100%;
  max-width: 400px;
  max-height: 85vh;
  overflow-y: auto;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
  animation: popupSlideIn 0.3s ease-out;
}

@keyframes popupSlideIn {
  from {
    opacity: 0;
    transform: translateY(50px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.popup-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 2px solid #f1f3f5;
}

.popup-header h3 {
  margin: 0;
  color: #2c3e50;
  font-size: 20px;
  font-weight: 600;
}

.popup-close {
  background: none;
  border: none;
  font-size: 28px;
  cursor: pointer;
  color: #6c757d;
  padding: 0;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: background-color 0.2s;
}

.popup-close:hover {
  background-color: #f8f9fa;
  color: #495057;
}

.booking-info {
  margin-bottom: 24px;
}

.booking-info p {
  margin: 12px 0;
  line-height: 1.5;
  font-size: 16px;
}

.booking-info strong {
  color: #2c3e50;
  font-weight: 600;
  display: inline-block;
  min-width: 120px;
}

.status {
  padding: 6px 12px;
  border-radius: 20px;
  font-weight: 600;
  font-size: 14px;
  margin-left: 8px;
}

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

.status-awaiting_confirmation {
  background-color: #fff3cd;
  color: #856404;
}

.status-pending {
  background-color: #f8d7da;
  color: #721c24;
}

.status-deleted {
  background-color: #e9ecef;
  color: #495057;
}

.popup-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 20px;
}

.btn-confirm,
.btn-delete,
.btn-close {
  padding: 16px;
  border: none;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: center;
}

.btn-confirm {
  background: linear-gradient(135deg, #28a745, #20c997);
  color: white;
}

.btn-confirm:active {
  transform: scale(0.98);
  background: linear-gradient(135deg, #218838, #1aa179);
}

.btn-delete {
  background: linear-gradient(135deg, #dc3545, #e83e8c);
  color: white;
}

.btn-delete:active {
  transform: scale(0.98);
  background: linear-gradient(135deg, #c82333, #d91a6b);
}

.btn-close {
  background: #6c757d;
  color: white;
}

.btn-close:active {
  transform: scale(0.98);
  background: #5a6268;
}

/* Адаптация для очень маленьких экранов */
@media (max-width: 360px) {
  .booking-popup {
    padding: 20px;
    margin: 10px;
  }

  .popup-header h3 {
    font-size: 18px;
  }

  .booking-info p {
    font-size: 14px;
  }

  .btn-confirm,
  .btn-delete,
  .btn-close {
    padding: 14px;
    font-size: 14px;
  }
}

/* Прокрутка для длинного контента */
.booking-popup::-webkit-scrollbar {
  width: 6px;
}

.booking-popup::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 3px;
}

.booking-popup::-webkit-scrollbar-thumb {
  background: #c1c1c1;
  border-radius: 3px;
}

.booking-popup::-webkit-scrollbar-thumb:hover {
  background: #a8a8a8;
}


.calendar {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.week {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 8px;
}

.day {
  padding: 10px;
  background: #f9f9f9;
  border-radius: 8px;
  text-align: center;
  font-size: 14px;
  transition: all 0.2s ease;
  cursor: pointer;
}

.day:hover {
  background: #e8f4ff;
}

.day-name {
  font-weight: 600;
  color: #444;
}

.day-date {
  font-size: 12px;
  color: #777;
}

.calendar-controls {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 12px;
  gap: 12px;
}

.calendar-header__title {
  font-weight: 600;
  font-size: 16px;
  color: #495057;
  text-align: center;
}

.calendar-arrow {
  background: none;
  border: none;
  font-size: 18px;
  cursor: pointer;
  color: #495057;
  padding: 4px 8px;
}

.calendar-arrow:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.calendar-controls {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px; /* расстояние между стрелками и текстом */
  padding: 8px 16px;
  border: 1px solid rgba(0,0,0,0.15); /* универсальная обводка для светлой темы */
  border-radius: 12px;
  background-color: var(--tg-theme-bg, #fff); /* использует переменную темы TG, fallback #fff */
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  max-width: fit-content;
  margin: 12px auto;
}

.calendar-header__title {
  font-weight: 600;
  font-size: 16px;
  color: var(--tg-theme-text, #495057);
  text-align: center;
  flex: none; /* чтобы текст не растягивался */
}

.calendar-arrow {
  background: linear-gradient(135deg, #ffb347, #ffcc33);
  border: none;
  font-size: 18px;
  cursor: pointer;
  color: #fff;
  padding: 6px 14px;
  border-radius: 8px;
  transition: all 0.2s ease;
  user-select: none;
}

.calendar-arrow:hover:not(:disabled) {
  transform: scale(1.1);
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}

.calendar-arrow:active:not(:disabled) {
  transform: scale(0.95);
}

.calendar-arrow:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  background: #ccc;
}

