/* ══════════════════════════════════════════════════════════
   RESET & BASE
══════════════════════════════════════════════════════════ */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  /* Palette — clean, minimal, single accent */
  --color-bg:           #F8F8F7;
  --color-bg-alt:       #F4F4F5;
  --color-surface:      #FFFFFF;
  --color-border:       #E4E4E7;
  --color-border-light: #F0F0F1;

  --color-text:         #09090B;
  --color-text-muted:   #71717A;
  --color-text-light:   #A1A1AA;

  --color-accent:       #C8102E;   /* Italian flag red — single accent */
  --color-accent-hover: #A50E26;
  --color-accent-bg:    #FFF0F1;

  --color-header-bg:    #111111;
  --color-header-text:  #FFFFFF;

  /* Typography */
  --font-display: 'Fraunces', Georgia, 'Times New Roman', serif;
  --font-body:    'Inter', system-ui, -apple-system, sans-serif;

  /* Spacing */
  --space-xs:  0.25rem;
  --space-sm:  0.5rem;
  --space-md:  1rem;
  --space-lg:  1.5rem;
  --space-xl:  2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;

  /* Layout */
  --header-height: 60px;
  --nav-height:    48px;
  --max-width:     1120px;
  --content-px:    2rem;

  /* Radii */
  --radius-sm:   4px;
  --radius-md:   8px;
  --radius-lg:   12px;
  --radius-full: 999px;

  /* Shadows — very subtle */
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.08);

  --transition: 0.15s ease;
}

html { font-size: 16px; scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background: var(--color-bg);
  color: var(--color-text);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  line-height: 1.2;
  color: var(--color-text);
  font-weight: 600;
}

a { color: var(--color-accent); text-decoration: none; }
button { cursor: pointer; font-family: inherit; }
img { max-width: 100%; display: block; }

/* ══════════════════════════════════════════════════════════
   ACCESSIBILITY
══════════════════════════════════════════════════════════ */
.skip-link {
  position: absolute;
  top: -100px;
  left: var(--space-md);
  background: var(--color-accent);
  color: #fff;
  padding: 8px 16px;
  border-radius: var(--radius-md);
  font-size: 0.875rem;
  font-weight: 600;
  z-index: 9999;
  transition: top var(--transition);
  text-decoration: none;
}
.skip-link:focus { top: var(--space-md); }

:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

/* ══════════════════════════════════════════════════════════
   HEADER
══════════════════════════════════════════════════════════ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--color-header-bg);
  height: var(--header-height);
  border-bottom: 1px solid #222;
}

.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--content-px);
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
}

.header-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.brand-icon { font-size: 1.25rem; line-height: 1; }

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.brand-name {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--color-header-text);
  letter-spacing: -0.01em;
}

.brand-tagline {
  font-size: 0.68rem;
  color: #888;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  flex-shrink: 0;
}

/* Language toggle */
.lang-toggle {
  display: flex;
  align-items: center;
  background: #222;
  border-radius: var(--radius-full);
  padding: 3px;
  gap: 0;
}

.lang-btn {
  background: transparent;
  border: none;
  color: #888;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 4px 11px;
  border-radius: var(--radius-full);
  transition: all var(--transition);
  letter-spacing: 0.06em;
}

.lang-btn.active {
  background: #fff;
  color: #111;
}

.lang-btn:hover:not(.active) { color: #ccc; }

.lang-divider { display: none; }

/* PDF download button */
.pdf-btn {
  display: flex;
  align-items: center;
  gap: 7px;
  background: var(--color-accent);
  color: #fff;
  border: none;
  padding: 8px 16px;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: background var(--transition);
  white-space: nowrap;
}

.pdf-btn:hover { background: var(--color-accent-hover); }
.pdf-icon { flex-shrink: 0; }

/* ══════════════════════════════════════════════════════════
   TAB NAVIGATION
══════════════════════════════════════════════════════════ */
.tab-nav {
  position: sticky;
  top: var(--header-height);
  z-index: 90;
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
}

.tab-nav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 8px var(--content-px);
  display: flex;
  justify-content: center;
  gap: 0;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
  position: relative;  /* for slider positioning */
}
.tab-nav-inner::-webkit-scrollbar { display: none; }

