:root {
  --ink: #1a2421;
  --paper: #f3efe6;
  --paper-deep: #e7e0d2;
  --moss: #1f5c4d;
  --moss-deep: #143d34;
  --amber: #c45c26;
  --line: rgba(26, 36, 33, 0.12);
  --white: #fffdf8;
  --shadow: 0 18px 40px rgba(20, 40, 34, 0.12);
  --radius: 14px;
  --font-display: "Fraunces", Georgia, serif;
  --font-body: "Source Sans 3", "Segoe UI", sans-serif;
  --font-ui: Helvetica, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background:
    radial-gradient(1200px 500px at 10% -10%, rgba(31, 92, 77, 0.18), transparent 60%),
    radial-gradient(900px 400px at 90% 0%, rgba(196, 92, 38, 0.12), transparent 55%),
    linear-gradient(180deg, #f7f3ea 0%, var(--paper) 40%, #ebe4d6 100%);
  min-height: 100vh;
}

a { color: var(--moss-deep); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--amber); }

.wrap { width: min(1100px, calc(100% - 2rem)); margin-inline: auto; }
.wrap-full { width: calc(100% - 2rem); max-width: none; margin-inline: auto; }

/* Community home: left menu · main · fixed sponsors column */
.body-community-home { min-height: 100vh; }
.site-header-compact .header-inner { gap: 1rem; }
.brand-block {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: inherit;
  min-width: 0;
}
.brand-logo {
  width: 75px;
  height: 75px;
  object-fit: contain;
  flex: 0 0 75px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.35);
}
.brand-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.15rem;
  min-width: 0;
}
.frontpage-logo-preview {
  display: block;
  width: 75px;
  height: 75px;
  object-fit: contain;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: #fff;
}
.frontpage-large-logo-preview {
  display: block;
  width: min(100%, 500px);
  height: auto;
  max-height: 500px;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: #fff;
}
.profile-bio-block {
  margin-top: 0.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--line);
}
.profile-name-photo-row {
  display: grid;
  grid-template-columns: minmax(0, 50%) minmax(0, 1fr);
  gap: 1rem 1.25rem;
  align-items: start;
}
.profile-left-fields {
  display: grid;
  gap: 0.9rem;
  min-width: 0;
}
.profile-left-fields > label {
  width: 100%;
  max-width: none;
}
.profile-left-fields > label input {
  width: 100%;
  box-sizing: border-box;
}
.profile-photo-side {
  display: grid;
  justify-items: center;
  align-content: start;
  gap: 0.45rem;
  text-align: center;
  min-width: 0;
  width: 100%;
}
.profile-photo-file-label {
  width: 100%;
  max-width: 12.5rem;
  font-size: 0.85rem;
}
.profile-photo-file-label input[type="file"] {
  width: 100%;
  font-size: 0.78rem;
}
.profile-photo-remove {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  margin: 0;
  font-weight: 400;
}
.profile-photo-preview,
.public-profile-photo {
  display: block;
  width: 100px;
  height: 100px;
  object-fit: cover;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: #fff;
}
.profile-name-photo-row .profile-photo-preview {
  width: min(12.5rem, 100%);
  height: auto;
  aspect-ratio: 1;
}
.profile-photo-preview--placeholder {
  background: rgba(26, 36, 33, 0.06);
}
.public-profile-photo {
  width: 120px;
  height: 120px;
}
.public-profile-photo--placeholder {
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-size: 2.4rem;
  font-weight: 700;
  color: rgba(26, 36, 33, 0.45);
  background: rgba(26, 36, 33, 0.06);
}
.public-profile-header {
  display: flex;
  align-items: center;
  gap: 1rem;
}
.public-profile-name {
  margin: 0;
  font-size: 1.45rem;
}
.public-profile-bio {
  margin-top: 1.1rem;
  line-height: 1.55;
  white-space: pre-wrap;
}
.author-byline-link {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 0.12em;
}
.author-byline-link:hover {
  color: var(--ink);
}
.site-header-compact .brand {
  font-size: clamp(2.25rem, 3.5vw, 2.65rem);
  line-height: 1.05;
}
.brand-tagline {
  display: block;
  margin-left: 0.55rem;
  font-family: var(--font-ui);
  font-size: 0.88rem;
  font-weight: 600;
  line-height: 1.25;
  color: rgba(26, 36, 33, 0.65);
  max-width: 64ch;
}
.header-pending-banner {
  flex: 1 1 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.45rem 0.75rem;
  min-width: 0;
  max-width: min(36rem, 100%);
  margin: 0 0.5rem;
  padding: 0.55rem 0.75rem;
  border-radius: 10px;
  border: 1px solid rgba(196, 92, 38, 0.28);
  background: #f8ebe1;
  color: #6a3214;
  box-shadow: 0 6px 16px rgba(26, 36, 33, 0.06);
  transition: opacity 0.35s ease, transform 0.35s ease;
}
.site-header-compact .header-inner:has(.header-pending-banner) .header-community-block {
  margin-left: 0;
}
.header-pending-banner.is-hiding {
  opacity: 0;
  transform: translateY(-0.35rem);
  pointer-events: none;
}
.header-pending-banner-text {
  margin: 0;
  font-family: var(--font-ui);
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.3;
  text-align: center;
}
.header-pending-banner-links {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.55rem;
  justify-content: center;
}
.header-pending-banner-link {
  font-family: var(--font-ui);
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--moss-deep);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.header-pending-banner-link:hover {
  color: var(--amber);
}
.header-pending-banner-dismiss {
  appearance: none;
  border: 1px solid rgba(106, 50, 20, 0.28);
  background: rgba(255, 253, 248, 0.85);
  color: #6a3214;
  font-family: var(--font-ui);
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1;
  padding: 0.35rem 0.55rem;
  border-radius: 8px;
  cursor: pointer;
}
.header-pending-banner-dismiss:hover {
  background: #fff;
  border-color: rgba(106, 50, 20, 0.45);
}
/* Admin-only login KPIs between site brand and LocalFocus logo */
.header-admin-scoreboard {
  display: flex;
  flex: 1 1 auto;
  align-items: stretch;
  justify-content: center;
  gap: 0.45rem;
  min-width: 0;
  max-width: min(28rem, 100%);
  margin: 0 0.35rem;
  padding: 0.2rem 0;
  text-decoration: none;
  color: inherit;
}
.header-score {
  flex: 1 1 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.05rem;
  min-width: 3.4rem;
  padding: 0.35rem 0.55rem;
  border: 1px solid rgba(26, 36, 33, 0.1);
  border-radius: 10px;
  background: rgba(255, 253, 248, 0.72);
  font-family: var(--font-ui);
  line-height: 1.1;
  text-decoration: none;
  color: inherit;
}
a.header-score:hover {
  border-color: rgba(31, 92, 77, 0.35);
  background: rgba(255, 253, 248, 0.95);
}
a.header-score:hover .header-score-value {
  color: var(--moss-deep);
}
.header-score-value {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -0.02em;
}
.header-score-label {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: rgba(26, 36, 33, 0.58);
  white-space: nowrap;
}
.site-header-compact .header-inner:has(.header-admin-scoreboard) .header-community-block {
  margin-left: 0;
}
.site-header-compact .header-inner:has(.header-pending-banner) .header-admin-scoreboard {
  max-width: min(18rem, 42vw);
  flex: 0 1 auto;
}
body.is-mobile .site-header-compact .header-admin-scoreboard {
  display: none !important;
}
.header-community-block {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  text-align: right;
  gap: 0.15rem;
  margin-left: auto;
}
.header-community {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.55rem;
  letter-spacing: -0.01em;
  color: var(--ink);
  line-height: 1.15;
  text-decoration: none;
}
.header-community:hover {
  color: var(--moss-deep);
}
.brand-with-logo,
a.header-community:has(.header-app-logo) {
  line-height: 0;
  display: inline-flex;
  align-items: center;
}
.header-app-logo {
  display: block;
  height: 32px;
  width: auto;
  max-width: min(200px, 48vw);
  object-fit: contain;
}
.site-header-compact .header-app-logo {
  /* Fits within existing compact header (community logo is 75px). */
  height: 40px;
  max-width: min(220px, 46vw);
}
.public-story-brand .header-app-logo {
  height: 30px;
  max-width: min(190px, 46vw);
}
.header-local-time {
  display: block;
  font-family: var(--font-ui);
  font-size: 1.1rem;
  font-weight: 600;
  color: rgba(26, 36, 33, 0.65);
  white-space: nowrap;
}

/* Phone login: site name + small site logo; no LocalFocus logo, tagline, or clock */
.brand-name-text {
  display: none;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.35rem;
  letter-spacing: -0.02em;
  line-height: 1.15;
  color: var(--moss-deep);
}
body.is-mobile .site-header-compact .brand-tagline,
body.is-mobile .site-header-compact .header-community-block {
  display: none !important;
}
body.is-mobile .site-header-compact .header-inner {
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
}
body.is-mobile .site-header-compact .header-pending-banner {
  flex: 1 1 100%;
  order: 3;
  max-width: none;
  margin: 0.15rem 0 0;
}
body.is-mobile .site-header-compact .brand-block {
  flex: 1 1 auto;
  width: 100%;
  max-width: 100%;
  gap: 0.4rem;
  align-items: center;
  --mobile-brand-size: 2.5rem;
}
body.is-mobile .site-header-compact .brand-text {
  flex: 1 1 auto;
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
}
body.is-mobile .site-header-compact .brand {
  display: block;
  width: max-content;
  max-width: none;
  font-size: var(--mobile-brand-size);
  line-height: 1.1;
  white-space: nowrap;
}
body.is-mobile .site-header-compact .brand-logo {
  display: block;
  height: var(--mobile-brand-size);
  width: auto;
  max-width: none;
  flex: 0 0 auto;
  border-radius: 3px;
  background: transparent;
  object-fit: contain;
}
body.is-mobile .header-app-logo {
  display: none !important;
}
body.is-mobile .brand-name-text {
  display: inline;
}
body.is-mobile .brand.brand-with-logo {
  font-size: inherit;
  line-height: 1.15;
}

/* Phone login: replace full side menu with Front Page + sections dropdown */
.home-menu-mobile {
  display: none;
}
body.is-mobile .home-menu-desktop {
  display: none !important;
}
body.is-mobile .home-menu-mobile {
  display: block;
  width: 100%;
  margin: 0;
}
body.is-mobile .home-menu {
  position: sticky;
  top: 3.35rem; /* sit just under the compact sticky site header */
  z-index: 18;
  align-self: auto;
  height: auto;
  max-height: none;
  overflow: visible;
  border-bottom: 1px solid var(--line);
  border-right: 0;
  padding: 0.55rem 0.75rem;
  background: rgba(255, 253, 248, 0.97);
  backdrop-filter: blur(10px);
}
body.has-site-color.is-mobile .home-menu {
  background: color-mix(in srgb, var(--community-site-color) 94%, transparent);
}
body.is-mobile .home-menu-inner {
  position: static;
  max-height: none;
  overflow: visible;
}
body.is-mobile .home-main-header {
  position: static;
  top: auto;
}
body.is-mobile {
  overflow-x: clip;
}
.mobile-section-nav {
  display: block;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  font-family: var(--font-ui);
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.3;
  color: var(--ink);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0.65rem 2.25rem 0.65rem 0.85rem;
  appearance: none;
  -webkit-appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, var(--ink) 50%),
    linear-gradient(135deg, var(--ink) 50%, transparent 50%);
  background-position:
    calc(100% - 1.1rem) calc(50% - 0.15rem),
    calc(100% - 0.75rem) calc(50% - 0.15rem);
  background-size: 0.35rem 0.35rem, 0.35rem 0.35rem;
  background-repeat: no-repeat;
}

.home-main-bleed { padding: 0; }
.home-shell {
  display: grid;
  grid-template-columns: 15% minmax(0, 1fr) 280px;
  gap: 0;
  min-height: calc(100vh - 4rem);
  width: 100%;
  align-items: stretch;
}
.home-shell.home-shell-no-ads {
  grid-template-columns: 15% minmax(0, 1fr);
}
.body-community-home:has(.story-view) .home-shell {
  height: calc(100vh - 4.25rem);
  min-height: 0;
  overflow: hidden;
}
.body-community-home:has(.story-view) .home-ads {
  overflow-y: auto;
}
.home-col { min-width: 0; }
/*
 * Side menu is its own sticky scrollport (not sticky-inner inside a stretched
 * grid column). That keeps wheel/trackpad up+down on the menu independent of
 * document scroll / scroll-latching on the main column.
 */
.home-menu {
  position: sticky;
  top: 4.25rem;
  align-self: start;
  height: calc(100vh - 4.25rem);
  height: calc(100dvh - 4.25rem);
  max-height: calc(100vh - 4.25rem);
  max-height: calc(100dvh - 4.25rem);
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  touch-action: pan-y;
  background: rgba(255, 253, 248, 0.92);
  border-right: 1px solid var(--line);
  padding: 1.25rem 0.85rem 2rem;
  font-family: var(--font-ui);
  box-sizing: border-box;
}
body.has-site-color .home-menu {
  background: color-mix(in srgb, var(--community-site-color) 92%, transparent);
}
.home-menu-inner {
  position: static;
  max-height: none;
  overflow: visible;
}
/* Story view locks .home-shell height/overflow; stretch+scroll the menu column like ads. */
.body-community-home:has(.story-view) .home-menu {
  position: relative;
  top: auto;
  align-self: stretch;
  height: auto;
  max-height: none;
  min-height: 0;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
}
.home-menu-title-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0 0 0.35rem;
  min-width: 0;
}
.home-menu-kicker {
  font-family: var(--font-ui);
  font-size: 1.05rem;
  font-weight: 700;
  margin: 0;
  line-height: 1.2;
  min-width: 0;
  flex: 1 1 auto;
}
.menu-calendar-link {
  flex: 0 0 auto;
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.85rem;
  height: 1.85rem;
  color: var(--moss-deep);
  text-decoration: none;
  border-radius: 7px;
}
.menu-calendar-link:hover,
.menu-calendar-link.is-active {
  color: var(--amber);
  background: rgba(196, 92, 38, 0.12);
}
.menu-calendar-icon {
  display: block;
}
.side-nav { display: flex; flex-direction: column; gap: 0.15rem; }
.side-nav-group {
  margin: 0.35rem 0 0;
  border: 0;
}
.side-nav-group + .side-nav-group {
  margin-top: 0.15rem;
}
.side-nav-summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin: 0.65rem 0 0.25rem;
  padding: 0.35rem 0.45rem;
  border-radius: 8px;
  font-size: 0.88rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--amber);
  user-select: none;
}
.side-nav-summary::-webkit-details-marker { display: none; }
.side-nav-summary::after {
  content: '';
  width: 0.45rem;
  height: 0.45rem;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  transition: transform 0.15s ease;
  opacity: 0.85;
  flex-shrink: 0;
}
.side-nav-group[open] > .side-nav-summary::after {
  transform: rotate(-135deg);
  margin-top: 0.2rem;
}
.side-nav-summary:hover {
  background: rgba(196, 92, 38, 0.1);
  color: #9a4318;
}
.side-nav-group-body {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  padding: 0 0 0.15rem;
}
/* display:flex above overrides the UA [hidden] rule — Front Page nest collapse */
.side-nav-front-page-block:not([data-open]) > .side-nav-group-body,
.side-nav-front-page-block .side-nav-group-body[hidden] {
  display: none !important;
}
.side-nav-label {
  margin: 1rem 0 0.35rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(26, 36, 33, 0.55);
}
.side-nav-sublabel {
  margin: 0.55rem 0 0.2rem;
  padding-left: 0.55rem;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: rgba(26, 36, 33, 0.45);
}
.side-nav-link {
  display: block;
  padding: 0.4rem 0.55rem;
  border-radius: 8px;
  text-decoration: none;
  color: var(--ink);
  font-weight: 600;
  font-size: 0.92rem;
}
.side-nav-front-page-block {
  margin: 0;
}
.side-nav-front-page-heading {
  display: flex;
  align-items: center;
  gap: 0.15rem;
  border-radius: 8px;
}
.side-nav-front-page-heading .side-nav-link {
  flex: 1 1 auto;
  min-width: 0;
}
.side-nav-front-page-toggle {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.85rem;
  height: 1.85rem;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
}
.side-nav-front-page-toggle:hover,
.side-nav-front-page-toggle:focus-visible {
  background: rgba(31, 92, 77, 0.12);
  color: var(--moss-deep);
  outline: none;
}
.side-nav-front-page-chevron {
  display: block;
  width: 0.45rem;
  height: 0.45rem;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  transition: transform 0.15s ease;
  opacity: 0.75;
}
.side-nav-front-page-block[data-open] .side-nav-front-page-chevron {
  transform: rotate(-135deg);
  margin-top: 0.15rem;
}
.side-nav-link.side-nav-front-page {
  font-size: 1.08rem;
  font-weight: 700;
}
.side-nav-link.side-nav-nested {
  padding-left: 1.15rem;
  font-size: 0.88rem;
  font-weight: 600;
}
.side-nav-link:hover,
.side-nav-link.is-active {
  background: rgba(31, 92, 77, 0.12);
  color: var(--moss-deep);
}
.side-nav-logout { margin-top: 1.25rem; }

.story-view-title-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.65rem 1rem;
  margin: 0 0 0.35rem;
}
.story-view-title-row .story-view-title {
  margin: 0;
  flex: 1 1 12rem;
  min-width: 0;
}
.story-review-ask-ai {
  flex: 0 0 auto;
  margin-top: 0.2rem;
}
.story-view--ask-ai .article-body-with-ai {
  margin-top: 0.35rem;
}
.story-review-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 0.65rem;
  margin-top: 1rem;
}
.story-review-return {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  flex: 1 1 18rem;
  min-width: 0;
}
.story-review-return input[type="text"] {
  flex: 1 1 12rem;
  min-width: 10rem;
  margin: 0;
}

.home-main {
  padding: 1.5rem 1.5rem 3rem;
  background: transparent;
}
.home-main-header {
  position: sticky;
  top: 3.75rem;
  z-index: 10;
  margin: -0.35rem -0.5rem 1rem;
  padding: 0.35rem 0.5rem 0.85rem;
  background:
    linear-gradient(180deg, rgba(247, 243, 234, 0.97) 0%, rgba(243, 239, 230, 0.94) 70%, rgba(243, 239, 230, 0.88) 100%);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.home-main-header-top {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.65rem 1rem;
}
.home-main-header-top--filters-only {
  justify-content: flex-end;
}
.home-main-header-top--filters-only .home-main-date-filters {
  margin-top: 0;
}
.home-front-page-welcome {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}
.home-greeting {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3vw, 2.6rem);
  line-height: 1.1;
  margin: 0.25rem 0 0;
}
body.is-mobile .home-greeting {
  font-size: clamp(1.2rem, 5.2vw, 1.5rem);
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}
body.is-mobile .home-main-date-filters,
body.is-mobile .article-view-toggle {
  display: none !important;
}

