:root {
  --paper:  #f0e6d0;
  --ink:    #1a1008;
  --sepia:  #7a5535;
  --gold:   #c8922a;
  --rust:   #9e3a1a;
  --mist:   rgba(26,16,8,0.72);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html, body {
  width: 100%; height: 100%;
  overflow: hidden;
  background: var(--ink);
  font-family: 'Cormorant Garamond', serif;
}

/* ═══════════════════════════ TOP NAV ══ */
#top-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 2000;
  height: 50px;
  background: rgba(6,3,1,0.97);
  border-bottom: 1px solid rgba(200,146,42,0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  padding: 0 1.4rem;
  backdrop-filter: blur(12px);
}

.nav-brand {
  font-family: 'IM Fell English', serif;
  font-size: 1.05rem;
  color: var(--paper);
  white-space: nowrap;
  cursor: pointer;
  transition: color 0.2s;
}

.nav-brand:hover { color: var(--gold); }

.nav-brand em { color: var(--gold); font-style: italic; }

.nav-tabs { display: flex; height: 100%; gap: 0.2rem; }

.nav-tab {
  background: none;
  border: none;
  border-bottom: 2.5px solid transparent;
  color: rgba(240,230,208,0.68);
  font-family: 'Cormorant Garamond', serif;
  font-size: 0.88rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 0 1.4rem;
  cursor: pointer;
  height: 100%;
  transition: color 0.2s, border-color 0.2s, background 0.2s;
}

.nav-tab:hover  { color: var(--paper); background: rgba(200,146,42,0.06); }
.nav-tab.active { color: var(--gold); border-bottom-color: var(--gold); background: rgba(200,146,42,0.08); }

/* ─── F-21: Search ──────────────────────────────────── */
.nav-search {
  position: relative;
  display: flex;
  align-items: center;
}

.search-icon {
  position: absolute;
  left: 0.55rem;
  color: rgba(200,146,42,0.55);
  pointer-events: none;
  flex-shrink: 0;
}

#search-input {
  background: rgba(200,146,42,0.06);
  border: 1px solid rgba(200,146,42,0.2);
  color: var(--paper);
  font-family: 'Cormorant Garamond', serif;
  font-size: 0.85rem;
  padding: 0.32rem 0.7rem 0.32rem 2rem;
  width: 175px;
  transition: border-color 0.2s, width 0.25s;
}

#search-input:focus {
  border-color: rgba(200,146,42,0.5);
  width: 230px;
  outline: none;
}

#search-input:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 2px;
}

#search-input::placeholder { color: rgba(200,160,90,0.3); }

.search-results {
  display: none;
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  min-width: 240px;
  background: rgba(13,8,5,0.98);
  border: 1px solid rgba(200,146,42,0.25);
  backdrop-filter: blur(12px);
  z-index: 3000;
  max-height: 300px;
  overflow-y: auto;
}

.search-results.visible { display: block; }

.search-result-item {
  padding: 0.6rem 0.9rem;
  cursor: pointer;
  font-family: 'Cormorant Garamond', serif;
  font-size: 1rem;
  color: rgba(240,230,208,0.8);
  border-bottom: 1px solid rgba(200,146,42,0.08);
  transition: background 0.15s, color 0.15s;
}

.search-result-item:last-child { border-bottom: none; }

.search-result-item:hover,
.search-result-item.focused {
  background: rgba(200,146,42,0.1);
  color: var(--gold);
}

.search-no-results {
  padding: 0.6rem 0.9rem;
  font-family: 'Cormorant Garamond', serif;
  font-size: 0.9rem;
  color: rgba(240,230,208,0.35);
}

/* ═══════════════════════ CONTENT SCREENS ══ */
.content-screen {
  position: fixed;
  top: 50px; left: 0; right: 0; bottom: 0;
  background: #0d0805;
  overflow-y: auto;
  display: none;
  z-index: 100;
}

.content-screen.active { display: block; }

.content-inner {
  max-width: 820px;
  margin: 0 auto;
  padding: 3rem 2rem 4rem;
  color: var(--paper);
}

.content-inner h1 {
  font-family: 'IM Fell English', serif;
  font-size: clamp(1.8rem, 4vw, 2.4rem);
  color: var(--gold);
  font-weight: normal;
  margin-bottom: 1.4rem;
}

