.offer-wrapper {
  font-family: sans-serif;
  margin: 0;
  max-width: 100%;
  overflow-x: hidden;
}

.filter-wrapper {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(240, 247, 255, 0.92)),
    rgba(255, 255, 255, 0.94);
  max-width: 100%;
  margin: 0 auto 30px auto;
  padding: 22px;
  position: relative;
  overflow: visible;
  border: 1px solid rgba(208, 223, 242, 0.8);
  border-radius: 18px;
  box-shadow: none;
  backdrop-filter: blur(8px);
}

.filter-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: space-between;
  align-items: flex-start;
}

.dropdown-field {
  flex: 1 1 22%;
  display: flex;
  flex-direction: column;
  position: relative;
  z-index: 1;
  min-width: 0;
}

.dropdown-field.dropdown-open {
  z-index: 1004;
}

.dropdown-field label {
  margin-bottom: 8px;
  font-size: 13px;
  font-weight: 700;
  color: #29405f;
}

.filter-input,
.dropdown-toggle,
#date-range {
  width: 90%;
  padding: 13px 14px;
  min-height: 48px;
  font-size: 14px;
  border: 1px solid #d8e4f5;
  border-radius: 12px !important;
  background: #fff;
  cursor: pointer;
  box-sizing: border-box;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  color: #22324a;
  -webkit-text-fill-color: #22324a;
}

.badge-toggle {
  appearance: none;
  -webkit-appearance: none;
  text-align: left;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 48px;
  overflow: hidden;
  min-width: 0;
  max-width: 90%;
  flex: 0 0 auto;
}

.toggle-content {
  display: flex;
  flex: 1;
  flex-wrap: nowrap;
  align-items: center;
  gap: 6px;
  min-width: 0;
  overflow-x: auto;
  overflow-y: hidden;
  white-space: nowrap;
  scrollbar-width: thin;
  scrollbar-color: #c8d6ee transparent;
  -webkit-overflow-scrolling: touch;
  cursor: grab;
}

.toggle-content::-webkit-scrollbar {
  height: 6px;
}

.toggle-content::-webkit-scrollbar-thumb {
  background: #c8d6ee;
  border-radius: 999px;
}

.toggle-content::-webkit-scrollbar-track {
  background: transparent;
}

.toggle-placeholder {
  color: #66768d;
}

.toggle-chevron {
  flex: 0 0 auto;
  color: #6f84a3;
  font-size: 14px;
  line-height: 1;
}

.selected-filter-badge {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  padding: 4px 9px;
  border-radius: 999px;
  background: linear-gradient(135deg, #eef4ff, #f7faff);
  border: 1px solid #d6e4fb;
  color: #2b4467;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.15;
  white-space: nowrap;
}

.filter-wrapper .filter-input,
.filter-wrapper .dropdown-toggle,
.filter-wrapper #date-range,
.filter-wrapper select,
.filter-wrapper input[type="number"] {
  background: #fff !important;
  border-radius: 12px !important;
}

.filter-input:focus,
.dropdown-toggle:focus,
#date-range:focus {
  outline: none;
  border-color: #7aa7ff;
  box-shadow: 0 0 0 4px rgba(72, 126, 255, 0.12);
}

.dropdown-panel {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  width: 90%;
  background: rgba(255, 255, 255, 0.98);
  border: 1px solid #d6e1f1;
  max-height: 250px;
  overflow-y: auto;
  z-index: 1002;
  padding: 12px;
  border-radius: 14px;
  box-shadow: 0 18px 32px rgba(33, 61, 102, 0.12);
}

.dropdown-panel.active {
  display: block;
}

.dropdown-panel label {
  display: flex;
  align-items: center;
  margin-bottom: 8px;
  font-size: 15px;
  line-height: 1.2;
}

.dropdown-panel input[type="checkbox"] {
  margin-right: 8px;
}

