/* ===== Layout base público ===== */

body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  background: #f5f5f7;
  color: #222;
}

.page-main {
  padding: 80px 16px 40px; /* top deja espacio para el header fijo en mobile */
}

@media (min-width: 768px) {
  .page-main {
    padding: 100px 32px 60px;
  }
}

/* ===== Header ===== */

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: #002e2c;
  color: #fff;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.header-inner {
  width: 97%;
  margin: 0 auto;
  padding: 10px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand img {
  height: 32px;
}

/* Nav */

.main-nav {
  position: fixed;
  top: 56px;
  right: 0;
  left: 0;
  background: #002e2c;
  transform: translateY(-100%);
  opacity: 0;
  pointer-events: none;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.main-nav.open {
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
}

.main-nav ul {
  list-style: none;
  margin: 0;
  padding: 8px 16px 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.main-nav a {
  color: #fff;
  text-decoration: none;
  padding: 8px 10px;
  border-radius: 6px;
  font-size: 0.95rem;
}

.main-nav a:hover {
  background: rgba(255,255,255,0.08);
}

.nav-cta {
  background: #d1a578;
  color: #222;
  font-weight: 600;
}
.nav-cta:hover {
  background: #ddbe9d;
}

.nav-logout {
  border: 1px solid rgba(255,255,255,0.5);
}

/* botón hamburguesa */

.nav-toggle {
  width: 36px;
  height: 32px;
  padding: 0;
  border-radius: 8px;
  border: none;
  background: transparent;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  cursor: pointer;
}

.nav-toggle span {
  height: 2px;
  background: #fff;
  border-radius: 999px;
  margin: 0 6px;
}

/* Desktop */

@media (min-width: 900px) {
  .header-inner {
    padding: 12px 24px;
  }

  .nav-toggle {
    display: none;
  }

  .main-nav {
    position: static;
    transform: none;
    opacity: 1;
    pointer-events: auto;
    background: transparent;
  }

  .main-nav ul {
    flex-direction: row;
    gap: 10px;
    padding: 0;
  }
}


/* ===== Footer ===== */

.site-footer {
  margin-top: 40px;
  background: #002e2c;
  color: #e3eceb;
  padding: 18px 16px;
}

.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.85rem;
}

.footer-lang {
  opacity: 0.8;
}

@media (min-width: 768px) {
  .footer-inner {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }
}


/* ====== CATÁLOGO LAYOUT ====== */
.catalog-wrapper {
  display: flex;
  align-items: flex-start;
  width: 100%;
  margin: 0 auto 60px;
}

.filters {
  flex: 1;
  background: #f4f4f4;
  padding: 20px;
  border-radius: 10px;
  font-size: 0.95em;
}

.filters-title {
  font-size: 1.3em;
  margin-bottom: 15px;
  font-weight: 700;
}

.filters-form {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.filter-group label {
  font-weight: 600;
  display: block;
  margin-bottom: 6px;
}

.filter-group select,
.filter-group input[type="number"] {
  width: 100%;
  padding: 8px 10px;
  border-radius: 6px;
  border: 1px solid #ccc;
}

.filter-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 15px;
}

.btn-apply {
  background-color: #d1a578;
  color: #fff;
  border: none;
  padding: 8px 10px;
  border-radius: 4px;
  cursor: pointer;
  font-weight: 600;
}

.btn-apply:hover {
  background-color: #e06e00;
}

.btn-reset {
  text-align: center;
  color: #333;
  text-decoration: none;
  font-weight: 600;
}

.btn-reset:hover {
  background-color: #d4d4d4;
}

.checkbox-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.checkbox-item {
  display: flex;
  align-items: center;
  gap: 5px;
}

.btn-filter {
  background: #333;
  color: #fff;
  padding: 10px;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  transition: 0.3s;
  font-weight: 600;
}

.btn-filter:hover {
  background: #000;
}

/* ====== GRILLA DE TOURS ====== */
.tours-grid {
  flex: 3;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 25px;
}

.tour-card {
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 10px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: box-shadow 0.2s ease-in-out;
}

.tour-card:hover {
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.tour-img {
  position: relative;
}

.tour-img img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.tour-price {
  position: absolute;
  top: 10px;
  right: 10px;
  background: #002e2c;
  color: #fff;
  font-weight: 700;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 0.9em;
}

.tour-body {
  padding: 15px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.tour-title {
  font-size: 1.1em;
  font-weight: 700;
  color: #222;
}

.tour-category {
  font-size: 12px;
  position: absolute;
  top: 130px;
  background-color: #d1a578;
  z-index: 1;
  padding: 6px;
  border-radius: 6px;
  color: #fff;
  text-transform: uppercase;
  font-weight: bold;
  letter-spacing: 0.7px;
}

.tour-meta {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  font-size: 0.85em;
  margin-top: 10px;
  margin-bottom: 10px;
}

.tour-meta i {
  margin-right: 4px;
  color: #d1a578;
}

.tour-desc {
  font-size: 0.9em;
  color: #444;
  flex-grow: 1;
  margin-bottom: 12px;
}

.btn-orange {
  background: #d1a578;
  color: white;
  border: none;
  border-radius: 6px;
  padding: 10px;
  text-align: center;
  font-weight: 600;
  text-decoration: none;
  transition: background 0.2s;
}

.btn-orange:hover {
  background: #ddbe9d;
}

.tour-detail {
  max-width: 1100px;
  margin: 40px auto;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.05);
  overflow: hidden;
  padding-bottom: 30px;
}

.tour-hero {
  position: relative;
  height: 360px;
  overflow: hidden;
}

.tour-hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(80%);
}

.tour-hero-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  color: #fff;
  background: rgba(0, 0, 0, .3);
  width: 100%;
  padding: 20px 0px 20px 20px;
  width: auto;
}

