:root {
  --apple-green: #bcc56a;
  --orange: #f68200;
  --stone-blue: #487787;
  --sky-blue: #69c9e1;
  --light-blue: #a5fdff;

  --bg: var(--light-blue);
  --ink: var(--stone-blue);
  --accent: var(--stone-blue);
  --warm: var(--orange);
  --panel: #ffd39c;
  --line: #9ec6d1;
  --font-body: "Sansita", sans-serif;
  --font-display: "Sansita", sans-serif;
}

* {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

img,
video,
canvas,
svg {
  max-width: 100%;
  height: auto;
}

html {
  background: #2a81cb;
  height: 100%;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 105%;
  color: var(--ink);
  background: transparent;
  min-height: 100vh;
  min-height: 100svh;
  position: relative;
  overflow-x: hidden;
  text-shadow: 0px 2px 2px rgba(255, 255, 255, 1);
  --top-banner-opacity: 0;
}

body.drawer-open {
  overflow: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background: linear-gradient(to top, #2a81cb 0%, #abd4e0 100%);
  z-index: -2;
  pointer-events: none;
}

body::after {
  content: none;
}

html.nav-loading-preboot body::after {
  content: "";
  position: fixed;
  inset: 0;
  background: linear-gradient(to top, #2a81cb 0%, #abd4e0 100%);
  z-index: 1090;
  pointer-events: auto;
}

.site-logo-link {
  position: fixed;
  top: calc(0.75rem + env(safe-area-inset-top));
  left: 1rem;
  z-index: 1200;
  width: 50px;
  height: 50px;
  border-radius: 999px;
  background: #f0f7c8;
  border: 3px solid var(--apple-green);
  display: grid;
  place-items: center;
  box-shadow: 0 10px 24px rgba(8, 13, 18, 0.2);
  transition:
    top 180ms ease,
    left 180ms ease,
    width 180ms ease,
    height 180ms ease,
    border-radius 180ms ease,
    border-color 180ms ease,
    background-color 180ms ease,
    box-shadow 180ms ease,
    transform 180ms ease;
}

.site-logo-image {
  width: 38px;
  height: 38px;
  object-fit: contain;
  border-radius: 50%;
  display: block;
  transition:
    width 180ms ease,
    height 180ms ease,
    border-radius 180ms ease;
}

@media (max-width: 1200px) {
  .hero {
    padding-left: max(1.2rem, 5%);
    padding-right: max(1.2rem, 5%);
  }

  .grid {
    padding-left: max(1rem, 5%);
    padding-right: max(1rem, 5%);
  }
}

.burger-nav {
  position: fixed;
  top: calc(0.75rem + env(safe-area-inset-top));
  right: 1rem;
  z-index: 3000;
  transition:
    top 180ms ease,
    right 180ms ease;
}

.burger-btn {
  width: 50px;
  height: 50px;
  border-radius: 999px;
  border: 3px solid var(--apple-green);
  background: #f0f7c8;
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 4px;
  padding: 0;
  position: relative;
  z-index: 3001;
  box-shadow: 0 10px 24px rgba(8, 13, 18, 0.2);
  transition:
    width 180ms ease,
    height 180ms ease,
    border-radius 180ms ease,
    border-color 180ms ease,
    background-color 180ms ease,
    box-shadow 180ms ease,
    transform 180ms ease;
}

.burger-btn[hidden] {
  display: none !important;
}

.burger-btn span {
  width: 20px;
  height: 2px;
  background: var(--stone-blue);
  border-radius: 2px;
  transition:
    transform 170ms ease,
    opacity 140ms ease;
}

.burger-btn.is-open {
  background: transparent;
}

.burger-btn.is-open span:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}

.burger-btn.is-open span:nth-child(2) {
  opacity: 0;
}

.burger-btn.is-open span:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

.top-scroll-banner {
  position: fixed;
  left: 0;
  right: 0;
  top: 0;
  height: calc(64px + env(safe-area-inset-top));
  background: #f0f7c8;
  border-bottom: 3px solid var(--apple-green);
  box-shadow: 0 8px 22px rgba(8, 13, 18, 0.14);
  opacity: var(--top-banner-opacity, 0);
  pointer-events: none;
  z-index: 1150;
  transition: opacity 180ms ease;
}

.top-scroll-banner-title {
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  transform: translateX(-50%);
  width: calc(100% - 152px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: calc(env(safe-area-inset-top) * 0.35);
  color: var(--stone-blue);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1rem, 2.4vw, 1.25rem);
  line-height: 1.1;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-shadow: none;
}

body.top-banner-active .site-logo-link {
  top: calc(0.4rem + env(safe-area-inset-top));
  left: 0.65rem;
  width: 44px;
  height: 44px;
  border-radius: 10px;
  border-color: transparent;
  background: transparent;
  box-shadow: none;
}

body.top-banner-active .site-logo-image {
  width: 34px;
  height: 34px;
  border-radius: 0;
}

body.top-banner-active .burger-nav {
  top: calc(0.4rem + env(safe-area-inset-top));
  right: 0.65rem;
}

body.top-banner-active .burger-btn {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  border-width: 0 !important;
  border-color: transparent !important;
  background: transparent;
  box-shadow: none;
}

.burger-panel {
  position: fixed;
  left: min(1rem, 3vw);
  right: min(1rem, 3vw);
  top: calc(env(safe-area-inset-top) + 4rem - 5px);
  width: auto;
  height: 500px;
  max-height: 500px;
  max-width: 860px;
  margin: 0 auto;
  background: #fffefb;
  border: 0;
  border-radius: 14px;
  box-shadow: 0 20px 36px rgba(22, 22, 22, 0.18);
  z-index: 2600;
  padding: 0.9rem;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  overscroll-behavior: contain;
  touch-action: pan-y;
  clip-path: inset(0 0 100% 0 round 0 0 14px 14px);
  opacity: 0;
  pointer-events: none;
  transition:
    opacity 190ms ease,
    clip-path 230ms cubic-bezier(0.2, 0.74, 0.2, 1);
}

.burger-panel.is-open {
  clip-path: inset(0 0 0 0 round 0 0 14px 14px);
  opacity: 1;
  pointer-events: auto;
  animation: burger-blinds-open 146ms ease-out;
}

.burger-panel-head {
  display: none;
}

.burger-backdrop {
  position: fixed;
  inset: 0;
  background: transparent;
  z-index: 2500;
  opacity: 0;
  transition: opacity 180ms ease;
}

.burger-backdrop.is-open {
  opacity: 1;
}

.action-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 14, 19, 0.45);
  z-index: 5000;
  display: grid;
  place-items: center;
  padding: 1rem;
}

.action-modal-overlay[hidden] {
  display: none;
}

.action-modal-card {
  width: min(460px, 92vw);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: 0 20px 40px rgba(15, 20, 23, 0.2);
  padding: 1rem;
}

.action-modal-card h3 {
  margin-top: 0;
}

.action-modal-actions {
  margin-top: 0.9rem;
  display: flex;
  justify-content: flex-end;
  gap: 0.6rem;
}

.toast-host {
  position: fixed;
  left: 50%;
  transform: translateX(-50%);
  bottom: 1rem;
  z-index: 2100;
  display: grid;
  gap: 0.45rem;
  justify-items: center;
}

.toast {
  background: #1d5f7a;
  color: #fff;
  border-radius: 10px;
  padding: 0.6rem 0.8rem;
  box-shadow: 0 12px 24px rgba(12, 20, 24, 0.2);
  font-weight: 600;
  text-shadow: none !important;
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 180ms ease, transform 180ms ease;
}

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

