:root {
  --navy: #0c3d62;
  --navy-deep: #0a3456;
  --navy-hover: #15527a;
  --orange: #e07022;
  --orange-hover: #c85f16;
  --teal: #2aa3a0;
  --teal-dark: #1f8c89;
  --teal-soft: #e7f6f4;
  --chip: #d8f0ec;
  --chip-text: #1a7a74;
  --text: #1b3348;
  --muted: #6a7d8c;
  --bg: #f4f7fa;
  --card: #ffffff;
  --border: #e3eaf0;
  --star: #f0a020;
  --shadow: 0 8px 24px rgba(16, 52, 86, 0.08);
  --radius: 16px;
  --header-h: 68px;
  --font: "Poppins", "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select,
textarea {
  font-family: inherit;
}

.container {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
}

/* Header */
.site-header {
  background: var(--navy);
  color: #fff;
  height: var(--header-h);
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.15);
}

.header-inner {
  height: 100%;
  display: grid;
  grid-template-columns: auto 1fr auto auto;
  align-items: center;
  gap: 24px;
}

.header-inner nav {
  display: flex;
  justify-content: center;
}

.logo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  letter-spacing: 0.08em;
  font-size: 15px;
  white-space: nowrap;
}

.logo svg {
  width: 28px;
  height: 22px;
  flex-shrink: 0;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 26px;
  list-style: none;
  font-size: 14px;
}

.nav-links a {
  color: rgba(255, 255, 255, 0.72);
  font-weight: 400;
  padding: 6px 0;
}

.nav-links a:hover,
.nav-links a.active {
  color: #fff;
  font-weight: 500;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border: 0;
  cursor: pointer;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 500;
  padding: 8px 16px;
  transition: 0.18s ease;
}

.btn-ghost {
  background: transparent;
  color: #fff;
  border: 1.5px solid rgba(255, 255, 255, 0.75);
  border-radius: 8px;
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.1);
}

.btn-orange {
  background: var(--orange);
  color: #fff;
}

.btn-orange:hover {
  background: var(--orange-hover);
}

.btn-navy {
  background: var(--navy);
  color: #fff;
}

.btn-navy:hover {
  background: var(--navy-hover);
}

.menu-toggle {
  display: none;
  background: none;
  border: 0;
  color: #fff;
  cursor: pointer;
}

/* Page shell */
.page {
  flex: 1;
  padding: 28px 0 48px;
}

.page-title {
  font-size: 34px;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--navy);
  line-height: 1.15;
}

.page-subtitle {
  color: var(--muted);
  font-size: 14.5px;
  margin-top: 4px;
  margin-bottom: 22px;
}

.catalog-layout {
  display: grid;
  grid-template-columns: 232px 1fr;
  gap: 22px;
  align-items: start;
}

/* Filters */
.filters {
  background: var(--card);
  border-radius: 18px;
  padding: 18px 18px 16px;
  box-shadow: var(--shadow);
  position: sticky;
  top: calc(var(--header-h) + 16px);
}

.filters-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
}

.filters-head h2 {
  font-size: 18px;
  font-weight: 700;
  color: var(--navy);
}

.btn-clear {
  background: none;
  border: 0;
  color: var(--teal);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
}

.btn-clear:hover {
  text-decoration: underline;
}

.filter-group {
  margin-bottom: 16px;
}

.filter-group h3 {
  font-size: 13.5px;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--text);
}

.check {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13.5px;
  color: var(--text);
  margin-bottom: 7px;
  cursor: pointer;
  user-select: none;
}

.check input {
  appearance: none;
  width: 16px;
  height: 16px;
  border: 1.6px solid #c5d0d8;
  border-radius: 4px;
  display: grid;
  place-items: center;
  background: #fff;
  flex-shrink: 0;
}

.check input:checked {
  background: var(--teal);
  border-color: var(--teal);
}

.check input:checked::after {
  content: "";
  width: 8px;
  height: 5px;
  border-left: 2px solid #fff;
  border-bottom: 2px solid #fff;
  transform: rotate(-45deg) translate(0, -1px);
}

.check-round input {
  border-radius: 50%;
}

.rating-list .check input {
  border-color: var(--orange);
  border-radius: 4px;
}

.rating-list .check input:checked {
  background: var(--orange);
  border-color: var(--orange);
}

.price-range {
  position: relative;
  height: 28px;
  margin: 8px 2px 4px;
}

