/* =========================================================
   Encuadre · Estilos
   ========================================================= */
:root {
  --bg: #0d0f14;
  --bg-2: #141821;
  --card: #181d28;
  --card-2: #1f2533;
  --line: rgba(255, 255, 255, 0.08);
  --text: #f3f1ec;
  --muted: #9aa3b5;
  --accent: #ff7a45;
  --accent-2: #ff4d8d;
  --gold: #ffc35a;
  --blue: #5c9dff;
  --teal: #22b8cf;
  --green: #3ecf8e;
  --grad: linear-gradient(120deg, #ffb347 0%, #ff7a45 45%, #ff4d8d 100%);
  --radius: 18px;
  --shadow: 0 20px 60px rgba(0, 0, 0, 0.45);
  --font-display: "Bricolage Grotesque", system-ui, sans-serif;
  --font: "Inter", system-ui, -apple-system, Segoe UI, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
button { font: inherit; color: inherit; cursor: pointer; }
[hidden] { display: none !important; }
h1, h2, h3 { font-family: var(--font-display); letter-spacing: -0.02em; line-height: 1.1; margin: 0; }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 1px solid var(--line); background: var(--card-2);
  padding: 12px 18px; border-radius: 999px; font-weight: 600;
  transition: transform .15s ease, background .2s ease, box-shadow .2s ease, border-color .2s;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); border-color: rgba(255,255,255,.18); }