/* Sliding background indicator — injected by JS */
.tab-slider {
  position: absolute;
  top: 8px;
  left: 0;
  height: calc(100% - 16px);
  background: var(--color-text);
  border-radius: 0;
  z-index: 0;
  pointer-events: none;
  transition: left 0.26s cubic-bezier(0.4, 0, 0.2, 1),
              width 0.26s cubic-bezier(0.4, 0, 0.2, 1);
}

/* First and last get rounded corners on outer edges */
.tab-slider.at-first { border-radius: var(--radius-sm) 0 0 var(--radius-sm); }
.tab-slider.at-last  { border-radius: 0 var(--radius-sm) var(--radius-sm) 0; }
.tab-slider.at-only  { border-radius: var(--radius-sm); }

.tab-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  background: none;
  border: 1px solid var(--color-border);
  border-right-width: 0;         /* shared border between buttons */
  border-radius: 0;
  padding: 8px 18px;
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--color-text-muted);
  white-space: nowrap;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  flex-shrink: 0;
  position: relative;
  z-index: 1;                    /* sits above slider */
  transition: color 0.18s ease;
  cursor: pointer;
}

/* First/last button get rounded outer corners */
.tab-btn:first-child { border-radius: var(--radius-sm) 0 0 var(--radius-sm); }
.tab-btn:last-child  { border-right-width: 1px; border-radius: 0 var(--radius-sm) var(--radius-sm) 0; }

.tab-btn:hover:not(.active) {
  color: var(--color-text);
  background: var(--color-bg-alt);
}

/* Active state — text turns white, slider provides the background */
.tab-btn.active {
  color: #fff;
  font-weight: 700;
}

/* Map tab — subtly highlighted so it reads as the "live map" entry point.
   Inactive only; when active the dark slider + white text take over. */
#map-tab-btn:not(.active) {
  background: var(--color-accent-bg);
  color: var(--color-accent);
}
#map-tab-btn:hover:not(.active) {
  background: #ffe3e6;
  color: var(--color-accent-hover);
}

/* ══════════════════════════════════════════════════════════
   MAIN / TAB PANELS
══════════════════════════════════════════════════════════ */
.main-content {
  flex: 1;
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;

  display: flex;
  flex-direction: column;
}

.tab-panel {
  padding: var(--space-xl) var(--content-px);
  animation: fadeIn 0.2s ease;
  width: 100%;
  background: var(--color-surface);
  border-left: 1px solid var(--color-border);
  border-right: 1px solid var(--color-border);
}

.tab-panel.map-panel { padding: 0; }
.tab-panel[hidden]   { display: none !important; }

/* Welcome panel: full-bleed horizontally so it aligns with the hero on
   desktop and reaches screen edges on mobile. */
#tab-welcome { 
  padding: 0;
  display: flex;
  flex-direction: column;
  flex: 1;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(4px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Tab headers */
.tab-header {
  margin-bottom: var(--space-xl);
  padding-bottom: var(--space-lg);
  border-bottom: 1px solid var(--color-border);
}

.tab-header.has-filter {
  margin-bottom: var(--space-md);
}

.tab-header.sightseeing {
  margin-bottom: 0;
  border-bottom: 0;
}

.tab-header h2 {
  font-size: 1.85rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 6px;
}

.tab-intro {
  color: var(--color-text-muted);
  font-size: 0.9rem;
  max-width: 60ch;
}

/* ══════════════════════════════════════════════════════════
   WELCOME
══════════════════════════════════════════════════════════ */
.welcome-hero {
  background: var(--color-header-bg);
  display: flex;
  flex-direction: column;
  margin-bottom: 0;
  flex: 1 0 auto;
  overflow: hidden;
  position: relative;
}


/* Subtle grid pattern */
.welcome-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
  background-size: 40px 40px;
}

/* Red accent bar — spans from top of overlay down to the CTA button */
.welcome-overlay::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 2rem;
  width: 4px;
  background: var(--color-accent);
}

.welcome-overlay {
  position: relative;
  z-index: 1;
  padding: clamp(2.5rem, 5vw, 4.5rem) clamp(2rem, 5vw, 4rem) 2rem;
  max-width: 880px;
}

