/* === Swedish Theme Variables === */
:root {
  --blue: #006AA7;
  --blue-light: #4A9FD9;
  --blue-dark: #004A75;
  --yellow: #FECC02;
  --yellow-light: #FFE066;
  --yellow-dark: #D4A800;
  --green: #2D8B4E;
  --red: #E4572E;
  --bg: #FAFBFE;
  --bg-warm: #FFF9F0;
  --card: #FFFFFF;
  --text: #2C3E50;
  --text-light: #6B7C93;
  --text-muted: #94A3B8;
  --border: #E8EDF3;
  --shadow: 0 2px 8px rgba(0, 106, 167, 0.08);
  --shadow-lg: 0 8px 32px rgba(0, 106, 167, 0.12);
  --radius: 12px;
  --radius-sm: 8px;
  --transition: 0.2s ease;
}

/* === Reset & Base === */
* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Nunito', -apple-system, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a { color: var(--blue); text-decoration: none; cursor: pointer; }
a:hover { color: var(--blue-dark); }

img { max-width: 100%; height: auto; }

.container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }

/* === Navigation === */
.navbar {
  background: var(--blue);
  color: white;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.15);
  min-height: 64px;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.2rem;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
}

.dala-horse { flex-shrink: 0; }

.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: white;
  font-size: 1.5rem;
  cursor: pointer;
  padding: 8px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
}

.nav-link {
  color: rgba(255, 255, 255, 0.85);
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 0.9rem;
  transition: var(--transition);
  cursor: pointer;
  white-space: nowrap;
}

.nav-link:hover, .nav-link.active {
  color: white;
  background: rgba(255, 255, 255, 0.15);
}

.nav-link.active { background: rgba(254, 204, 2, 0.25); color: var(--yellow); }

.nav-msg-btn {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  color: rgba(255,255,255,0.8);
  cursor: pointer;
  transition: var(--transition);
  margin-left: 4px;
}
.nav-msg-btn:hover { background: rgba(255,255,255,0.15); color: white; }
.nav-msg-badge {
  position: absolute;
  top: 2px;
  right: 0;
  background: var(--red);
  color: white;
  font-size: 0.65rem;
  font-weight: 700;
  min-width: 16px;
  height: 16px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
}

.nav-auth { display: flex; align-items: center; gap: 8px; margin-left: 12px; }

.nav-auth .btn { font-size: 0.85rem; padding: 6px 14px; }

.nav-user {
  display: flex;
  align-items: center;
  gap: 8px;
  color: white;
  font-weight: 600;
  font-size: 0.9rem;
}

.nav-user-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--yellow);
  color: var(--blue);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.85rem;
}

/* === Buttons === */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 20px;
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-weight: 600;
  font-size: 0.95rem;
  border: 2px solid transparent;
  cursor: pointer;
  transition: var(--transition);
  gap: 6px;
  text-decoration: none;
}

.btn-primary {
  background: var(--blue);
  color: white;
}
.btn-primary:hover { background: var(--blue-dark); color: white; }

.btn-secondary {
  background: var(--yellow);
  color: var(--blue-dark);
}
.btn-secondary:hover { background: var(--yellow-dark); }

.btn-outline {
  background: transparent;
  border-color: var(--blue);
  color: var(--blue);
}
.btn-outline:hover { background: var(--blue); color: white; }

.btn-danger {
  background: var(--red);
  color: white;
}
.btn-danger:hover { background: #c0392b; }

.btn-success {
  background: var(--green);
  color: white;
}
.btn-success:hover { background: #1e6f3a; }

.btn-small { padding: 6px 12px; font-size: 0.8rem; }
.btn-lg { padding: 14px 28px; font-size: 1.05rem; }
.btn-full { width: 100%; }

/* === Hero === */
.hero {
  background: linear-gradient(135deg, var(--blue) 0%, var(--blue-dark) 100%);
  color: white;
  padding: 80px 24px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(254, 204, 2, 0.15) 0%, transparent 70%);
  border-radius: 50%;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: -30%;
  left: -10%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(254, 204, 2, 0.1) 0%, transparent 70%);
  border-radius: 50%;
}

.hero-content { position: relative; z-index: 1; }

.hero h1 {
  font-size: 3rem;
  font-weight: 700;
  margin-bottom: 12px;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.hero-subtitle {
  font-size: 1.3rem;
  opacity: 0.9;
  margin-bottom: 32px;
}

.hero-buttons { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }

/* === Pages === */
.page { display: none; }
.page.active { display: block; }

.page-header {
  text-align: center;
  padding: 40px 0 32px;
}

.page-header h2 {
  font-size: 2rem;
  color: var(--blue);
  margin-bottom: 8px;
}

.page-header p { color: var(--text-light); font-size: 1.1rem; }

/* === Welcome Section === */
.welcome-section {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 40px;
  align-items: start;
  padding: 48px 0;
}

.welcome-photo img {
  width: 100%;
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
}

.welcome-text h2 {
  color: var(--blue);
  font-size: 1.8rem;
  margin-bottom: 12px;
}

.welcome-text p {
  color: var(--text-light);
  font-size: 1.05rem;
  margin-bottom: 24px;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.feature-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  cursor: pointer;
  transition: var(--transition);
}

.feature-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
  border-color: var(--blue-light);
}

.feature-icon { font-size: 2rem; margin-bottom: 8px; }

.feature-card h3 {
  font-size: 1rem;
  color: var(--blue);
  margin-bottom: 4px;
}

.feature-card p { font-size: 0.85rem; color: var(--text-light); }

/* === Weather Widget === */
.weather-widget {
  background: linear-gradient(135deg, var(--blue-light), var(--blue));
  color: white;
  border-radius: var(--radius);
  padding: 24px;
  margin: 32px 0;
}

.weather-widget h3 { margin-bottom: 16px; font-size: 1.2rem; }

.weather-content {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  padding-bottom: 8px;
}

.weather-day {
  background: rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  text-align: center;
  min-width: 100px;
  flex-shrink: 0;
}

.weather-day .day { font-weight: 700; font-size: 0.85rem; }
.weather-day .temp { font-size: 1.3rem; font-weight: 700; margin: 4px 0; }
.weather-day .icon { font-size: 1.8rem; }
.weather-day .range { font-size: 0.8rem; opacity: 0.85; }

/* === House Section === */
.house-section {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  margin: 32px 0;
  box-shadow: var(--shadow-lg);
}

