:root { --theme-font-stack-default: var(--bc-font); }

:where(.entry-content:not(:has(> .belchess-contacts)), .comment-content) a:not([class*="button"]):not(.wp-element-button) {
    text-decoration-line: underline;
    text-underline-offset: .18em;
    text-decoration-thickness: 1px;
}

:where(.entry-content:not(:has(> .belchess-contacts)), .comment-content) a:not([class*="button"]):not(.wp-element-button):hover {
    text-decoration-thickness: 2px;
}

.site-main :where(h1,h2,h3,h4,h5,h6,.entry-title,.page-title) {
    overflow-wrap: anywhere;
    text-wrap: pretty;
}

.single-post .entry-content:not(:has(> .elementor)) > :where(p,ul,ol,blockquote,h2,h3,h4,h5,h6) {
    max-inline-size: var(--bc-reading-width);
    line-height: var(--bc-leading-reading);
}

.single-post .entry-content:not(:has(> .elementor)) > :where(h2,h3,h4,h5,h6) { line-height: var(--bc-leading-heading); }

:where(.entry-content:not(:has(> .belchess-contacts)),.comment-content) :where(figcaption, .wp-caption-text) {
    color: var(--bc-text-secondary);
    font-size: var(--bc-size-small);
    line-height: var(--bc-leading-small);
}

.entry-content:not(:has(> .belchess-contacts)) > :where(blockquote,.wp-block-quote) {
    padding: var(--bc-space-16) var(--bc-space-20);
    border: 0;
    border-inline-start: 2px solid var(--bc-border);
    border-radius: var(--bc-radius-card);
    background: var(--bc-surface-light);
}

.entry-content:not(:has(> .belchess-contacts)) > :where(hr,.wp-block-separator) {
    border-color: var(--bc-border);
}

.entry-content:not(:has(> .belchess-contacts)) > :where(.wp-block-image,.wp-block-gallery) img,
.entries .ct-media-container img { border-radius: var(--bc-radius-image); }

:where(.entry-meta,.entry-meta a,.ct-entry-meta) { color: var(--bc-text-secondary); }
:where(.entry-meta,.ct-entry-meta) { font-size: var(--bc-size-meta); line-height: var(--bc-leading-small); }

body :focus-visible {
    outline: var(--bc-focus-width) solid var(--bc-primary);
    outline-offset: var(--bc-focus-offset);
}

/* The focus ring must be visible as soon as a search field receives focus. */
:is(.ct-search-form, .search-form) input[type="search"]:focus-visible {
    outline: var(--bc-focus-width) solid var(--bc-primary);
    outline-offset: var(--bc-focus-offset);
    transition-property: border-color, background-color, color;
}

/* The approved Contacts content keeps the original Blocksy container geometry. */
#main:has(.belchess-contacts) {
    --theme-container-edge-spacing: 90vw;
    --theme-container-width-base: calc(var(--theme-container-edge-spacing) - var(--theme-frame-size, 0px) * 2);
    --theme-container-width: min(100%, var(--theme-container-width-base));
}
@media (max-width: 689.98px) {
    #main:has(.belchess-contacts) { --theme-container-edge-spacing: 88vw; }
}

/* Keep the desktop and mobile navigation in their existing positions. */
#header [data-device="desktop"] .menu > .menu-item > a { white-space: normal; }
#footer :focus-visible, .bc-surface-dark :focus-visible { outline-color: var(--bc-accent); }