.price-range input[type="range"] {
  position: absolute;
  left: 0;
  width: 100%;
  appearance: none;
  background: none;
  pointer-events: none;
  height: 20px;
  top: 0;
}

.price-range input[type="range"]::-webkit-slider-thumb {
  appearance: none;
  pointer-events: auto;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--teal);
  border: 2px solid #fff;
  box-shadow: 0 0 0 1px var(--teal);
  cursor: pointer;
  margin-top: -6px;
}

.price-range input[type="range"]::-moz-range-thumb {
  pointer-events: auto;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--teal);
  border: 2px solid #fff;
  box-shadow: 0 0 0 1px var(--teal);
  cursor: pointer;
}

.range-rail {
  position: absolute;
  left: 0;
  right: 0;
  top: 8px;
  height: 4px;
  background: #d7e3ea;
  border-radius: 4px;
}

.range-fill {
  position: absolute;
  top: 8px;
  height: 4px;
  background: var(--teal);
  border-radius: 4px;
}

.price-labels {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--muted);
  margin-top: 2px;
}

.btn-apply {
  width: 100%;
  margin-top: 6px;
  padding: 10px 16px;
  border-radius: 10px;
  font-size: 14px;
}

/* Toolbar */
.toolbar {
  display: flex;
  gap: 12px;
  margin-bottom: 12px;
}

.search {
  flex: 1;
  position: relative;
}

.search svg {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: #8a9aaa;
}

.search input {
  width: 100%;
  height: 42px;
  border: 1px solid #d7e0e8;
  border-radius: 10px;
  padding: 0 14px 0 40px;
  background: #fff;
  font-size: 13.5px;
  color: var(--text);
  outline: none;
}

.search input:focus {
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(42, 163, 160, 0.12);
}

.sort {
  height: 42px;
  border: 1px solid #d7e0e8;
  border-radius: 10px;
  background: #fff;
  padding: 0 12px;
  font-size: 13px;
  color: var(--text);
  min-width: 190px;
}

.results-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 14px;
  min-height: 28px;
}

.results-count {
  font-size: 13px;
  color: var(--muted);
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--chip);
  color: var(--chip-text);
  font-size: 12.5px;
  font-weight: 500;
  padding: 4px 10px;
  border-radius: 999px;
}

.chip button {
  background: none;
  border: 0;
  color: inherit;
  cursor: pointer;
  font-size: 14px;
  line-height: 1;
}

/* Cards */
.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.card {
  background: #fff;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.card:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 28px rgba(16, 52, 86, 0.12);
}

.card-media {
  position: relative;
  height: 148px;
  overflow: hidden;
}

.card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.fav {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--orange);
  border: 0;
  color: #fff;
  display: grid;
  place-items: center;
  cursor: pointer;
}

.fav.active svg {
  fill: #fff;
}

.card-body {
  padding: 12px 14px 14px;
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-rows: auto auto auto auto;
  gap: 0 8px;
}

.card-title {
  font-size: 16.5px;
  font-weight: 700;
  color: var(--navy);
  grid-column: 1;
}

.card-rating {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  grid-column: 2;
  justify-self: end;
}

.card-rating svg {
  color: var(--star);
}

.card-loc {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 4px;
  color: var(--muted);
  font-size: 12px;
  margin: 2px 0 10px;
}

.card-from {
  grid-column: 1;
  font-size: 11.5px;
  color: var(--muted);
}

.card-price {
  grid-column: 1;
  font-size: 20px;
  font-weight: 700;
  color: var(--orange);
  line-height: 1.15;
}

.go {
  grid-column: 2;
  grid-row: 3 / 5;
  align-self: end;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--navy);
  color: #fff;
  display: grid;
  place-items: center;
  margin-bottom: 2px;
}

.go:hover {
  background: var(--navy-hover);
}

.empty {
  grid-column: 1 / -1;
  background: #fff;
  border-radius: 16px;
  padding: 48px 20px;
  text-align: center;
  color: var(--muted);
  box-shadow: var(--shadow);
}

/* Pagination */
.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  margin-top: 28px;
}

.page-btn {
  min-width: 32px;
  height: 32px;
  border-radius: 8px;
  border: 1px solid #d5dee6;
  background: #fff;
  color: var(--muted);
  cursor: pointer;
  font-size: 13px;
  display: grid;
  place-items: center;
}

.page-btn.active {
  background: var(--navy);
  border-color: var(--navy);
  color: #fff;
}

