/* Layout idea: portada verde pino con la fachada real; galería en columnas con filtros; acento mango. */
:root {
  --bg: #f4eee3;
  --surface: #fffaf2;
  --ink: #2a1c14;
  --muted: #6a5a4c;
  --line: #e0d3bf;
  --pine: #4a2a1a;        /* nogal: nav, portada y reservas */
  --pine-deep: #2e1a10;
  --mango: #b4552f;       /* terracota de las tejas: botones y detalles */
  --on-mango: #fbf3e6;
  --accent-soft: #e8a98b; /* arcilla clara para texto sobre nogal */
  --mango-text: #9a4423;
  --on-pine: #f8efe0;
  --font-display: "Caprasimo", "Rockwell", Georgia, serif;
  --font-body: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #1d130d; --surface: #2a1c13; --ink: #f3e9da; --muted: #c9b8a3;
    --line: #46321f; --pine-deep: #140b07; --mango-text: #e8a98b;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #1d130d; --surface: #2a1c13; --ink: #f3e9da; --muted: #c9b8a3;
  --line: #46321f; --pine-deep: #140b07; --mango-text: #e8a98b;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; }
html { background: var(--bg); }
body { margin: 0; overflow-x: clip; background: transparent; color: var(--ink); font-family: var(--font-body); font-size: 17px; line-height: 1.6; }
h1, h2, h3 { font-family: var(--font-display); font-weight: 400; line-height: 1.05; margin: 0; text-wrap: balance; }
p { margin: 0; }
a { color: inherit; }
img { max-width: 100%; height: auto; display: block; }
:focus-visible { outline: 3px solid var(--mango); outline-offset: 3px; border-radius: 4px; }
.wrap { width: min(1080px, 100% - 32px); margin-inline: auto; }

.draft { background: var(--mango); color: var(--on-mango); font-size: 14px; font-weight: 600; text-align: center; padding: 6px 16px; }

/* Nav */
.nav { position: sticky; top: 0; z-index: 50; background: var(--pine-deep); color: var(--on-pine); box-shadow: 0 2px 16px rgba(0, 0, 0, .28); }
.nav .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-block: 14px; flex-wrap: wrap; }
.brand { font-family: var(--font-display); font-size: 22px; text-decoration: none; }
.nav ul { display: flex; gap: 22px; list-style: none; margin: 0; padding: 0; flex-wrap: wrap; font-size: 15px; font-weight: 500; }
.nav a { text-decoration: none; opacity: .88; }
.nav a:hover { opacity: 1; text-decoration: underline; text-decoration-color: var(--accent-soft); text-underline-offset: 5px; }

/* Hero */
.hero { background: var(--pine); color: var(--on-pine); }
.hero .wrap { display: grid; grid-template-columns: 1fr 1.15fr; gap: 40px; align-items: center; padding-block: 48px; }
.hero-copy { display: flex; flex-direction: column; gap: 22px; align-items: flex-start; }
.kicker { font-size: 14px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--accent-soft); }
.hero h1 { font-size: clamp(54px, 8vw, 96px); letter-spacing: -.01em; }
.hero h1 span { color: var(--accent-soft); }
.hero p.lead { font-size: 19px; max-width: 42ch; opacity: .92; }
.hero-photo { border-radius: 20px; overflow: hidden; box-shadow: 0 24px 60px rgba(0,0,0,.35); }
.hero-photo img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.btn { display: inline-block; background: var(--mango); color: var(--on-mango); font-weight: 700; padding: 14px 24px; border-radius: 999px; text-decoration: none; border: 0; cursor: pointer; font-family: inherit; font-size: 16px; transition: transform .15s ease; }
.btn:hover { transform: translateY(-2px); }
.btn.ghost { background: transparent; color: inherit; border: 2px solid currentColor; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* Facts */
.facts { background: var(--surface); color: var(--ink); border-block: 1px solid var(--line); }
.facts ul { list-style: none; margin: 0; padding: 20px 0; display: flex; flex-wrap: wrap; gap: 8px 32px; justify-content: space-between; font-weight: 600; font-size: 14px; letter-spacing: .1em; text-transform: uppercase; }
.facts li + li::before { content: ""; display: inline-block; width: 5px; height: 5px; margin-right: 32px; vertical-align: middle; border-radius: 50%; background: var(--mango); }

section { padding-block: 72px; }
.eyebrow { font-size: 13px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--mango-text); margin-bottom: 10px; }
h2 { font-size: clamp(34px, 5vw, 52px); }

