/*
Theme Name: 3.14ONEER
Theme URI: https://314oneer.ch
Author: 3.14ONEER
Description: Custom theme for 3.14ONEER: custom high-end bikes, professional assembly and expert consultation. Quote-led custom builds, responsive layout, no third-party requests.
Version: 0.1.0
Requires at least: 6.4
Tested up to: 7.1
Requires PHP: 7.4
License: Proprietary
Text Domain: 314oneer
*/

/* ---------- Tokens ---------- */
:root {
	--carbon: #2d2d2a;
	--carbon-2: #3a3a36;
	--yellow: #fbdb6b;
	--yellow-dark: #e9c545;
	--grey: #e3e2db;
	--grey-2: #f3f2ee;
	--blue: #6bbcfb;
	--ink: #2d2d2a;
	--muted: #5f5f58;
	--white: #fff;
	--radius: 12px;
	--gutter: clamp(16px, 4vw, 32px);
	--max: 1180px;
	--font-head: "Montserrat", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
	--font-body: Georgia, "Iowan Old Style", "Palatino Linotype", Palatino, serif;
	--header-h: 68px;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
	margin: 0;
	background: var(--white);
	color: var(--ink);
	font-family: var(--font-body);
	font-size: 1.0625rem;
	line-height: 1.7;
	overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2, h3, h4 {
	font-family: var(--font-head);
	line-height: 1.15;
	letter-spacing: -0.02em;
	margin: 0 0 .6em;
	font-weight: 600;
	text-wrap: balance;
}
h1 { font-size: clamp(2rem, 5.5vw, 3.25rem); }
h2 { font-size: clamp(1.5rem, 3.6vw, 2.25rem); }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1.1em; }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; border-radius: 4px; }
.screen-reader-text {
	position: absolute !important; width: 1px; height: 1px; overflow: hidden;
	clip-path: inset(50%); white-space: nowrap;
}
.skip-link {
	position: absolute; left: 8px; top: -60px; z-index: 100;
	background: var(--yellow); color: var(--carbon); padding: .6em 1em; font-family: var(--font-head); font-weight: 600;
}
.skip-link:focus { top: 8px; }

.wrap { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: var(--gutter); }
.narrow { max-width: 780px; }
.center { text-align: center; }
.muted { color: var(--muted); }

/* ---------- Buttons ---------- */
.btn {
	display: inline-block; font-family: var(--font-head); font-weight: 600; font-size: 1rem;
	text-decoration: none; text-align: center; cursor: pointer;
	background: var(--yellow); color: var(--carbon); border: 2px solid var(--yellow);
	padding: .8em 1.5em; border-radius: 999px; line-height: 1.2;
	transition: background .15s, transform .15s;
}
.btn:hover { background: var(--yellow-dark); border-color: var(--yellow-dark); }
.btn-small { padding: .55em 1.1em; font-size: .9rem; }
.btn-ghost { background: transparent; color: var(--white); border-color: rgba(255,255,255,.55); }
.btn-ghost:hover { background: rgba(255,255,255,.1); border-color: var(--white); }
.btn-ghost-dark { background: transparent; color: var(--carbon); border-color: var(--carbon); }
.btn-ghost-dark:hover { background: var(--grey); border-color: var(--carbon); }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }
.center-row { justify-content: center; }
.text-link { font-family: var(--font-head); font-weight: 600; text-decoration: none; border-bottom: 2px solid var(--yellow); }
.text-link:hover { background: var(--yellow); }