.toast.toast-hide {
  opacity: 0;
  transform: translateY(8px);
}

.burger-panel[hidden],
.burger-backdrop[hidden] {
  display: none;
}

.page-loading {
  position: fixed;
  inset: 0;
  z-index: 1100;
  display: grid;
  place-items: center;
  background: rgba(33, 61, 78, 0.58);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  pointer-events: auto;
}

.page-loading[hidden] {
  display: none;
}

.page-loading-shell {
  min-width: 116px;
  min-height: 116px;
  border-radius: 14px;
  border: 3px solid var(--sky-blue);
  background: #fffefb;
  box-shadow: 0 16px 34px rgba(7, 14, 18, 0.24);
  padding: 0.85rem;
  display: grid;
  place-items: center;
}

.loading-snail {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 6px solid #c7e9f4;
  border-top-color: var(--stone-blue);
  border-right-color: var(--stone-blue);
  animation: snail-spin 1s linear infinite;
}

body.component-loading .panel,
body.component-loading .map-card,
body.component-loading #map,
body.component-loading .profile-table-viewport,
body.component-loading .business-list,
body.component-loading .home-calendar,
body.component-loading .ticker-wrap,
body.component-loading .tag-list,
body.component-loading .sms-log {
  position: relative;
  overflow: hidden;
}

body.component-loading .panel > *,
body.component-loading .map-card > *,
body.component-loading #map > *,
body.component-loading .profile-table-viewport > *,
body.component-loading .business-list > *,
body.component-loading .home-calendar > *,
body.component-loading .ticker-wrap > *,
body.component-loading .tag-list > *,
body.component-loading .sms-log > * {
  opacity: 0;
}

body.component-loading .panel::before,
body.component-loading .map-card::before,
body.component-loading #map::before,
body.component-loading .profile-table-viewport::before,
body.component-loading .business-list::before,
body.component-loading .home-calendar::before,
body.component-loading .ticker-wrap::before,
body.component-loading .tag-list::before,
body.component-loading .sms-log::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(#dbe5ea 0 0) 1rem 1rem / 42% 14px no-repeat,
    linear-gradient(#dbe5ea 0 0) 1rem 2.15rem / 66% 14px no-repeat,
    linear-gradient(#dbe5ea 0 0) 1rem 3.3rem / 54% 14px no-repeat,
    linear-gradient(#d0dce2 0 0) 0 0 / 100% 100% no-repeat;
  pointer-events: none;
  z-index: 2;
}

body.component-loading .panel::after,
body.component-loading .map-card::after,
body.component-loading #map::after,
body.component-loading .profile-table-viewport::after,
body.component-loading .business-list::after,
body.component-loading .home-calendar::after,
body.component-loading .ticker-wrap::after,
body.component-loading .tag-list::after,
body.component-loading .sms-log::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    100deg,
    rgba(255, 255, 255, 0) 28%,
    rgba(255, 255, 255, 0.45) 50%,
    rgba(255, 255, 255, 0) 72%
  );
  background-size: 220% 100%;
  animation: skeleton-sheen 1.05s linear infinite;
  pointer-events: none;
  z-index: 3;
}

@keyframes skeleton-sheen {
  from {
    background-position: 120% 0;
  }
  to {
    background-position: -120% 0;
  }
}

@keyframes burger-blinds-open {
  0% {
    clip-path: inset(0 0 100% 0 round 0 0 14px 14px);
    opacity: 0;
  }
  22% {
    clip-path: inset(0 0 72% 0 round 0 0 14px 14px);
    opacity: 0.55;
  }
  45% {
    clip-path: inset(0 0 48% 0 round 0 0 14px 14px);
    opacity: 0.72;
  }
  68% {
    clip-path: inset(0 0 24% 0 round 0 0 14px 14px);
    opacity: 0.88;
  }
  100% {
    clip-path: inset(0 0 0 0 round 0 0 14px 14px);
    opacity: 1;
  }
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@keyframes snail-spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

.burger-menu {
  flex: 1;
  min-height: 0;
  min-width: 220px;
  padding: 0.3rem 0.3rem 0.8rem;
  display: grid;
  gap: 0.25rem;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  touch-action: pan-y;
}

.burger-menu a {
  text-decoration: none;
  color: var(--ink);
  font-weight: 600;
  padding: 0.55rem 0.65rem;
  border-radius: 8px;
  font-size: 1rem;
  line-height: 1.2;
}

.burger-menu a:hover {
  background: #f4ede0;
}

.burger-menu a.active {
  background: #efe4d1;
}

.burger-group {
  display: grid;
  gap: 0.2rem;
}

.burger-expand-row {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.burger-parent-link {
  flex: 1;
}

.burger-expand-btn {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 8px;
  min-width: 34px;
  min-height: 32px;
  font-weight: 700;
  color: #44545a;
}

.burger-submenu {
  display: grid;
  gap: 0.15rem;
  padding-left: 0.55rem;
}

.burger-submenu[hidden] {
  display: none;
}

.burger-submenu-link {
  font-size: 0.9rem;
  color: #30444b;
}

@media (max-width: 768px) {
  .burger-panel {
    left: 0;
    right: 0;
    height: 500px;
    max-height: 500px;
    max-width: none;
    border-radius: 0;
    border-left-width: 0;
    border-right-width: 0;
    padding: 0.7rem 0.7rem 0.35rem;
  }

  .burger-panel-head {
    margin-bottom: 0.5rem;
  }

  .burger-panel-head h2 {
    font-size: clamp(1.55rem, 6vw, 2rem);
  }

  .burger-menu {
    padding: 0.15rem 0.15rem 0.5rem;
    gap: 0.1rem;
  }

  .burger-menu a {
    padding: 0.42rem 0.5rem;
    font-size: clamp(1.05rem, 4.8vw, 1.3rem);
  }

  .burger-expand-btn {
    min-width: 30px;
    min-height: 28px;
    padding: 0;
  }

  .burger-submenu {
    padding-left: 0.4rem;
  }

  .burger-submenu-link {
    font-size: clamp(0.92rem, 3.9vw, 1.05rem);
  }

  .burger-panel-footer {
    margin-top: 0.2rem;
    padding: 0.35rem 0.1rem 0.25rem;
    box-shadow: none;
  }
}

@media (max-width: 1024px) and (orientation: landscape) {
  .burger-panel {
    height: auto;
    max-height: calc(100dvh - env(safe-area-inset-top) - 0.75rem);
  }
}

.burger-logout-btn {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font-weight: 700;
  padding: 0.55rem 0.65rem;
  text-align: left;
}

.burger-logout-btn:hover {
  background: #f4ede0;
}

.burger-panel-footer {
  flex: 0 0 auto;
  margin-top: 0.35rem;
  padding: 0.55rem 0.3rem 0.45rem;
  border-top: 1px solid var(--line);
  background: #f2feff;
  box-shadow: 0 -8px 16px rgba(24, 45, 59, 0.08);
}

.bg-shape {
  position: fixed;
  border-radius: 999px;
  opacity: 0.24;
  filter: blur(30px);
  z-index: -1;
}

.bg-shape.one {
  width: 280px;
  height: 280px;
  background: #a8d4c5;
  top: -80px;
  right: 10%;
}

.bg-shape.two {
  width: 340px;
  height: 340px;
  background: #f3b283;
  bottom: -120px;
  left: -80px;
}

.hero {
  padding: 2.5rem 1.2rem 1rem;
  text-align: center;
}

.hero-title-logo {
  display: block;
  width: min(705px, 70vw);
  height: auto;
  object-fit: contain;
  object-position: center;
  margin: 0 auto;
}

.eyebrow {
  text-transform: uppercase;
  font-size: 0.76rem;
  letter-spacing: 0.14em;
  color: var(--accent);
  margin: 0;
}

h1,
h2,
h3 {
  font-family: var(--font-display);
  margin: 0.3rem 0 0.6rem;
  text-shadow: 0px 2px 2px rgba(255, 255, 255, 1);
}

h1 {
  font-size: clamp(2rem, 4vw, 3.2rem);
}

.subhead {
  max-width: 62ch;
  margin: 0 auto;
}

.grid {
  width: 100%;
  margin: 0 auto 2rem;
  padding: 0 1rem;
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(12, minmax(0, 1fr));
}

.panel,
.map-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 1rem;
  box-shadow: 0 12px 30px rgba(55, 46, 32, 0.08);
  min-width: 0;
}

.map-card {
  grid-column: span 12;
}

.map-filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-bottom: 0.55rem;
  align-items: center;
}

.map-filter-bar > * {
  max-width: 100%;
  min-width: 0;
}

.map-filter-bar input,
.map-filter-bar select {
  border: 1px solid #b8c3c8;
  border-radius: 8px;
  background: #fff;
  color: #1a2d33;
  min-height: 36px;
  padding: 0.45rem 0.55rem;
}

.map-search-wrap {
  position: relative;
  flex: 1 1 320px;
  width: auto;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 0.45rem;
}

.map-search-wrap input {
  flex: 1;
  min-width: 0;
}

.map-filter-bar select {
  flex: 1 1 220px;
  min-width: 170px;
  max-width: 360px;
}

.map-search-clear-btn {
  min-height: 36px;
  min-width: 70px;
  flex: 0 0 auto;
  padding: 0.45rem 0.65rem;
  border-radius: 8px;
  white-space: nowrap;
}

.map-suggest-list {
  position: absolute;
  top: calc(100% + 0.35rem);
  left: 0;
  width: min(100%, 560px);
  max-height: 250px;
  overflow-y: auto;
  border: 3px solid var(--sky-blue);
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 10px 22px rgba(16, 24, 29, 0.18);
  z-index: 1600;
}

.map-suggest-list[hidden] {
  display: none;
}

.map-suggest-item {
  width: 100%;
  text-align: left;
  border: 0;
  border-bottom: 1px solid #d9e5eb;
  border-radius: 0;
  background: #fff;
  color: #1a2d33;
  padding: 0.55rem 0.65rem;
  font-weight: 600;
  text-shadow: none;
}

.map-suggest-item:last-child {
  border-bottom: 0;
}

.map-suggest-item:hover {
  background: #eff9ff;
}

.map-popup-actions {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.35rem;
}

.fit-map-control {
  width: auto;
  min-width: 36px;
  padding: 0 8px;
  font-size: 12px;
  font-weight: 700;
}

.marker-edit-control {
  width: auto;
  min-width: 62px;
  padding: 0 8px;
  font-size: 11px;
  font-weight: 700;
}

.marker-edit-control.active {
  background: #f68200 !important;
  color: #fff !important;
  border-color: #8a4700 !important;
  text-shadow: none !important;
}

.locate-map-control {
  width: auto;
  min-width: 38px;
  padding: 0 8px;
  font-size: 11px;
  font-weight: 700;
}

#map {
  border-radius: 10px;
  height: min(62vh, 680px);
  border: 1px solid var(--line);
  width: 100%;
  max-width: 100%;
  position: relative;
  inset: auto;
}