.content-inner h2 {
  font-family: 'IM Fell English', serif;
  font-size: 1.2rem;
  color: var(--paper);
  font-weight: normal;
  margin: 2.2rem 0 0.7rem;
  border-bottom: 1px solid rgba(200,146,42,0.15);
  padding-bottom: 0.4rem;
}

/* RV-42: > p (direct child only) — previne specificitate prea largă ce forțase !important pe .donation-tagline/.donation-note */
.content-inner > p {
  font-size: clamp(0.95rem, 1.6vw, 1.05rem);
  line-height: 1.85;
  color: rgba(240,230,208,0.75);
  margin-bottom: 1rem;
}

.content-inner em { color: var(--gold); font-style: italic; }

.content-center { text-align: center; max-width: 580px; }

/* ─── Fact grid ────────── */
.fact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.1rem;
  margin-top: 1.8rem;
}

.fact-card {
  background: rgba(200,146,42,0.05);
  border: 1px solid rgba(200,146,42,0.16);
  padding: 1.4rem 1.5rem;
  transition: border-color 0.2s;
}

.fact-card:hover { border-color: rgba(200,146,42,0.35); }

.fact-card h3 {
  font-family: 'IM Fell English', serif;
  font-size: 1.05rem;
  color: var(--gold);
  font-weight: normal;
  margin-bottom: 0.6rem;
}

.fact-card p {
  font-size: 0.95rem;
  line-height: 1.8;
  color: rgba(240,230,208,0.82);
  margin: 0;
}

.fact-card p em { color: var(--gold); font-style: italic; }

.fact-category {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-top: 1.2rem;
}

.fact-category:first-child { margin-top: 0; }

.fact-category-label {
  font-family: 'IM Fell English', serif;
  font-size: 0.78rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gold);
  white-space: nowrap;
  opacity: 0.88;
}

.fact-category-line {
  flex: 1;
  height: 1px;
  background: rgba(200,146,42,0.15);
}

/* ─── Disclaimer box ────── */
.disclaimer-box {
  margin: 1.2rem 0;
  padding: 0.9rem 1.1rem;
  background: rgba(200,146,42,0.06);
  border-left: 3px solid var(--gold);
  border-radius: 4px;
  font-size: 0.9rem;
  color: rgba(240,230,208,0.75);
  line-height: 1.6;
}

/* ─── Contact form ─────── */
.contact-form {
  margin-top: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}

.contact-form input,
.contact-form textarea {
  background: rgba(200,146,42,0.04);
  border: 1px solid rgba(200,146,42,0.2);
  color: var(--paper);
  font-family: 'Cormorant Garamond', serif;
  font-size: 1rem;
  padding: 0.7rem 1rem;
  transition: border-color 0.2s;
  width: 100%;
  resize: vertical;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
  color: rgba(200,160,90,0.35);
}

.contact-form input:focus,
.contact-form textarea:focus {
  border-color: rgba(200,146,42,0.5);
  outline: none; /* mouse focus — border-color e suficient */
}

/* RV-41: focus indicator vizibil pentru navigare cu tastatura (WCAG 2.4.11) */
.contact-form input:focus-visible,
.contact-form textarea:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 2px;
}

.contact-form textarea { min-height: 120px; }

.cf-upload-row {
  display: flex;
  gap: 0.5rem;
  align-items: stretch;
}

.cf-upload-label {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.65rem 1rem;
  background: rgba(200,146,42,0.04);
  border: 1px dashed rgba(200,146,42,0.3);
  border-radius: 3px;
  color: rgba(200,160,90,0.6);
  font-size: 0.85rem;
  letter-spacing: 0.03em;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s;
}

.cf-upload-label:hover,
.cf-upload-label.has-files { border-color: rgba(200,146,42,0.6); color: var(--gold); }

.cf-upload-label input[type="file"] { display: none; }

.cf-upload-clear {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  background: rgba(158,58,26,0.15);
  border: 1px solid rgba(158,58,26,0.4);
  border-radius: 3px;
  color: var(--rust);
  font-size: 1.2rem;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s;
}

.cf-upload-clear:hover { background: rgba(158,58,26,0.3); border-color: var(--rust); }