.btn:active { transform: translateY(0) scale(.98); }
.btn-primary {
  background: var(--grad); border: none; color: #1a0f0a; font-weight: 700;
  box-shadow: 0 10px 30px rgba(255, 110, 80, .35);
}
.btn-primary:hover { box-shadow: 0 14px 40px rgba(255, 110, 80, .5); }
.btn-ghost { background: transparent; }
.btn-loc { background: rgba(92, 157, 255, .12); border-color: rgba(92, 157, 255, .35); color: #cfe0ff; }
.btn-dice { padding: 8px 14px; font-size: 14px; background: rgba(255, 195, 90, .12); border-color: rgba(255, 195, 90, .35); color: #ffe2a8; }
.btn-dice:hover { transform: translateY(-1px) rotate(-2deg); }
.badge {
  min-width: 22px; height: 22px; padding: 0 6px; border-radius: 999px;
  background: var(--accent-2); color: #fff; font-size: 12px; display: inline-grid; place-items: center;
}

.pulse-dot {
  width: 10px; height: 10px; border-radius: 50%; background: var(--blue); position: relative;
}
.pulse-dot::after {
  content: ""; position: absolute; inset: 0; border-radius: 50%; background: var(--blue);
  animation: pulse 1.8s ease-out infinite;
}
@keyframes pulse { from { transform: scale(1); opacity: .7; } to { transform: scale(3); opacity: 0; } }

/* ---------- Cabecera ---------- */
.topbar {
  position: sticky; top: 0; z-index: 1100;
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px clamp(16px, 4vw, 40px);
  background: rgba(13, 15, 20, .72); backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-family: var(--font-display); font-weight: 800; font-size: 22px; }
.aperture { width: 32px; height: 32px; transition: transform .6s cubic-bezier(.3,1.4,.5,1); }
.brand:hover .aperture { transform: rotate(120deg); }
.topnav { display: flex; align-items: center; gap: 12px; }
.units { display: flex; gap: 6px; }
.unit-toggle { display: inline-flex; background: var(--bg-2); border: 1px solid var(--line); border-radius: 999px; padding: 3px; }
.unit-toggle button {
  border: none; background: transparent; color: var(--muted); font-size: 13px; font-weight: 700;
  padding: 5px 10px; border-radius: 999px; transition: background .2s, color .2s;
}
.unit-toggle button:hover { color: var(--text); }
.unit-toggle button.active { background: #fff; color: #111; }
.navlink { text-decoration: none; color: var(--muted); font-weight: 500; padding: 8px 10px; }
.navlink:hover { color: var(--text); }

/* ---------- Portada ---------- */
.hero {
  position: relative; overflow: hidden;
  padding: clamp(60px, 10vw, 120px) clamp(16px, 4vw, 40px) clamp(50px, 8vw, 90px);
  min-height: 78vh; display: grid; place-items: center;
}
.hero-bg { position: absolute; inset: 0; pointer-events: none; }
.blob { position: absolute; border-radius: 50%; filter: blur(80px); opacity: .45; animation: float 14s ease-in-out infinite; }
.b1 { width: 480px; height: 480px; background: #ff7a45; top: -120px; left: -120px; }
.b2 { width: 420px; height: 420px; background: #ff4d8d; bottom: -160px; right: -80px; animation-delay: -5s; }
.b3 { width: 340px; height: 340px; background: #5c9dff; top: 30%; left: 55%; opacity: .25; animation-delay: -9s; }
@keyframes float { 0%,100% { transform: translate(0,0); } 50% { transform: translate(40px, -30px); } }

.polaroid {
  position: absolute; width: 130px; padding: 10px 10px 8px; background: #f7f3ea; color: #333;
  border-radius: 6px; box-shadow: var(--shadow); text-align: center; font-family: var(--font-display);
  animation: bob 7s ease-in-out infinite;
}
.polaroid .pic { height: 100px; border-radius: 3px; display: grid; place-items: center; font-size: 48px; background: linear-gradient(135deg, #2a3142, #3a2a3e); }
.polaroid small { display: block; margin-top: 6px; font-size: 13px; font-weight: 700; }
.p1 { top: 14%; left: 6%; --r: -8deg; }
.p2 { top: 18%; right: 7%; --r: 7deg; animation-delay: -2s; }
.p3 { bottom: 10%; left: 10%; --r: 5deg; animation-delay: -4s; }
.p4 { bottom: 14%; right: 11%; --r: -6deg; animation-delay: -1s; }
@keyframes bob { 0%,100% { transform: rotate(var(--r)) translateY(0); } 50% { transform: rotate(var(--r)) translateY(-12px); } }

.hero-inner { position: relative; max-width: 820px; width: 100%; text-align: center; }
.eyebrow {
  display: inline-block; margin: 0 0 18px; padding: 6px 14px; border-radius: 999px;
  background: rgba(255,255,255,.06); border: 1px solid var(--line); color: #ffd9c2; font-weight: 600; font-size: 14px;
}
.eyebrow.small { margin-bottom: 6px; padding: 3px 10px; font-size: 12px; }
.hero h1 { font-size: clamp(44px, 8vw, 88px); font-weight: 800; }
.grad { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.lead { color: #c7cdd9; font-size: clamp(16px, 2vw, 19px); max-width: 640px; margin: 18px auto 34px; }

.search-card {
  background: rgba(24, 29, 40, .85); backdrop-filter: blur(10px);
  border: 1px solid var(--line); border-radius: 24px; padding: 14px;
  box-shadow: var(--shadow); text-align: left;
}
.search-row { display: flex; gap: 10px; align-items: center; }
.search-row.second { margin-top: 12px; justify-content: space-between; flex-wrap: wrap; }
.input-wrap { position: relative; flex: 1; }
.input-icon { position: absolute; left: 16px; top: 50%; transform: translateY(-50%); opacity: .7; }
#placeInput {
  width: 100%; padding: 15px 16px 15px 46px; border-radius: 16px;
  border: 1px solid var(--line); background: var(--bg-2); color: var(--text); font-size: 16px; outline: none;
  transition: border-color .2s, box-shadow .2s;
}
#placeInput:focus { border-color: rgba(255,122,69,.6); box-shadow: 0 0 0 4px rgba(255,122,69,.15); }
.suggestions {
  position: absolute; z-index: 50; top: calc(100% + 6px); left: 0; right: 0; margin: 0; padding: 6px; list-style: none;
  background: var(--card-2); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow); max-height: 300px; overflow: auto;
}
.suggestions li { padding: 10px 12px; border-radius: 10px; cursor: pointer; font-size: 14px; color: #d8dde7; }
.suggestions li strong { display: block; color: var(--text); font-size: 15px; }
.suggestions li:hover, .suggestions li.active { background: rgba(255,255,255,.06); }

.radius { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.radius-label { color: var(--muted); font-size: 14px; margin-right: 4px; }
.pill {
  border: 1px solid var(--line); background: transparent; padding: 7px 13px; border-radius: 999px; font-size: 14px; color: #cfd5e1;
  transition: all .2s;
}
.pill:hover { border-color: rgba(255,255,255,.25); }
.pill.active { background: #fff; color: #111; border-color: #fff; font-weight: 700; }

.examples { margin-top: 22px; display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; align-items: center; color: var(--muted); font-size: 14px; }
.chip-ex { border: 1px dashed rgba(255,255,255,.2); background: transparent; padding: 6px 12px; border-radius: 999px; color: #dfe3ea; font-size: 14px; }
.chip-ex:hover { border-style: solid; border-color: var(--accent); color: #fff; }

/* ---------- Resultados ---------- */
.results { scroll-margin-top: 64px; padding: 28px clamp(16px, 4vw, 40px) 40px; border-top: 1px solid var(--line); background: linear-gradient(180deg, var(--bg-2), var(--bg)); }
.results-head { display: flex; justify-content: space-between; gap: 24px; align-items: flex-end; flex-wrap: wrap; }
.where h2 { font-size: clamp(26px, 4vw, 40px); }
.meta { color: var(--muted); margin: 6px 0 0; font-size: 14px; }

.conditions { display: flex; gap: 16px; align-items: stretch; flex-wrap: wrap; flex: 1; justify-content: flex-end; min-width: 300px; }
.weather {
  display: flex; align-items: center; gap: 12px; padding: 10px 16px; border-radius: 16px;
  background: var(--card); border: 1px solid var(--line); min-width: 190px;
}
.weather .w-emoji { font-size: 32px; }
.weather .w-temp { font-family: var(--font-display); font-size: 24px; font-weight: 700; }
.weather .w-desc { font-size: 13px; color: var(--muted); }

.lightline { flex: 1; max-width: 560px; min-width: 280px; padding: 12px 16px; border-radius: 16px; background: var(--card); border: 1px solid var(--line); }
.lightline-bar { position: relative; height: 16px; border-radius: 999px; background: #10131b; overflow: visible; }
.lightline-bar .seg-l { position: absolute; top: 0; bottom: 0; }
.lightline-bar .seg-l.day { background: linear-gradient(90deg, #ffe3a3, #fff6db, #ffe3a3); }
.lightline-bar .seg-l.golden { background: var(--gold); }
.lightline-bar .seg-l.blue { background: #3d6fd6; }
.lightline-bar .now {
  position: absolute; top: -6px; bottom: -6px; width: 3px; background: #fff; border-radius: 2px; z-index: 3;
  box-shadow: 0 0 0 3px rgba(255,77,141,.6);
}
.lightline-bar .now::after {
  content: "ahora"; position: absolute; top: -20px; left: 50%; transform: translateX(-50%);
  font-size: 11px; font-weight: 700; color: #ffb3cd;
}
.lightline-legend { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 10px; font-size: 12.5px; color: #c9cfdb; }
.lightline-legend b { color: var(--text); font-weight: 600; }
.lightline-legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 5px; vertical-align: -1px; }

.now-tip {
  margin: 18px 0; padding: 14px 18px; border-radius: 16px;
  background: linear-gradient(90deg, rgba(255,122,69,.14), rgba(255,77,141,.08));
  border: 1px solid rgba(255,122,69,.3); font-weight: 500;
}
.now-tip:empty { display: none; }

.scan {
  display: flex; align-items: center; gap: 10px; margin: -6px 0 16px; font-size: 14px; color: #c9d6ff;
}
.scan .spin { width: 16px; height: 16px; border-radius: 50%; border: 2px solid rgba(92,157,255,.25); border-top-color: var(--blue); animation: spin 0.8s linear infinite; }
.scan.ok { color: #9be8c1; }
.scan.warn { color: #ffd59a; }
.scan button { border: 1px solid var(--line); background: var(--card-2); border-radius: 999px; padding: 4px 12px; font-size: 13px; }

.layout { display: grid; grid-template-columns: minmax(340px, 440px) 1fr; gap: 18px; height: calc(100vh - 120px); min-height: 560px; }
.panel { display: flex; flex-direction: column; min-height: 0; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.filters { padding: 14px; border-bottom: 1px solid var(--line); display: grid; gap: 12px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip {
  border: 1px solid var(--line); background: var(--card-2); padding: 6px 11px; border-radius: 999px; font-size: 13.5px; color: #d3d8e2;
  transition: all .15s;
}
.chip .n { opacity: .55; margin-left: 3px; font-size: 12px; }
.chip.active { background: #fff; color: #111; border-color: #fff; font-weight: 600; }
.chip.active .n { opacity: .7; }
.filter-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.segmented { display: inline-flex; background: var(--bg-2); border: 1px solid var(--line); border-radius: 999px; padding: 3px; }
.seg { white-space: nowrap; border: none; background: transparent; padding: 6px 11px; border-radius: 999px; font-size: 13px; color: var(--muted); font-weight: 600; }
.seg.active { background: var(--card-2); color: var(--text); box-shadow: 0 2px 8px rgba(0,0,0,.3); }
select {
  background: var(--bg-2); color: var(--text); border: 1px solid var(--line); border-radius: 999px; padding: 7px 12px; font: inherit; font-size: 13px;
}
.count { color: var(--muted); font-size: 13.5px; }

.spot-list { list-style: none; margin: 0; padding: 10px; overflow-y: auto; flex: 1; display: grid; gap: 10px; align-content: start; }
.spot-list::-webkit-scrollbar { width: 8px; }
.spot-list::-webkit-scrollbar-thumb { background: rgba(255,255,255,.1); border-radius: 8px; }

.spot {
  display: grid; grid-template-columns: 84px 1fr; gap: 12px; padding: 10px; border-radius: 14px;
  background: var(--bg-2); border: 1px solid transparent; cursor: pointer; transition: border-color .15s, transform .15s, background .15s;
  animation: rise .35s ease both;
}
@keyframes rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.spot:hover { border-color: rgba(255,255,255,.15); transform: translateX(2px); }
.spot.active { border-color: var(--accent); background: #1d1a20; }
.thumb {
  width: 84px; height: 84px; border-radius: 10px; background-size: cover; background-position: center;
  display: grid; place-items: center; font-size: 36px; position: relative; overflow: hidden;
}
.spot-info { min-width: 0; }
.spot-top { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); margin-bottom: 2px; flex-wrap: wrap; }
.tag-pop, .tag-gem { font-size: 11px; font-weight: 700; padding: 2px 7px; border-radius: 999px; }
.tag-pop { background: rgba(255,122,69,.16); color: #ffb08a; }
.tag-gem { background: rgba(92,157,255,.15); color: #a9c8ff; }
.spot h3 { font-family: var(--font); font-size: 15.5px; font-weight: 700; letter-spacing: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.spot .types { margin: 4px 0 0; font-size: 12.5px; color: #b9c0ce; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.spot .stars { font-size: 12px; color: var(--gold); letter-spacing: 1px; margin-top: 3px; }
.spot .stars span { color: var(--muted); letter-spacing: 0; margin-left: 4px; }

.empty { text-align: center; padding: 40px 20px; color: var(--muted); }
.empty .big { font-size: 46px; }

.map-wrap { position: relative; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); }
#map { width: 100%; height: 100%; background: #1a1f2a; }
.btn-float { position: absolute; right: 14px; bottom: 24px; z-index: 500; width: 46px; height: 46px; padding: 0; font-size: 20px; background: var(--card); box-shadow: var(--shadow); }

/* Mapa oscuro: los mapas de OpenStreetMap invertidos */
.tiles-dark { filter: invert(1) hue-rotate(180deg) brightness(.92) contrast(.88) saturate(.6); }
.cluster {
  border-radius: 50%; display: grid; place-items: center; color: #1a0f0a; font-weight: 800; font-size: 14px;
  background: var(--grad); border: 3px solid rgba(255,255,255,.9); box-shadow: 0 0 0 6px rgba(255,122,69,.25), 0 8px 20px rgba(0,0,0,.4);
  transition: transform .15s;
}
.cluster:hover { transform: scale(1.08); }

/* Marcadores */
.marker {
  width: 38px; height: 38px; border-radius: 50% 50% 50% 4px; transform: rotate(-45deg);
  display: grid; place-items: center; border: 2px solid #fff; box-shadow: 0 6px 16px rgba(0,0,0,.45);
  transition: transform .2s;
}
.marker span { transform: rotate(45deg); font-size: 18px; }
.marker.gem { border-style: dashed; }
.marker.hi { transform: rotate(-45deg) scale(1.3); z-index: 999; }
.me-marker { width: 22px; height: 22px; border-radius: 50%; background: var(--accent-2); border: 4px solid #fff; box-shadow: 0 0 0 6px rgba(255,77,141,.3); }
.leaflet-popup-content-wrapper { background: var(--card); color: var(--text); border-radius: 14px; box-shadow: var(--shadow); }
.leaflet-popup-tip { background: var(--card); }
.leaflet-popup-content { margin: 12px 14px; font-family: var(--font); }
.leaflet-container a.leaflet-popup-close-button { color: var(--muted); }
.pop h4 { margin: 0 0 4px; font-size: 15px; }
.pop p { margin: 0 0 8px; color: var(--muted); font-size: 13px; }
.pop button { border: none; background: var(--grad); color: #1a0f0a; font-weight: 700; padding: 7px 12px; border-radius: 999px; font-size: 13px; }
.leaflet-control-attribution { background: rgba(13,15,20,.7) !important; color: #8a93a5 !important; }
.leaflet-control-attribution a { color: #c2c9d6 !important; }
.leaflet-bar a { background: var(--card) !important; color: var(--text) !important; border-color: var(--line) !important; }

/* ---------- Cómo funciona ---------- */
.how { padding: 80px clamp(16px, 4vw, 40px); max-width: 1100px; margin: 0 auto; text-align: center; }
.how h2 { font-size: clamp(30px, 4vw, 44px); margin-bottom: 36px; }
.how-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.how-card { text-align: left; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; transition: transform .2s, border-color .2s; }
.how-card:hover { transform: translateY(-4px) rotate(-.4deg); border-color: rgba(255,122,69,.4); }
.how-num { width: 42px; height: 42px; border-radius: 12px; background: var(--grad); color: #1a0f0a; font-family: var(--font-display); font-weight: 800; font-size: 22px; display: grid; place-items: center; margin-bottom: 16px; }
.how-card h3 { font-size: 21px; margin-bottom: 8px; }
.how-card p { color: var(--muted); margin: 0; }

.footer { text-align: center; padding: 30px 20px 40px; color: var(--muted); border-top: 1px solid var(--line); font-size: 14px; }
.footer p { margin: 4px 0; }
.credits { font-size: 12.5px; }

/* ---------- Modal ---------- */
.modal { position: fixed; inset: 0; z-index: 2000; display: grid; place-items: center; padding: 20px; }
.modal-backdrop, .drawer-backdrop { position: absolute; inset: 0; background: rgba(5,6,10,.7); backdrop-filter: blur(6px); animation: fade .2s ease; }
@keyframes fade { from { opacity: 0; } }
.modal-card {
  position: relative; width: min(720px, 100%); max-height: calc(100vh - 40px); overflow-y: auto;
  background: var(--card); border: 1px solid var(--line); border-radius: 24px; box-shadow: var(--shadow);
  animation: pop .28s cubic-bezier(.3,1.3,.5,1);
}
@keyframes pop { from { opacity: 0; transform: translateY(20px) scale(.97); } }
.modal-close {
  position: absolute; top: 14px; right: 14px; z-index: 5; width: 38px; height: 38px; border-radius: 50%;
  border: none; background: rgba(0,0,0,.55); backdrop-filter: blur(6px); font-size: 16px;
}
.modal-close.static { position: static; background: var(--card-2); }
.modal-cover { height: 260px; background-size: cover; background-position: center; display: grid; place-items: center; font-size: 96px; position: relative; }
.modal-cover::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 50%, var(--card)); }
.modal-cover .credit { position: absolute; left: 14px; top: 14px; z-index: 2; font-size: 11px; background: rgba(0,0,0,.5); padding: 3px 8px; border-radius: 999px; text-decoration: none; }
.modal-body { padding: 0 28px 28px; margin-top: -40px; position: relative; z-index: 2; }
.modal-body h2 { font-size: clamp(26px, 4vw, 34px); margin: 6px 0 6px; }
.m-meta { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; color: var(--muted); font-size: 14px; }
.m-meta .stars { color: var(--gold); }
.m-section { margin-top: 22px; }
.m-section h4 { margin: 0 0 8px; font-size: 13px; text-transform: uppercase; letter-spacing: .08em; color: #ffb08a; }
.m-section p { margin: 0; color: #d6dbe4; }
.m-extras { margin: 10px 0 0; padding: 0; list-style: none; display: grid; gap: 4px; color: #c2c9d6; font-size: 14px; }
.m-extras li::before { content: "→ "; color: var(--accent); }
.type-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.type-chips span { padding: 6px 12px; border-radius: 999px; background: var(--card-2); border: 1px solid var(--line); font-size: 13.5px; }
.light-box { display: flex; gap: 14px; align-items: center; padding: 14px 16px; border-radius: 14px; background: linear-gradient(90deg, rgba(255,195,90,.12), rgba(92,157,255,.08)); border: 1px solid rgba(255,195,90,.25); }
.light-box .le { font-size: 32px; }
.light-box strong { display: block; }
.light-box small { color: #c9cfdb; }
.tips { margin: 0; padding-left: 0; list-style: none; display: grid; gap: 8px; }
.tips li { padding: 10px 12px; background: var(--bg-2); border-radius: 12px; font-size: 14.5px; color: #d6dbe4; }
.tips li::before { content: "💡 "; }
.challenge { padding: 16px; border-radius: 14px; background: repeating-linear-gradient(-45deg, rgba(255,77,141,.08) 0 10px, rgba(255,77,141,.04) 10px 20px); border: 1px dashed rgba(255,77,141,.5); font-weight: 600; }
.wiki-extract { font-size: 14.5px; color: #c2c9d6 !important; }
.wiki-extract a { color: #ffb08a; }
.gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.gallery a { display: block; aspect-ratio: 1; border-radius: 10px; overflow: hidden; background: var(--bg-2); }
.gallery img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.gallery a:hover img { transform: scale(1.07); }
.gallery-note { display: block; margin-top: 8px; color: var(--muted); font-size: 12.5px; }
.m-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 26px; }
.m-actions a { text-decoration: none; }
.fav-on { background: rgba(255,77,141,.18); border-color: rgba(255,77,141,.5); color: #ffc2d6; }

/* ---------- Drawer favoritos ---------- */
.drawer { position: fixed; inset: 0; z-index: 2000; }
.drawer-card {
  position: absolute; right: 0; top: 0; bottom: 0; width: min(420px, 100%); background: var(--card); border-left: 1px solid var(--line);
  padding: 20px; display: flex; flex-direction: column; animation: slide .3s ease;
}
@keyframes slide { from { transform: translateX(100%); } }
.drawer-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; }
.fav-list { list-style: none; margin: 0; padding: 0; overflow-y: auto; display: grid; gap: 10px; }
.fav-item { display: flex; gap: 10px; align-items: center; padding: 10px; background: var(--bg-2); border-radius: 12px; }
.fav-item .e { font-size: 26px; }
.fav-item .t { flex: 1; min-width: 0; }
.fav-item .t strong { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fav-item .t small { color: var(--muted); }
.fav-item a, .fav-item button { font-size: 13px; padding: 6px 10px; border-radius: 999px; border: 1px solid var(--line); background: var(--card-2); text-decoration: none; }

/* ---------- Loader ---------- */
.loader { position: fixed; inset: 0; z-index: 3000; display: grid; place-items: center; background: rgba(5,6,10,.75); backdrop-filter: blur(8px); }
.loader-card { text-align: center; }
.loader-card p { margin-top: 22px; font-family: var(--font-display); font-size: 20px; font-weight: 700; min-height: 1.4em; }
.shutter { width: 96px; height: 96px; margin: 0 auto; border-radius: 50%; position: relative; border: 5px solid #fff; overflow: hidden; animation: spin 2.4s linear infinite; }
.shutter span {
  position: absolute; left: 50%; top: 50%; width: 80px; height: 80px; transform-origin: 0 0;
  background: var(--grad); opacity: .85; border: 1px solid rgba(0,0,0,.4);
}
.shutter span:nth-child(1) { transform: rotate(0deg) translate(-12px, -6px); }
.shutter span:nth-child(2) { transform: rotate(60deg) translate(-12px, -6px); }
.shutter span:nth-child(3) { transform: rotate(120deg) translate(-12px, -6px); }
.shutter span:nth-child(4) { transform: rotate(180deg) translate(-12px, -6px); }
.shutter span:nth-child(5) { transform: rotate(240deg) translate(-12px, -6px); }
.shutter span:nth-child(6) { transform: rotate(300deg) translate(-12px, -6px); }
.shutter { animation: spin 2.4s linear infinite, breathe 1.2s ease-in-out infinite; }
@keyframes spin { to { rotate: 360deg; } }
@keyframes breathe { 50% { transform: scale(.88); } }

.toast {
  position: fixed; left: 50%; bottom: 26px; transform: translateX(-50%); z-index: 4000;
  background: #fff; color: #111; padding: 12px 18px; border-radius: 14px; font-weight: 600; box-shadow: var(--shadow);
  animation: pop .25s ease; max-width: calc(100% - 40px);
}

/* ---------- Responsive ---------- */
@media (max-width: 1250px) {
  .polaroid { transform: scale(.8); opacity: .55; }
  .p1 { top: 6%; left: 2%; } .p2 { top: 6%; right: 2%; }
  .p3 { bottom: 4%; left: 2%; } .p4 { bottom: 4%; right: 2%; }
}
@media (max-width: 1100px) { .polaroid { display: none; } }
@media (max-width: 900px) {
  .layout { grid-template-columns: 1fr; height: auto; }
  .map-wrap { order: -1; height: 52vh; min-height: 340px; }
  .panel { max-height: none; }
  .spot-list { max-height: none; overflow: visible; }
  .how-grid { grid-template-columns: 1fr; }
  .polaroid { display: none; }
  .conditions { justify-content: flex-start; }
}
@media (max-width: 600px) {
  .search-row { flex-direction: column; align-items: stretch; }
  .search-row.second .btn-primary { width: 100%; }
  .navlink { display: none; }
  .topbar { padding-left: 12px; padding-right: 12px; }
  .brand span { display: none; }
  .fav-label { display: none; }
  #favBtn { padding: 10px 12px; }
  .unit-toggle button { padding: 5px 8px; }
  .modal-body { padding: 0 18px 22px; }
  .modal-cover { height: 200px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
