/* Odhad nemovitosti – moderní vzhled. Hlavní barvu nastavíte v administraci (--odh-accent). */
.odh {
	--odh-accent: #1d6fb8;
	--odh-deep: color-mix(in srgb, var(--odh-accent) 45%, #071426);
	--odh-soft: color-mix(in srgb, var(--odh-accent) 9%, #fff);
	--odh-ring: color-mix(in srgb, var(--odh-accent) 24%, transparent);
	--odh-text: #16202e;
	--odh-muted: #667589;
	--odh-line: #e3e8ef;
	--odh-field: #f4f6f9;
	--odh-err: #d92d20;
	--odh-radius: 14px;
	max-width: 980px;
	margin: 0 auto;
	font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
	font-size: 16px;
	line-height: 1.5;
	color: var(--odh-text);
	box-sizing: border-box;
	-webkit-font-smoothing: antialiased;
}
.odh *, .odh *::before, .odh *::after { box-sizing: border-box; }
.odh [hidden] { display: none !important; }

/* ---------- karta ---------- */
.odh-form {
	display: grid;
	grid-template-columns: 250px minmax(0, 1fr);
	column-gap: 44px;
	align-items: start;
	padding: 14px;
	background: #fff;
	border-radius: 28px;
	border: 1px solid var(--odh-line);
	box-shadow: 0 1px 2px rgba(16, 24, 40, .04), 0 24px 60px -20px rgba(16, 24, 40, .18);
}
.odh-form > * { grid-column: 2; }
.odh-form > .odh-rail { grid-column: 1; grid-row: 1 / span 40; }
.odh-form > .odh-grid, .odh-form > .odh-step { padding-right: 30px; }
.odh-step { padding-top: 26px; }
.odh-form > .odh-nav, .odh-form > .odh-later, .odh-form > .odh-global-error { margin-right: 30px; }
.odh-form > .odh-nav { margin-top: 28px; }
.odh-form > .odh-later { margin-bottom: 26px; }

/* ---------- tmavý panel s kroky ---------- */
.odh-rail {
	list-style: none; margin: 0; padding: 30px 24px;
	counter-reset: odh;
	position: sticky; top: 16px;
	border-radius: 18px;
	color: rgba(255, 255, 255, .62);
	background:
		radial-gradient(120% 70% at 0% 0%, color-mix(in srgb, var(--odh-accent) 80%, #fff) 0%, transparent 60%),
		linear-gradient(165deg, var(--odh-accent) -30%, var(--odh-deep) 75%);
	overflow: hidden;
}
.odh-rail::after {
	content: ""; position: absolute; right: -60px; bottom: -60px; width: 180px; height: 180px;
	border-radius: 50%; border: 28px solid rgba(255, 255, 255, .06); pointer-events: none;
}
.odh-rail li {
	counter-increment: odh; position: relative;
	display: flex; align-items: center; gap: 12px;
	padding: 9px 0; font-size: .92em; line-height: 1.3; font-weight: 500;
	transition: color .2s;
}
.odh-rail li::before {
	content: counter(odh); flex: none;
	width: 28px; height: 28px; border-radius: 50%;
	display: grid; place-items: center;
	font-size: .8em; font-weight: 700;
	border: 1.5px solid rgba(255, 255, 255, .3);
	transition: background .2s, color .2s, border-color .2s, transform .2s;
}
.odh-rail li.odh-done { color: rgba(255, 255, 255, .85); }
.odh-rail li.odh-done::before { content: "✓"; background: rgba(255, 255, 255, .18); border-color: transparent; color: #fff; }
.odh-rail li.odh-now { color: #fff; font-weight: 700; }
.odh-rail li.odh-now::before { background: #fff; color: var(--odh-deep); border-color: #fff; transform: scale(1.1); }

/* mobil: pilulková lišta místo panelu */
.odh-progress { display: none; padding: 22px 6px 0; }
.odh-progress-text { font-size: .85em; font-weight: 600; color: var(--odh-muted); margin-bottom: 10px; }
.odh-progress-track { height: 8px; background: var(--odh-line); border-radius: 99px; overflow: hidden; }
.odh-progress-bar { height: 100%; width: 0; background: linear-gradient(90deg, var(--odh-accent), color-mix(in srgb, var(--odh-accent) 60%, #6ee7f9)); border-radius: 99px; transition: width .35s cubic-bezier(.4, 0, .2, 1); }

@media (max-width: 800px) {
	.odh-form { grid-template-columns: 1fr; padding: 6px; border-radius: 22px; }
	.odh-form > *, .odh-form > .odh-rail { grid-column: 1; grid-row: auto; }
	.odh-rail { display: none; }
	.odh-progress { display: block; }
	.odh-form > .odh-grid, .odh-form > .odh-step { padding-right: 14px; padding-left: 14px; }
	.odh-form > .odh-nav, .odh-form > .odh-later, .odh-form > .odh-global-error { margin-left: 14px; margin-right: 14px; }
}

.odh-draft {
	display: flex; flex-wrap: wrap; gap: 6px 12px; align-items: center;
	background: var(--odh-soft); color: var(--odh-text);
	border-radius: 12px; padding: 12px 16px; margin-bottom: 14px; font-size: .9em;
}

/* ---------- nadpisy ---------- */
.odh-step-title { margin: 0 0 6px; font-size: 1.75em; line-height: 1.2; font-weight: 750; letter-spacing: -.025em; color: var(--odh-text); }
.odh-step-desc { margin: 0 0 26px; color: var(--odh-muted); max-width: 56ch; }

/* ---------- pole ---------- */
.odh-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px 18px; }
.odh-field { grid-column: 1 / -1; min-width: 0; }
.odh-field.odh-half { grid-column: span 1; }
@media (max-width: 560px) {
	.odh-grid { grid-template-columns: 1fr; }
	.odh-field.odh-half { grid-column: 1 / -1; }
}

.odh label, .odh legend { display: block; margin: 0 0 7px; font-size: .88em; font-weight: 600; color: var(--odh-text); }
.odh .odh-choice, .odh .odh-card { font-weight: 450; }
.odh-req { color: var(--odh-err); }
.odh-help { display: block; margin-top: 6px; color: var(--odh-muted); font-size: .82em; }
.odh-err { margin-top: 6px; color: var(--odh-err); font-size: .85em; font-weight: 600; }
.odh-err:empty { display: none; }

.odh input[type="text"], .odh input[type="email"], .odh input[type="tel"], .odh input[type="number"],
.odh select, .odh textarea {
	width: 100%; margin: 0; padding: 13px 14px; font: inherit; color: var(--odh-text);
	background: var(--odh-field); border: 1.5px solid transparent; border-radius: var(--odh-radius);
	outline: none; transition: background .15s, border-color .15s, box-shadow .15s;
}
.odh select {
	appearance: none; -webkit-appearance: none; padding-right: 40px;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23667589' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
	background-repeat: no-repeat; background-position: right 14px center; cursor: pointer;
}
.odh textarea { resize: vertical; min-height: 104px; }
.odh input::placeholder, .odh textarea::placeholder { color: #9aa7b8; }
.odh input:not([type="checkbox"]):not([type="radio"]):hover, .odh select:hover, .odh textarea:hover { border-color: var(--odh-line); }
.odh input:not([type="checkbox"]):not([type="radio"]):focus, .odh select:focus, .odh textarea:focus {
	background-color: #fff; border-color: var(--odh-accent); box-shadow: 0 0 0 4px var(--odh-ring);
}
.odh-invalid input:not([type="radio"]):not([type="checkbox"]), .odh-invalid select, .odh-invalid textarea {
	border-color: var(--odh-err); background-color: #fff5f4;
}

.odh-inputwrap { position: relative; }
.odh-unit {
	position: absolute; right: 14px; top: 0; bottom: 0; display: flex; align-items: center;
	color: var(--odh-muted); font-size: .88em; font-weight: 600; pointer-events: none;
}
.odh-inputwrap:has(.odh-unit) input { padding-right: 52px; }
.odh input[type="number"] { -moz-appearance: textfield; appearance: textfield; }
.odh input[type="number"]::-webkit-outer-spin-button, .odh input[type="number"]::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

fieldset.odh-fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
.odh-fieldset legend { padding: 0; }

/* ---------- karty typu nemovitosti ---------- */
.odh-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
@media (max-width: 560px) { .odh-cards { grid-template-columns: repeat(2, 1fr); } }
.odh-card { position: relative; display: block; margin: 0; cursor: pointer; }
.odh-card .odh-card-body { height: 100%; }
.odh-card input { position: absolute; opacity: 0; pointer-events: none; }
.odh-card-body {
	display: flex; flex-direction: column; align-items: flex-start; gap: 18px;
	min-height: 118px; padding: 18px; background: #fff;
	border: 1.5px solid var(--odh-line); border-radius: 18px;
	font-weight: 650; font-size: .95em; color: var(--odh-text);
	transition: border-color .18s, background .18s, box-shadow .18s, transform .18s;
}
.odh-card-icon {
	display: grid; place-items: center; width: 48px; height: 48px; border-radius: 14px;
	background: var(--odh-soft); color: var(--odh-accent); transition: background .18s, color .18s;
}
.odh-card-icon svg { width: 26px; height: 26px; }
.odh-card:hover .odh-card-body { border-color: color-mix(in srgb, var(--odh-accent) 45%, var(--odh-line)); transform: translateY(-2px); box-shadow: 0 10px 24px -10px rgba(16, 24, 40, .22); }
.odh-card input:checked + .odh-card-body {
	border-color: var(--odh-accent); background: var(--odh-soft);
	box-shadow: 0 0 0 4px var(--odh-ring); transform: none;
}
.odh-card input:checked + .odh-card-body .odh-card-icon { background: var(--odh-accent); color: #fff; }
.odh-card input:checked + .odh-card-body::after {
	content: "✓"; position: absolute; top: 12px; right: 12px;
	width: 22px; height: 22px; border-radius: 50%; background: var(--odh-accent); color: #fff;
	font-size: 12px; font-weight: 800; line-height: 22px; text-align: center;
}
.odh-card input:focus-visible + .odh-card-body { outline: 3px solid var(--odh-accent); outline-offset: 2px; }

/* ---------- volby ---------- */
.odh-choices { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 8px; }
.odh-choices.odh-inline { display: flex; flex-wrap: wrap; gap: 8px; }
.odh-choice {
	display: flex; align-items: center; gap: 10px; margin: 0; padding: 10px 14px;
	line-height: 1.3; cursor: pointer; background: var(--odh-field);
	border: 1.5px solid transparent; border-radius: 12px;
	transition: background .15s, border-color .15s;
}
.odh-choice:hover { border-color: var(--odh-line); background: #fff; }
.odh-choice:has(input:checked) { background: var(--odh-soft); border-color: var(--odh-accent); }
.odh-choice input { flex: none; width: 1.1em; height: 1.1em; margin: 0; accent-color: var(--odh-accent); }
.odh-choice:has(input:focus-visible) { outline: 3px solid var(--odh-ring); }
.odh-consent { margin-top: 6px; font-size: .9em; align-items: flex-start; background: transparent; padding-left: 2px; }
.odh-consent:hover, .odh-consent:has(input:checked) { background: transparent; border-color: transparent; }
.odh-consent a { color: var(--odh-accent); }

/* ---------- přílohy ---------- */
.odh-dropzone {
	display: block; margin: 0; padding: 40px 16px; text-align: center; cursor: pointer;
	background: var(--odh-field); border: 2px dashed #c3cddb; border-radius: 18px;
	transition: border-color .15s, background .15s;
}
.odh-dropzone:hover, .odh-dropzone.odh-drag { border-color: var(--odh-accent); background: var(--odh-soft); }
.odh-dz-title { display: block; font-size: 1.05em; font-weight: 650; }
.odh-dz-sub { display: block; margin-top: 6px; color: var(--odh-muted); font-size: .85em; font-weight: 400; }
.odh-file { position: absolute; width: 1px; height: 1px; opacity: 0; overflow: hidden; }
.odh-filelist { list-style: none; margin: 12px 0 0; padding: 0; }
.odh-filelist li {
	display: flex; justify-content: space-between; align-items: center; gap: 12px;
	margin-bottom: 6px; padding: 10px 14px; font-size: .9em;
	background: var(--odh-field); border-radius: 12px;
}
.odh-filelist span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- tlačítka ---------- */
.odh-nav { display: flex; justify-content: space-between; gap: 12px; }
.odh-btn {
	appearance: none; margin-left: auto; padding: 14px 28px; cursor: pointer;
	font: inherit; font-weight: 650; color: #fff;
	background: linear-gradient(180deg, color-mix(in srgb, var(--odh-accent) 88%, #fff), var(--odh-accent));
	border: 0; border-radius: 14px;
	box-shadow: 0 1px 0 rgba(255, 255, 255, .25) inset, 0 10px 22px -8px color-mix(in srgb, var(--odh-accent) 70%, transparent);
	transition: transform .15s, box-shadow .15s, filter .15s;
}
.odh-btn:hover { transform: translateY(-1px); filter: brightness(1.06); box-shadow: 0 1px 0 rgba(255, 255, 255, .25) inset, 0 14px 26px -8px color-mix(in srgb, var(--odh-accent) 80%, transparent); }
.odh-btn:active { transform: translateY(1px); filter: brightness(.96); }
.odh-btn:disabled { opacity: .6; cursor: wait; transform: none; }
.odh-btn:focus-visible, .odh-link:focus-visible { outline: 3px solid var(--odh-ring); outline-offset: 3px; }
.odh-btn-ghost { margin-left: 0; margin-right: auto; color: var(--odh-text); background: var(--odh-field); box-shadow: none; }
.odh-btn-ghost:hover { background: var(--odh-line); box-shadow: none; filter: none; }
.odh-link { padding: 0; background: none; border: 0; color: var(--odh-accent); font: inherit; font-weight: 600; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }

.odh-global-error { margin-top: 14px; color: var(--odh-err); font-weight: 600; }
.odh-global-error:empty { display: none; }

/* ---------- honeypot ---------- */
.odh-hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }

/* ---------- našeptávač ---------- */
.odh-suggest {
	position: absolute; z-index: 20; left: 0; right: 0; top: 100%;
	margin: 6px 0 0; padding: 6px; list-style: none; background: #fff;
	border: 1px solid var(--odh-line); border-radius: 14px;
	box-shadow: 0 16px 40px -12px rgba(16, 24, 40, .28);
}
.odh-suggest li { padding: 10px 12px; border-radius: 10px; font-size: .92em; cursor: pointer; }
.odh-suggest li:hover, .odh-suggest li.odh-active { background: var(--odh-soft); }

/* ---------- „Nevím“ ---------- */
.odh .odh-unk { display: inline-flex; align-items: center; gap: 7px; margin: 8px 0 0; color: var(--odh-muted); font-size: .85em; font-weight: 450; cursor: pointer; }
.odh .odh-unk input { margin: 0; accent-color: var(--odh-accent); }
.odh-unknown .odh-inputwrap input { background: #e9edf2; color: var(--odh-muted); }

/* ---------- mapa ---------- */
.odh-geo-box { margin-top: 4px; }
.odh-map { position: relative; height: 240px; margin-bottom: 10px; overflow: hidden; background: #e4e9ef; border-radius: 18px; border: 1px solid var(--odh-line); }
.odh-map img { position: absolute; max-width: none; width: 256px; height: 256px; user-select: none; }
.odh-pin {
	position: absolute; left: 50%; top: 50%; z-index: 2; width: 24px; height: 24px; margin: -24px 0 0 -12px;
	background: var(--odh-accent); border: 3px solid #fff; border-radius: 50% 50% 50% 0;
	transform: rotate(-45deg); box-shadow: 0 4px 10px rgba(0, 0, 0, .3);
}
.odh-map-attr { position: absolute; right: 8px; bottom: 6px; z-index: 3; padding: 2px 7px; font-size: 11px; color: #333; text-decoration: none; background: rgba(255, 255, 255, .88); border-radius: 6px; }
.odh-geo-link { color: var(--odh-accent); font-size: .92em; font-weight: 600; }

/* ---------- uložit na později ---------- */
.odh-later { margin-top: 20px; font-size: .9em; }
.odh-later-box { margin-top: 12px; padding: 18px; background: var(--odh-field); border-radius: 16px; }
.odh-later-row { display: flex; gap: 10px; }
.odh-later-row input { flex: 1; min-width: 0; background: #fff !important; }
.odh-later-row .odh-btn { margin: 0; padding: 12px 20px; white-space: nowrap; }
.odh-later-msg { margin-top: 10px; font-weight: 600; }
.odh-later-msg:empty { display: none; }
.odh-later-msg.odh-bad { color: var(--odh-err); }
@media (max-width: 560px) { .odh-later-row { flex-direction: column; } }

/* ---------- po odeslání ---------- */
.odh-success {
	padding: 64px 24px; text-align: center; background: #fff;
	border: 1px solid var(--odh-line); border-radius: 28px;
	box-shadow: 0 1px 2px rgba(16, 24, 40, .04), 0 24px 60px -20px rgba(16, 24, 40, .18);
}
.odh-success-icon {
	display: grid; place-items: center; width: 68px; height: 68px; margin: 0 auto 18px;
	border-radius: 50%; color: #fff; font-size: 30px; font-weight: 800;
	background: linear-gradient(160deg, var(--odh-accent), var(--odh-deep));
	box-shadow: 0 0 0 8px var(--odh-ring);
	animation: odh-pop .5s cubic-bezier(.2, 1.4, .4, 1);
}
.odh-success-text { max-width: 30ch; margin: 0 auto; font-size: 1.3em; font-weight: 650; line-height: 1.35; letter-spacing: -.01em; }
@keyframes odh-pop { from { transform: scale(.4); opacity: 0; } to { transform: scale(1); opacity: 1; } }

@media (prefers-reduced-motion: reduce) {
	.odh *, .odh *::before { transition: none !important; animation: none !important; }
}
