/* ============================================================
   Fröccs Apartman – Booking Page Styles
   File: css/booking.css
============================================================ */

/* Required field asterisk */
.required-star {
  color: #dc2626;
  margin-left: 2px;
  font-weight: 700;
}

.required-note {
  font-size: .82rem;
  color: var(--mid);
  margin-bottom: 1.4rem;
  margin-top: -.4rem;
}

.required-note .required-star {
  margin-left: 0;
  margin-right: 2px;
}

/* Password match feedback */
.password-match-msg {
  font-size: .82rem;
  font-weight: 600;
  margin-top: .3rem;
  display: block;
  min-height: 1.1em;
}

/* ===== PAGE BASE ===== */
.booking-page {
  background: var(--sand);
  min-height: 100vh;
}

/* ===== MAIN WRAPPER ===== */
.booking-main {
  max-width: 1000px;
  margin: 0 auto;
  padding: 7rem 1.5rem 4rem;
}

/* ===== PROGRESS BAR ===== */
.booking-progress {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  margin-bottom: 3rem;
}

.progress-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .4rem;
  color: #aaa;
  font-size: .8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .5px;
  transition: color .3s;
}

.progress-step.active { color: var(--teal); }
.progress-step.done   { color: var(--teal); }

.prog-dot {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #ddd;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: .9rem;
  transition: background .3s;
}

.progress-step.active .prog-dot { background: var(--teal); }
.progress-step.done   .prog-dot { background: var(--teal-dk); }

.progress-line {
  flex: 1;
  max-width: 120px;
  height: 2px;
  background: #ddd;
  margin: 0 .5rem;
  margin-bottom: 1.2rem;
  transition: background .3s;
}

/* ===== STEPS ===== */
.booking-step {
  display: none;
  animation: stepIn .35s ease;
}

.booking-step.active { display: block; }

@keyframes stepIn {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ===== STEP HEADER ===== */
.step-header {
  text-align: center;
  margin-bottom: 2.5rem;
}

.step-header h1 {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 800;
  color: var(--dark);
  margin-bottom: .5rem;
}

.step-header p {
  color: var(--mid);
  font-size: 1rem;
}

/* ===== PATH CARDS (Step 1) ===== */
.path-cards {
  display: flex;
  align-items: stretch;
  gap: 0;
  background: var(--light);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.path-card {
  flex: 1;
  padding: 2.5rem 2rem;
  display: flex;
  flex-direction: column;
  gap: .8rem;
}

.path-card--ghost {
  background: var(--sand);
}

.path-icon {
  font-size: 2.5rem;
}

.path-card h2 {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--dark);
}

.path-card p {
  color: var(--mid);
  font-size: .95rem;
  line-height: 1.6;
}

.path-perks {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: .4rem;
  margin: .4rem 0;
}

.path-perks li {
  color: var(--teal-dk);
  font-size: .9rem;
  font-weight: 600;
}

.path-btn {
  margin-top: auto;
  align-self: flex-start;
}

.path-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 1rem;
  color: #ccc;
  font-size: .85rem;
  font-weight: 600;
  position: relative;
}

.path-divider::before,
.path-divider::after {
  content: '';
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  width: 1px;
  height: calc(50% - 18px);
  background: #ddd;
}

.path-divider::before { top: 0; }
.path-divider::after  { bottom: 0; }

/* ===== DETAILS FORM (Step 2) ===== */
.details-form {
  background: var(--light);
  border-radius: var(--radius);
  padding: 2.5rem;
  box-shadow: var(--shadow);
  max-width: 620px;
  margin: 0 auto;
}

/* Reuse existing form-group, form-row from style.css */

/* ===== BUTTONS ===== */
.btn-outline-dark {
  background: transparent;
  color: var(--dark);
  border: 2px solid var(--dark);
}

.btn-outline-dark:hover {
  background: var(--dark);
  color: var(--light);
}

.btn-ghost {
  background: transparent;
  color: var(--mid);
  border: 2px solid #ddd;
}

.btn-ghost:hover {
  border-color: var(--mid);
  color: var(--dark);
}

.form-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  margin-top: 1.5rem;
  flex-wrap: wrap;
}

/* ===== CALENDAR LAYOUT (Step 3) ===== */
.calendar-booking-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 2rem;
  align-items: start;
}

/* ===== CALENDAR ===== */
.calendar-wrap {
  background: var(--light);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--shadow);
}

.calendar-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.2rem;
}

.cal-months-header {
  display: flex;
  gap: 2rem;
  font-weight: 700;
  font-size: 1rem;
  color: var(--dark);
  flex: 1;
  justify-content: center;
}

.cal-nav-btn {
  background: var(--sand);
  border: none;
  border-radius: 50%;
  width: 36px;
  height: 36px;
  font-size: 1.4rem;
  cursor: pointer;
  color: var(--dark);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background var(--trans);
  flex-shrink: 0;
}