/* Phone front page: sponsors sit between articles; logos span full width */
.promo-feed-slot {
  margin: 0.85rem 0 1.1rem;
}
.promo-feed-slot .promo-slot {
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
}
body.is-mobile .promo-feed-slot {
  width: 100vw;
  max-width: 100vw;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
}
body.is-mobile .promo-feed-slot .promo-banner,
body.is-mobile .promo-feed-slot .promo-banner-link,
body.is-mobile .promo-feed-slot .promo-square,
body.is-mobile .promo-feed-slot .promo-square-link,
body.is-mobile .promo-feed-slot .ad-image {
  display: block;
  width: 100% !important;
  max-width: none !important;
  height: auto !important;
  aspect-ratio: auto;
  object-fit: contain;
  border-radius: 0;
  margin: 0;
}
body.is-mobile .promo-feed-slot strong {
  display: block;
  margin: 0.45rem 0.85rem 0;
  font-family: var(--font-ui);
  font-size: 0.95rem;
}
.promo-feed-slot strong {
  display: block;
  margin-top: 0.45rem;
  font-family: var(--font-ui);
  font-size: 0.95rem;
}
.home-local-weather {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 0.85rem;
  margin: 0;
  font-family: var(--font-ui);
  font-size: 0.92rem;
  line-height: 1.35;
  color: var(--moss-deep);
}
.home-weather-link {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 0.85rem;
  color: inherit;
  text-decoration: none;
}
.home-weather-link:hover,
.home-weather-link:focus-visible {
  text-decoration: underline;
  text-underline-offset: 0.15em;
}
.home-weather-now {
  font-weight: 600;
}
.home-weather-range,
.home-weather-sun {
  color: var(--ink-muted, #4a5752);
}
.home-feature-nav {
  --feature-btn-bg: #eef6f1;
  --feature-btn-bg-hover: #e2efe8;
  --feature-btn-border: #9cbcab;
  --feature-btn-text: #2f4a3f;
  display: flex;
  flex-wrap: nowrap;
  align-items: stretch;
  gap: 0.5rem;
  margin: 0.75rem 0 0;
  width: 100%;
}
/* Seasonal pastel palettes — meteorological season from community-local month */
.home-feature-nav--spring {
  --feature-btn-bg: #e8f6ea;
  --feature-btn-bg-hover: #d9eedd;
  --feature-btn-border: #9dcca8;
  --feature-btn-text: #2f5a3c;
}
.home-feature-nav--summer {
  --feature-btn-bg: #e5f3fb;
  --feature-btn-bg-hover: #d4eaf7;
  --feature-btn-border: #8ebdd8;
  --feature-btn-text: #24506a;
}
.home-feature-nav--autumn {
  --feature-btn-bg: #f8ebe0;
  --feature-btn-bg-hover: #f0dccb;
  --feature-btn-border: #d4a882;
  --feature-btn-text: #6b3f24;
}
.home-feature-nav--winter {
  --feature-btn-bg: #e9eef8;
  --feature-btn-bg-hover: #dce4f3;
  --feature-btn-border: #9aadc9;
  --feature-btn-text: #33415f;
}
.home-feature-nav-btn {
  flex: 1 1 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  padding: 0.55rem 0.65rem;
  border: 1px solid var(--feature-btn-border);
  border-radius: 8px;
  background: var(--feature-btn-bg);
  color: var(--feature-btn-text);
  font-family: var(--font-ui);
  font-size: 0.9rem;
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}
.home-feature-nav-btn:hover,
.home-feature-nav-btn:focus-visible {
  background: var(--feature-btn-bg-hover);
  color: var(--feature-btn-text);
}
@media (max-width: 640px) {
  .home-feature-nav {
    flex-wrap: wrap;
    gap: 0.4rem;
  }
  .home-feature-nav-btn {
    flex: 1 1 calc(50% - 0.2rem);
    font-size: 0.84rem;
    padding: 0.5rem 0.45rem;
    white-space: normal;
  }
}
.home-main-header-top h1 {
  flex: 1 1 12rem;
  min-width: 0;
}
.home-main-title-block {
  flex: 1 1 12rem;
  min-width: 0;
}
.home-main-title-block h1 {
  flex: none;
}
.section-page-trail {
  margin: 0 0 0.35rem;
}
.section-page-title {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  min-width: 0;
}
.section-page-title h1 {
  margin: 0;
  min-width: 0;
}
.section-page-logo {
  width: 50px;
  height: 50px;
  object-fit: contain;
  flex: 0 0 50px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.45);
}
.section-editors-byline {
  margin: 0.2rem 0 0;
  text-align: left;
}
.home-section-name {
  margin: 0.15rem 0 0;
  font-family: var(--font-ui);
  font-size: clamp(1.05rem, 1.6vw, 1.25rem);
  font-weight: 700;
  color: var(--moss-deep);
  line-height: 1.25;
}
.section-news-feed {
  background-color: var(--section-feed-color);
  margin: -1.5rem;
  padding: 1.5rem;
  padding-bottom: 3rem;
  min-height: 100%;
}
.section-news-feed .home-main-header {
  background: var(--section-feed-color);
  border-bottom-color: rgba(26, 36, 33, 0.1);
}
.home-main-date-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 0.5rem;
  margin: 0;
  flex: 0 0 auto;
}
.home-main-header-controls {
  display: flex;
  flex-direction: column;
  flex-wrap: nowrap;
  align-items: flex-end;
  justify-content: flex-start;
  gap: 0.45rem;
  margin: 0.35rem 0 0 auto;
  flex: 0 0 auto;
}
.home-main-header-controls .article-view-toggle {
  align-self: flex-end;
}
.article-view-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  padding: 0.15rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
.article-view-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  padding: 0;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: rgba(26, 36, 33, 0.55);
  cursor: pointer;
}
.article-view-btn:hover {
  color: var(--ink);
  background: rgba(26, 36, 33, 0.06);
}
.article-view-btn[aria-pressed="true"] {
  color: var(--moss-deep);
  background: rgba(45, 90, 61, 0.12);
}
.article-card-grid-hit {
  display: none;
}
.article-feed[data-view="list"] {
  display: block;
}
.article-feed[data-view="grid"] {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  align-items: stretch;
}
.article-feed-empty {
  grid-column: 1 / -1;
}
.article-feed[data-view="grid"] .article-card {
  position: relative;
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 0;
  overflow: hidden;
  min-width: 0;
}
.article-feed[data-view="grid"] .article-card-grid-hit {
  display: block;
  position: absolute;
  inset: 0;
  z-index: 2;
}
.article-feed[data-view="grid"] .article-card-sections,
.article-feed[data-view="grid"] .article-card-meta,
.article-feed[data-view="grid"] .article-card-summary {
  display: none !important;
}
.article-feed[data-view="grid"] .article-card-body,
.article-feed[data-view="grid"] .article-card-body--headline-only {
  display: flex;
  flex-direction: column;
  flex: 0 0 auto;
  gap: 0;
  order: -1;
}
.article-feed[data-view="grid"] .article-card-photo {
  width: 100%;
  aspect-ratio: 1 / 1;
  flex: 0 0 auto;
  overflow: hidden;
  background: rgba(26, 36, 33, 0.06);
  position: relative;
}
/* Block (grid) mode: one photo at a time with prev/next above the card hit target. */
.article-feed[data-view="grid"] .article-card-photo .photo-carousel {
  z-index: 4;
  pointer-events: none;
}
.article-feed[data-view="grid"] .article-card-photo .photo-carousel-btn {
  pointer-events: auto;
}
.article-feed[data-view="grid"] .article-card-photo .photo-carousel,
.article-feed[data-view="grid"] .article-card-photo .photo-carousel--thumb,
.article-feed[data-view="grid"] .article-card-photo .photo-carousel-viewport,
.article-feed[data-view="grid"] .article-card-photo .photo-carousel-slide:not([hidden]),
.article-feed[data-view="grid"] .article-card-photo .story-photo-thumb-link {
  display: block !important;
  width: 100% !important;
  max-width: none !important;
  height: 100% !important;
  margin: 0 !important;
  box-sizing: border-box;
}
.article-feed[data-view="grid"] .article-card-photo .photo-carousel-slide[hidden] {
  display: none !important;
}
.article-feed[data-view="grid"] .article-card-photo .photo-carousel--thumb,
.article-feed[data-view="grid"] .article-card-photo .photo-carousel-viewport,
.article-feed[data-view="grid"] .article-card-photo .photo-carousel-slide:not([hidden]) {
  position: absolute !important;
  inset: 0 !important;
}
.article-feed[data-view="grid"] .article-card-photo .story-photo-thumb,
.article-feed[data-view="grid"] .article-card-photo .photo-carousel--thumb .photo-carousel-slide .story-photo-thumb,
.article-feed[data-view="grid"] .article-card-photo .article-card-photo .story-photo-thumb {
  display: block !important;
  width: 100% !important;
  max-width: none !important;
  height: 100% !important;
  object-fit: contain !important;
  object-position: center center !important;
  border-radius: 0 !important;
  background: rgba(26, 36, 33, 0.06);
}
.article-feed[data-view="grid"] .article-card-photo-placeholder {
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  height: auto;
  background:
    linear-gradient(145deg, rgba(45, 90, 61, 0.12), rgba(26, 36, 33, 0.05));
}
.article-feed[data-view="grid"] .article-card-photo-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
}
.article-feed[data-view="grid"] .article-card-site-logo {
  display: block;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: contain;
  object-position: center center;
  padding: 12%;
  box-sizing: border-box;
  background: rgba(26, 36, 33, 0.06);
}
.article-feed-sticky {
  display: block;
  margin-bottom: 0.25rem;
}
.article-feed-sticky .article-card-grid-hit,
.article-feed-sticky .article-card-photo-placeholder,
.article-feed-sticky .article-card-photo-fallback,
.article-feed-sticky .article-card-body--headline-only {
  display: none;
}
.article-feed[data-view="list"] .article-card-photo-placeholder,
.article-feed[data-view="list"] .article-card-photo-fallback,
.article-feed[data-view="list"] .article-card-body--headline-only {
  display: none;
}
.article-feed[data-view="grid"] .article-card-headline-row {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: stretch;
  flex: 0 0 auto;
  position: relative;
  z-index: 3;
  margin: 0;
  padding: 0.75rem 0.85rem 0.9rem;
}
.article-feed[data-view="grid"] .article-card:has(.article-card-grid-summary) .article-card-headline-row {
  padding-bottom: 0.35rem;
}
.article-feed[data-view="grid"] .article-card-headline-row h3 {
  font-size: 1.05rem;
  line-height: 1.3;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  align-self: stretch;
  width: 100%;
  text-align: center;
}
.article-card-grid-summary {
  display: none;
}
.article-feed[data-view="grid"] .article-card-grid-summary {
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex: 1 1 auto;
  position: relative;
  z-index: 3;
  margin: 0;
  padding: 0 0.85rem 0.9rem;
  font-size: 0.82rem;
  line-height: 1.4;
  text-align: center;
  color: rgba(26, 36, 33, 0.65);
}
.article-feed[data-view="grid"] .story-photo-thumb-link {
  pointer-events: none;
}
@media (max-width: 1100px) {
  .article-feed[data-view="grid"] {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 640px) {
  .article-feed[data-view="grid"] {
    grid-template-columns: minmax(0, 1fr);
  }
  .home-main-header-controls {
    width: 100%;
    align-items: flex-end;
    justify-content: flex-start;
  }
}
.home-main-date-filters select {
  min-width: 8.5rem;
  padding: 0.45rem 0.55rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  font-family: var(--font-ui);
  font-size: 0.88rem;
  color: var(--ink);
}
.home-main-header h1 {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3vw, 2.6rem);
  line-height: 1.1;
  margin: 0.25rem 0 0.5rem;
}
.home-main-header .lede {
  font-size: 1.05rem;
  max-width: none;
  margin: 0 0 0.35rem;
}
.home-main-header .home-intro-html {
  margin-bottom: 0;
}
.home-feed-title {
  font-family: var(--font-display);
  font-size: 1.35rem;
  margin: 1.25rem 0 0.75rem;
}
.article-card { animation: rise 0.45s ease both; }
.article-card-headline-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  margin: 0 0 0.35rem;
}
.article-card-headline-row h3 {
  margin: 0;
  min-width: 0;
  flex: 1 1 auto;
}
.article-card-sections {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.35rem;
  flex: 0 1 auto;
  max-width: 45%;
  text-align: right;
}
.article-card-meta {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  margin: 0 0 0.5rem;
}
.article-card-meta-left {
  min-width: 0;
}
.article-card-meta-date {
  margin-left: auto;
  text-align: right;
  white-space: nowrap;
  flex: 0 0 auto;
}
.article-card-body {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}
.article-card-photo {
  flex: 0 0 auto;
}
.article-card-photo .story-photo-thumb {
  width: 15rem;
  height: 11.25rem;
  object-fit: contain;
  background: rgba(26, 36, 33, 0.04);
}
.article-card-summary {
  margin: 0;
  flex: 1 1 auto;
  font-size: 1.08rem;
  line-height: 1.55;
}
.story-document-link {
  margin: 0 0 0.85rem;
  font-family: var(--font-ui);
  font-weight: 700;
}
.story-document-audio {
  display: grid;
  gap: 0.45rem;
}
.story-document-audio-label {
  margin: 0;
}
.story-document-player {
  display: block;
  width: min(100%, 28rem);
  max-width: 100%;
}
.story-document-audio .story-document-download,
.story-document-audio > .small {
  margin: 0;
  font-weight: 600;
}
.article-card-read-more {
  display: inline;
  margin-left: 0.35em;
  font-weight: 700;
  white-space: nowrap;
  text-decoration: none;
  color: var(--moss-deep);
}
.article-card-read-more:hover {
  color: var(--amber);
}

@media (max-width: 640px) {
  .article-card-body {
    flex-direction: column;
  }
}

.home-ads {
  width: 280px;
  max-width: 280px;
  min-width: 280px;
  box-sizing: border-box;
  overflow-x: visible;
  background: rgba(255, 248, 241, 0.65);
  border-left: 1px solid var(--line);
  padding: 1.25rem 0.75rem 2rem;
}
.home-ads-title {
  font-family: var(--font-ui);
  font-size: 1.1rem;
  margin: 0 0 0.85rem;
  text-align: center;
}
.home-ads .ad-slot {
  margin-bottom: 0.85rem;
  border-radius: 10px;
  max-width: 100%;
  padding-left: 0.55rem;
  padding-right: 0.55rem;
}
/* Right-rail caption under banner/square: center sponsor name. */
.home-ads .promo-slot > strong {
  display: block;
  text-align: center;
}
/* Fill the slot so banner/square don’t leave a right gutter beside the image. */
.home-ads .promo-banner-link,
.home-ads .promo-slot .promo-banner,
.home-ads .promo-slot .promo-square-link,
.home-ads .promo-slot .promo-square {
  max-width: 100%;
}
/* Non-highlighted sidebar slots drop the generic .ad-slot amber left bar. */
.home-ads .ad-slot:not(.promo-slot--highlighted) {
  border-left: 0;
}
/*
 * Highlighted border must beat `.home-ads .ad-slot { border-left: 0 }`
 * (and the later generic `.ad-slot { border-left: 3px … }`). That zeroed
 * left edge was why the highlight looked “cut off” on the left — not overflow.
 */
.home-ads .ad-slot.promo-slot--highlighted,
.promo-slot--highlighted {
  border: 2px solid var(--ink);
  border-left: 2px solid var(--ink);
  padding: 0.55rem;
  background: rgba(255, 255, 255, 0.55);
  box-sizing: border-box;
  max-width: 100%;
}
.sponsor-name-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  flex-wrap: wrap;
}
.sponsor-name-row .sponsor-name-field {
  flex: 1 1 12rem;
  min-width: 0;
}
.sponsor-name-row .sponsor-highlight-section {
  flex: 0 0 auto;
  margin-bottom: 0.2rem;
  min-width: 9rem;
}
.sponsor-name-row .sponsor-highlight-section select {
  display: block;
  margin-top: 0.25rem;
  min-width: 9rem;
}
.promo-empty-support-copy {
  margin: 0;
  line-height: 1.45;
}
.promo-empty-letter-link {
  font-weight: 600;
}
.weather-sponsor--empty {
  max-width: 14rem;
}
.weather-sponsor--empty .ad-slot {
  margin: 0;
  border-left: 0;
  border-radius: 10px;
}
.ad-image {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 8px;
  margin-bottom: 0.5rem;
}
.promo-slot .promo-banner {
  width: 100%;
  max-width: 200px;
  height: auto;
  aspect-ratio: 2 / 1;
  object-fit: cover;
}
.promo-banner-link {
  display: block;
  max-width: 200px;
}
.promo-banner-link:hover .promo-banner {
  opacity: 0.92;
}
.promo-slot .promo-square-link {
  display: block;
  margin-top: 0.55rem;
  max-width: 200px;
}
.promo-slot .promo-square {
  display: block;
  width: 100%;
  max-width: 200px;
  height: auto;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 8px;
}
.articles-table.is-sponsors .promo-col-start,
.articles-table.is-sponsors .promo-col-end {
  width: 7.5rem;
  min-width: 7.5rem;
}
.articles-table.is-sponsors .promo-col-section {
  width: 9rem;
  min-width: 7rem;
}
.articles-table.is-sponsors .promo-section-cell {
  overflow: hidden;
  text-overflow: ellipsis;
}
.articles-table.is-sponsors .promo-col-verification { width: 14rem; min-width: 10rem; }
.articles-table.is-sponsors .promo-col-impressions,
.articles-table.is-sponsors .promo-col-clicks {
  width: 5.5rem;
  min-width: 4.5rem;
}
.articles-table.is-sponsors .promo-stat-header,
.articles-table.is-sponsors .promo-stat-cell {
  text-align: right;
}
.articles-table.is-sponsors .articles-col-headline { width: auto; }
.articles-table.is-sponsors .articles-headline-cell {
  overflow: hidden;
  max-width: 0;
}
.articles-table.is-sponsors .articles-headline-link {
  display: block;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.articles-table.is-sponsors .articles-byline {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.articles-table.is-sponsors .articles-date-cell,
.articles-table.is-sponsors th.articles-date-header {
  white-space: nowrap;
}
.articles-table .promo-verification-cell {
  text-align: left;
  white-space: normal;
}
.promo-form-preview {
  display: block;
  margin: 0.35rem 0 0.5rem;
  border-radius: 6px;
  border: 1px solid var(--line);
}
.promo-form-preview-banner {
  width: 200px;
  height: 100px;
  object-fit: cover;
}
.promo-form-preview-square {
  width: 160px;
  height: 160px;
  object-fit: cover;
}

.event-form-preview {
  width: min(100%, 320px);
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.calendar-event-drawer-image {
  margin: 0.75rem 0 0;
}
.calendar-event-drawer-image img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 8px;
  border: 1px solid rgba(26, 36, 33, 0.08);
}

.home-main-inner .section.wrap {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 0;
}
.home-main-inner .layout-split {
  grid-template-columns: 1fr;
}

@media (max-width: 960px) {
  .home-shell,
  .home-shell.home-shell-no-ads {
    grid-template-columns: 1fr;
  }
  .home-menu,
  .home-ads {
    width: auto;
    max-width: none;
    min-width: 0;
    border: 0;
    border-bottom: 1px solid var(--line);
  }
  .home-menu {
    position: static;
    top: auto;
    align-self: auto;
    height: auto;
    max-height: none;
    overflow: visible;
  }
  .home-menu-inner {
    position: static;
    max-height: none;
    overflow: visible;
  }
  .side-nav {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 0.35rem;
  }
  .side-nav-label { width: 100%; margin-top: 0.5rem; }
  .side-nav-summary { width: 100%; margin-top: 0.5rem; }
  .article-card-headline-row {
    flex-wrap: wrap;
  }
  .article-card-sections {
    max-width: 100%;
    justify-content: flex-start;
  }
}

.site-header {
  position: sticky; top: 0; z-index: 20;
  backdrop-filter: blur(10px);
  background: rgba(243, 239, 230, 0.85);
  border-bottom: 1px solid var(--line);
}
body.has-site-color .site-header {
  background: color-mix(in srgb, var(--community-site-color) 85%, transparent);
}
.public-story-header {
  position: sticky;
  top: 0;
  z-index: 30;
  backdrop-filter: blur(12px);
  background: rgba(243, 239, 230, 0.94);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 8px 24px rgba(20, 40, 34, 0.06);
}
body.has-site-color.body-public-story .public-story-header {
  background: color-mix(in srgb, var(--community-site-color) 88%, transparent);
}
.public-story-header-inner {
  padding: 1rem 0 0.95rem;
}
.public-story-site-brand {
  display: flex;
  align-items: center;
  gap: 1rem;
  text-decoration: none;
  color: inherit;
  min-width: 0;
  margin: 0 0 0.85rem;
}
.public-story-site-brand--with-logo {
  align-items: center;
}
.public-story-site-logo {
  /* Match native 75×75 header logo so it stays sharp (no upscale blur). */
  width: 75px;
  height: 75px;
  object-fit: contain;
  flex: 0 0 75px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.4);
  box-shadow: 0 2px 10px rgba(20, 40, 34, 0.06);
}
.public-story-site-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.2rem;
  min-width: 0;
}
.public-story-site-name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2rem, 4.5vw, 3rem);
  line-height: 1.05;
  color: var(--moss-deep);
  letter-spacing: -0.02em;
}
.public-story-site-tagline {
  font-family: var(--font-ui);
  font-size: clamp(0.95rem, 2vw, 1.1rem);
  line-height: 1.35;
  color: rgba(26, 36, 33, 0.72);
  max-width: 40rem;
}
.public-story-header-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1rem;
}
.public-story-brand {
  font-size: clamp(1.45rem, 3vw, 1.85rem);
}
.public-story-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  align-items: center;
}
.public-story-promo {
  margin: 0;
  font-family: var(--font-ui);
  font-size: 0.92rem;
  line-height: 1.45;
  color: rgba(26, 36, 33, 0.78);
  max-width: 40rem;
  flex: 1 1 16rem;
}
.public-story-promo a {
  font-weight: 700;
  text-decoration: none;
  color: var(--moss-deep);
}
.public-story-promo a:hover {
  color: var(--amber);
}
.public-story-main {
  padding-bottom: 0.5rem;
  min-height: 0;
}
.public-story-cta {
  margin: 0.5rem auto 2rem;
}
.public-story-cta-panel {
  background: rgba(255, 253, 248, 0.95);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.35rem 1.4rem;
  box-shadow: var(--shadow);
}
.public-story-cta-panel h2 {
  margin: 0 0 0.45rem;
  font-family: var(--font-display);
  font-size: 1.55rem;
}
.public-story-cta-panel p {
  margin: 0 0 1rem;
  max-width: 40rem;
}
.start-site-page h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 2.8rem);
  margin: 0 0 0.75rem;
  max-width: 18ch;
}
.start-site-panel {
  margin-top: 1.15rem;
}
.start-site-list {
  margin: 0.35rem 0 0;
  padding-left: 1.2rem;
  line-height: 1.55;
}
.start-site-list li {
  margin-bottom: 0.35rem;
}
@media (max-width: 640px) {
  .public-story-site-brand {
    gap: 0.75rem;
    margin-bottom: 0.55rem;
  }
  .public-story-site-logo {
    width: 64px;
    height: 64px;
    flex-basis: 64px;
    border-radius: 8px;
  }
  .public-story-site-name {
    font-size: clamp(1.55rem, 7vw, 2rem);
  }
  .public-story-site-tagline {
    font-size: 0.88rem;
  }
  .public-story-header-row {
    align-items: flex-start;
  }
  .public-story-nav {
    width: 100%;
  }
  .public-story-nav .btn {
    flex: 1 1 auto;
    text-align: center;
  }
  /* Fallback when UA is not tagged is-mobile: keep shared story scrollable + compact */
  .body-public-story {
    height: 100vh;
    height: 100dvh;
    max-height: 100vh;
    max-height: 100dvh;
  }
  .body-public-story .public-story-main .story-view {
    flex: 1 1 auto;
    min-height: 0;
    max-height: 100%;
    overflow: hidden;
    padding: 0.45rem 0 0;
    width: calc(100% - 1.25rem);
    max-width: calc(100% - 1.25rem);
  }
  .body-public-story .story-view-content {
    overflow-y: scroll;
    -webkit-overflow-scrolling: touch;
    padding: 0.55rem 0 0.85rem;
  }
  .body-public-story .public-story-header-inner {
    padding: 0.55rem 0 0.65rem;
  }
  .body-public-story .public-story-promo {
    margin: 0;
    font-size: 0.8rem;
    line-height: 1.35;
  }
  .body-public-story .public-story-footer {
    padding-top: 0.4rem;
    padding-bottom: 0.4rem;
  }
  .body-public-story .public-story-footer p {
    margin: 0.1rem 0;
    font-size: 0.78rem;
    line-height: 1.35;
  }
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem; padding: 0.9rem 0;
}
.brand {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.9rem;
  color: var(--moss-deep);
  text-decoration: none;
  letter-spacing: -0.02em;
}
.brand.brand-with-logo {
  font-size: 0;
}
.nav { display: flex; flex-wrap: wrap; gap: 0.85rem; align-items: center; font-family: var(--font-ui); font-weight: 600; font-size: 0.95rem; }
.nav a { text-decoration: none; color: var(--ink); }
.nav a:hover { color: var(--moss); }

