/* ========================================
   CSS VARIABLES — Design System
   ======================================== */

@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600;700;800&family=Playfair+Display:ital,wght@0,700;1,700&family=Inter:wght@400;500;600&display=swap');

:root {
  /* Palette */
  --bg:           #F5F5DC;
  --bg-card:      #FFFFFF;
  --bg-cream:     #FFFDF5;
  --bg-hover:     #EDE9D5;
  --primary:      #2F4F4F;
  --primary-dark: #1a3333;
  --primary-light:#e8f0f0;
  --secondary:    #800020;
  --secondary-light:#f5e8ea;
  --accent:       #556B2F;
  --accent-warm:  #A52A2A;
  --text:         #3E2723;
  --text-mid:     #6B4C42;
  --text-muted:   #9E7B6E;
  --border:       #D2B48C;
  --border-light: #EBD9C2;

  /* Shadows */
  --shadow-xs:  0 1px 3px rgba(62,39,35,0.08);
  --shadow-sm:  0 2px 8px rgba(62,39,35,0.1);
  --shadow-md:  0 6px 24px rgba(62,39,35,0.14);
  --shadow-lg:  0 16px 48px rgba(62,39,35,0.2);

  /* Fonts */
  --font-head:  'Montserrat', 'Playfair Display', Georgia, serif;
  --font-body:  'Inter', system-ui, sans-serif;
  --font-serif: 'Playfair Display', Georgia, serif;

  /* Radius */
  --r-sm: 6px;
  --r-md: 12px;
  --r-lg: 16px;
  --r-xl: 24px;
  --r-pill: 100px;
}

/* ========================================
   RESET & BASE
   ======================================== */

*, *::before, *::after {
  margin: 0; padding: 0; box-sizing: border-box;
}

html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
}

/* ========================================
   LAYOUT
   ======================================== */

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 28px;
  width: 100%;
}

.page-wrapper {
  flex: 1;
  padding-bottom: 64px;
}

/* ========================================
   HEADER
   ======================================== */

.site-header {
  background: var(--bg);
  border-bottom: 1px solid var(--border-light);
  position: sticky;
  top: 0;
  z-index: 200;
  box-shadow: none;
}

.navbar {
  display: flex;
  align-items: center;
  height: 64px;
  gap: 24px;
}

.navbar-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
}

.navbar-logo {
  width: 38px; height: 38px;
  border-radius: 10px;
  overflow: hidden;
  flex-shrink: 0;
}

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

.navbar-title {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--primary);
  letter-spacing: -0.3px;
}

.navbar-nav {
  display: flex;
  align-items: center;
  gap: 2px;
  list-style: none;
}

.navbar-nav a {
  display: block;
  padding: 7px 16px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-mid);
  text-decoration: none;
  border-radius: var(--r-pill);
  transition: all 0.2s;
  font-family: var(--font-head);
  letter-spacing: 0.2px;
}

.navbar-nav a:hover { color: var(--primary); background: var(--primary-light); }
.navbar-nav a.active {
  color: var(--primary);
  /*background: var(--secondary-light);*/
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.navbar-search {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg);
  border: none;
  border-radius: var(--r-pill);
  padding: 8px 16px;
  transition: all 0.2s;
}

.navbar-search:focus-within {
  border-color: var(--secondary);
  box-shadow: 0 0 0 3px rgba(47,79,79,0.12);
  background: var(--bg-card);
}

.search-icon { font-size: 14px; color: var(--text-muted); }

.navbar-search input {
  border: none; background: transparent;
  font-family: var(--font-body);
  font-size: 14px; color: var(--text);
  outline: none; width: 200px;
}

.navbar-search input::placeholder { color: var(--text-muted); }

/* ========================================
   PAGE HERO
   ======================================== */

.page-hero {
  padding: 32px 0 20px;
}

.hero-month-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.hero-nav-btns {
  display: flex;
  gap: 4px;
}

.hero-nav-btn {
  width: 32px;
  height: 32px;
  border: none;
  border-radius: 50%;
  background: var(--bg-hover);
  color: var(--text-mid);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
  padding-bottom: 1px;
}

.hero-nav-btn:hover {
  background: var(--primary);
  color: white;
}

.hero-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.page-hero h1 {
  font-family: var(--font-serif);
  font-size: 2.4rem;
  font-weight: 700;
  color: var(--primary-dark);
  letter-spacing: -0.5px;
  line-height: 1.2;
}

