:root {
  --cream: #f4ede0;
  --cream-dark: #e8dcc4;
  --ink: #1a1714;
  --ink-soft: #3a322a;
  --red: #c8303f;        /* tube red */
  --red-deep: #8a1a23;
  --navy: #0e2244;       /* royal navy */
  --gold: #d4a548;
  --green: #2d5d3a;
  --hotel: #2d5d3a;      /* hotel = green */
  --bf: #d4a548;         /* breakfast = gold */
  --dn: #c8303f;         /* dinner = red */
  --st: #0e2244;         /* sights = navy */
  --tier-cheap: #2d5d3a;
  --tier-mid: #b8893a;
  --tier-splurge: #6b1f2a;
  --paper-shadow: 0 1px 0 rgba(26,23,20,.06), 0 12px 28px rgba(26,23,20,.08);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: 'Inter', sans-serif;
  background: var(--cream);
  color: var(--ink);
  line-height: 1.6;
  font-size: 16px;
  background-image:
    radial-gradient(circle at 20% 10%, rgba(212,165,72,.08), transparent 40%),
    radial-gradient(circle at 80% 80%, rgba(200,48,63,.06), transparent 45%);
}

/* Subtle paper-grain texture overlay */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  opacity: .35;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 .1  0 0 0 0 .08  0 0 0 0 .05  0 0 0 .35 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

/* ------------- MASTHEAD ------------- */
.masthead {
  position: relative;
  padding: 2.5rem 1.5rem 2rem;
  text-align: center;
  border-bottom: 3px double var(--ink);
  z-index: 2;
}

.masthead-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: 'Space Mono', monospace;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  border-bottom: 1px solid var(--ink);
  padding-bottom: 0.6rem;
  margin-bottom: 1.8rem;
  color: var(--ink-soft);
  flex-wrap: wrap;
  gap: 0.5rem;
}

.title {
  font-family: 'Fraunces', serif;
  font-weight: 900;
  line-height: 0.9;
  margin: 0 0 1.2rem;
  color: var(--ink);
  font-size: clamp(3.2rem, 14vw, 9rem);
  letter-spacing: -0.04em;
}
.title-line-1 { display: block; }
.title-line-2 {
  display: block;
  margin-top: -0.05em;
}
.title em {
  font-style: italic;
  color: var(--red);
  font-weight: 400;
  background: linear-gradient(180deg, transparent 60%, rgba(212,165,72,.4) 60%);
  padding: 0 0.05em;
}

.dek {
  max-width: 640px;
  margin: 0 auto 2rem;
  font-family: 'Fraunces', serif;
  font-size: clamp(1rem, 2.5vw, 1.2rem);
  font-style: italic;
  color: var(--ink-soft);
  font-weight: 400;
  line-height: 1.5;
}

.masthead-stats {
  display: flex;
  justify-content: center;
  gap: clamp(1.2rem, 5vw, 3rem);
  flex-wrap: wrap;
  padding-top: 1rem;
  border-top: 1px solid var(--ink);
  max-width: 700px;
  margin: 0 auto;
}
.masthead-stats > div {
  text-align: center;
}
.masthead-stats strong {
  display: block;
  font-family: 'Fraunces', serif;
  font-size: clamp(2.2rem, 6vw, 3rem);
  font-weight: 800;
  line-height: 1;
  color: var(--red);
}
.masthead-stats span {
  font-family: 'Space Mono', monospace;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--ink-soft);
}

/* ------------- SECTION NAV ------------- */
.section-nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--ink);
  display: flex;
  justify-content: center;
  gap: clamp(0.8rem, 4vw, 2.5rem);
  padding: 0.85rem 1rem;
  border-bottom: 2px solid var(--gold);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.section-nav a {
  font-family: 'Space Mono', monospace;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--cream);
  text-decoration: none;
  white-space: nowrap;
  padding: 0.3rem 0;
  border-bottom: 2px solid transparent;
  transition: border 0.2s, color 0.2s;
}
.section-nav a:hover {
  color: var(--gold);
  border-bottom-color: var(--gold);
}

/* ------------- CHAPTERS ------------- */
.chapter {
  position: relative;
  z-index: 2;
  padding: 4rem 1.25rem 4.5rem;
  max-width: 1280px;
  margin: 0 auto;
}

.chapter-head {
  text-align: center;
  margin-bottom: 3rem;
  position: relative;
}