.welcome-overlay h1 {
  font-size: clamp(2.5rem, 6.5vw, 4.75rem);
  color: #fff;
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 0.98;
  margin-bottom: var(--space-md);
}
.welcome-overlay h1 em {
  font-style: italic;
  font-weight: 400;
  color: var(--color-accent);
}

.welcome-subtitle {
  color: #c8c8d0;
  font-size: clamp(1rem, 1.4vw, 1.15rem);
  margin-bottom: var(--space-xl);
  line-height: 1.65;
  max-width: 52ch;
}

.cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--color-accent);
  color: #fff;
  border: none;
  padding: 10px 22px;
  border-radius: var(--radius-full);
  font-size: 0.875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  transition: background var(--transition);
  letter-spacing: 0.01em;
}

.cta-btn:hover { background: var(--color-accent-hover); }
.cta-btn .cta-arrow { transition: transform 0.2s ease; }
.cta-btn:hover .cta-arrow { transform: translateX(3px); }

/* ── Welcome info list (editorial rows over the dark hero) ── */
.welcome-info {
  list-style: none;
  margin: 0 clamp(2rem, 5vw, 4rem);
  padding: 0;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  position: relative;
  z-index: 1;
}

.welcome-info .info-row {
  display: grid;
  grid-template-columns: 56px minmax(160px, 1fr) minmax(0, 2.5fr);
  align-items: center;
  gap: 1.5rem;
  padding: 1.75rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.welcome-info .info-icon {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #fff;
  flex-shrink: 0;
}
.welcome-info .info-icon svg { width: 20px; height: 20px; }

.welcome-info .info-label {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 500;
  letter-spacing: -0.01em;
  color: #fff;
}

.welcome-info .info-body {
  font-size: 0.95rem;
  color: #c8c8d0;
  line-height: 1.65;
}
.welcome-info .info-body p + p { margin-top: 0.4rem; }
.welcome-info .info-body .info-note {
  color: #8a8a92;
  font-size: 0.85rem;
}
.welcome-info .info-body strong { color: #fff; font-weight: 600; }

.welcome-info .contact-line {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
}
.welcome-info .contact-line a {
  color: #fff;
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
  padding-bottom: 1px;
  text-decoration: none;
  transition: border-color 0.2s ease;
}
.welcome-info .contact-line a:hover { border-color: var(--color-accent); }
.welcome-info .contact-sep { color: rgba(255, 255, 255, 0.3); }

.welcome-info .address-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 0.85rem;
  padding: 8px 14px;
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: var(--radius-full);
  color: #fff;
  background: transparent;
  font-size: 0.78rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
  white-space: nowrap;
}
.welcome-info .address-link:hover {
  background: #fff;
  color: var(--color-text);
  border-color: #fff;
}

/* ══════════════════════════════════════════════════════════
   ADDRESS LINK (shared)
══════════════════════════════════════════════════════════ */
.address-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--color-accent);
  background: none;
  border: 1px solid var(--color-border);
  padding: 5px 12px;
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
  white-space: nowrap;
}

.address-link:hover {
  background: var(--color-accent);
  border-color: var(--color-accent);
  color: #fff;
}

/* ══════════════════════════════════════════════════════════
   FILTER ROW (shared)
══════════════════════════════════════════════════════════ */
.filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: var(--space-md);
}

.filter-btn {
  background: none;
  border: 1px solid var(--color-border);
  color: var(--color-text-muted);
  padding: 5px 14px;
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  font-weight: 500;
  transition: all var(--transition);
}

.filter-btn:hover {
  border-color: var(--color-text-light);
  color: var(--color-text);
}

.filter-btn.active {
  background: var(--color-text);
  border-color: var(--color-text);
  color: #fff;
}

/* ══════════════════════════════════════════════════════════
   PLACE CARDS — HORIZONTAL FULL-WIDTH LIST
══════════════════════════════════════════════════════════ */
.place-grid {
  display: flex;
  flex-direction: column;
  border-top: 1px solid var(--color-border);
}

