/* ── Reset & Base ── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  overflow: hidden;
  color: #1a1a1a;
  line-height: 1.5;
}

/* ── Map ── */
#map {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1;
}

/* ── Search Bar ── */
#search-bar {
  position: fixed;
  top: 16px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1000;
  display: flex;
  align-items: center;
  background: #fff;
  border-radius: 28px;
  box-shadow: 0 4px 18px rgba(0,0,0,.35);
  padding: 4px 4px 4px 16px;
  width: calc(100% - 160px);
  max-width: 480px;
}

#search-input {
  flex: 1;
  border: none;
  outline: none;
  font-size: 15px;
  background: transparent;
  padding: 8px 0;
}

#search-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: none;
  background: #3b82f6;
  color: #fff;
  font-size: 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

#search-btn:hover {
  background: #2563eb;
}

.search-dropdown {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  margin-top: 4px;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0,0,0,.15);
  max-height: 360px;
  overflow-y: auto;
}

.search-dropdown.visible {
  display: block;
}

.search-item {
  padding: 10px 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid #f3f4f6;
  font-size: 14px;
}

.search-item:last-child {
  border-bottom: none;
}

.search-item:hover {
  background: #f9fafb;
}

.search-item .search-icon {
  font-size: 18px;
  flex-shrink: 0;
}

.search-item .search-text {
  flex: 1;
  min-width: 0;
}

.search-item .search-text .name {
  font-weight: 500;
}

.search-item .search-text .sub {
  font-size: 12px;
  color: #6b7280;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.search-all-paris {
  color: #3b82f6;
  font-weight: 500;
  justify-content: center;
  padding: 12px 16px;
  background: #f0f7ff;
  border-radius: 0 0 12px 12px;
}

/* ── Search Banner ── */
#search-banner {
  position: fixed;
  top: 64px;
  left: 12px;
  right: 12px;
  z-index: 1000;
  background: #1e40af;
  color: #fff;
  padding: 8px 16px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
  font-weight: 500;
  box-shadow: 0 2px 12px rgba(0,0,0,.2);
}
#search-banner button {
  background: rgba(255,255,255,.2);
  color: #fff;
  border: none;
  padding: 4px 12px;
  border-radius: 6px;
  font-size: 13px;
  cursor: pointer;
  font-weight: 500;
  flex-shrink: 0;
}
#search-banner button:hover {
  background: rgba(255,255,255,.3);
}

/* ── Neighborhoods Panel ── */
#neighborhoods-panel {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1002;
  background: #fff;
  border-radius: 16px 16px 0 0;
  max-height: 60vh;
  transform: translateY(100%);
  transition: transform .3s cubic-bezier(.4,0,.2,1);
  padding: 20px;
  overflow-y: auto;
}

#neighborhoods-panel.open {
  transform: translateY(0);
}

.neighborhood-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 8px;
  cursor: pointer;
  border-bottom: 1px solid #f3f4f6;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 500;
  color: #374151;
  transition: background .15s;
  min-height: 44px;
}

.neighborhood-item:hover {
  background: #f3f4f6;
}

.neighborhood-item.active {
  background: #eff6ff;
  color: #3b82f6;
  font-weight: 600;
}

.neighborhood-item .nb-icon {
  font-size: 18px;
  width: 28px;
  text-align: center;
}

.neighborhood-item .nb-check {
  margin-left: auto;
  font-size: 16px;
  color: #3b82f6;
}

/* ── Refresh Button ── */
#refresh-btn {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 1000;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: none;
  background: #fff;
  box-shadow: 0 4px 18px rgba(0,0,0,.35);
  font-size: 22px;
  cursor: pointer;
  color: #6b7280;
  display: flex;
  align-items: center;
  justify-content: center;
}

#refresh-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 22px rgba(0,0,0,.4);
  color: #374151;
}

#refresh-btn:active {
  transform: scale(0.95);
}

/* ── FABs ── */
#fab-group {
  position: fixed;
  right: 16px;
  bottom: 24px;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.fab {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: none;
  background: #fff;
  box-shadow: 0 4px 18px rgba(0,0,0,.35);
  font-size: 20px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform .2s, box-shadow .2s;
}

.fab:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 22px rgba(0,0,0,.4);
}

.fab:active {
  transform: scale(0.95);
}

/* ── Overlay ── */
#overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0,0,0,.35);
  z-index: 1001;
}

#overlay.visible {
  display: block;
}

/* ── Bottom Sheet ── */
#sheet {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1003;
  background: #fff;
  border-radius: 16px 16px 0 0;
  max-height: 70vh;
  transform: translateY(100%);
  transition: transform .3s cubic-bezier(.4,0,.2,1);
  display: flex;
  flex-direction: column;
}

#sheet.open {
  transform: translateY(0);
}

.sheet-handle {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 10px 0 4px;
  cursor: grab;
  flex-shrink: 0;
  position: relative;
}

.sheet-handle span {
  width: 36px;
  height: 4px;
  background: #d1d5db;
  border-radius: 2px;
}

