/* SuperHote V2 - Search v4.0 — Minimal, theme-proof */

/* ===== Reset: override WordPress themes ===== */
.shp-search-wrapper,
.shp-search-wrapper *,
.shp-search-wrapper *::before,
.shp-search-wrapper *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

.shp-search-wrapper button {
  background: none;
  border: none;
  border-radius: 0;
  color: inherit;
  font: inherit;
  cursor: pointer;
  outline: none;
  box-shadow: none;
  text-shadow: none;
  text-decoration: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
}

.shp-search-wrapper button:hover,
.shp-search-wrapper button:focus,
.shp-search-wrapper button:active {
  background: none;
  border: none;
  box-shadow: none;
  outline: none;
  text-decoration: none;
}

/* ===== Wrapper ===== */
.shp-search-wrapper {
  --shp-accent: #F5A623;
  --shp-text: #222;
  --shp-muted: #aaa;
  --shp-border: #e5e5e5;
  max-width: 100%;
  margin: 0 auto;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

/* ===== Search Form ===== */
.shp-search-form {
  max-width: 960px;
  margin: -40px auto 32px;
  position: relative;
  z-index: 10;
  background: #fff;
  border: 1px solid var(--shp-border);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

.shp-search-form-fields {
  display: flex;
  align-items: stretch;
  min-height: 72px;
}

/* ===== Fields ===== */
.shp-search-field {
  display: flex;
  flex-direction: column;
  justify-content: center;
  flex: 1 1 0;
  padding: 16px 24px;
  border-right: 1px solid var(--shp-border);
  min-width: 0;
}

.shp-search-field:last-of-type {
  border-right: none;
}

.shp-search-field label {
  display: block;
  font-size: 11px;
  font-weight: 700;
  color: var(--shp-text);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin: 0 0 5px 0;
  padding: 0;
  line-height: 1;
}

/* ===== Date Input ===== */
.shp-date-input {
  display: flex;
  align-items: center;
  cursor: pointer;
  position: relative;
  padding: 0;
}

.shp-date-display {
  font-size: 14px;
  font-weight: 400;
  color: var(--shp-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
  user-select: none;
  line-height: 1.3;
}

.shp-date-display.shp-date-filled {
  color: var(--shp-text);
  font-weight: 600;
  text-transform: none;
  letter-spacing: 0;
}

/* ===== Datepicker Dropdown ===== */
.shp-datepicker {
  position: absolute;
  top: calc(100% + 16px);
  left: 0;
  z-index: 10000;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.12);
  border: 1px solid #e8e8e8;
  padding: 24px 28px 20px;
  user-select: none;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.15s ease, transform 0.15s ease;
  pointer-events: none;
}

.shp-datepicker.shp-datepicker-open {
  opacity: 1;
  transform: translateY(0);
  pointer-events: all;
}

.shp-datepicker-months {
  display: flex;
  gap: 36px;
}

.shp-datepicker-month {
  flex: 0 0 auto;
  min-width: 224px;
}

/* Month header */
.shp-datepicker-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 0 0 14px 0;
  padding: 0;
  min-height: 28px;
}

.shp-datepicker-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--shp-text);
  text-transform: lowercase;
  flex: 1;
  text-align: center;
  line-height: 1;
}

.shp-datepicker-title::first-letter {
  text-transform: uppercase;
}

.shp-datepicker-nav {
  width: 28px !important;
  height: 28px !important;
  border-radius: 50% !important;
  background: none !important;
  border: none !important;
  color: var(--shp-text) !important;
  font-size: 18px !important;
  font-weight: 400 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 0 !important;
  flex-shrink: 0;
  transition: background 0.15s ease;
}

.shp-datepicker-nav:hover {
  background: #f5f5f5 !important;
}

.shp-datepicker-nav-placeholder {
  width: 28px;
  height: 28px;
  flex-shrink: 0;
}

/* Weekdays */
.shp-datepicker-weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  margin: 0 0 2px 0;
  padding: 0;
}

.shp-datepicker-weekday {
  font-size: 11px;
  font-weight: 500;
  color: var(--shp-muted);
  text-align: center;
  padding: 4px 0;
  text-transform: lowercase;
  line-height: 1;
}

/* Days */
.shp-datepicker-days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 0;
}

.shp-datepicker .shp-datepicker-day {
  width: 34px !important;
  height: 34px !important;
  border-radius: 50% !important;
  font-size: 13px !important;
  font-weight: 400 !important;
  color: var(--shp-text) !important;
  background: none !important;
  border: none !important;
  box-shadow: none !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 0 !important;
  margin: 1px auto !important;
  transition: background 0.1s ease;
  cursor: pointer;
}

.shp-datepicker .shp-datepicker-day:hover:not(.shp-day-disabled):not(.shp-day-selected) {
  background: #f5f5f5 !important;
}

