.reservation-container {
  max-width: 1600px;
  margin: 0 auto;
  padding: 20px 15px;
}

.flow-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-bottom: 16px;
}

.flow-card {
  background: white;
  border-radius: 12px;
  padding: 14px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
  position: relative;
  display: none;
  opacity: 0;
}

/* First card is always visible */
.flow-card:first-child {
  display: block;
  opacity: 1;
}

/* Active cards are visible with animation */
.flow-card.active {
  display: block;
  animation: fadeInUp 0.6s ease-out forwards;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

/* Hiding animation */
.flow-card.hiding {
  animation: fadeOutDown 0.4s ease-out forwards;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes fadeOutDown {
  from {
    opacity: 1;
  }
  to {
    opacity: 0;
  }
}

.flow-card.completed {
  background: white;
}

.flow-card.active:hover {
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.16);
}

/* Card entrance animation */
@keyframes cardSlideIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.flow-card.animate-in {
  animation: cardSlideIn 0.5s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

/* Progress indicator */
.card-progress {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
  border-radius: 0 0 16px 16px;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s ease-out;
}

.flow-card.completed .card-progress {
  transform: scaleX(1);
}

/* Completion checkmark */
.card-complete-check {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 24px;
  height: 24px;
  background: #e8e8e8;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.card-complete-check svg {
  width: 14px;
  height: 14px;
  color: white;
  opacity: 0;
  transform: scale(0) rotate(-45deg);
  transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.flow-card.completed .card-complete-check {
  transform: scale(1.1);
}

.flow-card.completed .card-complete-check svg {
  opacity: 1;
  transform: scale(1) rotate(0deg);
  transition-delay: 0.1s;
}

.flow-card.completed .card-complete-check:after {
  content: '';
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  opacity: 0.3;
  transform: scale(1);
  animation: checkPulse 0.6s ease-out;
}

@keyframes checkPulse {
  0% {
    transform: scale(1);
    opacity: 0.3;
  }
  100% {
    transform: scale(1.8);
    opacity: 0;
  }
}

/* Next button for each card */
.card-next-btn {
  margin-top: 12px;
  padding: 8px 16px;
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
  display: none;
}

.card-next-btn.show {
  display: inline-block;
}

.card-next-btn:hover {
  transform: translateY(-1px);
}

.flow-card::after {
  content: '';
  position: absolute;
  right: -10px;
  top: 50%;
  transform: translateY(-50%);
  width: 0;
  height: 0;
  border-style: solid;
  border-width: 10px 0 10px 10px;
}

.flow-card:last-child::after {
  display: none;
}

.card-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  color: white;
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 8px;
}

.form-input {
  width: 100%;
  padding: 6px 12px;
  font-size: 13px;
  border: 2px solid #e1e4e8;
  border-radius: 10px;
  outline: none;
  transition: all 0.2s;
  background: white;
}

.form-input:focus {
  box-shadow: 0 0 0 4px rgba(27, 62, 137, 0.1);
}

.form-select {
  width: 100%;
  padding: 6px 12px;
  font-size: 13px;
  border: 2px solid #e1e4e8;
  border-radius: 10px;
  outline: none;
  transition: all 0.2s;
  background: white;
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 10px center;
  background-size: 18px;
  padding-right: 35px;
}

.form-select:focus {
  box-shadow: 0 0 0 4px rgba(27, 62, 137, 0.1);
}

.radio-card {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 8px;
  border: 1px solid #e1e4e8;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
  background: white;
  font-size: 12px;
  pointer-events: auto;
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
}

.radio-card:hover {
  background: #f8f9fa;
}

.radio-card.selected {
  box-shadow: 0 0 0 3px rgba(27, 62, 137, 0.08);
}

.radio-card svg {
  width: 16px;
  height: 16px;
  pointer-events: none;
}

.radio-card span {
  pointer-events: none;
}

.checkbox-card {
  display: flex;
  align-items: center;
  padding: 4px 12px;
  border: 2px solid #e1e4e8;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s;
  background: white;
}

.checkbox-card:hover {
  background: #f8f9fa;
}

.checkbox-card input[type="checkbox"] {
  width: 14px;
  height: 14px;
  margin-right: 10px;
}

/* Price display - removed gradient text effect for better compatibility */
.price-display {
  font-size: 28px;
  font-weight: 800;
  color: #1b3e89;
  text-align: center;
  margin: 12px 0;
}

@media (max-width: 1280px) {
  .flow-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .flow-grid {
    grid-template-columns: 1fr;
  }

  .reservation-container {
    padding: 15px 10px;
  }
}

/* ==============================================
   THEME CSS VARIABLES
   ============================================== */

:root {
  --color-primary-main: #1b3e89;
  --color-primary-dark: #14325c;
  --color-primary-light: #4b6db8;
  --color-secondary-main: #ff813e;
  --color-success: #6db142;
  --color-neutral-light: #f7f7f8;
  --color-neutral-white: #ffffff;
  --color-border: #e1e4e8;
  --color-text-dark: #393939;
  --color-text-muted: #586069;
}

/* ==============================================
   THEME-SPECIFIC CSS
   ============================================== */

/* Progress indicator (updated with CSS variable) */
.card-progress {
  background: var(--color-primary-main);
}

/* Completion check */
.flow-card.completed .card-complete-check {
  background: var(--color-success);
}

.flow-card.completed .card-complete-check:after {
  background: var(--color-success);
}

/* Next button */
.card-next-btn {
  background: var(--color-primary-main);
}

.card-next-btn:hover {
  background: var(--color-primary-dark);
}

/* Flow card arrow */
.flow-card::after {
  border-color: transparent transparent transparent var(--color-primary-light);
}

/* Card number */
.card-number {
  background: var(--color-primary-main);
}

/* Form inputs focus state */
.form-input:focus {
  border-color: var(--color-primary-main);
  box-shadow: 0 0 0 4px rgba(27, 62, 137, 0.1);
}

.form-select:focus {
  border-color: var(--color-primary-main);
  box-shadow: 0 0 0 4px rgba(27, 62, 137, 0.1);
}

/* Radio cards */
.radio-card:hover {
  border-color: var(--color-primary-light);
  background: #f8f9fa;
}

.radio-card.selected {
  border-color: var(--color-primary-main);
  background: var(--color-primary-main) !important;
  box-shadow: 0 0 0 3px rgba(27, 62, 137, 0.08);
}

.radio-card.selected svg {
  color: white !important;
}

.radio-card.selected span {
  color: white !important;
  font-weight: 600 !important;
}

.radio-card svg {
  color: var(--color-primary-main);
  stroke-width: 2;
}

/* Checkbox cards */
.checkbox-card:hover {
  border-color: var(--color-primary-light);
  background: #f8f9fa;
}

.checkbox-card input[type="checkbox"] {
  accent-color: var(--color-primary-main);
}

.checkbox-card.selected {
  border-color: var(--color-primary-main);
  background: linear-gradient(135deg, rgba(75, 109, 184, 0.1), rgba(75, 109, 184, 0.2));
}

/* ==============================================
   MOBILE DATE INPUT BORDER FIX
   ============================================== */

/* Normalize date/time input appearance across browsers */
input[type="date"].form-input,
input[type="time"].form-input {
  border: 2px solid #e1e4e8;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  background-color: white;
}

/* Style the calendar icon */
input[type="date"].form-input::-webkit-calendar-picker-indicator,
input[type="time"].form-input::-webkit-calendar-picker-indicator {
  filter: invert(47%) sepia(8%) saturate(318%) hue-rotate(181deg) brightness(93%) contrast(89%);
  cursor: pointer;
}

/* Mobile-specific fixes */
@media (max-width: 768px) {
  /* Force consistent border width on mobile */
  input[type="date"].form-input,
  input[type="time"].form-input {
    border: 2px solid var(--color-border) !important;
    border-radius: 10px !important;
    padding: 6px 12px !important;
    font-size: 14px !important;
    line-height: 1.4 !important;
    min-height: 40px; /* Touch-friendly height */
  }

  /* Mobile focus state */
  input[type="date"].form-input:focus,
  input[type="time"].form-input:focus {
    border-color: var(--color-primary-main) !important;
    box-shadow: 0 0 0 4px rgba(27, 62, 137, 0.1) !important;
  }

  /* Ensure icon is visible on mobile */
  input[type="date"].form-input::-webkit-calendar-picker-indicator,
  input[type="time"].form-input::-webkit-calendar-picker-indicator {
    width: 18px;
    height: 18px;
    margin-left: 6px;
  }
}

/* ==============================================
   WARNING MESSAGE ANIMATIONS
   ============================================== */

@keyframes fadeOut {
  from {
    opacity: 1;
    transform: translateY(0);
  }
  to {
    opacity: 0;
    transform: translateY(-5px);
  }
}

/* ==============================================
   CUSTOM DROPDOWN STYLES (Safari-style)
   Cross-browser compatible dropdown that shows options BELOW the select button
   ============================================== */

.custom-dropdown-container {
  position: relative;
  width: 100%;
}

/* Dropdown button (replaces native select) */
.custom-dropdown-button {
  width: 100%;
  padding: 6px 35px 6px 12px;
  font-size: 13px;
  border: 2px solid var(--color-border);
  border-radius: 10px;
  background: white;
  color: #24292e;
  text-align: left;
  cursor: pointer;
  transition: all 0.2s;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 38px;
}

.custom-dropdown-button:hover {
  border-color: var(--color-primary-light);
  background: #f8f9fa;
}

.custom-dropdown-button:focus {
  outline: none;
  border-color: var(--color-primary-main);
  box-shadow: 0 0 0 4px rgba(27, 62, 137, 0.1);
}

.custom-dropdown-button.open {
  border-color: var(--color-primary-main);
  box-shadow: 0 0 0 4px rgba(27, 62, 137, 0.1);
}

/* Button text */
.custom-dropdown-button-text {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Dropdown arrow icon */
.custom-dropdown-arrow {
  width: 16px;
  height: 16px;
  color: #586069;
  transition: transform 0.2s;
  flex-shrink: 0;
  margin-left: 6px;
}

.custom-dropdown-button.open .custom-dropdown-arrow {
  transform: rotate(180deg);
}

/* Dropdown menu (options list) - ALWAYS APPEARS BELOW */
.custom-dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  margin-top: 4px;
  background: white;
  border: 2px solid var(--color-border);
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
  z-index: 1000;
  max-height: 200px;
  overflow-y: auto;
  opacity: 0;
  transform: translateY(-10px);
  transition: opacity 0.2s, transform 0.2s;
}

.custom-dropdown-menu.open {
  opacity: 1;
  transform: translateY(0);
}

/* Dropdown menu item */
.custom-dropdown-item {
  padding: 10px 12px;
  cursor: pointer;
  transition: background 0.15s;
  color: #24292e;
  font-size: 13px;
}

.custom-dropdown-item:hover {
  background: #f8f9fa;
}

.custom-dropdown-item.selected {
  background: var(--color-primary-main);
  color: white;
  font-weight: 600;
}

.custom-dropdown-item:first-child {
  border-radius: 10px 10px 0 0;
}

.custom-dropdown-item:last-child {
  border-radius: 0 0 10px 10px;
}

/* Scrollbar styling for dropdown menu */
.custom-dropdown-menu::-webkit-scrollbar {
  width: 8px;
}

.custom-dropdown-menu::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 0 12px 12px 0;
}

.custom-dropdown-menu::-webkit-scrollbar-thumb {
  background: #c1c1c1;
  border-radius: 4px;
}

.custom-dropdown-menu::-webkit-scrollbar-thumb:hover {
  background: #a1a1a1;
}

/* Mobile optimizations */
@media (max-width: 768px) {
  .custom-dropdown-button {
    min-height: 42px;
    font-size: 14px;
  }

  .custom-dropdown-item {
    padding: 12px 12px;
    font-size: 14px;
  }

  .custom-dropdown-menu {
    max-height: 240px;
  }
}