.chapter-num {
  display: inline-block;
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-size: clamp(2.5rem, 8vw, 5rem);
  font-weight: 400;
  color: var(--red);
  line-height: 1;
  margin-bottom: 0.3rem;
  opacity: 0.85;
}

.chapter-head h2 {
  font-family: 'Fraunces', serif;
  font-weight: 800;
  font-size: clamp(2rem, 7vw, 3.8rem);
  margin: 0 0 0.7rem;
  letter-spacing: -0.025em;
  line-height: 1;
}

.chapter-sub {
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-size: clamp(0.95rem, 2.2vw, 1.15rem);
  color: var(--ink-soft);
  max-width: 560px;
  margin: 0 auto;
}

.chapter-breakfast .chapter-num { color: var(--gold); }
.chapter-dinner .chapter-num { color: var(--red); }
.chapter-sights .chapter-num { color: var(--navy); }
.chapter-map .chapter-num { color: var(--green); }

/* ------------- CARD GRID ------------- */
.card-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

@media (min-width: 640px) {
  .card-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 980px) {
  .card-grid { grid-template-columns: repeat(3, 1fr); }
}

.card {
  background: #fff;
  border: 1px solid var(--ink);
  position: relative;
  padding: 1.5rem 1.4rem 1.6rem;
  display: flex;
  flex-direction: column;
  box-shadow: var(--paper-shadow);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  overflow: hidden;
}
.card:hover {
  transform: translateY(-4px) rotate(-0.3deg);
  box-shadow: 0 18px 40px rgba(26,23,20,.18);
}

.card-num {
  position: absolute;
  top: -0.2rem;
  right: 1rem;
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-size: 4.5rem;
  font-weight: 800;
  color: var(--cream-dark);
  line-height: 1;
  z-index: 0;
  pointer-events: none;
}
.card > * { position: relative; z-index: 1; }

.card-tag {
  display: inline-block;
  font-family: 'Space Mono', monospace;
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.13em;
  padding: 0.3rem 0.6rem;
  margin-bottom: 0.9rem;
  background: var(--ink);
  color: var(--cream);
  align-self: flex-start;
}
.chapter-breakfast .card-tag { background: var(--gold); color: var(--ink); }
.chapter-dinner .card-tag { background: var(--red); color: var(--cream); }

.card-name {
  font-family: 'Fraunces', serif;
  font-size: 1.7rem;
  font-weight: 800;
  margin: 0 0 0.2rem;
  letter-spacing: -0.02em;
  line-height: 1.05;
}

.card-hood {
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-size: 0.95rem;
  color: var(--red);
  margin: 0 0 1rem;
}
.chapter-breakfast .card-hood { color: var(--red-deep); }

.card-why {
  font-size: 0.92rem;
  color: var(--ink-soft);
  margin: 0 0 1.1rem;
  line-height: 1.55;
  flex-grow: 1;
}

.card-must {
  font-family: 'Space Mono', monospace;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding-top: 0.8rem;
  border-top: 1px dashed var(--ink-soft);
  color: var(--ink);
  margin: 0 0 0.4rem;
}
.card-must::before {
  content: 'Order → ';
  color: var(--red);
  font-weight: 700;
}

.card-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 0.7rem;
  font-family: 'Space Mono', monospace;
  font-size: 0.7rem;
  color: var(--ink-soft);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.card-price {
  background: var(--cream);
  border: 1px solid var(--ink);
  padding: 0.25rem 0.55rem;
  font-weight: 700;
  color: var(--ink);
}

/* ------------- SIGHTS GRID ------------- */
.sights-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}
@media (min-width: 640px) {
  .sights-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 980px) {
  .sights-grid { grid-template-columns: repeat(3, 1fr); }
}

.sight-card {
  background: var(--navy);
  color: var(--cream);
  padding: 1.5rem 1.3rem;
  border: 1px solid var(--ink);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  min-height: 220px;
  transition: transform 0.25s, box-shadow 0.25s;
}
.sight-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 40px rgba(14,34,68,.4);
}
.sight-card::after {
  content: '';
  position: absolute;
  top: -50%;
  right: -30%;
  width: 250px;
  height: 250px;
  background: radial-gradient(circle, var(--red) 0%, transparent 60%);
  opacity: 0.35;
  pointer-events: none;
}
.sight-card > * { position: relative; z-index: 1; }