#map.leaflet-container {
  position: relative !important;
  top: auto !important;
  left: auto !important;
  inset: auto !important;
}

.panel {
  grid-column: span 12;
}

.ticker-panel {
  padding-top: 0.8rem;
}

.calendar-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.6rem;
  align-items: center;
}

.calendar-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
}

.calendar-surface-toggle {
  display: inline-flex;
  gap: 0.3rem;
  flex-wrap: wrap;
}

.calendar-view-toggle {
  display: inline-flex;
  gap: 0.3rem;
  flex-wrap: wrap;
}

.small-btn {
  padding: 0.35rem 0.55rem;
  border-radius: 8px;
  font-size: 0.8rem;
  border: 3px solid #2a81cb;
  background: #d9f4ff;
  color: #1b4f77;
  font-weight: 800;
}

.small-btn.active {
  background: #f68200;
  border-color: #8a4700;
  color: #fff;
  outline: none;
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.65);
}

.small-btn.active:hover {
  background: #f68200;
  border-color: #8a4700;
  color: #fff;
}

.home-calendar {
  margin-top: 0.7rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #f7fdff;
  padding: 0.6rem 0.7rem;
  display: grid;
  gap: 0.35rem;
  max-height: 460px;
  overflow-y: auto;
  position: relative;
  isolation: isolate;
}

.home-calendar.home-calendar-chalkboard {
  border: 15px solid #8a5a2b;
  background: #8a5a2b;
  padding: 0.55rem;
}

.home-calendar.home-calendar-day {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-height: 0;
}

.home-calendar.home-calendar-month {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-height: 0;
}

.chalkboard {
  border: 3px solid #6f8d62;
  border-radius: 8px;
  background: #29633e;
  box-shadow: inset 0 0 0 2px rgba(235, 247, 230, 0.13);
  padding: 0.8rem;
  color: #ecf7e7;
  text-shadow: none;
  margin: 0;
  position: relative;
}

.chalkboard-date {
  font-weight: 800;
  letter-spacing: 0.02em;
  margin-bottom: 0.55rem;
  padding-bottom: 0.45rem;
  border-bottom: 2px dashed rgba(236, 247, 231, 0.6);
}

.chalkboard-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.42rem;
}