.house-photo {
  width: 100%;
  height: 400px;
  object-fit: cover;
  display: block;
}

.house-info {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.7));
  color: white;
  padding: 40px 24px 24px;
}

.house-info h3 { font-size: 1.3rem; margin-bottom: 4px; }
.house-info p { opacity: 0.9; }

/* === Tips === */
.tips-section {
  padding: 40px 0;
}

.tips-section h3 {
  color: var(--blue);
  font-size: 1.4rem;
  margin-bottom: 20px;
  text-align: center;
}

.tips-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
}

.tip-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
}

.tip-card h4 {
  color: var(--blue);
  margin-bottom: 12px;
  font-size: 1.05rem;
}

.tip-card ul { list-style: none; }

.tip-card li {
  padding: 4px 0;
  padding-left: 20px;
  position: relative;
  color: var(--text-light);
  font-size: 0.95rem;
}

.tip-card li::before {
  content: '\2022';
  color: var(--yellow-dark);
  font-weight: bold;
  position: absolute;
  left: 0;
}

.tip-card p { color: var(--text-light); font-size: 0.95rem; }

/* Tip Links */
.tip-links {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--border);
}
.tip-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  background: rgba(0, 106, 167, 0.06);
  color: var(--blue);
  border-radius: 14px;
  font-size: 0.8rem;
  font-weight: 600;
  transition: var(--transition);
  text-decoration: none;
}
.tip-link:hover {
  background: var(--blue);
  color: white;
}
.tip-link::before {
  content: '🔗';
  font-size: 0.7rem;
}

/* === Calendar === */

/* Selection bar */
.calendar-selection-bar {
  background: var(--blue);
  color: white;
  padding: 12px 20px;
  border-radius: var(--radius);
  margin-bottom: 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  box-shadow: var(--shadow-lg);
  animation: slideDown 0.25s ease;
}

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

.selection-info { font-size: 0.95rem; }
.selection-hint { opacity: 0.7; font-style: italic; margin-left: 8px; }
.selection-actions { display: flex; gap: 8px; }
.calendar-selection-bar .btn { font-size: 0.85rem; }
.calendar-selection-bar .btn-primary { background: var(--yellow); color: var(--blue-dark); }
.calendar-selection-bar .btn-primary:hover { background: var(--yellow-dark); }
.calendar-selection-bar .btn-small:not(.btn-primary) { background: rgba(255,255,255,0.2); color: white; border: none; }

.calendar-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 20px;
}

.calendar-legend { display: flex; gap: 16px; flex-wrap: wrap; }
.calendar-cost-legend { display: flex; gap: 16px; flex-wrap: wrap; }

.legend-item { display: flex; align-items: center; gap: 6px; font-size: 0.9rem; color: var(--text-light); }

.legend-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}
.legend-dot.green { background: var(--green); }
.legend-dot.yellow { background: var(--yellow-dark); }
.legend-dot.red { background: var(--red); }
.legend-dot.purple { background: #8B5CF6; }
.legend-dot.gray { background: #94A3B8; }
.legend-dot.pink { background: #EC4899; }

/* Holiday bar events — thin colored strips */
.fc .holiday-bar {
  height: 6px !important;
  min-height: 6px !important;
  max-height: 6px !important;
  line-height: 6px !important;
  font-size: 0px !important;
  border-radius: 3px !important;
  margin: 0 1px 1px !important;
  padding: 0 !important;
  opacity: 0.85;
  overflow: hidden;
  pointer-events: auto;
}

.fc .holiday-bar .fc-event-title,
.fc .holiday-bar .fc-event-main {
  font-size: 0px !important;
  line-height: 6px !important;
  padding: 0 !important;
  height: 6px !important;
}

/* Color indicator dots in holiday checkbox labels */
.holiday-color-dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  margin-left: 4px;
  vertical-align: middle;
  flex-shrink: 0;
}

/* Time Periods in Calendar */
.fc .period-blocked {
  background: repeating-linear-gradient(
    45deg,
    rgba(148, 163, 184, 0.15),
    rgba(148, 163, 184, 0.15) 4px,
    rgba(148, 163, 184, 0.08) 4px,
    rgba(148, 163, 184, 0.08) 8px
  ) !important;
}

.fc .period-free {
  background: rgba(45, 139, 78, 0.08) !important;
}

/* Special Events in Calendar */
.fc .special-event {
  border-radius: 4px !important;
  font-size: 0.8rem !important;
  font-weight: 600 !important;
  padding: 2px 6px !important;
}

/* Admin Period List */
.admin-period {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}
.admin-period:last-child { border-bottom: none; }

.period-info {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.period-label {
  color: var(--text-light);
  font-size: 0.9rem;
}

/* Admin Event List */
.admin-event {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}
.admin-event:last-child { border-bottom: none; }

.event-info {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.event-color-badge {
  width: 16px;
  height: 16px;
  border-radius: 4px;
  flex-shrink: 0;
}

.calendar-actions { display: flex; gap: 8px; }

#calendar {
  background: var(--card);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow);
  margin-bottom: 40px;
}

.fc { font-family: 'Nunito', sans-serif; }
.fc .fc-toolbar-title { color: var(--blue); }
.fc .fc-button-primary {
  background: var(--blue) !important;
  border-color: var(--blue) !important;
}
.fc .fc-button-primary:hover { background: var(--blue-dark) !important; }
.fc .fc-button-primary.fc-button-active { background: var(--blue-dark) !important; box-shadow: inset 0 2px 4px rgba(0,0,0,0.2) !important; }
.fc .fc-daygrid-day.fc-day-today { background: rgba(254, 204, 2, 0.1) !important; }

/* List view styling */
.fc .fc-list { border-radius: var(--radius-sm); }
.fc .fc-list-day-cushion { background: rgba(0, 106, 167, 0.06) !important; font-weight: 700; }
.fc .fc-list-event:hover td { background: rgba(0, 106, 167, 0.03) !important; }
.fc .fc-list-event-title { font-size: 0.9rem; }
.fc .fc-list-empty-cushion { color: var(--text-muted); }

/* List event date range badge */
.list-event-range {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-weight: 400;
  margin-left: 6px;
}

/* Multi-month 3 view */
.fc .fc-multimonth {
  border: none !important;
}
.fc .fc-multimonth-month {
  padding: 4px 8px;
}
.fc .fc-multimonth .fc-daygrid-day-frame {
  min-height: 40px;
}
.fc .fc-multimonth .day-costs {
  display: none;
}
.fc .fc-multimonth .fc-daygrid-day-number {
  font-size: 0.8rem;
}

/* Calendar Title Clickable Month/Year */
.cal-title-month, .cal-title-year {
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 6px;
  transition: background 0.15s ease, color 0.15s ease;
}
.cal-title-month:hover, .cal-title-year:hover {
  background: rgba(0, 106, 167, 0.12);
  color: var(--blue);
}

/* Calendar Title Picker Overlay */
.cal-title-picker-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.4);
  z-index: 2000;
  justify-content: center;
  align-items: center;
  padding: 20px;
}
.cal-title-picker {
  background: var(--card);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow-lg);
  max-width: 400px;
  width: 100%;
}
.cal-title-picker h4 {
  margin: 0 0 16px;
  color: var(--blue);
  font-size: 1.1rem;
  text-align: center;
}
.cal-picker-grid {
  display: grid;
  gap: 8px;
}
.cal-picker-months {
  grid-template-columns: repeat(3, 1fr);
}
.cal-picker-years {
  grid-template-columns: repeat(4, 1fr);
}
.cal-picker-btn {
  padding: 10px 8px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--card);
  color: var(--text);
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}
.cal-picker-btn:hover {
  border-color: var(--blue-light);
  background: rgba(0, 106, 167, 0.06);
  color: var(--blue);
}
.cal-picker-btn.active {
  background: var(--blue);
  color: white;
  border-color: var(--blue);
}