.sight-num {
  font-family: 'Space Mono', monospace;
  font-size: 0.72rem;
  letter-spacing: 0.15em;
  color: var(--gold);
  margin-bottom: 0.5rem;
}
.sight-name {
  font-family: 'Fraunces', serif;
  font-size: 1.5rem;
  font-weight: 800;
  margin: 0 0 0.7rem;
  line-height: 1.05;
  letter-spacing: -0.02em;
}
.sight-why {
  font-size: 0.9rem;
  color: rgba(244,237,224,0.85);
  flex-grow: 1;
  margin: 0 0 1rem;
}
.sight-tip {
  font-family: 'Space Mono', monospace;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--gold);
  border-top: 1px solid rgba(212,165,72,0.3);
  padding-top: 0.7rem;
}

/* ------------- MAP ------------- */
.chapter-map {
  max-width: 1280px;
}

.map-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  justify-content: center;
  margin-bottom: 1.5rem;
}

.map-toggle {
  font-family: 'Space Mono', monospace;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  background: #fff;
  border: 1.5px solid var(--ink);
  color: var(--ink);
  padding: 0.55rem 1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: all 0.2s;
}
.map-toggle.active {
  background: var(--ink);
  color: var(--cream);
}
.map-toggle:hover { transform: translateY(-1px); }

.swatch {
  display: inline-block;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 1.5px solid currentColor;
}
.swatch-bf { background: var(--gold); }
.swatch-dn { background: var(--red); }
.swatch-st { background: var(--navy); }
.swatch-ho { background: var(--green); }

#map {
  height: 70vh;
  min-height: 480px;
  width: 100%;
  border: 2px solid var(--ink);
  box-shadow: 8px 8px 0 var(--ink);
  background: #d8e0d4;
  z-index: 2;
}

.map-legend-note {
  text-align: center;
  font-family: 'Space Mono', monospace;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--ink-soft);
  margin-top: 1rem;
}

/* Custom Leaflet pin */
.pin {
  width: 30px;
  height: 30px;
  border-radius: 50% 50% 50% 0;
  border: 2.5px solid var(--ink);
  transform: rotate(-45deg);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 2px 2px 0 var(--ink);
}
.pin-inner {
  transform: rotate(45deg);
  font-family: 'Fraunces', serif;
  font-weight: 800;
  font-size: 0.85rem;
  color: var(--ink);
}
.pin-bf { background: var(--gold); }
.pin-dn { background: var(--red); color: var(--cream); }
.pin-dn .pin-inner { color: var(--cream); }
.pin-st { background: var(--navy); color: var(--cream); }
.pin-st .pin-inner { color: var(--cream); }

/* Hotel pin — distinct, larger, star icon */
.pin-hotel {
  width: 42px;
  height: 42px;
  border-radius: 50% 50% 50% 0;
  border: 3px solid var(--ink);
  background: var(--green);
  transform: rotate(-45deg);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 3px 3px 0 var(--ink), 0 0 0 5px rgba(212,165,72,.35);
}
.pin-hotel-inner {
  transform: rotate(45deg);
  color: var(--gold);
  font-size: 1.3rem;
  line-height: 1;
  font-weight: 700;
}

/* Leaflet popup styling */
.leaflet-popup-content-wrapper {
  background: var(--cream);
  border: 1.5px solid var(--ink);
  border-radius: 2px;
  box-shadow: 4px 4px 0 var(--ink);
  padding: 4px;
}
.leaflet-popup-content {
  font-family: 'Inter', sans-serif;
  margin: 12px 14px;
  font-size: 0.88rem;
  line-height: 1.45;
  color: var(--ink);
}
.leaflet-popup-content h3 {
  font-family: 'Fraunces', serif;
  font-size: 1.15rem;
  font-weight: 800;
  margin: 0 0 0.25rem;
  letter-spacing: -0.015em;
}
.leaflet-popup-content .pop-tag {
  font-family: 'Space Mono', monospace;
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--red);
  margin-bottom: 0.4rem;
  display: block;
}
.leaflet-popup-content .pop-tier {
  display: inline-block;
  font-family: 'Space Mono', monospace;
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 0.15rem 0.5rem;
  margin-bottom: 0.4rem;
  border: 1px solid currentColor;
  font-weight: 700;
}
.leaflet-popup-content .pop-tier-cheap { color: var(--tier-cheap); }
.leaflet-popup-content .pop-tier-mid { color: var(--tier-mid); }
.leaflet-popup-content .pop-tier-splurge { color: var(--tier-splurge); }