.hero {
  padding: 3.5rem 0 2.5rem;
  animation: rise 0.7s ease both;
}
.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 5vw, 4rem);
  line-height: 1.05;
  margin: 0 0 0.75rem;
  max-width: 14ch;
}
.hero p.lede {
  font-size: 1.15rem;
  max-width: 40rem;
  margin: 0 0 1.5rem;
  color: rgba(26,36,33,0.8);
}
.hero-panel {
  margin-top: 2rem;
  border-radius: var(--radius);
  overflow: hidden;
  min-height: 280px;
  background:
    linear-gradient(135deg, rgba(20,61,52,0.72), rgba(196,92,38,0.35)),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160' viewBox='0 0 160 160'%3E%3Cpath fill='%23ffffff22' d='M0 80h160M80 0v160'/%3E%3C/svg%3E"),
    linear-gradient(160deg, #1f5c4d, #2f3e46);
  box-shadow: var(--shadow);
  display: grid;
  place-items: end start;
  padding: 1.5rem;
  color: white;
  animation: fadein 1s ease both 0.15s;
}
.hero-panel strong { font-family: var(--font-display); font-size: 1.4rem; display: block; }

.section { padding: 1.5rem 0 3rem; }
.section h2 {
  font-family: var(--font-display);
  font-size: 1.8rem;
  margin: 0 0 1rem;
}
.login-community-name {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 2.75rem);
  line-height: 1.1;
  margin: 0 0 0.75rem;
}
.login-community-name--with-logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.login-community-logo {
  width: 56px;
  height: 56px;
  object-fit: contain;
  flex: 0 0 56px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.35);
}
.login-community-name--with-logo > span {
  min-width: 0;
}
.login-form-links {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin: 0.75rem 0 1.25rem;
}
.login-form-links a:last-child {
  margin-left: auto;
  text-align: right;
}
.login-guest-panel {
  margin-top: 0.25rem;
}
.login-guest-title {
  font-family: var(--font-display);
  font-size: 1.25rem;
  margin: 0 0 0.35rem;
}
.login-guest-form label {
  display: block;
  margin-bottom: 0.75rem;
}
.login-guest-form input[name="community"] {
  width: 100%;
}

/* Login submit: calm moss spinner while the server responds */
.login-processing {
  display: none;
  align-items: center;
  gap: 0.65rem;
  margin: 0.9rem 0 0;
  color: var(--moss-deep);
  font-size: 0.95rem;
  font-weight: 600;
}
form[data-login-form].is-processing .login-processing,
.login-processing.is-visible {
  display: flex;
}
.login-processing-spinner {
  width: 1.15rem;
  height: 1.15rem;
  flex: 0 0 1.15rem;
  border: 2.5px solid rgba(31, 92, 77, 0.22);
  border-top-color: var(--moss);
  border-radius: 50%;
  animation: login-spin 0.7s linear infinite;
}
@keyframes login-spin {
  to { transform: rotate(360deg); }
}
@media (prefers-reduced-motion: reduce) {
  .login-processing-spinner {
    animation: none;
    border-color: var(--moss);
    opacity: 0.85;
  }
}
.btn:disabled,
button.btn:disabled {
  opacity: 0.65;
  cursor: wait;
  pointer-events: none;
}
/* Author compose: Submit gated until first Save (tooltip via wrap). */
.btn-save-first-wrap {
  display: inline-block;
  cursor: not-allowed;
}
.btn-save-first-wrap .btn:disabled {
  cursor: not-allowed;
}

.grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
}
.community-tile {
  display: block;
  padding: 1.25rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  text-decoration: none;
  color: inherit;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  animation: rise 0.6s ease both;
}
.community-tile:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}
.community-tile h3 {
  font-family: var(--font-display);
  margin: 0 0 0.35rem;
  font-size: 1.35rem;
}
.muted { color: rgba(26,36,33,0.65); }
.small { font-size: 0.9rem; }

.btn, button.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 0.4rem;
  border: 0;
  border-radius: 999px;
  padding: 0.7rem 1.2rem;
  background: var(--moss);
  color: white;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  text-decoration: none;
}
.btn:hover { background: var(--moss-deep); color: white; }
.btn-small { padding: 0.45rem 0.9rem; font-size: 0.9rem; }
.btn-secondary { background: transparent; color: var(--moss-deep); border: 1px solid var(--moss); }
.btn-secondary:hover { background: rgba(31,92,77,0.08); color: var(--moss-deep); }
.btn-danger { background: #8b2e2e; }
.btn-amber { background: var(--amber); }

.panel {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.25rem;
  margin-bottom: 1rem;
}
.panel h3 { margin-top: 0; font-family: var(--font-display); }

label.checkbox-row {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  margin: 0;
  cursor: pointer;
  line-height: 1.4;
}
label.checkbox-row input {
  margin-top: 0.2rem;
  width: 1.1rem;
  height: 1.1rem;
  flex: 0 0 auto;
}

.form-grid {
  display: grid;
  gap: 0.9rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.form-grid .full { grid-column: 1 / -1; }
.form-grid .half { grid-column: 1 / 2; }
.promo-code-description-field {
  max-width: 28rem;
}
.promo-code-description-field label {
  display: block;
}
.promo-code-description-input {
  display: block;
  width: 40ch;
  max-width: 100%;
  box-sizing: content-box;
  font: inherit;
  line-height: 1.35;
  padding: 0.4rem 0.55rem;
}
.promo-code-frontpage {
  margin: 0 0 1rem;
  padding: 0 0.55rem 0.85rem;
  border-bottom: 1px solid var(--line);
  text-align: center;
}
.promo-code-frontpage-title {
  margin: 0 0 0.55rem;
  font-family: var(--font-ui);
  font-size: 1.05rem;
  font-weight: 600;
  line-height: 1.25;
  text-align: center;
}
.promo-code-frontpage-btn {
  display: inline-block;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.promo-code-frontpage-desc {
  margin: 0.45rem 0 0;
  font-size: 0.88rem;
  line-height: 1.35;
  color: var(--muted, #5a5a5a);
  word-break: break-word;
  text-align: center;
}
.article-feed--with-promos > .promo-code-frontpage {
  margin: 0 0 0.85rem;
  padding: 0.65rem 0.75rem 0.85rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(255, 248, 241, 0.65);
}
.promo-code-top-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  align-items: flex-start;
}
.promo-code-top-row > label:nth-child(1) {
  width: 11.5rem;
  flex: 0 0 11.5rem;
}
.promo-code-top-row > label:nth-child(2) {
  width: 7rem;
  flex: 0 0 7rem;
}
.promo-code-right-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  align-items: flex-start;
  margin-left: auto;
}
.promo-used-value {
  font-weight: 700;
  font-size: 1.05rem;
  line-height: 1.4;
  padding: 0.65rem 0;
}
.promo-code-top-row > label:nth-child(2) input,
.promo-total-value .promo-used-value,
.promo-total-value input,
.promo-max-redemptions .promo-used-value,
.promo-max-redemptions input,
.promo-code-top-row > div:nth-child(2) .promo-used-value {
  text-align: right;
}
.promo-max-redemptions {
  width: 9.5rem;
  flex: 0 0 9.5rem;
  line-height: 1.2;
  text-align: right;
}
.promo-max-redemptions input {
  width: 100%;
}
.promo-total-value {
  width: 7.5rem;
  flex: 0 0 7.5rem;
  font-family: var(--font-ui);
  font-size: 0.92rem;
  text-align: right;
}
.promo-total-value input {
  width: 100%;
}
.promo-form-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  margin-bottom: 0.65rem;
}
.promo-form-actions-top {
  margin-top: 0;
  margin-left: auto;
  justify-content: flex-end;
}
.promo-form-actions-top .actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  justify-content: flex-end;
}
.promo-form-actions-top .section-form-delete {
  margin-left: 0;
  display: inline;
}
.promo-ledger-table {
  width: 100%;
  border-collapse: collapse;
}
.promo-ledger-table th,
.promo-ledger-table td {
  padding: 0.45rem 0.35rem;
  border-bottom: 1px solid rgba(26, 36, 33, 0.1);
  vertical-align: top;
}
.promo-ledger-table th {
  font-size: 0.85rem;
  text-align: left;
}
.promo-ledger-table .promo-ledger-amt {
  text-align: right;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
  width: 6.5rem;
}
@media (max-width: 640px) {
  .promo-code-top-row > label:nth-child(1),
  .promo-code-top-row > label:nth-child(2) {
    width: 100%;
    flex: 1 1 100%;
    max-width: 11.5rem;
  }
  .promo-code-right-group {
    margin-left: 0;
    width: 100%;
  }
}
.field-hint {
  display: block;
  margin-top: 0.3rem;
}
.event-short-section-row,
.event-name-section-row,
.article-headline-section-row,
.classified-header-category-row,
.notice-date-type-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 0.9rem 1.25rem;
}
.notice-date-field {
  flex: 0 1 12rem;
  min-width: 10rem;
  margin: 0;
}
.notice-date-field input {
  width: 100%;
  box-sizing: border-box;
}
.notice-type-field {
  flex: 0 1 18rem;
  margin: 0 0 0 auto;
  min-width: 12rem;
  text-align: left;
}
.notice-type-field select {
  width: 100%;
  min-width: 12rem;
  box-sizing: border-box;
}
.event-short-name-standalone {
  min-width: 0;
}
.event-short-name-standalone input {
  width: 100%;
  max-width: 14em;
  box-sizing: border-box;
}
.event-short-name-field,
.event-name-field,
.article-headline-field,
.classified-header-field {
  flex: 1 1 auto;
  min-width: 14rem;
  width: auto;
  max-width: none;
  margin: 0;
}
.event-short-name-field input,
.event-name-field input,
.article-headline-field input,
.classified-header-field input {
  width: 100%;
  max-width: none;
  box-sizing: border-box;
}
.event-name-section-row .event-short-name-field {
  flex: 0 1 14em;
  min-width: 10rem;
  max-width: 14em;
}
.event-section-field,
.article-section-field,
.classified-category-field {
  flex: 0 1 14rem;
  margin: 0 0 0 auto;
  min-width: 10rem;
  text-align: left;
}
.event-section-field select,
.article-section-field select,
.classified-category-field select {
  width: 100%;
  min-width: 10rem;
}
.event-datetime-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.9rem 1.25rem;
  align-items: start;
}
.obituary-service-fieldset {
  margin: 0.85rem 0 0;
  padding: 0.85rem 1rem 1rem;
  border: 1px solid var(--line, rgba(26, 36, 33, 0.22));
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.55);
}
.obituary-service-fieldset legend {
  padding: 0 0.35rem;
  margin: 0 0 0.65rem;
  font-weight: 700;
  color: var(--ink, #1a2421);
}
.obituary-service-fieldset .event-datetime-row {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-bottom: 0.75rem;
}
.obituary-services {
  display: grid;
  gap: 1rem;
  margin-top: 1.25rem;
}
.obituary-service {
  margin: 0;
  padding: 0.85rem 1rem 1rem;
  border: 1px solid var(--line, rgba(26, 36, 33, 0.22));
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.55);
}
.obituary-service-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}
.obituary-view-meta {
  display: grid;
  gap: 0.35rem;
  margin: 0 0 1rem;
}
.obituary-view-meta > .obituary-meta-text {
  display: block;
  width: 100%;
}
.obituary-view-meta .obituary-funeral-home {
  margin: 0;
  color: var(--ink, #1a2421);
}
.obituary-meta-line {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.65rem;
}
.obituary-meta-text {
  margin: 0;
  flex: 1 1 auto;
  min-width: 0;
  color: var(--ink, #1a2421);
}
.obituary-meta-label {
  display: inline-block;
  margin-right: 0.4rem;
  font-weight: 700;
}
.obituary-drawer-body > [data-obituary-meta]:not([hidden]) {
  margin: 0 0 0.85rem;
}
.obituary-meta-line .calendar-event-add-menu {
  flex: 0 0 auto;
  margin-top: -0.15rem;
}
.obituary-meta-line .calendar-event-add-toggle {
  width: 2rem;
  height: 2rem;
}
.obituary-view-meta + .story-body {
  margin-top: 0.25rem;
}
.classified-run-dates-row {
  display: grid;
  grid-template-columns: minmax(12rem, 1.2fr) repeat(2, minmax(0, 1fr)) minmax(12rem, 1.5fr);
  gap: 0.9rem 1.25rem;
  align-items: start;
}
.classified-run-dates-row label,
.classified-run-fee-fields,
.classified-listing-price-field,
.classified-wallet-balance-field {
  margin: 0;
  min-width: 0;
}
.classified-run-dates-row input,
.classified-run-dates-row select {
  width: 100%;
  box-sizing: border-box;
}
.classified-run-fee-fields {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem 1.25rem;
  align-items: start;
}
.classified-listing-price-field,
.classified-wallet-balance-field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  flex: 1 1 5.5rem;
}
.classified-listing-price-label {
  display: block;
  font-weight: inherit;
}
.classified-listing-price-value {
  display: block;
  font-size: 1.1rem;
  line-height: 1.4;
  padding: 0.55rem 0 0;
  font-variant-numeric: tabular-nums;
}
.classified-price-url-row {
  display: grid;
  grid-template-columns: minmax(8rem, 10rem) minmax(0, 1fr);
  gap: 0.9rem 1.25rem;
  align-items: start;
}
.classified-price-url-row label {
  margin: 0;
  min-width: 0;
}
.classified-contact-info {
  margin: 0;
  padding: 0;
  border: 0;
  min-width: 0;
}
.classified-contact-info legend {
  padding: 0;
  margin: 0 0 0.35rem;
  font-weight: 600;
}
.classified-contact-info-row {
  display: grid;
  grid-template-columns: minmax(10rem, 12rem) minmax(0, 1fr);
  gap: 0.9rem 1.25rem;
  align-items: start;
}
.classified-contact-info-row label,
.classified-contact-info-row .classified-cell-field {
  margin: 0;
  min-width: 0;
}
.classified-contact-info-row input,
.classified-contact-email-field input,
.classified-cell-field input[type="tel"] {
  width: 100%;
  box-sizing: border-box;
}
.classified-cell-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin: 0 0 0.25rem;
  font-weight: 600;
}
.classified-text-msg-check {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin: 0;
  font-weight: 500;
  font-size: 0.9rem;
  cursor: pointer;
}
.classified-text-msg-check input {
  width: auto;
  margin: 0;
}
.classified-contact-email-field {
  display: block;
  margin: 0.75rem 0 0;
  min-width: 0;
}
.classified-contact-public {
  margin: 1rem 0 0;
  display: grid;
  gap: 0.35rem;
}
.classified-contact-public p {
  margin: 0;
}
.classified-price-field input,
.classified-outside-url-field input {
  width: 100%;
  box-sizing: border-box;
}
.event-datetime-row label {
  margin: 0;
  min-width: 0;
}
.event-datetime-row input {
  width: 100%;
  box-sizing: border-box;
}
.user-form-tabs {
  margin: 0 0 0.85rem;
}
.user-form-panel[hidden] {
  display: none !important;
}
.user-permissions-list {
  list-style: none;
  margin: 0 0 1rem;
  padding: 0;
  display: grid;
  gap: 0.55rem;
}
.user-permissions-list .checkbox-row {
  display: flex;
  align-items: center;
  gap: 0.55rem;
}
.editor-permission-extras {
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px solid rgba(26, 36, 33, 0.12);
}
.user-form-name-type-row {
  display: grid;
  gap: 0.9rem;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(9rem, 11rem);
  align-items: end;
}
.user-form-name-type-row:not(:has(.user-form-type)) {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}
.user-form-type {
  justify-self: end;
  text-align: right;
  width: 100%;
  max-width: 11rem;
}
.user-form-type select,
.user-form-type input {
  width: 100%;
  box-sizing: border-box;
}
.user-form-email-phone-row {
  display: grid;
  gap: 0.9rem;
  grid-template-columns: minmax(0, 1fr) 11rem;
  align-items: end;
}
.user-form-phone input {
  width: 100%;
  box-sizing: border-box;
}
.editor-in-chief-row {
  margin: 1.25rem 0 0;
}
.editor-in-chief-row label {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  margin: 0;
  font-weight: 400;
  cursor: pointer;
}
.editor-in-chief-row input[type="checkbox"] {
  margin-top: 0.2rem;
  flex: 0 0 auto;
}
.editor-sections-block {
  margin: 1rem 0 0;
  padding: 1rem 0 0;
  border: 0;
  border-top: 1px solid rgba(0, 0, 0, 0.12);
}
.editor-sections-block legend {
  padding: 0;
  font-weight: 600;
  font-size: 1rem;
}
.editor-sections-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.45rem 1.25rem;
  grid-template-columns: repeat(auto-fill, minmax(12rem, 1fr));
}
.editor-sections-list label {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  margin: 0;
  font-weight: 400;
  cursor: pointer;
}
.editor-sections-list input[type="checkbox"] {
  margin-top: 0.2rem;
  flex: 0 0 auto;
}
.user-search-form {
  display: inline-flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 0.5rem;
  margin: 0;
  flex: 0 1 auto;
  min-width: 0;
}
.users-select-prompt {
  margin: 0;
  padding: 0.25rem 0;
}
.panel table td:has(.user-terms-accepted) {
  overflow: visible;
}
.user-terms-accepted {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-left: 0.25rem;
  padding: 0.2rem;
  vertical-align: middle;
  color: var(--moss);
  opacity: 0.8;
  cursor: help;
  border: 0;
  background: transparent;
  border-radius: 4px;
  line-height: 0;
  pointer-events: auto;
}
.user-terms-accepted:hover,
.user-terms-accepted:focus-visible {
  opacity: 1;
  outline: none;
  background: rgba(31, 92, 77, 0.08);
}
.user-terms-accepted-icon {
  display: block;
  flex: 0 0 auto;
  pointer-events: none;
}
/* Immediate CSS tooltip — native title alone was unreliable on the tiny SVG span.
   Anchor below the icon so table/panel overflow is less likely to clip it. */