.subtitle {
  margin-top: 4px;
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 500;
  font-family: var(--font-head);
  letter-spacing: 0.3px;
}

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

.btn-filters-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: var(--primary);
  color: white;
  border: none;
  border-radius: var(--r-pill);
  font-family: var(--font-head);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  letter-spacing: 0.3px;
}

.btn-filters-toggle:hover {
  background: var(--primary-dark);
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}

.btn-filters-icon { font-size: 16px; }

.view-switcher {
  display: flex;
  background: var(--bg-card);
  border: none;
  border-radius: var(--r-pill);
  padding: 3px;
  gap: 2px;
}

.view-btn {
  padding: 7px 16px;
  border: none;
  border-radius: var(--r-pill);
  background: transparent;
  font-family: var(--font-head);
  font-size: 13px;
  font-weight: 600;
  color: var(--text-mid);
  cursor: pointer;
  transition: all 0.2s;
}

.view-btn.active {
  background: var(--secondary);
  color: white;
}

/* ========================================
   FILTERS PANEL
   ======================================== */

.filters-panel {
  background: var(--bg-card);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  max-height: 500px;
  transition: max-height 0.35s ease, opacity 0.3s ease, margin 0.3s ease;
  margin-bottom: 20px;
  opacity: 1;
}

.filters-panel.collapsed {
  max-height: 0;
  opacity: 0;
  margin-bottom: 0;
  box-shadow: none;
}

.filters-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  padding: 20px 24px;
  align-items: flex-end;
}

.filter-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.filter-label {
  font-family: var(--font-head);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-muted);
}

.filter-input, .filter-select {
  padding: 10px 14px;
  border: none;
  border-radius: var(--r-md);
  background: var(--bg);
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--text);
  outline: none;
  transition: all 0.2s;
  min-width: 160px;
  cursor: pointer;
}

.filter-input:focus, .filter-select:focus {
  border-color: var(--secondary);
  background: var(--bg-card);
  box-shadow: 0 0 0 3px rgba(47,79,79,0.1);
}

.filter-actions { flex-direction: row; align-items: flex-end; gap: 8px; margin-left: auto; }

