:root {
  --plum: #2b0f3a; --plum2: #5b1d6e; --wine: #8e2b5b; --gold: #f5b83d; --ink: #1d1626; --muted: #6b6474;
  --line: #e9e3ee; --bg: #faf7fb; --card: #fff; --accent: #7c3aed;
}
* { box-sizing: border-box; }
body { margin: 0; font: 15px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; color: var(--ink); background: var(--bg); }
a { color: var(--wine); }
.wrap { max-width: 1360px; margin: 0 auto; padding: 0 16px; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
h1, h2, h3 { margin: 0; }

.top { background: radial-gradient(1200px 300px at 10% -50%, #8e2b5b 0, transparent 60%), linear-gradient(110deg, var(--plum), var(--plum2)); color: #fff; }
.top-in { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding-top: 12px; padding-bottom: 12px; }
.brand { display: flex; gap: 10px; align-items: center; color: #fff; text-decoration: none; font-size: 20px; }
.brand b { color: var(--gold); }
.tagline { opacity: .85; font-weight: 600; }

.tip { margin: 16px 0 8px; }
.tip-skel { padding: 40px; text-align: center; color: var(--muted); }
.tipcard { display: grid; grid-template-columns: minmax(0, 360px) 1fr; background: var(--card); border-radius: 18px; overflow: hidden; box-shadow: 0 10px 30px rgba(43,15,58,.12); border: 1px solid var(--line); }
.tipimg { background: linear-gradient(135deg, #f3e8ff, #fde68a); min-height: 200px; display: grid; place-items: center; font-size: 72px; }
.tipimg img { width: 100%; height: 100%; object-fit: cover; display: block; max-height: 300px; }
.tipb { padding: 18px 22px; display: flex; flex-direction: column; gap: 6px; }
.badge { align-self: flex-start; background: var(--gold); color: #3b2300; font-weight: 700; font-size: 13px; border-radius: 999px; padding: 3px 12px; }
.tipb h1 { font-size: 27px; line-height: 1.2; }
.orig { margin: 0; color: var(--muted); font-size: 14px; }
.tiptext { margin: 4px 0; font-size: 17px; }
.tipmeta { margin: 0; color: var(--muted); }

.controls { position: sticky; top: 0; z-index: 1000; background: var(--bg); padding: 8px 0 6px; border-bottom: 1px solid var(--line); }
.days, .cats { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; padding: 3px 1px; }
.days button, .cat { flex: 0 0 auto; border: 1px solid var(--line); background: var(--card); color: var(--ink); border-radius: 999px; padding: 7px 13px; font: inherit; font-size: 14px; cursor: pointer; }
.days button i, .cat i { font-style: normal; font-size: 11px; background: #f1ecf4; color: var(--muted); border-radius: 999px; padding: 1px 6px; margin-left: 4px; }
.days button.on { background: var(--plum2); color: #fff; border-color: var(--plum2); }
.days button.on i { background: rgba(255,255,255,.2); color: #fff; }
.days button.empty { opacity: .55; }
.cat.on { background: var(--wine); color: #fff; border-color: var(--wine); }
.cat.on i { background: rgba(255,255,255,.2); color: #fff; }
.cat.clear { border-style: dashed; }
.row2 { margin-top: 4px; }
.row3 { display: flex; gap: 12px; align-items: center; margin-top: 6px; flex-wrap: wrap; }
.dist { display: flex; align-items: center; gap: 8px; font-size: 14px; white-space: nowrap; }
.dist input { width: 140px; accent-color: var(--accent); }
#q { flex: 1; min-width: 160px; font: inherit; padding: 8px 12px; border: 1px solid var(--line); border-radius: 10px; background: #fff; }
.viewsw { display: none; }

.layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; margin-top: 10px; align-items: start; }
.mapcol { position: sticky; top: 150px; }
#map { height: calc(100vh - 175px); min-height: 420px; border-radius: 16px; border: 1px solid var(--line); box-shadow: 0 4px 16px rgba(43,15,58,.08); }
.mapnote { margin: 6px 2px; }
.dayh { font-size: 16px; margin: 18px 2px 8px; text-transform: none; color: var(--plum2); }
.dayh:first-of-type { margin-top: 4px; }
.card { display: grid; grid-template-columns: 96px 1fr; gap: 12px; background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 10px; margin: 8px 0; cursor: pointer; transition: box-shadow .15s, border-color .15s; }
.card:hover, .card:focus { border-color: #cdb9db; box-shadow: 0 4px 14px rgba(43,15,58,.08); outline: none; }
.thumb { width: 96px; height: 96px; border-radius: 10px; object-fit: cover; background: #f3edf7; }
.thumb.ph { display: grid; place-items: center; font-size: 40px; }
.cb { min-width: 0; }
.when { font-size: 13px; font-weight: 700; color: var(--wine); }
.card h3 { font-size: 16.5px; line-height: 1.3; margin: 2px 0; overflow-wrap: anywhere; }
.where { margin: 2px 0; font-size: 14px; color: var(--muted); }
.km { background: #f1ecf4; border-radius: 999px; padding: 0 7px; font-size: 12px; color: var(--plum2); white-space: nowrap; }
.desc { margin: 4px 0; font-size: 14px; overflow-wrap: anywhere; }
.acts { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 6px; }
.acts button, .acts a { font: inherit; font-size: 13px; border: 1px solid var(--line); background: #fff; color: var(--ink); border-radius: 8px; padding: 4px 9px; cursor: pointer; text-decoration: none; }
.acts button:hover, .acts a:hover { border-color: var(--wine); }
.src { margin: 6px 0 0; }
.empty { background: #fff; border: 1px dashed var(--line); border-radius: 14px; padding: 20px; color: var(--muted); }
.long { margin: 16px 0; background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 10px 12px; }
.long summary { cursor: pointer; font-weight: 600; }

.pin { background: none; border: 0; }
.pin span { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: #fff; border: 3px solid #64748b; font-size: 16px; box-shadow: 0 2px 6px rgba(0,0,0,.3); }
.pin.approx span { border-style: dotted; }
.pin.star span { box-shadow: 0 0 0 4px var(--gold), 0 2px 8px rgba(0,0,0,.35); }
.home span { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; background: var(--plum); font-size: 14px; box-shadow: 0 0 0 3px #fff; }
.leaflet-popup-content { font: 14px/1.4 system-ui, sans-serif; margin: 12px 14px; }
.pop p { margin: 6px 0; }

.about { margin: 24px 0 8px; }
.about details { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 10px 14px; }
.about summary { cursor: pointer; }
.warn { color: #b45309; }
.foot { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; font-size: 13px; color: var(--muted); padding-top: 12px; padding-bottom: 32px; }

@media (max-width: 900px) {
  .tipcard { grid-template-columns: 1fr; }
  .tipimg { min-height: 150px; }
  .tipimg img { max-height: 210px; }
  .tipb h1 { font-size: 22px; }
  .layout { grid-template-columns: minmax(0, 1fr); }
  .viewsw { display: flex; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
  .viewsw button { border: 0; background: #fff; font: inherit; font-size: 14px; padding: 7px 12px; cursor: pointer; }
  .viewsw button.on { background: var(--plum2); color: #fff; }
  body[data-view="list"] .mapcol { display: none; }
  body[data-view="map"] .listcol { display: none; }
  .mapcol { position: static; }
  #map { height: calc(100vh - 230px); min-height: 360px; }
  .tagline { display: none; }
}
@media (max-width: 520px) {
  .card { grid-template-columns: 72px 1fr; gap: 10px; }
  .thumb { width: 72px; height: 72px; }
  .dist input { width: 100px; }
  .row3 { gap: 8px; }
  #q { order: 3; flex-basis: 100%; }
}