/* Day Events Popup */
.day-events-popup {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.5);
  z-index: 2000;
  justify-content: center;
  align-items: center;
  padding: 20px;
}

.day-popup-body {
  background: var(--card);
  border-radius: var(--radius);
  max-width: 480px;
  width: 100%;
  max-height: 80vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
  animation: slideDown 0.2s ease;
}

.day-popup-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
}

.day-popup-header h3 {
  font-size: 1.05rem;
  color: var(--blue);
  margin: 0;
}

.day-popup-close {
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--text-light);
  padding: 0 4px;
  line-height: 1;
}
.day-popup-close:hover { color: var(--text); }

.day-popup-events {
  padding: 12px 20px;
}

.day-popup-event {
  padding: 10px 12px;
  margin-bottom: 8px;
  border-radius: var(--radius-sm);
  background: var(--bg);
}
.day-popup-event:last-child { margin-bottom: 0; }

.day-popup-event-title {
  font-weight: 600;
  font-size: 0.95rem;
}

.day-popup-event-dates {
  font-size: 0.85rem;
  color: var(--text-light);
  margin-top: 2px;
}

.day-popup-event-meta {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 2px;
}

/* Modal Overlay (shared for booking edit etc.) */
.modal-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.5);
  z-index: 2000;
  justify-content: center;
  align-items: center;
  padding: 20px;
}

.modal-card {
  background: var(--card);
  border-radius: var(--radius);
  max-width: 520px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
  padding: 24px;
  animation: slideDown 0.2s ease;
}

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

.modal-header h3 {
  color: var(--blue);
  margin: 0;
}

.modal-header button {
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--text-light);
  padding: 0 4px;
  line-height: 1;
}
.modal-header button:hover { color: var(--text); }

/* Day cell: make room for costs */
.fc .fc-daygrid-day-frame {
  min-height: 85px;
  position: relative;
  cursor: pointer;
}

.fc .fc-daygrid-day:hover .fc-daygrid-day-frame {
  background: rgba(0, 106, 167, 0.04);
}

/* Daily cost badges */
.day-costs {
  position: absolute;
  bottom: 2px;
  left: 3px;
  right: 3px;
  display: flex;
  flex-direction: column;
  gap: 1px;
  pointer-events: none;
}

.day-cost {
  display: flex;
  align-items: center;
  gap: 2px;
  font-size: 10px;
  font-weight: 600;
  line-height: 1.2;
  white-space: nowrap;
  padding: 1px 3px;
  border-radius: 3px;
}

.day-cost.ferry {
  color: var(--blue);
  background: rgba(0, 106, 167, 0.08);
}

.day-cost.bridge {
  color: var(--yellow-dark);
  background: rgba(212, 168, 0, 0.1);
}

.cost-icon {
  flex-shrink: 0;
  opacity: 0.85;
}

/* Date selection highlighting */
.fc .fc-daygrid-day.cal-selected-start .fc-daygrid-day-frame {
  background: rgba(0, 106, 167, 0.2) !important;
  border: 2px solid var(--blue) !important;
  border-radius: 8px 0 0 8px;
}

.fc .fc-daygrid-day.cal-selected-end .fc-daygrid-day-frame {
  background: rgba(0, 106, 167, 0.2) !important;
  border: 2px solid var(--blue) !important;
  border-radius: 0 8px 8px 0;
}

.fc .fc-daygrid-day.cal-selected-range .fc-daygrid-day-frame {
  background: rgba(0, 106, 167, 0.1) !important;
  border-top: 2px solid rgba(0, 106, 167, 0.3) !important;
  border-bottom: 2px solid rgba(0, 106, 167, 0.3) !important;
}

/* Holiday Panel */
.holiday-panel {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 20px;
}

.holiday-panel h4 { color: var(--blue); margin-bottom: 12px; }
.holiday-panel h5 { margin-bottom: 8px; color: var(--text); }
.holiday-group { margin-bottom: 16px; }

.checkbox-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 6px;
}

.checkbox-grid label, .holiday-group > label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.9rem;
  color: var(--text-light);
  cursor: pointer;
}

.checkbox-grid input[type="checkbox"], .holiday-group > label input {
  accent-color: var(--blue);
}

/* === Booking Form === */
.booking-form {
  max-width: 700px;
  margin: 0 auto 40px;
}

.form-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
}

.form-group {
  margin-bottom: 16px;
}

.form-group label {
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text);
  margin-bottom: 6px;
}

.form-input, .form-group input, .form-group textarea, .form-group select {
  width: 100%;
  padding: 10px 14px;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-size: 0.95rem;
  transition: var(--transition);
  background: var(--card);
}

.form-input:focus, .form-group input:focus, .form-group textarea:focus {
  outline: none;
  border-color: var(--blue-light);
  box-shadow: 0 0 0 3px rgba(0, 106, 167, 0.1);
}