.place-card {
  display: flex;
  align-items: center;
  gap: var(--space-xl);
  padding: var(--space-lg) 0;
  border-bottom: 1px solid var(--color-border-light);
  transition: background var(--transition);
  position: relative;
}

.place-card:hover { background: var(--color-bg-alt); margin: 0 calc(-1 * var(--content-px)); padding-left: var(--content-px); padding-right: var(--content-px); }

/* Featured accent */
.place-card.featured::before {
  content: '';
  position: absolute;
  left: -2px;
  top: 12px;
  bottom: 12px;
  width: 2px;
  background: var(--color-accent);
  border-radius: 2px;
}

.place-card.featured:hover::before {
  left: calc(var(--content-px) - 2px);
}

/* Hidden (filtered out) */
.place-card.hidden { display: none; }

/* ── Image placeholder ── */
.place-img {
  flex: 0 0 240px;
  height: 160px;
  background: var(--color-bg-alt);
  border-radius: var(--radius-sm);
  border: 1px solid var(--color-border);
  overflow: hidden;
  flex-shrink: 0;
}

.place-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* ── Left column: name + tag + price/badge ── */
.place-card-header {
  flex: 0 0 200px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.place-name {
  font-size: 1rem;
  font-weight: 600;
  color: var(--color-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.place-category-tag {
  font-size: 0.7rem;
  color: var(--color-text-light);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* Price stays inside header col — top-right of that column */
.place-price {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--color-text-light);
  margin-top: 2px;
}

.place-badge {
  display: inline-block;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-accent);
  background: var(--color-accent-bg);
  border: 1px solid #F5C6CC;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  margin-top: 6px;
  align-self: flex-start;
}

/* ── Middle: description ── */
.place-desc {
  flex: 1;
  font-size: 0.85rem;
  color: var(--color-text-muted);
  line-height: 1.6;
  min-width: 0;
  /* clamp to 2 lines */
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ── Right: meta (hours + address) ── */
.place-meta {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
  border-top: none;
  padding-top: 0;
}

.place-hours {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
  font-size: 0.75rem;
  color: var(--color-text-light);
  line-height: 1.3;
}

.place-hours-time {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
}

.place-hours-time::before {
  content: '';
  display: inline-block;
  width: 12px;
  height: 12px;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23A1A1AA' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><circle cx='12' cy='12' r='9'/><path d='M12 7v5l3 2'/></svg>");
  background-repeat: no-repeat;
  background-size: contain;
  flex-shrink: 0;
}

.place-hours-cond {
  font-size: 0.7rem;
  font-style: italic;
  color: var(--color-text-light);
}

/* ══════════════════════════════════════════════════════════
   TRANSPORT
══════════════════════════════════════════════════════════ */
.transport-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1px;
  background: var(--color-border);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-bottom: var(--space-xl);
}

.transport-card {
  background: var(--color-surface);
  padding: var(--space-xl);
  transition: background var(--transition);
}

.transport-card:hover { background: var(--color-bg-alt); }

.transport-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: var(--color-bg-alt);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--color-text-muted);
  text-transform: uppercase;
  margin-bottom: var(--space-sm);
}

.transport-card h3 {
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 8px;
}

.transport-card p {
  font-size: 0.82rem;
  color: var(--color-text-muted);
  line-height: 1.65;
}