.sheet-minimize-btn {
  position: absolute;
  right: 16px;
  top: 6px;
  width: 32px;
  height: 32px;
  border: none;
  background: none;
  font-size: 20px;
  color: #9ca3af;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  min-width: 44px;
  min-height: 44px;
}
.sheet-minimize-btn:active {
  background: #f3f4f6;
}

#sheet.minimized {
  transform: translateY(calc(100% - 48px));
  padding-bottom: env(safe-area-inset-bottom);
  pointer-events: auto;
}
#sheet.minimized .sheet-minimize-btn {
  display: none;
}
#sheet.minimized .sheet-handle {
  cursor: pointer;
}

#sheet-content {
  padding: 0 20px 24px;
  overflow-y: auto;
  flex: 1;
}

/* ── Sheet Detail Content ── */
.detail-header {
  margin-bottom: 12px;
  position: relative;
  padding-right: 36px;
}

.detail-header h2 {
  font-size: 20px;
  margin-bottom: 4px;
}

.detail-close {
  position: absolute;
  top: 0;
  right: 0;
  background: none;
  border: none;
  font-size: 24px;
  color: #6b7280;
  cursor: pointer;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: background .15s;
}

.detail-close:hover {
  background: #f3f4f6;
  color: #1a1a1a;
}

.category-badge {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 600;
  color: #fff;
}

.category-dropdown {
  position: absolute;
  left: 0;
  top: 100%;
  margin-top: 4px;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0,0,0,.2);
  z-index: 100;
  min-width: 180px;
  max-height: 300px;
  overflow-y: auto;
  padding: 4px 0;
}

.category-dropdown-item {
  padding: 8px 14px;
  font-size: 13px;
  cursor: pointer;
  white-space: nowrap;
}

.category-dropdown-item:hover {
  background: #f3f4f6;
}

.detail-address {
  color: #6b7280;
  font-size: 14px;
  margin: 8px 0;
}

.detail-description {
  font-size: 14px;
  margin: 8px 0 12px;
}

.detail-tip {
  background: #fef3c7;
  border-left: 3px solid #f59e0b;
  padding: 10px 14px;
  border-radius: 0 8px 8px 0;
  font-size: 13px;
  margin: 12px 0;
}

.detail-tip::before {
  content: "Tip: ";
  font-weight: 600;
}

/* Yelp details */
.detail-yelp {
  margin: 12px 0;
  display: flex;
  gap: 12px;
  align-items: flex-start;
}
.yelp-photo {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: 8px;
  flex-shrink: 0;
}
.yelp-info {
  font-size: 14px;
}
.yelp-rating {
  font-weight: 600;
}
.yelp-reviews {
  color: #6b7280;
  font-size: 13px;
}
.yelp-price {
  color: #16a34a;
  font-weight: 600;
}
.yelp-categories {
  color: #6b7280;
  font-size: 12px;
  margin-top: 2px;
}

/* External links */
.detail-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 12px 0;
}
.detail-link {
  display: inline-block;
  padding: 6px 14px;
  border-radius: 8px;
  background: #f3f4f6;
  color: #1d4ed8;
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
  border: 1px solid #e5e7eb;
}
.detail-link:hover {
  background: #e5e7eb;
}
.detail-link.yelp-link {
  background: #d32323;
  color: #fff;
  border-color: #d32323;
}
.detail-link.yelp-link:hover {
  background: #b81c1c;
}
.detail-link.tripadvisor-link {
  background: #34e0a1;
  color: #000;
  border-color: #34e0a1;
}
.detail-link.tripadvisor-link:hover {
  background: #2bc48d;
}
.detail-link.google-link {
  background: #4285f4;
  color: #fff;
  border-color: #4285f4;
}
.detail-link.google-link:hover {
  background: #3367d6;
}
.detail-link.wikipedia-link {
  background: #636466;
  color: #fff;
  border-color: #636466;
}
.detail-link.wikipedia-link:hover {
  background: #4a4b4d;
}

/* ── Directions Picker ── */
.directions-picker-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0,0,0,.4);
  z-index: 1004;
  display: flex;
  align-items: center;
  justify-content: center;
}

.directions-picker-card {
  background: #fff;
  border-radius: 16px;
  width: 280px;
  padding: 20px;
  box-shadow: 0 8px 30px rgba(0,0,0,.2);
}

.directions-picker-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  font-size: 16px;
  font-weight: 600;
}

.directions-picker-options {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.directions-option {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border-radius: 12px;
  border: 1px solid #e5e7eb;
  background: #fff;
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  transition: background .15s;
  min-height: 44px;
}

.directions-option:hover {
  background: #f3f4f6;
}

.directions-option:active {
  background: #e5e7eb;
}

.directions-option-icon {
  font-size: 22px;
  flex-shrink: 0;
}

.detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 16px 0;
}

.detail-actions button {
  padding: 8px 14px;
  border-radius: 8px;
  border: 1px solid #e5e7eb;
  background: #fff;
  font-size: 13px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 4px;
  transition: background .15s;
}

.detail-actions button:hover {
  background: #f3f4f6;
}

