/*
 Theme Name:   GFCH Theme
 Theme URI:    https://gfchealth.org
 Description:  Child theme for Global Foundation for Community Health, built on GeneratePress.
 Author:       GFCH
 Author URI:   https://gfchealth.org
 Template:     generatepress
 Version:      1.0.0
 License:      GNU General Public License v2 or later
 License URI:  https://www.gnu.org/licenses/gpl-2.0.html
 Text Domain:  gfch-theme
*/

/* ==========================================================================
   Design Tokens
   ========================================================================== */

:root {
	--blue: #1B4F8A;
	--red: #D42A35;
	--yellow: #E8960C;
	--green: #1E7A3E;
	--navy: #0F2B4C;
	--cream: #FAFAF7;
	--ice: #EDF2F8;
	--mint: #EBF5EE;
	--text: #1A1A2E;
	--text-mid: #3D4F5F;
	--text-light: #6B7C8B;
	--radius: 16px;
	--radius-lg: 24px;
	--radius-xl: 32px;
	--pill: 100px;
	--shadow-sm: 0 2px 8px rgba(15, 43, 76, 0.06);
	--shadow-md: 0 4px 20px rgba(15, 43, 76, 0.1);
	--shadow-lg: 0 8px 40px rgba(15, 43, 76, 0.14);
	--flag-stripe: linear-gradient(to right, var(--red) 25%, var(--blue) 25%, var(--blue) 50%, var(--yellow) 50%, var(--yellow) 75%, var(--green) 75%);
}

/* ==========================================================================
   Base
   ========================================================================== */

* { box-sizing: border-box; }

/* Prevent horizontal scroll */
html, body { overflow-x: hidden !important; }

/* GP containers the .site at max-width 1200px — we need full width for alignfull blocks */
.site {
	max-width: 100% !important;
	margin-left: 0 !important;
	margin-right: 0 !important;
	overflow-x: hidden;
}

body {
	font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
	color: var(--text);
	background: var(--cream);
	line-height: 1.7;
	-webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
	font-family: 'DM Sans', 'Inter', sans-serif;
	color: var(--navy);
	font-weight: 800;
	line-height: 1.15;
	letter-spacing: -0.03em;
}

p {
	color: var(--text-mid);
	line-height: 1.85;
}

a {
	color: var(--green);
	text-decoration: none;
	transition: color 0.2s ease;
}

a:hover { color: var(--blue); }

/* ==========================================================================
   Layout — kill sidebar, full width
   ========================================================================== */

#right-sidebar, #left-sidebar, .sidebar, .widget-area {
	display: none !important;
}

.site-content .content-area {
	width: 100% !important;
	float: none !important;
}

.one-container .site-content,
.site-content { max-width: 100%; padding: 0; }

.one-container .inside-article,
.inside-article { padding: 0; background: transparent; box-shadow: none; }

.one-container .entry-content,
.entry-content { padding: 0; }

.page .entry-header { display: none; }

.entry-content .alignfull {
	margin-left: 0 !important;
	margin-right: 0 !important;
	max-width: 100% !important;
	width: 100% !important;
}

/* ==========================================================================
   HEADER
   ========================================================================== */

.site-header {
	background: #fff;
	border: none;
	box-shadow: var(--shadow-sm);
	position: sticky;
	top: 0;
	z-index: 1000;
}

.site-header::after {
	content: '';
	display: block;
	height: 3px;
	background: var(--flag-stripe);
}

.inside-header {
	padding: 0.6rem 2.5rem !important;
	display: flex !important;
	align-items: center !important;
	max-width: 1400px;
	margin: 0 auto;
}

/* Hide GP default logo */
.site-branding-container .site-logo { display: none !important; }
.gfch-branding { display: block !important; flex-shrink: 0; }

/* Custom logo */
.gfch-logo-wrap { flex-shrink: 0; margin-right: auto; }

.gfch-logo-link {
	display: flex;
	align-items: center;
	text-decoration: none !important;
	color: var(--navy) !important;
	transition: opacity 0.2s;
}

.gfch-logo-link:hover { opacity: 0.85; }

.gfch-logo-mark {
	font-family: 'DM Sans', sans-serif;
	font-weight: 900;
	font-size: 2.05rem;
	letter-spacing: -0.04em;
	color: var(--navy);
	line-height: 1;
}

.gfch-logo-dots {
	display: flex;
	flex-direction: column;
	gap: 2px;
	margin-left: 5px;
	margin-right: 14px;
}

.gfch-logo-dots .dot {
	width: 7px; height: 7px;
	border-radius: 50%;
	display: block;
}

.dot-red    { background: var(--red); }
.dot-blue   { background: var(--blue); }
.dot-yellow { background: var(--yellow); }
.dot-green  { background: var(--green); }

.gfch-logo-sep {
	width: 1px; height: 34px;
	background: #D1D5DB;
	margin-right: 12px;
	flex-shrink: 0;
}

