/* Shortlista — layout kart hotel-pod-hotelem */
.page-title {
  margin: 0;
  font-size: clamp(1.25rem, 3vw, 1.75rem);
  font-weight: 700;
}

.page-sub {
  margin: 0.25rem 0 0;
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.page-note {
  margin: 0.4rem 0 0;
  font-size: 0.75rem;
  color: var(--text-secondary);
  max-width: 60ch;
  line-height: 1.4;
}

.main-wrap {
  max-width: 900px;
  margin: 0 auto;
  padding: 1.25rem 1rem 3rem;
}

.hotel-list {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.hotel-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  overflow: hidden;
}

.hotel-card__hero {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #e2e8f0;
  cursor: pointer;
}

.hotel-card__hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.hotel-card__hero-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  font-size: 0.9rem;
}

.hotel-card__photo-count {
  position: absolute;
  bottom: 0.75rem;
  right: 0.75rem;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
}

.page-head {
  margin-bottom: 1.25rem;
}

/* Wstążka z miejscem w rankingu na zdjęciu */
.hotel-card__rank {
  position: absolute;
  top: 0.75rem;
  left: 0.75rem;
  z-index: 2;
  padding: 0.3rem 0.7rem;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.82);
  color: #fff;
  font-size: 0.85rem;
  font-weight: 800;
  letter-spacing: 0.01em;
  box-shadow: var(--shadow-sm);
}

/* ── Werdykt: kafelki + tagline + plusy/minusy ─────────────────────────── */
.verdict {
  margin: 0.25rem 0 1.1rem;
}

.scorecard {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 0.85rem;
}

.chip {
  display: inline-flex;
  flex-direction: column;
  gap: 0.05rem;
  padding: 0.35rem 0.6rem;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: #f8fafc;
  line-height: 1.2;
}

.chip__label {
  font-size: 0.64rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  opacity: 0.85;
}

.chip__text {
  font-size: 0.82rem;
  font-weight: 600;
}

.verdict__tagline {
  margin: 0 0 0.85rem;
  font-size: 1rem;
  line-height: 1.55;
  font-weight: 600;
  color: var(--text);
}

.verdict__cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem 1.25rem;
}

