/* JMER – jediný stylopis webu. Barvy a rozměry jsou nahoře v :root. */

:root {
	--ink: #10233d;
	--text: #3a4b61;
	--muted: #61758a;
	--bg: #f8fafc;
	--surface: #ffffff;
	--line: #dbe5f1;
	--accent: #2459d9;
	--accent-hover: #1b47b3;
	--on-accent: #ffffff;
	--tint: #eff5ff;
	--radius: 12px;
	--wrap: 1120px;
	--font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

*,
*::before,
*::after {
	box-sizing: border-box;
}

html {
	scroll-behavior: smooth;
	scroll-padding-top: 88px;
	-webkit-text-size-adjust: 100%;
}

body {
	margin: 0;
	background: var(--bg);
	color: var(--text);
	font: 400 1.0625rem/1.65 var(--font);
}

h1,
h2,
h3 {
	color: var(--ink);
	line-height: 1.15;
	margin: 0;
	letter-spacing: -0.015em;
	text-wrap: balance;
}

h1 {
	font-size: clamp(2.25rem, 5.2vw, 3.6rem);
	font-weight: 750;
}

h2 {
	font-size: clamp(1.7rem, 3.2vw, 2.3rem);
	font-weight: 700;
}

h3 {
	font-size: 1.2rem;
	font-weight: 650;
	letter-spacing: -0.005em;
}

p {
	margin: 0;
}

a {
	color: var(--accent);
	text-underline-offset: 0.18em;
}

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

img,
svg {
	max-width: 100%;
	height: auto;
}

:focus-visible {
	outline: 2px solid var(--accent);
	outline-offset: 3px;
	border-radius: 4px;
}

.wrap {
	max-width: var(--wrap);
	margin-inline: auto;
	padding-inline: 20px;
}

.skip {
	position: absolute;
	left: -9999px;
}

.skip:focus {
	left: 12px;
	top: 12px;
	z-index: 100;
	background: var(--surface);
	padding: 8px 12px;
}

/* ---------- Hlavička ---------- */

.header {
	position: sticky;
	top: 0;
	z-index: 20;
	background: color-mix(in srgb, var(--bg) 92%, transparent);
	backdrop-filter: blur(8px);
	border-bottom: 1px solid var(--line);
}

.header .wrap {
	display: flex;
	align-items: center;
	gap: 28px;
	min-height: 68px;
}

.brand {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	color: var(--ink);
	font-weight: 700;
	font-size: 1.25rem;
	letter-spacing: -0.02em;
	text-decoration: none;
}

.brand:hover {
	color: var(--ink);
}

.brand svg,
.brand img {
	width: 34px;
	height: 34px;
	flex: none;
	border-radius: 22%;
}

.nav {
	display: flex;
	align-items: center;
	gap: 28px;
	margin-left: auto;
}

.nav a {
	color: var(--text);
	text-decoration: none;
	font-size: 0.98rem;
}

.nav a:hover {
	color: var(--ink);
}

.lang {
	display: inline-flex;
	gap: 2px;
	padding: 3px;
	border: 1px solid var(--line);
	border-radius: 999px;
	font-size: 0.82rem;
	font-weight: 600;
}

/* Obě položky mají stejné písmo a výšku řádku (jinak by odkaz zdědil větší
   písmo z .nav a) a text je vystředěný v obou směrech. */
.lang a,
.lang span {
	display: flex;
	align-items: center;
	justify-content: center;
	min-width: 38px;
	padding: 5px 10px;
	border-radius: 999px;
	font-size: inherit;
	line-height: 1.3;
	text-decoration: none;
	color: var(--muted);
}

.lang [aria-current] {
	background: var(--ink);
	color: var(--bg);
}

.menu-toggle {
	display: none;
	margin-left: auto;
	padding: 8px 12px;
	border: 1px solid var(--line);
	border-radius: 8px;
	background: var(--surface);
	color: var(--ink);
	font: inherit;
	font-size: 0.95rem;
	cursor: pointer;
}

@media (max-width: 820px) {
	.menu-toggle {
		display: block;
	}

	.nav {
		display: none;
		position: absolute;
		top: 100%;
		left: 0;
		right: 0;
		flex-direction: column;
		align-items: flex-start;
		gap: 18px;
		padding: 20px;
		background: var(--bg);
		border-bottom: 1px solid var(--line);
	}

	.header[data-open] .nav {
		display: flex;
	}
}

/* ---------- Tlačítka ---------- */

.btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 11px 20px;
	border: 1px solid var(--accent);
	border-radius: 8px;
	background: var(--accent);
	color: var(--on-accent);
	font: inherit;
	font-weight: 600;
	font-size: 0.98rem;
	line-height: 1.2;
	text-decoration: none;
	cursor: pointer;
}