.cost-preview {
  background: var(--bg-warm);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  margin: 16px 0;
}

.my-bookings { margin-top: 40px; }
.my-bookings h3 { color: var(--blue); margin-bottom: 16px; }

.booking-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin-bottom: 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.booking-dates { font-weight: 600; }
.booking-status {
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
}
.status-pending { background: var(--yellow-light); color: var(--yellow-dark); }
.status-confirmed { background: #D1FAE5; color: var(--green); }
.status-rejected { background: #FEE2E2; color: var(--red); }

/* === Routes / Map === */

/* Route Selector */
/* === Route Filters === */
.route-filters-section {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  margin-bottom: 16px;
}
.route-filters-section h4 {
  margin: 0 0 8px;
  color: var(--text-muted);
  font-size: 0.8rem;
  font-weight: 600;
}
.route-filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}
.filter-chip {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 4px 10px;
  border: 1.5px solid var(--border);
  border-radius: 14px;
  background: var(--card);
  color: var(--text-light);
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  font-family: inherit;
}
.filter-chip:hover {
  border-color: var(--blue-light);
  color: var(--blue);
  background: rgba(0, 106, 167, 0.04);
}
.filter-chip.active {
  background: var(--blue);
  color: white;
  border-color: var(--blue);
}
.filter-chip-icon { font-size: 0.9rem; }
.filter-chip-label {
  white-space: nowrap;
  max-width: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-width 0.25s ease, opacity 0.2s ease, margin 0.25s ease;
  margin-left: 0;
}
.filter-chip:hover .filter-chip-label,
.filter-chip.active .filter-chip-label {
  max-width: 120px;
  opacity: 1;
  margin-left: 3px;
}

/* === Section Tabs (Chat & Gästebuch) === */
.section-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 24px;
}
.section-tab {
  padding: 10px 24px;
  border: 2px solid var(--border);
  border-radius: var(--radius);
  background: var(--card);
  color: var(--text-light);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}
.section-tab:hover {
  border-color: var(--blue-light);
  color: var(--blue);
}
.section-tab.active {
  background: var(--blue);
  color: white;
  border-color: var(--blue);
}

/* === Route Map Section === */
.route-map-section {
  margin-bottom: 32px;
}
.route-map-section h4 {
  margin: 0 0 12px;
  color: var(--text);
  font-size: 1rem;
}
.route-map-controls {
  margin-bottom: 12px;
}
.route-map {
  height: 500px;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.route-map-hint {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 8px;
  font-style: italic;
}

/* POI Chips */
.poi-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.poi-chip {
  display: inline-flex;
  align-items: center;
  gap: 0;
  padding: 5px 10px;
  border: 2px solid var(--border);
  border-radius: 20px;
  background: var(--card);
  color: var(--text-light);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  font-family: inherit;
}
.poi-chip:hover {
  border-color: var(--blue-light);
  color: var(--blue);
  background: rgba(0, 106, 167, 0.04);
}
.poi-chip.active {
  color: white;
  border-color: transparent;
}
.poi-chip-icon { font-size: 0.95rem; }
.poi-chip-label {
  white-space: nowrap;
  max-width: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-width 0.25s ease, opacity 0.2s ease, margin 0.25s ease;
  margin-left: 0;
}
.poi-chip:hover .poi-chip-label,
.poi-chip.active .poi-chip-label {
  max-width: 140px;
  opacity: 1;
  margin-left: 4px;
}

/* === Route List (Collapsed/Expanded Cards) === */
.route-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 24px;
}

/* Card Wrapper */
.route-card-wrap {
  border: 2px solid var(--border);
  border-radius: var(--radius);
  background: var(--card);
  overflow: hidden;
  transition: all 0.25s ease;
}
.route-card-wrap.filter-match {
  border-color: var(--blue-light);
  box-shadow: 0 2px 12px rgba(0, 106, 167, 0.12);
}
.route-card-wrap.filtered-out {
  opacity: 0.35;
  order: 100;
}
.route-card-wrap.expanded {
  border-color: var(--blue-light);
  box-shadow: 0 4px 20px rgba(0, 106, 167, 0.15);
}

/* Map Toggle Button (Eye Icon) */
.route-map-toggle {
  width: 40px;
  min-width: 40px;
  align-self: stretch;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  background: rgba(0, 0, 0, 0.02);
  cursor: pointer;
  transition: var(--transition);
  border-right: 1px solid var(--border);
  color: var(--text-muted);
  opacity: 0.35;
}
.route-map-toggle:hover {
  background: rgba(0, 106, 167, 0.08);
  opacity: 0.7;
}
.route-map-toggle.active {
  background: var(--blue);
  color: white;
  opacity: 1;
}
.route-eye-icon {
  display: block;
}

/* Collapsed Card */
.route-card-collapsed {
  display: flex;
  align-items: center;
  gap: 0;
  padding: 0;
  min-height: 56px;
  transition: background 0.15s ease;
}
.route-card-collapsed:hover {
  background: rgba(0, 106, 167, 0.03);
}
.route-card-color {
  width: 5px;
  align-self: stretch;
  flex-shrink: 0;
}
.route-card-summary {
  flex: 1;
  min-width: 0;
  padding: 10px 12px;
  cursor: pointer;
}
.route-card-top-line {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 2px;
}
.route-card-emoji {
  font-size: 1.1rem;
  flex-shrink: 0;
}
.route-card-title {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.route-card-badge {
  background: linear-gradient(135deg, var(--blue), var(--blue-light));
  color: white;
  font-size: 0.65rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 10px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  flex-shrink: 0;
}
.route-card-star {
  font-size: 0.85rem;
  flex-shrink: 0;
}
.route-card-bottom-line {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.8rem;
  color: var(--text-muted);
  flex-wrap: wrap;
}
.route-card-duration {
  font-weight: 600;
  color: var(--text);
}
.route-card-driving { white-space: nowrap; }
.route-card-ferry { white-space: nowrap; color: var(--blue); }
.route-card-price {
  font-weight: 700;
  color: var(--green);
  white-space: nowrap;
}
.route-card-dist {
  color: var(--text-muted);
  white-space: nowrap;
}
.route-card-toggle {
  padding: 0 16px;
  color: var(--text-muted);
  font-size: 0.75rem;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  cursor: pointer;
}

/* Expanded Card Content */
.route-card-expanded {
  padding: 0 20px 20px;
  border-top: 1px solid var(--border);
}
.route-expanded-content {
  padding-top: 16px;
}
.route-description {
  color: var(--text-light);
  font-size: 0.85rem;
  margin-bottom: 12px;
}
.route-details {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
}
.route-tag {
  background: rgba(0, 106, 167, 0.06);
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 0.8rem;
  color: var(--text);
  white-space: nowrap;
}
.route-reason {
  font-size: 0.85rem;
  color: var(--blue);
  margin-top: 8px;
  margin-bottom: 4px;
  font-style: italic;
}
.route-tags-row {
  margin-top: 8px;
  font-size: 0.85rem;
  color: var(--text-light);
  display: flex;
  align-items: center;
  gap: 4px;
}
.route-tag-icon {
  font-size: 1.1rem;
  cursor: default;
}

/* Route Footer (in expanded card) */
.route-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 14px;
  border-top: 1px solid var(--border);
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 12px;
}
.route-cost { white-space: nowrap; }
.route-cost .total {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--blue);
}
.route-cost .breakdown {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* Booking Links */
.route-booking-links {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.booking-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 14px;
  background: var(--blue);
  color: white !important;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
  text-decoration: none;
  transition: var(--transition);
  white-space: nowrap;
}
.booking-link:hover {
  background: var(--blue-light);
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0,106,167,0.3);
}
.booking-icon { font-size: 1rem; }