.tour-hero-overlay h1 {
  font-size: 2.2rem;
  margin-bottom: 6px;
}

.tour-meta span {
  margin-right: 15px;
  color: #fff;
  font-size: 0.9rem;
}
.tour-meta.details span {
  color: #222;
}
.tour-body {
  padding: 30px 20px;
}

.tour-content h2, .tour-content h3 {
  color: #333;
  margin-bottom: 10px;
}

.tour-content p {
  line-height: 1.6;
  color: #555;
}

.includes li {
  margin-bottom: 5px;
}

.tour-sidebar {
  background: #f9fafb;
  border-radius: 8px;
  padding: 20px;
  box-shadow: inset 0 0 4px rgba(0,0,0,0.05);
}

.availability-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.availability-list li {
  border-bottom: 1px solid #e0e0e0;
  padding: 10px 0;
}

.availability-list .date {
  font-weight: 500;
  color: #333;
}

.btn-primary.full {
  display: block;
  text-align: center;
  background: #d1a578;
  color: #fff;
  padding: 12px;
  border-radius: 8px;
  margin-top: 20px;
  text-decoration: none;
  font-weight: bold;
  transition: background 0.3s;
}

.btn-primary.full:hover {
  background: #ddbe9d;
}

.booking-form {
  max-width: 600px;
  margin: 60px auto;
  background: #fff;
  padding: 30px;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

.booking-form h2 {
  text-align: center;
  margin-bottom: 20px;
}

.form-box label {
  display: block;
  margin-top: 15px;
  font-weight: 600;
}

.form-box input, 
.form-box select {
  /* width: 100%; */
  padding: 10px;
  border: 1px solid #ddd;
  border-radius: 6px;
}

.form-box .btn-primary {
  display: block;
  width: 100%;
  background: #d1a578;
  color: #fff;
  border: none;
  padding: 12px;
  font-weight: bold;
  border-radius: 6px;
  cursor: pointer;
}

.form-box .btn-primary:hover {
  background: #ddbe9d;
}

select#availability_id {
  appearance: none;
  background-color: #fff;
  background-image: url("data:image/svg+xml;utf8,<svg fill='%23f15a24' height='24' viewBox='0 0 24 24' width='24' xmlns='http://www.w3.org/2000/svg'><path d='M7 10l5 5 5-5z'/></svg>");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 18px;
  padding-right: 40px;
}