/* ---------- Header ---------- */
.site-header { background: var(--carbon); color: var(--grey); position: sticky; top: 0; z-index: 50; box-shadow: 0 1px 0 rgba(251,219,107,.18); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: var(--header-h); }
.brand img { height: 30px; width: auto; }
.nav-toggle {
	display: none; background: none; border: 0; color: var(--grey); width: 44px; height: 44px; padding: 0; cursor: pointer; border-radius: 8px;
}
.nav-toggle-bars, .nav-toggle-bars::before, .nav-toggle-bars::after {
	display: block; width: 24px; height: 2px; background: currentColor; margin: auto; position: relative; transition: transform .2s, opacity .2s;
}
.nav-toggle-bars::before, .nav-toggle-bars::after { content: ""; position: absolute; left: 0; }
.nav-toggle-bars::before { top: -7px; }
.nav-toggle-bars::after { top: 7px; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars { background: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars::before { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars::after { transform: translateY(-7px) rotate(-45deg); }

.primary-nav { display: flex; align-items: center; gap: 8px; }
.primary-nav ul { list-style: none; margin: 0; padding: 0; display: flex; align-items: center; gap: 4px; }
.primary-nav li a {
	display: block; padding: .6em .9em; text-decoration: none; font-family: var(--font-head); font-size: .95rem; border-radius: 8px; color: var(--grey);
}
.primary-nav li a:hover, .primary-nav li a[aria-current="page"], .primary-nav li.current-menu-item a { color: var(--yellow); background: rgba(251,219,107,.1); }
.nav-cta { margin-left: 8px; }

@media (max-width: 899px) {
	.nav-toggle { display: inline-flex; align-items: center; }
	.nav-ready .primary-nav {
		display: none; position: absolute; left: 0; right: 0; top: var(--header-h);
		background: var(--carbon); flex-direction: column; align-items: stretch; padding: 8px var(--gutter) 24px;
		border-top: 1px solid rgba(255,255,255,.1); box-shadow: 0 12px 24px rgba(0,0,0,.25);
	}
	.nav-ready .primary-nav.is-open { display: flex; }
	.nav-ready .primary-nav ul { flex-direction: column; align-items: stretch; }
	.nav-ready .primary-nav li a { padding: .9em .6em; }
	.nav-ready .nav-cta { margin: 12px 0 0; }
	/* No JS: the menu simply wraps below the logo. */
	body:not(.nav-ready) .header-inner { flex-wrap: wrap; padding-block: 10px; }
	body:not(.nav-ready) .primary-nav { flex-wrap: wrap; }
	body:not(.nav-ready) .primary-nav ul { flex-wrap: wrap; }
}

/* ---------- Hero ---------- */
.hero { background: var(--carbon); color: var(--grey); padding-block: clamp(32px, 7vw, 80px); }
.hero-grid { display: grid; gap: clamp(24px, 5vw, 56px); align-items: center; }
.hero h1 { color: var(--white); }
.eyebrow {
	font-family: var(--font-head); text-transform: uppercase; letter-spacing: .2em; font-size: .78rem; font-weight: 600; color: var(--yellow); margin-bottom: 1rem;
}
.lead { font-size: 1.2rem; line-height: 1.6; }
.hero .lead { color: var(--grey); max-width: 34em; margin-bottom: 1.6rem; }
.hero-media { background: var(--grey); border-radius: var(--radius); overflow: hidden; }
.hero-media img { width: 100%; }
@media (min-width: 900px) {
	.hero-grid { grid-template-columns: 1.05fr 1fr; }
}

.page-hero { background: var(--carbon); color: var(--grey); padding-block: clamp(32px, 6vw, 64px); }
.page-hero h1 { color: var(--white); margin-bottom: .4em; }
.page-hero .lead { margin: 0; }

/* ---------- Sections ---------- */
.section { padding-block: clamp(40px, 7vw, 88px); }
.section-alt { background: var(--grey-2); }
.section-title { margin-bottom: 1.2em; }
.section-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px 24px; }
.split { display: grid; gap: clamp(24px, 5vw, 56px); align-items: center; }
@media (min-width: 900px) {
	.split { grid-template-columns: 4fr 5fr; }
	.split-build { grid-template-columns: 5fr 4fr; }
}
.rounded { border-radius: var(--radius); width: 100%; }
.story p { font-size: 1.125rem; }
.pull-quote {
	margin: 1.4em 0; padding-left: 1em; border-left: 4px solid var(--yellow);
	font-family: var(--font-head); font-weight: 500; font-size: 1.35rem; line-height: 1.35; letter-spacing: -0.02em;
}

/* ---------- Cards ---------- */
.card-grid { display: grid; gap: 20px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 600px) {
	.card-grid-2, .card-grid-3, .card-grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 900px) {
	.card-grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
	.card-grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
.card { background: var(--white); border: 1px solid var(--grey); border-radius: var(--radius); overflow: hidden; }
.section-alt .card { border-color: transparent; }
.service-card { padding: 28px; }
.card-num { font-family: var(--font-head); font-weight: 700; color: var(--yellow-dark); font-size: 1.1rem; display: block; margin-bottom: .5em; }
.build-media { display: block; background: var(--grey); }
.build-media img, .build-img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.build-body { padding: 18px 20px 22px; }
.build-body h3, .card-title { margin-bottom: .3em; font-size: 1.15rem; }
.build-body h3 a, .card-title a { text-decoration: none; }
.build-body h3 a:hover, .card-title a:hover { text-decoration: underline; text-decoration-color: var(--yellow-dark); text-underline-offset: 4px; text-decoration-thickness: 3px; }
.build-body p { margin: 0; color: var(--muted); font-size: .98rem; }
.build-hero-media { background: var(--grey); border-radius: var(--radius); overflow: hidden; }
.build-hero-media img { width: 100%; }
.meta { font-family: var(--font-head); font-size: .8rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); margin-bottom: .4em; }
.note { margin-top: 2rem; color: var(--muted); text-align: center; }
.narrow-block { max-width: 780px; margin: 2rem auto 0; }

/* ---------- Steps ---------- */
.steps { list-style: none; counter-reset: step; margin: 0; padding: 0; display: grid; gap: 20px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 600px) { .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 900px) { .steps { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.contact-aside .steps { grid-template-columns: minmax(0, 1fr); }
.steps li { counter-increment: step; position: relative; padding-top: 52px; }
.steps li::before {
	content: counter(step); position: absolute; top: 0; left: 0; width: 38px; height: 38px; border-radius: 50%;
	background: var(--yellow); color: var(--carbon); font-family: var(--font-head); font-weight: 700; display: grid; place-items: center;
}
.steps h3 { margin-bottom: .3em; }
.steps p { margin: 0; color: var(--muted); font-size: .98rem; }
.contact-aside .steps li { padding-top: 0; padding-left: 52px; min-height: 38px; }

/* ---------- CTA band ---------- */
.cta-band { background: var(--carbon); color: var(--grey); }
.cta-band h2 { color: var(--white); }

/* ---------- Quote form ---------- */
.contact-grid { display: grid; gap: clamp(28px, 5vw, 56px); }
@media (min-width: 900px) { .contact-grid { grid-template-columns: 3fr 2fr; align-items: start; } }
.quote-box { background: var(--grey-2); border-radius: var(--radius); padding: clamp(20px, 4vw, 40px); }
.field { margin: 0 0 18px; }
.field label { display: block; font-family: var(--font-head); font-weight: 600; font-size: .9rem; margin-bottom: 6px; }
.field input[type="text"], .field input[type="email"], .field input[type="tel"], .field select, .field textarea {
	width: 100%; font: inherit; font-size: 1rem; padding: .75em .9em; border: 2px solid #c9c8c0; border-radius: 8px; background: var(--white); color: var(--ink);
}
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--carbon); outline: 3px solid var(--blue); outline-offset: 1px; }
.field-row { display: grid; gap: 0 18px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 600px) { .field-row { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.field.check { display: flex; gap: 10px; align-items: flex-start; }
.field.check input { margin-top: .4em; width: 20px; height: 20px; flex: none; accent-color: var(--carbon); }
.field.check label { font-family: var(--font-body); font-weight: 400; font-size: .95rem; margin: 0; }
.hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.notice { padding: 14px 18px; border-radius: 8px; margin-bottom: 20px; font-family: var(--font-head); font-size: .95rem; }
.notice-success { background: #e7f6dc; border: 2px solid #5da03a; }
.notice-error { background: #fde8e8; border: 2px solid #c0392b; }
.contact-aside h2 { font-size: 1.3rem; }
.contact-aside .steps { margin-bottom: 1rem; }
.footer-list { list-style: none; margin: 0; padding: 0; }
.footer-list li { margin-bottom: .7em; }
.contact-list a { text-decoration-color: var(--yellow-dark); text-underline-offset: 3px; }

/* ---------- Entry (editor content) ---------- */
.entry > * + * { margin-top: 1.1em; }
.entry img { border-radius: 8px; }
.entry a { text-decoration-color: var(--yellow-dark); text-underline-offset: 3px; text-decoration-thickness: 2px; }
.post-thumb { margin-block: 1rem 2rem; border-radius: var(--radius); overflow: hidden; }
.navigation.pagination { margin-top: 2rem; font-family: var(--font-head); }
.navigation .nav-links { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.navigation .page-numbers { padding: .5em .9em; border-radius: 8px; text-decoration: none; border: 1px solid var(--grey); }
.navigation .page-numbers.current { background: var(--yellow); border-color: var(--yellow); }

/* ---------- Footer ---------- */
.site-footer { background: var(--carbon); color: var(--grey); padding-top: clamp(36px, 6vw, 64px); font-size: .98rem; border-top: 1px solid rgba(251,219,107,.18); }
.footer-grid { display: grid; gap: 28px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 700px) { .footer-grid { grid-template-columns: 2fr 1.2fr 1fr; } }
.footer-logo { width: min(320px, 100%); height: auto; margin-bottom: 16px; }
.footer-services { color: #b9b8b0; font-size: .9rem; }
.footer-heading { font-size: .8rem; text-transform: uppercase; letter-spacing: .15em; color: var(--yellow); margin-bottom: 1em; }
.site-footer a { text-decoration: none; }
.site-footer a:hover { color: var(--yellow); }
.footer-bottom {
	display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; margin-top: 36px; padding-block: 20px;
	border-top: 1px solid rgba(255,255,255,.12); font-size: .85rem; color: #b9b8b0;
}
.footer-bottom p { margin: 0; }
.footer-legal { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 20px; }

@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	*, *::before, *::after { transition: none !important; }
}

/* WordPress core alignment helpers */
.alignleft { float: left; margin: 0 1.2em 1em 0; }
.alignright { float: right; margin: 0 0 1em 1.2em; }
.aligncenter { margin-inline: auto; }
.wp-caption-text, figcaption { font-size: .85rem; color: var(--muted); }