.page-btn:disabled {
  opacity: 0.45;
  cursor: default;
}

.page-ellipsis {
  color: var(--muted);
  padding: 0 4px;
}

/* Footer */
.site-footer {
  background: var(--navy);
  color: #d7e4ee;
  padding: 36px 0 18px;
  margin-top: auto;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 24px;
  padding-bottom: 28px;
}

.footer-brand p {
  margin: 10px 0 14px;
  font-size: 13px;
  max-width: 220px;
  line-height: 1.45;
  color: rgba(255, 255, 255, 0.72);
}

.socials {
  display: flex;
  gap: 8px;
}

.socials a {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  display: grid;
  place-items: center;
  color: #fff;
}

.footer-col h4 {
  color: #fff;
  font-size: 14px;
  margin-bottom: 10px;
}

.footer-col a {
  display: block;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.72);
  margin-bottom: 6px;
}

.footer-col a:hover {
  color: #fff;
}

.copyright {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  padding-top: 14px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.55);
}

/* Inner pages */
.hero-band {
  background: linear-gradient(120deg, var(--navy) 0%, #176087 100%);
  color: #fff;
  border-radius: 20px;
  padding: 36px 40px;
  margin-bottom: 24px;
  overflow: hidden;
}

.hero-band h1 {
  font-size: 32px;
  margin-bottom: 8px;
}

.hero-band p {
  opacity: 0.88;
  max-width: 560px;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.panel {
  background: #fff;
  border-radius: 16px;
  box-shadow: var(--shadow);
  padding: 20px;
}

.panel h3 {
  color: var(--navy);
  margin-bottom: 8px;
}

.panel p,
.panel li {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
}

.feature-icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: var(--teal-soft);
  color: var(--teal-dark);
  display: grid;
  place-items: center;
  margin-bottom: 12px;
}

.auth-wrap {
  min-height: calc(100vh - var(--header-h) - 220px);
  display: grid;
  place-items: center;
  padding: 40px 0;
}

.auth-card {
  width: min(420px, 100%);
  background: #fff;
  border-radius: 18px;
  box-shadow: var(--shadow);
  padding: 28px;
}

.auth-card h1 {
  color: var(--navy);
  font-size: 26px;
  margin-bottom: 6px;
}

.auth-card p.lead {
  color: var(--muted);
  font-size: 14px;
  margin-bottom: 20px;
}

.field {
  margin-bottom: 14px;
}

.field label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  margin-bottom: 6px;
}

.field input,
.field textarea,
.field select {
  width: 100%;
  border: 1px solid #d7e0e8;
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 14px;
  outline: none;
}

.field input:focus,
.field textarea:focus,
.field select:focus {
  border-color: var(--teal);
}

.auth-card .btn {
  width: 100%;
  padding: 11px;
  margin-top: 6px;
}

.auth-alt {
  text-align: center;
  margin-top: 14px;
  font-size: 13px;
  color: var(--muted);
}

.auth-alt a {
  color: var(--orange);
  font-weight: 600;
}

.detail {
  display: grid;
  grid-template-columns: 1.4fr 0.8fr;
  gap: 22px;
}

.detail-hero {
  height: 320px;
  border-radius: 18px;
  overflow: hidden;
  position: relative;
}

.detail-hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.booking {
  background: #fff;
  border-radius: 18px;
  box-shadow: var(--shadow);
  padding: 22px;
  height: fit-content;
  position: sticky;
  top: calc(var(--header-h) + 16px);
}

.booking .price {
  font-size: 32px;
  color: var(--orange);
  font-weight: 700;
}

.form-msg {
  display: none;
  margin-top: 12px;
  padding: 10px 12px;
  border-radius: 10px;
  background: var(--teal-soft);
  color: var(--teal-dark);
  font-size: 13px;
}

.form-msg.show {
  display: block;
}

.blog-card img {
  width: 100%;
  height: 160px;
  object-fit: cover;
  border-radius: 12px;
  margin-bottom: 12px;
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
}

