/* Shared controls. Component geometry is limited to controls, forms and native template fallbacks. */
body.flj-independent :is(.btn, .fljp-button, .flj-button, .wp-block-button__link, .flj-document .button) { display: inline-flex; align-items: center; justify-content: center; gap: 16px; min-height: var(--flj-control-height); padding: 13px 22px; border: 1px solid transparent; border-radius: var(--flj-radius); color: #fff; background: var(--flj-color-primary); font: 600 17px/1.4 var(--flj-font-body); text-decoration: none; box-shadow: none; }
body.flj-independent :is(.btn, .fljp-button, .flj-button, .wp-block-button__link, .flj-document .button):hover { color: #fff; background: var(--flj-color-primary-hover); text-decoration: none; }
body.flj-independent :is(.btn.outline, .btn-outline, .fljp-button--secondary, .flj-button--secondary) { background: transparent; border-color: currentColor; color: var(--flj-color-primary); }
body.flj-independent :is(.btn.outline, .btn-outline, .fljp-button--secondary, .flj-button--secondary):hover { color: var(--flj-color-primary-hover); background: var(--flj-color-silver); }
body.flj-independent :is(.hero, .cta, .rfq, .quality) :is(.btn.outline, .btn-outline) { color: inherit; }
body.flj-independent :is(.text-link, .fljp-text-link) { font-size: 17px; line-height: 1.5; font-weight: 600; text-underline-offset: 5px; }
body.flj-independent :is(.text-link, .fljp-text-link):hover { text-decoration: underline; }
body.flj-independent :is(.flj-native-form, .srfm-form, .flj-document form) :where(label, input, select, textarea) { font-family: var(--flj-font-body); font-size: 16px; line-height: 1.5; }
body.flj-independent :is(.flj-native-form, .srfm-form, .flj-document form) :where(label) { color: var(--flj-color-ink); font-weight: 500; }
body.flj-independent :is(.flj-native-form, .srfm-form, .flj-document form) :where(input:not([type=checkbox]):not([type=radio]):not([type=hidden]):not([type=submit]):not([type=file]), select, textarea) { max-width: 100%; min-height: var(--flj-control-height); padding: 11px 13px; border: 1px solid var(--flj-color-border); border-radius: var(--flj-radius); background: #fff; color: var(--flj-color-ink); box-shadow: none; }
body.flj-independent :is(.flj-native-form, .srfm-form, .flj-document form) :where(input, select, textarea):focus { border-color: var(--flj-color-primary); }
body.flj-independent :is(.flj-native-form, .srfm-form, .flj-document form) :where(input, textarea)::placeholder { color: var(--flj-color-muted); opacity: 1; }
body.flj-independent :is(.flj-native-form, .srfm-form) :where(input[type=checkbox], input[type=radio]) { accent-color: var(--flj-color-primary); }
body.flj-independent .srfm-form:is(#srfm-form-305, #srfm-form-4905) .srfm-submit-button { min-height: var(--flj-control-height); border-radius: var(--flj-radius); border-color: var(--flj-color-primary); background: var(--flj-color-primary); color: #fff; font: 600 17px/1.4 var(--flj-font-body); }
body.flj-independent .srfm-form:is(#srfm-form-305, #srfm-form-4905) .srfm-submit-button:hover { background: var(--flj-color-primary-hover); border-color: var(--flj-color-primary-hover); }
body.flj-independent .srfm-form .srfm-classic-upload-label { border-color: var(--flj-color-border); background: #fff; color: var(--flj-color-ink); border-radius: var(--flj-radius); font-size: 16px; }
body.flj-independent :where(input[aria-invalid=true], textarea[aria-invalid=true], select[aria-invalid=true]) { border-color: #b42318; }
body.flj-independent :where(.flj-pagination, .pagination, .nav-links) { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
body.flj-independent :where(.page-numbers) { display: inline-flex; align-items: center; justify-content: center; min-width: 44px; min-height: 44px; padding: 8px 14px; border: 1px solid var(--flj-color-border); border-radius: var(--flj-radius); color: var(--flj-color-ink); }
body.flj-independent :where(.page-numbers.current) { color: #fff; background: var(--flj-color-primary); border-color: var(--flj-color-primary); }
body.flj-independent :where(a.page-numbers:hover) { background: var(--flj-color-silver); }
body.flj-independent :where(.flj-search-form, .search-form) { display: flex; align-items: end; gap: 12px; flex-wrap: wrap; }
body.flj-independent :where(.flj-search-form, .search-form) label { flex: 1 1 250px; }
body.flj-independent :where(.search-field) { width: 100%; }
body.flj-independent :where(.search-submit) { min-height: var(--flj-control-height); padding: 12px 24px; border: 0; border-radius: var(--flj-radius); background: var(--flj-color-primary); color: #fff; font: 600 17px/1.4 var(--flj-font-body); }
body.flj-independent .flj-search-results { display: grid; gap: 32px; margin-block: 40px; max-width: var(--flj-reading-width); }
body.flj-independent .flj-search-result { border-bottom: 1px solid var(--flj-color-border); padding-bottom: 28px; }
body.flj-independent .flj-search-result :where(h2) { font-size: clamp(28px, 3vw, 38px); margin-bottom: 12px; }

/* WordPress template fallbacks, including records without migrated body markup. */
body.flj-independent :is(.flj-theme-utility, .flj-theme-page.flj-theme-legacy) { width: min(var(--flj-content-width), calc(100% - var(--flj-gutter) * 2)); margin-inline: auto; padding-block: var(--flj-space-section); }
body.flj-independent :is(.flj-theme-utility, .flj-theme-page.flj-theme-legacy) :where(h1) { margin: 0 0 24px; }
body.flj-independent :is(.flj-theme-utility, .flj-theme-page.flj-theme-legacy) :where(h2, h3, h4) { margin: 1.3em 0 .5em; }
body.flj-independent :is(.flj-theme-utility, .flj-theme-page.flj-theme-legacy) :where(p, ul, ol, blockquote, figure, table) { margin-block: 0 1.2em; }
body.flj-independent .flj-theme-utility .page-content { max-width: 76ch; }
body.flj-independent .flj-theme-legacy :where(.entry-content, .flj-v2-article-content) { font-family: var(--flj-font-body); font-size: var(--flj-size-body); line-height: 1.75; }
/* Legacy authoring includes long runs of nonbreaking spaces; keep the original text while allowing it to fit a narrow screen. */
body.flj-independent .flj-theme-legacy :where(.entry-content, .flj-v2-article-content, .elementor-widget-theme-post-content) :where(p, li) { overflow-wrap: anywhere; }
body.flj-independent .flj-theme-legacy :where(.entry-content, .flj-v2-article-content) :where(img) { display: block; max-width: 100%; height: auto; }
body.flj-independent .flj-theme-featured-image { max-width: 100%; margin: 0 0 28px; }
body.flj-independent .flj-theme-featured-image img { display: block; width: auto; max-width: 100%; height: auto; margin-inline: auto; }
body.flj-independent.flj-article-legacy .flj-theme-article .flj-v2-article-shell { width: 100%; max-width: 1288px; margin-inline: auto; padding-inline: var(--flj-gutter); }
body.flj-independent .flj-theme-archive .elementor-post__thumbnail { position: relative; overflow: hidden; }
body.flj-independent .flj-theme-post-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 36px 30px; }
body.flj-independent .flj-theme-post-grid :where(.elementor-post) { min-width: 0; }
body.flj-independent .flj-theme-post-grid :where(.elementor-post__title) { font-size: 25px; line-height: 1.3; margin: 18px 0 12px; }
body.flj-independent .flj-theme-post-grid :where(.elementor-post__meta-data) { display: flex; flex-wrap: wrap; gap: 10px; color: var(--flj-color-muted); font-size: 15px; }
body.flj-independent .flj-theme-post-grid :where(.elementor-post__excerpt) { margin-top: 12px; font-size: 17px; }
body.flj-independent .flj-theme-post-grid :where(.elementor-post__read-more) { display: inline-block; margin-top: 15px; color: var(--flj-color-primary); font-weight: 600; }
body.flj-independent .flj-theme-breadcrumbs ol { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 14px; margin: 0 0 25px; padding: 0; list-style: none; color: var(--flj-color-muted); font-size: 15px; }
body.flj-independent .flj-theme-breadcrumbs li + li::before { content: '/'; margin-inline-end: 14px; color: var(--flj-color-border); }
body.flj-independent .flj-theme-pagination { display: flex; flex-wrap: wrap; gap: 8px; margin-block: 35px; }
body.flj-independent .flj-theme-search { display: flex; align-items: stretch; flex-wrap: wrap; gap: 12px; max-width: 720px; margin-block: 24px; }
body.flj-independent .flj-theme-search > label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
body.flj-independent .flj-theme-search .search-field { flex: 1 1 240px; min-width: 0; width: auto; min-height: 48px; padding: 11px 14px; border: 1px solid var(--flj-color-border); border-radius: var(--flj-radius); color: var(--flj-color-ink); background: #fff; }
body.flj-independent .flj-theme-comments { clear: both; grid-column: 1/-1; max-width: var(--flj-reading-width); margin: 48px auto 0; padding-block: 32px; border-top: 1px solid var(--flj-color-border); font: 400 var(--flj-size-body)/1.65 var(--flj-font-body); }
body.flj-independent .flj-theme-comments :where(h2, h3) { margin-bottom: 22px; }
body.flj-independent .flj-theme-comments :where(.comment-list, .children) { list-style: none; padding-inline-start: 0; }
body.flj-independent .flj-theme-comments .children { padding-inline-start: 24px; }
body.flj-independent .flj-theme-comments .comment-body { padding-block: 22px; border-bottom: 1px solid var(--flj-color-border); }
body.flj-independent .flj-theme-comments .comment-author { display: flex; align-items: center; gap: 12px; }
body.flj-independent .flj-theme-comments .avatar { width: 48px; height: 48px; border-radius: 50%; }
body.flj-independent .flj-theme-comments .comment-metadata { margin-block: 8px 15px; color: var(--flj-color-muted); font-size: 15px; }
body.flj-independent .flj-theme-comments .comment-form > p { margin: 0 0 20px; }
body.flj-independent .flj-theme-comments .comment-form label { display: block; margin-bottom: 7px; color: var(--flj-color-ink); font-weight: 500; }
body.flj-independent .flj-theme-comments .comment-form :is(input:not([type=checkbox]):not([type=submit]), textarea) { width: 100%; max-width: 100%; min-height: 48px; padding: 11px 13px; border: 1px solid var(--flj-color-border); border-radius: var(--flj-radius); background: #fff; color: var(--flj-color-ink); }
body.flj-independent .flj-theme-comments .comment-form .comment-form-cookies-consent { display: flex; align-items: baseline; gap: 10px; }
body.flj-independent .flj-theme-comments .comment-form .comment-form-cookies-consent label { font-weight: 400; font-size: 16px; }
body.flj-independent .flj-theme-comments .submit { min-height: 48px; padding: 12px 22px; border: 0; border-radius: var(--flj-radius); color: #fff; background: var(--flj-color-primary); font: 600 17px/1.4 var(--flj-font-body); }
@media (max-width: 900px) { body.flj-independent .flj-theme-post-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { body.flj-independent .flj-theme-post-grid { grid-template-columns: 1fr; } body.flj-independent .flj-theme-comments .children { padding-inline-start: 14px; } }

/* Legacy related content remains a distinct section from engineering recommendations. */
body.flj-independent .flj-theme-related { margin: 48px 0; padding-top: 32px; border-top: 1px solid var(--flj-color-border); }
body.flj-independent .flj-theme-related__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 30px; }
body.flj-independent .flj-theme-related__card { min-width: 0; }
body.flj-independent .flj-theme-related__image { display: block; margin-bottom: 18px; }
body.flj-independent .flj-theme-related__image img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; }
body.flj-independent .flj-theme-related__title { margin: 0 0 12px; font-size: 25px; line-height: 1.3; }
body.flj-independent .flj-theme-related__meta { color: var(--flj-color-muted); font-size: 16px; line-height: 1.6; }
body.flj-independent .flj-theme-related__meta a:hover { color: var(--flj-color-primary); text-decoration: underline; }
@media (max-width: 600px) { body.flj-independent .flj-theme-related__grid { grid-template-columns: 1fr; } }
body.flj-independent .flj-theme-title .page-title { overflow-wrap: anywhere; }
body.flj-independent .flj-theme-breadcrumb { overflow-wrap: anywhere; font-size: 16px; line-height: 1.6; color: var(--flj-color-muted); }
