@charset "UTF-8";
/* ============================================ */
/* Variables & Theme Configuration              */
/* ============================================ */
/* SASS Variables */
/* CSS Custom Properties for Theme Support */
:root {
  /* Light mode (default) */
  --bg-primary: #fefefe;
  --bg-secondary: #f9f9f9;
  --bg-tertiary: #ffffff;
  --bg-card: #fff;
  --bg-table: #eeeee1;
  --bg-badge: #f0f0f0;
  --text-primary: #1a1a1a;
  --text-secondary: #666;
  --text-muted: #6c757d;
  --text-table: #333;
  --text-quote: #6a737d;
  --border-light: #eee;
  --border-medium: #e0e0e0;
  --border-gray: #ccc;
  --border-dark: #aaa;
  --border-table: #ccc;
  --border-quote: #dfe2e5;
  --border-badge: #ddd;
  --accent-red: #cc0000;
  --accent-red-dark: #a4343a;
  --accent-blue: #75ade8;
  --accent-blue-dark: #5a96d0;
  --accent-gray: #2f4f4f;
  --accent-orange: #ee802f;
  --shadow-light: rgba(0, 0, 0, 0.08);
  --shadow-medium: rgba(0, 0, 0, 0.15);
  --shadow-code: #eee;
  --shadow-nav: rgba(0, 0, 0, 0.1);
}

/* Dark mode - manual override only */
:root[data-theme=dark] {
  --bg-primary: #2d2d2d;
  --bg-secondary: #363636;
  --bg-tertiary: #3d3d3d;
  --bg-card: #333333;
  --bg-table: #3a3a3a;
  --bg-badge: #404040;
  --text-primary: #ffffff;
  --text-secondary: #b8b8b8;
  --text-muted: #999;
  --text-table: #e0e0e0;
  --text-quote: #a0a0a0;
  --border-light: #444;
  --border-medium: #4a4a4a;
  --border-gray: #555;
  --border-dark: #666;
  --border-table: #555;
  --border-quote: #555;
  --border-badge: #555;
  --accent-red: #ff3333;
  --accent-red-dark: #ff1a1a;
  --accent-blue: #8bbfef;
  --accent-blue-dark: #75ade8;
  --accent-gray: #5a8a8a;
  --accent-orange: #ff9d5c;
  --shadow-light: rgba(0, 0, 0, 0.3);
  --shadow-medium: rgba(0, 0, 0, 0.4);
  --shadow-code: #1a1a1a;
  --shadow-nav: rgba(0, 0, 0, 0.3);
}

/* ============================================ */
/* Base Styles & Typography                     */
/* ============================================ */
html {
  position: relative;
  min-height: 100%;
}

body {
  background: var(--bg-primary);
  color: var(--text-primary);
  font-family: Verdana, "Segoe UI", Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
  font-size: 14px;
  min-height: 100%;
  display: flex;
  flex-direction: column;
  margin: 0;
}

/* Typography */
h1,
h2,
h3,
h4,
h5 {
  line-height: 1.2;
  margin: 1rem 0;
}

section h1 {
  font-size: 150%;
}
section h2 {
  font-size: 120%;
}
section h3 {
  font-size: 115%;
}
section h4 {
  font-size: 110%;
}
section h5 {
  font-size: 100%;
}

.posts h1 {
  font-size: 150%;
}
.posts h2 {
  font-size: 130%;
}
.posts h3 {
  font-size: 120%;
}
.posts h4 {
  font-size: 110%;
}
.posts h5 {
  font-size: 100%;
}

/* Links */
a {
  text-decoration: none;
  color: var(--accent-blue);
}
a:hover {
  color: var(--accent-blue-dark);
  border-bottom: 1px var(--border-gray) dotted;
}

/* Code Blocks */
code {
  font-size: 100%;
}

pre {
  border-radius: 5px;
  box-shadow: 2px 2px 2px var(--shadow-code);
}
pre code {
  border-radius: 5px;
  font-size: 125%;
}

blockquote {
  border-left: 0.25em solid var(--border-quote);
  color: var(--text-quote);
  padding: 0 1em;
}

/* Images & Figures */
figure {
  margin: 2.5rem 0;
}
figure img {
  width: 100%;
  height: auto;
  border: 1px solid var(--border-medium);
  box-shadow: 0 4px 12px var(--shadow-light);
}
figure figcaption {
  font-size: 0.9em;
  font-style: italic;
  color: var(--text-secondary);
  margin-top: 0.75rem;
  text-align: center;
}

/* Accessibility */
.skip-link {
  position: absolute;
  top: -40px;
  left: 0;
  background: #000;
  color: #fff;
  padding: 8px;
  text-decoration: none;
  z-index: 100;
}
.skip-link:focus {
  top: 0;
}