.detail-actions .btn-bookmark.bookmarked {
  background: #fef3c7;
  border-color: #f59e0b;
}

/* ── Nearby Results Label / Dropdown ── */
.nearby-label {
  position: absolute;
  top: 60px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1002;
  background: #1f2937;
  color: #fff;
  padding: 6px 8px 6px 12px;
  border-radius: 20px;
  font-size: 14px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
  box-shadow: 0 2px 8px rgba(0,0,0,.25);
  white-space: nowrap;
}

.nearby-label-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #e11d48;
  flex-shrink: 0;
}

.nearby-label-select {
  -webkit-appearance: none;
  appearance: none;
  background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%239ca3af'/%3E%3C/svg%3E") no-repeat right 6px center;
  border: 1px solid #4b5563;
  border-radius: 12px;
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  padding: 5px 24px 5px 8px;
  cursor: pointer;
  max-width: 220px;
}

.nearby-label-select:focus {
  outline: none;
  border-color: #f97316;
}

.nearby-label-select option {
  background: #1f2937;
  color: #fff;
}

.nearby-label-close {
  background: none;
  border: none;
  color: #9ca3af;
  font-size: 18px;
  cursor: pointer;
  padding: 0 2px 0 2px;
  line-height: 1;
}

.nearby-label-close:hover {
  color: #fff;
}

/* ── Nearby Category Picker ── */
.nearby-picker h2 {
  font-size: 20px;
  margin: 0 0 4px;
}

.nearby-type-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.nearby-type-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 14px 8px;
  border-radius: 12px;
  border: 1px solid #e5e7eb;
  background: #fff;
  cursor: pointer;
  transition: background .15s, border-color .15s;
}

.nearby-type-btn:hover {
  background: #f3f4f6;
  border-color: #d1d5db;
}

.nearby-type-btn:active {
  background: #e5e7eb;
}

.nearby-type-icon {
  font-size: 24px;
  line-height: 1;
}

.nearby-type-label {
  font-size: 12px;
  color: #374151;
  text-align: center;
  line-height: 1.2;
}

/* ── Notes Section ── */
.notes-section {
  margin-top: 16px;
  border-top: 1px solid #e5e7eb;
  padding-top: 12px;
}

.notes-section h4 {
  font-size: 14px;
  margin-bottom: 8px;
}

.note-item {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 8px 0;
  border-bottom: 1px solid #f3f4f6;
  font-size: 13px;
}

.note-item .note-text {
  flex: 1;
  margin-right: 8px;
}

.note-item .note-date {
  font-size: 11px;
  color: #9ca3af;
  margin-top: 2px;
}

.note-item .note-delete {
  background: none;
  border: none;
  color: #ef4444;
  cursor: pointer;
  font-size: 16px;
  padding: 0 4px;
  flex-shrink: 0;
}

.note-add {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}

.note-add textarea {
  flex: 1;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  padding: 8px;
  font-size: 13px;
  resize: none;
  font-family: inherit;
  min-height: 36px;
}

.note-add button {
  padding: 6px 14px;
  background: #3b82f6;
  color: #fff;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-size: 13px;
  align-self: flex-end;
}

/* ── Filter Panel ── */
#filter-panel {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1002;
  background: #fff;
  border-radius: 16px 16px 0 0;
  max-height: 60vh;
  transform: translateY(100%);
  transition: transform .3s cubic-bezier(.4,0,.2,1);
  padding: 20px;
  overflow-y: auto;
}

#filter-panel.open {
  transform: translateY(0);
}

.panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.panel-header h3 {
  font-size: 18px;
}

.close-btn {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: #6b7280;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.filter-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 0;
  cursor: pointer;
  border-bottom: 1px solid #f3f4f6;
}

.filter-item:hover {
  background: #f9fafb;
  margin: 0 -20px;
  padding: 10px 20px;
}

.filter-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  flex-shrink: 0;
}

.filter-label {
  flex: 1;
  font-size: 14px;
  text-transform: capitalize;
}

.filter-item .filter-check {
  font-size: 18px;
  color: #3b82f6;
}

.filter-item.active .filter-check::after {
  content: "\2713";
}

.filter-btn-row {
  display: flex;
  gap: 8px;
  margin-top: 12px;
}

.filter-clear {
  display: block;
  flex: 1;
  padding: 10px;
  background: none;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  font-size: 14px;
  cursor: pointer;
  color: #6b7280;
}

.filter-clear:hover {
  background: #f3f4f6;
}

.filter-section-divider {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 16px 0 8px;
  color: #9ca3af;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.filter-section-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: #e5e7eb;
}

.settings-item .filter-check {
  font-size: 20px !important;
  color: #9ca3af !important;
}

/* ── Edit Lists UI ── */
.edit-list-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  margin-bottom: 6px;
}

.edit-list-name {
  font-size: 15px;
  font-weight: 500;
}

.edit-list-delete {
  background: none;
  border: none;
  font-size: 20px;
  color: #9ca3af;
  cursor: pointer;
  padding: 0 4px;
  line-height: 1;
}

