/*
Theme Name: itintell
Theme URI: https://itintell.org
Author: IIC Innovative International Consulting GmbH & Co. KG
Description: Schlankes, plugin-freies Theme für itintell.org – mit nativem Hero-Slider, Projekte-Portfolio, Kontaktformular und Cookie-Hinweis.
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 7.4
License: GNU General Public License v2 or later
Text Domain: itintell
*/

/* ---------- Basis ---------- */
:root {
	--c-primary: #176ae8;
	--c-primary-dark: #0f4fb3;
	--c-ink: #1a2333;
	--c-muted: #5b6577;
	--c-bg: #ffffff;
	--c-bg-alt: #f3f6fb;
	--c-line: #e2e8f2;
	--radius: 12px;
	--shadow: 0 8px 30px rgba(23, 41, 77, 0.10);
	--font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }
body {
	margin: 0;
	font-family: var(--font);
	font-size: 17px;
	line-height: 1.65;
	color: var(--c-ink);
	background: var(--c-bg);
	-webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; }
a { color: var(--c-primary); }
a:hover { color: var(--c-primary-dark); }
h1, h2, h3, h4 { line-height: 1.25; color: var(--c-ink); }
h1 { font-size: clamp(1.9rem, 4vw, 2.8rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); }
h3 { font-size: 1.25rem; }

.wrap { max-width: 1140px; margin: 0 auto; padding: 0 1.25rem; }
.section { padding: 3.5rem 1.25rem; }
.section-alt { background: var(--c-bg-alt); }
.section-title { text-align: center; margin-bottom: 2.5rem; }
.section-cta { text-align: center; margin-top: 2.5rem; }