/* === Filtros del catálogo === */
.filters {
  background: #f4f4f4;
  padding: 20px;
  border-radius: 10px;
  width: 260px;
  float: left;
  margin-right: 30px;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.filters h3 {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 15px;
  color: #333;
}

.filters label {
  display: block;
  margin-top: 10px;
  font-weight: 500;
}

.filters input,
.filters select {
  width: -webkit-fill-available;
  padding: 6px 8px;
  margin-top: 4px;
  border: 1px solid #ccc;
  border-radius: 6px;
}

.filters button {
  background-color: #d1a578;
  color: white;
  border: none;
  padding: 8px 12px;
  border-radius: 6px;
  cursor: pointer;
  font-weight: bold;
  transition: 0.3s;
}

.filters button:hover {
  background-color: #ddbe9d;
}

/* === Contenedor principal === */
.tour-catalog-container {
  display: flex;
  gap: 30px;
  flex-wrap: wrap;
}

/* === Tarjetas de tours === */
.tour-card {
  flex: 1 1 calc(33.33% - 30px);
  position: relative;
  background: white;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0,0,0,0.08);
  transition: 0.3s ease;
}

.tour-card:hover {
  transform: translateY(-5px);
}

.tour-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-bottom: 1px solid #eee;
}

.tour-info {
  padding: 15px;
  display: flex;
  justify-content: space-between;
  background-color: #eee;
}

.tour-info h3 {
  font-size: 18px;
  font-weight: 600;
  color: #222;
  margin-bottom: 5px;
}

.tour-info p {
  font-size: 14px;
  color: #555;
  margin: 4px 0;
}
.tour-actions {
  margin-top: 30px;
  text-align: center;
}

.btn-back {
  display: inline-block;
  background: #f5f5f5;
  color: #444;
  border: 1px solid #ddd;
  padding: 10px 20px;
  border-radius: 8px;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.2s ease-in-out;
}

.btn-back:hover {
  background: #b97c3f;
  color: #fff;
  border-color: #b97c3f;
}

.filters select[name="sort"] {
  font-weight: 500;
  background-color: #fff;
  border: 1px solid #ccc;
  border-radius: 6px;
  margin-top: 4px;
  padding: 6px 8px;
}

.filters select[name="sort"]:focus {
  border-color: #d1a578;
  outline: none;
}

/* Responsive */
@media (max-width: 768px) {
  .tour-body {
    grid-template-columns: 1fr;
  }

  .tour-hero-overlay h1 {
    font-size: 1.5rem;
  }

  .tour-sidebar {
    margin-top: 20px;
  }
}

/* ====== RESPONSIVE ====== */
@media (max-width: 900px) {
  .catalog-wrapper {
    flex-direction: column;
  }

  .filters {
    width: 100%;
  }

  .tours-grid {
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  }
}

.tour-detail-container {
  max-width: 1100px;
  margin: 40px auto;
  background: #fff;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
}

.tour-hero {
  position: relative;
  height: 400px;
  overflow: hidden;
}
.tour-hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(75%);
}
.tour-hero-overlay .tour-meta {
  font-size: 1rem;
  opacity: 0.9;
}
.tour-price {
  margin-top: 10px;
  font-size: 1.4rem;
  font-weight: bold;
  color: #fff;
}

.tour-content {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 40px;
  padding: 40px;
}
.tour-description h2, .tour-description h3 {
  color: #333;
  font-weight: bold;
  margin-top: 20px;
}
.tour-description p {
  color: #444;
  line-height: 1.6;
}