.dropdown-panel .nested-options label {
  margin-bottom: 7px;
}

.destination-flag {
  display: inline-flex;
  align-items: center;
  margin-right: 6px;
  font-size: 15px;
  line-height: 1;
}

.extra-options {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 10px;
}

.extra-options select,
.extra-options input[type="number"] {
  padding: 10px 12px;
  font-size: 14px;
  border-radius: 10px;
  border: 1px solid #d7e3f4;
  background: rgba(255, 255, 255, 0.95);
}

.reset-filters {
  display: none;
  cursor: pointer;
  position: absolute;
  top: 12px;
  right: 12px;
  font-size: 18px;
  font-weight: 700;
  color: #dd3b3b;
  width: 30px;
  height: 30px;
  line-height: 1;
  text-align: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid rgba(239, 132, 132, 0.35);
  box-shadow: 0 8px 18px rgba(63, 90, 129, 0.08);
  z-index: 1003;
  align-items: center;
  justify-content: center;
}

.reset-filters.is-visible {
  display: flex;
}

.reset-filters:hover {
  color: #bf2626;
  background: #fff;
}

#offers-results {
  max-width: 100%;
  margin: 0 auto;
  margin-top: 0px !important;
  overflow-x: hidden;
}

.wrapper {
  max-width: 100%;
  margin: 0 auto;
  background: #fff;
  box-shadow: 0 0 20px rgba(0,0,0,0.1);
  overflow-x: hidden;
}

.offers-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  table-layout: fixed;
}

.offers-table tr {
  border-bottom: 1px solid #e0e0e0;
  cursor: pointer;
  transition: background 0.2s ease-in-out;
}

.offers-table tr:hover {
  background: #f0f8ff;
}

.offers-table td {
  padding: 8px 6px;
  vertical-align: top;
}

.offers-table tr.yeta-offer-row td {
  padding: 0;
  vertical-align: middle;
}

.offers-table tr.yeta-offer-row td .offer-link {
  display: block;
  width: 100%;
  height: 100%;
  padding: 7px 10px;
  box-sizing: border-box;
  color: inherit;
  text-decoration: none;
}

.offers-table td.image-col .offer-link {
  padding: 0;
  display: block;
  width: 112px;
  height: 112px;
}

.offers-table td.image-col {
  width: 112px;
  min-width: 112px;
}

.offers-table td.main-col {
  width: 36%;
  overflow: hidden;
  min-width: 0;
  vertical-align: middle;
}

.offers-table td.main-col .offer-link {
  overflow: hidden;
  min-width: 0;
}

.offers-table td.schedule-col {
  width: 140px;
  vertical-align: middle;
}

.offers-table td.transport-col {
  width: 190px;
  vertical-align: middle;
}

.offers-table td.price-col {
  width: 170px;
  vertical-align: middle;
}

.offers-table tr.yeta-offer-row td.price-col {
  padding-right: 5px;
}

.offers-table td.image-col img.thumbnail {
  border-radius: 4px !important;
  display: block;
  width: 80px;
  object-fit: cover;
}


.info-col {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.hotel-name {
  font-weight: bold;
  font-size: 14px;
  color: #222;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.location {
  font-size: 13px;
  color: #666;
}

.details {
  margin-top: 8px;
  font-size: 12px;
  color: #666;
  line-height: 1.35;
}

.mobile-offer-details {
  display: none;
}

.details.mobile-offer-details {
  margin-top: 2px !important;
}

.departure-date {
  margin-bottom: 2px;
}

.offer-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  margin-top: 2px !important;
}

.schedule-col .offer-link,
.transport-col .offer-link {
  display: block;
}

.schedule-col-inner {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
}

.transport-col-inner {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: nowrap;
  white-space: nowrap;
}

.schedule-col .departure-date {
  font-size: 13px;
  line-height: 1.15;
  margin-bottom: 1px;
}