/* Performance Optimizations */
.jekyll-glossary .jekyll-glossary-tooltip {
  will-change: opacity;
  transform: translateZ(0);
}

/* ============================================ */
/* Layout & Structure                           */
/* ============================================ */
main {
  display: flex;
  flex-wrap: wrap;
  max-width: 54rem;
  width: 100%;
  margin: 2rem 0;
  padding: 1rem;
  padding-bottom: 3rem;
  flex: 1 0 auto;
  box-sizing: border-box;
}

header {
  flex-grow: 1;
  flex-basis: 10rem;
  position: relative;
}
header ul {
  list-style: none;
}
header a {
  color: var(--text-primary);
  text-decoration: none;
}
header a:hover {
  color: var(--text-primary);
  border-bottom: 1px var(--border-gray) dotted;
}
header li {
  margin-bottom: 0.2rem;
  text-align: right;
  margin-right: 2rem;
}

section {
  flex-basis: 0;
  flex-grow: 999;
  min-width: 70%;
  display: flex;
  flex-direction: column;
}

header,
section {
  padding: 1rem;
}

nav ul {
  border-right: 1px solid var(--border-light);
}

footer {
  position: absolute;
  bottom: 0;
  max-width: 54rem;
  width: 100%;
  height: 50px;
  padding-left: 10rem;
  box-sizing: border-box;
}

/* Footer Links - Theme Aware */
footer a,
.socials a {
  color: #000;
}
footer a:hover,
.socials a:hover {
  color: var(--accent-red);
}

:root[data-theme=dark] footer a,
:root[data-theme=dark] .socials a {
  color: #fff;
}
:root[data-theme=dark] footer a:hover,
:root[data-theme=dark] .socials a:hover {
  color: var(--accent-red);
}

/* ============================================ */
/* Navigation & Menu Styles                     */
/* ============================================ */
/* Theme Toggle Button */
.theme-toggle {
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  font-family: inherit;
  font-size: 1rem;
  color: var(--text-primary);
  transition: all 150ms ease;
  display: inline-flex;
  align-items: center;
  text-align: right;
}
.theme-toggle:hover {
  color: var(--accent-red);
}
.theme-toggle .theme-icon {
  font-size: 1em;
  display: inline-block;
}
.theme-toggle span:not(.theme-icon) {
  display: none;
}

/* Hamburger Menu Toggle */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  z-index: 1000;
  transition: all 250ms ease;
}
.nav-toggle .hamburger {
  display: block;
  width: 25px;
  height: 3px;
  background: var(--text-primary);
  margin: 5px 0;
  transition: all 250ms ease;
  border-radius: 3px;
}
.nav-toggle {
  /* Scrolled state: transform to vertical dots */
}
.nav-toggle.scrolled:not(.active) .hamburger {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  margin: 3px 0;
  margin-left: auto; /* Stick to right */
}
.nav-toggle {
  /* Active state: X icon */
}
.nav-toggle.active .hamburger:nth-child(1) {
  transform: rotate(45deg) translate(7px, 7px);
}
.nav-toggle.active .hamburger:nth-child(2) {
  opacity: 0;
}
.nav-toggle.active .hamburger:nth-child(3) {
  transform: rotate(-45deg) translate(7px, -7px);
}

/* Submenu Toggle Button */
.submenu-toggle {
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  width: 100%;
  text-align: right;
  font-family: inherit;
  font-size: inherit;
  gap: 0.5rem;
  margin-bottom: 0.2rem;
}
.submenu-toggle .submenu-title {
  color: var(--text-primary);
}
.submenu-toggle .submenu-title:hover {
  border-bottom: 1px var(--border-gray) dotted;
}
.submenu-toggle .submenu-arrow {
  font-size: 0.8em;
  transition: transform 250ms ease;
  display: inline-block;
  color: var(--accent-red);
  order: -1;
}

/* Submenu Container */
.submenu {
  list-style: none;
  max-height: 0;
  overflow: hidden;
  transition: max-height 250ms ease ease-out;
  padding-left: 0;
  margin-top: 0;
  margin-bottom: 0;
}
.submenu.submenu-open {
  max-height: 500px;
  transition: max-height 250ms ease ease-in;
  margin-bottom: 0.3rem;
}
.submenu li {
  margin-bottom: 0.5rem;
  text-align: right;
  margin-right: 2rem;
  padding-left: 0;
}
.submenu li a {
  color: var(--text-primary);
  font-size: 0.95em;
}
.submenu li a:hover {
  color: var(--text-primary);
  border-bottom: 1px var(--border-gray) dotted;
}
.submenu li a.active {
  color: var(--accent-red);
  font-weight: 600;
}