.screen-reader-text {
	clip: rect(1px, 1px, 1px, 1px);
	position: absolute !important;
	width: 1px; height: 1px; overflow: hidden;
}
.skip-link {
	position: absolute; left: -9999px; top: 0;
	background: var(--c-primary); color: #fff; padding: .6rem 1rem; z-index: 100;
}
.skip-link:focus { left: 0; color: #fff; }

/* ---------- Buttons ---------- */
.btn {
	display: inline-block;
	background: var(--c-primary);
	color: #fff;
	border: 2px solid var(--c-primary);
	border-radius: 999px;
	padding: .7rem 1.7rem;
	font-size: 1rem;
	font-weight: 600;
	text-decoration: none;
	cursor: pointer;
	transition: background .2s, color .2s;
}
.btn:hover { background: var(--c-primary-dark); border-color: var(--c-primary-dark); color: #fff; }
.btn-outline { background: transparent; color: var(--c-primary); }
.btn-outline:hover { background: var(--c-primary); color: #fff; }
.btn-small { padding: .4rem 1.1rem; font-size: .9rem; }

/* ---------- Topbar ---------- */
.topbar { background: var(--c-ink); color: #cdd6e4; font-size: .85rem; }
.topbar-inner { display: flex; justify-content: space-between; gap: 1rem; padding-top: .45rem; padding-bottom: .45rem; flex-wrap: wrap; }
.topbar a { color: #fff; text-decoration: none; }
.topbar .sep { margin: 0 .5rem; }

/* ---------- Header ---------- */
.site-header {
	position: sticky; top: 0; z-index: 50;
	background: rgba(255, 255, 255, .95);
	backdrop-filter: blur(8px);
	border-bottom: 1px solid var(--c-line);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; padding-top: .8rem; padding-bottom: .8rem; gap: 1.5rem; }
.branding img { max-height: 56px; width: auto; }
.site-title { font-size: 1.3rem; font-weight: 700; color: var(--c-ink); text-decoration: none; }

.nav-list { display: flex; gap: .3rem; list-style: none; margin: 0; padding: 0; }
.nav-list a {
	display: block; padding: .55rem 1rem;
	color: var(--c-ink); text-decoration: none; font-weight: 600; font-size: .95rem;
	border-radius: 8px;
	transition: background .15s, color .15s;
}
.nav-list a:hover { background: var(--c-bg-alt); color: var(--c-primary); }
.nav-list .current-menu-item > a, .nav-list .current_page_item > a { color: var(--c-primary); }

.nav-toggle { display: none; background: none; border: 0; padding: .5rem; cursor: pointer; }
.nav-toggle-bar { display: block; width: 24px; height: 2.5px; background: var(--c-ink); margin: 5px 0; border-radius: 2px; }

@media (max-width: 860px) {
	.nav-toggle { display: block; }
	.main-nav { display: none; position: absolute; top: 100%; left: 0; right: 0; background: #fff; border-bottom: 1px solid var(--c-line); box-shadow: var(--shadow); }
	.main-nav.is-open { display: block; }
	.nav-list { flex-direction: column; padding: .75rem; }
}

/* ---------- Hero-Slider ---------- */
.hero-slider { position: relative; height: min(72vh, 620px); min-height: 380px; overflow: hidden; background: var(--c-ink); }
.hero-slide {
	position: absolute; inset: 0;
	background-size: cover; background-position: center;
	opacity: 0; transition: opacity 1s ease;
	display: flex; align-items: center;
}
.hero-slide.is-active { opacity: 1; z-index: 1; }
.hero-slide-overlay { position: absolute; inset: 0; background: linear-gradient(100deg, rgba(13, 28, 56, .82) 20%, rgba(23, 106, 232, .35) 100%); }
.hero-slide-content { position: relative; z-index: 2; color: #fff; width: 100%; }
.hero-slide-content h2 { color: #fff; font-size: clamp(1.9rem, 4.5vw, 3.2rem); margin: 0 0 .75rem; max-width: 640px; }
.hero-slide-content p { font-size: clamp(1rem, 2vw, 1.3rem); max-width: 560px; margin: 0; color: #dbe6f7; }
.hero-dots { position: absolute; bottom: 1.2rem; left: 50%; transform: translateX(-50%); display: flex; gap: .55rem; z-index: 3; }
.hero-dot { width: 11px; height: 11px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .45); cursor: pointer; padding: 0; }
.hero-dot.is-active { background: #fff; }

/* ---------- Page-Hero ---------- */
.page-hero { background: linear-gradient(100deg, var(--c-ink), var(--c-primary-dark)); color: #fff; padding: 3rem 0; }
.page-hero h1 { color: #fff; margin: 0; }
.page-hero-meta { color: #c9d7ef; margin: .5rem 0 0; }

/* ---------- Cards ---------- */
.card-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1.75rem; }
.card { background: #fff; border: 1px solid var(--c-line); border-radius: var(--radius); overflow: hidden; transition: transform .2s, box-shadow .2s; }
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.card-link { display: block; color: inherit; text-decoration: none; height: 100%; }
.card-media img { display: block; width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }
.card-body { padding: 1.4rem 1.5rem 1.6rem; }
.card-body h3 { margin: .2rem 0 .6rem; }
.card-body p { color: var(--c-muted); margin: 0 0 1rem; }
.card-date { font-size: .85rem; color: var(--c-muted); }
.card-more { color: var(--c-primary); font-weight: 600; font-size: .95rem; }

/* ---------- Projekt-Karussell ---------- */
.carousel { position: relative; }
.carousel-track {
	display: flex; gap: 1.75rem;
	overflow-x: auto;
	scroll-snap-type: x mandatory;
	scroll-behavior: smooth;
	padding: .5rem .25rem 1.25rem;
	scrollbar-width: none;
}
.carousel-track::-webkit-scrollbar { display: none; }
.carousel-item {
	flex: 0 0 calc((100% - 3.5rem) / 3);
	min-width: 280px;
	scroll-snap-align: start;
}
@media (max-width: 960px) { .carousel-item { flex-basis: calc((100% - 1.75rem) / 2); } }
@media (max-width: 640px) { .carousel-item { flex-basis: 92%; } }
.carousel-btn {
	position: absolute; top: 50%; transform: translateY(-50%);
	z-index: 5;
	width: 52px; height: 52px; border-radius: 50%;
	border: 1px solid var(--c-line);
	background: #fff; color: var(--c-primary);
	font-size: 1.2rem; cursor: pointer;
	box-shadow: var(--shadow);
	transition: background .15s, color .15s;
}
.carousel-btn:hover { background: var(--c-primary); color: #fff; }
.carousel-prev { left: -20px; }
.carousel-next { right: -20px; }
.carousel-btn[disabled] { opacity: .35; cursor: default; }
.carousel-btn[disabled]:hover { background: #fff; color: var(--c-primary); }

/* ---------- Inhalt ---------- */
.entry-content { max-width: 860px; }
.entry-content img { border-radius: var(--radius); }
.entry-thumb { margin: 0 0 2rem; }
.entry-back { margin-top: 2.5rem; }
.pagination-nav { margin-top: 2.5rem; text-align: center; }
.pagination-nav .page-numbers { padding: .4rem .8rem; border-radius: 8px; text-decoration: none; }
.pagination-nav .page-numbers.current { background: var(--c-primary); color: #fff; }

/* ---------- Kontakt ---------- */
.contact-layout { display: grid; grid-template-columns: 1fr 1.4fr; gap: 3rem; max-width: 1140px; }
@media (max-width: 860px) { .contact-layout { grid-template-columns: 1fr; } }
.contact-info dl { margin: 1.5rem 0; }
.contact-info dt { font-weight: 700; margin-top: 1rem; }
.contact-info dd { margin: 0; color: var(--c-muted); }

.contact-form label { display: block; font-weight: 600; margin-bottom: .35rem; }
.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form textarea {
	width: 100%; padding: .7rem .9rem;
	border: 1px solid var(--c-line); border-radius: 8px;
	font: inherit; background: var(--c-bg-alt);
}
.contact-form input:focus, .contact-form textarea:focus { outline: 2px solid var(--c-primary); background: #fff; }
.contact-form .checkbox-row label { display: flex; gap: .6rem; font-weight: 400; align-items: flex-start; }
.contact-form .checkbox-row input { margin-top: .3rem; flex-shrink: 0; }
.contact-form .checkbox-row span { display: inline; line-height: 1.55; }
.hp-field { position: absolute !important; left: -9999px; }

.notice { border-radius: 8px; padding: .2rem 1.2rem; margin-bottom: 1.5rem; }
.notice-success { background: #e5f6ec; border: 1px solid #9adbb4; }
.notice-error { background: #fdecec; border: 1px solid #f0a9a9; }

/* ---------- Footer ---------- */
.site-footer { background: var(--c-ink); color: #aab6c9; margin-top: 3rem; }
.footer-inner { display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; padding-top: 1.8rem; padding-bottom: 1.8rem; font-size: .9rem; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }

/* ---------- Cookie-Hinweis ---------- */
.cookie-notice {
	position: fixed; bottom: 1rem; left: 50%; transform: translateX(-50%);
	max-width: 640px; width: calc(100% - 2rem);
	background: #fff; border: 1px solid var(--c-line); border-radius: var(--radius);
	box-shadow: var(--shadow);
	padding: 1rem 1.25rem;
	display: flex; gap: 1rem; align-items: center;
	z-index: 90;
	font-size: .9rem;
}
.cookie-notice p { margin: 0; }
.cookie-notice[hidden] { display: none !important; }

/* ---------- WordPress-Kern ---------- */
.alignleft { float: left; margin: 0 1.5rem 1rem 0; }
.alignright { float: right; margin: 0 0 1rem 1.5rem; }
.aligncenter { display: block; margin: 0 auto; }
.wp-caption { max-width: 100%; }
.wp-caption-text { font-size: .85rem; color: var(--c-muted); }
.sticky {}
.gallery-caption {}
.bypostauthor {}