/* Route Note */
.route-note {
  background: rgba(0, 106, 167, 0.04);
  border-left: 4px solid var(--yellow);
  padding: 12px 16px;
  border-radius: 0 var(--radius) var(--radius) 0;
  margin-bottom: 32px;
  font-size: 0.85rem;
  color: var(--text-light);
}
.route-note p { margin: 0; }

/* === Photos === */
.upload-form {
  background: var(--card);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 32px;
  box-shadow: var(--shadow);
}

.upload-area {
  border: 2px dashed var(--border);
  border-radius: var(--radius);
  padding: 40px;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
  margin-bottom: 12px;
}

.upload-area:hover {
  border-color: var(--blue-light);
  background: rgba(0, 106, 167, 0.03);
}

.upload-icon { font-size: 3rem; margin-bottom: 8px; }

.upload-form .form-input { margin-bottom: 12px; }

#uploadPreview {
  margin-bottom: 12px;
}

#uploadPreview img {
  max-height: 200px;
  border-radius: var(--radius-sm);
}

.photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 16px;
  padding-bottom: 40px;
}

.photo-item {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  box-shadow: var(--shadow);
  transition: var(--transition);
  aspect-ratio: 4/3;
  background: var(--border);
}

.photo-item:hover {
  transform: scale(1.02);
  box-shadow: var(--shadow-lg);
}

.photo-item img, .photo-item video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.photo-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.6));
  color: white;
  padding: 24px 12px 12px;
  font-size: 0.85rem;
}

.photo-overlay .photo-author { font-weight: 700; }
.photo-overlay .photo-caption { opacity: 0.9; margin-top: 2px; }

.photo-delete {
  position: absolute;
  top: 8px;
  right: 8px;
  background: rgba(0, 0, 0, 0.5);
  color: white;
  border: none;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  cursor: pointer;
  display: none;
  font-size: 1rem;
  align-items: center;
  justify-content: center;
}

.photo-item:hover .photo-delete { display: flex; }

/* Lightbox */
.lightbox {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.9);
  z-index: 2000;
  align-items: center;
  justify-content: center;
}

.lightbox.active { display: flex; }

.lightbox-content {
  max-width: 90vw;
  max-height: 85vh;
  text-align: center;
}

.lightbox-content img, .lightbox-content video {
  max-width: 90vw;
  max-height: 80vh;
  border-radius: var(--radius-sm);
}

.lightbox-caption {
  color: white;
  padding: 12px;
  font-size: 0.95rem;
}

.lightbox-close, .lightbox-prev, .lightbox-next {
  position: absolute;
  background: rgba(255, 255, 255, 0.15);
  color: white;
  border: none;
  cursor: pointer;
  font-size: 2rem;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.lightbox-close:hover, .lightbox-prev:hover, .lightbox-next:hover {
  background: rgba(255, 255, 255, 0.3);
}

.lightbox-close { top: 20px; right: 20px; }
.lightbox-prev { left: 20px; top: 50%; transform: translateY(-50%); }
.lightbox-next { right: 20px; top: 50%; transform: translateY(-50%); }

/* === Chat === */
.chat-container {
  display: grid;
  grid-template-columns: 220px 1fr;
  height: 500px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--card);
  box-shadow: var(--shadow);
  margin-bottom: 40px;
}

.chat-sidebar {
  background: var(--bg);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
}

.chat-tabs {
  display: flex;
  border-bottom: 1px solid var(--border);
}

.chat-tab {
  flex: 1;
  padding: 12px 8px;
  border: none;
  background: transparent;
  font-family: inherit;
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  color: var(--text-light);
  transition: var(--transition);
}

.chat-tab.active {
  color: var(--blue);
  border-bottom: 2px solid var(--blue);
}

.online-users {
  padding: 12px;
  overflow-y: auto;
  flex: 1;
}

.online-users h4 { font-size: 0.8rem; text-transform: uppercase; color: var(--text-muted); margin-bottom: 8px; }

.online-user {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 0;
  font-size: 0.9rem;
}

.online-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--green);
  flex-shrink: 0;
}

.chat-main {
  display: flex;
  flex-direction: column;
}

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.chat-msg {
  max-width: 75%;
  padding: 10px 14px;
  border-radius: 16px;
  font-size: 0.95rem;
  line-height: 1.4;
}

.chat-msg.incoming {
  align-self: flex-start;
  background: var(--bg);
  border-bottom-left-radius: 4px;
}

.chat-msg.outgoing {
  align-self: flex-end;
  background: var(--blue);
  color: white;
  border-bottom-right-radius: 4px;
}

.chat-msg .msg-author {
  font-size: 0.75rem;
  font-weight: 700;
  margin-bottom: 2px;
  opacity: 0.7;
}

.chat-msg .msg-time {
  font-size: 0.7rem;
  opacity: 0.6;
  margin-top: 4px;
  text-align: right;
}

.chat-input {
  display: flex;
  gap: 8px;
  padding: 12px;
  border-top: 1px solid var(--border);
}

