/*
Theme Name: Church & Dwight Innovation
Theme URI: https://churchdwightinnovation.com/
Description: Child theme of Twenty Twenty-Five for the Church & Dwight Innovation portal. Rebuilt from the original Interico/SiteOrigin site.
Author: Ezassi
Template: twentytwentyfive
Version: 1.0.4
Requires at least: 6.7
Tested up to: 7.1
Requires PHP: 8.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: cd-innovation
*/

/* ------------------------------------------------------------------
   Design tokens are defined in theme.json. This file holds component
   styling for the custom classes used in page content (cdi-*), the
   header and the footer.
   ------------------------------------------------------------------ */

:root {
	--cdi-navy: #1e2d40;
	--cdi-red: #be0f2e;
	--cdi-grey-bg: #f6f6f6;
	--cdi-text: #333333;
	--cdi-muted: #9a9a9a;
}

body {
	color: var(--cdi-text);
}

/* ---------- Header ---------- */
.cdi-header {
	background: var(--cdi-navy);
	position: sticky;
	top: 0;
	z-index: 100;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
}
.admin-bar .cdi-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .cdi-header { top: 46px; } }

.cdi-header .cdi-logo img {
	width: 72px;
	height: auto;
	display: block;
}

.cdi-header .wp-block-navigation {
	font-size: 0.9rem;
	font-weight: 500;
	letter-spacing: 0.02em;
	text-transform: uppercase;
}
.cdi-header .wp-block-navigation a,
.cdi-header .wp-block-navigation a:where(:not(.wp-element-button)),
.cdi-header .wp-block-navigation .wp-block-navigation-item__content,
.cdi-header .wp-block-navigation .wp-block-navigation-item__content:hover,
.cdi-header .cdi-logo a {
	color: #fff !important;
	text-decoration: none;
	padding: 0.25rem 0;
	border-bottom: 2px solid transparent;
	transition: border-color 0.15s;
}
.cdi-header .wp-block-navigation a:hover,
.cdi-header .wp-block-navigation .current-menu-item > a {
	border-bottom-color: #fff;
}
.cdi-header .wp-block-navigation__responsive-container-open,
.cdi-header .wp-block-navigation__responsive-container-close {
	color: #fff;
}
.cdi-header .wp-block-navigation__responsive-container.is-menu-open {
	background: var(--cdi-navy);
	color: #fff;
}

/* ---------- Footer ---------- */
.cdi-footer {
	background: var(--cdi-navy);
	color: #fff;
	font-size: 0.85rem;
	font-weight: 500;
}
.cdi-footer a {
	color: #fff;
	text-decoration: none;
}
.cdi-footer a:hover { text-decoration: underline; }
.cdi-footer .cdi-footer-links .wp-block-column {
	text-align: center;
}
.cdi-footer .cdi-copyright {
	border-top: 1px solid rgba(255, 255, 255, 0.12);
	font-weight: 400;
	font-size: 0.8rem;
}
.cdi-footer .cdi-copyright p::before {
	content: "";
	display: inline-block;
	width: 44px;
	height: 1px;
	background: rgba(255, 255, 255, 0.4);
	vertical-align: middle;
	margin-right: 1.5rem;
}

/* ---------- Generic helpers ---------- */
.cdi-eyebrow {
	font-size: 0.75rem;
	font-weight: 500;
	letter-spacing: 0.18em;
	text-transform: uppercase;
	color: var(--cdi-text);
	margin-bottom: 0.5rem;
}
.cdi-eyebrow-light { color: rgba(255, 255, 255, 0.85); }

.cdi-red { color: var(--cdi-red); }

.cdi-section-title {
	font-weight: 700;
	font-size: clamp(1.8rem, 3.2vw, 2.4rem);
	margin-top: 0;
}

.wp-block-separator.cdi-rule {
	width: 44px;
	margin: 1rem auto 2.5rem;
	border: 0;
	border-top: 1px solid rgba(0, 0, 0, 0.18);
	opacity: 1;
}
.wp-block-separator.cdi-rule-light { border-top-color: rgba(255, 255, 255, 0.45); }

/* ---------- Hero (Cover) ---------- */
.wp-block-cover.cdi-hero .wp-block-cover__inner-container,
.wp-block-cover.cdi-hero.has-custom-content-position .wp-block-cover__inner-container {
	width: 100% !important;
	max-width: 1050px !important;
	margin: 0 auto !important;
}
.cdi-hero h1 {
	font-weight: 700;
	font-size: clamp(2.2rem, 4.5vw, 3.4rem);
	line-height: 1.1;
	text-shadow: 0 1px 6px rgba(0, 0, 0, 0.15);
}
.cdi-hero .cdi-hero-text p { font-weight: 500; text-shadow: 0 1px 6px rgba(0, 0, 0, 0.15); }
.cdi-hero-center p { text-shadow: 0 1px 8px rgba(0, 0, 0, 0.35); }

