/*
Theme Name: Factory Child
Template: generatepress
Version: 2.8.3
Description: Shared child theme for every site-factory site. Per-site colour and fonts come from the factory_site option.
*/

:root {
	--f-accent: #9b1c31;
	--f-heading: Georgia, "Times New Roman", serif;
	--f-ink: #1d1d1f;
	--f-muted: #5f6368;
	--f-line: #e6e3de;
	--f-soft: #faf7f2;
}

body {
	font-family: "Segoe UI", Roboto, "Helvetica Neue", Helvetica, Arial, sans-serif;
	color: var(--f-ink);
	background: #fff;
	font-size: 18px;
	line-height: 1.7;
}

h1, h2, h3, .main-title {
	font-family: var(--f-heading);
	color: var(--f-ink);
	line-height: 1.25;
}

h1 { font-size: 2.2rem; }
h2 { font-size: 1.55rem; margin-top: 2.2em; }
h3 { font-size: 1.2rem; margin-top: 1.6em; }

a { color: var(--f-accent); }
a:hover, a:focus { color: var(--f-ink); }

/* Header */
.site-header { border-bottom: 1px solid var(--f-line); }
.main-title a, .main-title a:hover { color: var(--f-accent); text-decoration: none; }
.main-navigation, .main-navigation ul ul { background: transparent; }
.main-navigation .main-nav ul li a { color: var(--f-ink); font-size: 0.95rem; }
.main-navigation .main-nav ul li:hover > a,
.main-navigation .main-nav ul li[class*="current-menu-"] > a { color: var(--f-accent); background: transparent; }

/* Reading width for articles and pages */
body:not(.elementor-page):not(.f-adopted).single .content-area, body:not(.elementor-page):not(.f-adopted).page:not(.home) .content-area,
body.f-adopted.single-post:not(.elementor-page) .content-area { max-width: 780px; margin-left: auto; margin-right: auto; }
.separate-containers .inside-article { padding: 32px 20px; }
body:not(.elementor-page) .entry-content > p:first-of-type { font-size: 1.12em; }
.entry-meta { color: var(--f-muted); font-size: 0.85rem; }

/* Breadcrumbs and index heading */
.f-crumbs { font-size: 0.85rem; color: var(--f-muted); margin-bottom: 14px; }
.f-crumbs a { color: var(--f-muted); text-decoration: none; }
.f-crumbs a:hover { color: var(--f-accent); }
.f-index-header { padding: 28px 20px 0; }
.f-index-header p { color: var(--f-muted); }

/* Tables */
.entry-content table { border-collapse: collapse; width: 100%; font-size: 0.95rem; }
.entry-content th, .entry-content td { border: 1px solid var(--f-line); padding: 10px 12px; text-align: left; vertical-align: top; }
.entry-content thead th { background: var(--f-soft); }
.f-table-wrap { overflow-x: auto; }

/* Table of contents */
.f-toc { background: var(--f-soft); border-left: 3px solid var(--f-accent); padding: 16px 22px; margin: 28px 0; }
.f-toc strong { display: block; margin-bottom: 6px; font-family: var(--f-heading); }
.f-toc ol { margin: 0 0 0 1.2em; }
.f-toc li { margin: 2px 0; font-size: 0.95rem; }

/* Related guides */
.f-related { border-top: 1px solid var(--f-line); margin-top: 48px; padding-top: 8px; }
.f-related ul { list-style: none; margin: 0; }
.f-related li { margin: 8px 0; }