.chat-input input {
  flex: 1;
  padding: 10px 14px;
  border: 2px solid var(--border);
  border-radius: 24px;
  font-family: inherit;
  font-size: 0.95rem;
}

.chat-input input:focus {
  outline: none;
  border-color: var(--blue-light);
}

/* === Guestbook === */
.guestbook-form {
  max-width: 600px;
  margin: 0 auto 32px;
  display: flex;
  gap: 12px;
}

.guestbook-form textarea {
  flex: 1;
  resize: vertical;
}

.guestbook-entries {
  max-width: 700px;
  margin: 0 auto;
  padding-bottom: 40px;
}

.guestbook-entry {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin-bottom: 12px;
}

.guestbook-entry .entry-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.guestbook-entry .entry-author { font-weight: 700; color: var(--blue); }
.guestbook-entry .entry-date { font-size: 0.8rem; color: var(--text-muted); }
.guestbook-entry .entry-message { color: var(--text-light); }

/* === Gästebuch Feed (Combined Blog) === */
.gb-post-form {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 24px;
}
.gb-post-form textarea {
  margin-bottom: 10px;
  resize: vertical;
}
.gb-post-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}
.gb-photo-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg);
  color: var(--text-light);
  font-size: 0.85rem;
  cursor: pointer;
  transition: var(--transition);
}
.gb-photo-btn:hover {
  border-color: var(--blue-light);
  color: var(--blue);
}
#gbUploadPreview {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin-top: 10px;
  position: relative;
}
.gb-preview-remove {
  position: absolute;
  top: 4px;
  right: 4px;
  background: rgba(0,0,0,0.6);
  color: white;
  border: none;
  border-radius: 50%;
  width: 24px;
  height: 24px;
  cursor: pointer;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
}
.gb-feed {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.gb-post {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 20px;
  transition: var(--transition);
}
.gb-post:hover {
  box-shadow: var(--shadow);
}
.gb-post-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  position: relative;
}
.gb-post-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--blue);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
  flex-shrink: 0;
}
.gb-post-author {
  font-weight: 700;
  color: var(--blue);
  display: block;
}
.gb-post-date {
  font-size: 0.78rem;
  color: var(--text-muted);
  display: block;
}
.gb-post-delete {
  position: absolute;
  top: 0;
  right: 0;
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 1.2rem;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 4px;
}
.gb-post-delete:hover {
  color: var(--red);
  background: rgba(228, 87, 46, 0.08);
}
.gb-post-text {
  color: var(--text);
  line-height: 1.6;
  margin-bottom: 8px;
  white-space: pre-line;
}
.gb-post-media {
  cursor: pointer;
  border-radius: var(--radius-sm);
  overflow: hidden;
  margin-top: 4px;
}
.gb-post-media img,
.gb-post-media video {
  width: 100%;
  max-height: 500px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  display: block;
}
.gb-post-media:hover img,
.gb-post-media:hover video {
  opacity: 0.92;
}

/* === Auth === */
.auth-card {
  max-width: 420px;
  margin: 60px auto;
  background: var(--card);
  border-radius: var(--radius);
  padding: 40px;
  box-shadow: var(--shadow-lg);
}

.auth-card h2 {
  color: var(--blue);
  margin-bottom: 24px;
  text-align: center;
}

.auth-switch {
  text-align: center;
  margin-top: 20px;
  color: var(--text-light);
}

.error-msg {
  background: #FEE2E2;
  color: var(--red);
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  margin-bottom: 12px;
}

.info-box {
  background: rgba(0, 106, 167, 0.05);
  border: 1px solid var(--blue-light);
  border-radius: var(--radius);
  padding: 20px;
  text-align: center;
  margin: 20px auto;
  max-width: 500px;
}

/* === Profile === */
.profile-settings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
  margin-bottom: 40px;
}

.profile-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
}

.profile-card h3 {
  color: var(--blue);
  font-size: 1.1rem;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

/* === Admin === */
.admin-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.stat-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  text-align: center;
}

.stat-number {
  font-size: 2rem;
  font-weight: 700;
  color: var(--blue);
}

.stat-label {
  font-size: 0.85rem;
  color: var(--text-light);
  margin-top: 4px;
}

.admin-tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 20px;
  border-bottom: 2px solid var(--border);
  padding-bottom: 4px;
}

.admin-tab {
  padding: 10px 20px;
  border: none;
  background: transparent;
  font-family: inherit;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  color: var(--text-light);
  border-radius: var(--radius-sm) var(--radius-sm) 0 0;
  transition: var(--transition);
}

.admin-tab.active {
  color: var(--blue);
  background: rgba(0, 106, 167, 0.08);
}

.admin-panel {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 40px;
}

.admin-booking {
  border-bottom: 1px solid var(--border);
  padding: 16px 0;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 16px;
  align-items: center;
}

.admin-booking:last-child { border-bottom: none; }

.admin-booking .booking-info h4 { margin-bottom: 4px; }
.admin-booking .booking-meta { font-size: 0.85rem; color: var(--text-light); }

.admin-booking .booking-actions {
  display: flex;
  gap: 8px;
}

.admin-user {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}

.admin-user:last-child { border-bottom: none; }

.settings-form { max-width: 500px; }
.settings-form .form-row { margin-bottom: 16px; }

/* Route edit in admin */
.admin-route {
  border-bottom: 1px solid var(--border);
  padding: 16px 0;
}
.admin-route:last-child { border-bottom: none; }
.admin-route h4 { color: var(--blue); margin-bottom: 8px; }