/* ============================================ */
/* Reusable Components                          */
/* ============================================ */
/* Project Status Badge */
.project-status {
  display: inline-block;
  padding: 0.2em 0.5em;
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1;
  text-align: center;
  white-space: nowrap;
  border-radius: 3px;
  margin-top: 0.75rem;
  background-color: var(--bg-badge);
  color: var(--text-secondary);
  border: 1px solid var(--border-badge);
}

/* Project Cards */
.card-link {
  text-decoration: none;
  color: inherit;
  display: block;
}
.card-link:hover {
  border-bottom: none;
}

.project-card {
  border: 1px solid var(--border-medium);
  border-radius: 4px;
  background: var(--bg-card);
  transition: all 150ms ease;
  cursor: pointer;
}
.project-card:hover {
  box-shadow: 0 4px 12px var(--shadow-medium);
  transform: translateY(-2px);
}
.project-card {
  /* Side Image Layout - only when image exists */
}
.project-card.side-image-layout {
  display: flex;
  flex-direction: row;
  align-items: stretch;
}
.project-card .card-text-area {
  flex: 1;
  min-width: 0;
}
.project-card .card-image-area {
  flex-shrink: 0;
  width: 100px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem;
  padding-left: 0;
}
.project-card .card-img-side {
  width: 100%;
  height: 80px;
  object-fit: cover;
  border-radius: 3px;
  display: block;
}
.project-card .card-title {
  color: var(--text-table);
  font-size: 120%;
  margin-top: 0;
}
.project-card .card-subtitle {
  font-size: 110%;
}
.project-card .card-text {
  margin: 0.75rem 0 0 0;
  color: var(--text-secondary);
  line-height: 1.4;
}
.project-card .github-link {
  color: var(--text-primary);
}
.project-card .github-link:hover {
  color: var(--text-table);
  border-bottom: none;
}

.card {
  display: block;
  margin-bottom: 1.5rem;
}

.card-body {
  padding: 1rem 1.25rem;
}

/* Collapsible Details Block (HTML <details> tag) */
details {
  margin: 0rem 0 0 0;
  padding: 0;
  border: none;
  background-color: transparent;
}

summary {
  cursor: pointer;
  padding: 0rem 0;
  color: var(--text-primary);
}
summary:hover {
  color: var(--text-table);
}

details > *:not(summary) {
  padding: 0.5rem 0 0.5rem 1.5rem;
  margin-top: 0.25rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Digest Entries */
.digest-entry {
  margin-bottom: 2rem;
}

.digest-citation {
  line-height: 1.6;
  margin-bottom: 0.25rem;
}

.digest-note {
  color: var(--text-secondary);
  font-style: italic;
  margin: 0.25rem 0;
}

.digest-abstract {
  margin-top: 0.5rem;
}

/* Digest-specific spacing */
.digest-post-content h2 {
  margin-bottom: 1.5rem;
}
.digest-post-content p {
  margin-bottom: 0.5rem;
  line-height: 1.6;
}
.digest-post-content p:has(+ details) {
  margin-bottom: 0;
}
.digest-post-content details {
  margin: 0;
}
.digest-post-content details + p {
  margin-top: 1.5rem;
}
.digest-post-content details + h2,
.digest-post-content details + h3 {
  margin-top: 2.5rem;
}

/* Forms & Inputs */
input[type=text] {
  outline: none;
  padding: 0.7rem;
  width: 100%;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  font-family: inherit;
  font-size: 100%;
  border: none;
  border-bottom: 1px solid var(--border-gray);
  background: var(--bg-primary);
  color: var(--text-primary);
}

/* Search */
#search-container {
  max-width: 100%;
}

#results-container {
  margin: 1rem 0;
  background-color: var(--bg-secondary);
}

/* ============================================ */
/* Image Comparison Slider                      */
/* ============================================ */
.image-comparison {
  position: relative;
  width: 100%;
  max-width: 800px;
  margin: 2em auto;
  overflow: hidden;
  user-select: none;
  border-radius: 4px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  touch-action: pan-y;
}

.image-comparison img {
  display: block;
  width: 100%;
  height: auto;
  pointer-events: none;
}

.comparison-after {
  position: relative;
  width: 100%;
}

.comparison-before {
  position: absolute;
  top: 0;
  left: 0;
  width: 50%;
  height: 100%;
  overflow: hidden;
}

.comparison-before img {
  position: absolute;
  top: 0;
  left: 0;
  width: auto;
  height: 100%;
  max-width: none;
  object-fit: cover;
}

.comparison-slider {
  position: absolute;
  top: 0;
  left: 50%;
  width: 2px;
  height: 100%;
  background: rgba(255, 255, 255, 0.8);
  cursor: ew-resize;
  transform: translateX(-50%);
  z-index: 10;
  box-shadow: 0 0 4px rgba(0, 0, 0, 0.2);
}