.user-terms-accepted[data-tooltip]::after {
  content: attr(data-tooltip);
  position: absolute;
  left: 0;
  top: calc(100% + 0.3rem);
  z-index: 40;
  box-sizing: border-box;
  width: max-content;
  max-width: 16rem;
  padding: 0.35rem 0.55rem;
  border-radius: 6px;
  background: var(--ink);
  color: var(--white);
  font-family: var(--font-ui);
  font-size: 0.78rem;
  font-weight: 500;
  line-height: 1.25;
  white-space: nowrap;
  box-shadow: 0 6px 16px rgba(20, 40, 34, 0.18);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.12s ease, visibility 0.12s ease;
}
.user-terms-accepted[data-tooltip]:hover::after,
.user-terms-accepted[data-tooltip]:focus-visible::after {
  opacity: 1;
  visibility: visible;
}

.users-page-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  margin-bottom: 1rem;
}
.users-page-header h2 {
  margin: 0;
}
.users-page-header-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 0.65rem;
  margin-left: auto;
}
.user-search-form input[type="search"] {
  width: 14rem;
  min-width: 8rem;
  max-width: 20rem;
  flex: 1 1 auto;
  padding: 0.55rem 0.75rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-family: var(--font-ui);
  font-size: 0.95rem;
}
.user-search-form .btn,
.user-search-form .btn-small {
  flex-shrink: 0;
  white-space: nowrap;
}
.article-summary-price-row {
  display: grid;
  gap: 0.9rem;
  grid-template-columns: minmax(0, 1fr) 8.5rem;
  align-items: end;
}
.article-media-row {
  display: grid;
  gap: 0.9rem;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  align-items: start;
}
.article-photos-field,
.article-document-field {
  display: grid;
  gap: 0.35rem;
  font-weight: 600;
  font-size: 0.92rem;
  font-family: var(--font-ui);
}
.article-photos-field input[type="file"],
.article-document-field input[type="file"] {
  font-weight: 400;
}
@media (max-width: 640px) {
  .article-media-row {
    grid-template-columns: 1fr;
  }
}
.section-form-fields {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}
.section-form-title-row {
  display: grid;
  gap: 0.9rem;
  grid-template-columns: minmax(0, 1fr) 6.5rem;
  align-items: end;
}
.section-form-title-row-with-active {
  grid-template-columns: minmax(0, 1fr) 6.5rem 6.5rem;
}
.section-form-sort input {
  width: 100%;
}
.section-form-description {
  display: block;
  width: 100%;
}
.section-form-description input {
  width: 100%;
  box-sizing: border-box;
}
.section-form-active {
  display: block;
  max-width: none;
}
.section-form-active select {
  width: 100%;
}
.section-form-color {
  display: block;
  max-width: 16rem;
}
.section-form-logo {
  display: grid;
  gap: 0.45rem;
}
.section-form-logo-heading {
  margin: 0;
  font-weight: 600;
}
.section-form-logo-preview-wrap {
  margin: 0;
}
.section-logo-preview {
  display: block;
  width: 50px;
  height: 50px;
  object-fit: contain;
  border-radius: 6px;
  border: 1px solid var(--line);
  background: #fff;
}
.section-form-logo-hint {
  margin: 0;
}
.section-form-logo-remove {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-weight: 400;
}
.section-form-editors {
  display: grid;
  gap: 0.45rem;
}
.section-form-editors-heading {
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: 0.92rem;
}
.section-form-editors-empty {
  margin: 0;
}
.section-form-editors-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.4rem;
}
.section-form-editors-list li {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.75rem;
  align-items: baseline;
}
.section-form-editor-name {
  font-weight: 500;
}
.color-dropdown {
  position: relative;
}
.color-dropdown-trigger {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  width: 100%;
  padding: 0.65rem 0.75rem;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #fff;
  font: inherit;
  color: var(--ink);
  cursor: pointer;
  text-align: left;
}
.color-dropdown-trigger::after {
  content: "";
  width: 0.45rem;
  height: 0.45rem;
  margin-left: auto;
  border-right: 2px solid rgba(26, 36, 33, 0.55);
  border-bottom: 2px solid rgba(26, 36, 33, 0.55);
  transform: rotate(45deg) translateY(-1px);
}
.color-dropdown-menu {
  position: absolute;
  z-index: 20;
  top: calc(100% + 0.35rem);
  left: 0;
  right: 0;
  margin: 0;
  padding: 0.35rem;
  list-style: none;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 8px 24px rgba(26, 36, 33, 0.12);
  max-height: 14rem;
  overflow-y: auto;
}
.color-dropdown-option {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.5rem 0.55rem;
  border-radius: 8px;
  cursor: pointer;
}
.color-dropdown-option:hover,
.color-dropdown-option.is-selected {
  background: rgba(26, 36, 33, 0.06);
}
.section-color-swatch {
  display: inline-block;
  width: 1.25rem;
  height: 1.25rem;
  border-radius: 999px;
  border: 1px solid rgba(26, 36, 33, 0.12);
  flex-shrink: 0;
}
.section-color-swatch-none {
  background:
    linear-gradient(135deg, transparent 46%, rgba(26, 36, 33, 0.28) 48%, rgba(26, 36, 33, 0.28) 52%, transparent 54%),
    #fff;
}
.section-form-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.75rem;
  margin-top: 1rem;
  flex-wrap: wrap;
}
.section-form-actions .actions {
  justify-content: flex-end;
}
.section-form-delete {
  margin-left: 0;
}
.article-summary-field,
.article-price-field {
  display: grid;
  gap: 0.35rem;
  font-weight: 600;
  font-size: 0.92rem;
}
.article-summary-field textarea {
  min-height: 0;
  height: auto;
  resize: vertical;
  field-sizing: content;
}
.article-price-field input {
  width: 100%;
}
@media (max-width: 640px) {
  .article-summary-price-row {
    grid-template-columns: 1fr;
  }
}
label { display: grid; gap: 0.35rem; font-family: var(--font-ui); font-weight: 600; font-size: 0.92rem; }
input, select, textarea {
  font: inherit;
  padding: 0.65rem 0.75rem;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #fff;
}
textarea { min-height: 140px; resize: vertical; }

/* Letter to the Editor: inputs inherit label weight (600); keep typing weight normal + slightly larger. */
#letter-form input,
#letter-form textarea {
  font-weight: 400;
  font-size: 1.05rem;
}

/* Event create/edit: same — labels are bold; typed values stay normal weight + slightly larger.
   Form uses id=article-form (shared editor stack) + .event-form for scoping. */
form.event-form input,
form.event-form textarea,
form.event-form select {
  font-weight: 400;
  font-size: 1.05rem;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}
table th {
  font-family: var(--font-ui);
}
.sections-table {
  table-layout: fixed;
}
.sections-table .sections-col-sort { width: 5%; }
.sections-table .sections-col-color { width: 8%; }
.sections-table .sections-col-name { width: 57%; }
.sections-table .sections-col-articles { width: 5%; }
.sections-table .sections-col-edit { width: 25%; }
.sections-table td:nth-child(1),
.sections-table th:nth-child(1),
.sections-table td:nth-child(4),
.sections-table th:nth-child(4),
.sections-table td:nth-child(5),
.sections-table th:nth-child(5) {
  text-align: right;
}
.sections-table td:nth-child(2),
.sections-table th:nth-child(2) {
  text-align: center;
}
.sections-table td:nth-child(3) {
  overflow-wrap: anywhere;
}

/* Market Place has no color column — fold that 8% into the name column. */
.marketplace-sections-table .marketplace-sections-col-name {
  width: 65%;
}
.marketplace-sections-table td:nth-child(1),
.marketplace-sections-table th:nth-child(1),
.marketplace-sections-table td:nth-child(3),
.marketplace-sections-table th:nth-child(3),
.marketplace-sections-table td:nth-child(4),
.marketplace-sections-table th:nth-child(4) {
  text-align: right;
}
.marketplace-sections-table td:nth-child(1),
.marketplace-sections-table td:nth-child(3) {
  vertical-align: top;
}
.marketplace-sections-table td:nth-child(2),
.marketplace-sections-table th:nth-child(2) {
  text-align: left;
  overflow-wrap: anywhere;
}

.marketplace-sections-title {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.35rem 0.5rem;
}
.marketplace-sections-desc {
  margin: 0.2rem 0 0;
}

.tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin: 0;
  padding: 0.35rem;
  border-radius: 12px;
  background: rgba(26, 36, 33, 0.04);
  border: 1px solid var(--line);
  font-family: var(--font-ui);
}
.calendar-page {
  padding: 0.25rem 0 1.5rem;
}
.weather-page {
  padding: 0.25rem 0 1.5rem;
}
.weather-page-header {
  margin-bottom: 1rem;
}
.weather-title {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.35rem 0.85rem;
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 3vw, 2.3rem);
}
.weather-title-location {
  font-family: var(--font-ui);
  font-size: 0.72em;
  font-weight: 600;
  color: var(--ink-muted, #4a5752);
}
.weather-section-label {
  margin: 0 0 0.65rem;
  font-family: var(--font-display);
  font-size: 1.2rem;
}
.weather-now {
  margin-bottom: 1.25rem;
}
.weather-now-layout {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem 1.25rem;
}
.weather-now-main {
  flex: 1 1 14rem;
  min-width: 0;
}
.weather-sponsor {
  flex: 0 0 auto;
  margin-left: auto;
  text-align: right;
}
.weather-sponsor-link {
  display: inline-block;
  line-height: 0;
}
.weather-sponsor-image {
  display: block;
  max-width: min(220px, 42vw);
  max-height: 160px;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: #fff;
}
.weather-sponsor-control {
  margin-bottom: 1rem;
}
.weather-sponsor-form {
  margin: 0;
}
.weather-sponsor-label {
  display: block;
  font-weight: 700;
  font-family: var(--font-ui);
  margin-bottom: 0.4rem;
}
.weather-sponsor-fields {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 0.65rem;
}
.weather-sponsor-fields select {
  min-width: min(100%, 18rem);
  max-width: 28rem;
}
.weather-now-primary {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem 0.75rem;
  margin: 0 0 0.55rem;
  font-family: var(--font-ui);
}
.weather-now-temp {
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  font-weight: 700;
  color: var(--moss-deep);
  line-height: 1;
}
.weather-now-summary {
  font-size: 1.05rem;
  font-weight: 600;
}
.weather-now-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1rem;
  margin: 0;
  font-family: var(--font-ui);
  font-size: 0.92rem;
}
.weather-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--moss-deep);
  line-height: 0;
  flex: 0 0 auto;
}
.weather-icon svg {
  width: 100%;
  height: 100%;
  display: block;
}
.weather-icon--now {
  width: 2.4rem;
  height: 2.4rem;
}
.weather-icon--day {
  width: 2.75rem;
  height: 2.75rem;
}
.weather-icon--clear,
.weather-icon--mostly-clear {
  color: #c9851a;
}
.weather-icon--partly-cloudy,
.weather-icon--overcast,
.weather-icon--fog,
.weather-icon--mixed {
  color: #5b6e7a;
}
.weather-icon--drizzle,
.weather-icon--rain,
.weather-icon--showers {
  color: #2f6f9e;
}
.weather-icon--snow {
  color: #5a7ea8;
}
.weather-icon--thunder {
  color: #8a5a12;
}
.weather-day-icon {
  margin: 0 0 0.45rem;
}
.weather-forecast {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 0.65rem;
  margin-bottom: 1rem;
}
.weather-day {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.85rem 0.7rem;
  background: rgba(31, 92, 77, 0.04);
  font-family: var(--font-ui);
  min-width: 0;
}
.weather-day.is-today {
  background: rgba(31, 92, 77, 0.1);
  border-color: rgba(31, 92, 77, 0.28);
}
.weather-day-label {
  font-weight: 700;
  color: var(--moss-deep);
  margin-bottom: 0.35rem;
}
.weather-day-summary {
  font-size: 0.9rem;
  line-height: 1.3;
  margin-bottom: 0.55rem;
  min-height: 2.4em;
}
.weather-day-temps {
  display: flex;
  align-items: baseline;
  gap: 0.4rem;
  margin-bottom: 0.25rem;
}
.weather-day-high {
  font-size: 1.15rem;
  font-weight: 700;
}
.weather-day-low {
  font-size: 0.95rem;
}
.weather-day-precip {
  font-size: 0.82rem;
}
.return-to-frontpage {
  margin: 0 0 0.75rem;
  font-family: var(--font-ui);
  font-size: 0.92rem;
  font-weight: 600;
  line-height: 1.3;
}
.return-to-frontpage a {
  color: var(--moss-deep);
  text-decoration: none;
}
.return-to-frontpage a:hover,
.return-to-frontpage a:focus-visible {
  text-decoration: underline;
  text-underline-offset: 0.15em;
}
.weather-source {
  margin: 0.75rem 0 0;
}
.weather-empty {
  margin-top: 0.5rem;
}
.history-page {
  width: 100%;
  max-width: none;
}
.history-page-header {
  margin-bottom: 1rem;
}
.history-title {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.35rem 0.85rem;
  margin: 0;
}
.history-title-date {
  font-family: var(--font-ui);
  font-size: 0.72em;
  font-weight: 600;
  color: var(--ink-muted, #4a5752);
}
.history-event-list {
  margin: 0;
  padding: 1rem 1.25rem;
  list-style: none;
  width: 100%;
}
.history-event {
  display: flex;
  align-items: baseline;
  gap: 0.65rem 1rem;
  width: 100%;
  padding: 0.7rem 0;
  border-bottom: 1px solid color-mix(in srgb, var(--moss-deep, #2f4a3f) 12%, transparent);
  font-family: var(--font-ui);
  font-size: 0.98rem;
  line-height: 1.45;
}
.history-event:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}
.history-event:first-child {
  padding-top: 0;
}
.history-event-year {
  flex: 0 0 auto;
  min-width: 3.5rem;
  font-weight: 700;
  color: var(--moss-deep);
  font-variant-numeric: tabular-nums;
}
.history-event-text {
  flex: 1 1 auto;
  min-width: 0;
  color: var(--ink, #1c2421);
}
.history-source {
  margin: 0.75rem 0 0;
}
.history-empty {
  margin-top: 0.5rem;
}
@media (max-width: 520px) {
  .history-event {
    flex-wrap: wrap;
    gap: 0.2rem 0.75rem;
  }
  .history-event-year {
    min-width: 0;
  }
  .history-event-text {
    flex-basis: 100%;
  }
}

.happening-today-page {
  width: 100%;
  max-width: none;
}
.happening-today-header {
  margin-bottom: 1rem;
}
.happening-today-title {
  margin: 0 0 0.5rem;
}
.happening-today-day-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: center;
  gap: 0.75rem 1.5rem;
  font-family: var(--font-ui);
  font-size: 0.95rem;
  font-weight: 600;
}
.happening-today-day-nav a {
  color: var(--ink, #1c2421);
  text-decoration: none;
  flex-shrink: 0;
}
.happening-today-day-nav a:hover {
  text-decoration: underline;
}
.happening-today-day-nav-date {
  min-width: 12rem;
  text-align: center;
  font-size: 1.35rem;
  font-weight: 700;
  line-height: 1.2;
}
.happening-today-empty {
  margin-top: 0.5rem;
}
.happening-today-list {
  margin: 0;
  padding: 0.5rem 0;
  list-style: none;
}
.happening-today-item {
  border-bottom: 1px solid var(--rule, rgba(28, 36, 33, 0.12));
}
.happening-today-item:last-child {
  border-bottom: 0;
}
.happening-today-item-link {
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
  padding: 0.85rem 1.25rem;
  color: inherit;
  text-decoration: none;
}
.happening-today-item-link:hover {
  background: rgba(28, 36, 33, 0.04);
}
.happening-today-thumb {
  flex: 0 0 3.5rem;
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 0.35rem;
  overflow: hidden;
  background: rgba(28, 36, 33, 0.06);
}
.happening-today-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.happening-today-item-body {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  min-width: 0;
  flex: 1 1 auto;
}
.happening-today-item-name {
  font-weight: 700;
  line-height: 1.25;
}
.happening-today-item-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.2rem 0.75rem;
  font-family: var(--font-ui);
  font-size: 0.85rem;
  font-weight: 600;
}
.happening-today-item-section {
  color: var(--accent, #2f5d50);
}
.happening-today-item-desc {
  font-size: 0.9rem;
  line-height: 1.35;
}
@media (max-width: 520px) {
  .happening-today-item-link {
    padding: 0.75rem 1rem;
  }
  .happening-today-thumb {
    flex-basis: 2.75rem;
    width: 2.75rem;
    height: 2.75rem;
  }
}

@media (max-width: 1100px) {
  .weather-forecast {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}
@media (max-width: 900px) {
  .weather-forecast {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 520px) {
  .weather-forecast {
    grid-template-columns: 1fr;
  }
  .weather-sponsor {
    width: 100%;
    margin-left: 0;
    text-align: left;
  }
  .weather-sponsor-image {
    max-width: 100%;
  }
}
.calendar-page-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  margin-bottom: 0.85rem;
}
.calendar-title {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 3vw, 2.3rem);
}
.calendar-toolbar {
  display: flex;
  flex-direction: column;
  flex-wrap: nowrap;
  align-items: flex-end;
  justify-content: flex-start;
  gap: 0.35rem;
  margin-left: auto;
}
.calendar-month-label {
  margin: 0;
  text-align: right;
  font-family: var(--font-display);
  font-size: 1.35rem;
  white-space: nowrap;
}
.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
  min-height: calc(100vh - 12rem);
}
.calendar-weekday {
  background: rgba(31, 92, 77, 0.1);
  padding: 0.55rem 0.4rem;
  text-align: center;
  font-family: var(--font-ui);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: rgba(26, 36, 33, 0.7);
}
.calendar-day {
  background: rgba(255, 253, 248, 0.96);
  min-height: 7.5rem;
  padding: 0.4rem 0.45rem 0.55rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}
.calendar-day.is-empty {
  background: rgba(243, 239, 230, 0.55);
}
.calendar-day.is-today {
  box-shadow: inset 0 0 0 2px var(--moss);
}
.calendar-day-number {
  font-family: var(--font-ui);
  font-weight: 700;
  font-size: 0.85rem;
  color: rgba(26, 36, 33, 0.75);
}
.calendar-day-events {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  overflow: hidden;
}
.calendar-event-link {
  display: block;
  font-family: var(--font-ui);
  font-size: 0.72rem;
  font-weight: 600;
  line-height: 1.25;
  text-decoration: none;
  color: var(--moss-deep);
  background: rgba(31, 92, 77, 0.1);
  border-radius: 4px;
  padding: 0.18rem 0.3rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.calendar-event-link:hover {
  background: rgba(31, 92, 77, 0.18);
  color: var(--amber);
}
.calendar-event-link.has-section-color {
  background: var(--calendar-event-bg);
  color: var(--calendar-event-fg);
}
.calendar-event-link.has-section-color:hover {
  background: color-mix(in srgb, var(--calendar-event-bg) 88%, var(--ink));
  color: var(--calendar-event-fg);
}
.calendar-event-link.has-section-color .calendar-event-time {
  color: var(--calendar-event-fg);
  opacity: 0.72;
}
.calendar-event-time {
  color: rgba(26, 36, 33, 0.55);
  font-weight: 700;
  margin-right: 0.2rem;
}
.calendar-event-drawer-section {
  margin: 0.2rem 0 0;
}
.calendar-event-drawer-when {
  margin: 0;
}
.calendar-event-drawer-location {
  margin: 0.45rem 0 0;
}
.calendar-event-drawer-description {
  margin: 0.75rem 0 0;
  white-space: pre-wrap;
}
/* Formatted description HTML (article_html) — same as obituaries; do not pre-wrap. */
.calendar-event-drawer-description.has-html {
  white-space: normal;
}
.calendar-event-drawer-description.has-html a {
  pointer-events: auto;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.calendar-event-drawer-description.is-empty {
  color: rgba(26, 36, 33, 0.6);
}
.calendar-event-drawer-views {
  margin: 0.85rem 0 0;
}
.calendar-event-drawer-author {
  margin: 0.85rem 0 0;
}
.calendar-event-drawer-views + .calendar-event-drawer-author {
  margin-top: 0.35rem;
}
@media (max-width: 900px) {
  .calendar-grid {
    min-height: 0;
  }
  .calendar-day {
    min-height: 5.5rem;
  }
}

.articles-list-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.65rem 1rem;
  margin: 0 0 1rem;
}
.articles-list-toolbar .tabs {
  flex: 1 1 auto;
}
.tab-link {
  padding: 0.55rem 1rem;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.92rem;
  color: rgba(26, 36, 33, 0.72);
  text-decoration: none;
  transition: background 0.15s ease, color 0.15s ease;
}
.tab-link:hover {
  background: rgba(255, 255, 255, 0.75);
  color: var(--ink);
}
.tab-link.is-active {
  background: #fff;
  color: var(--ink);
  box-shadow: 0 1px 2px rgba(26, 36, 33, 0.08);
}
.articles-date-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  margin: 0;
}
.articles-date-filters select {
  min-width: 8.5rem;
  padding: 0.45rem 0.55rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  font-family: var(--font-ui);
  font-size: 0.88rem;
  color: var(--ink);
}
.articles-date-filters .articles-headline-search {
  width: 12rem;
  min-width: 9rem;
  max-width: 16rem;
  flex: 0 1 12rem;
  padding: 0.45rem 0.55rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  font-family: var(--font-ui);
  font-size: 0.88rem;
  color: var(--ink);
}
.articles-date-filters .btn-small {
  flex-shrink: 0;
  white-space: nowrap;
}

.story-photo-thumb-link {
  display: block;
  line-height: 0;
}
.story-photo-thumb {
  display: block;
  width: 4.5rem;
  height: 3.375rem;
  object-fit: cover;
  border-radius: 3px;
  background: rgba(26, 36, 33, 0.06);
}
.articles-table {
  table-layout: fixed;
}
.articles-table .articles-col-headline { width: auto; }
.articles-table.is-events .articles-col-headline { width: 50%; }
.articles-table .articles-col-section {
  width: 9rem;
  min-width: 7rem;
}
.articles-table .articles-section-cell {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.articles-table .articles-col-price { width: 4.5rem; }
.articles-table .articles-col-claimed,
.articles-table .articles-col-author { width: 8.5rem; min-width: 7rem; }
.articles-table .articles-col-status { width: 6.5rem; }
/* Event date/time is one line (e.g. "Sep 30, 2026 · 14:00–16:00"); keep room + nowrap. */
.articles-table .articles-col-event-date {
  width: 15.5rem;
  min-width: 15.5rem;
}
.articles-table .articles-col-created,
.articles-table .articles-col-published {
  width: 10.25rem;
  min-width: 10.25rem;
}
.articles-table.has-date-only-created .articles-col-created {
  width: 7.5rem;
  min-width: 7.5rem;
}
.articles-table.is-letters .articles-col-submitted { width: 14rem; min-width: 14rem; }
.articles-table.is-letters .articles-col-from { width: 11rem; min-width: 11rem; }
.articles-table.is-letters .articles-from-cell,
.articles-table.is-letters .articles-from-header {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.articles-table.is-letters .articles-submitted-cell,
.articles-table.is-letters .articles-submitted-header {
  overflow: visible;
  text-overflow: clip;
  white-space: nowrap;
}
.articles-table .articles-col-views,
.articles-table .articles-col-opens,
.articles-table .articles-col-paid { width: 3.25rem; }
.articles-table .articles-col-actions { width: 11.5rem; min-width: 11.5rem; }
.articles-table.has-pending-actions .articles-col-actions {
  width: 14.5rem;
  min-width: 14.5rem;
}
.articles-table .articles-price-cell,
.articles-table .articles-views-cell,
.articles-table .articles-opens-cell,
.articles-table .articles-paid-cell,
.articles-table th.articles-price-header,
.articles-table th.articles-views-header,
.articles-table th.articles-opens-header,
.articles-table th.articles-paid-header {
  text-align: center;
}
.articles-table .articles-claimed-cell,
.articles-table th.articles-claimed-header,
.articles-table .articles-author-cell,
.articles-table th.articles-author-header {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  vertical-align: top;
}
.articles-table .articles-claimed-cell,
.articles-table .articles-author-cell {
  color: rgba(26, 36, 33, 0.78);
  font-size: 0.92em;
}
.articles-table .articles-price-cell {
  vertical-align: top;
}
.articles-table .articles-actions-cell {
  display: table-cell;
  vertical-align: top;
  text-align: right;
  white-space: nowrap;
}
.articles-table .articles-actions-cell > a,
.articles-table .articles-actions-cell > form {
  display: inline-flex;
  vertical-align: top;
  margin: 0 0 0 0.35rem;
}
.articles-table .articles-actions-cell > a:first-child,
.articles-table .articles-actions-cell > form:first-child {
  margin-left: 0;
}
.articles-table .articles-actions-cell .btn-small {
  padding: 0.35rem 0.65rem;
  font-size: 0.78rem;
  white-space: nowrap;
}
.articles-table .articles-headline-cell {
  overflow: hidden;
  max-width: 0; /* force fixed-layout table to let this column take leftover + ellipsis */
}
.articles-table .articles-headline-link {
  display: block;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  line-height: 1.35;
}
.articles-table .articles-byline {
  overflow: hidden;
  margin-bottom: 0.35rem;
}
.articles-excerpt {
  margin-top: 0.35rem;
  overflow: auto;
}
.articles-excerpt::after {
  content: "";
  display: table;
  clear: both;
}
.articles-excerpt-photo {
  float: right;
  margin: 0 0 0.35rem 0.75rem;
}
.articles-excerpt-photo .story-photo-thumb {
  width: 4.5rem;
  height: 3.375rem;
}
.articles-excerpt-text {
  margin: 0;
  font-size: 0.88rem;
  line-height: 1.35;
  color: rgba(26, 36, 33, 0.78);
}
.articles-table .articles-date-cell,
.articles-table th.articles-date-header {
  font-size: inherit;
  line-height: 1.3;
  text-align: right;
  vertical-align: top;
  white-space: normal;
  overflow: visible;
  text-overflow: clip;
}
/* Match letters submitted / wallet activity datetime: one line, no wrap. */
.articles-table .articles-date-cell.articles-event-date-cell,
.articles-table th.articles-date-header.articles-event-date-header {
  overflow: visible;
  text-overflow: clip;
  white-space: nowrap;
}
.articles-table .articles-date-day,
.articles-table .articles-date-time {
  display: block;
  white-space: nowrap;
}
.articles-table .articles-date-time {
  color: rgba(26, 36, 33, 0.72);
  font-size: 0.92em;
}
.articles-table .articles-price-cell,
.articles-table .articles-views-cell,
.articles-table .articles-opens-cell,
.articles-table .articles-paid-cell,
.articles-table th.articles-price-header,
.articles-table th.articles-views-header,
.articles-table th.articles-opens-header,
.articles-table th.articles-paid-header {
  text-align: center;
}
.story-photo {
  margin: 0 0 1.25rem;
}
.story-photo img,
.story-photo-preview img,
.photo-carousel--full .photo-carousel-slide img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 12px;
  border: 1px solid var(--line);
}
/* Article reading view (public + in-app): photo floats top-right; body copy wraps */
.story-view .story-photo {
  float: right;
  width: min(calc(100% - 1.25rem), 28rem);
  max-width: 100%;
  margin: 0 0 1rem 1.25rem;
}
.story-view .story-photo img,
.story-view .photo-carousel--full .photo-carousel-slide img {
  border: 1px solid rgba(26, 36, 33, 0.35);
}
.story-view .story-body::after {
  content: "";
  display: table;
  clear: both;
}
.story-photo-preview {
  margin-top: 0.25rem;
}

.photo-carousel {
  position: relative;
  max-width: 100%;
}
.photo-carousel-viewport {
  position: relative;
}
.photo-carousel-slide {
  margin: 0;
}
.photo-carousel-slide[hidden] {
  display: none !important;
}
.photo-carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 5;
  width: 2.75rem;
  height: 2.75rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 253, 248, 0.96);
  color: var(--ink);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  box-shadow: 0 1px 4px rgba(26, 36, 33, 0.12);
  pointer-events: auto;
  -webkit-tap-highlight-color: transparent;
}
.photo-carousel-btn:hover {
  background: #fff;
}
.photo-carousel-prev {
  left: 0.5rem;
}
.photo-carousel-next {
  right: 0.5rem;
}
.photo-carousel-counter {
  position: absolute;
  right: 0.5rem;
  bottom: 0.5rem;
  margin: 0;
  padding: 0.15rem 0.45rem;
  border-radius: 6px;
  background: rgba(26, 36, 33, 0.72);
  color: #fff;
  font-size: 0.75rem;
  font-family: var(--font-ui);
  line-height: 1.2;
}
.photo-carousel--thumb {
  width: 15rem;
}
.photo-carousel--thumb .photo-carousel-slide .story-photo-thumb {
  width: 15rem;
  height: 11.25rem;
  object-fit: contain;
  background: rgba(26, 36, 33, 0.04);
}
.photo-carousel--thumb .photo-carousel-btn {
  width: 2.25rem;
  height: 2.25rem;
  font-size: 1.2rem;
}
.photo-carousel--thumb .photo-carousel-counter {
  font-size: 0.7rem;
}
.articles-excerpt-photo .photo-carousel--thumb {
  width: auto;
}
.articles-excerpt-photo .photo-carousel--thumb .photo-carousel-slide .story-photo-thumb {
  width: 4.5rem;
  height: 3.375rem;
}

.story-photo-manage-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}
.story-photo-manage-item {
  width: 7.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}