.admin-route .cost-inputs {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.admin-route .cost-inputs label {
  font-size: 0.85rem;
  color: var(--text-light);
}

.admin-route .cost-inputs input {
  width: 100px;
  padding: 6px 10px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}

/* === Toast === */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 3000;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.toast {
  background: var(--card);
  border-radius: var(--radius-sm);
  padding: 14px 20px;
  box-shadow: var(--shadow-lg);
  border-left: 4px solid var(--blue);
  font-size: 0.95rem;
  animation: slideIn 0.3s ease;
  max-width: 360px;
}

.toast.success { border-left-color: var(--green); }
.toast.error { border-left-color: var(--red); }
.toast.warning { border-left-color: var(--yellow-dark); }

@keyframes slideIn {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

/* === Loading === */
.loading { text-align: center; color: var(--text-muted); padding: 40px; }

/* === Footer === */
.footer {
  background: var(--blue-dark);
  color: rgba(255, 255, 255, 0.8);
  padding: 20px 24px;
  margin-top: auto;
  font-size: 0.9rem;
}

.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.footer-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* === Responsive === */
@media (max-width: 768px) {
  .nav-toggle { display: block; }

  .nav-links {
    display: none;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    background: var(--blue);
    flex-direction: column;
    padding: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    z-index: 999;
  }

  .nav-links.open { display: flex; }
  .nav-auth { margin-left: 0; margin-top: 8px; flex-wrap: wrap; }

  .hero h1 { font-size: 2rem; }
  .hero-subtitle { font-size: 1rem; }
  .hero { padding: 50px 24px; }

  .welcome-section { grid-template-columns: 1fr; }
  .welcome-photo { max-width: 250px; margin: 0 auto; }

  .features-grid { grid-template-columns: 1fr; }

  .house-photo { height: 250px; }

  /* Route cards mobile */
  .route-card-bottom-line { gap: 6px; font-size: 0.72rem; }
  .route-card-title { font-size: 0.88rem; }
  .route-footer { flex-direction: column; align-items: flex-start; }
  .route-booking-links { width: 100%; }
  .booking-link { flex: 1; justify-content: center; }
  .filter-chip { padding: 3px 8px; font-size: 0.72rem; }
  .filter-chip-icon { font-size: 1rem; }
  .route-card-expanded { padding: 0 14px 14px; }
  .route-map-toggle { width: 34px; min-width: 34px; font-size: 0.9rem; }
  .route-details { gap: 6px; }
  .route-tag { font-size: 0.75rem; padding: 3px 8px; }

  .chat-container { grid-template-columns: 1fr; height: 400px; }
  .chat-sidebar { display: none; }

  .form-row { grid-template-columns: 1fr; }

  .guestbook-form { flex-direction: column; }

  .route-map { height: 300px; }

  .admin-booking { grid-template-columns: 1fr; }
  .admin-booking .booking-actions { justify-content: flex-start; }

  .calendar-selection-bar { flex-direction: column; text-align: center; }
  .selection-actions { width: 100%; justify-content: center; }

  .day-cost { font-size: 9px; padding: 0 2px; }
  .cost-icon { width: 9px; height: 9px; }
  .fc .fc-daygrid-day-frame { min-height: 60px; }

  .calendar-controls { flex-direction: column; align-items: flex-start; }
  .calendar-legend { gap: 8px; }

  /* FullCalendar mobile toolbar */
  .fc .fc-toolbar { flex-direction: column; gap: 8px; }
  .fc .fc-toolbar-chunk { display: flex; justify-content: center; }
  .fc .fc-toolbar-title { font-size: 1.1rem !important; }
  .fc .fc-button { padding: 6px 10px !important; font-size: 0.8rem !important; }

  /* Calendar compact */
  #calendar { padding: 12px; }

  /* Photo grid: 2 columns */
  .photo-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
  .photo-delete { display: flex; }

  /* Tips grid single column */
  .tips-grid { grid-template-columns: 1fr; }

  /* Admin tabs: scrollable */
  .admin-tabs {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    flex-wrap: nowrap;
  }
  .admin-tabs::-webkit-scrollbar { display: none; }
  .admin-tab { white-space: nowrap; padding: 8px 14px; font-size: 0.85rem; flex-shrink: 0; }

  /* Admin panel compact */
  .admin-panel { padding: 14px; }
  .settings-form { max-width: 100%; }

  /* Admin stats 2x2 */
  .admin-stats { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .stat-card { padding: 14px; }
  .stat-number { font-size: 1.5rem; }

  /* Section tabs full width */
  .section-tab { flex: 1; text-align: center; padding: 10px 12px; font-size: 0.85rem; }

  /* Page headers compact */
  .page-header { padding: 24px 0 16px; }
  .page-header h2 { font-size: 1.5rem; }
  .page-header p { font-size: 0.95rem; }

  /* Holiday panel compact */
  .holiday-panel { padding: 14px; }
  .checkbox-grid { grid-template-columns: 1fr; }

  /* Footer stacked */
  .footer-content { flex-direction: column; text-align: center; }

  /* Route cost compact */
  .route-cost .total { font-size: 1.1rem; }

  /* Lightbox touch-friendly */
  .lightbox-prev, .lightbox-next { font-size: 1.5rem; padding: 12px; }
  .lightbox-close { font-size: 1.5rem; padding: 8px 12px; }

  /* Toast: full width */
  .toast-container { left: 16px; right: 16px; bottom: 16px; }
  .toast { max-width: 100%; }

  /* Weather compact */
  .weather-day { min-width: 80px; padding: 10px 12px; }
  .weather-day .icon { font-size: 1.4rem; }
  .weather-day .temp { font-size: 1.1rem; }

  /* Month/Year nav compact */
  .cal-picker-months { grid-template-columns: repeat(2, 1fr); }
  .cal-picker-years { grid-template-columns: repeat(3, 1fr); }
  .cal-title-picker { padding: 16px; }

  /* Day popup responsive */
  .day-popup-body { max-width: 100%; }
  .day-popup-header { padding: 12px 16px; }
  .day-popup-events { padding: 10px 16px; }

  /* Modal responsive */
  .modal-card { padding: 18px; max-width: 100%; }

  /* Profile responsive */
  .profile-settings-grid { grid-template-columns: 1fr; }
  .profile-card { padding: 18px; }
}

@media (max-width: 480px) {
  .hero h1 { font-size: 1.5rem; }
  .hero-subtitle { font-size: 0.9rem; margin-bottom: 20px; }
  .hero { padding: 36px 16px; }
  .hero-buttons { flex-direction: column; }
  .hero-buttons .btn { width: 100%; }
  .container { padding: 0 12px; }
  .auth-card { padding: 20px; margin: 20px 12px; }

  /* Nav compact */
  .nav-brand { font-size: 1rem; gap: 8px; }
  .navbar { padding: 0 12px; min-height: 56px; }
  .nav-links { top: 56px; }

  /* Calendar: more compact */
  .fc .fc-daygrid-day-frame { min-height: 44px; }
  .fc .fc-daygrid-day-number { font-size: 0.8rem; padding: 2px 4px; }
  .day-costs { display: none; }
  .fc .fc-toolbar-title { font-size: 1rem !important; }
  .fc .fc-button { padding: 4px 8px !important; font-size: 0.75rem !important; }

  /* Route map smaller */
  .route-map { height: 250px; }

  /* Chat shorter */
  .chat-container { height: 320px; }
  .chat-msg { max-width: 85%; font-size: 0.9rem; }

  /* Booking card stacked */
  .booking-card { flex-direction: column; align-items: flex-start; gap: 8px; }

  /* Photo grid compact */
  .photo-grid { grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); }

  /* Admin route inputs */
  .admin-route .cost-inputs input { width: 80px; }

  /* Guestbook compact */
  .guestbook-entry { padding: 12px 14px; }
  .guestbook-entry .entry-header { flex-direction: column; align-items: flex-start; gap: 2px; }

  /* Upload area compact */
  .upload-area { padding: 24px 16px; }
  .upload-icon { font-size: 2rem; }

  /* Weather scroll */
  .weather-day { min-width: 70px; padding: 8px 10px; }
  .weather-day .icon { font-size: 1.2rem; }
  .weather-day .temp { font-size: 1rem; }
  .weather-day .range { font-size: 0.7rem; }

  /* Route filter compact */
  .route-filters-section { padding: 8px 10px; }
  .route-filters-section h4 { font-size: 0.75rem; margin-bottom: 5px; }
  .route-card-driving { display: none; }
  .poi-chip { font-size: 0.72rem; padding: 3px 6px; }
  .route-map-toggle { width: 30px; min-width: 30px; font-size: 0.85rem; }

  /* Selection bar compact */
  .selection-info { font-size: 0.85rem; }
  .selection-hint { display: none; }
}

/* Extra small phones */
@media (max-width: 360px) {
  .hero h1 { font-size: 1.2rem; }
  .nav-brand span { display: none; }
  .admin-stats { grid-template-columns: 1fr; }
  .fc .fc-button { padding: 3px 6px !important; font-size: 0.7rem !important; }
}

/* === Comments === */
.gb-post-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid var(--border);
}
.gb-comment-toggle {
  background: none;
  border: none;
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.85rem;
  cursor: pointer;
  padding: 4px 0;
}
.gb-comment-toggle:hover { color: var(--blue); }
.gb-comments {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}
.gb-comments-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 10px;
}
.gb-comment {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  font-size: 0.9rem;
  position: relative;
}
.gb-comment-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--blue-light);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.75rem;
  flex-shrink: 0;
}
.gb-comment-body {
  flex: 1;
  background: var(--bg);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
}
.gb-comment-author {
  font-weight: 700;
  font-size: 0.8rem;
  color: var(--blue);
}
.gb-comment-text { margin-top: 2px; line-height: 1.4; }
.gb-comment-time { font-size: 0.7rem; color: var(--text-muted); margin-top: 2px; }
.gb-comment-delete {
  position: absolute;
  top: 4px;
  right: 4px;
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 0.9rem;
  opacity: 0;
  transition: var(--transition);
}
.gb-comment:hover .gb-comment-delete { opacity: 1; }
.gb-comment-delete:hover { color: #e53e3e; }
.gb-comment-form {
  display: flex;
  gap: 8px;
  align-items: center;
}
.gb-comment-input {
  flex: 1;
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: 20px;
  font-family: inherit;
  font-size: 0.9rem;
}
.gb-comment-input:focus { outline: none; border-color: var(--blue-light); }

/* === Tags === */
.gb-post-tags { display: flex; flex-wrap: wrap; gap: 4px; }
.gb-tag {
  display: inline-block;
  padding: 2px 10px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 600;
}
.gb-tag.clickable { cursor: pointer; }
.gb-tag.clickable:hover {
  background: var(--blue);
  color: white;
  border-color: var(--blue);
}
.gb-tags-input { margin-top: 8px; }
.gb-tags-label {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 4px;
  display: block;
}
.gb-tags-wrapper {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  padding: 6px 10px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: white;
  min-height: 38px;
}
.gb-tags-selected { display: flex; flex-wrap: wrap; gap: 4px; }
.gb-tags-field {
  border: none;
  outline: none;
  font-family: inherit;
  font-size: 0.9rem;
  min-width: 100px;
  flex: 1;
}
.gb-tag-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  background: var(--blue);
  color: white;
  border-radius: 12px;
  font-size: 0.8rem;
  font-weight: 600;
}
.gb-tag-pill button {
  background: none;
  border: none;
  color: white;
  cursor: pointer;
  font-size: 0.9rem;
  padding: 0;
  line-height: 1;
}
.gb-tags-suggestions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
}
.gb-tag-suggestion {
  padding: 3px 10px;
  border: 1px solid var(--border);
  border-radius: 12px;
  font-size: 0.8rem;
  cursor: pointer;
  background: var(--bg);
  color: var(--text-muted);
  transition: var(--transition);
}
.gb-tag-suggestion:hover {
  background: var(--blue);
  color: white;
  border-color: var(--blue);
}