.btn-submit {
  align-self: flex-start;
  padding: 0.7rem 2rem;
  background: transparent;
  border: 1px solid var(--gold);
  color: var(--gold);
  font-family: 'IM Fell English', serif;
  font-size: 0.9rem;
  letter-spacing: 0.12em;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}

.btn-submit:hover { background: var(--gold); color: var(--ink); }

/* ─── Contribution list ─── */
.contrib-list {
  list-style: none;
  margin: 0.6rem 0 1rem;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.contrib-list li {
  font-size: clamp(0.9rem, 1.5vw, 1rem);
  line-height: 1.6;
  color: rgba(240,230,208,0.7);
  padding-left: 1.2rem;
  position: relative;
}

.contrib-list li::before {
  content: '—';
  position: absolute;
  left: 0;
  color: var(--gold);
  opacity: 0.6;
}

.contrib-list li strong { color: var(--paper); font-weight: 600; }

/* ─── Form status ──────── */
.cf-status {
  padding: 0.7rem 1rem;
  font-size: 0.9rem;
  font-style: italic;
  border: 1px solid;
}

.cf-ok  { color: #7ecb7e; border-color: rgba(126,203,126,0.3); background: rgba(126,203,126,0.06); }
.cf-err { color: #e07070; border-color: rgba(224,112,112,0.3); background: rgba(224,112,112,0.06); }

/* ─── Donation box ─────── */
.donation-box {
  border: 1px solid rgba(200,146,42,0.25);
  padding: 2.5rem 2rem;
  margin: 2rem 0;
}

.donation-tagline {
  font-family: 'IM Fell English', serif;
  font-size: 1.15rem;
  color: var(--gold);
  margin-bottom: 1.2rem;
}

.donate-buttons {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
  margin: 0.4rem 0;
}

.btn-donate {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.85rem 2.2rem;
  font-family: 'IM Fell English', serif;
  font-size: 1rem;
  letter-spacing: 0.1em;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
}

.btn-revolut {
  background: #191C33;
  color: #fff;
  border: 1px solid rgba(255,255,255,0.15);
}

.btn-revolut:hover {
  background: #2a2e4a;
  transform: translateY(-2px);
  box-shadow: 0 4px 20px rgba(0,0,0,0.4);
}

.btn-paypal {
  background: #0070BA;
  color: #fff;
}

.btn-paypal:hover {
  background: #005ea6;
  transform: translateY(-2px);
  box-shadow: 0 4px 20px rgba(0,0,0,0.4);
}

.donation-note {
  margin-top: 1rem;
  font-size: 0.72rem;
  color: rgba(120,90,55,0.55);
  letter-spacing: 0.08em;
}

/* ─── F-16: Filter bar ──────────────────────────────── */
.map-filter-bar {
  position: absolute;
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1000;
  display: flex;
  gap: 0.4rem;
  pointer-events: all;
  flex-wrap: wrap;
  justify-content: center;
  max-width: calc(100vw - 2rem);
}

.filter-btn {
  background: rgba(13,8,5,0.88);
  border: 1px solid rgba(200,146,42,0.25);
  color: rgba(240,230,208,0.85);
  font-family: 'Cormorant Garamond', serif;
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.28rem 0.75rem;
  cursor: pointer;
  backdrop-filter: blur(8px);
  transition: color 0.2s, border-color 0.2s, background 0.2s;
  white-space: nowrap;
}

.filter-btn:hover {
  color: var(--paper);
  border-color: rgba(200,146,42,0.5);
}

.filter-btn.active {
  color: var(--gold);
  border-color: var(--gold);
  background: rgba(200,146,42,0.12);
}

/* ═══════════════════════════ MAP SCREEN ══ */
#map-screen {
  position: fixed;
  top: 50px; left: 0; right: 0; bottom: 0;
  display: flex;
  flex-direction: column;
  transition: opacity 0.6s ease, transform 0.6s ease;
}

#map-screen.hidden {
  opacity: 0;
  transform: scale(0.97);
  pointer-events: none;
}


#map {
  width: 100%;
  height: 100%;
  filter: sepia(35%) contrast(0.9) brightness(0.88);
}

.leaflet-container { background: #b8a485; }

/* Container hint + buton locație — pe desktop lasă copiii să se poziționeze absolut */
.map-bottom-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 100px;   /* suficient pt btn la 70px + înălțimea sa */
  z-index: 1000;
  pointer-events: none;
}