.gfch-logo-text {
	display: flex;
	flex-direction: column;
	line-height: 1.3;
}

.gfch-logo-line1 {
	font-family: 'Inter', sans-serif;
	font-size: 0.77rem;
	font-weight: 500;
	color: var(--text-light);
}

.gfch-logo-line2 {
	font-family: 'Inter', sans-serif;
	font-size: 0.77rem;
	font-weight: 800;
	color: var(--navy);
}

/* Hide GP duplicate mobile toggle wrapper + Rise Blocks off-canvas nav */
nav.mobile-menu-control-wrapper { display: none !important; }
.nav-container, .hc-offcanvas-nav { display: none !important; }
.hc-nav-trigger { display: none !important; }

/* Nav */
.main-navigation { background: transparent !important; }
.main-navigation .inside-navigation { padding: 0 !important; }

.main-navigation .main-nav ul li a {
	color: var(--text-mid) !important;
	font-family: 'Inter', sans-serif;
	font-weight: 500;
	font-size: 0.88rem;
	text-transform: none;
	letter-spacing: 0;
	padding: 0.5rem 1rem !important;
	border-radius: var(--radius);
	transition: all 0.2s ease;
}

.main-navigation .main-nav ul li a:hover,
.main-navigation .main-nav ul li.current-menu-item > a,
.main-navigation .main-nav ul li.current-menu-ancestor > a,
.main-navigation .main-nav ul li.current-menu-parent > a,
.main-navigation .main-nav ul li.sfHover > a {
	color: var(--green) !important;
	background: var(--mint) !important;
}

/* Last nav item = green CTA button */
.main-navigation .main-nav > ul > li:last-child > a {
	background: var(--green) !important;
	color: #fff !important;
	border-radius: var(--radius) !important;
	padding: 0.35rem 1.2rem !important;
	font-weight: 700;
	font-size: 0.82rem;
	box-shadow: 0 2px 12px rgba(30, 122, 62, 0.2);
}

.main-navigation .main-nav > ul > li:last-child > a:hover {
	background: #166432 !important;
	transform: translateY(-1px);
	box-shadow: 0 4px 20px rgba(30, 122, 62, 0.3);
}

/* Dropdown menus */
.main-navigation ul ul {
	background: #fff !important;
	border: 1px solid rgba(0,0,0,0.06) !important;
	border-radius: var(--radius) !important;
	box-shadow: var(--shadow-lg) !important;
	padding: 0.5rem !important;
	min-width: 240px;
}

.main-navigation ul ul li a {
	border-radius: 10px !important;
	padding: 0.6rem 1rem !important;
	font-size: 0.85rem !important;
}

/* ==========================================================================
   HERO — bold gradient, no competing image
   ========================================================================== */