.chalkboard-list li {
  color: #ecf7e7;
  text-shadow: none;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.chalkboard-event-btn {
  width: 100%;
  text-align: left;
  border: none;
  background: transparent;
  color: #ecf7e7;
  text-shadow: none;
  font: inherit;
  font-weight: 700;
  padding: 0;
  cursor: pointer;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.chalkboard-event-btn:hover {
  text-decoration: underline;
}

.calendar-controls.chalkboard-mode #cal-view-toggle {
  display: none !important;
}

.cal-grid {
  display: grid;
  gap: 0;
  border: 1px solid #e3d8c6;
  border-radius: 8px;
  overflow: hidden;
  background: #f7fdff;
}

.cal-grid-day {
  grid-template-columns: 70px 1fr;
}

.cal-day-layout {
  display: grid;
  grid-template-columns: 70px minmax(0, 1fr);
  border: 0;
  border-radius: 0;
  overflow: hidden;
  background: #f7fdff;
  position: relative;
  z-index: 1;
}

.cal-day-shell {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
}

.cal-day-title {
  position: relative;
  flex: 0 0 auto;
  font-weight: 700;
  color: #1d5f7a;
  background: #f7fdff;
  z-index: 30;
  padding: 0.3rem 0.15rem;
  border-bottom: 0;
}

.cal-day-scroll {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  background: #f7fdff;
}

.cal-month-shell {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
}

.cal-month-title {
  position: relative;
  flex: 0 0 auto;
  font-weight: 700;
  color: #1d5f7a;
  background: #f7fdff;
  z-index: 10;
  padding: 0.3rem 0.15rem;
  border-bottom: 0;
}

.cal-month-scroll {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  background: #f7fdff;
}

.cal-all-day-strip {
  margin-bottom: 0.45rem;
  display: grid;
  gap: 0.24rem;
}

.cal-day-hours {
  border-right: 1px solid #eadfcd;
  background: #f7fdff;
}

.cal-day-hours .cal-time {
  box-sizing: border-box;
  display: flex;
  align-items: flex-start;
  padding: 0.35rem;
  border-top: 1px solid #eadfcd;
  border-right: 0;
  background: #f7fdff;
}

.cal-day-hours .cal-time:first-child {
  border-top: 0;
}

.cal-day-track {
  position: relative;
  background: #f7fdff;
  overflow: hidden;
}

.cal-day-line {
  position: absolute;
  left: 0;
  right: 0;
  border-top: 1px solid #eadfcd;
}

.cal-day-line:first-child {
  border-top: 0;
}

.cal-grid-week,
.cal-grid-month {
  grid-template-columns: repeat(7, minmax(0, 1fr));
}

.cal-grid-year {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.6rem;
  border: none;
}

.cal-head {
  background: #f4ecde;
  font-weight: 700;
  font-size: 0.82rem;
  text-align: center;
  padding: 0.35rem 0.2rem;
  border-right: 1px solid #e3d8c6;
}

.cal-time {
  font-size: 0.8rem;
  color: #5c6f76;
  padding: 0.35rem;
  border-top: 1px solid #eadfcd;
  border-right: 1px solid #eadfcd;
  background: #f7fdff;
}

.cal-cell {
  min-height: 78px;
  padding: 0.28rem;
  border-top: 1px solid #eadfcd;
  border-right: 1px solid #eadfcd;
  overflow: hidden;
  background: #f7fdff;
}

.cal-grid-day .cal-cell {
  background: #f7fdff;
}

.cal-grid-day .cal-time {
  background: #f7fdff;
  min-height: calc(60px * 1.2);
}

.cal-day-event {
  display: block;
  position: absolute;
  left: 0.35rem;
  width: calc(100% - 0.7rem);
  margin-bottom: 0;
  padding: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  vertical-align: top;
}

.cal-day-event .event-sticky-text {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  display: block;
  margin: 0;
  padding: 0.14rem 0.34rem 0 0.34rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  will-change: top;
}

.cal-clickable {
  cursor: pointer;
}

.cal-clickable:hover {
  background: #f9f3e8;
}

.cal-date {
  font-size: 0.78rem;
  font-weight: 700;
  margin-bottom: 0.2rem;
}

.cal-event-count {
  margin-top: 0.28rem;
  font-size: 0.78rem;
  font-weight: 800;
  color: #1d5f7a;
  display: inline-block;
  border: 3px solid #bcc56a;
  background: #dff0bf;
  border-radius: 999px;
  padding: 0.12rem 0.45rem;
}

.cal-event-count-number {
  display: inline;
}

.cal-event-count-label {
  display: inline;
  margin-left: 0.2rem;
}

.cal-event-chip {
  font-size: 0.82rem;
  line-height: 1.3;
  padding: 0.2rem 0.35rem;
  margin-bottom: 0.22rem;
  border-radius: 7px;
  background: #d8ecf3;
  border: 1px solid #8fbfd0;
  color: #0d3c4d;
  font-weight: 600;
  box-sizing: border-box;
  width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.chalkboard-event-btn.is-canceled .event-main-text,
.cal-event-chip.is-canceled .event-main-text {
  text-decoration: line-through;
  text-decoration-thickness: 2px;
}

.event-canceled-label {
  color: #c02626;
  font-weight: 900;
  text-decoration: none !important;
  margin-left: 0.25rem;
  background: #fff;
  border-radius: 999px;
  padding: 0.05rem 0.38rem;
  display: inline-block;
  line-height: 1.1;
  text-shadow: none !important;
}

.event-title-canceled {
  text-decoration: line-through;
  text-decoration-thickness: 2px;
}

.event-canceled-row {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}

.cal-event-button {
  text-align: left;
  width: 100%;
  cursor: pointer;
}

.cal-more {
  font-size: 0.72rem;
  color: #5b6d73;
}

.cal-muted {
  opacity: 0.45;
  background: #f8f5ef;
}

.cal-mini {
  border: 1px solid #e3d8c6;
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
}

.cal-mini-title {
  padding: 0.35rem 0.45rem;
  font-weight: 700;
  background: #f4ecde;
}

.cal-mini-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
}

.cal-mini-head {
  font-size: 0.66rem;
  text-align: center;
  padding: 0.2rem 0;
  border-right: 1px solid #eadfcd;
  border-top: 1px solid #eadfcd;
  background: #faf5ea;
}

.cal-mini-cell {
  position: relative;
  font-size: 0.68rem;
  min-height: 26px;
  text-align: right;
  padding: 0.15rem 0.25rem;
  border-right: 1px solid #eadfcd;
  border-top: 1px solid #eadfcd;
}

.cal-dot {
  position: absolute;
  left: 2px;
  bottom: 2px;
  min-width: 12px;
  height: 12px;
  border-radius: 999px;
  background: #1d5f7a;
  color: #fff;
  font-size: 0.58rem;
  display: grid;
  place-items: center;
}

.calendar-title {
  font-weight: 700;
  color: #1d5f7a;
  position: sticky;
  top: 0;
  background: #f7fdff;
  z-index: 30;
  padding: 0.3rem 0.15rem;
  border-bottom: 1px solid #e9decc;
}

.calendar-title-today {
  background: #eaf4f8;
  color: #0f4d63;
}

.cal-today-cell {
  background: #eef7fb;
  box-shadow: inset 0 0 0 2px #4f9eb9;
}

.calendar-subtitle {
  margin-top: 0.3rem;
  font-weight: 700;
}

.calendar-item {
  border-top: 1px dashed #e8dfd2;
  padding-top: 0.3rem;
  font-size: 0.9rem;
}

.calendar-empty {
  color: #566a71;
  font-size: 0.9rem;
}

.event-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(8, 13, 18, 0.45);
  z-index: 2300;
  display: grid;
  place-items: center;
  padding: 1rem;
}

.event-modal-overlay[hidden] {
  display: none;
}

.event-modal-card {
  width: min(520px, 94vw);
  background: #fffefb;
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: 0 18px 36px rgba(8, 14, 18, 0.24);
  padding: 1rem;
}

.event-modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.event-modal-head h3 {
  margin: 0;
}

.ticker-wrap {
  overflow-x: hidden;
  overflow-y: hidden;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  -webkit-overflow-scrolling: touch;
  scroll-behavior: smooth;
  scrollbar-width: none;
  -ms-overflow-style: none;
  touch-action: pan-y;
}

.ticker-wrap::-webkit-scrollbar {
  width: 0;
  height: 0;
}

.ticker-track {
  display: flex;
  gap: 0.65rem;
  width: max-content;
  white-space: nowrap;
  will-change: transform;
  transform: translate3d(0, 0, 0);
  padding: 0.6rem 0.7rem;
}

.ticker-wrap:hover .ticker-track,
.ticker-wrap:focus-within .ticker-track,
.ticker-track.ticker-paused {
  /* JS loop handles pause state */
}

.ticker-wrap:focus-visible {
  outline: 2px solid var(--stone-blue);
  outline-offset: 2px;
}

.ticker-track.ticker-static {
  width: 100%;
}

.ticker-item {
  display: inline-flex;
  align-items: center;
  gap: 0.38rem;
  position: relative;
  padding-left: 1rem;
  padding-right: 0.1rem;
  font-size: 0.9rem;
}

