/*
 * Srdcem Robinson – vzhled formulářů (plugin srdcem-formulare)
 * Vzor: formulář na stránce Kontakt (Fluent Forms). Platí pro Contact Form 7 a Fluent Forms.
 *
 * Standardní zápis polí v CF7 (popisek vždy NAD polem, ne kolem něj):
 *     <label>Jméno a příjmení</label>
 *     [text* jmeno autocomplete:name class:main-form-input]
 *
 *     <label>Otázka</label><br><small>Nápověda pod popiskem</small>
 *     [select* otazka class:main-form-select first_as_label "- Vyberte -" "A" "B"]
 *
 *     <label>Skupina voleb</label>
 *     [radio tema use_label_element "A" "B"]
 *
 *     [acceptance souhlas class:main-form-checkbox] Text souhlasu… [/acceptance]
 *     [submit class:main-form-btn "Odeslat"]
 * Hvězdička u povinného pole se přidá sama (CF7: list Oxygenu „cf7“, zde jen sjednocený vzhled).
 * Selektory začínají „html body“, aby přebily Core Framework (main-form-*) i styly stránek.
 */

/* ---------- rozestupy a popisky (CF7) ---------- */
html body .wpcf7-form p {
	margin: 0 0 24px;
}
html body .wpcf7-form p:has(.wpcf7-form-control-wrap) > br {
	display: none;
}
html body .wpcf7-form label,
html body .wpcf7-form .sr-form-group {
	display: block;
	margin: 0 0 8px;
	font-weight: 400;
	line-height: 1.4;
	color: inherit;
}
html body .wpcf7-form p:has(.wpcf7-validates-as-required) > label::after {
	content: "\00a0*"; /* nezalomitelná mezera — hvězdička nezůstane sama na řádku */
	color: inherit;
	font-weight: 400;
}
html body .wpcf7-form small {
	display: block;
	margin: -4px 0 8px;
	font-size: .85em;
	opacity: .75;
}
html body .wpcf7-form .wpcf7-form-control-wrap {
	display: block;
	width: 100%;
}

/* ---------- pole ---------- */
html body .wpcf7-form input[type="text"],
html body .wpcf7-form input[type="email"],
html body .wpcf7-form input[type="tel"],
html body .wpcf7-form input[type="number"],
html body .wpcf7-form input[type="url"],
html body .wpcf7-form input[type="date"],
html body .wpcf7-form select,
html body .wpcf7-form textarea {
	box-sizing: border-box;
	width: 100%;
	max-width: 100% !important;
	min-height: 52px;
	margin: 0;
	padding: .6em 1.1em; /* jako Fluent na Kontaktu: výška ~53 px */
	line-height: 1.5;
	font: inherit;
	color: inherit;
	background-color: #fff;
	border: 2px solid rgba(0, 0, 0, .1);
	border-radius: 8px;
	box-shadow: 0 1px 2px rgba(0, 0, 0, .15);
	outline: none;
	transition: all .25s;
}
html body .wpcf7-form textarea {
	min-height: 160px;
	resize: vertical;
}
html body .wpcf7-form select {
	cursor: pointer;
}
html body .wpcf7-form input::placeholder,
html body .wpcf7-form textarea::placeholder {
	color: rgba(0, 0, 0, .45);
	opacity: 1;
}
/* stavy jako na Kontaktu (Fluent): najetí = červený rámeček, fokus = červený rámeček bez stínu */
html body .wpcf7-form input:not([type="checkbox"]):not([type="radio"]):not([type="submit"]):hover,
html body .wpcf7-form select:hover,
html body .wpcf7-form textarea:hover {
	background-color: #fff;
	border-color: var(--primary, #d33216);
	box-shadow: 0 1px 2px rgba(0, 0, 0, .15);
}
html body .wpcf7-form input:not([type="checkbox"]):not([type="radio"]):not([type="submit"]):focus,
html body .wpcf7-form select:focus,
html body .wpcf7-form textarea:focus {
	background-color: #fff;
	border-color: var(--primary, #d33216);
	box-shadow: none;
	outline: none;
}
html body .wpcf7-form .wpcf7-not-valid {
	border-color: var(--primary, #d33216);
}

/* telefon s předvolbou (Country Phone Field) */
html body .wpcf7-form .intl-tel-input {
	display: block;
	width: 100%;
}
html body .wpcf7-form .intl-tel-input .selected-flag {
	background-color: transparent;
	border-radius: 8px 0 0 8px;
}
html body .wpcf7-form .intl-tel-input.allow-dropdown .flag-container:hover .selected-flag {
	background-color: rgba(0, 0, 0, .04);
}

/* ---------- zaškrtávací políčka a přepínače (CF7 + Fluent) ---------- */
html body .wpcf7-form .wpcf7-list-item {
	display: block;
	margin: 0 0 10px;
}
html body .wpcf7-form .wpcf7-list-item label,
html body .fluentform .ff-el-form-check-label,
html body .fluentform .ff_tc_label {
	display: flex;
	align-items: flex-start;
	gap: 12px;
	margin: 0;
	font-weight: 400;
	cursor: pointer;
}
html body .wpcf7-form input[type="checkbox"],
html body .wpcf7-form input[type="radio"],
html body .fluentform input[type="checkbox"],
html body .fluentform input[type="radio"] {
	-webkit-appearance: auto;
	appearance: auto;
	flex: 0 0 22px;
	width: 22px;
	height: 22px;
	min-width: 22px;
	margin: 2px 0 0;
	padding: 0;
	border: 0;
	background: none;
	box-shadow: none;
	accent-color: var(--primary, #d33216);
	cursor: pointer;
}
html body .wpcf7-form .wpcf7-list-item-label::before,
html body .wpcf7-form .wpcf7-list-item-label::after {
	display: none;
}

/* ---------- tlačítko (jako na Kontaktu) ---------- */
html body .wpcf7-form .wpcf7-submit {
	-webkit-appearance: none;
	appearance: none;
	display: inline-block;
	width: auto;
	max-width: 100%;
	margin: 8px 0 0;
	padding: .93em 1.25em;
	font-family: inherit;
	font-size: 1.25em;
	font-weight: 700;
	line-height: 1.5;
	white-space: normal;
	color: #fff;
	background: var(--primary, #d33216);
	border: 0;
	border-radius: 9999px;
	cursor: pointer;
	transition: all .25s;
}
/* jako tlačítko na Kontaktu: při najetí se zvedne o 1 px */
html body .wpcf7-form .wpcf7-submit:hover:not(:disabled),
html body .wpcf7-form .wpcf7-submit:focus-visible {
	transform: translateY(-1px);
}
html body .wpcf7-form .wpcf7-submit:disabled {
	opacity: .5;
	cursor: not-allowed;
}

/* ---------- hlášky ---------- */
html body .wpcf7-form .wpcf7-not-valid-tip {
	margin-top: 6px;
	font-size: .85em;
	color: var(--primary, #d33216);
}
html body .wpcf7-form .wpcf7-response-output {
	margin: 16px 0 0;
	padding: 12px 16px;
	border-radius: 8px;
}