/* About */
.about { display: grid; grid-template-columns: 1fr 1.2fr; gap: 48px; }
.about .text { display: flex; flex-direction: column; gap: 16px; color: var(--muted); font-size: 18px; }
.about .text strong { color: var(--ink); }
.duo { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 40px; }
.duo img { width: 100%; height: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 16px; }

/* Amenities */
.amen { display: grid; grid-template-columns: repeat(auto-fit, minmax(225px, 1fr)); gap: 14px; margin-top: 32px; padding: 0; list-style: none; }
.amen li { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 18px 20px; display: flex; gap: 12px; align-items: flex-start; }
.amen li::before { content: ""; flex: none; width: 12px; height: 12px; margin-top: 7px; border-radius: 60% 40% 60% 40%; background: var(--mango); transform: rotate(-20deg); }
.amen b { display: block; }
.amen span { color: var(--muted); font-size: 15px; }

/* Gallery */
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 24px; }
.chip { font: inherit; font-size: 15px; font-weight: 600; padding: 8px 16px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); cursor: pointer; }
.chip[aria-pressed="true"] { background: var(--pine); color: var(--on-pine); border-color: var(--pine); }
.gallery { column-count: 3; column-gap: 12px; margin-top: 24px; }
.gallery figure { margin: 0 0 12px; break-inside: avoid; }
.gallery figure[hidden] { display: none; }
.gallery button { display: block; width: 100%; padding: 0; border: 0; background: none; cursor: zoom-in; border-radius: 12px; overflow: hidden; }
.gallery img { width: 100%; height: auto; transition: transform .3s ease; }
.gallery button:hover img { transform: scale(1.03); }

/* Fondo de fotos fijo: cambia con un fundido según la sección en pantalla */
.bg { position: fixed; inset: 0; z-index: -1; background: var(--pine-deep); }
.bg-layer { position: absolute; inset: 0; background-size: cover; background-position: center; opacity: 0; transition: opacity 1.4s ease; }
.bg-layer.is-on { opacity: 1; }
main > section:not(.hero) > .wrap { background: var(--bg); background: color-mix(in srgb, var(--bg) 90%, transparent); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); border-radius: 24px; padding: clamp(20px, 4vw, 44px); }
main > section#reservar > .wrap { background: none; backdrop-filter: none; -webkit-backdrop-filter: none; padding: 0; border-radius: 0; }
main > section:not(.hero) { padding-block: 56px; }
footer { background: var(--bg); }
@media (prefers-reduced-motion: reduce) { .bg-layer { transition: none; } }