.edit-list-delete:hover {
  color: #ef4444;
}

.edit-list-add-form {
  display: flex;
  gap: 8px;
  margin-top: 12px;
}

.edit-list-add-form input {
  flex: 1;
  padding: 10px 12px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  font-size: 15px;
}

.edit-list-add-btn {
  padding: 10px 18px;
  border: none;
  border-radius: 8px;
  background: #8b5cf6;
  color: #fff;
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
}

/* ── My Places Panel ── */
#my-places-panel,
#search-panel,
#events-panel {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1002;
  background: #fff;
  border-radius: 16px 16px 0 0;
  max-height: 70vh;
  transform: translateY(100%);
  transition: transform .3s cubic-bezier(.4,0,.2,1);
  padding: 20px;
  overflow-y: auto;
}

#my-places-panel.open,
#search-panel.open,
#events-panel.open {
  transform: translateY(0);
}

/* ── Events panel: flex layout for sticky header ── */
#events-panel {
  display: flex;
  flex-direction: column;
  overflow-y: hidden;
}

#events-header-area {
  flex-shrink: 0;
}

#events-panel #events-content {
  flex: 1;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  min-height: 0;
}

/* ── Minimize / restore for events panel ── */
.panel-header-actions {
  display: flex;
  align-items: center;
  gap: 4px;
}

.minimize-btn {
  width: 32px;
  height: 32px;
  border: none;
  background: none;
  font-size: 22px;
  color: #9ca3af;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  min-width: 44px;
  min-height: 44px;
}
.minimize-btn:active {
  background: #f3f4f6;
}

#events-panel.minimized {
  transform: translateY(calc(100% - 56px));
  padding-bottom: env(safe-area-inset-bottom);
  pointer-events: auto;
}
#events-panel.minimized .panel-header {
  cursor: pointer;
}
#events-panel.minimized .minimize-btn {
  display: none;
}

/* ── Filter chips ── */
.events-filter-row {
  display: flex;
  gap: 8px;
  padding: 8px 0 12px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  flex-shrink: 0;
  border-bottom: 1px solid #f3f4f6;
}
.events-filter-row::-webkit-scrollbar {
  display: none;
}
.filter-chip {
  flex-shrink: 0;
  padding: 6px 14px;
  border-radius: 16px;
  border: 1px solid #d1d5db;
  background: #fff;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  color: #374151;
  min-height: 32px;
  white-space: nowrap;
}
.filter-chip.active {
  background: #1d4ed8;
  color: #fff;
  border-color: #1d4ed8;
}
.filter-chip:active {
  opacity: 0.8;
}

.search-result-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 0;
  cursor: pointer;
  border-bottom: 1px solid #f3f4f6;
}
.search-result-item:hover { background: #f9fafb; margin: 0 -20px; padding: 12px 20px; }
.search-result-item:last-child { border-bottom: none; }
.search-result-item .sr-icon { font-size: 18px; flex-shrink: 0; }
.search-result-item .sr-name { font-weight: 500; font-size: 14px; }
.search-result-item .sr-sub { font-size: 12px; color: #6b7280; }
.search-result-item .sr-actions { margin-left: auto; flex-shrink: 0; }
.search-result-item .sr-save {
  padding: 4px 10px; border-radius: 12px; border: 1px solid #e5e7eb;
  background: #fff; font-size: 12px; cursor: pointer;
}
.search-result-item .sr-save:hover { background: #f3f4f6; }

#search-panel .search-loading {
  text-align: center; padding: 40px 20px; color: #6b7280;
}

@media (min-width: 768px) {
  #search-panel {
    left: auto;
    width: 400px;
    border-radius: 16px 0 0 16px;
    top: 0;
    bottom: 0;
    max-height: none;
    transform: translateX(100%);
    box-shadow: -4px 0 20px rgba(0,0,0,.1);
  }
  #search-panel.open {
    transform: translateX(0);
  }
}

.my-place-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 0;
  cursor: pointer;
  border-bottom: 1px solid #f3f4f6;
}

.my-place-item:hover {
  background: #f9fafb;
  margin: 0 -20px;
  padding: 10px 20px;
}

.my-place-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 4px;
}

.my-place-info {
  flex: 1;
  min-width: 0;
}

.my-place-name {
  font-size: 14px;
  font-weight: 500;
  display: block;
}

.my-place-cat {
  font-size: 12px;
  color: #6b7280;
  text-transform: capitalize;
  display: block;
}

.my-place-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 4px;
}

.saved-by-tag-sm {
  font-size: 10px;
  background: #eff6ff;
  color: #2563eb;
  padding: 1px 6px;
  border-radius: 8px;
  font-weight: 500;
}

.saved-remove-btn {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border: none;
  border-radius: 50%;
  background: #f3f4f6;
  color: #6b7280;
  font-size: 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  align-self: center;
}

.saved-remove-btn:hover {
  background: #e5e7eb;
}

.saved-delete-btn {
  font-size: 14px;
}

.saved-delete-btn:hover {
  background: #fee2e2;
  color: #ef4444;
}