.shp-datepicker .shp-datepicker-day.shp-day-today:not(.shp-day-selected) {
  font-weight: 700 !important;
  text-decoration: underline;
}

.shp-datepicker .shp-datepicker-day.shp-day-selected {
  background: var(--shp-text) !important;
  color: #fff !important;
  font-weight: 600 !important;
}

.shp-datepicker .shp-datepicker-day.shp-day-disabled {
  color: #d5d5d5 !important;
  cursor: default;
  text-decoration: line-through;
}

.shp-datepicker .shp-datepicker-day.shp-day-empty {
  visibility: hidden;
  cursor: default;
}

/* ===== Stepper ===== */
.shp-stepper {
  display: flex;
  align-items: center;
  gap: 0;
}

.shp-search-wrapper .shp-stepper-btn {
  width: 30px !important;
  height: 30px !important;
  border-radius: 50% !important;
  border: 1.5px solid #ccc !important;
  background: none !important;
  color: #555 !important;
  font-size: 16px !important;
  font-weight: 300 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 0 !important;
  box-shadow: none !important;
  line-height: 1 !important;
  flex-shrink: 0;
  transition: border-color 0.15s ease, color 0.15s ease;
}

.shp-search-wrapper .shp-stepper-btn:hover {
  border-color: var(--shp-text) !important;
  color: var(--shp-text) !important;
  background: none !important;
}

.shp-search-wrapper .shp-stepper-btn:active {
  transform: scale(0.92);
}

.shp-stepper-value {
  min-width: 36px;
  text-align: center;
  font-size: 16px;
  font-weight: 600;
  color: var(--shp-text);
  user-select: none;
  line-height: 1;
}

/* ===== Submit Button ===== */
.shp-search-field-submit {
  flex: 0 0 auto !important;
  display: flex;
  align-items: stretch;
  padding: 0 !important;
  border-right: none !important;
}

.shp-search-wrapper .shp-search-btn {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 0 48px !important;
  background: var(--shp-accent) !important;
  color: #fff !important;
  font-size: 14px !important;
  font-weight: 700 !important;
  letter-spacing: 0.12em !important;
  text-transform: uppercase !important;
  border: none !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  white-space: nowrap;
  min-height: 100%;
  transition: filter 0.2s ease;
}

.shp-search-wrapper .shp-search-btn:hover {
  filter: brightness(1.05);
  background: var(--shp-accent) !important;
}

.shp-search-wrapper .shp-search-btn:active {
  filter: brightness(0.95);
}

.shp-search-wrapper .shp-search-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  filter: none;
}

/* ===== Iframe (detail mode) ===== */
.shp-rentals-iframe {
  display: none;
  width: 100%;
  border: none;
  margin: 0;
}

/* ===== Search Results Container ===== */
.shp-search-wrapper .shp-search-results.shp-rentals-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 30px 20px;
}

.shp-search-results .shp-loading {
  text-align: center;
  padding: 40px 20px;
  color: #717171;
  font-size: 0.9375rem;
  width: 100%;
}

/* ===== Responsive ===== */
@media (max-width: 900px) {
  .shp-search-wrapper {
    max-width: 100%;
  }

  .shp-search-form-fields {
    flex-wrap: wrap;
  }

  .shp-search-field {
    flex: 1 1 50%;
    border-bottom: 1px solid var(--shp-border);
    padding: 14px 20px;
  }

  .shp-search-field-submit {
    flex: 1 1 100% !important;
  }

  .shp-search-wrapper .shp-search-btn {
    width: 100%;
    min-height: 54px;
  }

  .shp-datepicker-months {
    flex-direction: column;
    gap: 16px;
  }

  .shp-datepicker {
    left: -24px;
    right: -24px;
    padding: 20px 16px;
  }

  .shp-datepicker-month {
    min-width: auto;
  }
}

@media (max-width: 600px) {
  .shp-search-form-fields {
    flex-direction: column;
  }

  .shp-search-field {
    flex: 1 1 100%;
    border-right: none;
    border-bottom: 1px solid var(--shp-border);
    padding: 14px 20px;
  }

  .shp-search-field:last-of-type {
    border-bottom: none;
  }

  .shp-search-field-submit {
    border-bottom: none !important;
  }

  .shp-search-wrapper .shp-search-btn {
    min-height: 52px;
  }

  .shp-datepicker {
    position: fixed;
    top: auto;
    bottom: 0;
    left: 0;
    right: 0;
    border-radius: 12px 12px 0 0;
    padding: 20px 16px 28px;
    box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.15);
    max-height: 70vh;
    overflow-y: auto;
  }

  .shp-datepicker.shp-datepicker-open {
    transform: translateY(0);
  }

  .shp-datepicker .shp-datepicker-day {
    width: 38px !important;
    height: 38px !important;
  }
}