.cdi-btn-light .wp-block-button__link {
	background: #fff;
	color: var(--cdi-navy);
	border-radius: 2px;
	font-size: 0.8rem;
	font-weight: 500;
	letter-spacing: 0.05em;
	text-transform: uppercase;
	padding: 1rem 1.5rem;
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.12);
}
.cdi-btn-light .wp-block-button__link:hover { background: var(--cdi-red); color: #fff; }

/* ---------- Home: process cards ---------- */
.cdi-process {
	background-color: var(--cdi-grey-bg);
	background-image: radial-gradient(rgba(0, 0, 0, 0.08) 1px, transparent 1px);
	background-size: 22px 22px;
}
.cdi-cards { margin-top: 2.5rem; align-items: flex-start; }
.cdi-card {
	position: relative;
	background: #fff;
	padding: 3.5rem 1.5rem 2rem;
	margin-top: 2rem;
	box-shadow: 0 2px 12px rgba(0, 0, 0, 0.05);
}
.cdi-num {
	position: absolute;
	top: -2.2rem;
	left: 1.5rem;
	margin: 0;
	width: 5rem;
	height: 5rem;
	line-height: 5rem;
	text-align: center;
	background: #d8d8d8;
	color: #fff;
	font-size: 2.6rem;
	font-weight: 500;
}
.cdi-card-title {
	font-size: 1.15rem;
	font-weight: 400;
	color: var(--cdi-muted);
	margin: 0 0 0.75rem;
}
.cdi-card p:not(.cdi-num) { font-size: 0.9rem; line-height: 1.7; }

.cdi-logos .wp-block-image { margin-bottom: 1.5rem; }

/* ---------- Red title band + breadcrumb ---------- */
.cdi-title-band { background: var(--cdi-red); }
.cdi-title-band h1 { font-weight: 700; font-size: clamp(2rem, 4vw, 2.8rem); margin: 0; }

.cdi-breadcrumb {
	border-bottom: 1px solid #eee;
	padding: 0.9rem 0;
}
.cdi-breadcrumb p { margin: 0; font-size: 0.8rem; }
.cdi-breadcrumb a { color: var(--cdi-muted); text-decoration: none; }
.cdi-breadcrumb .cdi-sep { margin: 0 0.5rem; color: var(--cdi-muted); }

/* ---------- Areas of Interest ---------- */
.cdi-aoi-row { margin-bottom: 2.5rem; }
.cdi-aoi-img img {
	border: 1px solid #5b8fd6;
	border-radius: 50%;
}
.cdi-aoi-title {
	font-weight: 400;
	font-size: clamp(1.4rem, 2.4vw, 2rem);
	margin: 0;
}
.cdi-aoi p { font-size: 0.9rem; line-height: 1.7; }
.cdi-aoi a { color: var(--cdi-muted); text-decoration: none; }
.cdi-aoi a:hover { color: var(--cdi-red); }

/* ---------- Innovation Challenges: category tiles ---------- */
.cdi-categories {
	background-color: var(--cdi-red);
	background-image: repeating-linear-gradient(90deg, rgba(0, 0, 0, 0.06) 0 1px, transparent 1px 20%);
}
.cdi-tile-grid { margin-top: 2rem; gap: 1.5rem; }
.cdi-tile {
	display: grid;
	grid-template-columns: 34px 1fr;
	grid-template-rows: auto auto;
	background: #fff;
}
.cdi-tile-label {
	grid-column: 1;
	grid-row: 1;
	margin: 0;
	background: var(--cdi-navy);
	color: #fff;
	writing-mode: vertical-rl;
	transform: rotate(180deg);
	text-align: left;
	line-height: 34px;
	padding: 0.75rem 0;
	font-size: 0.72rem;
	font-weight: 500;
	white-space: nowrap;
	overflow: hidden;
}
.cdi-tile-label::after { content: "\00a0\00a0—"; }
.cdi-tile-img {
	grid-column: 2;
	grid-row: 1;
	margin: 0;
}
.cdi-tile-img img {
	display: block;
	width: 100%;
	height: 100%;
	aspect-ratio: 1 / 1.25;
	object-fit: cover;
}
.cdi-tile-caption {
	grid-column: 1 / -1;
	grid-row: 2;
	margin: 0;
	padding: 1rem 0.5rem;
	font-size: 0.95rem;
	min-height: 4.5rem;
	display: flex;
	align-items: center;
	justify-content: center;
}
@media (max-width: 1024px) {
	.cdi-tile-grid { grid-template-columns: repeat(3, 1fr) !important; }
}
@media (max-width: 600px) {
	.cdi-tile-grid { grid-template-columns: repeat(2, 1fr) !important; }
}

/* ---------- Innovation Challenges: brand grids ---------- */
.cdi-brand-title {
	font-weight: 400;
	font-size: clamp(1.4rem, 2.4vw, 2rem);
	margin: 2.5rem 0 0.75rem;
}
.wp-block-separator.cdi-brand-rule {
	width: 70%;
	margin: 0 auto 1rem;
	border: 0;
	border-top: 1px solid #e5e5e5;
	opacity: 1;
}
.cdi-brand-grid { margin: 0 auto 1rem; max-width: 760px; }

/* ---------- FAQ ---------- */
.cdi-faq-q {
	font-weight: 400;
	font-size: clamp(1.3rem, 2.2vw, 1.9rem);
	margin: 2.25rem 0 0.75rem;
}
.cdi-faq p { font-size: 0.9rem; line-height: 1.7; }
.cdi-faq a { color: var(--cdi-muted); }
.cdi-faq a:hover { color: var(--cdi-red); }

/* ---------- Mobile ---------- */
@media (max-width: 781px) {
	.cdi-card { margin-top: 3rem; }
	.cdi-aoi-row .wp-block-column:first-child { text-align: center; }
	.cdi-aoi-img { margin: 0 auto; }
}