.story-photo-manage-item img {
  display: block;
  width: 7.5rem;
  height: 5.625rem;
  object-fit: contain;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: rgba(26, 36, 33, 0.04);
}

th, td {
  text-align: left;
  padding: 0.7rem 0.5rem;
  border-bottom: 1px solid var(--line);
}
th { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.04em; color: rgba(26,36,33,0.6); }

.letter-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  gap: 0.15rem 0;
  margin: 0 0 0.85rem;
  padding: 0.55rem 0.35rem;
  background: rgba(255, 253, 248, 0.92);
  border: 1px solid var(--line);
  border-radius: 12px;
  font-family: var(--font-ui);
  box-sizing: border-box;
}
.letter-bar-item {
  flex: 1 1 0;
  min-width: 1.35rem;
  height: 1.7rem;
  padding: 0 0.2rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.82rem;
  color: var(--ink);
  line-height: 1;
  text-align: center;
}
.letter-bar-item:hover {
  background: rgba(31, 92, 77, 0.12);
  color: var(--moss-deep);
}
.letter-bar-item.is-active {
  background: var(--moss);
  color: #fffdf8;
}
.letter-bar-item.is-active:hover {
  background: var(--moss-deep);
  color: #fffdf8;
}
.letter-bar-item.is-disabled {
  color: rgba(26, 36, 33, 0.28);
  cursor: default;
  font-weight: 600;
}

.sortable-th {
  white-space: nowrap;
}
.sortable-th-link {
  color: inherit;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
}
.sortable-th-link:hover {
  color: var(--moss-deep);
  text-decoration: underline;
}
.sortable-th.is-sorted .sortable-th-link::after {
  content: '▲';
  font-size: 0.65rem;
  opacity: 0.75;
}