.map-hint {
  position: absolute;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--mist);
  border: 1px solid rgba(200,146,42,0.35);
  color: var(--paper);
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  padding: 0.5rem 1.4rem;
  text-transform: uppercase;
  backdrop-filter: blur(6px);
  animation: pulse 3s ease infinite;
  pointer-events: none;
  white-space: nowrap;
}

@keyframes pulse { 0%,100%{opacity:.65} 50%{opacity:1} }

/* custom marker */
.pin-outer { width:36px; height:52px; position:relative; cursor:pointer; }

.pin-circle {
  width:22px; height:22px;
  background: var(--rust);
  border: 2.5px solid var(--gold);
  border-radius: 50%;
  position: absolute;
  top:0; left:7px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.5);
  transition: transform 0.2s, background 0.2s;
}

.pin-circle::after {
  content:'';
  position:absolute;
  bottom:-8px; left:50%;
  transform:translateX(-50%);
  border-left:5px solid transparent;
  border-right:5px solid transparent;
  border-top:9px solid var(--rust);
}

.pin-outer:hover .pin-circle {
  background: var(--gold);
  transform: scale(1.2) translateY(-3px);
}

.pin-outer:hover .pin-circle::after { border-top-color: var(--gold); }

.pin-label {
  position:absolute;
  bottom:-22px; left:50%;
  transform:translateX(-50%);
  white-space:nowrap;
  font-size:0.68rem;
  font-style:italic;
  color:var(--paper);
  text-shadow: 0 1px 4px rgba(0,0,0,0.95), 0 0 8px rgba(0,0,0,0.7);
  pointer-events:none;
  background: rgba(6,3,1,0.78);
  border: 1px solid rgba(200,146,42,0.25);
  padding: 2px 7px;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.pin-outer:hover .pin-label {
  opacity: 1;
}



/* ═══════════════════════════ VIEW SCREEN ══ */
#view-screen {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.72);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
  z-index: 1500;
}

#view-screen.active {
  opacity: 1;
  pointer-events: all;
}

/* ─── Popup container (split layout) ─── */
.view-popup {
  width: 78vw;
  max-width: 1100px;
  height: 72vh;
  display: flex;
  flex-direction: row;
  background: #0d0805;
  border: 1px solid rgba(200,146,42,0.22);
  box-shadow: 0 24px 80px rgba(0,0,0,0.9), 0 0 0 1px rgba(200,146,42,0.06);
  overflow: hidden;
}

/* ─── Left: photo column ─── */
.popup-left {
  flex: 1;
  display: flex;
  flex-direction: column;
  background: #080503;
  min-width: 0;
  position: relative; /* F-5: anchor pentru #tl-thumb */
}

.popup-photo-area {
  flex: 1;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  min-height: 0;
}

.popup-photo-area::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 25%;
  background: linear-gradient(180deg, rgba(0,0,0,0.55) 0%, transparent 100%);
  z-index: 2; pointer-events: none;
}

/* ─── Timeline bar below photo ─── */
.popup-timeline-bar {
  flex-shrink: 0;
  min-height: 48px;
  background: rgba(6,3,1,0.97);
  border-top: 1px solid rgba(200,146,42,0.12);
  align-items: center;
  justify-content: flex-start;
  flex-wrap: nowrap;
  gap: 0;
  padding: 0 1rem;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scroll-behavior: smooth;
  scrollbar-width: none;
}

.popup-timeline-bar::-webkit-scrollbar { display: none; }

/* ─── Right: info panel ─── */
.popup-right {
  width: 320px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  border-left: 1px solid rgba(200,146,42,0.12);
  padding: 1.6rem 2rem 1.5rem;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(200,146,42,0.15) transparent;
}

/* back button */
.btn-back {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: transparent;
  border: 1px solid rgba(200,146,42,0.28);
  color: rgba(240,230,208,0.55);
  font-family: 'Cormorant Garamond', serif;
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  padding: 0.38rem 0.8rem;
  cursor: pointer;
  align-self: flex-start;
  margin-bottom: 1.8rem;
  transition: border-color 0.2s, color 0.2s;
}

.btn-back:hover { border-color: rgba(200,146,42,0.55); color: var(--paper); }