.btn-delete-place {
  padding: 10px 18px;
  background: #ef4444;
  border: none;
  border-radius: 8px;
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  margin-right: auto;
}

.btn-delete-place:hover {
  background: #dc2626;
}

.empty-state {
  text-align: center;
  padding: 32px 16px;
  color: #9ca3af;
  font-size: 14px;
}

/* ── Saved Places Tabs ── */
.saved-tabs {
  display: flex;
  gap: 6px;
  padding: 0 0 12px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  flex-wrap: nowrap;
}

.saved-tab {
  padding: 6px 14px;
  border: 1px solid #d1d5db;
  border-radius: 20px;
  background: #fff;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  color: #374151;
}

.saved-tab.active {
  background: #2563eb;
  border-color: #2563eb;
  color: #fff;
}

.saved-tab-rename {
  background: #f3f4f6 !important;
  border-color: #d1d5db !important;
  color: #6b7280 !important;
  font-size: 14px !important;
  padding: 6px 10px !important;
}

/* ── Save Picker ── */
.save-picker {
  padding: 8px 0;
}

.save-picker h3 {
  margin: 0 0 4px;
  font-size: 18px;
}

.save-picker-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.save-picker-btn {
  padding: 10px 18px;
  border: 2px solid #d1d5db;
  border-radius: 12px;
  background: #fff;
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s;
  min-width: 80px;
}

.save-picker-btn.saved {
  border-color: #2563eb;
  background: #eff6ff;
  color: #2563eb;
}

.save-picker-btn:active {
  transform: scale(0.96);
}

.save-picker-done {
  display: block;
  width: 100%;
  padding: 12px;
  border: none;
  border-radius: 10px;
  background: #2563eb;
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}

.rename-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 16px;
}

.rename-list-btn {
  padding: 12px 16px;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  background: #fff;
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  text-align: left;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.rename-list-btn:hover {
  background: #f9fafb;
  border-color: #2563eb;
}

/* ── Saved-by tags in detail view ── */
.detail-saved-by {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 8px 0 12px;
}

.saved-by-tag {
  font-size: 12px;
  background: #eff6ff;
  color: #2563eb;
  padding: 3px 10px;
  border-radius: 12px;
  font-weight: 500;
}

/* ── Add Place Modal ── */
#add-place-modal,
#edit-place-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1003;
  background: rgba(0,0,0,.4);
  align-items: center;
  justify-content: center;
}

#add-place-modal.open,
#edit-place-modal.open {
  display: flex;
}

.modal-card {
  background: #fff;
  border-radius: 16px;
  width: 90%;
  max-width: 420px;
  max-height: 85vh;
  overflow-y: auto;
  padding: 24px;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.modal-header h3 {
  font-size: 18px;
}

#add-place-form label,
#edit-place-form label:not(.edit-list-checkbox) {
  display: block;
  margin-bottom: 12px;
  font-size: 13px;
  font-weight: 500;
  color: #374151;
}

#add-place-form input,
#add-place-form select,
#add-place-form textarea,
#edit-place-form input[type="text"],
#edit-place-form select,
#edit-place-form textarea {
  display: block;
  width: 100%;
  margin-top: 4px;
  padding: 8px 12px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  font-size: 14px;
  font-family: inherit;
}

#add-place-form textarea,
#edit-place-form textarea {
  resize: vertical;
}

.edit-lists-section {
  margin-bottom: 12px;
}

.edit-lists-label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: #374151;
  margin-bottom: 8px;
}

.edit-lists-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
}

.edit-list-checkbox {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 14px;
  color: #374151;
  cursor: pointer;
}

.edit-list-checkbox input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: #2563eb;
}

.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 16px;
}

.btn-cancel {
  padding: 8px 16px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  background: #fff;
  font-size: 14px;
  cursor: pointer;
}

.btn-primary {
  padding: 8px 20px;
  border: none;
  border-radius: 8px;
  background: #3b82f6;
  color: #fff;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
}

.btn-primary:hover {
  background: #2563eb;
}

.btn-locate {
  width: 100%;
  padding: 10px;
  border: 1px dashed #9ca3af;
  border-radius: 8px;
  background: #f9fafb;
  font-size: 14px;
  cursor: pointer;
  color: #374151;
  margin-top: -4px;
  transition: background .15s;
}

.btn-locate:hover {
  background: #f3f4f6;
}

.btn-locate:disabled {
  opacity: 0.6;
  cursor: wait;
}

/* ── Schedule Panel ── */
#schedule-panel {
  position: fixed;
  z-index: 1002;
  background: #fff;
  overflow-y: auto;
  transform: translateX(100%);
  transition: transform .3s cubic-bezier(.4,0,.2,1);
}

/* Desktop: right sidebar */
@media (min-width: 768px) {
  #schedule-panel {
    top: 0;
    right: 0;
    bottom: 0;
    width: 360px;
    padding: 20px;
    box-shadow: -4px 0 20px rgba(0,0,0,.1);
  }

  #schedule-panel.open {
    transform: translateX(0);
  }
}