.flash {
  margin: 1rem auto 0;
  padding: 0.85rem 1rem;
  border-radius: 12px;
  font-weight: 600;
}
.flash-bottom {
  position: sticky;
  bottom: 0;
  z-index: 40;
  margin: 0 auto;
  border-radius: 0;
  box-shadow: 0 -4px 18px rgba(26, 36, 33, 0.08);
}
.flash-bottom.wrap,
.flash-bottom.wrap-full {
  width: 100%;
  max-width: none;
  box-sizing: border-box;
}
.flash-success { background: #dff3ea; color: #14553f; }
.flash-error { background: #fde2e0; color: #7a1f1a; }

.layout-split {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: 2fr 1fr;
}
.story-body {
  font-size: 1.08rem;
  line-height: 1.7;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
}
.story-body p { margin: 0 0 1rem; }
.story-body table,
.article-editor table {
  width: 100%;
  max-width: 100%;
  border-collapse: collapse;
  margin: 0 0 1rem;
  font-size: 0.98em;
}
.story-body th,
.story-body td,
.article-editor th,
.article-editor td {
  border: 1px solid var(--line);
  padding: 0.45rem 0.65rem;
  text-align: left;
  vertical-align: top;
}
.story-body th,
.article-editor th {
  font-weight: 700;
  background: rgba(26, 36, 33, 0.04);
}
.story-body thead th,
.article-editor thead th {
  border-bottom-width: 2px;
}

/* Article view: sticky meta/headline; only body content scrolls */
.story-view {
  display: flex;
  flex-direction: column;
  min-height: 0;
  flex: 1 1 auto;
}
.story-view-header {
  flex: 0 0 auto;
  position: sticky;
  top: 0;
  z-index: 8;
  margin: 0 0 0.15rem;
  padding: 0 0 0.75rem;
  background:
    linear-gradient(180deg, rgba(247, 243, 234, 0.98) 0%, rgba(243, 239, 230, 0.96) 75%, rgba(243, 239, 230, 0.9) 100%);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.story-view-content {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  padding: 1rem 0 1.5rem;
}
.story-view-title {
  margin: 0 0 0.35rem;
  font-family: var(--font-display);
  font-size: clamp(1.55rem, 3vw, 2.2rem);
  line-height: 1.15;
}
.home-main:has(.story-view) {
  display: flex;
  flex-direction: column;
  max-height: calc(100vh - 4.25rem);
  overflow: hidden;
  padding-bottom: 0.75rem;
}
.home-main:has(.story-view) .home-main-inner {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.home-main:has(.story-view) .story-view-header {
  top: 0;
}
.body-public-story {
  display: flex;
  flex-direction: column;
  height: 100vh;
  height: 100dvh;
  max-height: 100vh;
  max-height: 100dvh;
  overflow: hidden;
}
.body-public-story .public-story-header {
  flex: 0 0 auto;
}
.body-public-story .public-story-main {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  padding: 0;
}
.body-public-story .public-story-main .story-view {
  /* Flex-shrink chain so .story-view-content can scroll (not height:100% + .section padding). */
  flex: 1 1 auto;
  min-height: 0;
  max-height: 100%;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  max-width: min(1100px, calc(100% - 2rem));
  width: calc(100% - 2rem);
  margin-inline: auto;
  padding: 0.75rem 0 0;
}
.body-public-story .story-view-content {
  flex: 1 1 auto;
  min-height: 0;
  overflow-x: hidden;
  overflow-y: scroll; /* dedicated scrollport so shared stories scroll on iOS/Android */
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
}
.body-public-story .story-view-header {
  flex: 0 0 auto;
  background:
    linear-gradient(180deg, rgba(247, 243, 234, 0.98) 0%, rgba(243, 239, 230, 0.96) 80%, rgba(243, 239, 230, 0.92) 100%);
}
.body-public-story .public-story-footer {
  flex: 0 0 auto;
  margin-top: 0;
  padding-top: 0.75rem;
  padding-bottom: 0.75rem;
}
.body-public-story .public-story-cta {
  margin: 1.25rem 0 0.5rem;
}

/* Shared-link / guest story: keep site brand clear, compress chrome so article can scroll */
body.is-mobile.body-public-story .public-story-header-inner {
  padding: 0.55rem 0 0.65rem;
}
body.is-mobile.body-public-story .public-story-site-brand {
  gap: 0.65rem;
  margin-bottom: 0.45rem;
}
body.is-mobile.body-public-story .public-story-site-logo {
  width: 56px;
  height: 56px;
  flex-basis: 56px;
  border-radius: 8px;
}
body.is-mobile.body-public-story .public-story-site-name {
  font-size: clamp(1.45rem, 6.5vw, 1.85rem);
}
body.is-mobile.body-public-story .public-story-site-tagline {
  display: none; /* save vertical space; name + logo carry the brand */
}
body.is-mobile.body-public-story .public-story-header-row {
  gap: 0.4rem 0.65rem;
}
body.is-mobile.body-public-story .public-story-brand {
  font-size: 1.2rem;
}
body.is-mobile.body-public-story .public-story-nav {
  gap: 0.35rem;
}
body.is-mobile.body-public-story .public-story-nav .btn {
  padding: 0.35rem 0.65rem;
  font-size: 0.82rem;
}
body.is-mobile.body-public-story .public-story-promo {
  margin: 0;
  font-size: 0.8rem;
  line-height: 1.35;
}
body.is-mobile.body-public-story .public-story-main .story-view {
  padding: 0.45rem 0 0;
  width: calc(100% - 1.25rem);
  max-width: calc(100% - 1.25rem);
}
body.is-mobile.body-public-story .story-view-header {
  padding: 0 0 0.45rem;
  margin-bottom: 0;
}
body.is-mobile.body-public-story .story-view-title {
  font-size: clamp(1.25rem, 5.5vw, 1.55rem);
  margin-bottom: 0.2rem;
}
body.is-mobile.body-public-story .story-view-summary {
  margin: 0.2rem 0 0.45rem;
  font-size: 0.95rem;
  line-height: 1.4;
}
body.is-mobile.body-public-story .story-view-meta,
body.is-mobile.body-public-story .story-view-dates {
  margin-bottom: 0.4rem;
}
body.is-mobile.body-public-story .story-view-content {
  padding: 0.55rem 0 0.85rem;
}
body.is-mobile.body-public-story .story-body {
  font-size: 1.02rem;
  line-height: 1.6;
}
body.is-mobile.body-public-story .public-story-cta {
  margin: 0.85rem 0 0.25rem;
}
body.is-mobile.body-public-story .public-story-cta-panel {
  padding: 0.85rem 0.95rem;
}
body.is-mobile.body-public-story .public-story-cta-panel h2 {
  font-size: 1.2rem;
  margin-bottom: 0.3rem;
}
body.is-mobile.body-public-story .public-story-cta-panel p {
  margin-bottom: 0.65rem;
  font-size: 0.92rem;
}
body.is-mobile.body-public-story .public-story-footer {
  padding-top: 0.4rem;
  padding-bottom: 0.4rem;
}
body.is-mobile.body-public-story .public-story-footer p {
  margin: 0.1rem 0;
  font-size: 0.78rem;
  line-height: 1.35;
}
.story-view-meta {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 0.75rem 1rem;
  margin: 0 0 0.5rem;
  width: 100%;
}
.story-view-meta-left {
  min-width: 0;
}
.story-view-meta .badge,
.story-view-meta .story-front-page-form,
.story-view-meta .story-view-section {
  justify-self: end;
  align-self: start;
  flex-shrink: 0;
}
.story-view-meta .story-front-page-form {
  margin: 0;
}
.story-placement-flags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.85rem;
  justify-content: flex-end;
  align-items: center;
}
.story-view-headline {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  margin: 0 0 0.5rem;
}
.story-view-headline h2 {
  margin: 0;
  min-width: 0;
  flex: 1 1 auto;
}
.story-view-summary {
  margin: 0.35rem 0 0.75rem;
}
.story-view-dates {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  margin: 0 0 0.75rem;
}
.story-view-dates-left {
  min-width: 0;
}
.story-view-reads {
  flex-shrink: 0;
}
.story-view-reads-group {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin-left: auto;
  flex-shrink: 0;
}
.story-share-icons {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
}
.story-share-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.7rem;
  height: 1.7rem;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: rgba(26, 36, 33, 0.62);
  cursor: pointer;
  text-decoration: none;
  transition: color 0.15s ease, background-color 0.15s ease;
}
.story-share-icon:hover,
.story-share-icon:focus-visible {
  color: var(--moss-deep);
  background: rgba(31, 92, 77, 0.1);
  outline: none;
}
.story-share-facebook:hover,
.story-share-facebook:focus-visible {
  color: #1877f2;
  background: rgba(24, 119, 242, 0.12);
}
.story-share-icon.is-copied {
  color: var(--moss);
}
.story-share-icon svg {
  display: block;
}
.copy-link-notice {
  position: fixed;
  left: 50%;
  bottom: 1.25rem;
  transform: translateX(-50%);
  z-index: 60;
  max-width: min(28rem, calc(100% - 2rem));
  padding: 0.75rem 1.1rem;
  border-radius: 12px;
  background: #dff3ea;
  color: #14553f;
  font-family: var(--font-ui);
  font-size: 0.95rem;
  font-weight: 600;
  box-shadow: 0 8px 24px rgba(26, 36, 33, 0.16);
  text-align: center;
}
.copy-link-notice.is-error {
  background: #fde2e0;
  color: #7a1f1a;
}
.copy-link-notice[hidden] {
  display: none;
}
.story-view-headline .story-placement-form {
  display: flex;
  align-items: flex-end;
  flex-shrink: 0;
  margin: 0;
  margin-top: 0.15rem;
}
.story-front-page-check {
  margin: 0;
  white-space: nowrap;
}
.tag-sticky {
  background: rgba(31, 92, 77, 0.14);
  color: var(--moss-deep);
  font-weight: 700;
}
.story-sections-select select {
  min-width: 9rem;
  max-width: 14rem;
  padding: 0.35rem 0.65rem;
  font-family: var(--font-ui);
  font-size: 0.85rem;
  font-weight: 600;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: #fff;
}
.story-sections-select select:disabled {
  opacity: 0.65;
}
.paywall {
  border: 1px dashed var(--amber);
  background: linear-gradient(180deg, #fff7ef, #fff);
  border-radius: var(--radius);
  padding: 1.25rem;
}
.paywall-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 0.65rem;
  margin-top: 1rem;
}
.paywall-actions form {
  margin: 0;
}
.article-compose-panels {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.article-compose-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.45rem 1rem;
  width: 100%;
}
.article-compose-tabs {
  flex: 0 1 auto;
  width: fit-content;
  max-width: 100%;
}
.article-compose-placement-flags {
  flex: 0 0 auto;
  margin-left: auto;
}
@media (max-width: 640px) {
  .article-compose-toolbar {
    align-items: stretch;
  }
  .article-compose-placement-flags {
    width: 100%;
    margin-left: 0;
    justify-content: flex-end;
  }
}
.article-compose-tabs .tab-link {
  border: 0;
  background: transparent;
  cursor: pointer;
  font: inherit;
  font-family: var(--font-ui);
}
.article-compose-tabs .tab-link.is-active {
  background: #fff;
  color: var(--ink);
  box-shadow: 0 1px 2px rgba(26, 36, 33, 0.08);
}
.article-compose-panel[hidden] {
  display: none !important;
}
.article-notes-hint {
  margin: 0 0 0.55rem;
}
.article-notes-editor {
  display: block;
  width: 100%;
  min-height: 220px;
  padding: 0.85rem 1rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  line-height: 1.55;
  font: inherit;
  font-family: var(--font-body);
  resize: vertical;
}
.article-notes-editor:focus {
  outline: 2px solid rgba(31, 92, 77, 0.35);
  outline-offset: 1px;
}
.article-editor-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin: 0 0 1rem;
  padding: 0.65rem 0;
  position: sticky;
  /* Under sticky .site-header (top:0, z-index:20) — same offset as .home-main-header */
  top: 3.75rem;
  /* Below .site-header so scrolled chrome never covers the main nav */
  z-index: 15;
  background:
    linear-gradient(180deg, rgba(247, 243, 234, 0.98) 0%, rgba(247, 243, 234, 0.96) 70%, rgba(247, 243, 234, 0.88) 100%);
  backdrop-filter: blur(6px);
}
.article-editor-header-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 0.5rem;
  flex: 0 0 auto;
  margin-left: auto;
}
.article-full-edit-window {
  margin: 0 0 0.85rem;
  padding: 0.7rem 0.9rem;
  border: 1px solid rgba(26, 36, 33, 0.14);
  border-left: 3px solid #2f6f4e;
  background: rgba(215, 240, 227, 0.45);
}
/* Editor's Desk → Published: same green while 24h full-edit window remains. */
.articles-table tr.article-full-edit-window-row > td {
  background: rgba(215, 240, 227, 0.45);
}
.articles-table tr.article-full-edit-window-row > td:first-child {
  box-shadow: inset 3px 0 0 #2f6f4e;
}
.article-full-edit-window.is-expired {
  border-left-color: #8a5a3a;
  background: rgba(255, 247, 239, 0.9);
}
.article-full-edit-window-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.35rem 0.85rem;
  margin: 0;
}
.article-full-edit-window-ends {
  flex: 1 1 10rem;
  min-width: 0;
}
.article-full-edit-window-timer {
  flex: 0 0 auto;
  margin-left: auto;
  font-size: inherit;
  font-weight: inherit;
  letter-spacing: 0.02em;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  color: inherit;
}
.article-full-edit-window-expired {
  flex: 1 1 10rem;
  min-width: 0;
  font-weight: 600;
  color: #8a5a3a;
}
.article-editor-header-actions .btn {
  white-space: nowrap;
}
.article-editor-header-actions .article-header-inline-form {
  display: inline;
  margin: 0;
}
.article-status-control select {
  min-width: 9.5rem;
  font-weight: 700;
}
.article-status-badge {
  align-self: flex-start;
  font-size: 0.9rem;
  padding: 0.55rem 0.9rem;
}
.article-editor-stats {
  margin-top: 1.25rem;
}
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.stat-row {
  display: flex; flex-wrap: wrap; gap: 1rem;
}
.stat {
  flex: 1 1 140px;
  background: var(--paper-deep);
  border-radius: 12px;
  padding: 1rem;
  font-family: var(--font-ui);
}
.stat strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.6rem;
}
.deposit-steps {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
  list-style: none;
  padding: 0;
  margin: 0 0 1.25rem;
  font-family: var(--font-ui);
  font-size: 0.95rem;
}
.deposit-step {
  color: var(--muted);
}
.deposit-step.is-complete {
  color: var(--moss-deep);
  font-weight: 600;
}
.deposit-step.is-complete::before {
  content: "✓ ";
}
.deposit-step.is-current {
  color: var(--ink);
  font-weight: 700;
}
.deposit-summary-amount {
  font-family: var(--font-display);
  font-size: 2rem;
  margin: 0.25rem 0 0.75rem;
  color: var(--moss-deep);
}
.deposit-fee-table {
  width: 100%;
  border-collapse: collapse;
  font-family: var(--font-ui);
  font-size: 0.95rem;
}
.deposit-fee-table td,
.deposit-fee-table th {
  padding: 0.35rem 0;
  border-top: 1px solid var(--line);
}
.deposit-fee-table td:last-child,
.deposit-fee-table th:last-child {
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.deposit-help-list {
  margin: 0 0 1rem;
  padding-left: 1.25rem;
}
.accounting-tabs {
  margin-top: 0.25rem;
}
.login-graph {
  margin-top: 0.75rem;
}
.login-graph-bars {
  display: flex;
  align-items: stretch;
  gap: 0.55rem;
  height: 260px;
  padding: 0.5rem 0 0;
  border-bottom: 1px solid var(--line);
}
.login-graph-day {
  flex: 1 1 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  min-width: 0;
  height: 100%;
  text-decoration: none;
  color: inherit;
  background: transparent;
  border: 0;
  padding: 0;
  cursor: pointer;
  font: inherit;
}
a.login-graph-day:hover .login-graph-stack:not(.is-empty),
button.login-graph-day:hover .login-graph-stack:not(.is-empty) {
  filter: brightness(0.92);
}
.login-graph-day.is-selected .login-graph-label,
.login-graph-day.is-selected .login-graph-count {
  color: var(--moss-deep);
  font-weight: 700;
}
.login-graph-day.is-selected .login-graph-stack:not(.is-empty) {
  outline: 2px solid var(--moss-deep);
  outline-offset: 1px;
}
.login-graph-track {
  flex: 1 1 auto;
  width: 100%;
  min-height: 0;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}
.login-graph-stack {
  width: 100%;
  max-width: 42px;
  height: var(--bar-height, 0%);
  min-height: 0;
  display: flex;
  flex-direction: column-reverse;
  border-radius: 6px 6px 2px 2px;
  overflow: hidden;
  background: rgba(26, 36, 33, 0.06);
  align-self: flex-end;
}
.login-graph-stack:not(.is-empty) {
  min-height: 4px;
}
.login-graph-seg {
  width: 100%;
  min-height: 3px;
  flex-grow: 0;
  flex-shrink: 0;
}
.login-graph-seg-single {
  flex: 1 1 auto;
  background: var(--moss);
  min-height: 100%;
}
.login-graph-empty {
  flex: 1;
  background: transparent;
}
.login-graph-label,
.login-graph-count {
  font-family: var(--font-ui);
  font-size: 0.72rem;
  color: rgba(26, 36, 33, 0.65);
  text-align: center;
  line-height: 1.1;
}
.login-graph-count {
  font-weight: 700;
  color: var(--ink);
}
.login-graph-legend {
  list-style: none;
  margin: 1rem 0 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem 1.1rem;
  font-family: var(--font-ui);
  font-size: 0.85rem;
}
.login-graph-legend li {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}
.login-graph-swatch {
  width: 0.75rem;
  height: 0.75rem;
  border-radius: 2px;
  display: inline-block;
}
.ad-slot {
  border-left: 3px solid var(--amber);
  padding: 0.75rem 0.9rem;
  background: #fff8f1;
  border-radius: 0 10px 10px 0;
  margin-bottom: 0.75rem;
}
/* Keep full highlight frame after generic .ad-slot border-left. */
.home-ads .ad-slot.promo-slot--highlighted {
  border: 2px solid var(--ink);
  border-left: 2px solid var(--ink);
  padding: 0.55rem;
  background: rgba(255, 255, 255, 0.55);
  border-radius: 10px;
}
.inline { display: inline; }
.linkish {
  background: none; border: 0; color: var(--ink); font: inherit; font-weight: 600; cursor: pointer; padding: 0;
}
.linkish:hover { color: var(--moss); }
.actions { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: center; }
/* Bottom-of-screen form / panel action rows — right-aligned sitewide */
.form-actions,
.button-row,
.actions.form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  justify-content: flex-end;
}
.site-option-row {
  display: grid;
  grid-template-columns: minmax(10rem, 1.2fr) minmax(9rem, 12rem) minmax(8rem, 10rem);
  gap: 0.75rem 1.25rem;
  align-items: end;
  border: 0;
  margin: 0 0 1.15rem;
  padding: 0 0 1.15rem;
  border-bottom: 1px solid rgba(26, 36, 33, 0.1);
}
.site-option-row--toggle-only {
  grid-template-columns: 1fr;
  align-items: center;
}
.site-option-row--use-only {
  grid-template-columns: 1fr auto;
  align-items: center;
}
.site-option-row--has-site-cost.site-option-row--no-use {
  grid-template-columns: minmax(10rem, 1fr) minmax(12rem, 16rem);
}
.site-option-row:last-of-type {
  margin-bottom: 0.5rem;
  padding-bottom: 0;
  border-bottom: 0;
}
.site-option-toggle {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  font-weight: 600;
  font-size: 1rem;
}
.site-option-toggle input {
  width: 1.05rem;
  height: 1.05rem;
}
.site-option-price {
  display: grid;
  gap: 0.35rem;
  font-weight: 600;
  font-size: 0.92rem;
}
.site-option-price.is-disabled {
  opacity: 0.45;
}
.site-option-price input {
  width: 100%;
}
.site-option-use-charge {
  display: grid;
  gap: 0.2rem;
  justify-items: end;
  text-align: right;
  font-weight: 600;
  font-size: 0.92rem;
}
.site-option-use-charge.is-disabled {
  opacity: 0.45;
}
.site-option-use-charge__label {
  font-size: 0.8rem;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--muted, #5c6b66);
  font-weight: 600;
}
.site-option-use-charge__amount {
  font-size: 1.05rem;
  font-weight: 650;
}
.site-option-total {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.75rem 1.25rem;
  margin: 1.25rem 0 0;
  padding-top: 1rem;
  border-top: 1px solid rgba(26, 36, 33, 0.14);
}
.site-option-total__label {
  font-weight: 700;
  font-size: 1.05rem;
}
.site-option-total__amount {
  margin-left: auto;
  text-align: right;
  font-size: 1.2rem;
  font-weight: 700;
}
@media (max-width: 640px) {
  .site-option-row,
  .site-option-row--use-only,
  .site-option-row--has-site-cost.site-option-row--no-use {
    grid-template-columns: 1fr;
  }
  .site-option-use-charge {
    justify-items: start;
    text-align: left;
  }
}
.disk-usage-panel {
  margin-bottom: 1.25rem;
}
.disk-usage-panel--over {
  border-color: rgba(160, 60, 40, 0.35);
  background: linear-gradient(180deg, rgba(180, 70, 45, 0.06), transparent 70%);
}
.disk-usage-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(7.5rem, 1fr));
  gap: 0.75rem 1.25rem;
  margin: 0 0 0.85rem;
}
.disk-usage-stats--plan-price {
  grid-template-columns: 1fr auto;
  align-items: end;
}
.disk-usage-stats--plan-price .disk-usage-stats__plan {
  justify-self: start;
  text-align: left;
}
.disk-usage-stats--plan-price .disk-usage-stats__price {
  justify-self: end;
  text-align: right;
}
.disk-usage-plan-select {
  display: block;
  width: min(100%, 22rem);
  max-width: 100%;
  margin-top: 0.15rem;
  font: inherit;
  font-size: 1rem;
  font-weight: 650;
}
.disk-usage-stats--usage {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.disk-usage-bar.is-hidden,
.disk-usage-warning.is-hidden {
  display: none;
}
.disk-usage-stats dt {
  margin: 0;
  font-size: 0.8rem;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--muted, #5c6b66);
}
.disk-usage-stats dd {
  margin: 0.15rem 0 0;
  font-size: 1.15rem;
  font-weight: 650;
}
@media (max-width: 640px) {
  .disk-usage-stats--usage {
    grid-template-columns: 1fr 1fr;
  }
}
.disk-usage-bar {
  height: 0.55rem;
  border-radius: 999px;
  background: rgba(26, 36, 33, 0.1);
  overflow: hidden;
  margin-bottom: 0.75rem;
}
.disk-usage-bar__fill {
  display: block;
  height: 100%;
  background: #2f6f5e;
  border-radius: inherit;
}
.disk-usage-panel--over .disk-usage-bar__fill {
  background: #a33c28;
}
.disk-usage-warning {
  margin: 0 0 0.75rem;
  color: #8a2f1f;
  font-weight: 600;
}
table td.actions {
  display: table-cell;
  vertical-align: top;
  text-align: right;
  white-space: nowrap;
}
table td.actions > a,
table td.actions > form {
  display: inline-flex;
  vertical-align: top;
  margin: 0 0 0 0.35rem;
}
table td.actions > a:first-child,
table td.actions > form:first-child {
  margin-left: 0;
}
table td.actions .btn-small {
  white-space: nowrap;
}
.badge {
  display: inline-block;
  padding: 0.15rem 0.55rem;
  border-radius: 999px;
  background: var(--paper-deep);
  font-family: var(--font-ui);
  font-size: 0.78rem;
  font-weight: 700;
}
.badge-pending { background: #ffe7c2; }
.badge-approved { background: #d7f0e3; }
.badge-rejected { background: #f7d4d1; }
.badge-draft { background: #e6e6e6; }
.badge-creating { background: #e6e6e6; }
.badge-completed { background: #ffe7c2; }
.badge-published { background: #d7f0e3; }

.tag {
  display: inline-block;
  padding: 0.12rem 0.5rem;
  margin: 0.1rem 0.15rem 0.1rem 0;
  border-radius: 6px;
  background: rgba(31, 92, 77, 0.12);
  font-family: var(--font-ui);
  font-size: 0.78rem;
  font-weight: 600;
}
.tag-picker legend { font-family: var(--font-ui); font-weight: 700; }
.tag-options { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.tag-check {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.35rem 0.65rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: 0.9rem;
}
.article-editor-shell {
  display: flex;
  flex-direction: column;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  overflow: hidden;
}
.article-editor-shell .editor-toolbar {
  flex: 0 0 auto;
  z-index: 2;
  margin: 0;
  padding: 0.45rem 0.55rem;
  border-bottom: 1px solid var(--line);
  background: #f7f3ea;
}
.article-editor-scroll {
  flex: 1 1 auto;
  min-height: 14rem;
  max-height: min(55vh, 32rem);
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
}
.article-editor-shell .article-editor,
.article-editor-shell .article-editor-html {
  border: 0;
  border-radius: 0;
  min-height: 14rem;
}
.article-editor-shell .article-editor-html {
  width: 100%;
  resize: none;
  min-height: 100%;
}
.article-editor-shell.is-fullscreen {
  position: fixed;
  inset: 0.65rem;
  z-index: 90;
  max-height: none;
  height: calc(100vh - 1.3rem);
  box-shadow: var(--shadow);
}
.article-editor-shell.is-fullscreen .article-editor-scroll {
  max-height: none;
  flex: 1 1 auto;
  min-height: 0;
}
.article-editor-shell.is-fullscreen .article-editor,
.article-editor-shell.is-fullscreen .article-editor-html {
  min-height: 100%;
}
body.article-editor-fullscreen-open {
  overflow: hidden;
}
body.article-editor-fullscreen-open::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 85;
  background: rgba(26, 36, 33, 0.35);
  pointer-events: none;
}
.editor-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
  margin: 0.35rem 0;
}
.editor-toolbar-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
}
.editor-toolbar-end {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
  margin-left: auto;
}
.editor-toolbar-end .editor-toolbar-ai,
.editor-toolbar-end .editor-toolbar-size {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 8px;
  padding: 0.35rem 0.7rem;
  cursor: pointer;
  font: inherit;
  font-family: var(--font-ui);
  font-size: 0.82rem;
  font-weight: 700;
  color: rgba(26, 36, 33, 0.7);
  white-space: nowrap;
}
.editor-toolbar-end .editor-toolbar-ai:hover:not(:disabled):not([aria-disabled="true"]),
.editor-toolbar-end .editor-toolbar-size:hover {
  background: var(--paper-deep);
}
.editor-toolbar-end .editor-toolbar-size[aria-pressed="true"] {
  background: var(--moss);
  color: #fffdf8;
  border-color: var(--moss);
}
.editor-toolbar-end .editor-toolbar-size[aria-pressed="true"]:hover {
  background: var(--moss-deep);
  border-color: var(--moss-deep);
}
.editor-toolbar-end .editor-toolbar-ai:disabled,
.editor-toolbar-end .editor-toolbar-ai[aria-disabled="true"] {
  opacity: 0.45;
  cursor: not-allowed;
  color: rgba(26, 36, 33, 0.45);
}
.editor-mode-toggle {
  display: inline-flex;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
}
.editor-mode-toggle button {
  border: 0;
  border-radius: 0;
  background: transparent;
  padding: 0.35rem 0.7rem;
  cursor: pointer;
  font: inherit;
  font-family: var(--font-ui);
  font-size: 0.82rem;
  font-weight: 700;
  color: rgba(26, 36, 33, 0.7);
}
.editor-mode-toggle button + button {
  border-left: 1px solid var(--line);
}
.editor-mode-toggle button:hover {
  background: var(--paper-deep);
}
.editor-mode-toggle button.is-active {
  background: var(--moss);
  color: #fffdf8;
}
.editor-mode-toggle button.is-active:hover {
  background: var(--moss-deep);
}
.editor-toolbar-tools button {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 8px;
  padding: 0.35rem 0.65rem;
  cursor: pointer;
  font: inherit;
}
.editor-toolbar-tools button:hover { background: var(--paper-deep); }
.editor-toolbar-tools button:disabled {
  opacity: 0.45;
  cursor: default;
  background: #fff;
}
.editor-toolbar-tools button:disabled:hover {
  background: #fff;
}
.article-editor {
  min-height: 220px;
  padding: 0.85rem 1rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  line-height: 1.6;
}
.article-editor-html {
  display: block;
  width: 100%;
  min-height: 220px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.9rem;
  line-height: 1.45;
  resize: vertical;
  white-space: pre-wrap;
}
.article-editor[hidden],
.article-editor-html[hidden] {
  display: none !important;
}
.article-editor:focus,
.article-editor-html:focus {
  outline: 2px solid rgba(31, 92, 77, 0.35);
  outline-offset: 1px;
}
.article-body-empty-warning {
  margin: 0.55rem 0 0;
  padding: 0.55rem 0.75rem;
  border: 1px solid #c45c26;
  border-radius: 8px;
  background: #fff7ef;
  color: #8b2e2e;
  font-family: var(--font-ui);
  font-size: 0.92rem;
  font-weight: 700;
}
.article-body-with-ai {
  display: grid;
  gap: 0.85rem;
}
.article-body-with-ai.has-ai-assist:not(.ai-assist-collapsed) {
  grid-template-columns: minmax(0, 1fr) minmax(240px, 18rem);
  align-items: start;
}
.article-body-with-ai.ai-assist-collapsed {
  grid-template-columns: 1fr;
}
.article-ai-assist {
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--paper-deep);
  padding: 0.75rem 0.85rem 0.9rem;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  min-height: 280px;
  max-height: 36rem;
}
/* display:flex above overrides the UA [hidden] rule; Close must fully hide the panel */
.article-ai-assist[hidden] {
  display: none !important;
}
.article-ai-assist-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}
.article-ai-assist-title {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.15rem;
}
.article-ai-assist-intro {
  margin: 0;
}
.article-ai-assist-audio-hint {
  margin: 0.35rem 0 0;
}
.article-ai-prompt-helpers {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin: 0 0 0.55rem;
}
.article-ai-prompt-helpers .article-ai-btn {
  font-size: 0.8rem;
  padding: 0.25rem 0.55rem;
}
.article-ai-chat {
  flex: 1 1 auto;
  overflow: auto;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  min-height: 8rem;
  padding-right: 0.15rem;
}
.article-ai-msg {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}
.article-ai-bubble {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.55rem 0.7rem;
  font-size: 0.92rem;
  line-height: 1.45;
  white-space: normal;
  word-break: break-word;
}
.article-ai-msg--user .article-ai-bubble {
  background: rgba(31, 92, 77, 0.08);
  border-color: rgba(31, 92, 77, 0.25);
  align-self: flex-end;
  max-width: 95%;
}
.article-ai-msg--error .article-ai-bubble {
  border-color: #c45c26;
  background: #fff7ef;
  color: #8b2e2e;
}
.article-ai-msg-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}
.article-ai-compose {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}
.article-ai-compose textarea {
  width: 100%;
  resize: vertical;
  min-height: 4.5rem;
  font-family: var(--font-ui);
  font-size: 0.92rem;
}
.article-ai-compose-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem 0.85rem;
}
.article-ai-include-doc {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0.4rem;
  margin: 0;
  margin-right: auto;
  font-family: var(--font-ui);
  font-size: 0.88rem;
  font-weight: 600;
  color: rgba(26, 36, 33, 0.78);
  cursor: pointer;
  user-select: none;
}
.article-ai-include-doc.is-disabled {
  color: rgba(26, 36, 33, 0.42);
  cursor: not-allowed;
}
.article-ai-include-doc input {
  margin: 0;
}
.article-ai-include-doc input:disabled {
  cursor: not-allowed;
}
/* Compact square Ask AI actions — match editor toolbar controls, not pill .btn */
.article-ai-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--moss);
  color: #fffdf8;
  padding: 0.35rem 0.7rem;
  cursor: pointer;
  font: inherit;
  font-family: var(--font-ui);
  font-size: 0.82rem;
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none;
  white-space: nowrap;
}
.article-ai-btn:hover:not(:disabled) {
  background: var(--moss-deep);
  color: #fffdf8;
}
.article-ai-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
.article-ai-btn-secondary {
  background: #fff;
  color: rgba(26, 36, 33, 0.78);
}
.article-ai-btn-secondary:hover:not(:disabled) {
  background: var(--paper-deep);
  color: rgba(26, 36, 33, 0.9);
}
.article-ai-compose-actions .article-ai-btn {
  margin-left: auto;
}
@media (max-width: 960px) {
  .article-body-with-ai.has-ai-assist:not(.ai-assist-collapsed) {
    grid-template-columns: 1fr;
  }
  .article-ai-assist {
    max-height: none;
  }
}
.return-form {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
}