.slider-button {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 40px;
  height: 40px;
  background: transparent;
  cursor: ew-resize;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.slider-button::before {
  content: "";
  position: absolute;
  left: 8px;
  width: 10px;
  height: 10px;
  border-left: 2px solid white;
  border-bottom: 2px solid white;
  transform: rotate(45deg);
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.3));
}

.slider-button::after {
  content: "";
  position: absolute;
  right: 8px;
  width: 10px;
  height: 10px;
  border-right: 2px solid white;
  border-top: 2px solid white;
  transform: rotate(45deg);
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.3));
}

.slider-button:hover::before,
.slider-button:hover::after {
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.4));
}

/* ============================================ */
/* Posts & Content Styles                       */
/* ============================================ */
/* Page Titles */
.page-title {
  color: var(--accent-red);
}

.page-title-h2 {
  color: var(--accent-red);
}

/* Post Listings */
.posts ul {
  list-style: none;
}
.posts li {
  align-items: center;
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.5rem;
}
.posts li a {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--text-primary);
}
.posts li a:hover {
  color: var(--accent-blue);
}
.posts li time {
  padding-left: 1rem;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.posts {
  /* Tags - keep blue */
}
.posts p a {
  color: var(--accent-blue);
}
.posts p a:hover {
  color: var(--accent-blue-dark);
}

/* RSS Link */
.rss {
  color: var(--accent-red);
  text-decoration: none;
  display: inline;
  margin-right: 1rem;
}
.rss span {
  color: var(--accent-orange);
  margin-left: 0.2em;
}
.rss:hover {
  text-decoration: none;
  text-decoration-style: none;
  text-decoration-color: var(--accent-red-dark);
  color: var(--accent-red-dark);
  border-bottom: none;
}
.rss:hover span {
  color: var(--accent-orange);
}

/* Post Content */
.digest-post-content {
  line-height: 1.65;
  font-size: 1.05em;
  margin-bottom: 2em;
}
.digest-post-content p,
.digest-post-content ul,
.digest-post-content ol {
  margin-bottom: 1em;
}
.digest-post-content h2,
.digest-post-content h3 {
  margin-top: 2em;
  margin-bottom: 0.5em;
  color: var(--accent-gray);
}
.digest-post-content a {
  color: var(--accent-blue);
  text-decoration: none;
}
.digest-post-content a:hover {
  color: var(--accent-blue-dark);
  border-bottom: none;
}

/* ============================================ */
/* Tables                                       */
/* ============================================ */
table tr th {
  background: var(--bg-table);
  color: var(--text-table);
  padding: 0;
  border: 1px solid var(--border-dark);
  text-align: center;
  font-weight: bold;
}
table tr td {
  border: 1px solid var(--border-table);
  padding: 5px;
}
table tr td.rightright {
  background: var(--bg-table);
}
table tr td h4 {
  margin: 0;
  padding: 0;
  font-weight: normal;
}

/* ============================================ */
/* Utility Classes                              */
/* ============================================ */
.row {
  margin: 0 -0.5rem;
}

.col {
  padding: 0 0.5rem;
}

.py-2 {
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
}

.pb-2 {
  padding-bottom: 0.5rem;
}

.mb-2 {
  margin-bottom: 0.5rem;
}

.p-3 {
  padding: 1rem;
}

.text-muted {
  color: var(--text-muted) !important;
}

.border {
  border: 1px solid var(--border-medium) !important;
}

.border-4 {
  border-width: 4px !important;
}

.rounded {
  border-radius: 0.25rem;
}

/* ============================================ */
/* Maps Page Styles                             */
/* ============================================ */
.page-intro {
  line-height: 1.65;
  margin-bottom: 2rem;
  color: var(--text-secondary);
}

.map-container {
  margin: 2rem 0;
  background: var(--bg-card);
  border: 1px solid var(--border-medium);
  border-radius: 4px;
  overflow: hidden;
}

/* Map Controls */
.map-controls {
  padding: 1rem;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-light);
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  flex-wrap: wrap;
  justify-content: flex-end;
}

/* Filter Dropdown */
.filter-dropdown {
  position: relative;
  min-width: 130px;
}
.filter-dropdown label {
  display: block;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-muted);
  margin-bottom: 0.25rem;
  font-weight: 600;
}