/* Home page */
.f-home { width: 100%; }
.f-home .site-main { padding: 0 20px; }
button, input, select, textarea, .main-navigation a { font-family: inherit; }
.f-hero { background: var(--f-soft); border-radius: 14px; padding: 64px 40px; text-align: center; margin: 28px 0 8px; }
.f-hero h1 { font-size: 2.7rem; margin: 0 auto 16px; max-width: 18em; }
.f-hero p { color: var(--f-muted); max-width: 40em; margin: 0 auto 26px; }
.f-btn { display: inline-block; background: var(--f-accent); color: #fff; padding: 12px 26px; border-radius: 999px; text-decoration: none; font-size: 1rem; }
.f-btn:hover, .f-btn:focus { background: var(--f-ink); color: #fff; }
.f-section { margin: 48px 0; }
.f-section > h2 { margin-top: 0; }
.f-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 22px; }
.f-card { display: block; border: 1px solid var(--f-line); border-radius: 12px; padding: 24px; text-decoration: none; color: var(--f-ink); background: #fff; transition: border-color .15s, transform .15s; }
.f-card:hover, .f-card:focus { border-color: var(--f-accent); transform: translateY(-2px); color: var(--f-ink); }
.f-card-cat { font-size: 0.75rem; letter-spacing: .08em; text-transform: uppercase; color: var(--f-accent); }
.f-card h3 { margin: 8px 0 10px; font-size: 1.25rem; }
.f-card p { margin: 0; color: var(--f-muted); font-size: 0.95rem; line-height: 1.55; }
.f-about { border-top: 1px solid var(--f-line); padding-top: 36px; max-width: 46em; }

/* Guides index */
.blog .inside-article, .archive .inside-article { border-bottom: 1px solid var(--f-line); }
.blog .entry-title, .archive .entry-title { font-size: 1.5rem; }
.blog .entry-title a, .archive .entry-title a { color: var(--f-ink); text-decoration: none; }
.blog .entry-title a:hover, .archive .entry-title a:hover { color: var(--f-accent); }

/* Footer */
.site-info { border-top: 1px solid var(--f-line); background: #fff; color: var(--f-muted); font-size: 0.9rem; }
.site-info a { color: var(--f-muted); }
.site-info a:hover { color: var(--f-accent); }

/* Cookie notice */
.f-consent { position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 9999; max-width: 560px; margin: 0 auto; background: #fff; border: 1px solid var(--f-line); border-radius: 12px; box-shadow: 0 8px 30px rgba(0,0,0,.12); padding: 18px 20px; font-size: 0.92rem; }
.f-consent[hidden] { display: none; }
.f-consent p { margin: 0 0 12px; }
.f-consent-actions { display: flex; gap: 10px; justify-content: flex-end; }
.f-consent button { border-radius: 999px; padding: 8px 20px; font-size: 0.92rem; cursor: pointer; border: 1px solid var(--f-ink); }
.f-consent-no, .f-consent-no:hover, .f-consent-no:focus { background: #fff; color: var(--f-ink); }
.f-consent-yes, .f-consent-yes:hover, .f-consent-yes:focus { background: var(--f-ink); color: #fff; }

/* Hero layout */
html { overflow-x: hidden; }
.f-hero2 { box-sizing: border-box; position: relative; width: 100vw; margin: 0 0 8px calc(50% - 50vw); padding: 44px 16px 40px; background-color: #012169; background-position: center; background-size: cover; background-repeat: no-repeat; }
.f-hero2::before { content: ""; position: absolute; inset: 0; background: rgba(0, 0, 0, .18); }
.f-hero2-inner { position: relative; max-width: 1140px; margin: 0 auto; display: flex; flex-direction: column; gap: 14px; }
.f-banner { margin: 0; background: #000; color: #fff; text-align: center; text-transform: uppercase; font-family: "Arial Black", Arial, "Liberation Sans", sans-serif; font-weight: 800; letter-spacing: .01em; line-height: 1.15; padding: 8px 16px; border-radius: 6px; font-size: clamp(1.05rem, 2.6vw, 1.9rem); }
h1.f-banner-main { font-size: clamp(1.6rem, 4.4vw, 3.1rem); padding: 10px 18px; color: #fff; }
.f-banner-hl { background: #0b4f7c; font-size: clamp(1.2rem, 3.2vw, 2.4rem); }
.f-hero2-sub { margin: 4px 0 0; color: #fff; text-align: center; font-family: Arial, "Liberation Sans", sans-serif; font-weight: 700; font-size: clamp(1.1rem, 2.6vw, 2.1rem); line-height: 1.25; text-shadow: 0 2px 10px rgba(0, 0, 0, .7); }
.f-hero2-buttons { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; margin-top: 18px; }
.f-hero2-btn, .f-hero2-btn:visited { display: block; background: #2f4fa8; color: #fff; text-align: center; padding: 13px 12px; border-radius: 6px; font-family: Arial, "Liberation Sans", sans-serif; font-weight: 700; text-decoration: none; box-shadow: 0 2px 0 rgba(0, 0, 0, .35); }
.f-hero2-btn:hover, .f-hero2-btn:focus { background: #0b4f7c; color: #fff; }
.f-linkgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 12px 28px; margin-bottom: 24px; }
.f-linkgrid a { font-weight: 600; line-height: 1.4; text-decoration: none; }
.f-linkgrid a:hover { text-decoration: underline; }

/* Compact header: name and menu on one short row */
body.f-header-compact .site-description { display: none; }
body.f-header-compact .inside-header { padding-top: 10px; padding-bottom: 10px; align-items: center; }
body.f-header-compact .main-title { font-size: 1.45rem; line-height: 1.2; margin: 0; }
body.f-header-compact .inside-header { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; }
body.f-header-compact .inside-header .site-branding { display: flex; align-items: center; min-height: 44px; margin: 0; }
body.f-header-compact .inside-header .main-navigation { float: none; margin-left: auto; }
body.f-header-compact .site-branding .main-title, body.f-header-compact .main-title p { margin: 0; }
body.f-layout-hero.home .site-content, body.f-layout-hero.home .site-main { padding-top: 0; margin-top: 0; }
body.f-layout-hero.home .inside-article { padding-top: 0; }
body.f-header-compact .main-navigation .main-nav ul li a { line-height: 44px; padding-left: 14px; padding-right: 14px; font-size: 0.9rem; }
body.f-header-compact .main-navigation .menu-toggle { line-height: 44px; }

/* Dark colour scheme */
body.f-dark { --f-ink: #f1f2f4; --f-muted: #b8bcc4; --f-line: #2b2f36; --f-soft: #16191e; background: #000; color: var(--f-ink); }
body.f-dark .site-header, body.f-dark .main-navigation, body.f-dark .main-navigation ul ul, body.f-dark .inside-header,
body.f-dark .separate-containers .inside-article, body.f-dark .one-container .container, body.f-dark .inside-article,
body.f-dark .page-header, body.f-dark .site-info, body.f-dark .site-footer, body.f-dark .footer-widgets,
body.f-dark .f-card, body.f-dark .f-consent, body.f-dark .container.grid-container { background-color: #101216; color: var(--f-ink); }
body.f-dark .site-header, body.f-dark .inside-header, body.f-dark .main-navigation, body.f-dark #site-navigation { background-color: #000; border-bottom-color: #222; }
body.f-dark .site-description { color: var(--f-muted); }
body.f-dark .main-title a, body.f-dark .main-title a:hover { color: #fff; text-transform: uppercase; font-family: Arial, "Liberation Sans", sans-serif; font-weight: 700; }
body.f-dark .main-navigation .main-nav ul li a, body.f-dark .menu-toggle, body.f-dark .menu-toggle:hover { color: #fff; background: transparent; }
body.f-dark h1, body.f-dark h2, body.f-dark h3, body.f-dark .entry-title a { color: #fff; }
body.f-dark .f-card h3 { color: var(--f-accent); }
body.f-dark .f-card:hover, body.f-dark .f-card:focus { color: var(--f-ink); }
body.f-dark .entry-content th, body.f-dark .entry-content td { border-color: var(--f-line); }
body.f-dark .f-consent-no, body.f-dark .f-consent-no:hover { background: #101216; color: #fff; border-color: #fff; }
body.f-dark .f-consent-yes, body.f-dark .f-consent-yes:hover { background: #fff; color: #000; border-color: #fff; }
body.f-dark a:hover, body.f-dark a:focus { color: #fff; }
body.f-dark .f-btn:hover, body.f-dark .f-btn:focus { background: #fff; color: #000; }

@media (max-width: 768px) {
	body.f-header-compact .inside-header { display: flex; flex-direction: row; flex-wrap: wrap; justify-content: space-between; text-align: left; padding: 8px 16px; }
	body.f-header-compact .inside-header .site-branding { text-align: left; margin-bottom: 0; }
	body.f-header-compact .main-title { font-size: 1.15rem; }
	body.f-header-compact .inside-header .main-navigation { margin: 0; width: auto; flex: 0 0 auto; }
	body.f-header-compact .main-navigation.toggled { width: 100%; }
	body { font-size: 17px; }
	h1 { font-size: 1.8rem; }
	.f-hero { padding: 40px 20px; }
	.f-home .site-main { padding: 0 16px; }
	.f-hero h1 { font-size: 2rem; }
}