.btn:hover {
	background: var(--accent-hover);
	border-color: var(--accent-hover);
	color: var(--on-accent);
}

.btn.ghost {
	background: transparent;
	border-color: var(--line);
	color: var(--ink);
}

.btn.ghost:hover {
	border-color: var(--ink);
	background: transparent;
	color: var(--ink);
}

.actions {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
}

/* ---------- Úvod ---------- */

.hero {
	position: relative;
	overflow: hidden;
	padding: clamp(56px, 9vw, 112px) 0 clamp(56px, 8vw, 96px);
}

.hero .wrap {
	position: relative;
}

.hero-text {
	max-width: 720px;
}

.eyebrow {
	margin-bottom: 18px;
	color: var(--accent);
	font-size: 0.82rem;
	font-weight: 700;
	letter-spacing: 0.09em;
	text-transform: uppercase;
}

.lead {
	margin: 22px 0 32px;
	max-width: 620px;
	font-size: clamp(1.1rem, 1.6vw, 1.25rem);
	line-height: 1.6;
}

.hero .wrap {
	display: grid;
	grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
	align-items: center;
	gap: 40px;
}

.hero-photo {
	border-radius: 24px;
	background: radial-gradient(closest-side, var(--tint), transparent);
}

.hero-photo img {
	display: block;
	width: 100%;
}