.dropdown-toggle {
  width: 100%;
  padding: 0.45rem 1.75rem 0.45rem 0.65rem;
  background: var(--bg-primary);
  border: 1px solid var(--border-light);
  border-radius: 3px;
  font-family: inherit;
  font-size: 0.85rem;
  color: var(--text-primary);
  cursor: pointer;
  text-align: left;
  position: relative;
  transition: all 0.15s ease;
}
.dropdown-toggle:hover {
  border-color: var(--border-gray);
  background: var(--bg-secondary);
}
.dropdown-toggle::after {
  content: "";
  position: absolute;
  right: 0.65rem;
  top: 50%;
  transform: translateY(-50%);
  width: 0;
  height: 0;
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 5px solid var(--accent-red);
  transition: transform 0.2s;
}
.dropdown-toggle.active::after {
  transform: translateY(-50%) rotate(180deg);
}

.dropdown-menu {
  position: absolute;
  top: calc(100% + 0.25rem);
  left: 0;
  right: 0;
  background: var(--bg-primary);
  border: 1px solid var(--border-light);
  border-radius: 3px;
  box-shadow: 0 2px 8px var(--shadow-light);
  z-index: 1000;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: all 0.2s ease;
}
.dropdown-menu.show {
  max-height: 300px;
  opacity: 1;
}

.dropdown-item {
  padding: 0.45rem 0.65rem;
  cursor: pointer;
  font-size: 0.85rem;
  color: var(--text-primary);
  transition: background 0.15s;
  border: none;
  background: none;
  width: 100%;
  text-align: left;
  font-family: inherit;
}
.dropdown-item:hover {
  background: var(--bg-tertiary);
}
.dropdown-item.active {
  background: var(--bg-secondary);
  color: var(--accent-red);
  font-weight: 600;
}
.dropdown-item:first-child {
  border-radius: 3px 3px 0 0;
}
.dropdown-item:last-child {
  border-radius: 0 0 3px 3px;
}

/* Upcoming Events Checkbox */
.upcoming-checkbox-container {
  position: relative;
  min-width: 130px;
}
.upcoming-checkbox-container label.filter-label {
  display: block;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-muted);
  margin-bottom: 0.25rem;
  font-weight: 600;
}

.upcoming-checkbox-wrapper {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 0.65rem;
  background: var(--bg-primary);
  border: 1px solid var(--border-light);
  border-radius: 3px;
  cursor: pointer;
  transition: all 0.15s ease;
  user-select: none;
}
.upcoming-checkbox-wrapper:hover {
  border-color: var(--border-gray);
  background: var(--bg-secondary);
}

.upcoming-checkbox-label {
  cursor: pointer;
  color: var(--text-primary);
  font-size: 0.85rem;
  flex: 1;
}

.upcoming-checkbox {
  cursor: pointer;
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  margin: 0;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  border: 2px solid var(--border-gray);
  background-color: var(--bg-primary);
  border-radius: 3px;
  position: relative;
  transition: all 0.15s ease;
}
.upcoming-checkbox:checked {
  background-color: var(--accent-red);
  border-color: var(--accent-red);
}
.upcoming-checkbox:checked::after {
  content: "✓";
  position: absolute;
  color: white;
  font-size: 12px;
  font-weight: bold;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

/* Dark mode checkbox */
:root[data-theme=dark] .upcoming-checkbox {
  border-color: var(--border-medium);
  background-color: var(--bg-secondary);
}
:root[data-theme=dark] .upcoming-checkbox:checked {
  background-color: #ff6666;
  border-color: #ff6666;
}

/* Map Element */
#map {
  height: 600px;
  width: 100%;
  background: var(--bg-secondary);
  transition: filter 0.3s ease;
}

/* Automatic theme switching for map tiles */
:root[data-theme=dark] #map {
  filter: invert(0.9) hue-rotate(180deg) brightness(0.95);
}

/* Prevent markers and popups from being inverted in dark mode */
:root[data-theme=dark] .leaflet-marker-icon,
:root[data-theme=dark] .leaflet-popup-content-wrapper,
:root[data-theme=dark] .leaflet-popup-tip,
:root[data-theme=dark] .custom-marker {
  filter: invert(1) hue-rotate(180deg);
}

/* Leaflet Popup Styling */
.leaflet-popup-content-wrapper {
  background: var(--bg-card) !important;
  color: var(--text-primary) !important;
  border-radius: 4px;
  box-shadow: 0 3px 14px var(--shadow-medium) !important;
}

.leaflet-popup-tip {
  background: var(--bg-card) !important;
}

.leaflet-popup-close-button {
  color: var(--text-primary) !important;
}
.leaflet-popup-close-button:hover {
  color: var(--accent-red) !important;
}

.marker-popup {
  max-width: 280px;
  padding: 0.5rem;
}

.popup-title {
  font-weight: 600;
  font-size: 1rem;
  margin-bottom: 0.4rem;
  color: var(--text-primary);
  line-height: 1.3;
}