.map-placeholder {
  height: 220px;
  border-radius: 14px;
  background: linear-gradient(135deg, #d7eee9, #c5dcec);
  display: grid;
  place-items: center;
  color: var(--navy);
  font-weight: 600;
}

.offer-badge {
  display: inline-block;
  background: #ffe8d4;
  color: var(--orange);
  font-size: 12px;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 999px;
  margin-bottom: 8px;
}

@media (max-width: 980px) {
  .catalog-layout,
  .detail,
  .contact-grid,
  .footer-grid,
  .grid-3 {
    grid-template-columns: 1fr 1fr;
  }

  .catalog-layout {
    grid-template-columns: 1fr;
  }

  .filters {
    position: static;
  }

  .cards {
    grid-template-columns: 1fr 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 760px) {
  .header-inner {
    grid-template-columns: 1fr auto;
  }

  .header-inner nav {
    display: contents;
  }

  .nav-links,
  .header-actions {
    display: none;
  }

  .header-actions.open,
  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: var(--header-h);
    left: 0;
    right: 0;
    background: var(--navy-deep);
    padding: 16px;
    gap: 12px;
  }

  .menu-toggle {
    display: block;
  }

  .cards,
  .grid-3,
  .detail,
  .contact-grid,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .page-title {
    font-size: 28px;
  }

  .toolbar {
    flex-direction: column;
  }
}

/* Modo oscuro y botón de tema */
.btn-tema {
  padding: 6px 12px;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  background: #f0f0f0;
  color: #222;
  font-weight: 600;
  font-size: 12.5px;
  margin-left: 0;
  transition: all 0.3s ease;
  white-space: nowrap;
}

.btn-tema:hover {
  background: #e0e0e0;
  transform: scale(1.05);
}

body {
  transition: background-color 0.3s ease, color 0.3s ease;
}

body.oscuro {
  --bg: #121212;
  --card: #1e1e1e;
  --text: #e0e0e0;
  --muted: #a0a0a0;
  --border: #333;
  --navy: #1e1e1e;
  --navy-deep: #1a1a1a;
  --navy-hover: #333;
  --teal-soft: #1a2e2d;
  --chip: #1a2e2d;
  --chip-text: #7dd3d0;
  background-color: #121212 !important;
  color: #e0e0e0 !important;
}

body.oscuro .site-header,
body.oscuro .site-footer {
  background-color: #1a1a1a !important;
}

body.oscuro .card,
body.oscuro .filters,
body.oscuro .panel,
body.oscuro .booking,
body.oscuro .auth-card,
body.oscuro .empty {
  background-color: #1e1e1e !important;
  color: #e0e0e0 !important;
  border-color: #333 !important;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4) !important;
}

body.oscuro .page-title,
body.oscuro .filters-head h2,
body.oscuro .card-title,
body.oscuro .panel h3,
body.oscuro .auth-card h1,
body.oscuro .hero-band h1 {
  color: #e0e0e0 !important;
}

body.oscuro .page-subtitle,
body.oscuro .card-loc,
body.oscuro .card-from,
body.oscuro .results-count,
body.oscuro .price-labels,
body.oscuro .auth-card p.lead {
  color: #a0a0a0 !important;
}

body.oscuro .card-title a {
  color: #e0e0e0 !important;
}

body.oscuro .search input,
body.oscuro .sort,
body.oscuro .field input,
body.oscuro .field textarea,
body.oscuro .field select {
  background-color: #2a2a2a !important;
  color: #e0e0e0 !important;
  border-color: #444 !important;
}

body.oscuro .check input {
  background: #2a2a2a !important;
  border-color: #555 !important;
}

body.oscuro .check {
  color: #e0e0e0 !important;
}

body.oscuro .filter-group h3 {
  color: #e0e0e0 !important;
}

body.oscuro .range-rail {
  background: #333 !important;
}

body.oscuro .btn-clear {
  color: #7dd3d0 !important;
}

body.oscuro .btn-tema {
  background-color: #f0f0f0 !important;
  color: #222 !important;
}

body.oscuro .page-btn {
  background: #2a2a2a !important;
  color: #e0e0e0 !important;
  border-color: #444 !important;
}

body.oscuro .page-btn.active {
  background: #0c3d62 !important;
  border-color: #0c3d62 !important;
  color: #fff !important;
}

body.oscuro a:hover {
  color: #90caf9 !important;
}

body.oscuro .nav-links a {
  color: rgba(255, 255, 255, 0.72);
}

body.oscuro .nav-links a:hover,
body.oscuro .nav-links a.active {
  color: #fff;
}

body.oscuro .footer-col a {
  color: rgba(255, 255, 255, 0.72);
}

body.oscuro .footer-col a:hover {
  color: #fff;
}

body.oscuro .socials a {
  color: #fff;
}