.transport-tip {
  margin-top: var(--space-sm);
  font-size: 0.78rem;
  color: var(--color-text-muted);
  padding: 8px 10px;
  background: var(--color-bg-alt);
  border-left: 2px solid var(--color-accent);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

/* Info table */
.info-table-wrap {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.info-table-wrap h3 {
  font-size: 0.875rem;
  font-weight: 600;
  padding: var(--space-lg) var(--space-xl);
  border-bottom: 1px solid var(--color-border);
  background: var(--color-bg-alt);
}

.info-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
}

.info-table th {
  background: var(--color-bg-alt);
  color: var(--color-text-muted);
  font-weight: 600;
  padding: 10px 20px;
  text-align: left;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  border-bottom: 1px solid var(--color-border);
}

.info-table td {
  padding: 11px 20px;
  border-bottom: 1px solid var(--color-border-light);
  color: var(--color-text-muted);
}

.info-table tr:last-child td { border-bottom: none; }
.info-table tr:hover td { background: var(--color-bg-alt); }

/* ══════════════════════════════════════════════════════════
   TIPS
══════════════════════════════════════════════════════════ */
.tips-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 1px;
  background: var(--color-border);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.tip-section {
  background: var(--color-surface);
  padding: var(--space-xl);
  transition: background var(--transition);
}

.tip-section:hover { background: var(--color-bg-alt); }

.tip-section h3 {
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: var(--space-md);
  padding-bottom: var(--space-sm);
  border-bottom: 1px solid var(--color-border);
}

.tip-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.tip-list li {
  font-size: 0.82rem;
  color: var(--color-text-muted);
  padding-left: var(--space-md);
  position: relative;
  line-height: 1.55;
}

.tip-list li::before {
  content: '–';
  position: absolute;
  left: 0;
  color: var(--color-accent);
  font-weight: 700;
}

.tip-section p {
  font-size: 0.82rem;
  color: var(--color-text-muted);
  line-height: 1.65;
  margin-bottom: var(--space-sm);
}

/* Phrase table */
.phrase-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8rem;
}

.phrase-table th {
  background: var(--color-bg-alt);
  color: var(--color-text-muted);
  font-weight: 600;
  padding: 7px 10px;
  text-align: left;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  border-bottom: 1px solid var(--color-border);
}

.phrase-table td {
  padding: 6px 10px;
  border-bottom: 1px solid var(--color-border-light);
  color: var(--color-text-muted);
}

.phrase-table tr:last-child td { border-bottom: none; }
.phrase-table tr:hover td { background: var(--color-bg-alt); }

/* ══════════════════════════════════════════════════════════
   MAP
══════════════════════════════════════════════════════════ */
.tab-panel.map-panel {
  height: 100%;
  padding: 0;
}

/* When map tab is active, lock viewport so footer stays visible without scroll */
body.map-active { height: 100vh; overflow: hidden; }
body.map-active .main-content { min-height: 0; overflow: hidden; }

.map-element {
  width: 100%;
  height: 100%;
  z-index: 1;
}

/* Circle pins */
.map-pin-wrap {
  background: transparent;
  border: 0;
}

.map-pin {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--pin-color, #555);
  border: 2.5px solid #fff;
  box-shadow: 0 2px 6px rgba(0,0,0,0.25);
  transition: transform 0.15s ease;
}

.map-pin svg {
  width: 24px;
  height: 24px;
  display: block;
}

.map-pin-wrap:hover .map-pin { transform: scale(1.15); }

/* Zoom control — minimal, modern, bottom-right on desktop, hidden on mobile */
.leaflet-control-zoom {
  border: none !important;
  box-shadow: 0 2px 8px rgba(0,0,0,0.12) !important;
  border-radius: var(--radius-md) !important;
  overflow: hidden;
  margin: 0 var(--space-lg) var(--space-lg) 0 !important;
}

.leaflet-control-zoom a {
  background: #fff !important;
  color: var(--color-text) !important;
  width: 34px !important;
  height: 34px !important;
  line-height: 34px !important;
  font-size: 18px !important;
  font-weight: 400 !important;
  border: none !important;
  border-bottom: 1px solid var(--color-border-light) !important;
  transition: background var(--transition);
}

.leaflet-control-zoom a:last-child { border-bottom: none !important; }
.leaflet-control-zoom a:hover { background: var(--color-bg-alt) !important; }

/* Leaflet popup card */
.leaflet-popup-content-wrapper {
  border-radius: var(--radius-md) !important;
  box-shadow: var(--shadow-md) !important;
  border: 1px solid var(--color-border);
  padding: 4px !important;
}

.leaflet-popup-content { margin: 10px 12px !important; }

.map-popup h4 {
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 4px;
  letter-spacing: -0.01em;
}

.map-popup p {
  font-size: 0.78rem;
  color: var(--color-text-muted);
  margin-bottom: 4px;
}

.map-popup-addr {
  font-size: 0.72rem !important;
  color: var(--color-text-light) !important;
  margin-bottom: 10px !important;
}