.popup-venue {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--accent-gray);
  margin-bottom: 0.2rem;
}

.popup-date {
  font-size: 0.7rem;
  color: var(--text-muted);
  margin-bottom: 0.4rem;
  font-style: italic;
}

.popup-meta {
  font-size: 0.7rem;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
  text-transform: capitalize;
}

.popup-excerpt {
  font-size: 0.8rem;
  line-height: 1.5;
  margin-bottom: 0.75rem;
  color: var(--text-secondary);
}

.popup-link {
  color: var(--accent-blue);
  text-decoration: none;
  font-size: 0.8rem;
  font-weight: 500;
  background: none;
  padding: 0;
  border: none;
}
.popup-link:hover {
  color: var(--accent-blue-dark);
  text-decoration: none;
}

/* Map Gallery */
.map-gallery {
  margin-top: 4rem;
}

.section-title {
  font-size: 1.25rem;
  color: var(--accent-gray);
  margin-bottom: 1.5rem;
  font-weight: 600;
}

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

.gallery-item {
  border: 1px solid var(--border-medium);
  border-radius: 4px;
  overflow: hidden;
  background: var(--bg-card);
  transition: all 0.2s ease;
}
.gallery-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px var(--shadow-medium);
}
.gallery-item img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  display: block;
}

.gallery-info {
  padding: 1rem;
}

.gallery-title {
  font-weight: 600;
  font-size: 0.95rem;
  margin-bottom: 0.5rem;
  color: var(--text-primary);
}

.gallery-description {
  font-size: 0.8rem;
  line-height: 1.5;
  color: var(--text-secondary);
  margin-bottom: 0.5rem;
}

.gallery-source {
  font-size: 0.7rem;
  color: var(--text-muted);
  font-style: italic;
}

.gallery-link {
  color: var(--accent-blue);
  text-decoration: none;
  font-size: 0.8rem;
  margin-top: 0.5rem;
  display: inline-block;
}
.gallery-link:hover {
  color: var(--accent-blue-dark);
}

/* Minimize Leaflet attribution */
.leaflet-control-attribution {
  font-size: 0.6rem !important;
  opacity: 0.6;
  padding: 2px 5px !important;
  background: rgba(255, 255, 255, 0.7) !important;
}
.leaflet-control-attribution:hover {
  opacity: 1;
}

:root[data-theme=dark] .leaflet-control-attribution {
  background: rgba(0, 0, 0, 0.5) !important;
  color: #ccc !important;
}
:root[data-theme=dark] .leaflet-control-attribution a {
  color: #8bbfef !important;
}

/* ============================================ */
/* Gallery Filters                            */
/* ============================================ */
/* Gallery Filter Section */
.gallery-filters {
  display: flex;
  gap: 1rem;
  margin-bottom: 1.5rem;
  align-items: flex-end;
}
.gallery-filters .filter-dropdown {
  flex: 1;
  min-width: 150px;
}

/* Gallery Results Counter */
.gallery-results {
  color: var(--text-secondary);
  font-size: 0.85rem;
  margin-bottom: 1rem;
  font-style: italic;
}

/* Gallery Item Hidden State */
.gallery-item.hidden {
  display: none;
}

/* Disabled/unavailable filter options */
.dropdown-item.disabled {
  opacity: 0.4;
  cursor: not-allowed;
  pointer-events: none;
  color: var(--text-muted);
}

.dropdown-item.disabled:hover {
  background: transparent;
}