.leaflet-popup-content .pop-addr {
  font-family: 'Space Mono', monospace;
  font-size: 0.7rem;
  color: var(--ink-soft);
  margin-top: 0.5rem;
  padding-top: 0.5rem;
  border-top: 1px dashed var(--ink-soft);
}
.leaflet-popup-tip {
  background: var(--cream);
  border: 1.5px solid var(--ink);
}
.leaflet-container a.leaflet-popup-close-button {
  color: var(--ink);
  font-size: 18px;
  padding: 6px 8px 0 0;
}

/* ------------- COLOPHON ------------- */
.colophon {
  background: var(--ink);
  color: var(--cream);
  padding: 3.5rem 1.25rem 2rem;
  margin-top: 3rem;
  position: relative;
  z-index: 2;
  border-top: 6px solid var(--gold);
}
.colophon-grid {
  max-width: 1100px;
  margin: 0 auto 2rem;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}
@media (min-width: 640px) {
  .colophon-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 980px) {
  .colophon-grid { grid-template-columns: repeat(4, 1fr); }
}
.colophon h4 {
  font-family: 'Fraunces', serif;
  font-size: 1.2rem;
  font-weight: 800;
  margin: 0 0 0.5rem;
  color: var(--gold);
}
.colophon p {
  margin: 0;
  font-size: 0.9rem;
  color: rgba(244,237,224,0.8);
  line-height: 1.55;
}
.colophon-foot {
  text-align: center;
  font-family: 'Space Mono', monospace;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: rgba(244,237,224,0.5);
  border-top: 1px solid rgba(244,237,224,0.15);
  padding-top: 1.5rem;
  max-width: 1100px;
  margin: 0 auto;
}

/* Mobile tweaks */
@media (max-width: 520px) {
  .masthead { padding: 1.8rem 1rem 1.5rem; }
  .chapter { padding: 2.8rem 1rem 3rem; }
  .card { padding: 1.3rem 1.2rem 1.4rem; }
  .card-num { font-size: 3.5rem; right: 0.7rem; }
  #map { height: 60vh; min-height: 400px; box-shadow: 5px 5px 0 var(--ink); }
  .masthead-top { font-size: 0.65rem; letter-spacing: 0.1em; }
}

/* ------------- TIER BANDS ------------- */
.tier-band {
  display: flex;
  align-items: baseline;
  gap: 1.1rem;
  max-width: 880px;
  margin: 2.5rem auto 1.4rem;
  padding: 0.9rem 1.2rem 1rem;
  border-top: 2px solid var(--ink);
  border-bottom: 1px dashed var(--ink-soft);
  position: relative;
}
.tier-band::before {
  content: '';
  position: absolute;
  top: -2px;
  left: 0;
  width: 60px;
  height: 6px;
  background: var(--tier-cheap);
}
.tier-band.tier-mid::before { background: var(--tier-mid); }
.tier-band.tier-splurge::before { background: var(--tier-splurge); }

.tier-num {
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-weight: 800;
  font-size: clamp(2rem, 5vw, 3rem);
  line-height: 1;
  color: var(--tier-cheap);
  flex-shrink: 0;
}
.tier-mid .tier-num { color: var(--tier-mid); }
.tier-splurge .tier-num { color: var(--tier-splurge); }

.tier-band h3 {
  font-family: 'Fraunces', serif;
  font-weight: 800;
  font-size: clamp(1.4rem, 3.5vw, 2rem);
  margin: 0;
  letter-spacing: -0.02em;
  line-height: 1.1;
}
.tier-band p {
  margin: 0.2rem 0 0;
  font-family: 'Space Mono', monospace;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ink-soft);
}
.tier-band > div {
  flex: 1;
}
@media (max-width: 520px) {
  .tier-band {
    flex-wrap: wrap;
    gap: 0.6rem;
    padding: 0.7rem 1rem 0.9rem;
  }
}

/* Tier-colored price pills on cards */
.card-cheap .card-price { background: var(--tier-cheap); color: var(--cream); border-color: var(--tier-cheap); }
.card-mid .card-price { background: var(--tier-mid); color: var(--cream); border-color: var(--tier-mid); }
.card-splurge .card-price { background: var(--tier-splurge); color: var(--cream); border-color: var(--tier-splurge); }

/* Splurge cards get a subtle gold edge */
.card-splurge {
  border-color: var(--tier-splurge);
  box-shadow: 0 1px 0 rgba(26,23,20,.06), 0 12px 28px rgba(107,31,42,.15);
}
.card-splurge::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--gold), var(--tier-splurge));
  z-index: 2;
}
