@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@700&display=swap');

html, body {
    height: 100%;
    margin: 0;
    padding: 0;
    background: #000;
}

body {
    font-family: Arial, sans-serif;
    background: #f4f4f4;
    margin: 0;
    padding: 0;
    text-align: center;
}

h1 {
    color: #333;
    margin-top: 40px;
}

button {
    padding: 10px 20px;
    font-size: 16px;
    margin-top: 20px;
    cursor: pointer;
    background: #0078d7;
    color: #fff;
    border: none;
    border-radius: 4px;
}

button:hover {
    background: #3e3e3e;
}

.site-header {
    position: fixed;
    top: 0; left: 0; right: 0;
    height: 56px;
    background: rgba(0, 0, 0, 0.96);
    display: flex;
    align-items: center;
    justify-content: space-between;
    z-index: 13000;
    padding: 0 24px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.12);
}

.header-left,
.header-right {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    height: 56px;
}

.header-center {
    flex: 1 1 auto;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 56px;
}

.header-left {
    justify-content: flex-start;
}

.header-right {
    justify-content: flex-end;
}

.header-icon {
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    border-radius: 50%;
    transition: background 0.2s;
    display: flex;
    align-items: center;
    height: 40px;
    margin-top: 0px; /* смещаем чуть выше */
}

.header-icon svg {
    display: block;
    margin-top: 0; /* убираем лишнее смещение, если было */
}

.header-left .site-title {
    display: none;
}

.header-center .site-title {
    font-family: 'Montserrat', Arial, sans-serif;
    font-size: 1.5em;
    font-weight: 700;
    color: #fff;
    letter-spacing: 1px;
    text-align: center;
}

#map {
    position: absolute;
    top: 56px;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100vw;
    height: calc(100vh - 56px);
    margin: 0;
    border-radius: 0;
    box-shadow: none;
    background: #131313 !important; /* или другой темный цвет */
}
/* Delete this before realese */
.leaflet-control-attribution {
    display: none !important;
}

#nearby-panel {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    height: 60px;
    background: #0b0b0bfa; /* более темный фон */
    border-top-left-radius: 18px;
    border-top-right-radius: 18px;
    box-shadow: 0 -2px 24px rgba(0,0,0,0.28);
    z-index: 10002;
    transition: height 0.25s cubic-bezier(.4,.4,.6,1), background 0.2s;
    overflow: hidden;
    pointer-events: auto;
}

#nearby-panel.open {
    height: 80vh; /* открывается выше */
    background: #0b0b0bfa; /* еще темнее при открытии */
}

#nearby-panel-handle {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: pointer;
    padding-top: 8px;
    padding-bottom: 8px;
    user-select: none;
}

.handle-bar {
    width: 44px;
    height: 6px;
    background: #444;
    border-radius: 3px;
    margin-bottom: 6px;
    display: block;
}

.nearby-title {
    color: #fff;
    font-size: 1.1em;
    font-weight: 600;
    letter-spacing: 0.5px;
}

#nearby-list {
    padding: 12px 0 0 0;
    max-height: calc(80vh - 60px);
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.nearby-event {
    background: #232323;
    border-radius: 12px;
    margin: 0 18px;
    padding: 14px 16px 12px 16px;
    display: flex;
    align-items: center;
    gap: 14px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.10);
}

.nearby-dot {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    border: 2px solid #fff;
    flex-shrink: 0;
}

.nearby-info {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.nearby-title-main {
    color: #fff;
    font-weight: 600;
    font-size: 1.08em;
}

.nearby-time {
    color: #ffd600;
    font-size: 0.97em;
}

.nearby-place {
    color: #bbb;
    font-size: 0.97em;
}

.nearby-more-btn {
    padding: 6px 14px;
    border: none;
    border-radius: 6px;
    background: #ff2222;
    color: #fff;
    cursor: pointer;
    font-size: 1em;
    margin-left: 8px;
    transition: background 0.2s;
}

.nearby-more-btn:hover {
    background: #bb1818;
}

/* Модальное окно поверх всего */
#protest-modal {
    z-index: 20000 !important;
}

#burger-menu-overlay {
    position: fixed;
    z-index: 12000;
    top: 0; left: 0; right: 0; bottom: 0;
    background: transparent;
    pointer-events: none;
    transition: background 0.2s;
}