/* Mobile: bottom overlay */
@media (max-width: 767px) {
  #schedule-panel {
    left: 0;
    right: 0;
    bottom: 0;
    max-height: 80vh;
    border-radius: 16px 16px 0 0;
    padding: 20px;
    transform: translateY(100%);
  }

  #schedule-panel.open {
    transform: translateY(0);
  }
}

.schedule-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-bottom: 12px;
}

.schedule-day {
  min-width: 200px;
  flex-shrink: 0;
}

.schedule-day-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 600;
  font-size: 14px;
  padding: 8px 0;
  border-bottom: 2px solid #e5e7eb;
  margin-bottom: 8px;
}

.schedule-slot {
  margin-bottom: 6px;
}

.schedule-slot-label {
  font-size: 11px;
  text-transform: uppercase;
  color: #9ca3af;
  font-weight: 600;
  margin-bottom: 4px;
}

.schedule-entry {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  background: #f9fafb;
  border-radius: 8px;
  font-size: 13px;
  margin-bottom: 4px;
  border-left: 3px solid #d1d5db;
}

.schedule-entry .entry-name {
  flex: 1;
  cursor: pointer;
}

.schedule-entry .entry-name:hover {
  text-decoration: underline;
}

.schedule-entry .entry-remove {
  background: none;
  border: none;
  color: #ef4444;
  cursor: pointer;
  font-size: 14px;
  padding: 0 2px;
}

.schedule-empty-slot {
  padding: 6px 10px;
  background: #f9fafb;
  border-radius: 8px;
  font-size: 12px;
  color: #d1d5db;
  text-align: center;
  border: 1px dashed #e5e7eb;
}

/* Schedule add picker */
.schedule-picker {
  margin-top: 12px;
  padding: 12px;
  background: #f0f7ff;
  border-radius: 8px;
}

.schedule-picker h4 {
  font-size: 14px;
  margin-bottom: 8px;
}

.schedule-picker label {
  display: block;
  margin-bottom: 8px;
  font-size: 13px;
}

.schedule-picker select {
  width: 100%;
  padding: 6px 10px;
  border: 1px solid #d1d5db;
  border-radius: 6px;
  font-size: 13px;
  margin-top: 4px;
}

.schedule-picker .picker-actions {
  display: flex;
  gap: 8px;
  margin-top: 10px;
  justify-content: flex-end;
}

.schedule-picker .picker-actions button {
  padding: 6px 14px;
  border-radius: 6px;
  font-size: 13px;
  cursor: pointer;
}