/* Schéma řídicího modulu v úvodu; barvy bere z proměnných webu. */
.hero-diagram {
	display: block;
	width: 100%;
	height: auto;
	overflow: visible;
	fill: none;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.hero-diagram text {
	fill: var(--ink);
	font: 600 19px var(--font);
}

.hero-diagram .pcb {
	fill: var(--tint);
	stroke: var(--ink);
	stroke-width: 2.5;
}

.hero-diagram .hole circle {
	fill: var(--bg);
	stroke: var(--ink);
	stroke-width: 1.5;
}

.hero-diagram .part {
	fill: var(--surface);
	stroke: var(--ink);
	stroke-width: 2;
}

.hero-diagram .chip {
	fill: var(--line);
	stroke: var(--ink);
	stroke-width: 2;
}

.hero-diagram .dot {
	fill: var(--ink);
}

.hero-diagram .thin {
	stroke: var(--ink);
	stroke-width: 1.5;
}

.hero-diagram .slot,
.hero-diagram .antenna {
	fill: var(--accent);
}

.hero-diagram .pins {
	fill: var(--surface);
	opacity: 0.85;
}

.hero-diagram .switch,
.hero-diagram .lte-chip {
	fill: var(--tint);
	stroke: var(--accent);
	stroke-width: 2;
}

.hero-diagram .toggle {
	fill: var(--surface);
	stroke: var(--accent);
	stroke-width: 1.5;
}

.hero-diagram .lte,
.hero-diagram .lte-part {
	fill: var(--surface);
	stroke: var(--accent);
	stroke-width: 2.5;
}

.hero-diagram .lte-part {
	stroke-width: 2;
}

.hero-diagram .cable {
	stroke: var(--accent);
	stroke-width: 2.5;
}

.hero-diagram .lead {
	stroke: var(--muted);
	stroke-width: 1.5;
}

@media (max-width: 900px) {
	.hero .wrap {
		grid-template-columns: 1fr;
	}

	.hero-photo {
		max-width: 460px;
	}
}

/* ---------- Sekce ---------- */

.section {
	padding: clamp(56px, 8vw, 92px) 0;
	border-top: 1px solid var(--line);
}

.section.tinted {
	background: var(--tint);
}

.section-head {
	max-width: 680px;
	margin-bottom: 40px;
}

.section-head p {
	margin-top: 14px;
}

.cards {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
	gap: 18px;
}

.cards.two {
	grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}

.cards.four {
	grid-template-columns: repeat(4, 1fr);
}

@media (max-width: 1040px) {
	.cards.four {
		grid-template-columns: repeat(2, 1fr);
	}
}

@media (max-width: 560px) {
	.cards.four {
		grid-template-columns: 1fr;
	}
}

.card {
	display: flex;
	flex-direction: column;
	gap: 12px;
	padding: 26px;
	background: var(--surface);
	border: 1px solid var(--line);
	border-radius: var(--radius);
}

.card p {
	font-size: 1rem;
	line-height: 1.6;
}

.card .icon {
	width: 30px;
	height: 30px;
	color: var(--accent);
}

.card .more {
	margin-top: auto;
	padding-top: 10px;
	font-weight: 600;
	text-decoration: none;
}

.card .more:hover {
	text-decoration: underline;
}

.card .kind {
	color: var(--muted);
	font-size: 0.8rem;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
}

/* ---------- Kontakt ---------- */

.contact {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
	gap: 40px;
}

.contact .big {
	display: block;
	margin-top: 18px;
	color: var(--ink);
	font-size: clamp(1.35rem, 2.6vw, 1.75rem);
	font-weight: 700;
	letter-spacing: -0.01em;
	text-decoration-color: var(--accent);
	overflow-wrap: anywhere;
}

.contact .phone {
	display: block;
	margin-top: 8px;
	color: var(--text);
	font-size: 1.1rem;
	text-decoration: none;
}

.company {
	font-size: 0.98rem;
	line-height: 1.7;
}

.company strong {
	color: var(--ink);
}

/* ---------- Podstránky ---------- */

.ticks {
	display: grid;
	gap: 8px;
	margin: 4px 0 0;
	padding: 0;
	list-style: none;
	font-size: 1rem;
	line-height: 1.5;
}

.ticks li {
	position: relative;
	padding-left: 22px;
}

.ticks li::before {
	content: "";
	position: absolute;
	left: 2px;
	top: 0.62em;
	width: 8px;
	height: 2px;
	border-radius: 2px;
	background: var(--accent);
}

address {
	font-style: normal;
}

.nav a[aria-current="page"] {
	color: var(--ink);
	font-weight: 600;
}

.page {
	padding: clamp(40px, 7vw, 80px) 0 clamp(56px, 8vw, 96px);
}

.page h1 {
	font-size: clamp(2rem, 4.4vw, 3rem);
}

.page .section-head p {
	margin-top: 16px;
}

.prose > * {
	max-width: 780px;
}

.prose h2 {
	margin-top: 44px;
	font-size: 1.45rem;
}

.prose ul:not(.ticks) {
	margin: 12px 0 0;
	padding-left: 22px;
}

.prose li + li {
	margin-top: 6px;
}

.prose p,
.prose .ticks {
	margin-top: 16px;
}

/* ---------- Stránka hardwaru ---------- */

.after {
	margin-top: 28px;
	font-weight: 600;
}

.module {
	display: grid;
	grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
	gap: clamp(20px, 4vw, 48px);
	align-items: start;
	padding: clamp(28px, 5vw, 48px) 0;
	border-top: 1px solid var(--line);
	scroll-margin-top: 80px;
}

.module img {
	display: block;
	width: 100%;
}

.module .kind {
	color: var(--accent);
	font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
	font-size: 0.9rem;
	font-weight: 700;
	letter-spacing: 0.02em;
}

.module h2 {
	margin-top: 6px;
	font-size: clamp(1.4rem, 2.6vw, 1.8rem);
}

.module p + p,
.module h2 + p {
	margin-top: 14px;
}

@media (max-width: 760px) {
	.module {
		grid-template-columns: 1fr;
	}

	.module img {
		max-width: 420px;
	}
}

/* ---------- Patička ---------- */

.footer {
	padding: 28px 0 36px;
	border-top: 1px solid var(--line);
	color: var(--muted);
	font-size: 0.9rem;
}

.footer .wrap {
	display: flex;
	flex-wrap: wrap;
	gap: 8px 24px;
	justify-content: space-between;
}

.footer a {
	color: var(--muted);
}

.footer nav {
	display: flex;
	flex-wrap: wrap;
	gap: 8px 20px;
}

/* ---------- Lišta cookies ---------- */

.consent {
	position: fixed;
	z-index: 50;
	left: 0;
	right: 0;
	bottom: 0;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: center;
	gap: 18px 40px;
	padding: 26px max(20px, calc((100vw - var(--wrap)) / 2 + 20px));
	background: var(--ink);
	border-top: 4px solid var(--accent);
	box-shadow: 0 -16px 48px rgb(0 0 0 / 0.28);
	color: #ffffff;
	animation: consent-in 0.45s ease-out;
}

.consent[hidden] {
	display: none;
}

@keyframes consent-in {
	from {
		transform: translateY(100%);
	}
}

@media (prefers-reduced-motion: reduce) {
	.consent {
		animation: none;
	}
}

.consent-text {
	flex: 1 1 380px;
}

.consent-text strong {
	display: block;
	margin-bottom: 6px;
	font-size: 1.25rem;
	line-height: 1.25;
	letter-spacing: -0.01em;
}

.consent-text p {
	color: rgb(255 255 255 / 0.86);
	font-size: 1rem;
	line-height: 1.55;
}

.consent a {
	color: #ffffff;
}

.consent .actions {
	flex: none;
	gap: 12px;
}

/* Obě tlačítka jsou stejně velká a na jedno kliknutí; souhlas je plný, odmítnutí obrysové. */
.consent .btn {
	min-width: 150px;
	padding: 14px 26px;
	font-size: 1.05rem;
}

.consent .btn.ghost {
	border-color: rgb(255 255 255 / 0.6);
	color: #ffffff;
}

.consent .btn.ghost:hover {
	border-color: #ffffff;
	color: #ffffff;
}

@media (max-width: 640px) {
	.consent {
		padding-top: 22px;
		padding-bottom: 22px;
	}

	.consent .actions {
		flex: 1 1 100%;
		flex-direction: column-reverse;
	}

	.consent .btn {
		width: 100%;
	}
}

/* ---------- Přihlášení v hlavičce ---------- */

.nav .btn {
	padding: 9px 16px;
	color: var(--on-accent);
}

/* ---------- Kroky ---------- */

.steps {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
	gap: 18px;
	margin: 0;
	padding: 0;
	list-style: none;
	counter-reset: step;
}

.steps li {
	counter-increment: step;
	padding: 26px;
	background: var(--surface);
	border: 1px solid var(--line);
	border-radius: var(--radius);
}

.steps li::before {
	content: counter(step);
	display: grid;
	place-items: center;
	width: 34px;
	height: 34px;
	margin-bottom: 16px;
	border-radius: 50%;
	background: var(--accent);
	color: var(--on-accent);
	font-weight: 700;
}

.steps h3 {
	margin-bottom: 10px;
}

.steps p {
	font-size: 1rem;
	line-height: 1.6;
}

/* ---------- Schéma ---------- */

.figure {
	margin: 40px 0 0;
	padding: clamp(12px, 3vw, 28px);
	background: var(--surface);
	border: 1px solid var(--line);
	border-radius: var(--radius);
}

.figure img {
	display: block;
	width: 100%;
	max-width: 900px;
	margin-inline: auto;
}

.figure figcaption {
	margin-top: 14px;
	color: var(--muted);
	font-size: 0.9rem;
	text-align: center;
}

/* ---------- Desky ---------- */

.boards {
	display: grid;
	grid-template-columns: repeat(5, 1fr);
	gap: 18px;
}

@media (max-width: 1000px) {
	.boards {
		grid-template-columns: repeat(3, 1fr);
	}
}

@media (max-width: 600px) {
	.boards {
		grid-template-columns: repeat(2, 1fr);
	}
}

.board {
	display: flex;
	flex-direction: column;
	background: var(--surface);
	border: 1px solid var(--line);
	border-radius: var(--radius);
	color: inherit;
	text-decoration: none;
	overflow: hidden;
}

.board:hover {
	border-color: var(--accent);
	color: inherit;
}

.board img {
	display: block;
	width: 100%;
	aspect-ratio: 4 / 3;
	object-fit: contain;
	padding: 10px;
}

.board div {
	padding: 16px 18px 20px;
}

.board h3 {
	font-size: 1rem;
	font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
	letter-spacing: 0;
}

.board p {
	margin-top: 6px;
	font-size: 0.93rem;
	line-height: 1.5;
}

/* ---------- Dvojice text + odkazy ---------- */

.split {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
	gap: 40px;
	align-items: start;
}

.split h2 + p {
	margin-top: 14px;
}

.split .actions {
	margin-top: 24px;
}

.checks {
	display: grid;
	gap: 14px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.checks li {
	padding-left: 30px;
	background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Ccircle cx='10' cy='10' r='10' fill='%232459d9'/%3E%3Cpath d='m6 10.5 2.6 2.6L14 7.6' fill='none' stroke='%23fff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat 0 0.3em / 20px;
}

.checks strong {
	color: var(--ink);
}