.ticker-item::before {
  content: "\00b7";
  color: #64818d;
  font-weight: 900;
  position: absolute;
  left: 0.18rem;
  top: 50%;
  transform: translateY(-58%);
  width: 0.72rem;
  height: 1em;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-size: 1.45em;
  line-height: 0.9;
  text-shadow: none;
  pointer-events: none;
}

.ticker-item-btn {
  border: none;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font: inherit;
}

.ticker-item-btn:hover {
  color: #11475d;
}

.ticker-open {
  color: #1d7a46;
  font-weight: 700;
}

.ticker-closed {
  color: #8b2f2f;
  font-weight: 700;
}

.business-list {
  display: grid;
  gap: 0.9rem;
}

.business-pagination {
  margin-top: 0.85rem;
}

.business-pagination-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.business-pagination-nav {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}

.business-page-status {
  font-weight: 700;
  font-size: 0.9rem;
}

.business-page-size-wrap {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-weight: 700;
}

.business-page-size-wrap select {
  min-width: 92px;
  border: 1px solid #a9b4b9;
  border-radius: 9px;
  background: #fff;
  color: #14242b;
  padding: 0.4rem 0.5rem;
}

.business-page-size-wrap select:focus {
  outline: 2px solid #1d5f7a;
  outline-offset: 1px;
}

@media (orientation: portrait) and (max-width: 900px) {
  .cal-event-count-label {
    display: none;
  }

  .cal-event-count {
    min-width: 1.8rem;
    text-align: center;
    padding: 0.12rem 0.4rem;
  }
}

.business-tabs {
  display: block;
  margin: 0;
  min-width: 0;
  flex: 1 1 220px;
}

.business-tags-select-wrap {
  display: flex;
  align-items: center;
  margin: 0;
  width: 100%;
}

.business-tags-select-wrap select {
  width: 100%;
  border: 1px solid #a9b4b9;
  border-radius: 9px;
  background: #fff;
  color: #14242b;
  padding: 0.5rem 0.6rem;
}

.business-tags-select-wrap select:focus {
  outline: 2px solid #1d5f7a;
  outline-offset: 1px;
}

.business-filter-bar {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex-wrap: wrap;
  margin: 0.15rem 0 0.7rem;
}

.business-filter-bar > input {
  width: min(700px, 100%);
  flex: 1 1 320px;
  border: 1px solid #a9b4b9;
  border-radius: 9px;
  background: #fff;
  color: #14242b;
  padding: 0.5rem 0.6rem;
}

.business-filter-bar > input:focus {
  outline: 2px solid #1d5f7a;
  outline-offset: 1px;
}

.business-filter-bar > input,
.business-filter-bar #business-tag-select,
.business-filter-bar .map-search-clear-btn {
  min-height: 44px;
}

.business-filter-bar .business-tabs {
  display: flex;
  align-items: center;
}

.tab-chip {
  text-decoration: none;
  border: 1px solid #d8c9ad;
  border-radius: 999px;
  padding: 0.28rem 0.62rem;
  background: #fff;
  color: #31474f;
  font-weight: 600;
  font-size: 0.88rem;
  display: inline-flex;
  max-width: 100%;
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.tab-chip:hover {
  background: #f7efe0;
}

.tab-chip.active {
  background: #1d5f7a;
  color: #fff;
  border-color: #1d5f7a;
}

.profile-link-list {
  display: grid;
  gap: 0.55rem;
}

.profile-table-tools {
  display: flex;
  justify-content: flex-start;
  align-items: center;
  gap: 0.55rem;
  flex-wrap: wrap;
}

.profile-search {
  width: min(700px, 100%);
  flex: 1 1 320px;
  background: #fff;
  border: 1px solid #a9b4b9;
  color: #14242b;
}

.profile-search:focus {
  outline: 2px solid #1d5f7a;
  outline-offset: 1px;
}

.profile-tags-select-wrap {
  display: flex;
  align-items: center;
  min-width: 0;
  margin: 0;
  flex: 1 1 240px;
}

.profile-tags-select-wrap select {
  width: 100%;
  border: 1px solid #a9b4b9;
  border-radius: 9px;
  background: #fff;
  color: #14242b;
  padding: 0.5rem 0.6rem;
}

.profile-tags-select-wrap select:focus {
  outline: 2px solid #1d5f7a;
  outline-offset: 1px;
}

.profile-table-tools > input,
.profile-table-tools #profile-tag-select,
.profile-table-tools .profile-search-clear-btn {
  min-height: 44px;
}

.profile-search-clear-btn {
  min-width: 70px;
  flex: 0 0 auto;
}

.profile-table-viewport {
  border: 1px solid #b7c3c8;
  border-radius: 10px;
  background: #fbfdfd;
  height: 580px;
  overflow: auto;
}

.profile-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 520px;
}

.profile-table th,
.profile-table td {
  border-bottom: 1px solid #d3dde2;
  padding: 0.55rem 0.65rem;
  text-align: left;
  vertical-align: middle;
  font-size: 0.9rem;
  color: #17272e;
}

.profile-table thead th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: #dce9ee;
  color: #102f3d;
}

.profile-table tbody tr:nth-child(even) {
  background: #f3f8fa;
}

.profile-table tbody tr:hover {
  background: #e8f2f6;
}

.profile-data-row {
  cursor: pointer;
}

.profile-data-row[aria-expanded="true"] {
  background: #e2f0f6 !important;
}

.profile-tooltip-row td {
  padding: 0.45rem 0.55rem 0.7rem;
  background: #eef7fb;
}

.profile-row-tooltip-card {
  border: 1px solid #9fc4d2;
  border-radius: 10px;
  background: #ffffff;
  padding: 0.6rem 0.65rem;
  display: grid;
  gap: 0.6rem;
}

.profile-row-tooltip-section {
  display: grid;
  gap: 0.28rem;
}

.profile-row-tooltip-section h4 {
  margin: 0;
  font-size: 0.92rem;
  color: #1e5568;
}

.profile-row-tooltip-section > div {
  overflow-wrap: anywhere;
}

.profile-tooltip-empty {
  opacity: 0.8;
}

.table-sort-btn {
  border: 1px solid #7e99a5;
  background: #f7fbfd;
  color: #113948;
  border-radius: 8px;
  padding: 0.25rem 0.42rem;
  font-size: 0.82rem;
  font-weight: 700;
}

.table-sort-btn:hover {
  background: #e8f2f6;
}

.actions-col {
  width: 120px;
  white-space: nowrap;
}

.icon-btn {
  border: 1px solid #8799a1;
  background: #f8fbfc;
  color: #153745;
  border-radius: 8px;
  width: 32px;
  height: 32px;
  margin-right: 0.32rem;
  font-size: 0.95rem;
  line-height: 1;
  padding: 0;
  display: inline-grid;
  place-items: center;
}

.danger-icon {
  color: #8f1f1f;
  border-color: #b58585;
  background: #fff6f6;
}

.icon-btn:hover {
  background: #e8f2f6;
}

.danger-icon:hover {
  background: #feecec;
}

.profile-empty {
  color: #566a71;
}

.edit-section-card {
  border: 3px solid var(--sky-blue);
  border-radius: 12px;
  background: #f7fdff;
  padding: 0.7rem 0.8rem;
  margin-top: 0.7rem;
}

.edit-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.edit-section-head h3 {
  margin: 0;
}

.edit-section-summary {
  margin-top: 0.45rem;
  color: #2f5561;
  font-size: 0.92rem;
  min-width: 0;
}