.btn-apply {
  padding: 10px 22px;
  background: var(--secondary);
  color: white;
  border: none;
  border-radius: var(--r-md);
  font-family: var(--font-head);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-apply:hover { background: #1a3333; transform: translateY(-1px); }

.btn-clear {
  padding: 10px 18px;
  background: transparent;
  color: var(--text-muted);
  border: none;
  border-radius: var(--r-md);
  font-family: var(--font-head);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-clear:hover { color: var(--primary); background: var(--primary-light); }

/* ========================================
   CALENDAR SECTION
   ======================================== */

.calendar-section {
  background: transparent;
  border-radius: 0;
  border: none;
  box-shadow: none;
  padding: 0;
  margin-bottom: 48px;
}

/* FullCalendar overrides */
.fc { font-family: var(--font-body) !important; }

.fc-theme-standard td, .fc-theme-standard th {
  border-color: var(--border-light) !important;
}
.fc-theme-standard .fc-scrollgrid { border-color: var(--border-light) !important; }

.fc-header-toolbar {
  margin-bottom: 0 !important;
  align-items: center !important;
  padding-bottom: 0 !important;
}

/* Скрываем заголовок — он теперь в hero */
.fc-toolbar-title { display: none !important; }

/* Скрываем chunk с заголовком полностью */
.fc-toolbar-chunk:first-child { display: none !important; }


.fc-prev-button, .fc-next-button {
  background: var(--bg) !important;
  border: none !important;
  color: var(--text-mid) !important;
  width: 34px !important; height: 34px !important;
  border-radius: 50% !important;
  padding: 0 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  box-shadow: none !important;
  transition: all 0.15s !important;
  font-size: 13px !important;
}

.fc-prev-button:hover, .fc-next-button:hover {
  background: var(--bg-hover) !important;
  color: var(--text) !important;
}

.fc-button-primary {
  background: var(--bg) !important;
  color: var(--text-mid) !important;
  border: none !important;
  border-radius: var(--r-md) !important;
  padding: 8px 16px !important;
  font-family: var(--font-head) !important;
  font-size: 13px !important;
  font-weight: 600 !important;
  text-transform: none !important;
  box-shadow: none !important;
  transition: all 0.2s !important;
  letter-spacing: 0.2px !important;
}

.fc-button-primary:hover {
  background: var(--secondary-light) !important;
  color: var(--secondary) !important;
}

.fc-button-primary:not(:disabled).fc-button-active,
.fc-button-primary:not(:disabled):active {
  background: var(--secondary) !important;
  color: white !important;
  border-color: var(--secondary) !important;
}

.fc-col-header-cell { background: var(--bg-hover) !important; }

/* Скруглённые углы у сетки */
.fc-scrollgrid { border-radius: var(--r-md) !important; overflow: hidden !important; border-color: var(--border-light) !important; }
.fc .fc-scrollgrid-section-header .fc-scroller { border-radius: var(--r-md) var(--r-md) 0 0 !important; overflow: hidden !important; }

/* Отступ между тулбаром и сеткой */
#calendar .fc-view-harness { margin-top: 16px; }

.fc-col-header-cell-cushion {
  font-family: var(--font-head) !important;
  font-size: 11px !important;
  font-weight: 700 !important;
  color: var(--text-muted) !important;
  text-transform: uppercase !important;
  letter-spacing: 1px !important;
  text-decoration: none !important;
  padding: 12px 4px !important;
}

.fc-daygrid-day { background: transparent !important; transition: background 0.15s; }
.fc-daygrid-day-frame { background-color: var(--bg-cream) !important; min-height: 100%; position: relative; }
.fc-daygrid-day:hover { background: var(--bg-hover) !important; }

.fc-daygrid-day-number {
  font-size: 13px !important;
  font-weight: 500 !important;
  color: var(--text-mid) !important;
  text-decoration: none !important;
  padding: 6px 8px !important;
  font-family: var(--font-head) !important;
}

.fc-day-today { background: rgba(47,79,79,0.05) !important; }
.fc-day-today .fc-daygrid-day-number {
  color: white !important;
  background: var(--secondary) !important;
  border-radius: 50% !important;
  width: 28px !important; height: 28px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  margin: 4px !important;
  font-weight: 400 !important;
}

.fc-day-other .fc-daygrid-day-number { color: var(--border) !important; }

/* Event pills */
.fc-event {
  border: none !important;
  border-radius: var(--r-sm) !important;
  padding: 3px 7px !important;
  margin: 1px 2px !important;
  cursor: pointer !important;
  transition: all 0.15s !important;
  font-size: 11px !important;
  background: var(--secondary-light) !important;
  border-left: 3px solid var(--secondary) !important;
}

.fc-event.ev-outdoor { background: #e8f0e8 !important; border-left-color: #2F4F4F !important; }
.fc-event.ev-virtual { background: #ede8f5 !important; border-left-color: #6b4a8a !important; }
.fc-event.ev-other   { background: #f5ede8 !important; border-left-color: #A52A2A !important; }

.fc-event:hover {
  filter: brightness(0.95) !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 2px 8px rgba(62,39,35,0.15) !important;
}

.fc-event-title {
  font-weight: 600 !important;
  font-size: 11px !important;
  color: var(--text) !important;
  font-family: var(--font-body) !important;
}

.fc-event-time {
  font-size: 10px !important;
  color: var(--text-muted) !important;
  font-weight: 500 !important;
}

.fc-daygrid-event-dot { display: none !important; }

/* List view */
.fc-list { border-radius: var(--r-md) !important; overflow: hidden !important; }
.fc-list-day-cushion { background: var(--bg-hover) !important; }

.fc-list-day-text, .fc-list-day-side-text {
  color: var(--primary) !important;
  font-family: var(--font-head) !important;
  font-weight: 700 !important;
  font-size: 13px !important;
  text-transform: uppercase !important;
  letter-spacing: 0.8px !important;
  text-decoration: none !important;
}

.fc-list-event td { background: var(--bg-card) !important; border-color: var(--border-light) !important; }
.fc-list-event:hover td { background: var(--bg-hover) !important; cursor: pointer !important; }
.fc-list-event-dot { border-color: var(--secondary) !important; }
.fc-list-event-time { color: var(--text-muted) !important; font-size: 13px !important; }
.fc-list-event-title a {
  color: var(--text) !important;
  font-weight: 600 !important;
  font-size: 14px !important;
  text-decoration: none !important;
  font-family: var(--font-body) !important;
}

/* ========================================
   LIST SECTION
   ======================================== */

.hidden { display: none !important; }

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

/* Day group */
.day-group { margin-bottom: 24px; }

.day-label {
  font-family: var(--font-head);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--primary);
  padding: 12px 0 8px;
  border-bottom: 1px solid var(--border-light);
  margin-bottom: 8px;
}

.event-row {
  display: flex;
  align-items: center;
  background: var(--bg-card);
  border: none;
  border-radius: var(--r-md);
  padding: 16px 20px;
  margin-bottom: 8px;
  cursor: pointer;
  transition: all 0.18s ease;
  gap: 16px;
}

.event-row:hover {
  border-color: var(--border);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.event-row-time {
  flex-shrink: 0;
  width: 60px;
  text-align: center;
}

.event-row-time .time-big {
  font-family: var(--font-head);
  font-size: 18px;
  font-weight: 800;
  color: var(--text);
  line-height: 1;
  letter-spacing: -0.5px;
}

.event-row-time .time-period {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-top: 2px;
}

.event-row-sep {
  width: 1px;
  height: 36px;
  background: var(--border-light);
  flex-shrink: 0;
}

.event-row-info {
  flex: 1;
  min-width: 0;
}

.event-row-name {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-family: var(--font-head);
  letter-spacing: -0.2px;
}

.event-row-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 5px;
  flex-wrap: wrap;
}

.event-type-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: var(--r-pill);
  font-size: 11px;
  font-weight: 700;
  font-family: var(--font-head);
  letter-spacing: 0.3px;
}

.tag-outdoor { background: #e8f0e8; color: #2F4F4F; }
.tag-virtual { background: #ede8f5; color: #6b4a8a; }
.tag-other   { background: #f5ede8; color: #A52A2A; }

.event-row-location {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  color: var(--text-muted);
}

.event-row-chevron {
  color: var(--border);
  font-size: 16px;
  flex-shrink: 0;
  transition: color 0.2s;
}

.event-row:hover .event-row-chevron { color: var(--text-muted); }

/* ========================================
   UPCOMING EVENTS
   ======================================== */

.upcoming-section { margin-bottom: 48px; }

.upcoming-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 20px;
}

.upcoming-title {
  font-family: var(--font-serif);
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.3px;
}

.upcoming-see-all {
  font-size: 14px;
  font-weight: 600;
  color: var(--secondary);
  background: none;
  border: none;
  cursor: pointer;
  font-family: var(--font-head);
  transition: color 0.2s;
}
.upcoming-see-all:hover { color: var(--primary); }

.upcoming-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.upcoming-loading, .upcoming-empty {
  padding: 40px 24px;
  text-align: center;
  color: var(--text-muted);
  font-size: 14px;
  background: var(--bg-card);
  border-radius: var(--r-md);
  border: 1px solid var(--border-light);
  grid-column: 1 / -1;
}

/* Upcoming Card */
.up-card {
  background: var(--bg-card);
  border: none;
  border-radius: var(--r-lg);
  overflow: hidden;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  flex-direction: column;
}

.up-card:hover {
  border-color: var(--border);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.up-card-img {
  height: 160px;
  background: linear-gradient(135deg, var(--bg-hover) 0%, var(--border-light) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.up-card-img-placeholder {
  font-size: 48px;
  opacity: 0.2;
}

.up-card-img-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(62,39,35,0.3) 0%, transparent 60%);
}

.up-card-tag {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 4px 12px;
  border-radius: var(--r-pill);
  font-family: var(--font-head);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.up-card-body {
  padding: 16px 18px 18px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.up-card-title {
  font-family: var(--font-head);
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.2px;
  line-height: 1.3;
}

.up-card-meta {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.up-card-meta-row {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--text-muted);
  font-weight: 500;
}

.up-card-meta-icon { font-size: 12px; }

.up-card-action {
  display: block;
  width: 100%;
  padding: 11px;
  background: transparent;
  border: none;
  border-radius: var(--r-md);
  font-family: var(--font-head);
  font-size: 13px;
  font-weight: 700;
  color: var(--text-mid);
  cursor: pointer;
  transition: all 0.2s;
  text-align: center;
  margin-top: auto;
}

.up-card-action:hover {
  background: var(--primary);
  color: white;
}

/* ========================================
   MODAL
   ======================================== */

.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(30, 18, 12, 0.6);
  backdrop-filter: blur(8px);
  padding: 20px;
  overflow-y: auto;
  justify-content: center;
  align-items: flex-start;
}

.modal-overlay.open {
  display: flex;
}

.modal-content {
  background: var(--bg-card);
  border-radius: var(--r-xl);
  max-width: 860px;
  width: 100%;
  margin: auto;
  position: relative;
  animation: modalUp 0.3s cubic-bezier(0.34,1.56,0.64,1);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}

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

.modal-hero {
  position: relative;
  height: 240px;
  background: linear-gradient(135deg, #3E2723 0%, #2F4F4F 50%, #556B2F 100%);
  display: flex;
  align-items: flex-end;
  padding: 0;
}

.modal-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(30,18,12,0.8) 0%, rgba(30,18,12,0.15) 60%, transparent 100%);
}

.modal-close {
  position: absolute;
  top: 14px; right: 14px;
  width: 34px; height: 34px;
  border-radius: 50%;
  background: rgba(255,255,255,0.9);
  border: none;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  font-size: 14px;
  color: var(--text);
  z-index: 10;
  transition: all 0.2s;
  font-weight: 700;
}

.modal-close:hover { background: white; box-shadow: var(--shadow-sm); }

.modal-hero-bottom {
  position: relative;
  z-index: 2;
  padding: 20px 32px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.modal-type-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 14px;
  border-radius: var(--r-pill);
  background: var(--secondary);
  color: white;
  font-family: var(--font-head);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  width: fit-content;
}

.modal-event-title {
  font-family: var(--font-serif);
  font-size: 1.9rem;
  font-weight: 700;
  color: white;
  line-height: 1.2;
  letter-spacing: -0.3px;
  text-shadow: 0 2px 8px rgba(0,0,0,0.3);
}

/* Layout */
.modal-layout {
  display: flex;
  gap: 0;
}

.modal-main {
  flex: 1;
  padding: 28px 32px;
  min-width: 0;
}

.modal-sidebar {
  width: 220px;
  flex-shrink: 0;
  padding: 28px 24px 28px 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
  border-left: 1px solid var(--border-light);
  margin-left: 0;
  padding-left: 24px;
}

.modal-sidebar-card {
  background: var(--bg);
  border-radius: var(--r-md);
  padding: 14px 16px;
}

.sidebar-label {
  font-family: var(--font-head);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.sidebar-value {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  font-family: var(--font-head);
}

/* Meta row */
.modal-meta-row {
  display: flex;
  gap: 24px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.modal-meta-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.modal-meta-item .meta-icon {
  font-size: 22px;
  margin-top: 2px;
}

.meta-label {
  font-family: var(--font-head);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-muted);
  margin-bottom: 2px;
}

.meta-value {
  font-family: var(--font-head);
  font-size: 17px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.3px;
}

.modal-divider {
  height: 1px;
  background: var(--border-light);
  margin-bottom: 20px;
}

.modal-section { margin-bottom: 20px; }

.modal-section-label {
  font-family: var(--font-head);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-muted);
  margin-bottom: 10px;
}

.modal-raw-text {
  font-family: var(--font-body);
  font-size: 14px;
  line-height: 1.75;
  color: var(--text-mid);
  white-space: pre-wrap;
  word-break: break-word;
}

.modal-raw-text a { color: var(--secondary); text-decoration: underline; text-underline-offset: 2px; }
.modal-raw-text a:hover { color: var(--primary); }

.modal-location {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  background: var(--primary-light);
  border-radius: var(--r-md);
  margin-bottom: 24px;
}

.modal-location-icon {
  width: 36px; height: 36px;
  background: var(--primary);
  border-radius: var(--r-sm);
  display: flex; align-items: center; justify-content: center;
  color: white; font-size: 16px;
  flex-shrink: 0;
}

.modal-location-text {
  font-size: 14px;
  font-weight: 700;
  color: var(--primary);
  font-family: var(--font-head);
}

.modal-actions {
  display: flex;
  gap: 12px;
}

.btn-register {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 24px;
  background: var(--primary);
  color: white;
  border: none;
  border-radius: var(--r-md);
  font-family: var(--font-head);
  font-size: 15px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s;
  letter-spacing: 0.2px;
}

.btn-register:hover {
  background: var(--primary-dark);
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(128,0,32,0.3);
}

.btn-arrow { font-size: 18px; }

/* ========================================
   WEATHER BLOCK (modal)
   ======================================== */

.modal-weather {
  background: var(--primary-light);
  border-radius: var(--r-md);
  padding: 16px 18px;
  margin-bottom: 24px;
}

.weather-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}

.weather-title-icon { font-size: 18px; }

.weather-title-text {
  font-family: var(--font-head);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--primary);
}

.weather-body {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.weather-icon {
  flex-shrink: 0;
  border-radius: var(--r-sm);
  background: rgba(47, 79, 79, 0.08);
}

.weather-temp { flex-shrink: 0; }

.weather-temp-main {
  font-family: var(--font-head);
  font-size: 28px;
  font-weight: 800;
  color: var(--text);
  line-height: 1;
}

.weather-temp-feels {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 2px;
}

.weather-details { flex: 1; min-width: 100px; }

.weather-desc {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-mid);
  text-transform: capitalize;
}

.weather-wind {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 4px;
}

.weather-forecast-time {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 10px;
  text-align: right;
}

.weather-locked {
  font-size: 14px;
  color: var(--text-muted);
  font-style: italic;
  padding: 4px 0;
}

.weather-unavailable {
  font-size: 14px;
  color: var(--text-muted);
  font-style: italic;
  padding: 4px 0;
}

/* ========================================
   FOOTER
   ======================================== */

.site-footer {
  background: var(--text);
  color: rgba(255,255,255,0.5);
  padding: 48px 0 24px;
  margin-top: 0;
}

.footer-inner {
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 48px;
  margin-bottom: 36px;
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 18px;
  margin-bottom: 10px;
}

.footer-title {
  font-family: var(--font-head);
  font-size: 1.1rem;
  font-weight: 800;
  color: white;
}

.footer-brand p {
  font-size: 13px;
  line-height: 1.65;
  max-width: 240px;
}

.footer-col h4 {
  font-family: var(--font-head);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: rgba(255,255,255,0.65);
  margin-bottom: 14px;
}

.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.footer-col ul li a {
  font-size: 13px;
  color: rgba(255,255,255,0.4);
  text-decoration: none;
  transition: color 0.2s;
  font-family: var(--font-body);
}
.footer-col ul li a:hover { color: rgba(255,255,255,0.85); }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.08);
  padding-top: 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer-bottom p { font-size: 12px; font-family: var(--font-body); }

.footer-bottom-links { display: flex; gap: 20px; }
.footer-bottom-links a {
  font-size: 12px;
  color: rgba(255,255,255,0.35);
  text-decoration: none;
  transition: color 0.2s;
}
.footer-bottom-links a:hover { color: rgba(255,255,255,0.7); }

/* ========================================
   RESPONSIVE
   ======================================== */

@media (max-width: 900px) {
  .modal-layout { flex-direction: column; }
  .modal-sidebar {
    width: 100%;
    flex-direction: row;
    flex-wrap: wrap;
    border-left: none;
    border-top: 1px solid var(--border-light);
    padding: 20px 32px;
    gap: 12px;
  }
  .modal-sidebar-card { flex: 1; min-width: 120px; }
  .modal-sidebar .modal-weather { order: -1; width: 100%; }
  .footer-inner { grid-template-columns: 1fr 1fr; gap: 24px; }
  .footer-brand { grid-column: span 2; }
  .navbar-search input { width: 140px; }
}

@media (max-width: 768px) {
  .container { padding: 0 16px; }

  /* Хедер — компактный, всё видно */
  .navbar { gap: 8px; height: auto; padding: 8px 0; flex-wrap: wrap; }
  .navbar-brand { flex-shrink: 0; }
  .navbar-logo { width: 30px; height: 30px; }
  .navbar-title { font-size: 1rem; }

  .navbar-nav { display: flex; gap: 0; }
  .navbar-nav a { padding: 5px 10px; font-size: 12px; }

  .navbar-search {
    display: flex;
    margin-left: auto;
    padding: 6px 10px;
  }
  .navbar-search input { width: 90px; font-size: 13px; }

  /* Переключатель вида — всегда видим */
  .view-switcher { display: flex; }
  .view-btn { padding: 6px 10px; font-size: 12px; }

  .page-hero h1 { font-size: 1.8rem; }
  .hero-actions { flex-wrap: wrap; }
  .calendar-section { padding: 0; }

  .fc-toolbar-title { font-size: 1.2rem !important; }
  .fc-button-primary { padding: 6px 10px !important; font-size: 12px !important; }

  .modal-content { border-radius: var(--r-lg); }
  .modal-hero { height: 180px; }
  .modal-event-title { font-size: 1.4rem; }
  .modal-main { padding: 20px; }
  .modal-hero-bottom { padding: 16px 20px; }

  .modal-meta-row { gap: 16px; }
  .modal-actions { flex-direction: column; }

  .upcoming-cards { grid-template-columns: 1fr; }

  .footer-inner { grid-template-columns: 1fr; gap: 20px; }
  .footer-brand { grid-column: 1; }
  .footer-bottom { flex-direction: column; gap: 8px; text-align: center; }
}

@media (max-width: 480px) {
  .modal-meta-row { flex-direction: column; gap: 12px; }
}

/* ========================================
   ACCESSIBILITY
   ======================================== */

:focus-visible { outline: 2px solid var(--secondary); outline-offset: 2px; }
/* ========================================
   CITY SWITCHER
   ======================================== */

.city-switcher {
  position: relative;
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
}

.city-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 13px 5px 10px;
  background: var(--secondary);
  color: white;
  border: none;
  border-radius: var(--r-pill);
  font-family: var(--font-head);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  letter-spacing: 0.2px;
  white-space: nowrap;
  line-height: 1.4;
}

.city-btn:hover {
  background: var(--accent-warm);
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}

.city-btn-pin { font-size: 13px; }

.city-chevron {
  font-size: 11px;
  opacity: 0.8;
  margin-left: 2px;
  transition: transform 0.2s;
}

.city-btn[aria-expanded="true"] .city-chevron {
  transform: rotate(180deg);
}

.city-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  background: var(--bg-card);
  border-radius: var(--r-md);
  box-shadow: var(--shadow-md);
  min-width: 200px;
  z-index: 300;
  overflow: hidden;
  border: 1px solid var(--border-light);
  animation: dropdownIn 0.18s ease;
}

@keyframes dropdownIn {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: translateY(0); }
}

.city-option {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 11px 16px;
  font-family: var(--font-head);
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  cursor: pointer;
  transition: background 0.15s;
  border-bottom: 1px solid var(--border-light);
}

.city-option:last-child { border-bottom: none; }

.city-option:hover {
  background: var(--bg-hover);
}

.city-option.active {
  color: var(--secondary);
  font-weight: 700;
  background: var(--secondary-light);
}

/* На мобильном — немного компактнее */
@media (max-width: 768px) {
  .city-btn {
    font-size: 12px;
    padding: 4px 10px 4px 8px;
  }
  .city-btn-pin { display: none; }
  .city-dropdown { min-width: 170px; }
}

/* ========================================
   FEEDBACK BUTTON & MODAL
   ======================================== */

.feedback-fab {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 210;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: var(--r-pill);
  background: var(--secondary);
  color: #fff;
  border: none;
  font-family: var(--font-head);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: var(--shadow-md);
  transition: transform 0.15s, box-shadow 0.15s, background 0.15s;
}

.feedback-fab:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-lg);
  background: var(--accent-warm);
}