.site-footer {
  border-top: 1px solid var(--line);
  padding: 2rem 0 3rem;
  margin-top: 2rem;
  color: rgba(26,36,33,0.75);
}

@keyframes rise {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes fadein {
  from { opacity: 0; }
  to { opacity: 1; }
}

@media (max-width: 800px) {
  .form-grid, .layout-split { grid-template-columns: 1fr; }
  .form-grid .half { grid-column: 1 / -1; }
  .event-short-section-row,
  .event-name-section-row,
  .article-headline-section-row,
  .classified-header-category-row,
  .notice-date-type-row {
    flex-direction: column;
    align-items: stretch;
  }
  .notice-date-field,
  .notice-type-field {
    width: 100%;
    max-width: none;
    margin-left: 0;
  }
  .notice-type-field select {
    width: 100%;
    max-width: none;
  }
  .event-short-name-standalone,
  .event-short-name-standalone input,
  .event-short-name-field,
  .event-short-name-field input,
  .event-name-field,
  .event-name-field input,
  .article-headline-field,
  .article-headline-field input,
  .classified-header-field,
  .classified-header-field input {
    width: 100%;
    max-width: none;
    flex: 1 1 auto;
  }
  .event-datetime-row,
  .classified-run-dates-row,
  .classified-price-url-row,
  .classified-contact-info-row {
    grid-template-columns: 1fr;
  }
  .event-section-field,
  .article-section-field,
  .classified-category-field {
    margin-left: 0;
    width: 100%;
    flex: 1 1 auto;
  }
  .marketplace-title-row {
    flex-direction: column;
    align-items: stretch;
  }
  .marketplace-title-field,
  .marketplace-title-field input,
  .marketplace-section-field,
  .marketplace-price-field {
    width: 100%;
    max-width: none;
    flex: 1 1 auto;
    min-width: 0;
  }
  .section-form-title-row,
  .user-form-email-phone-row,
  .user-form-name-type-row,
  .profile-name-photo-row {
    grid-template-columns: 1fr;
  }
  .profile-photo-side {
    justify-items: center;
    text-align: center;
    width: 100%;
  }
  .profile-photo-remove {
    justify-content: center;
  }
  .user-form-type {
    justify-self: stretch;
    max-width: none;
    text-align: left;
  }
  .users-page-header-actions {
    width: 100%;
    margin-left: 0;
  }
  .user-search-form input[type="search"] {
    max-width: none;
  }
  .header-inner { flex-direction: column; align-items: flex-start; }
  .brand-logo {
    width: 56px;
    height: 56px;
    flex-basis: 56px;
  }
  .header-admin-scoreboard {
    order: 2;
    width: 100%;
    max-width: none;
    margin: 0.15rem 0;
    justify-content: flex-start;
  }
  .header-pending-banner {
    width: 100%;
    max-width: none;
    margin: 0.25rem 0;
    order: 3;
  }
  .header-community-block {
    align-self: flex-end;
    width: 100%;
    order: 4;
  }
  .site-header-compact .header-app-logo {
    height: 34px;
    max-width: min(200px, 70vw);
  }
  .header-app-logo {
    height: 28px;
  }
  .hero { padding-top: 2rem; }
}

/* Obituary create/edit: body editor label is separate from contenteditable so
   typed copy stays normal weight (reporter article-editor stack). */
.obituary-body-editor .obituary-body-label {
  display: block;
  margin-bottom: 0.35rem;
  font-weight: 600;
}
.obituary-body-editor .article-editor {
  font-family: var(--font-body);
  font-weight: 400;
}

/* Event description: same article-editor stack; label separate from contenteditable. */
.event-body-editor .event-body-label {
  display: block;
  margin-bottom: 0.35rem;
  font-weight: 600;
}
.event-body-editor .article-editor {
  font-family: var(--font-body);
  font-weight: 400;
  min-height: 10rem;
}

/* Public Obituaries — block / card grid (4×3 pages; last row padded to 4) */
.obituary-block-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
  align-items: stretch;
  margin-bottom: 1rem;
}
.obituary-block {
  position: relative;
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 0;
  overflow: hidden;
  min-width: 0;
}
.obituary-block--blank {
  pointer-events: none;
  background:
    linear-gradient(145deg, rgba(45, 90, 61, 0.05), rgba(26, 36, 33, 0.02));
  border-style: dashed;
  opacity: 0.55;
  min-height: 0;
}
.obituary-block--blank::before {
  content: "";
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
}
.obituary-block-hit {
  display: block;
  position: absolute;
  inset: 0;
  z-index: 2;
}
.obituary-block-photo {
  width: 100%;
  aspect-ratio: 1 / 1;
  flex: 0 0 auto;
  overflow: hidden;
  background: rgba(26, 36, 33, 0.06);
}
.obituary-block-photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
}
.obituary-block-photo--empty {
  background:
    linear-gradient(145deg, rgba(45, 90, 61, 0.08), rgba(26, 36, 33, 0.04));
}
.obituary-block-body {
  position: relative;
  z-index: 3;
  padding: 0.75rem 0.85rem 0.9rem;
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}
.obituary-block-name {
  margin: 0;
  font-size: 1.05rem;
  line-height: 1.3;
  font-family: var(--font-display);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.obituary-block-name a {
  color: inherit;
  text-decoration: none;
}
.obituary-block-name a:hover {
  color: var(--moss-deep);
}
.obituary-block-meta {
  margin: 0;
}
.obituary-pager {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin: 0.25rem 0 1rem;
}
.obituary-pager .btn.is-disabled,
.obituary-pager span.btn.is-disabled {
  opacity: 0.45;
  pointer-events: none;
  cursor: default;
}
.obituary-pager-status {
  min-width: 6.5rem;
  text-align: center;
}
@media (max-width: 1100px) {
  .obituary-block-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 640px) {
  .obituary-block-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  /* Hide row-fill blanks on single-column phones */
  .obituary-block--blank {
    display: none;
  }
  .obituary-pager {
    justify-content: space-between;
  }
}

.marketplace-title-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 0.9rem 1.25rem;
}
.marketplace-title-field {
  flex: 1 1 auto;
  min-width: 14rem;
  width: auto;
  max-width: none;
  margin: 0;
}
.marketplace-title-field input {
  width: 100%;
  max-width: none;
  box-sizing: border-box;
}
.marketplace-section-field {
  flex: 0 1 12rem;
  margin: 0;
  min-width: 9rem;
}
.marketplace-section-field select {
  width: 100%;
  min-width: 9rem;
}
.marketplace-price-field {
  flex: 0 0 8rem;
  margin: 0;
  min-width: 6.5rem;
}
.marketplace-price-field input {
  width: 100%;
  box-sizing: border-box;
}

.marketplace-header-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}
.marketplace-header-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}
/* Fixed width so Community/Commercial category options don't resize the control. */
.marketplace-section-filter select {
  width: 17.5rem;
  min-width: 17.5rem;
  max-width: 100%;
  box-sizing: border-box;
}
.marketplace-block-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}
.marketplace-block {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 0;
  overflow: hidden;
}
.marketplace-block-hit {
  position: absolute;
  inset: 0;
  z-index: 1;
}
.marketplace-block-photo {
  aspect-ratio: 1 / 1;
  background: #f0f0f0;
  overflow: hidden;
}
.marketplace-block-photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.marketplace-block-photo--empty {
  background: repeating-linear-gradient(-45deg, #f5f5f5, #f5f5f5 8px, #ececec 8px, #ececec 16px);
}
.marketplace-block-body {
  position: relative;
  z-index: 2;
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  padding: 0.85rem 1rem 1rem;
  pointer-events: none;
}
.marketplace-block-body a {
  pointer-events: auto;
}
.marketplace-block-price {
  margin: 0 0 0.25rem;
  font-weight: 700;
}
.marketplace-block-title {
  margin: 0 0 0.35rem;
  font-size: 1.05rem;
  line-height: 1.3;
}
.marketplace-block-title a {
  color: inherit;
  text-decoration: none;
}
.marketplace-block-title a:hover {
  text-decoration: underline;
}
.marketplace-block-desc,
.marketplace-block-meta {
  margin: 0;
}
/* Pin category · through to the bottom of the tile body (short ads too). */
.marketplace-block-meta.classified-ad-meta {
  margin-top: auto;
  padding-top: 0.55rem;
  border-top: 1px solid var(--line);
}
.marketplace-block--empty-slot {
  pointer-events: none;
  border-style: dashed;
  background: transparent;
  opacity: 0.65;
  box-shadow: none;
}
.marketplace-block-body--empty-slot {
  min-height: 4.25rem;
}
.marketplace-detail-price {
  margin: 0.35rem 0 0;
  font-size: 1.25rem;
  font-weight: 700;
}
.marketplace-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 0.75rem;
  margin-bottom: 1rem;
}
.marketplace-detail-body + .marketplace-gallery {
  margin-top: 1rem;
  margin-bottom: 0;
}
.marketplace-gallery-item {
  margin: 0;
  overflow: hidden;
  border-radius: 4px;
  background: #f0f0f0;
}
.marketplace-gallery-item img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  object-fit: cover;
}
@media (max-width: 1100px) {
  .marketplace-block-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 640px) {
  .marketplace-block-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Explicit card chrome for the 3-across Public Notices grid (match .panel line). */
.public-notice-block {
  margin-bottom: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
}
.public-notice-block.marketplace-block--empty-slot {
  border-style: dashed;
  background: transparent;
}

.public-notice-block-body {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  min-height: 8rem;
}
.public-notice-block-site {
  margin: 0;
}
.public-notice-block-type {
  margin: 0;
}
.public-notice-block-text {
  margin: 0;
  flex: 1 1 auto;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 8;
  overflow: hidden;
  font-weight: 400;
}
.public-notice-block-date {
  margin: 0.35rem 0 0;
  text-align: left;
}

.public-notice-text-toolbar {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  margin: 0.35rem 0 0.45rem;
}
.public-notice-format-btn {
  min-width: 2rem;
  padding: 0.2rem 0.55rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  font: inherit;
  font-weight: 700;
  line-height: 1.2;
  cursor: pointer;
}
.public-notice-format-btn:hover {
  background: rgba(26, 36, 33, 0.06);
}
.public-notice-format-btn--underline {
  text-decoration: underline;
  font-weight: 600;
}
.public-notice-align-group {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  margin-left: 0.25rem;
  padding-left: 0.45rem;
  border-left: 1px solid var(--line);
}
.public-notice-format-btn.is-active {
  background: rgba(31, 92, 77, 0.12);
  border-color: rgba(31, 92, 77, 0.35);
  color: var(--moss-deep);
}

.public-notice-editor-field {
  display: grid;
  gap: 0.35rem;
}
.public-notice-editor-label {
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: 0.92rem;
}
.public-notice-editor {
  min-height: 10rem;
  padding: 0.75rem 0.85rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 1rem;
  line-height: 1.5;
  color: var(--ink);
  overflow: auto;
}
/* Create/edit drawers: grow the notice editor to fill available drawer height. */
.public-notice-create-drawer .public-notice-drawer-inner {
  overflow: hidden;
}
.public-notice-create-drawer .public-notice-drawer-header {
  flex: 0 0 auto;
}
.public-notice-create-drawer .public-notice-drawer-body {
  display: flex;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
}
.public-notice-create-drawer .public-notice-drawer-body > form {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-height: 0;
}
.public-notice-create-drawer .form-grid {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-height: 0;
  gap: 0.9rem;
}
.public-notice-create-drawer .public-notice-editor-field {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-height: 0;
  gap: 0.35rem;
}
.public-notice-create-drawer .public-notice-editor {
  flex: 1 1 auto;
  min-height: min(22rem, 45vh);
  height: 100%;
}
.public-notice-create-drawer .form-actions {
  flex: 0 0 auto;
  margin-top: 1rem;
}
.public-notice-editor:focus {
  outline: 2px solid rgba(31, 92, 77, 0.35);
  outline-offset: 1px;
}
.public-notice-editor strong,
.public-notice-editor b {
  font-weight: 700;
}
.public-notice-editor u {
  text-decoration: underline;
}
.public-notice-editor p,
.public-notice-editor div {
  margin: 0 0 0.35rem;
}
.public-notice-editor p:last-child,
.public-notice-editor div:last-child {
  margin-bottom: 0;
}

/* Default notice copy is regular weight so **bold** / <strong> clearly contrasts. */
.public-notice-body,
.public-notice-block-text,
.public-notice-drawer-body > [data-public-notice-body] {
  font-family: var(--font-body);
  font-weight: 400;
}
.public-notice-body:not(.public-notice-body--html) {
  white-space: pre-wrap;
}
.public-notice-body--html {
  white-space: normal;
}
.public-notice-body--html p,
.public-notice-body--html div {
  margin: 0 0 0.35rem;
}
.public-notice-body--html p:last-child,
.public-notice-body--html div:last-child {
  margin-bottom: 0;
}
.public-notice-body strong,
.public-notice-block-text strong,
.public-notice-drawer-body > [data-public-notice-body] strong {
  font-weight: 700;
}
.public-notice-body u,
.public-notice-block-text u,
.public-notice-drawer-body > [data-public-notice-body] u {
  text-decoration: underline;
}

/* Classified Ads — author-marked Sold (stays published) */
.classified-ad-sold-banner {
  margin: 0 0 0.5rem;
  color: #c41e1e;
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 800;
  letter-spacing: 0.06em;
  line-height: 1.1;
  text-transform: uppercase;
}
.classified-ad-sold-banner--tile {
  position: absolute;
  z-index: 2;
  top: 0.45rem;
  left: 0.55rem;
  margin: 0;
  font-size: clamp(1.35rem, 3vw, 1.85rem);
  text-shadow: 0 1px 2px rgba(255, 253, 248, 0.85);
  pointer-events: none;
}
.marketplace-block--sold {
  position: relative;
}
.classified-ad-sold-banner--drawer {
  margin: 0 0 0.35rem;
  font-size: clamp(1.5rem, 3.5vw, 2rem);
}
.classified-ad-sold-inline {
  display: inline-block;
  margin-left: 0.45rem;
  color: #c41e1e;
  font-size: 0.85rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  vertical-align: middle;
}
.classified-ad-sold-toggle {
  display: inline-block;
}

/* Right-side drawers (classified ads + obituaries + wallet users + disk plans + wallet funds + public notices + calendar events + newsletter + stories) */
.classified-ad-drawer,
.obituary-drawer,
.wallet-user-drawer,
.disk-plan-drawer,
.wallet-funds-drawer,
.public-notice-drawer,
.calendar-event-drawer,
.newsletter-drawer,
.newsletter-view-drawer,
.newsletter-recipients-drawer,
.newspaper-drawer,
.newspaper-view-drawer,
.story-drawer {
  border: 0;
  padding: 0;
  margin: 0;
  width: min(28rem, 100vw);
  height: 100vh;
  max-height: 100vh;
  max-width: none;
  background: transparent;
  color: inherit;
  inset: 0 0 0 auto;
}
/* Accounting wallet activity table needs room for datetime + amount columns. */
.wallet-user-drawer {
  width: min(40rem, 100vw);
}
/* Obituary View: wider side desk for photo + body + service lines. */
.obituary-drawer {
  width: min(48rem, 100vw);
}
/* Newsletter compose needs a bit more room than the standard side desk. */
.newsletter-drawer,
.newspaper-drawer {
  width: min(42rem, 100vw);
}
/* Published View: ~2× normal side desk (28rem → 56rem) for HTML preview. */
.newsletter-view-drawer,
.newspaper-view-drawer,
.story-drawer {
  width: min(56rem, 100vw);
}
/* Recipients list: ~2× normal side desk (28rem → 56rem) for long emails. */
.newsletter-recipients-drawer {
  width: min(56rem, 100vw);
}
.classified-ad-drawer::backdrop,
.obituary-drawer::backdrop,
.wallet-user-drawer::backdrop,
.disk-plan-drawer::backdrop,
.wallet-funds-drawer::backdrop,
.public-notice-drawer::backdrop,
.calendar-event-drawer::backdrop,
.newsletter-drawer::backdrop,
.newsletter-view-drawer::backdrop,
.newsletter-recipients-drawer::backdrop,
.newspaper-drawer::backdrop,
.newspaper-view-drawer::backdrop,
.story-drawer::backdrop {
  background: rgba(20, 32, 28, 0.4);
  backdrop-filter: blur(1px);
}
.classified-ad-drawer-inner,
.obituary-drawer-inner,
.wallet-user-drawer-inner,
.disk-plan-drawer-inner,
.wallet-funds-drawer-inner,
.public-notice-drawer-inner,
.calendar-event-drawer-inner,
.newsletter-drawer-inner,
.story-drawer-inner {
  display: flex;
  flex-direction: column;
  height: 100%;
  background: #fffdf8;
  border-left: 1px solid var(--line);
  box-shadow: -12px 0 36px rgba(20, 32, 28, 0.16);
  padding: 0.75rem 1.1rem 1rem;
  overflow: auto;
}
.classified-ad-drawer-header,
.obituary-drawer-header,
.wallet-user-drawer-header,
.disk-plan-drawer-header,
.wallet-funds-drawer-header,
.public-notice-drawer-header,
.calendar-event-drawer-header,
.newsletter-drawer-header,
.story-drawer-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.65rem;
}
.classified-ad-drawer-header h2,
.obituary-drawer-header h2,
.wallet-user-drawer-header h2,
.disk-plan-drawer-header h2,
.wallet-funds-drawer-header h2,
.public-notice-drawer-header h2,
.calendar-event-drawer-header h2,
.newsletter-drawer-header h2,
.story-drawer-header h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.25rem, 2.4vw, 1.65rem);
  line-height: 1.2;
}
.newsletter-view-drawer .newsletter-drawer-header h2 {
  font-size: clamp(1.05rem, 2vw, 1.3rem);
}
.public-notice-drawer-site,
.public-notice-drawer-date {
  margin: 0.2rem 0 0;
}
.public-notice-create-drawer .form-grid {
  margin: 0;
}
.public-notice-create-drawer .form-actions {
  flex-wrap: wrap;
}
.public-notice-create-drawer .notice-date-type-row {
  margin-bottom: 0;
}
.public-notice-create-drawer .public-notice-editor-label,
.public-notice-create-drawer .public-notice-text-toolbar,
.public-notice-create-drawer [data-public-notice-count] {
  flex: 0 0 auto;
}
.classified-ad-drawer-header .marketplace-detail-price,
.obituary-drawer-lifespan,
.wallet-user-drawer-header .marketplace-detail-price {
  margin-top: 0.2rem;
}
.classified-ad-price-author-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
  margin-top: 0.2rem;
  flex-wrap: wrap;
}
.classified-ad-price-author-row .marketplace-detail-price {
  margin: 0;
}
.classified-ad-creator {
  margin: 0;
  margin-left: auto;
  text-align: right;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--muted, #667);
}
.obituary-drawer-lifespan {
  margin-bottom: 0;
}
.classified-ad-drawer-close,
.obituary-drawer-close,
.wallet-user-drawer-close,
.disk-plan-drawer-close,
.wallet-funds-drawer-close,
.public-notice-drawer-close,
.calendar-event-drawer-close,
.newsletter-drawer-close,
.story-drawer-close {
  flex: 0 0 auto;
  margin-left: auto;
}
.story-drawer-meta,
.story-drawer-summary,
.story-drawer-dates {
  margin: 0.25rem 0 0;
}
.story-drawer-summary {
  font-size: 1.02rem;
}
.calendar-event-drawer-actions {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex: 0 0 auto;
  margin-left: auto;
}
.calendar-event-drawer-actions .calendar-event-drawer-close {
  margin-left: 0;
}
.calendar-event-add-menu {
  position: relative;
  flex: 0 0 auto;
}
.calendar-event-add-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.35rem;
  height: 2.35rem;
  padding: 0;
  border: 1px solid var(--line, rgba(26, 36, 33, 0.18));
  border-radius: 10px;
  background: #fff;
  color: var(--moss-deep, #1f5c4d);
  cursor: pointer;
  transition: color 0.15s ease, background-color 0.15s ease, border-color 0.15s ease;
}
.calendar-event-add-toggle:hover,
.calendar-event-add-toggle:focus-visible,
.calendar-event-add-toggle[aria-expanded="true"] {
  color: var(--moss-deep, #1f5c4d);
  background: rgba(31, 92, 77, 0.1);
  border-color: rgba(31, 92, 77, 0.35);
  outline: none;
}
.calendar-event-add-toggle svg {
  display: block;
}
.calendar-event-add-menu-panel {
  position: absolute;
  top: calc(100% + 0.35rem);
  right: 0;
  z-index: 5;
  min-width: 11.5rem;
  padding: 0.35rem;
  border: 1px solid var(--line, rgba(26, 36, 33, 0.18));
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 10px 28px rgba(20, 32, 28, 0.16);
}
.calendar-event-add-menu-panel[hidden] {
  display: none;
}
.calendar-event-add-option {
  display: block;
  width: 100%;
  margin: 0;
  padding: 0.55rem 0.7rem;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--ink, #1a2421);
  font-family: var(--font-ui);
  font-size: 0.95rem;
  font-weight: 600;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
}
.calendar-event-add-option:hover,
.calendar-event-add-option:focus-visible {
  background: rgba(31, 92, 77, 0.1);
  color: var(--moss-deep, #1f5c4d);
  outline: none;
}
.calendar-event-add-option[aria-disabled="true"] {
  opacity: 0.45;
  pointer-events: none;
  cursor: default;
}
.classified-ad-drawer-gallery,
.obituary-drawer-gallery {
  display: grid;
  gap: 0.65rem;
  margin: 0.75rem 0 0;
}
.classified-ad-drawer-gallery[hidden],
.obituary-drawer-gallery[hidden] {
  display: none;
}
.obituary-drawer-primary {
  margin: 0 0 0.85rem;
}
.obituary-drawer-primary[hidden] {
  display: none;
}
.obituary-drawer-primary img,
.classified-ad-drawer-photo img,
.obituary-drawer-photo img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 8px;
  border: 1px solid rgba(26, 36, 33, 0.08);
}
.classified-ad-drawer-photo,
.obituary-drawer-photo {
  margin: 0;
}
.classified-ad-drawer-body,
.obituary-drawer-body,
.wallet-user-drawer-body,
.disk-plan-drawer-body,
.wallet-funds-drawer-body,
.public-notice-drawer-body,
.calendar-event-drawer-body,
.story-drawer-body {
  margin: 0.5rem 0 0;
  margin-bottom: 0;
  padding: 0.75rem 0.85rem;
  white-space: pre-wrap;
  flex: 1 1 auto;
}
.calendar-event-drawer-body {
  white-space: normal;
}
.public-notice-drawer-body {
  white-space: normal;
}
/* Formatted obituary / story HTML (article_html) — do not pre-wrap the panel. */
.obituary-drawer-body,
.story-drawer-body {
  white-space: normal;
}
.public-notice-drawer-body > [data-public-notice-body] {
  white-space: pre-wrap;
  margin: 0;
}
.public-notice-drawer-publish,
.obituary-drawer-publish {
  margin: 1rem 0 0;
  display: flex;
  justify-content: flex-start;
}
.public-notice-drawer-publish[hidden],
.obituary-drawer-publish[hidden] {
  display: none !important;
}
.wallet-user-drawer-body,
.disk-plan-drawer-body,
.wallet-funds-drawer-body {
  white-space: normal;
}
.wallet-funds-drawer-body [data-wallet-funds-panel][hidden] {
  display: none;
}
.wallet-funds-drawer-message {
  position: static;
  margin: 0 0 0.85rem;
  box-shadow: none;
  border-radius: 10px;
}
/* Keep pre-wrap on the ad text node only — pre-wrap on the panel preserved
   markup newlines around hidden URL/gallery siblings as blank lines. */
.classified-ad-drawer-body {
  white-space: normal;
  margin-top: 0.35rem;
  padding: 0.5rem 0.85rem;
  flex: 0 1 auto;
}
.classified-ad-drawer-body > [data-classified-ad-body] {
  white-space: pre-wrap;
  margin: 0;
}
.disk-plan-drawer-body form[hidden] {
  display: none;
}
.wallet-user-drawer-body table {
  width: 100%;
  font-size: 0.92rem;
}
.wallet-user-drawer-body table th:first-child,
.wallet-user-drawer-body table td:first-child,
.wallet-user-drawer-body table th:nth-child(3),
.wallet-user-drawer-body table td:nth-child(3),
.wallet-user-drawer-body table th:nth-child(4),
.wallet-user-drawer-body table td:nth-child(4) {
  white-space: nowrap;
}
.classified-ad-drawer-body > [data-classified-ad-body] > :first-child,
.obituary-drawer-body > [data-obituary-body] > :first-child {
  margin-top: 0;
}
.obituary-drawer-body > [data-obituary-primary]:not([hidden]) + [data-obituary-body] {
  margin-top: 0;
}
.classified-ad-drawer-status,
.obituary-drawer-status,
.wallet-user-drawer-status,
.public-notice-drawer-status,
.story-drawer-status {
  margin: 0.65rem 0 0;
}
.story-drawer-body .story-document-link {
  margin: 0 0 0.85rem;
}
.story-drawer-body > [data-story-drawer-body] > :first-child {
  margin-top: 0;
}
/* Desk preview: smaller floated primary photo; body copy wraps around it. */
.story-drawer .story-photo {
  float: right;
  width: min(calc(100% - 1rem), 16rem);
  max-width: 42%;
  margin: 0 0 0.85rem 1rem;
}
.story-drawer .story-photo img,
.story-drawer .photo-carousel--full .photo-carousel-slide img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 10px;
  border: 1px solid rgba(26, 36, 33, 0.35);
}
.story-drawer .story-body::after {
  content: "";
  display: table;
  clear: both;
}
@media (max-width: 520px) {
  .story-drawer .story-photo {
    float: none;
    width: 100%;
    max-width: 100%;
    margin: 0 0 0.85rem;
  }
}