.verdict__col h3 {
  margin: 0 0 0.4rem;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.verdict__col--pros h3 { color: #047857; }
.verdict__col--cons h3 { color: #c2410c; }

.verdict__col ul {
  margin: 0;
  padding-left: 1.15rem;
  font-size: 0.9rem;
  line-height: 1.5;
  color: var(--text);
}

.verdict__col li { margin-bottom: 0.2rem; }

/* Kolory tierów (wspólne dla kafelków i tabeli porównania) */
.cmp--good { background: #ecfdf5; border-color: #a7f3d0; color: #047857; }
.cmp--ok   { background: #fffbeb; border-color: #fde68a; color: #b45309; }
.cmp--weak { background: #fef2f2; border-color: #fecaca; color: #dc2626; }

.hotel-card__body {
  padding: 1.25rem 1.25rem 1.5rem;
}

.hotel-card__title {
  margin: 0 0 0.35rem;
  font-size: 1.35rem;
  line-height: 1.25;
}

.hotel-card__meta {
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin-bottom: 0.75rem;
}

.hotel-card__badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 1rem;
}

.badge {
  display: inline-block;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  background: #f1f5f9;
  color: var(--text);
}

.badge--gold { background: var(--gold-soft); color: #92400e; }
.badge--rating { background: var(--accent-soft); color: var(--accent-hover); }
.badge--warn { background: #fef2f2; color: #b91c1c; }

.rating-sources {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1rem;
  margin: -0.5rem 0 1rem;
  font-size: 0.82rem;
  color: var(--text-secondary);
}
.rating-src__name { color: var(--text); font-weight: 600; }
.rating-src strong { color: var(--text); }
.rating-src__scale,
.rating-src__count { color: var(--text-secondary); font-weight: 400; }

.trip-info {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 0.5rem 1rem;
  padding: 0.75rem 1rem;
  background: #f8fafc;
  border-radius: var(--radius-sm);
  margin-bottom: 1rem;
  font-size: 0.85rem;
}

.trip-info strong { display: block; font-size: 0.95rem; }

.price-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.5rem;
  margin-bottom: 1rem;
}

@media (max-width: 520px) {
  .price-grid { grid-template-columns: 1fr; }
}

.price-box {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.65rem 0.75rem;
  text-align: center;
}

.price-box__label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-secondary);
  font-weight: 600;
}

.price-box__value {
  font-size: 1.1rem;
  font-weight: 700;
  margin-top: 0.15rem;
}

.price-box__sub {
  font-size: 0.72rem;
  color: var(--text-secondary);
  margin-top: 0.2rem;
}

.price-box__room {
  font-size: 0.68rem;
  color: var(--text-secondary);
  margin-top: 0.35rem;
  line-height: 1.3;
}

.price-box__luggage {
  font-size: 0.68rem;
  margin-top: 0.3rem;
  line-height: 1.3;
  font-weight: 600;
}

.price-box__luggage--added {
  color: #b45309;
}

.price-box__luggage--incl {
  color: #15803d;
}

.price-box__link {
  display: inline-block;
  font-size: 0.72rem;
  margin-top: 0.4rem;
  color: var(--accent);
}

.content-sections {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin: 1rem 0;
}

/* Zwijane kategorie (Plaża, Baseny…) — jak details „warianty" */
details.accordion {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  overflow: hidden;
}

details.accordion > summary {
  list-style: none;
  cursor: pointer;
  padding: 0.7rem 0.85rem;
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--accent-hover);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

details.accordion > summary::-webkit-details-marker { display: none; }

details.accordion > summary::after {
  content: "+";
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1;
  color: var(--text-secondary);
  transition: transform 0.15s;
}

details.accordion[open] > summary::after {
  content: "−";
}

details.accordion[open] > summary {
  border-bottom: 1px solid var(--border);
}

.accordion__body {
  padding: 0.65rem 0.85rem 0.85rem;
}

.accordion__body p {
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.55;
  color: var(--text);
}

.card-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.55rem 1rem;
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
  font-weight: 600;
  text-decoration: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
}

.btn--primary {
  background: var(--accent);
  color: #fff;
}

.btn--primary:hover { background: var(--accent-hover); }

.btn--ghost {
  background: transparent;
  border: 1px solid var(--border-strong);
  color: var(--text);
}

details.variants, details.reviews-panel {
  margin-top: 0.75rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.5rem 0.75rem;
}

details.variants summary, details.reviews-panel summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 0.88rem;
  padding: 0.25rem 0;
}

.variants-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin-top: 0.5rem;
}

.variants-table {
  width: 100%;
  min-width: 520px;
  border-collapse: collapse;
  font-size: 0.8rem;
}

.variants-table th, .variants-table td {
  border-bottom: 1px solid var(--border);
  padding: 0.4rem 0.35rem;
  text-align: left;
}

.review-item {
  border-bottom: 1px solid var(--border);
  padding: 0.65rem 0;
  font-size: 0.85rem;
  line-height: 1.5;
}

.review-item:last-child { border-bottom: none; }

.review-head {
  font-weight: 600;
  color: var(--text-secondary);
  font-size: 0.78rem;
  margin-bottom: 0.25rem;
}

.map-modal {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.map-modal.hidden { display: none; }

.map-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.5);
}

.map-modal-panel {
  position: relative;
  width: min(920px, 100%);
  height: min(70vh, 520px);
  background: var(--surface);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.map-modal-close {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  z-index: 10;
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 50%;
  background: #fff;
  font-size: 1.4rem;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
}

.map-container {
  width: 100%;
  height: 100%;
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 3000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lightbox.hidden { display: none; }

.lightbox-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.88);
}

.lightbox img {
  position: relative;
  max-width: min(96vw, 1100px);
  max-height: 88vh;
  object-fit: contain;
  border-radius: 4px;
}

.lightbox-close, .lightbox-nav {
  position: absolute;
  z-index: 2;
  border: none;
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  font-size: 2rem;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  cursor: pointer;
}

.lightbox-close { top: 1rem; right: 1rem; font-size: 1.75rem; }
.lightbox-prev { left: 1rem; }
.lightbox-next { right: 1rem; }