/* F-12: share button */
.btn-share {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: transparent;
  border: 1px solid rgba(200,146,42,0.22);
  color: rgba(240,230,208,0.45);
  font-family: 'Cormorant Garamond', serif;
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  padding: 0.38rem 0.8rem;
  cursor: pointer;
  align-self: flex-start;
  margin-top: 1rem;
  transition: border-color 0.2s, color 0.2s;
}

.btn-share:hover { border-color: rgba(200,146,42,0.55); color: var(--paper); }

/* info content */
.popup-info {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.view-year {
  font-family: 'IM Fell English', serif;
  font-size: 0.7rem;
  color: var(--gold);
  letter-spacing: 0.28em;
  text-transform: uppercase;
  margin-bottom: 0.55rem;
  opacity: 0.85;
}

.view-title {
  font-family: 'IM Fell English', serif;
  font-size: clamp(1.35rem, 2.2vw, 1.9rem);
  color: var(--paper);
  line-height: 1.2;
  font-weight: normal;
  margin-bottom: 1.1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid rgba(200,146,42,0.1);
}

.view-desc {
  font-size: 0.95rem;
  font-style: italic;
  color: rgba(240,230,208,0.75);
  line-height: 1.8;
  flex: 1;
}

/* Sursă per fotografie — sub foto, discret */
.photo-source-line {
  font-size: 0.6rem;
  color: rgba(160, 135, 95, 0.5);
  text-align: right;
  padding: 3px 8px 2px;
  font-family: sans-serif;
  letter-spacing: 0.03em;
  line-height: 1.4;
  min-height: 18px;
}

.kb-hint {
  margin-top: 0.9rem;
  font-size: 0.6rem;
  letter-spacing: 0.1em;
  color: rgba(120,90,55,0.35);
  text-align: right;
  pointer-events: none;
}

/* RV-22: picture wrapper transparent pentru layout */
.popup-photo-area picture { display: contents; }

/* photo */
.view-photo {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  filter: sepia(50%) contrast(0.88) brightness(0.82);
  display: block;
  position: relative;
  z-index: 1;
  box-shadow: 0 8px 60px rgba(0,0,0,0.85);
}

.view-placeholder {
  width: 100%; height: 100%;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: 1rem;
  background: radial-gradient(ellipse at center, #2a1a0a 0%, #0d0805 70%);
  color: var(--sepia);
}

.view-placeholder svg { opacity: 0.2; }

.view-placeholder p {
  font-style: italic; font-size: 1.1rem;
  opacity: 0.45; letter-spacing: 0.1em;
}

/* grain */
.grain {
  position:absolute; inset:0; z-index:3; pointer-events:none;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.07'/%3E%3C/svg%3E");
  opacity:0.5; mix-blend-mode:overlay;
}

/* scanlines */
.scanlines {
  position:absolute; inset:0; z-index:3; pointer-events:none;
  background: repeating-linear-gradient(0deg, transparent, transparent 2px, rgba(0,0,0,0.025) 2px, rgba(0,0,0,0.025) 4px);
}

/* ══════════════════════ PHOTO TIMELINE DOTS ══ */
.tl-dot {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.3rem 0.6rem;
  flex-shrink: 0;
}

/* F-5: floating thumbnail preview — poziționat față de .popup-left */
#tl-thumb {
  position: absolute;
  bottom: 56px; /* deasupra timeline bar (~48px) + gap */
  width: 100px;
  height: 70px;
  background-size: cover;
  background-position: center;
  border: 1px solid rgba(200,146,42,0.45);
  box-shadow: 0 4px 20px rgba(0,0,0,0.8);
  filter: sepia(30%);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s;
  transform: translateX(-50%);
  z-index: 20;
}

#tl-thumb.visible { opacity: 1; }

.tl-circle {
  width: 9px; height: 9px;
  border-radius: 50%;
  background: var(--sepia);
  border: 1.5px solid rgba(200,146,42,0.3);
  transition: background 0.2s, transform 0.2s, border-color 0.2s;
}

.tl-dot.active .tl-circle {
  background: var(--gold);
  border-color: var(--gold);
  transform: scale(1.35);
}

.tl-dot:hover .tl-circle {
  background: var(--gold);
  border-color: var(--gold);
}

.tl-year {
  font-family: 'IM Fell English', serif;
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  color: rgba(200,160,90,0.45);
  transition: color 0.2s;
}

.tl-dot.active .tl-year { color: var(--gold); }
.tl-dot:hover .tl-year  { color: var(--paper); }

.tl-line {
  width: 36px; height: 1px;
  background: rgba(200,146,42,0.2);
  align-self: center;
  margin-bottom: 1.1rem;
  flex-shrink: 0;
}

/* ─── Loading spinner (RV-8) ─── */
@keyframes spin { to { transform: translate(-50%, -50%) rotate(360deg); } }

.popup-photo-area.is-loading::after {
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 28px; height: 28px;
  border: 2px solid rgba(200,146,42,0.15);
  border-top-color: var(--gold);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  z-index: 10;
}

/* fade-in animation */
@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.fade-in { animation: fadeIn 0.9s ease forwards; }

/* ══════════════════════ MOBILE — tablet ══ */
@media (max-width: 768px) {
  .view-popup  { width: 96vw; height: 86vh; flex-direction: column; }
  .popup-right { width: 100%; flex-shrink: 0; border-left: none; border-top: 1px solid rgba(200,146,42,0.12); padding: 1rem 1.2rem; max-height: 40%; overflow-y: auto; }
  .view-desc   { display: none; }
  .kb-hint     { display: none; }
}

/* ══════════════════════ MOBILE — telefon ══ */
@media (max-width: 600px) {
  /* Navbar — tabs pe toată lățimea, brand ascuns */
  #top-nav    { gap: 0; padding: 0; justify-content: flex-start; }
  .nav-brand  { display: none; }
  .nav-search { display: none; }
  .nav-tabs   { flex: 1; gap: 0; }
  .nav-tab    { flex: 1; text-align: center; padding: 0 0.3rem; font-size: 0.72rem; letter-spacing: 0.05em; }

  /* Filter bar — scroll orizontal pe mobile */
  .map-filter-bar {
    top: 6px;
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
    justify-content: flex-start;
    padding: 0 0.5rem;
  }
  .filter-btn { font-size: 0.68rem; padding: 0.22rem 0.6rem; flex-shrink: 0; }

  /* Map bottom bar — rând flex pe mobile */
  .map-bottom-bar {
    height: auto;
    bottom: 8px;
    left: 8px;
    right: 8px;
    display: flex;
    flex-direction: row;
    align-items: stretch;
    gap: 6px;
  }

  /* Map hint — flow normal în flex, nu mai e absolut */
  .map-hint {
    position: static;
    transform: none;
    flex: 1;
    font-size: 0.65rem;
    padding: 0.4rem 0.9rem;
    white-space: normal;
    text-align: center;
    max-width: none;
  }

  /* Buton locație — pătrat, icon only, flow normal în flex */
  .btn-locate {
    position: static;
    flex-shrink: 0;
    width: 36px;
    padding: 0;
    justify-content: center;
    border-radius: 0;
  }
  .btn-locate span { display: none; }

  /* Toast eroare — mai sus ca să nu acopere bara de jos */
  .geo-error { bottom: 60px; }

  /* Pin labels — mereu vizibile (touch nu are hover) */
  .pin-label { opacity: 1; }

  /* Content screens — padding mai mic */
  .content-inner { padding: 1.5rem 1rem 3rem; }

  /* Fact grid — o singură coloană */
  .fact-grid { grid-template-columns: 1fr; }

  /* Popup — fullscreen pe telefon */
  .view-popup  { width: 100vw; height: 100svh; border: none; border-radius: 0; }
  .popup-right { max-height: 44%; padding: 0.75rem 1rem 0.5rem; }
  .btn-back    { margin-bottom: 0.6rem; }

  /* Formular contact */
  .contact-form textarea { min-height: 80px; }
  .btn-submit { align-self: stretch; justify-content: center; font-size: 1rem; padding: 0.9rem 1rem; }

  /* Butoane donații — full width pe ecrane mici */
  .donate-buttons { flex-direction: column; align-items: stretch; }
  .btn-donate     { justify-content: center; }

  /* Cookie banner — mobil */
  #cookie-banner  { flex-direction: column; align-items: flex-start; gap: 0.9rem; }
  .cookie-actions { width: 100%; justify-content: flex-end; }
}

/* ══════════════════════ COOKIE CONSENT BANNER ══ */
#cookie-banner {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 3000;
  background: rgba(8, 4, 2, 0.97);
  border-top: 1px solid rgba(200,146,42,0.3);
  display: flex;
  align-items: center;
  gap: 1.5rem;
  padding: 0.9rem 1.6rem;
  backdrop-filter: blur(10px);
  font-family: 'Cormorant Garamond', serif;
}