.map-popup-btn {
  display: block;
  width: 100%;
  text-align: center;
  background: var(--color-accent);
  color: #fff;
  border: none;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background var(--transition);
}

.map-popup-btn:hover { background: var(--color-accent-hover); }

/* ── Transport layer: metro / bus lines + station & taxi markers ── */

/* Transit lines are faint by default; the .is-active class (toggled on click)
   makes the whole line stand out. Colour comes from inline `color` per line. */
.transit-line        { opacity: 0.3; transition: opacity 0.2s ease; cursor: pointer; }
.transit-line:hover     { opacity: 0.6; }
.transit-line.is-active { opacity: 1; stroke-width: 6; }

/* Small circular station / stop / taxi markers — smaller than place pins
   so they don't compete with the eat/sights teardrops. */
.transit-pin-wrap { background: transparent; border: 0; }

.transit-pin {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #fff;
  border: 3px solid var(--pin-color, #555);
  box-shadow: 0 1px 3px rgba(0,0,0,0.3);
  font-size: 9px;
  font-weight: 800;
  color: var(--pin-color, #555);
  line-height: 1;
  transition: transform 0.15s ease;
}

.transit-pin svg { width: 11px; height: 11px; display: block; }

.transit-pin.taxi {
  background: #1A1A1A;
  border-color: #F2C200;
  color: #F2C200;
}

.transit-pin-wrap:hover .transit-pin { transform: scale(1.25); }

/* Line badge used in transit popups (e.g. "A", "B", "64") */
.transit-badge {
  display: inline-block;
  min-width: 18px;
  padding: 1px 6px;
  border-radius: var(--radius-full);
  background: var(--badge-color, #555);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 800;
  text-align: center;
  margin-right: 4px;
}

/* ══════════════════════════════════════════════════════════
   NAV MODAL
══════════════════════════════════════════════════════════ */
.modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-lg);
}

.modal[hidden] { display: none; }

.modal-box {
  background: var(--color-surface);
  border-radius: var(--radius-lg);
  padding: var(--space-2xl);
  max-width: 360px;
  width: 100%;
  position: relative;
  box-shadow: 0 20px 60px rgba(0,0,0,0.15);
  border: 1px solid var(--color-border);
  animation: slideUp 0.18s ease;
}

@keyframes slideUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

.modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  background: var(--color-bg-alt);
  border: 1px solid var(--color-border);
  width: 30px;
  height: 30px;
  border-radius: 50%;
  font-size: 0.8rem;
  color: var(--color-text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition);
}

.modal-close:hover { background: var(--color-border); color: var(--color-text); }

.modal-box h2 {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-text-muted);
  margin-bottom: 4px;
}

.modal-place-name {
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: var(--space-lg);
  color: var(--color-text);
}

.modal-desc {
  font-size: 0.8rem;
  color: var(--color-text-muted);
  margin-bottom: var(--space-sm);
}

.nav-options { display: flex; flex-direction: column; gap: 6px; }

.nav-option-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--color-bg-alt);
  border: 1px solid var(--color-border);
  color: var(--color-text);
  padding: 11px 16px;
  border-radius: var(--radius-md);
  font-size: 0.875rem;
  font-weight: 500;
  text-decoration: none;
  transition: all var(--transition);
}

.nav-option-btn:hover {
  background: var(--color-text);
  border-color: var(--color-text);
  color: #fff;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.4);
  z-index: 999;
  backdrop-filter: blur(4px);
}
.modal-backdrop[hidden] { display: none; }

/* ══════════════════════════════════════════════════════════
   FOOTER
══════════════════════════════════════════════════════════ */
.site-footer {
  background: var(--color-bg-alt);
  border-top: 1px solid var(--color-border);
  padding: 12px var(--content-px);
  margin-top: auto;
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  text-align: center;
}

.footer-legal {
  font-size: 0.7rem;
  color: var(--color-text-muted);
  line-height: 1.5;
}

.footer-company {
  color: var(--color-text);
  font-weight: 700;
}

.footer-meta {
  font-size: 0.7rem;
  color: var(--color-text-light);
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 6px;
}