@media (max-width: 768px) {
  .feedback-fab {
    right: 16px;
    bottom: 16px;
    font-size: 13px;
    padding: 8px 14px;
  }
}

.feedback-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 1100;
  background: rgba(30, 18, 12, 0.6);
  backdrop-filter: blur(8px);
  padding: 20px;
  overflow-y: auto;
  justify-content: center;
  align-items: center;
}

.feedback-overlay.open {
  display: flex;
}

.feedback-modal {
  background: var(--bg-card);
  border-radius: var(--r-lg);
  width: 100%;
  max-width: 420px;
  padding: 22px 24px 20px;
  position: relative;
  box-shadow: var(--shadow-lg);
}

.feedback-close {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: none;
  background: var(--bg);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  color: var(--text-mid);
  transition: background 0.15s;
}

.feedback-close:hover {
  background: var(--bg-hover);
}

.feedback-title {
  font-family: var(--font-head);
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 4px;
  color: var(--primary-dark);
}

.feedback-subtitle {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 14px;
}

.feedback-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.feedback-label {
  font-family: var(--font-head);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-muted);
}

.feedback-textarea {
  border-radius: var(--r-md);
  border: 1px solid var(--border-light);
  padding: 10px 12px;
  font-family: var(--font-body);
  font-size: 14px;
  resize: vertical;
  min-height: 80px;
}