/* Mobile: Inline labels for gallery filters ONLY */
@media screen and (max-width: 45rem) {
  .gallery-filters {
    flex-direction: column;
    gap: 0.5rem;
  }
  .gallery-filters .filter-dropdown {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    width: 100%;
  }
  .gallery-filters .filter-dropdown label {
    flex-shrink: 0;
    width: 75px;
    margin-bottom: 0;
    text-align: right;
    font-size: 0.75rem;
  }
  .gallery-filters .filter-dropdown .dropdown-toggle {
    flex: 1;
  }
}
/* ============================================ */
/* Responsive Styles & Media Queries            */
/* ============================================ */
@media screen and (max-width: 45rem) {
  /* Layout Adjustments */
  header li {
    display: inline;
    margin-right: 1rem;
    font-size: 110%;
  }
  header ul {
    border-bottom: 1px solid var(--border-light);
    padding-bottom: 2rem;
  }
  footer {
    margin-bottom: 1rem;
    padding-left: 0.5rem;
    padding-right: 0.5rem;
    left: 0;
    transform: none;
    width: 100%;
  }
  /* Mobile Navigation Toggle */
  .nav-toggle {
    display: block !important;
    position: fixed;
    top: 1rem;
    right: 1rem;
  }
  /* Mobile Navigation Menu */
  nav ul {
    display: none !important;
    position: fixed;
    top: 0;
    right: 0;
    width: 250px;
    height: 100vh;
    background: var(--bg-primary);
    box-shadow: -2px 0 10px var(--shadow-nav);
    padding: 4rem 2rem 2rem;
    border-right: none !important;
    border-left: 1px solid var(--border-light) !important;
    border-bottom: none !important;
    z-index: 999;
    list-style: none;
  }
  nav ul.nav-open {
    display: block !important;
    animation: slideIn 250ms ease;
  }
  nav ul li {
    display: block !important;
    text-align: left !important;
    margin-right: 0 !important;
    margin-bottom: 0.25rem !important;
    padding: 0.25rem 0 !important;
    font-size: 1.1rem !important;
  }
  nav ul br {
    display: none;
  }
  @keyframes slideIn {
    from {
      transform: translateX(100%);
      opacity: 0;
    }
    to {
      transform: translateX(0);
      opacity: 1;
    }
  }
  /* Mobile Submenu Styles */
  .submenu-toggle {
    justify-content: space-between;
    padding: 0.25rem 0 !important;
    margin-bottom: 0 !important;
  }
  .submenu-toggle .submenu-arrow {
    order: 1;
    margin-left: auto;
    padding-left: 1rem;
    font-size: 1.1em;
  }
  .submenu-toggle .submenu-title {
    order: 0;
  }
  .submenu {
    display: block !important;
    position: static !important;
    width: auto !important;
    height: auto !important;
    background: transparent !important;
    box-shadow: none !important;
    padding: 0 0 0 1rem !important;
    border: none !important;
  }
  .submenu.submenu-open {
    max-height: 500px !important;
  }
  .submenu li {
    text-align: left !important;
    margin-right: 0 !important;
    padding: 0.25rem 0 !important;
    padding-left: 1rem !important;
    font-size: 1rem !important;
    margin-bottom: 0.25rem !important;
  }
  .submenu li a {
    font-size: 1em !important;
  }
  /* Mobile Content Typography */
  main,
  .digest-post-content {
    font-size: 1rem;
    line-height: 1.65;
  }
  /* Mobile Project Cards - Keep side layout, just smaller */
  .project-card.side-image-layout .card-image-area {
    width: 80px;
    padding: 0.5rem;
    padding-left: 0.5rem;
  }
  .project-card.side-image-layout .card-img-side {
    width: 70px;
    height: 70px;
    object-fit: cover;
    border-radius: 4px;
  }
  /* Mobile Map Adjustments */
  #map {
    height: 400px;
  }
  .map-controls {
    gap: 0.75rem;
    align-items: center;
  }
  .filter-dropdown,
  .upcoming-checkbox-container {
    min-width: 120px;
    flex: 1 1 auto;
  }
  .gallery-grid {
    grid-template-columns: 1fr;
  }
}
/* Mobile Image Comparison Slider */
@media screen and (max-width: 45rem) {
  .image-comparison {
    margin: 1.5em 0;
    width: 100%;
    max-width: 100%;
    touch-action: none; /* Prevent scrolling while dragging */
  }
  .slider-button {
    width: 50px;
    height: 50px;
  }
  .slider-button::before {
    left: 10px;
    width: 12px;
    height: 12px;
    border-width: 2.5px;
  }
  .slider-button::after {
    right: 10px;
    width: 12px;
    height: 12px;
    border-width: 2.5px;
  }
}
/* Tooltip from https://www.w3schools.com/css/css_tooltip.asp */
.jekyll-glossary {
  position: relative;
  display: inline-block;
  border-bottom: 2px dotted var(--accent-blue);
  cursor: help;
}

.jekyll-glossary .jekyll-glossary-tooltip {
  visibility: hidden;
  width: 120px;
  background-color: var(--bg-tertiary);
  color: var(--text-primary);
  text-align: center;
  font-size: 0.8em;
  padding: 5px;
  border-radius: 6px;
  border: 1px solid var(--border-medium);
  /* Position the tooltip text - see examples below! */
  position: absolute;
  z-index: 1;
  width: 160px;
  bottom: 100%;
  left: 50%;
  margin-left: -80px; /* Use half of the width to center the tooltip */
}

/* Show the tooltip text when you mouse over the tooltip container */
.jekyll-glossary:hover .jekyll-glossary-tooltip {
  visibility: visible;
}

/* Style the source link (if there is one provided in the glossary entry). */
.jekyll-glossary-source-link:before {
  content: "[source]";
}

/* Arrow created with borders. */
.jekyll-glossary .jekyll-glossary-tooltip::after {
  content: " ";
  position: absolute;
  top: 100%;
  left: 50%;
  margin-left: -5px;
  border-width: 5px;
  border-style: solid;
  border-color: var(--bg-tertiary) transparent transparent transparent;
}