/* Przełącznik warstw mapy (Mapa / Satelita) */
.leaflet-control-layers {
  min-width: 132px;
  border-radius: 8px;
  box-shadow: 0 1px 6px rgba(0, 0, 0, 0.3);
}
.leaflet-control-layers-expanded {
  padding: 8px 12px 8px 10px;
  font-size: 0.9rem;
}
.leaflet-control-layers-expanded label {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 2px 0;
  white-space: nowrap;
  font-weight: 600;
  color: #1f2933;
}
.leaflet-control-layers-separator { margin: 6px 0; }
.leaflet-control-layers-expanded .leaflet-control-layers-toggle { display: none; }
.leaflet-control-layers-list { margin: 0; }

/* ── Sekcja porównania (na dole) ───────────────────────────────────────── */
.compare {
  margin-top: 2.5rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  overflow: hidden;
}

.compare-head {
  padding: 1.1rem 1.25rem;
  border-bottom: 1px solid var(--border);
  background: linear-gradient(180deg, #ffffff, #f8fafc);
}

.compare-title {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 700;
}

.compare-sub {
  margin: 0.25rem 0 0;
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.compare-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  margin-top: 0.7rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.legend-item { display: inline-flex; align-items: center; gap: 0.35rem; }

.legend-dot {
  width: 0.85rem;
  height: 0.85rem;
  border-radius: 50%;
  border: 1px solid;
}

.legend-dot.cmp--good { background: #10b981; border-color: #059669; }
.legend-dot.cmp--ok   { background: #f59e0b; border-color: #d97706; }
.legend-dot.cmp--weak { background: #ef4444; border-color: #dc2626; }

.compare-table-wrap { width: 100%; }

.cmp-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.84rem;
}

.cmp-table thead th {
  position: sticky;
  top: 0;
  background: #f8fafc;
  text-align: left;
  padding: 0.6rem 0.7rem;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border);
}

.cmp-table td {
  padding: 0.55rem 0.7rem;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}

.cmp-table tbody tr:last-child td { border-bottom: none; }
.cmp-table tbody tr:hover td { background: #f8fafc; }

.cmp-hotel { min-width: 11rem; }

.cmp-rank {
  display: inline-block;
  font-weight: 800;
  color: var(--accent-hover);
  margin-right: 0.35rem;
}

.cmp-name {
  font: inherit;
  font-weight: 700;
  color: var(--text);
  background: none;
  border: none;
  padding: 0;
  text-align: left;
  cursor: pointer;
}

.cmp-name:hover { color: var(--accent-hover); text-decoration: underline; }

.cmp-loc {
  display: block;
  font-size: 0.74rem;
  color: var(--text-secondary);
  font-weight: 500;
  margin-top: 0.1rem;
}

.cmp-cell {
  display: inline-block;
  padding: 0.28rem 0.5rem;
  border-radius: 8px;
  border: 1px solid;
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1.25;
}

/* ── Mobile-first: karty zamiast tabeli + dopasowanie karty hotelu ─────── */
@media (max-width: 760px) {
  .main-wrap { padding: 1rem 0.75rem 2.5rem; }

  .hotel-card__body { padding: 1rem 1rem 1.25rem; }

  .verdict__cols { grid-template-columns: 1fr; }

  .chip { flex: 1 1 8.5rem; }

  .price-grid { grid-template-columns: 1fr 1fr; }

  .compare { margin-left: -0.1rem; margin-right: -0.1rem; }

  /* Tabela porównania -> karty */
  .cmp-table thead { display: none; }

  .cmp-table,
  .cmp-table tbody,
  .cmp-table tr,
  .cmp-table td { display: block; width: 100%; }

  .cmp-table tbody tr {
    padding: 0.4rem 0.9rem 0.7rem;
    border-bottom: 8px solid var(--bg);
  }

  .cmp-table td {
    display: grid;
    grid-template-columns: 6.5rem 1fr;
    gap: 0.6rem;
    align-items: center;
    padding: 0.32rem 0;
    border-bottom: none;
  }

  .cmp-table td::before {
    content: attr(data-label);
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--text-secondary);
  }

  .cmp-table td.cmp-hotel {
    display: block;
    padding: 0.6rem 0 0.5rem;
  }

  .cmp-table td.cmp-hotel::before { display: none; }

  .cmp-name { font-size: 1.02rem; }

  .cmp-table tbody tr:hover td { background: transparent; }

  .cmp-cell { width: 100%; }
}

@media (max-width: 420px) {
  .price-grid { grid-template-columns: 1fr; }
  .chip { flex: 1 1 100%; }
}