.feedback-textarea:focus {
  outline: none;
  border-color: var(--secondary);
  box-shadow: 0 0 0 2px rgba(128, 0, 32, 0.15);
}

.feedback-file-hidden {
  position: absolute;
  width: 0;
  height: 0;
  opacity: 0;
  pointer-events: none;
}

.feedback-dropzone {
  border: 2px dashed var(--border);
  border-radius: var(--r-md);
  padding: 18px 16px;
  text-align: center;
  transition: border-color 0.2s, background 0.2s;
  position: relative;
  cursor: pointer;
}

.feedback-dropzone--drag {
  border-color: var(--secondary);
  background: var(--secondary-light);
}

.feedback-dropzone-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.feedback-dropzone-icon {
  font-size: 22px;
}

.feedback-dropzone-text {
  font-size: 13px;
  color: var(--text-muted);
}

.feedback-dropzone-btn {
  display: inline-flex;
  align-items: center;
  padding: 7px 16px;
  background: var(--primary);
  color: white;
  border: none;
  border-radius: var(--r-pill);
  font-family: var(--font-head);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  margin-top: 4px;
}

.feedback-dropzone-btn:hover {
  background: var(--primary-dark);
  transform: translateY(-1px);
}

.feedback-dropzone-selected {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.feedback-dropzone-selected.hidden { display: none; }

.feedback-selected-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  max-width: 240px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.feedback-selected-remove {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: none;
  background: var(--bg-hover);
  color: var(--text-muted);
  font-size: 12px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
}

.feedback-selected-remove:hover {
  background: var(--secondary-light);
  color: var(--secondary);
}

.feedback-status {
  min-height: 18px;
  font-size: 13px;
  margin-top: 4px;
}

.feedback-status--loading {
  color: var(--text-muted);
}

.feedback-status--success {
  color: var(--accent);
}

.feedback-status--error {
  color: var(--secondary);
}

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

.feedback-btn-secondary,
.feedback-btn-primary {
  border-radius: var(--r-pill);
  padding: 8px 16px;
  font-family: var(--font-head);
  font-size: 13px;
  font-weight: 600;
  border: none;
  cursor: pointer;
}

.feedback-btn-secondary {
  background: transparent;
  color: var(--text-muted);
}

.feedback-btn-secondary:hover {
  background: var(--bg-hover);
  color: var(--text);
}

.feedback-btn-primary {
  background: var(--secondary);
  color: #fff;
}

.feedback-btn-primary[disabled] {
  opacity: 0.7;
  cursor: default;
}

.feedback-btn-primary:not([disabled]):hover {
  background: var(--accent-warm);
}

/* ========================================
   SIMPLE PAGES & 404
   ======================================== */

.simple-page {
  max-width: 760px;
  margin: 0 auto;
  padding: 48px 0 64px;
}

.simple-page:has(.clubs-grid) {
  max-width: 1000px;
}

.simple-page-title {
  font-family: var(--font-head);
  font-size: 2rem;
  color: var(--primary);
  margin-bottom: 24px;
}

.simple-page-body {
  font-family: var(--font-body);
  font-size: 1.05rem;
  color: var(--text);
  line-height: 1.75;
}

.simple-page-body h2 {
  font-family: var(--font-head);
  font-size: 1.35rem;
  color: var(--primary);
  margin: 32px 0 12px;
}

.simple-page-body h3 {
  font-family: var(--font-head);
  font-size: 1.15rem;
  color: var(--primary-dark);
  margin: 24px 0 8px;
}

.simple-page-body p {
  margin-bottom: 16px;
}

.simple-page-body ul,
.simple-page-body ol {
  margin: 0 0 16px 24px;
}

.simple-page-body li {
  margin-bottom: 6px;
}

.simple-page-body a {
  color: var(--secondary);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.simple-page-body a:hover {
  color: var(--accent-warm);
}

/* ========================================
   CLUBS PAGE
   ======================================== */

.clubs-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  max-width: 960px;
}

.simple-page-body .club-card {
  background: var(--bg-card);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
  transition: box-shadow 0.2s, transform 0.2s;
}

.club-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
}

.club-card-img {
  width: 100%;
  aspect-ratio: 4 / 3;
  background: linear-gradient(135deg, var(--bg-hover) 0%, var(--border-light) 100%);
  overflow: hidden;
}

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

.club-card-body {
  padding: 16px 18px 20px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.club-card-name {
  font-family: var(--font-head);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--primary);
  margin: 0;
}

.club-card-desc {
  font-size: 0.9rem;
  color: var(--text-mid);
  line-height: 1.55;
  margin: 0;
}

.clubs-cta {
  margin-top: 32px;
  text-align: center;
  font-size: 0.95rem;
  color: var(--text-mid);
}

.clubs-cta a {
  color: var(--secondary);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.clubs-cta a:hover {
  color: var(--accent-warm);
}

@media (max-width: 768px) {
  .clubs-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
}