.cookie-text {
  flex: 1;
  font-size: 0.82rem;
  line-height: 1.6;
  color: rgba(240,230,208,0.65);
  letter-spacing: 0.02em;
}

.cookie-text strong {
  color: var(--gold);
  font-weight: 600;
}

.cookie-text a {
  color: rgba(200,146,42,0.6);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.cookie-text a:hover { color: var(--gold); }

.cookie-actions {
  display: flex;
  gap: 0.6rem;
  flex-shrink: 0;
}

.cookie-actions button {
  font-family: 'IM Fell English', serif;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  padding: 0.45rem 1.2rem;
  cursor: pointer;
  border: 1px solid;
  transition: background 0.2s, color 0.2s;
  text-transform: uppercase;
}

#cookie-reject {
  background: transparent;
  border-color: rgba(200,146,42,0.25);
  color: rgba(240,230,208,0.4);
}

#cookie-reject:hover {
  border-color: rgba(200,146,42,0.5);
  color: rgba(240,230,208,0.7);
}

#cookie-accept {
  background: transparent;
  border-color: var(--gold);
  color: var(--gold);
}

#cookie-accept:hover {
  background: var(--gold);
  color: var(--ink);
}

/* ══════════════════════════ F-17: GEOCALIZARE ══ */

/* Buton "Unde mă aflu?" — colț dreapta-jos pe hartă */
.btn-locate {
  position: absolute;
  bottom: 70px;
  right: 16px;
  z-index: 1000;
  pointer-events: auto;
  display: flex;
  align-items: center;
  gap: 0.45rem;
  background: var(--mist);
  border: 1px solid rgba(200,146,42,0.35);
  color: var(--paper);
  font-family: 'IM Fell English', serif;
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  padding: 0.45rem 0.9rem;
  cursor: pointer;
  backdrop-filter: blur(6px);
  transition: border-color 0.2s, color 0.2s, background 0.2s;
  white-space: nowrap;
}

