/* Loaded by the theme bootstrap for business pages, the directory and the journal. */
:root {
  --public-ink: var(--theme-ink);
  --public-bg: var(--theme-bg);
  --public-surface: var(--theme-surface);
  --public-muted: var(--theme-muted);
  --public-line: var(--theme-line);
  --public-green: var(--theme-link);
}

body:has(> .public-site-header),
body.directory-page {
  background: var(--theme-bg);
  color: var(--theme-ink);
}

.public-site-header,
body.portfolio-business-home > .public-site-header,
body.spr-business-page:not(.portfolio-business-home) > .spr-business-header,
body.spr-business-page .spr-business-content .spr-page-heading,
.directory-page .feed-header {
  background: var(--theme-bg);
  border-color: var(--theme-line);
}

.public-business-header-brand,
.public-site-header .public-business-header-brand strong,
.public-footer a {
  color: var(--theme-ink);
}

.public-footer { border-color: var(--theme-line); }
.public-mobile-menu-actions a:last-child { color: var(--theme-bg); }
.public-nav a:not([aria-current]):hover { background: var(--theme-raised); }

.portfolio-header-note,
.portfolio-eyebrow,
.portfolio-owner,
.portfolio-bio,
.portfolio-empty,
.portfolio-footer,
.spr-business-content .spr-lead,
body.spr-business-page:not(.portfolio-business-home) .spr-kicker,
body.spr-business-page:not(.portfolio-business-home) .spr-business-header nav a:not([aria-current]),
body.spr-business-page:not(.portfolio-business-home) .spr-footer {
  color: var(--theme-muted);
}

body.spr-business-page:not(.portfolio-business-home) .spr-prose { color: var(--theme-ink); }
.spr-business-content .spr-prose a { color: var(--theme-link); }

body.portfolio-business-home .public-business-header-brand :is(img, span),
body.portfolio-business-home .business-cover-logo,
body.spr-business-page:not(.portfolio-business-home) .spr-business-mark :is(span, img) {
  border-color: var(--theme-line);
  background: var(--theme-raised);
  color: var(--theme-ink);
}

body.portfolio-business-home .business-cover-fallback,
.directory-card-visual {
  background: linear-gradient(125deg, var(--theme-raised), var(--theme-surface));
}
body.portfolio-business-home .business-cover-fallback > span { color: var(--theme-muted); }
body.spr-business-page .spr-detail-heading img { border-color: var(--theme-line); }

.portfolio-contact:hover,
body.spr-business-page:not(.portfolio-business-home) .spr-button:hover {
  background: var(--theme-link);
  color: var(--theme-bg);
}
.portfolio-tab:not(.is-active):is(:hover, :focus-visible),
body.spr-business-page:not(.portfolio-business-home) .spr-business-header nav a:not([aria-current]):hover {
  background: var(--theme-raised);
  color: var(--theme-ink);
}

.business-gallery-view .gallery-masonry figure,
:is(.business-archive-view, .business-gallery-view) .author-empty,
.owner-public-profile,
.author-info-card,
.author-meta-list,
.author-section-tabs,
.author-empty {
  border-color: var(--theme-line);
  background: var(--theme-surface);
}

.business-gallery-view .gallery-masonry figcaption,
.author-info-card > p,
.author-page-main .business-summary { color: var(--theme-muted); }

.author-page-main .owner-public-profile .public-business-logo,
.author-page-main .author-tags span,
.author-page-main .article-card-cover i {
  border-color: var(--theme-line);
  background: var(--theme-raised);
  color: var(--theme-ink);
}

/* Business directory and its mobile navigation. */
.directory-page {
  --ink: var(--theme-ink);
  --muted: var(--theme-muted);
  --paper: var(--theme-bg);
  --line: var(--theme-line);
  --directory-ink: var(--theme-ink);
  --directory-muted: var(--theme-muted);
  --directory-line: var(--theme-line);
}
.directory-hero { background: linear-gradient(140deg, var(--theme-surface), var(--theme-bg)); }
.directory-search:focus-within,
.directory-card:focus-visible {
  outline-color: var(--theme-accent);
  border-color: var(--theme-accent);
}
.directory-card:hover { border-color: var(--theme-muted); }
.directory-search input::placeholder { color: var(--theme-muted); }