/* Animation from invisible to visible on hover. */
.jekyll-glossary .jekyll-glossary-tooltip {
  opacity: 0;
  transition: opacity 0.5s;
}

.jekyll-glossary:hover .jekyll-glossary-tooltip {
  opacity: 1;
}

/* HACK: hide surrounding parenthesis on definition. When Jekyll renders
 * post.excerpt, all HTML and CSS is stripped. The effect is that the extra
 * parenthesis that are added are hidden in the normal blog post with hoover, but
 * hidden in the post.except when html and css is stripped. Ref:
 * https://github.com/erikw/jekyll-glossary_tooltip/issues/7#issuecomment-2711471867 */
.jekyll-glossary-tooltip-hidden {
  display: none;
}

/* Print Stylesheet for Academic Articles */
@media print {
  * {
    background: white !important;
    color: black !important;
    box-shadow: none !important;
    text-shadow: none !important;
  }
  header,
  footer,
  nav,
  .skip-link {
    display: none !important;
  }
  main {
    max-width: 100%;
    margin: 0;
    padding: 0;
  }
  a {
    text-decoration: underline;
  }
  a[href^=http]:after {
    content: " (" attr(href) ")";
    font-size: 0.8em;
  }
  figure,
  blockquote,
  pre {
    page-break-inside: avoid;
  }
  h1,
  h2,
  h3,
  h4,
  h5,
  h6 {
    page-break-after: avoid;
  }
  img {
    max-width: 100%;
    page-break-inside: avoid;
  }
  .toc-wrapper {
    border: 1px solid #000;
    background: transparent !important;
  }
}
.toc-wrapper {
  background-color: var(--bg-secondary);
  padding: 1rem 1.5rem;
  border-left: 3px solid var(--accent-red);
  margin: 2rem 0;
  border-radius: 8px;
  font-size: clamp(0.875rem, 0.9vw + 0.5rem, 0.95rem);
  line-height: 1.6;
  box-shadow: 0 1px 2px var(--shadow-light);
  transition: background-color 250ms ease;
}
.toc-wrapper h3,
.toc-wrapper h2 {
  margin-top: 0;
  margin-bottom: 0.5rem;
  font-size: clamp(0.95rem, 1vw + 0.5rem, 1rem);
  font-weight: 600;
  color: var(--text-primary);
}
.toc-wrapper ul {
  list-style: none;
  padding-left: 1rem;
  margin: 0;
}
.toc-wrapper li {
  margin: 0.3rem 0;
  position: relative;
}
.toc-wrapper li::before {
  content: "▸";
  position: absolute;
  left: -0.8rem;
  color: var(--accent-red);
  opacity: 0;
  transition: opacity 150ms ease;
}
.toc-wrapper li:hover::before {
  opacity: 1;
}
.toc-wrapper a {
  color: var(--accent-blue);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color 200ms ease, color 200ms ease, padding-left 200ms ease;
  display: inline-block;
}
.toc-wrapper a:hover, .toc-wrapper a:focus {
  color: var(--accent-blue-dark);
  border-bottom-color: var(--accent-blue-dark);
  padding-left: 0.25rem;
  outline: none;
}
.toc-wrapper a:focus-visible {
  outline: 2px solid var(--accent-blue);
  outline-offset: 2px;
}

.toc-wrapper ul ul {
  margin-left: 1rem;
  margin-top: 0.25rem;
  border-left: 1px solid var(--border-medium);
  padding-left: 0.8rem;
}
.toc-wrapper ul ul a {
  font-size: 0.9em;
  color: var(--text-secondary);
}
.toc-wrapper ul ul a:hover, .toc-wrapper ul ul a:focus {
  color: var(--accent-blue-dark);
}

.toc-wrapper ul ul ul {
  font-size: 0.85em;
  border-left-color: var(--border-gray);
}

@media screen and (max-width: 768px) {
  .toc-wrapper {
    padding: 0.75rem 1rem;
    font-size: 0.875rem;
  }
  .toc-wrapper ul {
    padding-left: 0.75rem;
  }
  .toc-wrapper ul ul {
    margin-left: 0.5rem;
    padding-left: 0.5rem;
  }
}
@media print {
  .toc-wrapper {
    background-color: transparent;
    border: 1px solid #000;
    box-shadow: none;
    page-break-inside: avoid;
  }
  .toc-wrapper a {
    color: #000;
    border-bottom: none;
  }
  .toc-wrapper a::after {
    content: " (page " target-counter(attr(href), page) ")";
    font-size: 0.8em;
  }
}

/*# sourceMappingURL=main.css.map */