.edit-section-summary > div,
.edit-section-summary > p,
.edit-section-summary > span {
  min-width: 0;
  max-width: 100%;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.summary-event-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.55rem;
  border-top: 1px dashed #9fc5d2;
  padding-top: 0.35rem;
  margin-top: 0.35rem;
}

.summary-event-main {
  min-width: 0;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.summary-event-actions {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  flex: 0 0 auto;
}

.summary-event-actions .icon-btn {
  width: 30px;
  height: 30px;
  margin-right: 0;
}

.edit-drawer-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(8, 13, 18, 0.45);
  z-index: 2700;
}

.edit-drawer-backdrop[hidden] {
  display: none;
}

.edit-drawer {
  position: fixed;
  inset: 0 0 0 auto;
  width: min(720px, 100vw);
  height: 100svh;
  background: #f7fdff;
  border-left: 3px solid var(--sky-blue);
  box-shadow: -18px 0 36px rgba(12, 20, 24, 0.24);
  z-index: 2800;
  padding: calc(0.9rem + env(safe-area-inset-top)) 0.9rem calc(0.9rem + env(safe-area-inset-bottom));
  overflow: hidden;
  display: flex;
  flex-direction: column;
  min-height: 100svh;
}

@supports (height: 100dvh) {
  body {
    min-height: 100dvh;
  }

  .edit-drawer {
    height: 100dvh;
    max-height: 100dvh;
    min-height: 100dvh;
  }
}

.edit-drawer[hidden] {
  display: none;
}

.edit-drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: nowrap;
  gap: 0.6rem;
  margin-bottom: 0.7rem;
  position: sticky;
  top: 0;
  z-index: 6;
  background: #f7fdff;
  padding-bottom: 0.35rem;
  border-bottom: 3px solid var(--sky-blue);
}

.edit-drawer-head h2 {
  margin: 0;
  min-width: 0;
  flex: 1;
}

.edit-drawer-head-actions {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.4rem;
  flex: 0 0 auto;
  margin-left: auto;
  white-space: nowrap;
}

.edit-drawer-body[hidden] {
  display: none;
}

.edit-drawer-body {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding-bottom: calc(0.8rem + env(safe-area-inset-bottom));
  -webkit-overflow-scrolling: touch;
}

.edit-drawer #edit-event-editor-list {
  max-height: 38vh;
  overflow: auto;
  padding-right: 0.25rem;
}

.drawer-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  margin-bottom: 0.55rem;
  padding-bottom: 0.35rem;
  border-bottom: 3px solid var(--sky-blue);
}

.drawer-panel-head h3 {
  margin: 0;
}

.drawer-panel-actions {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.4rem;
}

.drawer-icon-btn {
  width: 36px;
  height: 36px;
  font-size: 1rem;
  line-height: 1;
}

.drawer-save-btn {
  color: var(--stone-blue) !important;
}

.add-icon-btn {
  position: relative;
}

.icon-plus {
  position: relative;
  width: 14px;
  height: 14px;
  display: inline-block;
}

.icon-plus::before,
.icon-plus::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  background: currentColor;
  border-radius: 2px;
  transform: translate(-50%, -50%);
}

.icon-plus::before {
  width: 12px;
  height: 2.5px;
}

.icon-plus::after {
  width: 2.5px;
  height: 12px;
}

.profile-link-list a {
  display: block;
  text-decoration: none;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.7rem 0.9rem;
  background: #fff;
  color: var(--ink);
  font-weight: 600;
}

.profile-link-list a:hover {
  background: #f4ede0;
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 0.45rem 0 0.7rem;
}

.tag-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  border: 1px solid #d8c9ad;
  border-radius: 999px;
  padding: 0.22rem 0.55rem;
  background: #f7efe0;
  font-size: 0.84rem;
  font-weight: 600;
}

.tag-remove-btn {
  border: 1px solid #d9c5a3;
  border-radius: 999px;
  background: #fffaf0;
  color: #7f342a;
  font-size: 0.74rem;
  line-height: 1;
  padding: 0.16rem 0.42rem;
  cursor: pointer;
}

.tag-remove-btn:hover {
  background: #f3e0c9;
}

.tag-form {
  display: grid;
  gap: 0.5rem;
}

.event-time-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.5rem;
}

.event-time-row label {
  margin: 0;
}

.hours-editor-grid {
  display: grid;
  gap: 0.6rem;
  max-width: 100%;
  min-width: 0;
}

.hours-day-section {
  border: 1px solid #c6d3d8;
  border-radius: 10px;
  background: #fff;
  max-width: 100%;
  min-width: 0;
}

.hours-day-head {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding: 0.45rem 0.55rem;
  border-bottom: 1px solid #e2eaed;
  background: #f7fbfc;
}

.hours-day-label {
  min-width: 34px;
  color: #173c49;
}

.hours-editor-wrap {
  max-width: 100%;
  min-width: 0;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
}

.hours-editor-table {
  width: 100%;
  min-width: 620px;
  border-collapse: collapse;
}

.hours-editor-table th,
.hours-editor-table td {
  border-bottom: 1px solid #e2eaed;
  padding: 0.34rem 0.4rem;
  text-align: left;
  vertical-align: middle;
}

.hours-editor-table th {
  background: #edf4f6;
  color: #153744;
  font-size: 0.82rem;
}

.hours-editor-table td input[type="text"] {
  width: 100%;
}

.hours-time-wrap {
  display: flex;
  gap: 0.3rem;
  align-items: center;
}

.hours-time-wrap input[type="text"] {
  min-width: 86px;
}

.hours-time-wrap select {
  min-width: 84px;
}

.hours-editor-table td select[data-hours-description] {
  min-width: 130px;
}

.hours-closed {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.85rem;
}

.hours-editor-help {
  margin: 0;
  padding: 0.45rem 0.55rem;
  font-size: 0.8rem;
  color: #3d545c;
  border: 1px solid #e2eaed;
  border-radius: 8px;
  background: #fafdfd;
}

.address-suggest-list {
  border: 1px solid #b7c3c8;
  border-radius: 10px;
  background: #fff;
  margin-top: 0.35rem;
  max-height: 220px;
  overflow: auto;
  box-shadow: 0 8px 20px rgba(18, 29, 35, 0.14);
}

.address-suggest-item {
  display: block;
  width: 100%;
  border: 0;
  border-bottom: 1px solid #e2e9ec;
  background: #fff;
  text-align: left;
  padding: 0.48rem 0.6rem;
}

.address-suggest-item:last-child {
  border-bottom: 0;
}

.address-suggest-item:hover {
  background: #eef5f8;
}

.address-line-1 {
  display: block;
  font-weight: 700;
  color: #153744;
  font-size: 0.88rem;
}

.address-line-2 {
  display: block;
  margin-top: 0.12rem;
  color: #405961;
  font-size: 0.82rem;
}

.tag-picker {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  max-width: 100%;
  min-width: 0;
}