.directory-page .bottom-nav,
:is(.directory-page, .blog-home) .feed-session-menu,
:is(.directory-page, .blog-home) .account-icon-control:not(.is-guest) {
  border-color: var(--theme-line);
  background: var(--theme-surface);
  color: var(--theme-ink);
}
:is(.directory-page, .blog-home) .session-menu-person > span,
:is(.directory-page, .blog-home) .account-icon-control:not(.is-guest):is(:hover, [aria-expanded="true"]),
:is(.directory-page, .blog-home) .feed-desktop-nav a:not(.is-active):hover,
:is(.directory-page, .blog-home) .feed-session-menu nav a:hover { background: var(--theme-raised); }
:is(.directory-page, .blog-home) .account-icon-control::after { color: var(--theme-bg); }
:is(.directory-page, .blog-home) .session-logout { color: #ffb6ad; }
:is(.directory-page, .blog-home) .session-logout:hover { background: #46302c; }

/* The database journal and its retained static article pages share the same palette. */
body.blog-home,
body.article-page {
  --ink: var(--theme-ink);
  --ink-soft: var(--theme-muted);
  --muted: var(--theme-muted);
  --paper: var(--theme-bg);
  --paper-deep: var(--theme-surface);
  --line: var(--theme-line);
  --line-strong: var(--theme-line);
  --purple: #c6b8ec;
  --editorial-rule: var(--theme-line);
  --editorial-rule-strong: var(--theme-muted);
  background: var(--theme-bg);
  color: var(--theme-ink);
}
.blog-home:has(.journal-index) {
  --journal-canvas: var(--theme-bg);
  --journal-surface: var(--theme-surface);
  --journal-photo-mat: var(--theme-raised);
  --journal-edge: var(--theme-line);
  --journal-muted: var(--theme-muted);
  --journal-shadow: 0 10px 24px -15px #0009;
}
.blog-home:has(.journal-index) :is(.blog-footer, .feed-header),
.blog-home .site-header,
.article-page .site-header {
  background: var(--theme-bg);
  border-color: var(--theme-line);
}
.blog-home .journal-masthead--welcome h1 > span:first-child,
.blog-home .blog-hero .eyebrow { color: var(--theme-muted); }
.blog-home .journal-story__topic {
  background: var(--theme-raised);
  color: var(--theme-ink);
}
.sparblog-wordmark,
.blog-footer .sparblog-wordmark--footer { --wordmark-ink: var(--theme-ink); }
.blog-home .blog-empty-state,
.blog-home .article-grid > .article-card,
.article-page:not(.spr-compact-article) .next-card {
  background: var(--theme-surface);
  border-color: var(--theme-line);
}
.blog-home .blog-empty-state > p:last-child,
.article-page:not(.spr-compact-article) .article-aside span { color: var(--theme-muted); }
.blog-home .journal-list-item:is(:hover, :focus-within),
.blog-home .placeholder-blog-row:is(:hover, :focus-within),
.blog-home .hero-link:hover {
  background: var(--theme-raised);
  color: var(--theme-ink);
}
.article-page:not(.spr-compact-article) .article-content { color: var(--theme-ink); }
.blog-home .header-cta,
.article-page .header-cta,
.article-page:not(.spr-compact-article) .article-callout,
.article-page:not(.spr-compact-article) .article-callout p:last-child,
.article-page:not(.spr-compact-article) .next-card:hover,
.article-page:not(.spr-compact-article) .next-card:hover span {
  color: var(--theme-bg);
}

/* Fallback for a legacy URL when its redirect cannot run. */
body:has(main > .direct-link) {
  color: var(--theme-ink);
  background: var(--theme-bg);
}
main:has(> .direct-link) p { color: var(--theme-muted); }
main > .direct-link { color: var(--theme-bg); background: var(--theme-ink); }
main > .direct-link:focus-visible { outline-color: var(--theme-accent); }