.departure-badge {
  display: inline-block;
  background: #5b39f0;
  color: white;
  font-size: 13px;
  padding: 3px 9px;
  border-radius: 4px;
  line-height: 1.2;
}

.own-transport-badge {
  display: inline-block;
  background: #ffc107;
  color: #000;
  font-size: 13px;
  padding: 3px 9px;
  border-radius: 4px;
  line-height: 1.2;
}

.board-badge {
  display: inline-block;
  background: #eef3fa;
  color: #333;
  font-size: 13px;
  padding: 3px 9px;
  border-radius: 4px;
  line-height: 1.2;
}

.days-badge {
  display: inline-block;
  background: #68d36c;
  color: #fff;
  font-size: 13px;
  padding: 3px 9px;
  border-radius: 4px;
  line-height: 1.2;
}

.mobile-price-days {
  display: none;
}

.price-col {
  text-align: right;
  white-space: normal;
}

.price-col .offer-link {
  display: flex !important;
  flex-direction: column;
  align-items: flex-end;
}

.price-col .price {
  font-weight: bold;
  font-size: 16px;
  color: #129d43;
  line-height: 1.1;
}

.price-col .price .price-prefix {
  font-size: 12px;
  font-weight: 500;
  color: #8c98a8;
}

.price-col .tour-operator {
  font-size: 12px;
  color: #666;
  margin-top: 5px;
  line-height: 1.2;
}

.price-col .rating {
  font-size: 11px;
  color: #999;
  margin-top: 2px;
  line-height: 1.2;
}

@media (min-width: 769px) {
  .offers-table tr.yeta-offer-row td {
    height: 96px;
    vertical-align: middle;
  }

  .offers-table tr.yeta-offer-row td .offer-link {
    padding-top: 0;
    padding-bottom: 0;
  }

  .offers-table td.main-col .offer-link,
  .offers-table td.schedule-col .offer-link,
  .offers-table td.transport-col .offer-link,
  .offers-table td.price-col .offer-link {
    display: table-cell !important;
    vertical-align: middle;
    width: 100%;
    height: 96px;
  }

  .offers-table td.image-col .offer-link {
    display: flex !important;
    align-items: center;
    justify-content: center;
    width: 112px;
    height: 96px;
  }
}

.stars {
  color: #f4b400;
  font-size: 13px;
}

/* === MOBILE === */
@media (max-width: 768px) {
  .dropdown-field > label {
    font-size: 15px;
  }

  .filter-grid {
    flex-direction: column;
    gap: 12px;
  }

  .dropdown-field {
    flex: 1 1 100%;
    width: 100%;
    margin-bottom: 10px;
  }

  .filter-input,
  .dropdown-toggle,
  #date-range,
  .dropdown-panel,
  .dropdown-field input[type="text"],
  .dropdown-field select,
  .dropdown-field input[type="number"] {
    width: 100% !important;
    box-sizing: border-box;
    max-width: 100%;
  }

  .dropdown-panel {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    width: 100%;
    padding: 12px;
    z-index: 9999;
  }
}