/* Lightbox */
dialog#lb { border: 0; padding: 0; background: transparent; max-width: 100vw; max-height: 100vh; width: 100%; height: 100%; color: #fff; }
dialog#lb::backdrop { background: rgba(14, 8, 5, .92); }
.lb-body { height: 100%; display: grid; grid-template-rows: 1fr auto; gap: 12px; padding: 16px; }
.lb-body img { margin: auto; max-height: calc(100vh - 110px); width: auto; max-width: 100%; object-fit: contain; border-radius: 8px; }
.lb-cap { text-align: center; font-size: 15px; opacity: .9; }
.lb-btn { position: fixed; background: rgba(255,255,255,.14); color: #fff; border: 0; width: 46px; height: 46px; border-radius: 50%; font-size: 22px; cursor: pointer; }
.lb-btn:hover { background: rgba(255,255,255,.26); }
.lb-close { top: 16px; right: 16px; }
.lb-prev { left: 12px; top: 50%; }
.lb-next { right: 12px; top: 50%; }

/* Place */
.place { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; }
.place ul { list-style: none; margin: 18px 0 0; padding: 0; display: flex; flex-direction: column; }
.place li { display: flex; justify-content: space-between; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.place li span:last-child { color: var(--muted); text-align: right; }
.place p { color: var(--muted); margin-top: 16px; font-size: 18px; }

/* Booking */
.book { background: var(--pine); color: var(--on-pine); border-radius: 24px; padding: clamp(24px, 5vw, 56px); display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }
.book .eyebrow { color: var(--accent-soft); }
.book p { opacity: .9; margin-top: 14px; }
.book .num { font-weight: 700; font-size: 20px; margin-top: 18px; opacity: 1; }
.book .num a { color: inherit; text-underline-offset: 4px; }
form { display: flex; flex-direction: column; gap: 14px; }
label { display: flex; flex-direction: column; gap: 6px; font-size: 14px; font-weight: 600; }
input { width: 100%; max-width: 100%; min-width: 0; min-height: 48px; -webkit-appearance: none; appearance: none; font: inherit; font-size: 16px; padding: 12px 14px; border-radius: 10px; border: 1px solid transparent; background: #fbf6ec; color: #2a1c14; }
.row { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: 12px; }
form .btn { text-align: center; margin-top: 4px; }

.prices { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px 40px; }
.prices-copy { display: flex; flex-direction: column; gap: 12px; max-width: 52ch; }
.prices-copy p:not(.eyebrow) { color: var(--muted); font-size: 18px; }

/* Ubicación */
.where-head { display: flex; flex-direction: column; gap: 12px; max-width: 56ch; margin-bottom: 28px; }
.where-head p:not(.eyebrow) { color: var(--muted); font-size: 18px; }
.map { display: block; width: 100%; height: 420px; border: 0; border-radius: 16px; background: var(--line); }
.where-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px; margin-top: 24px; }
.where-foot .plus { margin: 0; font-size: 14px; line-height: 1.5; color: var(--muted); letter-spacing: .04em; text-transform: uppercase; }
.where-foot .plus strong { display: block; margin-top: 2px; font-size: 17px; letter-spacing: .02em; text-transform: none; color: var(--ink); }
.where-actions { display: flex; flex-wrap: wrap; gap: 10px; }

footer { padding: 36px 0 56px; color: var(--muted); font-size: 15px; }
footer .wrap { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }

@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } .btn, .gallery img { transition: none; } }
@media (max-width: 900px) { .gallery { column-count: 2; } }
@media (max-width: 760px) {
  body { font-size: 16px; }
  .row { grid-template-columns: minmax(0, 1fr); }
  .facts ul { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 16px; font-size: 12px; letter-spacing: .08em; padding: 18px 0; }
  .facts li + li::before { display: none; }
  .facts li:nth-child(3) { grid-column: 1 / -1; }
  html { scroll-padding-top: 96px; }
  .nav .wrap { flex-direction: column; align-items: flex-start; gap: 6px; padding-block: 10px; }
  .brand { font-size: 20px; }
  .nav nav { width: 100%; }
  .nav ul { flex-wrap: nowrap; gap: 18px; font-size: 14px; overflow-x: auto; white-space: nowrap; scrollbar-width: none; padding-bottom: 2px; }
  .nav ul::-webkit-scrollbar { display: none; }
  .hero .wrap, .about, .place, .book { grid-template-columns: minmax(0, 1fr); }
  .hero .wrap { padding-block: 32px; gap: 28px; }
  .about, .place { gap: 24px; }
  .map { height: 320px; }
  section { padding-block: 52px; }
  .duo { margin-top: 28px; }
  .facts ul { justify-content: flex-start; }
}