.btn-locate:hover {
  border-color: rgba(200,146,42,0.7);
  color: var(--gold);
}

.btn-locate:disabled {
  opacity: 0.6;
  cursor: default;
}

.btn-locate.geo-active {
  border-color: #4a9eff;
  color: #4a9eff;
}

/* Marker pulsating — poziția utilizatorului */
.geo-dot {
  width: 14px;
  height: 14px;
  background: #4a9eff;
  border: 2.5px solid #fff;
  border-radius: 50%;
  box-shadow: 0 2px 8px rgba(0,0,0,0.5);
  position: relative;
}

.geo-pulse {
  position: absolute;
  top: 50%; left: 50%;
  width: 14px; height: 14px;
  background: rgba(74,158,255,0.45);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  animation: geo-ring 1.8s ease-out infinite;
}

@keyframes geo-ring {
  0%   { width: 14px; height: 14px; opacity: 0.8; }
  100% { width: 44px; height: 44px; opacity: 0;   }
}

/* Pinii din raza de 300m — evidențiați cu auriu */
.pin-nearby .pin-circle {
  background: var(--gold);
  box-shadow: 0 0 12px rgba(200,146,42,0.7);
}
.pin-nearby .pin-circle::after { border-top-color: var(--gold); }
.pin-nearby .pin-label { opacity: 1; }

/* Toast eroare geocalizare */
.geo-error {
  position: absolute;
  bottom: 110px;
  right: 16px;
  z-index: 1001;
  background: rgba(158,58,26,0.95);
  border: 1px solid rgba(200,146,42,0.3);
  color: var(--paper);
  font-family: 'Cormorant Garamond', serif;
  font-size: 0.8rem;
  padding: 0.5rem 1rem;
  max-width: 260px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
  backdrop-filter: blur(6px);
}

.geo-error.visible { opacity: 1; }
