/*
Theme Name: RutasyPlanes
Theme URI: https://www.rutasyplanes.com
Author: RutasyPlanes
Author URI: https://www.rutasyplanes.com
Description: Tema a medida para el portal de experiencias RutasyPlanes. Home de inicio del portal.
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 7.4
License: GNU General Public License v2 or later
Text Domain: rutasyplanes
*/

/* ===========================================================
   RutasyPlanes · estilos base de la home
   El layout vive en estilos inline (fiel al diseño original).
   Aquí solo: reset, tipografía y los estados :hover / :focus.
   =========================================================== */

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: #FFFFFF;
  color: #0B2239;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { text-decoration: none; color: inherit; }

img { display: block; max-width: 100%; }

/* Transición suave en todo lo interactivo */
a, button, .card, input { transition: all .22s ease; }

/* ---------- Header ---------- */
.nav-link:hover       { color: #00B4D8 !important; }
.lang-link:hover      { background: #F4F7FA !important; color: #0B2239 !important; }
.share-link:hover     { color: #E66E00 !important; }
.btn-outline:hover    { border-color: #00B4D8 !important; color: #00B4D8 !important; }

/* ---------- Botones / pills ---------- */
.btn-primary:hover    { background: #0096B7 !important; }
.btn-orange:hover     { background: #E66E00 !important; }
.btn-reserve:hover    { background: #00B4D8 !important; color: #fff !important; }
.chip-light:hover     { background: rgba(255,255,255,0.22) !important; }
.link-more:hover      { gap: 12px !important; color: #E66E00 !important; }

/* ---------- Tarjetas ---------- */
.card-cat:hover       { box-shadow: 0 18px 40px rgba(2,62,138,0.16) !important; }
.card-dest:hover      { box-shadow: 0 20px 44px rgba(2,62,138,0.18) !important; }
.card-exp:hover       { box-shadow: 0 20px 44px rgba(2,62,138,0.15) !important; }
.card-insp:hover      { transform: translateY(-4px); }

/* ---------- Newsletter ---------- */
.news-input:focus     { border-color: #00B4D8 !important; background: #fff !important; }

/* ---------- Footer ---------- */
.social-link:hover    { background: #00B4D8 !important; }
.footer-link:hover    { color: #00B4D8 !important; }
.footer-legal:hover   { color: #fff !important; }

/* ---------- Página de ciudad: tarjetas e interacción ---------- */
.card-cat:hover      { transform: translateY(-3px); box-shadow: 0 16px 34px rgba(2,62,138,0.12) !important; }
.card-insp:hover     { background: rgba(255,255,255,0.10) !important; }

/* FAQ (acordeón con <details>) */
.ryp-faq summary::-webkit-details-marker { display: none; }
.ryp-faq[open] { box-shadow: 0 10px 26px rgba(2,62,138,0.07); }
.ryp-faq-icon { transition: transform .22s ease; }
.ryp-faq[open] .ryp-faq-icon { transform: rotate(45deg); } /* el "+" pasa a "x" */
.ryp-faq summary:hover span { color: #0288B0; }

/* Buscador del hero de la home */
.hero-search-btn:hover { background: #E66E00 !important; box-shadow: 0 10px 24px rgba(230,110,0,0.45) !important; }
@media (max-width: 600px) {
  /* Hero más compacto y cerca de la cabecera en móvil */
  .ryp-home-hero { min-height: auto !important; align-items: flex-start !important; }
  .ryp-home-hero > div:last-child { padding: 22px 0 36px !important; }
  /* Buscador estilo pastilla en una sola línea (lupa izq. + campo + botón circular) */
  .ryp-hsearch { flex-wrap: nowrap !important; gap: 8px !important; padding: 6px 6px 6px 16px !important; border-radius: 999px !important; }
  .ryp-hsearch-ico { display: inline-flex !important; font-size: 20px !important; flex: none; }
  .ryp-hsearch input { font-size: 15px !important; min-width: 0 !important; padding: 10px 2px !important; }
  .ryp-hsearch-txt { display: none; }
  .ryp-hsearch .hero-search-btn { width: 46px; height: 46px; padding: 0 !important; border-radius: 50% !important; justify-content: center; flex: none; box-shadow: 0 6px 16px rgba(255,122,0,0.4) !important; }
  .ryp-hsearch .hero-search-btn i { font-size: 19px !important; }
}

/* Buscador del menú en fichas de ciudad (naranja) */
.ryp-header-busca {
  display: flex;
  align-items: center;
  gap: 7px;
  background: #fff;
  border: 1.5px solid #FF7A00;
  border-radius: 11px;
  padding: 4px 4px 4px 12px;
}
.ryp-header-busca i { color: #FF7A00; font-size: 18px; }
.ryp-header-busca input {
  border: none;
  outline: none;
  background: transparent;
  font-family: inherit;
  font-size: 14px;
  color: #0B2239;
  width: 150px;
  max-width: 32vw;
}
.ryp-header-busca button {
  background: #FF7A00;
  color: #fff;
  border: none;
  font-family: inherit;
  font-weight: 700;
  font-size: 13.5px;
  padding: 8px 14px;
  border-radius: 8px;
  cursor: pointer;
  white-space: nowrap;
}
.ryp-header-busca button:hover { background: #E66E00; }
@media (max-width: 860px) {
  .ryp-header-busca { width: 100%; margin-top: 6px; }
  .ryp-header-busca input { flex: 1; width: auto; max-width: none; }
}

/* Sección "Guía de la ciudad": rótulo+título a la izquierda, texto a la derecha */
.ryp-guia { display: grid; gap: 32px; align-items: start; }
@media (min-width: 860px) {
  .ryp-guia { grid-template-columns: 330px minmax(0, 1fr); gap: 56px; }
}

/* Texto SEO largo de la ficha de ciudad */
.ryp-ciudad-texto p { font-size: 17px; line-height: 1.75; color: #3D4A5C; margin: 0 0 16px; }
.ryp-ciudad-texto p:last-child { margin-bottom: 0; }
.ryp-ciudad-texto h2, .ryp-ciudad-texto h3 { color: #0B2239; margin: 24px 0 10px; }
.ryp-ciudad-texto ul { margin: 0 0 16px; padding-left: 22px; color: #3D4A5C; font-size: 17px; line-height: 1.7; }
.ryp-ciudad-texto li { margin-bottom: 7px; }

/* Migas de pan (breadcrumbs) */
.ryp-breadcrumbs { background: #F8F9FA; border-bottom: 1px solid #EEF2F6; }
.ryp-bc-inner { width: min(1280px, 100% - 48px); margin-inline: auto; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 13px 0; font-size: 13.5px; color: #6C757D; }
.ryp-breadcrumbs a { color: #0288B0; font-weight: 600; }
.ryp-breadcrumbs a:hover { color: #E66E00; }
.ryp-breadcrumbs i { font-size: 12px; color: #AEB8C2; }
.ryp-breadcrumbs span[aria-current] { color: #0B2239; font-weight: 700; }

/* Buscador secundario del hero de ciudad (desplegable, sin JS) */
.ryp-busca { max-width: 520px; margin: 16px auto 0; }
.ryp-busca summary {
  list-style: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: #fff;
  font-weight: 600;
  font-size: 15px;
  background: rgba(255,255,255,0.14);
  border: 1px solid rgba(255,255,255,0.3);
  padding: 12px 22px;
  border-radius: 13px;
  backdrop-filter: blur(6px);
}
.ryp-busca summary::-webkit-details-marker { display: none; }
.ryp-busca summary:hover { background: rgba(255,255,255,0.24); }
.ryp-busca[open] summary { margin-bottom: 12px; }

/* Formulario de contacto */
.ryp-input {
  width: 100%;
  font-family: inherit;
  font-size: 16px;
  color: #0B2239;
  background: #F8F9FA;
  border: 1.5px solid #E1E8EE;
  border-radius: 12px;
  padding: 13px 15px;
  outline: none;
  transition: border-color .2s ease, background .2s ease;
}
.ryp-input:focus { border-color: #FF7A00; background: #fff; }
.ryp-input::placeholder { color: #9AA7B2; }
.ryp-form-enviar:hover { background: #E66E00 !important; }
.ryp-form-enviar:disabled { opacity: .45; cursor: not-allowed; box-shadow: none; }
.ryp-form-enviar:disabled:hover { background: #FF7A00 !important; }

/* Ficha de producto: galería + lightbox */
.ryp-galeria { display: grid; grid-template-columns: 2fr 1fr 1fr; grid-template-rows: 1fr 1fr; gap: 10px; border-radius: 20px; overflow: hidden; aspect-ratio: 16 / 8; }
.ryp-galeria-item { position: relative; border: none; padding: 0; cursor: pointer; background-size: cover; background-position: center; background-color: #e0eaf0; transition: filter .2s ease; }
.ryp-galeria-item:hover { filter: brightness(1.05); }
.ryp-galeria-main { grid-row: 1 / 3; }
.ryp-galeria-mas { position: absolute; right: 12px; bottom: 12px; display: inline-flex; align-items: center; gap: 6px; background: rgba(11,34,57,0.82); color: #fff; font-size: 13px; font-weight: 700; padding: 8px 13px; border-radius: 10px; }
@media (max-width: 700px) {
  .ryp-galeria { grid-template-columns: 1fr 1fr; grid-template-rows: auto; aspect-ratio: auto; gap: 8px; }
  .ryp-galeria-main { grid-column: 1 / 3; aspect-ratio: 16 / 10; }
  .ryp-galeria-item:not(.ryp-galeria-main) { aspect-ratio: 1 / 1; }
}
.ryp-lightbox { position: fixed; inset: 0; z-index: 9999; background: rgba(7,16,26,0.93); display: flex; align-items: center; justify-content: center; padding: 20px; }
.ryp-lightbox[hidden] { display: none; }
.ryp-lightbox img { max-width: 92vw; max-height: 86vh; border-radius: 10px; object-fit: contain; }
.ryp-lb-btn { position: absolute; background: rgba(255,255,255,0.16); border: none; color: #fff; width: 48px; height: 48px; border-radius: 50%; font-size: 22px; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.ryp-lb-btn:hover { background: rgba(255,255,255,0.28); }
.ryp-lb-close { top: 18px; right: 18px; }
.ryp-lb-prev { left: 14px; top: 50%; transform: translateY(-50%); }
.ryp-lb-next { right: 14px; top: 50%; transform: translateY(-50%); }

/* Ficha de producto: layout + comparador + sticky */
.ryp-prod { display: grid; gap: 32px; align-items: start; }
@media (min-width: 980px) {
  .ryp-prod { grid-template-columns: minmax(0, 1fr) 360px; }
  .ryp-prod-aside { position: sticky; top: 96px; }
}
@media (max-width: 979px) { .ryp-prod-aside { order: -1; } }
.ryp-oferta { display: flex; align-items: center; justify-content: space-between; gap: 12px; border: 1.5px solid #E7EEF3; border-radius: 12px; padding: 11px 14px; transition: border-color .2s ease, box-shadow .2s ease; }
.ryp-oferta:hover { border-color: #FF7A00; box-shadow: 0 6px 16px rgba(255,122,0,0.12); }
.ryp-oferta-cta { display: inline-flex; align-items: center; gap: 4px; color: #FF7A00; font-weight: 700; font-size: 12.5px; }

/* Barra de reserva fija (solo móvil) */
.ryp-prod-barra { display: none; }
@media (max-width: 979px) {
  .ryp-prod-barra { display: flex; align-items: center; justify-content: space-between; gap: 14px; position: fixed; left: 0; right: 0; bottom: 0; z-index: 60; background: #fff; border-top: 1px solid #EEF2F6; box-shadow: 0 -8px 24px rgba(4,20,34,0.10); padding: 10px 18px; }
  body.page-template-page-producto, body.single-evento { padding-bottom: 78px; }
}

/* Paginación (resultados de búsqueda) */
.pagination .nav-links { display: inline-flex; gap: 8px; flex-wrap: wrap; justify-content: center; }
.pagination .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 12px;
  border-radius: 10px;
  border: 1.5px solid #E1E8EE;
  color: #0B2239;
  font-weight: 700;
  font-size: 14px;
}
.pagination .page-numbers.current { background: #00B4D8; border-color: #00B4D8; color: #fff; }
.pagination .page-numbers:hover { border-color: #00B4D8; color: #0288B0; }
.pagination .page-numbers.dots { border: none; }

/* La barra de admin de WP no debe tapar el header sticky */
body.admin-bar header { top: 32px; }
@media screen and (max-width: 782px) { body.admin-bar header { top: 46px; } }

/* ---------- Navegación móvil (menú hamburguesa) ---------- */
@media (max-width: 860px) {
  .ryp-burger { display: inline-flex !important; }

  .ryp-nav {
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    flex-direction: column;
    align-items: stretch !important;
    gap: 0 !important;
    background: #fff;
    border-bottom: 1px solid #EEF2F6;
    box-shadow: 0 14px 28px rgba(2, 62, 138, 0.10);
    padding: 6px 24px 14px;
    display: none !important;
  }
  .ryp-nav.is-open { display: flex !important; }

  .ryp-nav a {
    padding: 14px 2px;
    font-size: 16px;
    border-top: 1px solid #F0F3F6;
  }
  .ryp-nav a:first-child { border-top: none; }
}

/* ---------- Rejilla de categorías: filas centradas (incluida la última) ---------- */
.cat-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 18px;
}
.cat-grid > a {
  flex: 1 1 150px;
  max-width: 210px;
}
@media (max-width: 600px) {
  .cat-grid > a { max-width: none; }
}

/* ---------- Botón "Buscar" del hero centrado en móvil ---------- */
@media (max-width: 600px) {
  .hero-search-btn {
    margin-inline: auto;
    justify-content: center;
  }
}
