/**
 * Styles pour le bloc Horaires Petit Train (Slider Hebdomadaire)
 */

.horaires-petit-train {
  --pt-primary: var(--color-primary, #1e3a5f);
  --pt-secondary: var(--color-secondary, #b91c1c);
  --pt-white: var(--color-white, #ffffff);
  --pt-gray-50: var(--color-gray-50, #f9fafb);
  --pt-gray-100: var(--color-gray-100, #f3f4f6);
  --pt-gray-200: var(--color-gray-200, #e5e7eb);
  --pt-gray-300: var(--color-gray-300, #d1d5db);
  --pt-gray-400: var(--color-gray-400, #9ca3af);
  --pt-gray-600: var(--color-gray-600, #4b5563);
  position: relative;
  box-sizing: border-box;
}

.horaires-petit-train *,
.horaires-petit-train *::before,
.horaires-petit-train *::after {
  box-sizing: border-box;
}

.horaires-petit-train .hpt-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.horaires-petit-train .hpt-range-label {
  font-size: 1rem;
  font-weight: 700;
  color: var(--pt-primary);
}

@media (min-width: 768px) {
  .horaires-petit-train .hpt-range-label {
    font-size: 1.125rem;
  }
}

.horaires-petit-train .hpt-controls {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.horaires-petit-train .hpt-nav-btn {
  display: inline-flex;
  height: 2.5rem;
  width: 2.5rem;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  border-radius: 9999px;
  border: 1px solid rgba(30, 58, 95, 0.2);
  background-color: #ffffff;
  color: var(--pt-primary);
  transition: all 0.2s ease;
  padding: 0;
}

.horaires-petit-train .hpt-nav-btn:hover:not(:disabled) {
  border-color: var(--pt-primary);
  background-color: var(--pt-primary);
  color: #ffffff;
}

.horaires-petit-train .hpt-nav-btn:disabled {
  cursor: not-allowed;
  opacity: 0.3;
}

.horaires-petit-train .hpt-viewport {
  overflow: hidden;
  width: 100%;
}

.horaires-petit-train .hpt-viewport.is-draggable {
  cursor: grab;
  user-select: none;
  -webkit-user-select: none;
}

.horaires-petit-train .hpt-viewport.is-dragging {
  cursor: grabbing;
}

.horaires-petit-train .hpt-track {
  display: flex;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  width: 100%;
}

.horaires-petit-train .hpt-slide {
  width: 100%;
  flex-shrink: 0;
}

.horaires-petit-train .hpt-week-grid {
  display: flex;
  gap: 0.5rem;
  overflow-x: auto;
  padding-bottom: 0.5rem;
  -webkit-overflow-scrolling: touch;
}

@media (min-width: 768px) {
  .horaires-petit-train .hpt-week-grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    padding-bottom: 0;
  }
}

.horaires-petit-train .hpt-day-card {
  display: flex;
  min-width: 92px;
  flex: 1;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid rgba(30, 58, 95, 0.15);
  background-color: #ffffff;
  border-radius: 4px;
}

@media (min-width: 768px) {
  .horaires-petit-train .hpt-day-card {
    min-width: 0;
  }
}

.horaires-petit-train .hpt-day-card.is-today {
  border-color: var(--pt-secondary);
}

.horaires-petit-train .hpt-day-card.is-today .hpt-date {
  background-color: var(--pt-secondary);
}

.horaires-petit-train .hpt-day-card.is-disabled {
  pointer-events: none;
  border-color: var(--pt-gray-200);
  background-color: var(--pt-gray-50);
  opacity: 0.55;
  user-select: none;
}

.horaires-petit-train .hpt-day-card.is-disabled .hpt-date {
  background-color: var(--pt-gray-300);
  color: var(--pt-gray-600);
}

.horaires-petit-train .hpt-day-card.is-disabled .hpt-horaire {
  color: var(--pt-gray-400);
}

.horaires-petit-train .hpt-date {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  background-color: var(--pt-primary);
  padding: 0.75rem 0.5rem;
  color: #ffffff;
}

.horaires-petit-train .hpt-day-name {
  font-size: 0.75rem;
  line-height: 1;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  opacity: 0.85;
}

.horaires-petit-train .hpt-day-num {
  font-size: 1.5rem;
  line-height: 1;
  font-weight: 700;
}

@media (min-width: 768px) {
  .horaires-petit-train .hpt-day-num {
    font-size: 1.875rem;
  }
}

.horaires-petit-train .hpt-month {
  font-size: 0.875rem;
  line-height: 1;
  text-transform: lowercase;
  opacity: 0.9;
}

.horaires-petit-train .hpt-horaire {
  display: flex;
  flex: 1;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 0.5rem;
  text-align: center;
  font-size: 0.9375rem;
  font-weight: 500;
  line-height: 1.25;
  color: var(--pt-primary);
}

.horaires-petit-train .hpt-closed {
  font-size: 0.75rem;
  line-height: 1.1;
  font-weight: 400;
  color: var(--pt-gray-400);
  font-style: italic;
}

.horaires-petit-train .hpt-dots {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 1rem;
}

.horaires-petit-train .hpt-dot {
  width: 0.625rem;
  height: 0.625rem;
  border-radius: 9999px;
  border: none;
  padding: 0;
  cursor: pointer;
  background-color: rgba(30, 58, 95, 0.25);
  transition: all 0.2s ease;
}

.horaires-petit-train .hpt-dot:hover {
  background-color: rgba(30, 58, 95, 0.5);
}

.horaires-petit-train .hpt-dot.bg-primary {
  background-color: var(--pt-primary) !important;
  width: 1.5rem !important;
}
