/* Eric Wisniewski Racing — theme styles */

:root {
	--ew-orange: #FF4000;
	--ew-blue: #002181;
	--ew-black: #000000;
	--ew-carbon: #0E0E0E;
	--ew-line: #2A2A2A;
	--ew-muted: #C4C8D2;
	--ew-dim: #A3A8B8;
	--ew-gutter: clamp(16px, 4vw, 56px);
	--ew-display: 'Barlow Condensed', 'Arial Narrow', sans-serif;
}

body { margin: 0; background: #000; }
.wp-site-blocks { padding: 0; }
.wp-site-blocks *, .wp-site-blocks *::before, .wp-site-blocks *::after { box-sizing: border-box; }
.wp-site-blocks figure.wp-block-image { margin: 0; }
.wp-site-blocks .wp-block-image img { display: block; }

/* ---------- Layout ---------- */
.ew-section { padding: clamp(72px, 9vw, 128px) var(--ew-gutter); }
.ew-section.ew-pt-0 { padding-top: 0; }
.ew-wrap { max-width: 1328px; width: 100%; margin-left: auto; margin-right: auto; }
.ew-stack { display: flex; flex-direction: column; gap: 22px; }
.ew-stack.ew-gap-sm { gap: 12px; }
.ew-stack.ew-gap-lg { gap: 56px; }
.ew-row { display: flex; flex-wrap: wrap; gap: 32px 64px; align-items: flex-end; }
.ew-row-between { display: flex; flex-wrap: wrap; gap: 16px; justify-content: space-between; align-items: flex-end; }
.ew-grow { flex: 999 1 520px; min-width: 0; }
.ew-side { flex: 1 1 340px; min-width: 0; }
.ew-split { display: flex; flex-wrap: wrap; gap: 48px 72px; align-items: center; }
.ew-split > * { flex: 1 1 400px; min-width: 0; }
.ew-split.ew-align-start { align-items: flex-start; }
.ew-grid-auto { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 28px 32px; }

/* ---------- Type ---------- */
.ew-eyebrow { margin: 0; font-size: 13px; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ew-orange); }
.ew-display, h1.ew-display, h2.ew-display, h3.ew-display {
	margin: 0;
	font-family: var(--ew-display);
	font-style: italic;
	font-weight: 800;
	text-transform: uppercase;
	line-height: 0.92;
	letter-spacing: -0.005em;
	font-size: clamp(44px, 6vw, 88px);
	color: #fff;
}
.ew-display.ew-xl { font-size: clamp(64px, 11vw, 180px); line-height: 0.84; }
.ew-display.ew-md { font-size: clamp(36px, 4.5vw, 64px); }
.ew-display.ew-sm { font-size: clamp(26px, 2.6vw, 34px); line-height: 1; }
.ew-lead { margin: 0; max-width: 580px; font-size: clamp(16px, 1.4vw, 19px); line-height: 1.55; color: #D6D9E0; }
.ew-body { margin: 0; font-size: 17px; line-height: 1.65; color: var(--ew-muted); max-width: 640px; }
.ew-small { margin: 0; font-size: 13px; color: var(--ew-dim); }
.ew-more { margin: 0; }
.ew-more a { display: inline-block; padding: 12px 0; font-size: 14px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; text-decoration: none; }
.ew-quote { margin: 0; font-family: var(--ew-display); font-style: italic; font-weight: 700; font-size: clamp(28px, 3vw, 40px); line-height: 1.1; color: #fff; }
.ew-email { margin: 0; }
.ew-email a { color: var(--ew-orange); font-size: clamp(20px, 3vw, 36px); font-weight: 600; text-decoration: none; overflow-wrap: anywhere; }
.ew-email a:hover { color: #fff; }

/* ---------- Buttons ---------- */
.wp-block-buttons { gap: 12px; }
.ew-btn-small .wp-block-button__link { padding: 13px 20px; font-size: 13px; }
.ew-btn-ghost .wp-block-button__link { background: transparent; color: #fff; border: 1px solid rgba(255, 255, 255, 0.6); }
.ew-btn-ghost .wp-block-button__link:hover { background: transparent; color: var(--ew-orange); border-color: var(--ew-orange); }
.ew-btn-white .wp-block-button__link { background: #fff; color: #000; }
.ew-btn-white .wp-block-button__link:hover { background: var(--ew-orange); color: #000; }

/* ---------- Header ---------- */
.ew-header {
	display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
	gap: 16px 32px; padding: 18px var(--ew-gutter);
	background: #000; border-bottom: 1px solid #1C1C1C;
}
.ew-brand { margin: 0; }
.ew-brand a { display: flex; align-items: center; gap: 14px; text-decoration: none; color: #fff; }
.ew-brand img { width: 68px; height: auto; display: block; }
.ew-brand span { font-family: var(--ew-display); font-style: italic; font-weight: 800; font-size: 22px; letter-spacing: 0.02em; }
.ew-header-right { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 28px; }
.ew-nav .wp-block-navigation__container { gap: 8px 28px; }
.ew-nav .wp-block-navigation-item__content { padding: 12px 0; font-size: 13px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; text-decoration: none; color: #fff; }
.ew-nav .wp-block-navigation-item__content:hover { color: var(--ew-orange); }
.ew-nav .wp-block-navigation__responsive-container-open,
.ew-nav .wp-block-navigation__responsive-container-close { color: #fff; }
.ew-nav .wp-block-navigation__responsive-container.is-menu-open { background: #000 !important; color: #fff !important; padding: 24px var(--ew-gutter); }
.ew-nav .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation-item__content { font-size: 24px; padding: 10px 0; }

/* ---------- Heroes ---------- */
.ew-hero { position: relative; display: flex; align-items: flex-end; min-height: clamp(560px, 62vw, 860px); overflow: hidden; background: #000; }
.ew-hero.ew-page-hero { min-height: clamp(380px, 40vw, 560px); }
.ew-hero > .ew-hero-img { position: absolute; inset: 0; margin: 0; }
.ew-hero > .ew-hero-img img { width: 100%; height: 100%; object-fit: cover; object-position: center 45%; }
.ew-hero::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(to top, rgba(0,0,0,0.92) 0%, rgba(0,0,0,0.55) 32%, rgba(0,0,0,0) 62%); }
.ew-hero-content { position: relative; z-index: 2; width: 100%; display: flex; flex-direction: column; gap: 18px; padding: 0 var(--ew-gutter) clamp(32px, 5vw, 64px); }
.ew-hero-content .wp-block-buttons { margin-top: 6px; }

/* ---------- Orange band ---------- */
.ew-band-orange { background: var(--ew-orange); color: #000; padding: 36px var(--ew-gutter); }
.ew-stat { display: flex; flex-direction: column; gap: 6px; }
.ew-stat-big { margin: 0; font-family: var(--ew-display); font-style: italic; font-weight: 800; font-size: 44px; line-height: 1; color: #000; }
.ew-stat-label { margin: 0; font-size: 15px; font-weight: 600; line-height: 1.4; color: #000; }

/* ---------- Key/value rows ---------- */
.ew-meta { display: flex; flex-direction: column; }
.ew-meta-row { display: flex; justify-content: space-between; gap: 16px; padding: 16px 0; border-top: 1px solid var(--ew-line); }
.ew-meta-row:last-child { border-bottom: 1px solid var(--ew-line); }
.ew-meta-row p { margin: 0; font-size: 15px; }
.ew-meta-row p:first-child { color: var(--ew-dim); }
.ew-meta-row p:last-child { font-weight: 600; text-align: right; }
.ew-accent { color: var(--ew-orange); }

/* ---------- Timeline (home) ---------- */
.ew-timeline { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 32px 24px; }
.ew-tl { display: flex; flex-direction: column; gap: 10px; padding-top: 18px; border-top: 2px solid var(--ew-line); }
.ew-tl.is-champ { border-top-color: var(--ew-orange); }
.ew-tl-year { margin: 0; font-family: var(--ew-display); font-style: italic; font-weight: 800; font-size: 34px; line-height: 1; color: #fff; }
.ew-tl.is-champ .ew-tl-year { color: var(--ew-orange); }
.ew-tl-text { margin: 0; font-size: 14px; line-height: 1.5; color: var(--ew-muted); }

/* ---------- Seasons (racing page) ---------- */
.ew-seasons { display: flex; flex-direction: column; }
.ew-season { display: grid; grid-template-columns: minmax(120px, 240px) minmax(0, 1fr); gap: 10px 48px; padding: 32px 0; border-top: 1px solid var(--ew-line); }
.ew-season:last-child { border-bottom: 1px solid var(--ew-line); }
.ew-season-year { margin: 0; font-family: var(--ew-display); font-style: italic; font-weight: 800; font-size: clamp(40px, 5vw, 64px); line-height: 0.9; color: #fff; }
.ew-season.is-champ .ew-season-year { color: var(--ew-orange); }
.ew-season-body { display: flex; flex-direction: column; gap: 8px; }
.ew-badge { margin: 0; align-self: flex-start; background: var(--ew-orange); color: #000; font-size: 12px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; padding: 5px 10px; border-radius: 2px; }
@media (max-width: 640px) { .ew-season { grid-template-columns: 1fr; } }

/* ---------- Photos ---------- */
.ew-photo img { width: 100%; object-fit: cover; border-radius: 2px; }
.ew-photo-wide img { height: clamp(280px, 40vw, 600px); object-position: center 60%; }
.ew-photo-tall img { height: clamp(440px, 48vw, 680px); object-position: center 30%; }
.ew-photo-natural img { height: auto; }
.ew-photo-band img { height: clamp(300px, 38vw, 560px); border-radius: 0; object-position: center 50%; }
.ew-photo figcaption, .ew-photo .wp-element-caption { margin: 10px 0 0; font-size: 13px; color: var(--ew-dim); text-align: left; }
.ew-gallery { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 12px; }
.ew-gallery .wp-block-image img { width: 100%; height: 360px; object-fit: cover; border-radius: 2px; }

/* ---------- Cards ---------- */
.ew-card { display: flex; align-items: center; gap: 18px; padding: 18px; background: var(--ew-carbon); border: 1px solid #1F1F1F; border-radius: 2px; }
.ew-card > .wp-block-image { flex: 0 0 84px; }
.ew-card > .wp-block-image img { width: 84px; height: 84px; object-fit: cover; object-position: center 62%; border-radius: 2px; }
.ew-card > p { margin: 0; font-size: 15px; line-height: 1.5; color: #E2E5EB; }
.ew-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; }
.ew-offer { display: flex; flex-direction: column; gap: 12px; padding: 28px; background: var(--ew-carbon); border: 1px solid #1F1F1F; border-radius: 2px; }
.ew-offer-num { margin: 0; font-family: var(--ew-display); font-style: italic; font-weight: 800; font-size: 22px; color: var(--ew-orange); }
.ew-offer p:not(.ew-offer-num) { margin: 0; font-size: 15px; line-height: 1.6; color: var(--ew-muted); }
.ew-offer a { color: var(--ew-orange); font-weight: 600; text-decoration: none; }

/* ---------- Blue section + logos ---------- */
.ew-blue { background: var(--ew-blue); }
.ew-blue .ew-eyebrow { color: #fff; }
.ew-blue .ew-body { color: #E2E7F5; }
.ew-logos { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
.ew-logos figure.ew-logo-tile { display: flex; align-items: center; justify-content: center; height: 120px; padding: 20px 24px; background: #fff; border-radius: 2px; }
.ew-logo-tile img { max-width: 100%; max-height: 64px; width: auto; height: auto; object-fit: contain; }
.ew-logo-tile.ew-logo-short img { max-height: 44px; }
.ew-logo-tile.ew-logo-tall img { max-height: 76px; }
.ew-photo-narrow { max-width: 440px; }

/* ---------- Page content (generic pages and posts) ---------- */
.ew-content { max-width: 760px; }
.ew-content p, .ew-content li { color: var(--ew-muted); }
.ew-content a { color: var(--ew-orange); }
.ew-content > * + * { margin-top: 1.2em; }
.ew-post-list .wp-block-post { padding: 28px 0; border-top: 1px solid var(--ew-line); }
.ew-post-list .wp-block-post-title { margin: 0 0 8px; font-size: clamp(28px, 3vw, 40px); }
.ew-post-list .wp-block-post-title a { text-decoration: none; }

/* ---------- Footer ---------- */
.ew-footer { padding: 36px var(--ew-gutter); border-top: 1px solid #1C1C1C; }
.ew-footer-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px; }
.ew-footer-logo { margin: 0; }
.ew-footer-logo img { width: 56px; height: auto; display: block; }
.ew-footer-links { margin: 0; display: flex; flex-wrap: wrap; gap: 4px 24px; font-size: 13px; }
.ew-footer-links a { display: inline-block; padding: 10px 0; text-decoration: none; color: var(--ew-dim); }
.ew-footer-links a:hover { color: var(--ew-orange); }
.ew-copy { margin: 0; font-size: 13px; color: #8A90A0; }