.tag-option {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  border: 1px solid #d9ccb3;
  border-radius: 999px;
  padding: 0.25rem 0.55rem;
  background: #fff;
  font-size: 0.86rem;
  max-width: 100%;
  min-width: 0;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.business {
  position: relative;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.7rem 0.9rem;
  background: #fff;
  max-width: 100%;
  min-width: 0;
  overflow: hidden;
}

.business h3,
.business p,
.business .hours,
.business .events,
.business .event-row,
.business .hours-row {
  overflow-wrap: anywhere;
  word-break: break-word;
}

.business h3 {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
  padding-right: 2.3rem;
}

.business-edit-link {
  position: absolute;
  top: 0.45rem;
  right: 0.5rem;
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border: 1px solid #b8c6cc;
  border-radius: 8px;
  text-decoration: none;
  color: #1a4759;
  background: #f7fbfc;
}

.business-edit-link:hover {
  background: #e8f2f6;
}

.badge {
  display: inline-block;
  font-size: 0.74rem;
  padding: 0.12rem 0.5rem;
  border-radius: 999px;
  background: #eaf4f8;
  color: var(--accent);
  margin-left: 0.5rem;
}

.numbers {
  margin-top: 0.5rem;
  font-size: 0.88rem;
  color: #3b4d53;
}

.inline-link {
  color: #0f5c77;
  text-decoration: underline;
  text-underline-offset: 2px;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.hours,
.events {
  margin-top: 0.5rem;
  font-size: 0.94rem;
}

.hours-day-block {
  margin-top: 0.35rem;
}

.hours-day-title {
  font-weight: 700;
  color: #25454f;
}

.hours-sub-row {
  padding-left: 0.9rem;
  font-size: 0.9rem;
}

.sms-log {
  display: grid;
  gap: 0.7rem;
}

.sms-log-viewport {
  max-height: 380px;
  overflow-y: auto;
  padding-right: 0.35rem;
}

.sms-row {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.65rem 0.8rem;
  background: #fff;
}

.sms-meta {
  display: flex;
  justify-content: space-between;
  gap: 0.8rem;
  font-size: 0.82rem;
  color: #54666c;
}

.sms-body {
  margin-top: 0.35rem;
  font-size: 0.92rem;
}

.hours-row,
.event-row {
  display: flex;
  justify-content: space-between;
  gap: 0.8rem;
  border-top: 1px dashed #e8dfd2;
  padding-top: 0.35rem;
  margin-top: 0.35rem;
}

.form-panel form {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0.55rem;
  min-width: 0;
}

.form-panel form > * {
  min-width: 0;
}

label {
  font-size: 0.88rem;
  display: grid;
  gap: 0.25rem;
  min-width: 0;
}

input,
select,
textarea,
button {
  font: inherit;
}

input,
select,
textarea {
  border: 1px solid #cfbfa7;
  border-radius: 8px;
  padding: 0.55rem 0.65rem;
  background: #fffdf8;
  max-width: 100%;
}

.form-panel form > label > input:not([type="checkbox"]):not([type="radio"]),
.form-panel form > label > textarea,
.form-panel form > label > select {
  width: 100%;
}

button {
  border: none;
  border-radius: 10px;
  padding: 0.65rem 0.8rem;
  background: var(--accent);
  color: #fff;
  font-weight: 600;
  cursor: pointer;
}

button:hover {
  filter: brightness(1.06);
}

.actions {
  display: flex;
  gap: 0.6rem;
  align-items: center;
}

.edit-delete-actions {
  justify-content: flex-end;
  margin-top: 1rem;
  padding-top: 0.75rem;
  border-top: 3px dashed var(--sky-blue);
}

button.danger {
  background: var(--orange);
}

.cancel-btn {
  background: #fff;
  color: var(--ink);
  border: 1px solid #c8ba9f;
}

.button-link {
  display: inline-block;
  text-decoration: none;
  border-radius: 10px;
  padding: 0.65rem 0.8rem;
  background: var(--accent);
  color: #fff;
  font-weight: 600;
}

.settings-create-link {
  text-shadow: none !important;
  margin: 0.2rem 0;
}

.window-wide {
  grid-column: 1 / -1;
  width: 100%;
  margin-left: 0;
  border-radius: 16px;
  border-left: 1px solid var(--line);
  border-right: 1px solid var(--line);
  padding: 1rem;
}

.guide {
  white-space: pre-wrap;
  display: block;
  background: #f7efe0;
  border: 1px solid #e3d3b8;
  padding: 0.65rem;
  border-radius: 8px;
  font-size: 0.84rem;
}

.edit-profile-grid > .form-panel {
  grid-column: 1 / -1;
}

.edit-profile-grid > .panel {
  grid-column: 1 / -1;
}

.edit-profile-grid {
  grid-template-columns: repeat(12, minmax(0, 1fr));
  width: 100%;
}

.settings-grid > .panel {
  grid-column: 1 / -1;
}

.home-anchor {
  scroll-margin-top: 84px;
}

@media (max-width: 800px) {
  .cal-grid-year {
    grid-template-columns: 1fr;
  }

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

  .actions {
    flex-wrap: wrap;
  }

  .business-pagination-inner {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.45rem;
    align-items: stretch;
  }

  .business-pagination-nav {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    align-items: center;
    gap: 0.4rem;
  }

  .business-pagination-nav [data-business-page-prev] {
    justify-self: start;
  }

  .business-pagination-nav [data-business-page-next] {
    justify-self: end;
  }

  .business-page-status {
    text-align: center;
  }

  .business-page-size-wrap {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: center;
    gap: 0.4rem;
  }

  .business-page-size-wrap > span {
    justify-self: start;
  }

  .business-page-size-wrap select {
    width: 100%;
    max-width: none;
    justify-self: stretch;
  }
}

.login-panel {
  max-width: 560px;
  width: 100%;
  margin: 0 auto;
}

.login-status {
  min-height: 1.2em;
  margin: 0.25rem 0 0;
}

@media (min-width: 900px) {
  .map-card {
    grid-column: 1 / -1;
  }

  #home-open-now-section {
    grid-column: 1 / -1;
  }

  .grid > .panel:nth-of-type(1) {
    grid-column: span 5;
  }
  .form-panel {
    grid-column: span 6;
  }

  .grid > .panel:last-child {
    grid-column: span 12;
  }

  .edit-profile-grid > .form-panel,
  .edit-profile-grid > .panel,
  .edit-profile-grid > .panel:nth-of-type(1),
  .edit-profile-grid > .panel:last-child {
    grid-column: 1 / -1;
  }

  .settings-grid > .panel,
  .settings-grid > .panel:nth-of-type(1),
  .settings-grid > .panel:last-child {
    grid-column: 1 / -1;
  }
}

/* Palette refresh: friendly colorful vibe */
.burger-btn,
.burger-close,
.burger-expand-btn {
  background: #f7ffe8;
  border-color: var(--apple-green);
}

.burger-btn span {
  background: var(--stone-blue);
}

.burger-panel {
  background: #f2feff;
  border-color: transparent;
}

.burger-menu a:hover,
.burger-menu a.active {
  background: #e7f9ff;
  color: var(--stone-blue);
}

.panel,
.map-card,
.business,
.event-modal-card,
.action-modal-card {
  background: var(--panel);
  border-color: var(--sky-blue);
}

.event-modal-card {
  background: #fff !important;
}

.action-modal-card {
  background: #fff !important;
}

.business {
  background: #f0f7d6;
  border-color: var(--apple-green);
}

#business-feed {
  background: #e6f0b8;
  border-color: var(--apple-green);
}

.hero .eyebrow,
.calendar-title,
.hours-day-title,
.inline-link {
  color: var(--stone-blue);
}

.tag-chip,
.tag-option,
.badge {
  background: #f0f7c8;
  border-color: var(--apple-green);
  color: #2b4d57;
}

.badge {
  background: #d9f4ff;
  border-color: var(--sky-blue);
  color: #2b5f70;
}

.tag-remove-btn {
  background: #fff4e4;
  border-color: #f2b56e;
  color: #8d4f00;
}

.home-calendar,
.profile-table-viewport,
.hours-day-section,
.sms-row,
.address-suggest-list,
.ticker-wrap {
  border-color: var(--sky-blue);
  background: #f7fdff;
}