.availability-box {
  background: #faf7f3;
  border-radius: 10px;
  padding: 20px;
  border: 1px solid #e2d6c4;
}
.availability-box h4 {
  margin-bottom: 15px;
  font-weight: 600;
  color: #333;
}
.availability-item {
  background: #fff;
  border-radius: 8px;
  padding: 10px;
  border: 1px solid #eee;
  margin-bottom: 10px;
}
.availability-item span {
  font-size: 0.9rem;
  color: #666;
}
.no-availability {
  color: #999;
  font-style: italic;
  text-align: center;
}

.btn-reserve {
  display: block;
  text-align: center;
  background: #b47d4e;
  color: white;
  padding: 14px;
  border-radius: 10px;
  font-weight: 600;
  margin-top: 20px;
  transition: background 0.3s ease;
  text-decoration: none;
}
.btn-reserve:hover {
  background: #9f6941;
}
.btn-reserve.disabled {
  background: #ccc;
  pointer-events: none;
  color: #777;
}


.btn {
  background: #b47d4e;
  color: white;
  text-decoration: none;
  padding: 8px 14px;
  border-radius: 6px;
  font-size: 0.9rem;
  margin-right: 6px;
  transition: 0.2s;
}
.btn:hover { background: #a36d43; }
.btn-cancel { background: #d9534f; }
.btn-cancel:hover { background: #c9302c; }

.feather {
    width: 15px;
    height: 15px;
    stroke: #d1a578;
}
.tour-meta span {
    display: inline-flex;
    align-items: center;
}
.tour-meta span > * {
    margin-right: 6px;
} 

.gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: 260px;
  grid-auto-rows: 260px;
  grid-gap: 15px;
}
.gallery img {
  width: 100%;
  border-radius: 8px;
  transition: transform 0.2s;
}
.gallery img:hover { transform: scale(1.05); }

.tabs { display: flex; gap: 1rem; border-bottom: 1px solid #ccc; }
.tab { background: none; border: none; padding: 8px 16px; cursor: pointer; font-weight: 600; }
.tab.active { border-bottom: 3px solid #b97c3f; color: #b97c3f; }
.tab-content { display: none; padding-top: 15px; }
.tab-content.active { display: block; }

.lang-float {
  position: fixed;
  bottom: 20px;
  right: 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  z-index: 9999;
}

.lang-float a {
  font-size: 1.6rem;
  text-decoration: none;
  background: #fff;
  border-radius: 50%;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.25s ease;
}

.lang-float a:hover {
  transform: scale(1.1);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.25);
}

.lang-float a.active {
  background-color: #b97c3f;
  color: #fff;
}

@media (max-width: 600px) {
  .lang-float {
    bottom: 15px;
    right: 15px;
    flex-direction: row;
  }
}

@media (max-width: 900px) {
  .tour-content {
    grid-template-columns: 1fr;
    gap: 24px;
    padding: 24px 16px 30px;
  }

  .tour-detail-container {
    margin: 24px 0;
    border-radius: 0;
  }

  .tour-hero {
    height: 260px;
  }

  .tour-hero-overlay h1 {
    font-size: 1.6rem;
  }
}

@media (max-width: 768px) {
  .catalog-wrapper {
    flex-direction: column;
    width: 100%;
    margin: 0 auto 40px;
  }

  .filters {
    width: 100%;
    margin-right: 0;
    order: -1; /* filtros arriba en mobile */
  }

  .tours-grid {
    gap: 16px;
  }

  .tour-card {
    flex: 1 1 100%;
  }
}

@media (max-width: 600px) {
  .booking-form {
    margin: 24px auto 40px;
    padding: 20px 16px;
    border-radius: 10px;
  }

  .form-box label {
    margin-top: 12px;
  }

  .form-box input,
  .form-box select {
    width: 100%;
  }
}