/* Newsletter (Editor's Desk) */
.newsletter-desk-header {
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}
/* Created / Emailed / Actions are fixed; Subject takes remaining width (ellipsis). */
.newsletter-history-table th:nth-child(2),
.newsletter-history-table td:nth-child(2),
.newsletter-history-table th:nth-child(3),
.newsletter-history-table td:nth-child(3) {
  width: 10.25rem;
  white-space: nowrap;
}
.newsletter-history-table th.newsletter-recipients-col,
.newsletter-history-table td.newsletter-recipients-col {
  width: 6.5rem;
  text-align: center;
  white-space: nowrap;
}
/* Room for Email + View on Published (Draft only shows Edit — extra space is fine). */
.newsletter-history-table th:nth-child(5),
.newsletter-history-table td:nth-child(5),
.newsletter-history-table td.articles-actions {
  width: 11.5rem;
  min-width: 11.5rem;
  white-space: nowrap;
}
.newsletter-recipients-count {
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 0.12em;
}
.newsletter-history-table td.newsletter-subject,
.newsletter-history-table th.newsletter-subject {
  width: auto;
  max-width: 0; /* fixed-layout: claim leftover + ellipsis (same as articles headline) */
  overflow: hidden;
  white-space: nowrap;
}
.newsletter-history-table .newsletter-subject-link,
.newsletter-history-table .newsletter-subject-meta {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.newsletter-drawer-body {
  margin-top: 0.75rem;
}
.newsletter-step {
  margin-bottom: 1rem;
}
.newsletter-step h3 {
  display: flex;
  align-items: baseline;
  gap: 0.55rem;
  flex-wrap: wrap;
  margin: 0 0 0.85rem;
  font-size: 1.1rem;
}
.newsletter-step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.6rem;
  height: 1.6rem;
  border-radius: 50%;
  background: var(--site-color, #1a3a4a);
  color: #fff;
  font-size: 0.85rem;
  font-weight: 700;
  flex: 0 0 auto;
}
.newsletter-pick-list {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  max-height: 18rem;
  overflow: auto;
  padding: 0.15rem;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.55);
}
.newsletter-pick {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  padding: 0.55rem 0.65rem;
  margin: 0;
  cursor: pointer;
  border-radius: 4px;
}
.newsletter-pick:hover {
  background: rgba(0, 0, 0, 0.04);
}
.newsletter-pick input {
  margin-top: 0.2rem;
  width: 1.1rem;
  height: 1.1rem;
  flex: 0 0 auto;
}
.newsletter-pick > span {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 0;
}
.newsletter-pick-title {
  font-weight: 600;
  line-height: 1.3;
}
.newsletter-pick--sponsor {
  align-items: center;
}
.newsletter-sponsor-pick {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.45rem 0.55rem;
  border: 1px solid transparent;
  border-radius: 6px;
}
.newsletter-sponsor-pick:hover {
  background: rgba(0, 0, 0, 0.04);
}
.newsletter-sponsor-pick.is-primary {
  border-color: rgba(31, 92, 77, 0.35);
  background: rgba(31, 92, 77, 0.08);
}
.newsletter-sponsor-pick-include {
  display: flex;
  gap: 0.65rem;
  align-items: center;
  flex: 1 1 auto;
  cursor: pointer;
}
.newsletter-sponsor-pick-include input {
  margin: 0;
  width: 1.1rem;
  height: 1.1rem;
  flex: 0 0 auto;
}
.newsletter-primary-none {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.55rem 0.55rem;
  font-size: 0.9rem;
  color: var(--muted, #666);
  cursor: pointer;
}
.newsletter-primary-none input {
  margin: 0;
  width: 1.1rem;
  height: 1.1rem;
}
.newsletter-primary-pick {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  flex: 0 0 auto;
  padding: 0.2rem 0.45rem;
  border-radius: 6px;
  font-size: 0.78rem;
  cursor: pointer;
  color: var(--ink, #222);
  background: rgba(0, 0, 0, 0.04);
}
.newsletter-primary-pick:has(input:disabled) {
  opacity: 0.4;
  cursor: not-allowed;
}
.newsletter-sponsor-pick.is-primary .newsletter-primary-pick {
  color: var(--moss-deep, #1f5c4d);
  background: rgba(31, 92, 77, 0.12);
}
.newsletter-primary-pick input {
  margin: 0;
}
.newsletter-sponsor-thumb {
  width: 40px;
  height: 40px;
  object-fit: contain;
  border-radius: 4px;
  background: #fff;
  flex: 0 0 auto;
}
.newsletter-actions.sticky-actions {
  position: sticky;
  bottom: 0;
  z-index: 5;
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  padding: 0.85rem 1rem;
  margin: 0 0 1rem;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 8px;
  box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.06);
}
.newsletter-actions-publish {
  margin-left: auto;
}
.newsletter-preview-frame {
  display: block;
  width: 100%;
  min-height: 420px;
  border: 1px solid rgba(0, 0, 0, 0.12);
  border-radius: 6px;
  background: #ececec;
}
.newsletter-view-drawer-body {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  min-height: 0;
}
.newsletter-view-preview-frame {
  flex: 1 1 auto;
  min-height: min(70vh, 720px);
  height: 100%;
}
.newsletter-status {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  padding: 0.15rem 0.45rem;
  border-radius: 4px;
  background: #e8e8e8;
  color: #333;
}
.newsletter-status--draft {
  background: #fff3cd;
  color: #6b5200;
}
.newsletter-status--published {
  background: #d4edda;
  color: #1e5c2f;
}
.newsletter-recipients-table th:nth-child(2),
.newsletter-recipients-table td:nth-child(2) {
  width: 7.5rem;
  white-space: nowrap;
}
/* When: room for "M j, Y g:ia" (e.g. Sep 30, 2026 12:35pm). */
.newsletter-recipients-table th:nth-child(3),
.newsletter-recipients-table td:nth-child(3) {
  width: 10rem;
  white-space: nowrap;
}
.newsletter-recipient-email {
  max-width: 0;
  overflow: hidden;
}
.newsletter-recipient-address,
.newsletter-recipient-name {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.newsletter-recipient-status {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  padding: 0.15rem 0.45rem;
  border-radius: 4px;
  background: #e8e8e8;
  color: #444;
}
.newsletter-recipient-status--success {
  background: #d4edda;
  color: #1e5c2f;
}
.newsletter-recipient-status--failed {
  background: #f8d7da;
  color: #7a1c24;
}
.profile-email-prefs .checkbox-row {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  margin: 0;
  cursor: pointer;
}
.profile-email-prefs .checkbox-row input {
  margin-top: 0.2rem;
  width: 1.1rem;
  height: 1.1rem;
  flex: 0 0 auto;
}
@media (max-width: 700px) {
  .newsletter-actions.sticky-actions {
    position: static;
  }
  .newsletter-preview-frame {
    min-height: 320px;
  }
}
.newspaper-story-pick {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  padding: 0.55rem 0.65rem;
  border: 1px solid transparent;
  border-radius: 6px;
}
.newspaper-story-pick:hover {
  background: rgba(31, 92, 77, 0.06);
}
.newspaper-story-pick.is-lead {
  border-color: rgba(31, 92, 77, 0.35);
  background: rgba(31, 92, 77, 0.08);
}
.newspaper-story-pick-include {
  display: flex;
  gap: 0.65rem;
  align-items: flex-start;
  flex: 1 1 auto;
  min-width: 0;
  cursor: pointer;
}
.newspaper-story-pick-include input {
  margin-top: 0.25rem;
  flex: 0 0 auto;
}
.newspaper-story-pick-include > span {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 0;
}
.newspaper-lead-pick {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  flex: 0 0 auto;
  margin-top: 0.15rem;
  padding: 0.2rem 0.45rem;
  border-radius: 6px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: rgba(26, 36, 33, 0.65);
  cursor: pointer;
  user-select: none;
}
.newspaper-lead-pick:has(input:disabled) {
  opacity: 0.4;
  cursor: not-allowed;
}
.newspaper-story-pick.is-lead .newspaper-lead-pick {
  color: var(--moss-deep);
  background: rgba(31, 92, 77, 0.12);
}
.newspaper-lead-pick input {
  margin: 0;
}
.newspaper-template-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.newspaper-template-pick {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  padding: 0.65rem 0.75rem;
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 6px;
  cursor: pointer;
  background: #fff;
}
.newspaper-template-pick:hover,
.newspaper-template-pick.is-selected {
  border-color: rgba(0, 0, 0, 0.28);
  background: #f7f7f7;
}
.newspaper-template-pick input {
  margin-top: 0.25rem;
  flex: 0 0 auto;
}
.newspaper-template-pick > span {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 0;
}
.newspaper-view-header-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  justify-content: flex-end;
}
.newspaper-preview-frame {
  min-height: 520px;
  background: #d8d8d8;
}

/* Full-screen newspaper compose / page editor (not a side desk). */
.newspaper-compose-header {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 1.25rem;
}
.newspaper-compose-header-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  justify-content: flex-end;
}
.newspaper-compose-kicker a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.newspaper-ads-stub {
  opacity: 0.85;
  border-style: dashed;
}
.newspaper-page-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
}
.newspaper-page-nav-left {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  align-items: center;
}
.newspaper-page-nav-status {
  font-size: 1.05rem;
}
.newspaper-page-nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.newspaper-page-nav-actions {
  display: flex;
  flex-direction: column;
  flex-wrap: wrap;
  gap: 0.45rem;
  align-items: flex-end;
  margin-left: auto;
}
.newspaper-page-nav-action-btns {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  justify-content: flex-end;
}
.newspaper-page-processing {
  display: none;
  align-items: center;
  gap: 0.65rem;
  margin: 0;
  color: var(--moss-deep);
  font-size: 0.95rem;
  font-weight: 600;
}
form[data-newspaper-page-edit-form].is-saving .newspaper-page-processing,
.newspaper-page-processing.is-visible {
  display: flex;
}
.newspaper-params-actions {
  justify-content: flex-end;
}
.newspaper-params-apply-btn {
  margin-left: auto;
}
.newspaper-params-processing {
  display: none;
  align-items: center;
  gap: 0.65rem;
  width: 100%;
  justify-content: flex-end;
  margin: 0.35rem 0 0;
  color: var(--moss-deep);
  font-size: 0.95rem;
  font-weight: 600;
}
form[data-newspaper-params-apply-form].is-processing .newspaper-params-processing,
.newspaper-params-processing.is-visible {
  display: flex;
}
.newspaper-nav-disabled {
  opacity: 0.45;
  pointer-events: none;
}
.newspaper-page-jump-label {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}
.newspaper-page-edit-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  gap: 1rem;
  align-items: start;
}
.newspaper-page-preview-frame {
  min-height: 640px;
  width: 100%;
  border: 1px solid rgba(0, 0, 0, 0.12);
  background: #d8d8d8;
}
.newspaper-page-html {
  width: 100%;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.82rem;
  line-height: 1.4;
  resize: vertical;
  min-height: 28rem;
}
.newspaper-show-preview-frame {
  min-height: 70vh;
  width: 100%;
  border: 1px solid rgba(0, 0, 0, 0.12);
}
@media (max-width: 900px) {
  .newspaper-page-edit-grid {
    grid-template-columns: 1fr;
  }
  .newspaper-page-preview-frame {
    min-height: 420px;
  }
}