/* Naprawa wyjeżdżającej listy wyników na mobile */
@media (max-width: 768px) {
  .wrapper {
    max-width: 100%;
    overflow-x: hidden;
  }

  .offers-table,
  .offers-table tbody,
  .offers-table tr,
  .offers-table td {
    display: block;
    width: 100%;
  }

  .offers-table {
    width: 100%;
    table-layout: auto;
    word-wrap: break-word;
  }

  .offers-table td {
    word-break: break-word;
  }

  .offers-table tr:first-child td,
  .offers-table tr:last-child td {
    display: table-cell;
    width: auto;
  }

  .offers-table tr.yeta-offer-row {
    display: flex;
    align-items: flex-start;
    width: 100%;
  }

  .offers-table td.image-col {
    display: block;
    width: 84px;
    min-width: 84px;
  }

  .offers-table td.price-col {
    display: block;
    width: 116px;
    min-width: 116px;
    align-self: center;
  }

  .offers-table td.schedule-col,
  .offers-table td.transport-col {
    display: none;
  }

  .offers-table td.main-col {
    display: block;
    flex: 1 1 auto;
    width: auto;
    min-width: 0;
  }

  .offers-table tr.yeta-offer-row td .offer-link {
    padding: 12px 4px;
  }

  .offers-table td.image-col .offer-link {
    width: 84px;
    height: 84px;
  }

  .offers-table td.image-col img.thumbnail {
    width: 84px;
    height: 84px;
  }

  .hotel-name {
    font-size: 13px;
  }

  .location {
    font-size: 12px;
  }

  .details {
    margin-top: 4px;
  }

  .mobile-offer-details {
    display: block;
  }

  .offer-badges {
    gap: 4px;
  }

  .mobile-days-badge-source {
    display: none;
  }

  .mobile-price-days {
    display: block;
    margin-top: 4px;
  }

  .departure-badge,
  .board-badge,
  .days-badge,
  .own-transport-badge {
    font-size: 11px;
    padding: 2px 6px;
  }

  .price-col .price {
    font-size: 15px;
  }

  .price-col .tour-operator,
  .price-col .rating {
    font-size: 12px;
  }

  .price-col {
    white-space: nowrap;
  }

  .price-col .price {
    white-space: nowrap;
  }

  .price-col .tour-operator,
  .price-col .rating {
    white-space: normal;
    overflow-wrap: normal;
    word-break: normal;
  }

  .price-col .offer-link {
    min-height: 72px;
    display: flex !important;
    justify-content: center;
    padding-left: 2px;
    padding-right: 2px;
  }
}

#load-more-btn:hover {
  background-color: #0d6efd;
}

    .nested-options {
      margin-left: 20px;
      display: none;
    }
    .has-children > label {
      font-weight: bold;
      cursor: pointer;
      display: flex;
      align-items: center;
      user-select: none;
    }
    .has-children > label svg.arrow {
      width: 12px;
      height: 12px;
      color: #d3d3d3;
      transition: transform 0.2s ease;
    }
    .has-children.expanded > label svg.arrow {
      transform: rotate(-90deg);
    }
    .partial-checked {
      background-color: #ffe6e6;
      border-radius: 4px;
    }

input,
select,
textarea {
  font-size: 16px !important;
}

.section-heading {
  margin-top: 12px;
  margin-bottom: 6px;
  font-weight: bold;
  font-size: 16px;
}

.info-col {
  display: flex;
  flex-direction: column;
  gap: 0px;
}

.info-col > * {
  margin: 0 !important;
  padding: 0 !important;
  line-height: 1.2;
}

.price-col > * {
  margin: 0 !important;
  padding: 0 !important;
  line-height: 1.2;
}

.price-col .offer-link > * {
  margin: 0 !important;
}

.details > * {
  margin: 0 !important;
  line-height: 1.2;
}

.offers-table tr {
  border-bottom: 1px solid #f2f2f2;
}

.offers-table,
.offers-table td,
.offers-table th {
  border: none !important;
  border-collapse: collapse;
}

.offer-wrapper input[type=email],
.offer-wrapper input[type=number],
.offer-wrapper input[type=password],
.offer-wrapper input[type=reset],
.offer-wrapper input[type=search],
.offer-wrapper input[type=tel],
.offer-wrapper input[type=text],
.offer-wrapper input[type=url],
.offer-wrapper select,
.offer-wrapper textarea {
    color: #9ca3af;
    padding: .75em;
    height: auto;
    border-width: 1px;
    border-style: solid;
    border-color: #e6eeff;
    border-radius: 2px;
    background: var(--ast-comment-inputs-background);
    box-shadow: none;
    box-sizing: border-box;
    transition: all .2s linear;
}

#load-more-button:hover {
  background-color: #0d6efd;
}