.cal-nav-btn:hover { background: var(--teal); color: #fff; }

.cal-grid-wrap {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

.cal-day-names {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  margin-bottom: .4rem;
}

.cal-day-name {
  text-align: center;
  font-size: .75rem;
  font-weight: 700;
  color: var(--mid);
  padding: .3rem 0;
}

.cal-days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
}

.cal-day {
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .85rem;
  border-radius: 50%;
  cursor: default;
  transition: background .15s, color .15s;
  font-weight: 500;
  color: var(--dark);
}

.cal-day--empty { visibility: hidden; }

.cal-day--past {
  color: #ccc;
  cursor: not-allowed;
}

.cal-day--selectable {
  cursor: pointer;
}

.cal-day--selectable:hover {
  background: rgba(74,124,89,.15);
  color: var(--teal-dk);
}

.cal-day--checkin {
  background: var(--teal) !important;
  color: #fff !important;
  border-radius: 50% 0 0 50%;
}

.cal-day--checkout {
  background: var(--teal) !important;
  color: #fff !important;
  border-radius: 0 50% 50% 0;
}

.cal-day--checkin.cal-day--checkout {
  border-radius: 50%;
}

.cal-day--range {
  background: rgba(74,124,89,.12);
  color: var(--teal-dk);
  border-radius: 0;
}

/* Legend */
.cal-legend {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  margin-top: 1rem;
  font-size: .8rem;
  color: var(--mid);
  justify-content: center;
}

.leg-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  display: inline-block;
  margin-right: .3rem;
}

.leg-checkin  { background: var(--teal); }
.leg-checkout { background: var(--teal); }
.leg-range    { background: rgba(74,124,89,.3); border-radius: 3px; }

/* ===== BOOKING SUMMARY BOX ===== */
.booking-summary-box {
  background: var(--light);
  border-radius: var(--radius);
  padding: 1.8rem;
  box-shadow: var(--shadow);
  position: sticky;
  top: 90px;
}

.booking-summary-box h3 {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 1.2rem;
}

.summary-dates {
  display: flex;
  align-items: center;
  gap: .5rem;
  margin-bottom: 1rem;
}

.summary-date-box {
  flex: 1;
  background: var(--sand);
  border-radius: 8px;
  padding: .7rem .8rem;
  text-align: center;
}

.sd-label {
  display: block;
  font-size: .72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .5px;
  color: var(--mid);
  margin-bottom: .2rem;
}

.sd-val {
  font-weight: 700;
  font-size: .9rem;
  color: var(--dark);
}

.sd-arrow {
  color: var(--mid);
  font-size: 1.1rem;
}

.summary-nights {
  text-align: center;
  font-size: .9rem;
  color: var(--mid);
  margin-bottom: .5rem;
}

.summary-nights strong {
  font-size: 1.4rem;
  color: var(--teal);
}

/* ===== SUCCESS ===== */
.success-box {
  text-align: center;
  background: var(--light);
  border-radius: var(--radius);
  padding: 3.5rem 2rem;
  box-shadow: var(--shadow);
  max-width: 560px;
  margin: 0 auto;
}

.success-icon { font-size: 3.5rem; margin-bottom: 1rem; }

.success-box h1 {
  font-size: 2rem;
  font-weight: 800;
  color: var(--dark);
  margin-bottom: 1rem;
}

.success-box p {
  color: var(--mid);
  font-size: 1.05rem;
  margin-bottom: 1.5rem;
}

.success-details {
  background: var(--sand);
  border-radius: var(--radius);
  padding: 1.2rem 1.5rem;
  text-align: left;
}

.success-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: .5rem 0;
  border-bottom: 1px solid #e2e8f0;
  font-size: .95rem;
  color: var(--mid);
}

.success-row:last-child { border-bottom: none; }
.success-row strong { color: var(--dark); }

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  /* Az oldal ne tudjon jobbra túlnyúlni */
  .booking-page { overflow-x: hidden; }
  .booking-main { padding: 6rem 1rem 3rem; max-width: 100%; }

  .path-cards { flex-direction: column; }
  .path-divider { padding: 1rem 0; flex-direction: row; }
  .path-divider::before, .path-divider::after { display: none; }

  /* Naptár layout: 1 oszlop */
  .calendar-booking-layout {
    grid-template-columns: 1fr;
    gap: 1.2rem;
  }

  /* Naptár wrap: ne nyúljon túl, kisebb padding */
  .calendar-wrap {
    padding: .8rem .6rem;
    overflow: hidden;          /* vasárnap ne lógjon ki */
    width: 100%;
  }

  /* Mobilon csak 1 hónap egyszerre — a 2. rejtve */
  .cal-grid-wrap {
    grid-template-columns: 1fr;
    gap: 0;
  }
  #calMonth2 { display: none; }

  /* Fejlécben csak 1 hónap neve látszik */
  .cal-months-header {
    font-size: .95rem;
    gap: 0;
  }
  .cal-months-header span:last-child { display: none; }

  /* Napok kompaktabbak mobilon */
  .cal-day      { font-size: .78rem; }
  .cal-day-name { font-size: .65rem; padding: .2rem 0; letter-spacing: 0; }

  /* Summary panel: kisebb padding, ne lógjon ki */
  .booking-summary-box {
    position: static;
    padding: 1.1rem;
    width: 100%;
  }

  /* ÉRKEZÉS / TÁVOZÁS dobozkák — kisebb font, ne lógjanak ki */
  .summary-dates { gap: .3rem; }
  .summary-date-box { padding: .5rem .4rem; }
  .sd-label { font-size: .65rem; letter-spacing: .3px; }
  .sd-val   { font-size: .8rem; }

  /* Vissza + Tovább gombok: egymás alá kerülnek */
  .form-actions {
    flex-direction: column;
    gap: .7rem;
  }
  .form-actions .btn {
    width: 100%;
    justify-content: center;
    text-align: center;
  }
}