/* === Feed Filters === */
.gb-filter-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}
.gb-filter-toggle {
  background: none;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 6px 12px;
  font-family: inherit;
  font-size: 0.85rem;
  cursor: pointer;
  color: var(--text-muted);
  transition: var(--transition);
}
.gb-filter-toggle:hover { border-color: var(--blue-light); color: var(--blue); }
.gb-filters {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 16px;
}
.gb-filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: flex-end;
}
.gb-filter-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.gb-filter-group label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
}
.gb-filter-group input,
.gb-filter-group select {
  padding: 6px 10px;
  font-size: 0.85rem;
  height: 34px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: inherit;
}

/* === DM User Picker === */
.dm-user-picker { padding: 12px; }
.dm-user-picker h4 {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 8px;
}
.dm-user-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: 0.9rem;
  transition: var(--transition);
}
.dm-user-item:hover { background: var(--bg); }
.dm-user-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--blue);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.75rem;
  flex-shrink: 0;
}
.dm-unread-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #e53e3e;
  margin-left: auto;
}

/* === @-Mention Dropdown === */
.chat-input { position: relative; }
.mention-dropdown {
  position: absolute;
  bottom: 100%;
  left: 0;
  right: 60px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-lg);
  max-height: 180px;
  overflow-y: auto;
  z-index: 10;
}
.mention-item {
  padding: 8px 14px;
  cursor: pointer;
  font-size: 0.9rem;
  transition: var(--transition);
}
.mention-item:hover, .mention-item.active {
  background: var(--bg);
  color: var(--blue);
}