.footer-meta a {
  color: var(--color-text-muted);
  text-decoration: none;
}
.footer-meta a:hover { color: var(--color-accent); }

.footer-sep { color: var(--color-text-light); }

/* ══════════════════════════════════════════════════════════
   RESPONSIVE
══════════════════════════════════════════════════════════ */
@media (max-width: 768px) {
  :root { --content-px: 1rem; }

  .leaflet-control-zoom { display: none !important; }


  .brand-tagline { font-size: 0.6rem; letter-spacing: 0.05em; }
  .brand-name { font-size: 1rem; }
  .pdf-label { display: none; }
  .pdf-btn { padding: 8px 10px; }

  /* Welcome section on mobile: full-bleed dark fills the page with extra dark space below the cards */
  .main-content { display: flex; flex-direction: column; }
  #tab-welcome { display: flex; flex-direction: column; flex: 1; padding: 0; }
  .welcome-hero {
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
    margin-bottom: 0;
    flex: 1 0 auto;
  }
  .welcome-info {
    margin: 0 1rem 1rem;
  }
  .welcome-info .info-row {
    grid-template-columns: 1fr;
    grid-template-areas:
      "icon"
      "label"
      "body";
    justify-items: center;
    text-align: center;
    row-gap: 0.75rem;
    padding: 1.5rem 0;
  }
  .welcome-info .info-icon  { grid-area: icon; width: 40px; height: 40px; }
  .welcome-info .info-icon svg { width: 18px; height: 18px; }
  .welcome-info .info-label { grid-area: label; font-size: 1.15rem; }
  .welcome-info .info-body  { grid-area: body; }
  .welcome-info .contact-line { justify-content: center; }
  /* Red accent bar spans the entire overlay on mobile */
  .welcome-overlay::before { bottom: 0; }

  /* Center-align overlay content on mobile to match the info rows */
  .welcome-overlay { text-align: center; }
  .welcome-subtitle { margin-left: auto; margin-right: auto; }

  /* Left-align tabs on mobile — centered flex + overflow-x causes left side to be unreachable */
  .tab-nav-inner { justify-content: flex-start; }
  .tab-btn { padding: 10px 12px; font-size: 0.72rem; }

  /* Welcome hero overlay: align with page gutter on mobile */
  .welcome-overlay { padding: var(--space-xl) var(--content-px); }

  /* Stack cards vertically on mobile */
  .place-card {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-sm);
  }

  .place-card:hover {
    margin: 0;
    padding-left: 0;
    padding-right: 0;
  }

  .place-card.featured::before { display: none; }

  .place-img { width: 100%; height: 160px; flex: none; }
  .place-card-header { flex: none; width: 100%; }
  .place-desc { -webkit-line-clamp: 3; }
  .place-meta { align-items: flex-start; width: 100%; }
  .place-hours { align-items: flex-start; }


  .transport-grid { grid-template-columns: 1fr 1fr; }
  .tips-grid { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
  .tab-btn { padding: 10px 8px; font-size: 0.65rem; letter-spacing: 0.06em; }
  .transport-grid { grid-template-columns: 1fr; }

  /* Header: tighten spacing on very small screens */
  .header-inner { gap: var(--space-sm); }
  .lang-btn { padding: 4px 8px; }
}

/* ══════════════════════════════════════════════════════════
   PRINT / PDF
══════════════════════════════════════════════════════════ */
@media print {
  .site-header, .tab-nav, .filter-row, .pdf-btn,
  .nav-btn, .modal, .modal-backdrop, .map-panel, #tab-map { display: none !important; }

  body { background: #fff; font-size: 10pt; }

  .tab-panel { display: block !important; page-break-before: always; padding: 20pt; }
  .tab-panel:first-child { page-break-before: avoid; }

  .place-card { page-break-inside: avoid; }
  a { text-decoration: none; color: inherit; }
}

/* ══════════════════════════════════════════════════════════
   HIGH CONTRAST & REDUCED MOTION
══════════════════════════════════════════════════════════ */
@media (prefers-contrast: high) {
  :root { --color-border: #888; --color-text-muted: #333; }
  .place-card { border-bottom-width: 2px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
  html { scroll-behavior: auto; }
}
