/* R.S. Site & Sports — core block styling (front end + block editor). Colours/fonts/sizes come from Astra's global palette + typography; this only covers what Astra leaves generic. */
.wp-block-quote, .editor-styles-wrapper .wp-block-quote {
  border-left: 4px solid var(--rs-lime, #92C153); padding: 4px 0 4px 24px; margin-inline: 0; font-style: italic; color: var(--rs-dark, #242424);
}
.wp-block-quote cite, .wp-block-pullquote cite { display: block; margin-top: 12px; font-style: normal; font-weight: 600; font-size: 14px; color: var(--rs-green, #037940); text-transform: uppercase; }
.wp-block-pullquote, .editor-styles-wrapper .wp-block-pullquote {
  border-top: 4px solid var(--rs-lime, #92C153); border-bottom: 4px solid var(--rs-lime, #92C153); box-shadow: none; padding: 40px 24px; background: var(--rs-mint, #F5FAED);
}
.wp-block-pullquote blockquote p { font-family: var(--rs-font-heading, "industry-inc-base"), sans-serif; font-weight: 400; font-style: normal; font-size: 28px; line-height: 1.2; text-transform: uppercase; color: var(--rs-dark, #242424); }
.wp-block-pullquote blockquote::before { color: var(--rs-lime, #92C153); }
.wp-block-button.is-style-outline > .wp-block-button__link,
.wp-block-button.is-style-outline > .wp-block-button__link:not(:hover) { color: var(--rs-dark, #242424); background: transparent; border: 2px solid var(--rs-lime, #92C153); }
.wp-block-button.is-style-outline > .wp-block-button__link:hover { color: var(--rs-white, #FFFFFF); background: var(--rs-lime, #92C153); border-color: var(--rs-lime, #92C153); }
.wp-block-button__link { min-width: 200px; text-align: center; transition: background-color .25s ease, border-color .25s ease, color .25s ease; }
.wp-block-separator { border: 0; border-top: 2px solid var(--rs-lime, #92C153); opacity: 1; }
.wp-block-separator:not(.is-style-wide):not(.is-style-dots) { width: 120px; }
.wp-block-table table { border-collapse: collapse; }
.wp-block-table th { background: var(--rs-green, #037940); color: var(--rs-white, #FFFFFF); font-weight: 600; text-align: left; }
.wp-block-table th, .wp-block-table td { border: 1px solid var(--ast-global-color-7, #DDE7CF); padding: 10px 14px; }
.wp-block-table tbody tr:nth-child(even) td { background: var(--rs-mint, #F5FAED); }
.wp-block-table figcaption, .wp-block-image figcaption, .wp-block-gallery figcaption { font-size: 14px; color: var(--ast-global-color-8, #5C5C5C); text-align: center; }
.wp-block-code, .wp-block-preformatted { background: var(--rs-mint, #F5FAED); border: 1px solid var(--ast-global-color-7, #DDE7CF); border-radius: 5px; padding: 16px 20px; font-size: 14px; color: var(--rs-dark, #242424); }
.wp-block-image img, .wp-block-gallery img { border-radius: 10px; }
.entry-content a:not(.wp-block-button__link) { text-underline-offset: 3px; }
/* Astra's own blockquote/code/button rules are more specific — override them inside content and the editor. */
.entry-content .wp-block-pullquote, .editor-styles-wrapper .wp-block-pullquote { box-shadow: none; }
.entry-content .wp-block-pullquote blockquote, .editor-styles-wrapper .wp-block-pullquote blockquote { border: 0; padding: 0; margin: 0; }
.entry-content .wp-block-code code, .editor-styles-wrapper .wp-block-code code { background: none; padding: 0; border: 0; }
.entry-content .wp-block-button.is-style-outline > .wp-block-button__link,
.editor-styles-wrapper .wp-block-button.is-style-outline > .wp-block-button__link { color: var(--rs-dark, #242424); border-color: var(--rs-lime, #92C153); background: transparent; }
.entry-content .wp-block-button.is-style-outline > .wp-block-button__link:hover { color: var(--rs-white, #FFFFFF); background: var(--rs-lime, #92C153); }
.entry-content .wp-block-table, .editor-styles-wrapper .wp-block-table { box-shadow: none; }
/* Outline button = rs-btn-outline (dark text, lime border); beats Astra's .wp-block-buttons … :not(.has-text-color) rule,
   while a colour picked in the editor (.has-text-color) still wins. */
.entry-content .wp-block-buttons .wp-block-button.is-style-outline > .wp-block-button__link:not(.has-text-color),
.editor-styles-wrapper .wp-block-buttons .wp-block-button.is-style-outline > .wp-block-button__link:not(.has-text-color) { color: var(--rs-dark, #242424); border-color: var(--rs-lime, #92C153); }
.entry-content .wp-block-buttons .wp-block-button.is-style-outline > .wp-block-button__link:not(.has-text-color):hover { color: var(--rs-white, #FFFFFF); background-color: var(--rs-lime, #92C153); }

/* ---- Post content inside Elementor's Post Content widget (single post template 927) + block editor ----
   The widget wrapper has no .entry-content, so the rules above that need it are repeated for it here.
   Only block internals live here (no Elementor control reaches them); template layout/images = Elementor. */
:is(.elementor-widget-theme-post-content, .editor-styles-wrapper) .wp-block-pullquote { box-shadow: none; }
:is(.elementor-widget-theme-post-content, .editor-styles-wrapper) .wp-block-pullquote blockquote { border: 0; padding: 0; margin: 0; }
:is(.elementor-widget-theme-post-content, .editor-styles-wrapper) .wp-block-code code { background: none; padding: 0; border: 0; }

/* Buttons = rs-btn-solid / rs-btn-outline (size, colours, hover, focus); the rs-text link style never applies to them. */
:is(.entry-content, .elementor-widget-theme-post-content, .editor-styles-wrapper) .wp-block-button .wp-block-button__link {
  display: inline-flex; align-items: center; justify-content: center; min-height: 35px; min-width: 200px; padding: 6px 12px;
  border: 2px solid var(--rs-lime, #92C153); border-radius: 5px; font-family: var(--rs-font-body, "Work Sans"), sans-serif;
  font-size: 16px; font-weight: 600; line-height: 19px; text-decoration: none;
}
:is(.entry-content, .elementor-widget-theme-post-content, .editor-styles-wrapper) .wp-block-button:not(.is-style-outline) .wp-block-button__link:not(.has-background) { background-color: var(--rs-lime, #92C153); }
:is(.entry-content, .elementor-widget-theme-post-content, .editor-styles-wrapper) .wp-block-button:not(.is-style-outline) .wp-block-button__link:not(.has-text-color) { color: var(--rs-white, #FFFFFF); }
:is(.entry-content, .elementor-widget-theme-post-content) .wp-block-button:not(.is-style-outline) .wp-block-button__link:is(:hover, :focus-visible) { background-color: var(--rs-green, #037940); border-color: var(--rs-green, #037940); color: var(--rs-white, #FFFFFF); }
.elementor-widget-theme-post-content .wp-block-button.is-style-outline > .wp-block-button__link:not(.has-text-color) { color: var(--rs-dark, #242424); background: transparent; }
/* Touch sizes = rs-btn: 44px tall up to 1199px (tap target). */
@media (max-width: 1199px) { :is(.entry-content, .elementor-widget-theme-post-content) .wp-block-button .wp-block-button__link { min-height: 44px; } }
.elementor-widget-theme-post-content .wp-block-button.is-style-outline > .wp-block-button__link:is(:hover, :focus-visible) { color: var(--rs-white, #FFFFFF); background-color: var(--rs-lime, #92C153); }

/* Keyboard focus: one visible ring for every interactive element in content. */
:is(.entry-content, .elementor-widget-theme-post-content) :is(a, summary, button):focus-visible { outline: 2px solid var(--rs-green, #037940); outline-offset: 3px; border-radius: 2px; }

/* Left/right aligned images float beside the text on desktop, stack full width on phones. */
/* display:block + width (not core's display:table shrink-to-fit): WebKit keeps a table's old width after a resize,
   which collapsed the photo to 0px until reload. */
:is(.entry-content, .elementor-widget-theme-post-content, .editor-styles-wrapper) .wp-block-image:is(.alignleft, .alignright) { display: block; width: 50%; max-width: 50%; margin-top: .3em; margin-bottom: 1em; }
:is(.entry-content, .elementor-widget-theme-post-content) .wp-block-image.alignleft { float: left; margin-right: 30px; }
:is(.entry-content, .elementor-widget-theme-post-content) .wp-block-image.alignright { float: right; margin-left: 30px; }
:is(.entry-content, .elementor-widget-theme-post-content) :is(h1, h2, h3, h4, h5, h6, .wp-block-separator, .wp-block-buttons, .wp-block-table, .wp-block-columns,
  .wp-block-quote, .wp-block-pullquote, .wp-block-gallery, .wp-block-cover, .wp-block-media-text, .wp-block-embed, .wp-block-details, .wp-block-code, .wp-block-preformatted, .wp-block-verse, .wp-block-group) { clear: both; }
/* Same rounded corners as every other image. */
:is(.entry-content, .elementor-widget-theme-post-content, .editor-styles-wrapper) :is(.wp-block-cover, .wp-block-media-text__media img, .wp-block-embed iframe) { border-radius: 10px; overflow: hidden; }
@media (max-width: 767px) {
  :is(.entry-content, .elementor-widget-theme-post-content) .wp-block-image:is(.alignleft, .alignright) { float: none; width: 100%; max-width: 100%; margin-left: 0; margin-right: 0; }
}

/* Cover: readable text on the dim photo unless the editor picked a text colour. */
:is(.entry-content, .elementor-widget-theme-post-content, .editor-styles-wrapper) .wp-block-cover.is-dark .wp-block-cover__inner-container :is(p, h1, h2, h3, h4, h5, h6, li):not(.has-text-color) { color: var(--rs-white, #FFFFFF); }
:is(.entry-content, .elementor-widget-theme-post-content, .editor-styles-wrapper) .wp-block-cover .wp-block-cover__inner-container :is(h1, h2, h3, h4, h5, h6) { margin-top: 0; }

/* Group with a background colour gets inner spacing so text never touches its edge. */
:is(.entry-content, .elementor-widget-theme-post-content, .editor-styles-wrapper) .wp-block-group.has-background { padding: 24px 30px; border-radius: 10px; }

/* Verse matches preformatted/code. */
.wp-block-verse, .editor-styles-wrapper .wp-block-verse { background: var(--rs-mint, #F5FAED); border: 1px solid var(--ast-global-color-7, #DDE7CF); border-radius: 5px; padding: 16px 20px; font-size: 15px; color: var(--rs-dark, #242424); }

/* Details (FAQ-style toggle): bordered panel, bold question, lime marker, hover/focus. */
.wp-block-details, .editor-styles-wrapper .wp-block-details { border: 1px solid var(--ast-global-color-7, #DDE7CF); border-radius: 10px; padding: 14px 20px; }
.wp-block-details summary { cursor: pointer; font-weight: 600; color: var(--rs-dark, #242424); transition: color .2s ease; }
.wp-block-details summary::marker { color: var(--rs-lime, #92C153); }
.wp-block-details summary:hover { color: var(--rs-green, #037940); }
.wp-block-details[open] summary { margin-bottom: 10px; }

/* Captions: one style for every block. */
:is(.wp-block-embed, .wp-block-video, .wp-block-audio, .wp-block-media-text) figcaption { font-size: 14px; color: var(--ast-global-color-8, #5C5C5C); text-align: center; }

/* Tables fit the column: cells wrap instead of the table scrolling sideways (a scroll box can't be reached by
   keyboard — axe scrollable-region-focusable). Tighter cells on phones. */
.wp-block-table { overflow-x: visible; }
.wp-block-table table { width: 100%; }
.wp-block-table :is(th, td) { overflow-wrap: anywhere; }
@media (max-width: 767px) { .wp-block-table :is(th, td) { padding: 8px 10px; font-size: 14px; } }

/* Links in post text = rs-text links (green, 600, underline; dark on hover/focus). Buttons and Elementor-built
   content (its own classes) are excluded. */
:is(.entry-content, .elementor-widget-theme-post-content, .editor-styles-wrapper) :is(p, li, td, th, figcaption, cite, dd, summary) a:not(.wp-block-button__link):not([class*="e-"]):not(.elementor-button) {
  color: var(--rs-green, #037940); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; transition: color .2s ease;
}
:is(.entry-content, .elementor-widget-theme-post-content) :is(p, li, td, th, figcaption, cite, dd, summary) a:not(.wp-block-button__link):not([class*="e-"]):not(.elementor-button):is(:hover, :focus-visible) { color: var(--rs-dark, #242424); }

/* Media & text stacks at 600px (core) with the text glued to the image: give it the same 16px as other captions/blocks. */
@media (max-width: 600px) {
  .wp-block-media-text.is-stacked-on-mobile .wp-block-media-text__content { padding: 16px 0 0; }
}

/* ---- Post Content widget (single post template 927), front end only — moved from the widget's Custom CSS 2026-11-13 ----
   Same weight as Elementor's own "selector" (.elementor .elementor-element.<widget>). */
/* Every content image: max height + cover (user 2026-11-13), smaller on tablet / phone. */
.elementor .elementor-element.elementor-widget-theme-post-content img:not(.emoji):not(.wp-smiley):not(.wp-block-cover__image-background):not([width="16"]) { max-height: 480px; object-fit: cover; object-position: center; }
.elementor .elementor-element.elementor-widget-theme-post-content :is(.wp-block-image.size-large:not(.is-resized), .wp-block-image.size-full:not(.is-resized), .wp-block-media-text__media) img { width: 100%; }
/* Every block keeps clear space from its neighbours. */
.elementor .elementor-element.elementor-widget-theme-post-content :is(.wp-block-image, .wp-block-gallery, .wp-block-cover, .wp-block-media-text, .wp-block-columns, .wp-block-group, .wp-block-embed, .wp-block-table, .wp-block-details, .wp-block-buttons, .wp-block-quote, .wp-block-pullquote) { margin-block: 32px; }
@media (max-width: 1024px) {
  .elementor .elementor-element.elementor-widget-theme-post-content img:not(.emoji):not(.wp-smiley):not(.wp-block-cover__image-background):not([width="16"]) { max-height: 400px; }
}
@media (max-width: 767px) {
  .elementor .elementor-element.elementor-widget-theme-post-content img:not(.emoji):not(.wp-smiley):not(.wp-block-cover__image-background):not([width="16"]) { max-height: 320px; }
  .elementor .elementor-element.elementor-widget-theme-post-content :is(.wp-block-image, .wp-block-gallery, .wp-block-cover, .wp-block-media-text, .wp-block-columns, .wp-block-group, .wp-block-embed, .wp-block-table, .wp-block-details, .wp-block-buttons, .wp-block-quote, .wp-block-pullquote) { margin-block: 24px; }
}
/* Heading rhythm (Gutenberg headings only — Elementor content keeps its own spacing): more space above than below.
   Space above per level (QA round 7, 2026-11-16, was 1.6em = 72px before H2): fluid from 375px to 1366px,
   H2 32→40, H3 28→36, H4 26→32, H5/H6 24→30. After an image/table/quote block its own 32px (24px phone) margin
   collapses with these, so the larger of the two applies. */
.elementor .elementor-element.elementor-widget-theme-post-content :is(h2, h3, h4, h5, h6):not(.e-heading-base):not(.elementor-heading-title) { margin-bottom: .6em; }
.elementor .elementor-element.elementor-widget-theme-post-content h2:not(.e-heading-base):not(.elementor-heading-title) { margin-top: clamp(32px, calc(28.97px + .807vw), 40px); }
.elementor .elementor-element.elementor-widget-theme-post-content h3:not(.e-heading-base):not(.elementor-heading-title) { margin-top: clamp(28px, calc(24.97px + .807vw), 36px); }
.elementor .elementor-element.elementor-widget-theme-post-content h4:not(.e-heading-base):not(.elementor-heading-title) { margin-top: clamp(26px, calc(23.73px + .605vw), 32px); }
.elementor .elementor-element.elementor-widget-theme-post-content :is(h5, h6):not(.e-heading-base):not(.elementor-heading-title) { margin-top: clamp(24px, calc(21.73px + .605vw), 30px); }
.elementor .elementor-element.elementor-widget-theme-post-content > .elementor-widget-container > :first-child,
.elementor .elementor-element.elementor-widget-theme-post-content > :first-child { margin-top: 0; }

/* ---- Block editor only (2026-11-16): content + title max 1360px, centred. Astra's full-width single-post layout
   sets the editor to max-width: none; these classes exist only inside the editor canvas, so the front end is untouched. ---- */
.block-editor-block-list__layout.is-root-container { max-width: 1360px; margin-inline: auto; }
/* Title: Astra sets its width with !important (.ast-page-builder-template … max-width: calc(100% - 5px) !important),
   so only a heavier !important rule can match it to the content width. */
:is(.ast-page-builder-template, .editor-styles-wrapper) .editor-visual-editor__post-title-wrapper.edit-post-visual-editor__post-title-wrapper { max-width: 1360px !important; margin-inline: auto; }
/* Images stay inside their block: Astra's full-width editor rule (.ast-page-builder-template .is-root-container > … > *)
   sets max-width: none on them, so a 50% left/right-aligned image showed at its natural 1024px and overflowed. */
:is(.ast-page-builder-template, .editor-styles-wrapper) .is-root-container .wp-block-image img { max-width: 100%; }
/* ---- end block editor ---- */