.cal-head,
.cal-mini-title,
.hours-day-head,
.profile-table thead th {
  background: #d9f4ff;
  color: #245766;
}

.cal-event-chip {
  background: #d8f7de;
  border-color: var(--apple-green);
  color: #28514d;
}

.cal-today-cell {
  background: #fff4dd;
  box-shadow: inset 0 0 0 2px var(--orange);
}

input,
select,
textarea {
  border-color: #a7d4e0;
  background: #ffffff;
}

input:focus,
select:focus,
textarea:focus {
  outline: 2px solid var(--sky-blue);
  outline-offset: 1px;
}

button,
.button-link {
  background: var(--stone-blue);
  color: #fff;
}

button.danger,
.danger {
  background: var(--orange);
}

.cancel-btn {
  background: #f7ffe8;
  border-color: var(--apple-green);
  color: #27414a;
}

.table-sort-btn:hover,
.icon-btn:hover,
.business-edit-link:hover,
.address-suggest-item:hover {
  background: #e7f9ff;
}

.tab-chip {
  background: #d9f4ff;
  border-color: var(--sky-blue);
  color: #2b5f70;
}

.tab-chip:hover {
  background: #c7eeff;
}

.tab-chip.active {
  background: var(--stone-blue);
  border-color: var(--stone-blue);
  color: #fff;
  text-shadow: none;
}

.tab-chip.active * {
  color: #fff;
  text-shadow: none;
}

.ticker-open {
  color: #2e7d32;
}

.ticker-track.ticker-static .ticker-item {
  color: #2f5561;
}

/* Global border thickness boost (+2px from prior 1px baseline) */
body :where(
    .panel,
    .map-card,
    .business,
    .ticker-wrap,
    .home-calendar,
    .cal-grid,
    .cal-head,
    .cal-time,
    .cal-cell,
    .cal-mini,
    .cal-mini-head,
    .cal-mini-cell,
    .event-modal-card,
    .action-modal-card,
    .sms-row,
    .hours-day-section,
    .hours-day-head,
    .hours-editor-help,
    .address-suggest-list,
    .address-suggest-item,
    .tag-chip,
    .tag-option,
    .tag-remove-btn,
    .profile-table-viewport,
    .profile-table th,
    .profile-table td,
    .table-sort-btn,
    .icon-btn,
    .business-edit-link,
    .burger-btn,
    .burger-close,
    .burger-expand-btn,
    .burger-panel,
    .button-link,
    #map,
    .cancel-btn,
    .tab-chip,
    button,
    input,
    select,
    textarea
  ) {
  border-width: 3px !important;
}

.hours-row,
.event-row,
.calendar-item {
  border-top-width: 3px;
}

/* Spacing polish: component-level only (no text/icon/button overrides) */
:root {
  --space-2: 0.6rem;
  --space-3: 0.85rem;
  --space-4: 1.1rem;
  --space-5: 1.4rem;
  --space-6: 1.8rem;
}

.hero {
  padding-top: var(--space-6);
  padding-bottom: var(--space-4);
}

.grid {
  gap: var(--space-4);
  margin-bottom: var(--space-6);
}

.panel,
.map-card {
  padding: var(--space-4);
}

.business {
  padding: var(--space-4);
}

.home-calendar {
  padding: var(--space-3);
}

.event-modal-card,
.action-modal-card {
  padding: var(--space-4);
}

.edit-section-card {
  padding: var(--space-3) var(--space-4);
}

.edit-section-card + .edit-section-card {
  margin-top: var(--space-3);
}

.edit-drawer {
  padding: var(--space-4);
}

.edit-drawer-head {
  margin-bottom: var(--space-3);
}

.edit-drawer-body {
  padding-bottom: var(--space-4);
}

.drawer-panel-head {
  margin-bottom: var(--space-3);
}

.profile-table-tools {
  margin-bottom: var(--space-2);
}

.map-popup-actions {
  gap: var(--space-2);
  margin-top: var(--space-2);
}

@media (max-width: 800px) {
  .hero {
    padding-top: var(--space-5);
  }

  .grid {
    gap: var(--space-3);
  }

  .panel,
  .map-card,
  .business,
  .event-modal-card,
  .action-modal-card {
    padding: var(--space-3);
    max-width: 100%;
    min-width: 0;
  }

  .cal-cell {
    min-width: 0;
    padding: 0.2rem;
  }

  .cal-event-chip {
    font-size: 0.74rem;
    padding: 0.16rem 0.28rem;
  }

  .hero-title-logo {
    width: min(705px, 100%);
  }

  .map-filter-bar {
    gap: 0.4rem;
  }

  .map-search-wrap {
    width: 100%;
    min-width: 0;
    display: block;
  }

  .map-search-wrap input {
    width: 100%;
    min-width: 0;
  }

  .map-search-clear-btn {
    min-width: 62px;
    max-width: 100%;
    padding-left: 0.45rem;
    padding-right: 0.45rem;
  }

  .map-filter-bar select {
    width: auto;
    flex: 1 1 200px;
    min-width: 0;
  }

  .calendar-controls {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 0.4rem;
    align-items: stretch;
  }

  .calendar-controls.chalkboard-mode {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .calendar-controls > * {
    max-width: 100%;
  }

  .calendar-head {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.45rem;
    align-items: stretch;
  }

  .calendar-surface-toggle {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.4rem;
  }

  .calendar-view-toggle {
    display: contents;
  }

  .calendar-surface-toggle .small-btn,
  .calendar-controls .small-btn {
    width: 100%;
    display: inline-flex;
    justify-content: center;
    align-items: center;
  }

  .window-wide {
    width: 100%;
    margin-left: 0;
    border-radius: 16px;
    border-left: 1px solid var(--line);
    border-right: 1px solid var(--line);
  }

  .hours-editor-wrap {
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
  }

  .hours-editor-table {
    min-width: 540px;
  }

  .form-panel form,
  .form-panel form > label,
  .form-panel form > label > * {
    max-width: 100%;
    min-width: 0;
  }
}

@media (max-width: 800px) and (orientation: portrait) {
  .settings-create-link {
    display: inline-flex;
    width: 100%;
    max-width: 100%;
    justify-content: center;
    align-items: center;
    text-align: center;
    white-space: normal;
    word-break: break-word;
    line-height: 1.2;
    padding: 0.65rem 0.75rem;
  }

  .create-profile-page .grid {
    padding-left: 0.65rem;
    padding-right: 0.65rem;
  }

  .create-profile-page .window-wide {
    padding: 0.75rem;
  }

  .create-profile-page .form-panel form {
    gap: 0.5rem;
  }

  .create-profile-page .tag-picker {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.4rem;
  }

  .create-profile-page .tag-option {
    width: 100%;
    margin: 0;
  }

  .create-profile-page .hours-day-head {
    gap: 0.35rem;
    padding: 0.35rem 0.45rem;
  }

  .create-profile-page .hours-editor-wrap {
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
  }

  .create-profile-page .hours-editor-table {
    min-width: 500px;
  }

  .create-profile-page .hours-editor-table th,
  .create-profile-page .hours-editor-table td {
    padding: 0.28rem 0.3rem;
  }

  .create-profile-page .hours-time-wrap {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 0.25rem;
    align-items: center;
  }

  .create-profile-page .hours-time-wrap input[type="text"] {
    min-width: 74px;
  }

  .create-profile-page .hours-time-wrap select {
    min-width: 62px;
  }

  .create-profile-page .actions {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.5rem;
  }

  .create-profile-page .actions button {
    width: 100%;
  }
}