/* ── Category Colors ── */
.cat-restaurant { background-color: #dc2626; }
.cat-cafe { background-color: #ec4899; }
.cat-bakery { background-color: #ec4899; }
.cat-bar { background-color: #8b5cf6; }
.cat-museum { background-color: #6d28d9; }
.cat-attraction { background-color: #f59e0b; }
.cat-landmark { background-color: #b45309; }
.cat-shopping { background-color: #ea580c; }
.cat-market { background-color: #ea580c; }
.cat-park { background-color: #0d9488; }
.cat-neighborhood { background-color: #16a34a; }
.cat-jazz { background-color: #2563eb; }
.cat-services { background-color: #94a3b8; }
.cat-practical { background-color: #94a3b8; }
.cat-other { background-color: #a8a29e; }

/* ── Leaflet Popup Overrides ── */
.leaflet-popup-content-wrapper {
  border-radius: 12px !important;
  padding: 5px !important;
  box-shadow: 0 4px 16px rgba(0,0,0,.15) !important;
  min-width: 220px !important;
}

.leaflet-popup-content {
  margin: 4px 6px 6px !important;
  font-family: inherit !important;
  font-size: 14px !important;
  line-height: 1.4 !important;
  overflow: visible !important;
  width: 230px !important;
}

.leaflet-popup-close-button {
  top: 6px !important;
  right: 8px !important;
  font-size: 18px !important;
}

.popup-title {
  font-weight: 600;
  font-size: 15px;
  margin-bottom: 4px;
}

.popup-category {
  font-size: 12px;
  color: #6b7280;
  margin-bottom: 6px;
}

.popup-address {
  font-size: 12px;
  color: #6b7280;
  margin-bottom: 8px;
}

.popup-actions {
  display: flex;
  gap: 6px;
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid #f3f4f6;
}

.popup-actions button {
  flex: 1;
  padding: 10px 6px;
  min-height: 44px;
  border-radius: 6px;
  border: none;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: opacity .15s;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.popup-actions button:first-child {
  background: #3b82f6;
}

.popup-actions button:nth-child(2) {
  background: #16a34a;
}

.popup-actions button:nth-child(3) {
  background: #f59e0b;
  color: #1a1a1a;
}

.popup-actions button:hover {
  opacity: 0.85;
}

/* ── Custom Map Markers ── */
.saved-pin {
  background: none !important;
  border: none !important;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,.4));
}

.marker-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: #fff;
  border: 3px solid #94a3b8;
  box-shadow: 0 2px 6px rgba(0,0,0,.3);
  font-size: 11px;
  line-height: 1;
}

.home-marker {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px !important;
  height: 32px !important;
  background: #fbbf24;
  border-radius: 50%;
  border: 3px solid #fff;
  box-shadow: 0 2px 8px rgba(251,191,36,.7);
  font-size: 16px;
  line-height: 1;
}

.nearby-marker {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px !important;
  height: 32px !important;
  background: #fff;
  border-radius: 50%;
  border: 3px solid #94a3b8;
  box-shadow: 0 2px 8px rgba(0,0,0,.3), 0 0 0 2px rgba(0,0,0,.08);
  font-size: 15px;
  line-height: 1;
  animation: nearby-pulse 2s ease-in-out infinite;
}

@keyframes nearby-pulse {
  0%, 100% { box-shadow: 0 2px 8px rgba(0,0,0,.3), 0 0 0 2px rgba(0,0,0,.08); }
  50% { box-shadow: 0 2px 8px rgba(0,0,0,.3), 0 0 0 6px rgba(0,0,0,.05); }
}

.search-result-marker {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px !important;
  height: 28px !important;
  background: #fff;
  border-radius: 50%;
  border: 3px solid #8b5cf6;
  box-shadow: 0 2px 6px rgba(0,0,0,.3);
  font-size: 14px;
  line-height: 1;
}

/* ── Loading ── */
.loading-spinner {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 2px solid #e5e7eb;
  border-top-color: #3b82f6;
  border-radius: 50%;
  animation: spin .6s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* ── Scrollbar styling ── */
#sheet-content::-webkit-scrollbar,
#filter-panel::-webkit-scrollbar,
#my-places-panel::-webkit-scrollbar,
#search-panel::-webkit-scrollbar,
#schedule-panel::-webkit-scrollbar,
#events-panel::-webkit-scrollbar {
  width: 4px;
}

#sheet-content::-webkit-scrollbar-thumb,
#filter-panel::-webkit-scrollbar-thumb,
#my-places-panel::-webkit-scrollbar-thumb,
#search-panel::-webkit-scrollbar-thumb,
#schedule-panel::-webkit-scrollbar-thumb,
#events-panel::-webkit-scrollbar-thumb {
  background: #d1d5db;
  border-radius: 2px;
}

/* ── Toast Notifications (B2) ── */
#toast-container {
  position: fixed;
  bottom: 80px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2000;
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: center;
  pointer-events: none;
}

.toast {
  background: #1f2937;
  color: #fff;
  padding: 10px 16px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 500;
  box-shadow: 0 4px 12px rgba(0,0,0,.2);
  display: flex;
  align-items: center;
  gap: 10px;
  pointer-events: all;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity .3s, transform .3s;
  max-width: 340px;
}

.toast.visible {
  opacity: 1;
  transform: translateY(0);
}

.toast-success { background: #059669; }
.toast-error { background: #dc2626; }

.toast-undo {
  background: none;
  border: 1px solid rgba(255,255,255,.4);
  color: #fff;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
}

.toast-undo:hover {
  background: rgba(255,255,255,.15);
}

/* ── Inline Day Weather (F6) ── */
.day-weather {
  font-size: 12px;
  font-weight: 400;
  color: #6b7280;
  text-decoration: none;
  white-space: nowrap;
  padding: 2px 6px;
  border-radius: 4px;
  background: #f3f4f6;
  cursor: pointer;
}

.day-weather:hover {
  background: #e5e7eb;
  color: #374151;
}

/* ── Photos (F7) ── */
.photo-gallery {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 8px 0;
}

.photo-thumb {
  width: 80px;
  height: 80px;
  border-radius: 8px;
  object-fit: cover;
  cursor: pointer;
  flex-shrink: 0;
}

.photo-upload-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 8px 14px;
  background: #f3f4f6;
  border: 1px dashed #d1d5db;
  border-radius: 8px;
  color: #6b7280;
  font-size: 13px;
  cursor: pointer;
  margin-top: 8px;
}

.photo-upload-btn:hover {
  background: #e5e7eb;
}

/* ── Drag-to-Reorder (F3) ── */
.schedule-entry {
  cursor: grab;
  user-select: none;
}

.schedule-entry.dragging {
  opacity: 0.4;
  background: #e5e7eb;
}

.schedule-entry.drag-over {
  border-top: 2px solid #3b82f6;
}

.entry-drag-handle {
  cursor: grab;
  padding: 0 4px;
  color: #9ca3af;
  font-size: 14px;
}

/* ── iOS Safe Area Insets (D1) ── */
#search-bar {
  top: max(16px, env(safe-area-inset-top));
}
#refresh-btn {
  top: max(16px, env(safe-area-inset-top));
}
#fab-group {
  bottom: max(24px, env(safe-area-inset-bottom));
}
#toast-container {
  bottom: max(80px, calc(56px + env(safe-area-inset-bottom)));
}

/* ── Touch Target Minimums (D2) ── */
.close-btn {
  min-height: 44px;
  min-width: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.note-item .note-delete {
  min-height: 44px;
  min-width: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.detail-actions button {
  min-height: 44px;
}
.nearby-label-close {
  min-height: 44px;
  min-width: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.entry-remove {
  min-height: 44px;
  min-width: 44px;
}

/* ── Events Panel (F8) ── */

.events-header {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 0 0 12px;
  border-bottom: 1px solid #f3f4f6;
  margin-bottom: 12px;
}
.events-header-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.events-count {
  font-weight: 600;
  font-size: 14px;
  color: #374151;
}
.events-dates {
  font-size: 13px;
  color: #6b7280;
}
.events-header-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.events-last-updated {
  font-size: 11px;
  color: #9ca3af;
}
.events-refresh-btn {
  background: none;
  border: 1px solid #d1d5db;
  border-radius: 6px;
  padding: 4px 10px;
  font-size: 11px;
  color: #6b7280;
  cursor: pointer;
  min-height: 28px;
}
.events-refresh-btn:active {
  background: #f3f4f6;
}

.events-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.event-card {
  display: flex;
  gap: 12px;
  padding: 12px;
  border-radius: 12px;
  background: #f9fafb;
  cursor: pointer;
  min-height: 44px;
  transition: background .15s;
}
.event-card:active {
  background: #f3f4f6;
}

.event-card-image {
  flex-shrink: 0;
  width: 72px;
  height: 72px;
  border-radius: 8px;
  overflow: hidden;
  background: #e5e7eb;
}
.event-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.event-card-body {
  flex: 1;
  min-width: 0;
}
.event-card-title {
  font-weight: 600;
  font-size: 14px;
  color: #111827;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.event-card-date {
  font-size: 12px;
  color: #6b7280;
  margin-top: 4px;
}
.event-card-venue {
  font-size: 12px;
  color: #6b7280;
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.event-price-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 10px;
  margin-top: 4px;
}
.event-price-badge.free {
  background: #d1fae5;
  color: #065f46;
}
.event-price-badge.paid {
  background: #f3f4f6;
  color: #6b7280;
}

.events-load-more {
  text-align: center;
  padding: 16px 0;
}
.events-load-more button {
  padding: 10px 24px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  background: #fff;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  color: #374151;
  min-height: 44px;
}
.events-load-more button:active {
  background: #f3f4f6;
}

.event-retry-btn {
  margin-top: 12px;
  padding: 10px 24px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  background: #fff;
  font-size: 14px;
  cursor: pointer;
  min-height: 44px;
}

/* Event detail in bottom sheet */
.event-detail {
  padding: 4px 0;
}
#sheet.event-mode .sheet-handle {
  display: none;
}
.event-detail-image {
  width: 100%;
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 16px;
}
.event-detail-image img {
  width: 100%;
  height: auto;
  display: block;
}
.event-detail-title {
  font-size: 18px;
  font-weight: 700;
  margin: 0 0 12px;
  color: #111827;
}
.event-detail-row {
  font-size: 14px;
  color: #374151;
  margin-bottom: 8px;
  line-height: 1.4;
}
.event-detail-desc {
  font-size: 14px;
  color: #4b5563;
  line-height: 1.5;
  margin: 12px 0 16px;
}
.event-detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}
.event-action-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 10px 16px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  background: #fff;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  color: #374151;
  text-decoration: none;
  min-height: 44px;
}
.event-action-btn:active {
  background: #f3f4f6;
}

/* Event map markers */
.event-marker-icon {
  background: none;
  border: none;
}
.event-marker-inner {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #e11d48;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  box-shadow: 0 2px 6px rgba(0,0,0,.3);
  border: 2px solid #fff;
}

.event-detail {
  position: relative;
}
.event-detail-close {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 44px;
  height: 44px;
  border: none;
  background: rgba(255,255,255,0.85);
  border-radius: 50%;
  font-size: 24px;
  line-height: 1;
  color: #374151;
  cursor: pointer;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}
.event-detail-close:active {
  background: rgba(255,255,255,1);
}
.event-detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 8px 0;
}
.event-tag-chip {
  display: inline-block;
  font-size: 12px;
  color: #4b5563;
  background: #f3f4f6;
  border-radius: 12px;
  padding: 4px 10px;
}
.event-new-badge {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  color: #fff;
  background: #3b82f6;
  border-radius: 4px;
  padding: 2px 6px;
  margin-left: 4px;
  vertical-align: middle;
  text-transform: uppercase;
}
.event-translate-btn {
  background: #eff6ff;
  border-color: #3b82f6;
  color: #1d4ed8;
}
.event-translate-btn:active {
  background: #dbeafe;
}
.event-translate-btn:disabled {
  cursor: wait;
}
.event-lang-badge {
  display: inline-block;
  font-size: 10px;
  font-weight: 600;
  color: #6b7280;
  background: #f3f4f6;
  border-radius: 4px;
  padding: 2px 6px;
  margin-left: 4px;
  vertical-align: middle;
}

@media (min-width: 768px) {
  #events-panel {
    left: auto;
    width: 400px;
    border-radius: 16px 0 0 16px;
  }
}