.gfch-hero {
	background: linear-gradient(145deg, var(--navy) 0%, #14395E 40%, var(--blue) 100%) !important;
	position: relative;
	overflow: hidden;
}

/* Subtle geometric accent — large faded circle */
.gfch-hero::before {
	content: '';
	position: absolute;
	top: -40%;
	right: -15%;
	width: 600px;
	height: 600px;
	border-radius: 50%;
	background: radial-gradient(circle, rgba(30, 122, 62, 0.12) 0%, transparent 70%);
	pointer-events: none;
}

.gfch-hero::after {
	content: '';
	position: absolute;
	bottom: -30%;
	left: -10%;
	width: 500px;
	height: 500px;
	border-radius: 50%;
	background: radial-gradient(circle, rgba(232, 150, 12, 0.08) 0%, transparent 70%);
	pointer-events: none;
}

/* Hero h1 */
.gfch-hero h1 {
	font-family: 'DM Sans', sans-serif !important;
	font-weight: 900 !important;
	letter-spacing: -0.03em !important;
	line-height: 1.08 !important;
	color: #fff !important;
	margin-bottom: 1.2rem;
}

/* Hero paragraph text */
.gfch-hero p {
	position: relative;
	z-index: 1;
}

/* Faces strip below hero — edge to edge, no border radius */
.gfch-faces-strip {
	line-height: 0;
	overflow: hidden !important;
}

/* Hide the gallery layout before JS replaces it */
.gfch-faces-strip .wp-block-gallery {
	display: flex;
	gap: 0;
	overflow: hidden;
}

.gfch-faces-strip .wp-block-gallery .wp-block-image {
	margin: 0 !important;
	background: transparent !important;
	box-shadow: none !important;
	border-radius: 0 !important;
}

.gfch-faces-strip .wp-block-gallery .wp-block-image:hover {
	transform: none !important;
	box-shadow: none !important;
}

/* Donate button in hero — with celebration sparkles on hover */
.gfch-hero .custom-donate-button {
	position: relative;
	display: inline-block;
}

.gfch-hero .custom-donate-button .wp-block-button__link {
	background: var(--red) !important;
	color: #fff !important;
	border-radius: var(--pill) !important;
	padding: 16px 48px !important;
	font-size: 1rem !important;
	font-weight: 800 !important;
	font-family: 'Inter', sans-serif !important;
	letter-spacing: 0.08em !important;
	box-shadow: 0 6px 28px rgba(212, 42, 53, 0.4);
	transition: all 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
	white-space: nowrap !important;
	width: auto !important;
	display: inline-block !important;
	position: relative;
	overflow: visible;
}

/* Heart particles — hidden by default */
.gfch-hero .custom-donate-button::before,
.gfch-hero .custom-donate-button::after {
	content: '♥';
	position: absolute;
	color: var(--red);
	opacity: 0;
	pointer-events: none;
	transition: none;
}

.gfch-hero .custom-donate-button::before {
	font-size: 16px;
	top: -4px;
	right: -2px;
}

.gfch-hero .custom-donate-button::after {
	font-size: 12px;
	bottom: -2px;
	left: 2px;
}

/* On hover: button lifts + sparkles burst out */
.gfch-hero .custom-donate-button:hover .wp-block-button__link {
	background: #b8222d !important;
	transform: translateY(-4px) scale(1.04);
	box-shadow: 0 12px 44px rgba(212, 42, 53, 0.5);
}

.gfch-hero .custom-donate-button:hover::before {
	opacity: 1;
	animation: sparkle-top-right 0.7s ease-out forwards;
}

.gfch-hero .custom-donate-button:hover::after {
	opacity: 1;
	animation: sparkle-bottom-left 0.8s ease-out 0.1s forwards;
}

@keyframes sparkle-top-right {
	0%   { opacity: 0; transform: translate(0, 0) scale(0.5) rotate(0deg); }
	30%  { opacity: 1; }
	100% { opacity: 0; transform: translate(18px, -22px) scale(1.2) rotate(20deg); }
}

@keyframes sparkle-bottom-left {
	0%   { opacity: 0; transform: translate(0, 0) scale(0.5); }
	30%  { opacity: 1; }
	100% { opacity: 0; transform: translate(-16px, 20px) scale(1.1); }
}

/* Hero outline button ("Learn More") */
.gfch-hero .gfch-hero-outline .wp-block-button__link {
	background: transparent !important;
	color: #fff !important;
	border: 2px solid rgba(255, 255, 255, 0.4) !important;
	border-radius: var(--pill) !important;
	padding: 14px 40px !important;
	font-weight: 600 !important;
	box-shadow: none !important;
}

.gfch-hero .gfch-hero-outline .wp-block-button__link:hover {
	background: rgba(255, 255, 255, 0.1) !important;
	border-color: rgba(255, 255, 255, 0.7) !important;
	transform: translateY(-2px);
}

/* Legacy cover block hero styles (for other pages that may use cover blocks) */
.wp-block-cover .wp-block-cover__inner-container p {
	color: #fff !important;
}

.wp-block-cover .custom-donate-button .wp-block-button__link:hover,
.wp-block-cover .wp-block-button .wp-block-button__link:hover {
	background: #b8222d !important;
	transform: translateY(-3px) scale(1.02);
	box-shadow: 0 10px 40px rgba(212, 42, 53, 0.45);
}

/* Hero footnote */
.wp-block-cover .wp-block-cover__inner-container > p:last-child {
	font-size: 0.75rem !important;
	opacity: 0.6;
	margin-top: 2rem !important;
	max-width: 600px;
	margin-left: auto;
	margin-right: auto;
}

/* ==========================================================================
   STORY SLIDER / CAROUSEL
   ========================================================================== */

/* If Rise Blocks slider exists */
.rise-blocks-page-slider {
	padding: 4rem 2rem !important;
	margin: 0 !important;
	background: var(--ice);
}

.rise-blocks-page-slider .rise-blocks-page-slider-item {
	border-radius: var(--radius-xl) !important;
	overflow: hidden !important;
	box-shadow: var(--shadow-md);
}

/* If slider is broken, style the fallback block content */
.wp-block-rise-blocks-page-slider {
	padding: 4rem 2rem;
	background: var(--ice);
}

/* ==========================================================================
   "WHO WE ARE" SECTION
   ========================================================================== */

/* Override inline grey color */
p[style*="color:#82828c"],
p[style*="color: #82828c"] {
	color: var(--green) !important;
	font-family: 'Inter', sans-serif !important;
	font-weight: 700 !important;
	font-size: 0.78rem !important;
	letter-spacing: 0.14em !important;
	text-transform: uppercase !important;
}

.entry-content > .wp-block-group:not(.alignfull) {
	max-width: 880px;
	margin: 0 auto;
	padding: 5rem 2.5rem !important;
	text-align: center;
}

.entry-content > .wp-block-group:not(.alignfull) h2 {
	font-size: 2.8rem;
	margin-bottom: 0.3rem;
}

/* Flag bar under headings */
.entry-content > .wp-block-group:not(.alignfull) h2::after {
	content: '';
	display: block;
	width: 80px;
	height: 4px;
	margin: 1.2rem auto 2rem;
	border-radius: 2px;
	background: var(--flag-stripe);
}

.entry-content > .wp-block-group:not(.alignfull) p.has-text-align-center {
	font-size: 1.1rem;
	line-height: 1.9;
	color: var(--text-mid);
	max-width: 660px;
	margin-left: auto;
	margin-right: auto;
	margin-bottom: 1.5rem;
}

/* ==========================================================================
   DARK "OUR STORIES" BAND
   ========================================================================== */

.wp-block-group.alignfull.has-black-background-color {
	background: linear-gradient(135deg, var(--navy) 0%, #162D4A 100%) !important;
	padding: 4.5rem 2.5rem !important;
	margin: 0 !important;
	border-radius: 0 !important;
	text-align: center;
}

.wp-block-group.alignfull.has-black-background-color p {
	color: rgba(255, 255, 255, 0.85) !important;
	max-width: 620px;
	margin: 0 auto 1.5rem;
	font-size: 1.15rem;
	line-height: 1.75;
}

.wp-block-group.alignfull.has-black-background-color .wp-block-button__link {
	background: var(--yellow) !important;
	color: var(--navy) !important;
	font-weight: 800 !important;
	border-radius: var(--pill) !important;
	padding: 14px 40px !important;
	letter-spacing: 0.02em;
	box-shadow: 0 4px 16px rgba(232, 150, 12, 0.3);
}

.wp-block-group.alignfull.has-black-background-color .wp-block-button__link:hover {
	background: #fff !important;
	color: var(--navy) !important;
	transform: translateY(-2px);
}

/* ==========================================================================
   "OUR MISSION" SECTION
   ========================================================================== */

.entry-content > .wp-block-group:last-of-type {
	max-width: 880px;
	margin: 0 auto;
	padding: 5rem 2.5rem !important;
}

.entry-content > .wp-block-group:last-of-type h2 {
	font-size: 2.5rem;
	text-align: center;
}

.entry-content > .wp-block-group:last-of-type h2::after {
	content: '';
	display: block;
	width: 80px;
	height: 4px;
	margin: 1.2rem auto 2rem;
	border-radius: 2px;
	background: var(--flag-stripe);
}

/* SEED SCALE image */
.entry-content .wp-block-image img {
	border-radius: var(--radius-lg);
	box-shadow: var(--shadow-md);
}

/* ==========================================================================
   BUTTONS — all pill-shaped
   ========================================================================== */

.wp-block-button__link,
button:not(.menu-toggle),
input[type="submit"] {
	background: var(--green) !important;
	color: #fff !important;
	border: none;
	border-radius: var(--pill) !important;
	padding: 14px 36px;
	font-family: 'Inter', sans-serif;
	font-weight: 700;
	font-size: 0.92rem;
	letter-spacing: 0.02em;
	transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
	box-shadow: 0 2px 12px rgba(30, 122, 62, 0.15);
	cursor: pointer;
}

.wp-block-button__link:hover,
button:not(.menu-toggle):hover,
input[type="submit"]:hover {
	background: var(--blue) !important;
	color: #fff !important;
	transform: translateY(-2px);
	box-shadow: 0 6px 24px rgba(27, 79, 138, 0.25);
}

.is-style-outline .wp-block-button__link {
	background: transparent !important;
	color: var(--green) !important;
	border: 2px solid var(--green) !important;
	box-shadow: none;
}

.is-style-outline .wp-block-button__link:hover {
	background: var(--green) !important;
	color: #fff !important;
}

/* ==========================================================================
   SPACERS — reduce excessive whitespace
   ========================================================================== */

.wp-block-spacer { max-height: 20px !important; }

/* ==========================================================================
   IMAGES
   ========================================================================== */

.entry-content img,
.wp-block-image img { border-radius: var(--radius); }

.wp-block-image.is-style-rounded img { border-radius: 50%; }

/* ==========================================================================
   FOOTER
   ========================================================================== */

.site-footer,
.site-info {
	background: var(--navy) !important;
	color: rgba(255, 255, 255, 0.7) !important;
}

.site-footer::before {
	content: '';
	display: block;
	height: 3px;
	background: var(--flag-stripe);
}

.site-info {
	padding: 1.5rem 2rem !important;
	font-size: 0.85rem;
	border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.site-footer a,
.site-info a { color: var(--yellow) !important; }

.site-footer a:hover,
.site-info a:hover { color: #fff !important; }

/* Custom footer content */
.gfch-footer-content {
	padding: 3.5rem 2.5rem 2rem;
}

.gfch-footer-inner {
	display: grid;
	grid-template-columns: 1.5fr 1fr 1fr;
	gap: 3rem;
	max-width: 1100px;
	margin: 0 auto;
}

.gfch-footer-logo {
	display: flex;
	align-items: center;
	margin-bottom: 1rem;
}

.gfch-footer-logo .gfch-logo-dots {
	display: flex;
	flex-direction: column;
	gap: 1.5px;
}

.gfch-footer-logo .dot {
	width: 5px; height: 5px;
	border-radius: 50%;
	display: block;
}

.gfch-footer-desc {
	color: rgba(255, 255, 255, 0.6) !important;
	font-size: 0.85rem !important;
	line-height: 1.7 !important;
	margin-bottom: 0.5rem !important;
}

.gfch-footer-legal {
	color: rgba(255, 255, 255, 0.35) !important;
	font-size: 0.75rem !important;
	font-weight: 500;
}

.gfch-footer-col h4 {
	color: #fff !important;
	font-family: 'DM Sans', sans-serif;
	font-size: 0.9rem;
	font-weight: 700;
	margin-bottom: 1rem;
	letter-spacing: 0.02em;
}

.gfch-footer-col ul {
	list-style: none;
	padding: 0;
	margin: 0;
}

.gfch-footer-col ul li {
	margin-bottom: 0.6rem;
}

.gfch-footer-col ul li a {
	color: rgba(255, 255, 255, 0.55) !important;
	font-size: 0.85rem;
	transition: color 0.2s;
}

.gfch-footer-col ul li a:hover {
	color: var(--yellow) !important;
}

@media (max-width: 768px) {
	.gfch-footer-inner {
		grid-template-columns: 1fr;
		gap: 2rem;
	}
	.gfch-footer-content {
		padding: 2.5rem 1.5rem 1.5rem;
	}
}

/* ==========================================================================
   ANIMATIONS & MICRO-INTERACTIONS
   ========================================================================== */

/* --- Gentle float for hero text (short, subtle) --- */
.gfch-hero h1 {
	animation: hero-fade-up 0.4s ease-out both;
}

.gfch-hero > div > p:nth-child(1) {
	animation: hero-fade-up 0.35s ease-out both;
}

.gfch-hero > div > p:nth-child(3) {
	animation: hero-fade-up 0.45s ease-out 0.05s both;
}

@keyframes hero-fade-up {
	0%   { opacity: 0; transform: translateY(10px); }
	100% { opacity: 1; transform: translateY(0); }
}

/* --- Faces strip: infinite seamless horizontal scroll --- */
.gfch-faces-strip {
	overflow: hidden !important;
}

.gfch-faces-strip figure {
	margin: 0 !important;
}

.gfch-faces-track-wrapper {
	overflow: hidden !important;
	margin: 0 !important;
}

.gfch-faces-strip .faces-scroll-track {
	display: flex;
	width: max-content;
	animation: faces-scroll 50s linear infinite;
}

.gfch-faces-strip .faces-scroll-track img {
	height: clamp(160px, 16vw, 270px);
	width: clamp(130px, 14vw, 230px);
	max-width: none !important;
	flex-shrink: 0;
	border-radius: 12px !important;
	object-fit: cover;
	object-position: center 20%;
	margin-right: clamp(8px, 1vw, 16px);
	box-shadow: none !important;
}

@keyframes faces-scroll {
	0%   { transform: translateX(0); }
	100% { transform: translateX(-50%); }
}

/* --- Section headings: flag bar grows in --- */
.entry-content > .wp-block-group:not(.alignfull) h2::after {
	animation: bar-grow 0.6s ease-out both;
}

@keyframes bar-grow {
	0%   { width: 0; opacity: 0; }
	100% { width: 80px; opacity: 1; }
}

/* --- Buttons: gentle pulse on idle for primary CTAs --- */
.gfch-hero .custom-donate-button .wp-block-button__link {
	animation: gentle-pulse 3s ease-in-out 2s infinite;
}

@keyframes gentle-pulse {
	0%, 100% { box-shadow: 0 6px 28px rgba(212, 42, 53, 0.4); }
	50%      { box-shadow: 0 6px 36px rgba(212, 42, 53, 0.6); }
}

/* Stop pulse on hover (the hover effect takes over) */
.gfch-hero .custom-donate-button:hover .wp-block-button__link {
	animation: none;
}

/* --- Nav CTA: subtle glow --- */
.main-navigation .main-nav > ul > li:last-child > a {
	animation: nav-glow 4s ease-in-out 3s infinite;
}

@keyframes nav-glow {
	0%, 100% { box-shadow: 0 2px 12px rgba(30, 122, 62, 0.2); }
	50%      { box-shadow: 0 2px 20px rgba(30, 122, 62, 0.35); }
}

/* --- All green buttons: lift + shadow on hover --- */
.wp-block-button__link {
	transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94) !important;
}

/* --- "Read Their Stories" yellow button: warm glow on hover --- */
.wp-block-group.has-black-background-color .wp-block-button__link:hover {
	box-shadow: 0 6px 28px rgba(232, 150, 12, 0.5) !important;
}

/* --- Logo dots: stagger-fade on page load --- */
.gfch-logo-dots .dot {
	animation: dot-pop 0.4s ease-out both;
}

.gfch-logo-dots .dot-red    { animation-delay: 0.1s; }
.gfch-logo-dots .dot-blue   { animation-delay: 0.2s; }
.gfch-logo-dots .dot-yellow { animation-delay: 0.3s; }
.gfch-logo-dots .dot-green  { animation-delay: 0.4s; }

@keyframes dot-pop {
	0%   { opacity: 0; transform: scale(0); }
	60%  { transform: scale(1.3); }
	100% { opacity: 1; transform: scale(1); }
}

/* --- Flag stripe: shimmer animation --- */
.site-header::after {
	background-size: 200% 100%;
	animation: flag-shimmer 60s linear infinite;
}

@keyframes flag-shimmer {
	0%   { background-position: 0% 0; }
	100% { background-position: 200% 0; }
}

/* --- Reduce motion for accessibility --- */
@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after {
		animation-duration: 0.01ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.01ms !important;
	}
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */

@media (max-width: 1024px) {
	.inside-header { padding: 0.5rem 1.5rem !important; }
	.gfch-logo-mark { font-size: 1.6rem; }

	.wp-block-cover .wp-block-cover__inner-container > p:first-child,
	.wp-block-cover .wp-block-cover__inner-container > p:first-child strong {
		font-size: 2.5rem !important;
	}
}

@media (max-width: 768px) {
	.inside-header { padding: 0.5rem 1rem !important; }

	/* Hide full text, show abbreviation only */
	.gfch-logo-sep,
	.gfch-logo-text { display: none; }
	.gfch-logo-mark { font-size: 1.5rem; }
	.gfch-logo-dots { margin-right: 0; }

	/* Mobile nav toggle */
	.menu-toggle {
		background: transparent !important;
		color: var(--navy) !important;
		border: 1.5px solid var(--ice) !important;
		border-radius: var(--radius) !important;
		padding: 0.4rem 0.9rem !important;
		font-weight: 600 !important;
		font-size: 0.85rem !important;
		box-shadow: none !important;
	}

	/* Hero */
	.wp-block-cover.alignfull { min-height: 440px !important; }

	.wp-block-cover .wp-block-cover__inner-container {
		padding: 2.5rem 1.5rem;
	}

	.wp-block-cover .wp-block-cover__inner-container > p:first-child,
	.wp-block-cover .wp-block-cover__inner-container > p:first-child strong {
		font-size: 2rem !important;
	}

	.wp-block-cover .wp-block-cover__inner-container > p:nth-child(2) {
		font-size: 1rem !important;
	}

	/* Sections */
	.entry-content > .wp-block-group:not(.alignfull) {
		padding: 3.5rem 1.5rem !important;
	}

	.entry-content > .wp-block-group:not(.alignfull) h2,
	.entry-content > .wp-block-group:last-of-type h2 {
		font-size: 1.9rem;
	}

	.wp-block-group.alignfull.has-black-background-color {
		padding: 3rem 1.5rem !important;
	}

	.wp-block-group.alignfull.has-black-background-color p {
		font-size: 1rem;
	}

	.entry-content > .wp-block-group:last-of-type {
		padding: 3.5rem 1.5rem !important;
	}

	/* Inner pages mobile */
	.page:not(.home) .entry-content {
		padding: 1.5rem 1.2rem 3rem;
	}

	.page:not(.home) .entry-content h2 {
		font-size: 1.6rem;
	}

	.page:not(.home) .entry-content h3 {
		font-size: 1.25rem;
	}

	.wp-block-pullquote {
		padding: 1.5rem 1rem !important;
	}

	.wp-block-pullquote blockquote p {
		font-size: 1.05rem !important;
	}

	/* Team columns stack on mobile */
	.page:not(.home) .wp-block-columns {
		flex-direction: column !important;
	}

	.page:not(.home) .wp-block-column .wp-block-image img {
		max-height: 300px;
	}
}

/* ==========================================================================
   INNER PAGES — consistent styling for About, Team, Stories, Contact, etc.
   ========================================================================== */

/* Inner pages: full-width container, content constrained via children */
.page:not(.home) .entry-content {
	max-width: 100% !important;
	margin: 0 !important;
	padding: 0 !important;
}

/* But homepage should stay full-width */
.home .entry-content {
	max-width: 100%;
	padding: 0;
}

/* Non-fullwidth blocks on inner pages get constrained + centered */
.page:not(.home) .entry-content > *:not(.alignfull) {
	max-width: 880px;
	margin-left: auto;
	margin-right: auto;
	padding-left: 2.5rem;
	padding-right: 2.5rem;
	box-sizing: border-box;
}

/* First content block gets top spacing */
.page:not(.home) .entry-content > *:first-child {
	margin-top: 2.5rem;
}

/* Last content block gets bottom spacing */
.page:not(.home) .entry-content > *:last-child {
	margin-bottom: 3rem;
}

/* Alignfull blocks go edge-to-edge naturally (parent is 100%) */
.page:not(.home) .entry-content > .alignfull {
	max-width: 100% !important;
	padding-left: 0;
	padding-right: 0;
	overflow-x: hidden !important;
	box-sizing: border-box !important;
}

/* Tame inline padding on full-width blocks (some have 100px padding) */
.page:not(.home) .entry-content > .alignfull[style*="padding"] {
	padding-left: clamp(1.5rem, 5vw, 100px) !important;
	padding-right: clamp(1.5rem, 5vw, 100px) !important;
}

/* Prevent fixed-width images from causing overflow */
.page:not(.home) .entry-content img[style*="width"],
.page:not(.home) .entry-content .alignfull img {
	max-width: 100% !important;
	height: auto !important;
}

/* Columns inside full-width blocks */
.page:not(.home) .entry-content .alignfull .wp-block-columns {
	max-width: 1200px;
	margin-left: auto !important;
	margin-right: auto !important;
}

/* Prevent any child inside alignfull from exceeding parent */
.page:not(.home) .entry-content .alignfull * {
	max-width: 100%;
	box-sizing: border-box;
}

/* --- Pullquotes (Lincoln quote, etc.) --- */
.wp-block-pullquote {
	border: none !important;
	padding: 2.5rem 2rem !important;
	margin: 2rem auto !important;
	max-width: 720px;
	position: relative;
}

.wp-block-pullquote::before {
	content: '\201C';
	font-family: 'DM Sans', sans-serif;
	font-size: 5rem;
	color: var(--green);
	opacity: 0.2;
	position: absolute;
	top: -0.5rem;
	left: 0.5rem;
	line-height: 1;
}

.wp-block-pullquote blockquote {
	border: none !important;
	padding: 0 !important;
}

.wp-block-pullquote blockquote p {
	font-family: 'DM Sans', sans-serif !important;
	font-size: 1.25rem !important;
	font-weight: 500 !important;
	color: var(--navy) !important;
	font-style: italic;
	line-height: 1.7 !important;
}

.wp-block-pullquote blockquote cite,
.wp-block-pullquote cite {
	font-family: 'Inter', sans-serif !important;
	font-size: 0.85rem !important;
	color: var(--text-light) !important;
	font-style: normal !important;
	font-weight: 600;
	letter-spacing: 0.04em;
	margin-top: 1rem;
	display: block;
}

/* --- Blockquotes (Stories page) --- */
.wp-block-quote {
	border-left: 4px solid var(--green) !important;
	padding: 1.5rem 2rem !important;
	margin: 2rem auto !important;
	max-width: 720px;
	background: var(--mint);
	border-radius: 0 var(--radius) var(--radius) 0;
}

.wp-block-quote p {
	font-family: 'DM Sans', sans-serif !important;
	font-size: 1.1rem !important;
	color: var(--navy) !important;
	font-style: italic;
	line-height: 1.7 !important;
}

.wp-block-quote cite {
	font-family: 'Inter', sans-serif !important;
	font-size: 0.85rem !important;
	color: var(--text-light) !important;
	font-style: normal !important;
	font-weight: 600;
}

/* --- Separators --- */
.wp-block-separator {
	border: none !important;
	height: 3px !important;
	background: var(--flag-stripe) !important;
	width: 80px !important;
	margin: 2.5rem auto !important;
	border-radius: 2px;
	opacity: 1 !important;
}

/* --- Inner page headings --- */
.page:not(.home) .entry-content h2 {
	font-size: 2.2rem;
	text-align: center;
	margin-top: 2rem;
	margin-bottom: 1rem;
}

.page:not(.home) .entry-content h3 {
	font-size: 1.5rem;
	text-align: center;
	margin-top: 2rem;
	margin-bottom: 1rem;
	color: var(--navy);
}

/* Remove italic from inner page h3 (many have <em> wrapping) */
.page:not(.home) .entry-content h3 em {
	font-style: normal;
}

/* --- Media & text blocks --- */
.wp-block-media-text {
	gap: 2rem;
	margin: 2rem 0;
}

.wp-block-media-text__media img {
	border-radius: var(--radius-lg) !important;
}

/* --- Lists --- */
.page:not(.home) .entry-content ul,
.page:not(.home) .entry-content ol {
	max-width: 720px;
	margin: 1.5rem auto;
	padding-left: 1.5rem;
}

.page:not(.home) .entry-content li {
	color: var(--text-mid);
	line-height: 1.85;
	margin-bottom: 0.5rem;
}

/* ==========================================================================
   TEAM PAGE — card grid
   ========================================================================== */

/* Team grid background */
.page-template-default .wp-block-group.alignfull[style*="#f2f0e9"],
.wp-block-group.alignfull[style*="background-color:#f2f0e9"] {
	background: var(--cream) !important;
	padding: 3rem 2rem !important;
}

/* Team columns — CSS grid for better control */
.page:not(.home) .wp-block-columns {
	max-width: 1200px;
	margin: 0 auto !important;
	gap: 1.5rem !important;
}

/* Team member images as cards */
.page:not(.home) .wp-block-column .wp-block-image {
	background: #fff;
	border-radius: var(--radius-lg);
	overflow: hidden;
	box-shadow: var(--shadow-sm);
	transition: all 0.3s ease;
	margin-bottom: 1.5rem !important;
}

.page:not(.home) .wp-block-column .wp-block-image:hover {
	box-shadow: var(--shadow-md);
	transform: translateY(-4px);
}

.page:not(.home) .wp-block-column .wp-block-image img {
	border-radius: 0 !important;
	box-shadow: none !important;
	aspect-ratio: 1;
	object-fit: cover;
	width: 100%;
}

.page:not(.home) .wp-block-column .wp-block-image figcaption {
	padding: 1rem 1rem 1.2rem !important;
	font-size: 0.82rem !important;
	line-height: 1.5;
	color: var(--text-mid);
	text-align: center;
	background: #fff;
}

.page:not(.home) .wp-block-column .wp-block-image figcaption strong {
	display: block;
	font-family: 'DM Sans', sans-serif;
	font-size: 0.9rem;
	font-weight: 700;
	color: var(--navy);
	margin-bottom: 0.2rem;
}

/* LinkedIn icon in team cards */
.team-linkedin {
	display: inline-block;
	color: #0A66C2 !important;
	opacity: 0.7;
	transition: opacity 0.2s;
	vertical-align: middle;
	margin-left: 4px;
}

.team-linkedin:hover {
	opacity: 1;
	color: #0A66C2 !important;
}

/* ==========================================================================
   STORIES PAGE — card-style story entries
   ========================================================================== */

/* Story title links */
.page:not(.home) .entry-content p.has-medium-font-size a {
	color: var(--navy) !important;
	font-family: 'DM Sans', sans-serif;
	font-weight: 700;
	font-size: 1.3rem !important;
	transition: color 0.2s;
}

.page:not(.home) .entry-content p.has-medium-font-size a:hover {
	color: var(--green) !important;
}

/* Story excerpt text */
.page:not(.home) .entry-content p.has-x-small-font-size {
	font-size: 0.95rem !important;
	line-height: 1.8;
	color: var(--text-mid);
	max-width: 620px;
	margin-left: auto !important;
	margin-right: auto !important;
}

/* Story images — circular portraits */
.page:not(.home) .entry-content .wp-block-image.aligncenter img {
	border-radius: 50% !important;
	box-shadow: var(--shadow-md) !important;
	max-width: 220px;
	aspect-ratio: 1;
	object-fit: cover;
}

/* ==========================================================================
   CONTACT / JOIN PAGE
   ========================================================================== */

/* Form inputs */
.page:not(.home) input[type="text"],
.page:not(.home) input[type="email"],
.page:not(.home) input[type="tel"],
.page:not(.home) input[type="url"],
.page:not(.home) textarea,
.page:not(.home) select {
	border: 1.5px solid #D1D5DB !important;
	border-radius: var(--radius) !important;
	padding: 0.75rem 1rem !important;
	font-family: 'Inter', sans-serif;
	font-size: 0.95rem;
	color: var(--text);
	background: #fff;
	transition: border-color 0.2s, box-shadow 0.2s;
}

.page:not(.home) input:focus,
.page:not(.home) textarea:focus,
.page:not(.home) select:focus {
	border-color: var(--green) !important;
	box-shadow: 0 0 0 3px rgba(30, 122, 62, 0.1) !important;
	outline: none !important;
}

/* ==========================================================================
   COMMUNITY HEALTH PLAN — dark section overrides
   ========================================================================== */

/* Dark background sections on inner pages */
.page:not(.home) .wp-block-group.has-background[style*="background-color"] {
	border-radius: var(--radius-lg);
	padding: 3rem 2.5rem !important;
	margin: 2rem 0 !important;
}

/* Dark background text */
.wp-block-cover__inner-container h2,
.wp-block-cover__inner-container h3 {
	color: #fff !important;
}

.wp-block-cover__inner-container p {
	color: rgba(255, 255, 255, 0.85) !important;
}

/* ==========================================================================
   INNER PAGE ANIMATIONS
   ========================================================================== */

/* Subtle fade-in for inner page content blocks */
.page:not(.home) .entry-content > .wp-block-group,
.page:not(.home) .entry-content > .wp-block-columns,
.page:not(.home) .entry-content > p,
.page:not(.home) .entry-content > .wp-block-image,
.page:not(.home) .entry-content > .wp-block-pullquote,
.page:not(.home) .entry-content > .wp-block-quote {
	animation: inner-fade-in 0.5s ease-out both;
}

@keyframes inner-fade-in {
	0%   { opacity: 0; transform: translateY(8px); }
	100% { opacity: 1; transform: translateY(0); }
}

@media (max-width: 480px) {
	.wp-block-cover .wp-block-cover__inner-container > p:first-child,
	.wp-block-cover .wp-block-cover__inner-container > p:first-child strong {
		font-size: 1.65rem !important;
	}

	.entry-content > .wp-block-group:not(.alignfull) h2 {
		font-size: 1.6rem;
	}
}
