/* Room Selection Sliding Panel Styles */

/* Room card select button */
.room-card-select-btn {
  order: 999;
  margin-top: auto;
  padding: 10px 16px;
  background: var(--accent);
  color: white;
  border: none;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  width: 100%;
  text-align: center;
}

.room-card-select-btn:hover {
  background: #4338ca;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(79, 70, 229, 0.3);
}

.room-card-select-btn:active {
  transform: translateY(0);
  box-shadow: 0 2px 6px rgba(79, 70, 229, 0.2);
}

/* Room selection sliding panel */
.room-selection-panel {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 9999;
  pointer-events: none;
}

.room-selection-panel.open {
  pointer-events: auto;
}

.room-panel-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0);
  transition: background 0.3s ease;
}

.room-selection-panel.open .room-panel-overlay {
  background: rgba(0, 0, 0, 0.6);
}

.room-panel-content {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  max-width: 500px;
  background: var(--panel);
  border-left: 1px solid var(--border);
  box-shadow: -4px 0 24px rgba(0, 0, 0, 0.3);
  transform: translateX(100%);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.room-selection-panel.open .room-panel-content {
  transform: translateX(0);
}

/* Panel header */
.room-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid var(--border);
  background: var(--bg);
}

.room-panel-title {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
  color: var(--ink);
}

.room-panel-close {
  background: transparent;
  border: none;
  color: var(--muted);
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  padding: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  transition: all 0.2s ease;
}

.room-panel-close:hover {
  background: rgba(255, 255, 255, 0.05);
  color: var(--ink);
}

/* Panel body */
.room-panel-body {
  flex: 1;
  overflow-y: auto;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

/* Panel sections */
.room-panel-section {
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border);
}

.room-panel-section:last-child {
  border-bottom: none;
  margin-top: auto;
}

.room-panel-section h4 {
  margin: 0 0 12px 0;
  font-size: 14px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--muted);
}

.room-panel-section p {
  margin: 0;
  color: var(--ink);
  line-height: 1.6;
}

/* Confirm button */
.room-panel-confirm-btn {
  width: 100%;
  padding: 14px 20px;
  background: var(--accent);
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.room-panel-confirm-btn:hover:not(:disabled) {
  background: #4338ca;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(79, 70, 229, 0.4);
}

.room-panel-confirm-btn:active:not(:disabled) {
  transform: translateY(0);
  box-shadow: 0 3px 10px rgba(79, 70, 229, 0.3);
}

.room-panel-confirm-btn:disabled,
.room-panel-confirm-btn.disabled {
  background: rgba(79, 70, 229, 0.3);
  color: rgba(255, 255, 255, 0.5);
  cursor: not-allowed;
  opacity: 0.6;
}

.room-panel-confirm-btn:disabled:hover,
.room-panel-confirm-btn.disabled:hover {
  transform: none;
  box-shadow: none;
}

/* Room panel image */
.room-panel-image {
  width: 100%;
  height: auto;
  border-radius: 8px;
  margin-bottom: 12px;
}

/* Room panel summary */
.room-panel-summary {
  font-size: 14px;
  line-height: 1.6;
  color: var(--ink);
  margin-bottom: 12px;
}

/* Room panel info */
.room-panel-info {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 12px;
}

.room-panel-info-item {
  font-size: 13px;
  color: var(--muted);
}

.room-panel-info-item strong {
  color: var(--ink);
  font-weight: 600;
}

/* Rate plans list */
.room-panel-rates-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 12px;
}

.room-panel-rate-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.room-panel-rate-item:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--accent);
  transform: translateX(4px);
}

.room-panel-rate-item.selected {
  background: rgba(79, 70, 229, 0.1);
  border-color: var(--accent);
}

.room-panel-rate-name {
  font-size: 14px;
  font-weight: 500;
  color: var(--ink);
}

.room-panel-rate-price {
  font-size: 14px;
  font-weight: 600;
  color: var(--accent);
}

.room-panel-price-summary {
  font-size: 13px;
  color: var(--muted);
  text-align: center;
  margin-top: 8px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}

.room-panel-placeholder {
  font-size: 13px;
  color: var(--muted);
  font-style: italic;
}

/* Ensure all availability slider cards have equal height */
.entry.assistant .bubble .availability-slider,
.entry.assistant.slider-entry .availability-slider {
  display: flex;
  align-items: stretch;
}

.entry.assistant .bubble .availability-slider .room-card,
.entry.assistant.slider-entry .availability-slider .room-card {
  display: flex !important;
  flex-direction: column !important;
  height: auto;
  min-height: 340px;
}

/* Reduce summary height to make cards shorter */
.availability-slider .room-card-summary {
  -webkit-line-clamp: 2 !important;
  max-height: 3em;
  line-height: 1.4;
}

/* Select button always at bottom */
.availability-slider .room-card-select-btn {
  margin-top: auto !important;
}

/* Mobile responsive */
@media (max-width: 768px) {
  .room-panel-content {
    max-width: 100%;
  }
  
  .room-panel-header {
    padding: 16px 20px;
  }
  
  .room-panel-body {
    padding: 20px;
  }
  
  .room-panel-rate-item {
    padding: 10px 14px;
  }
  
  /* Smaller min-height for mobile cards */
  .entry.assistant .bubble .availability-slider .room-card,
  .entry.assistant.slider-entry .availability-slider .room-card {
    min-height: 380px;
  }
}