#burger-menu-overlay.open {
    background: rgba(10,10,15,0.45);
    pointer-events: auto;
}

#burger-menu {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: 300px;
    max-width: 90vw;
    background: #0b0b0b; /* под цвет шапки */
    box-shadow: 4px 0 32px rgba(0,0,0,0.25);
    padding: 72px 32px 32px 32px; /* сверху больше, чтобы не перекрывать шапку */
    color: #fff;
    border-top-right-radius: 18px;
    border-bottom-right-radius: 18px;
    z-index: 12001;
    transform: translateX(-100%);
    transition: transform 0.28s cubic-bezier(.4,.4,.6,1);
    display: flex;
    flex-direction: column;
    gap: 24px;
}

#burger-menu-overlay.open #burger-menu {
    transform: translateX(0);
}

#burger-menu-close {
    display: none;
}

#burger-menu ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

#burger-menu li {
    margin: 22px 0;
}

#burger-menu a {
    color: #fff;
    text-decoration: none;
    font-size: 1.18em;
    font-weight: 500;
    transition: color 0.2s;
}

#burger-menu a:hover {
    color: #ffd600;
}

.leaflet-popup-content-wrapper {
  background: transparent !important;
  box-shadow: none !important;
  border-radius: 14px !important;
  border: none !important;
}

.leaflet-popup-content {
  background: transparent !important;
  margin: 0 !important;
  padding: 0 !important;
}

#search-sidebar {
  position: fixed;
  top: 0;
  right: 0;
  width: 420px;
  max-width: 100vw;
  height: 100vh;
  background: rgba(35,35,35,0.7);
  backdrop-filter: blur(16px);
  color: #fff;
  z-index: 12000;
  box-shadow: -4px 0 32px #000a;
  border-radius: 18px 0 0 18px;
  transform: translateX(100%);
  transition: transform 0.3s;
  display: flex;
  flex-direction: column;
  padding-bottom: 24px;
}

@media (max-width: 700px) {
  #search-sidebar {
    width: 100vw;
    border-radius: 0;
  }
}

#search-sidebar.sidebar-open {
  transform: translateX(0);
}

#search-sidebar.sidebar-closed {
  transform: translateX(100%);
}

.sidebar-header {
  display: flex;
  align-items: center;
  padding: 64px 18px 16px 18px;
  background: transparent;
  border-bottom: 1px solid #444;
}

.sidebar-close-btn {
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 40px;
  margin-left: 8px;
  /* Центрируем по высоте строки поиска */
  align-self: center;
}

#sidebar-search {
  flex: 1 1 auto;
  padding: 10px 14px;
  font-size: 1.08em;
  border-radius: 8px;
  border: none;
  background: #181818cc;
  color: #fff;
  margin-right: 12px;
}

.sidebar-close-btn {
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

#sidebar-events-list {
  flex: 1 1 auto;
  overflow-y: auto;
  padding: 12px 0 0 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.sidebar-event-card {
  background: #282828cc;
  border-radius: 12px;
  margin: 0 18px;
  padding: 16px 14px 14px 14px;
  box-shadow: 0 2px 12px #0006;
  display: flex;
  flex-direction: column;
  gap: 8px;
  border: 2px solid;
  position: relative;
}

.sidebar-event-card.red { border-color: #ff1744; }
.sidebar-event-card.yellow { border-color: #ffd600; }
.sidebar-event-card.green { border-color: #00e676; }

.sidebar-event-title {
  font-weight: 700;
  font-size: 1.12em;
  color: #fff;
  text-align: left;
}

.sidebar-event-desc {
  font-size: 0.99em;
  color: #ccc;
  margin-bottom: 2px;
  max-height: 3.6em;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}

.sidebar-event-date {
  font-size: 0.97em;
  color: #bbb;
}

.sidebar-event-img {
  width: 100%;
  max-width: 320px;
  height: auto;
  object-fit: cover;
  border-radius: 8px;
  box-shadow: 0 2px 16px #000c;
  margin: 12px auto 2px auto; /* центрируем по горизонтали */
  display: block;
}

.sidebar-event-showmore {
  background:none;
  border:none;
  color:#fff;
  text-decoration:underline;
  cursor:pointer;
  font-size:0.95em;
  padding:0;
  margin-bottom:8px;
}