/* Factory Handball – Turnaje
 * Values taken from the existing "Aktuálne turnaje" cards on factoryhandball.com.
 * Override the variables below in Elementor > Site Settings > Custom CSS if anything changes. */
:root {
	--fh-accent: #e31e24;
	--fh-accent-hover: #c8191f;
	--fh-card-bg: #17181b;
	--fh-border: #26282c;
	--fh-input-bg: #0f1012;
	--fh-text: #ffffff;
	--fh-muted: #7a7a7a;
	--fh-radius: 10px;
	--fh-font-head: "Onest", sans-serif;
	--fh-font-body: "Open Sans", sans-serif;
}

/* ---------- Tournament grid ---------- */
.fh-grid {
	display: grid;
	grid-template-columns: repeat(var(--fh-cols, 4), minmax(0, 1fr));
	gap: 20px;
	align-items: start; /* opening one card doesn't stretch its neighbours */
}
@media (max-width: 1024px) { .fh-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px)  { .fh-grid { grid-template-columns: 1fr; } }

.fh-card {
	background: var(--fh-card-bg);
	border: 2px solid var(--fh-border);
	border-radius: var(--fh-radius);
	padding: 36px;
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	color: var(--fh-text);
}
.fh-card__badge {
	display: inline-block;
	margin: 0 0 12px;
	background: var(--fh-accent);
	color: #fff !important;
	font-family: var(--fh-font-head);
	font-size: 12px;
	font-weight: 500;
	line-height: 12px;
	padding: 12px 24px;
	border-radius: 3px;
	text-decoration: none !important;
	transition: background-color .2s;
}
a.fh-card__badge:hover { background: var(--fh-accent-hover); }
.fh-card__title {
	margin: 0 0 18px;
	font-family: var(--fh-font-head);
	font-size: 27px;
	font-weight: 800;
	line-height: 1.2;
	letter-spacing: -1px;
	text-transform: uppercase;
	color: var(--fh-text);
	overflow-wrap: anywhere;
}
.fh-card__title a { color: inherit !important; text-decoration: none !important; }
.fh-card__title a:hover { color: var(--fh-accent) !important; }
.fh-card__desc {
	margin: 0 0 16px;
	font-family: var(--fh-font-body);
	font-size: 15px;
	font-weight: 400;
	line-height: 1.5;
	color: var(--fh-muted);
}
.fh-card__meta {
	margin: -6px 0 16px;
	font-family: var(--fh-font-body);
	font-size: 13px;
	line-height: 1.5;
	color: var(--fh-muted);
}
.fh-empty { font-family: var(--fh-font-body); font-size: 15px; color: var(--fh-muted); }


/* ---------- Card details (collapsible) ---------- */
.fh-card__details { width: 100%; margin-top: auto; border-top: 2px solid var(--fh-border); }
.fh-card__details summary {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	padding: 16px 0 0;
	list-style: none;
	cursor: pointer;
	font-family: var(--fh-font-head);
	font-size: 13px;
	font-weight: 500;
	color: var(--fh-text);
	user-select: none;
}
.fh-card__details summary::-webkit-details-marker { display: none; }
.fh-card__details summary:hover,
.fh-card__details summary:focus-visible { color: var(--fh-accent); outline: none; }
.fh-card__chev { flex: none; color: var(--fh-accent); transition: transform .2s; }
.fh-card__details[open] .fh-card__chev { transform: rotate(180deg); }
.fh-card__less { display: none; }
.fh-card__details[open] .fh-card__less { display: inline; }
.fh-card__details[open] .fh-card__more { display: none; }

.fh-card__panel { padding-top: 16px; animation: fh-fade .2s ease-out; }
@keyframes fh-fade { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }

.fh-card__list { margin: 0; padding: 0; }
.fh-card__row { padding: 10px 0; border-bottom: 1px solid var(--fh-border); }
.fh-card__row:first-child { padding-top: 0; }
.fh-card__row dt {
	margin: 0 0 3px;
	font-family: var(--fh-font-head);
	font-size: 11px;
	font-weight: 500;
	letter-spacing: 1.5px;
	text-transform: uppercase;
	color: #ff5a5f;
}
.fh-card__row dd {
	margin: 0;
	font-family: var(--fh-font-body);
	font-size: 14px;
	line-height: 1.5;
	color: var(--fh-text);
	overflow-wrap: anywhere;
}
.fh-card__row dd a { color: var(--fh-text) !important; text-decoration: underline !important; text-decoration-color: var(--fh-accent) !important; text-underline-offset: 3px; }
.fh-card__row dd a:hover { color: var(--fh-accent) !important; }

.fh-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 3px; }
.fh-chip {
	padding: 4px 10px;
	background: var(--fh-input-bg);
	border: 1px solid var(--fh-border);
	border-radius: 3px;
	font-size: 12px;
	line-height: 1.4;
	color: var(--fh-text);
}

.fh-card__pdf {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	margin-top: 16px;
	padding: 12px 16px;
	background: var(--fh-accent);
	border-radius: 3px;
	color: #fff !important;
	font-family: var(--fh-font-head);
	font-size: 13px;
	font-weight: 500;
	line-height: 1;
	text-decoration: none !important;
	transition: background-color .2s;
}
.fh-card__pdf:hover { background: var(--fh-accent-hover); }

/* ---------- Form ---------- */
#fh-form { scroll-margin-top: 120px; }
.fh-form {
	position: relative;
	background: var(--fh-card-bg);
	border: 2px solid var(--fh-border);
	border-radius: var(--fh-radius);
	padding: 36px;
	color: var(--fh-text);
	font-family: var(--fh-font-body);
}
.fh-form__status { margin: 0 0 24px; font-size: 14px; line-height: 1.5; color: var(--fh-muted); }
.fh-form__status strong { color: var(--fh-text); }
.fh-form__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px 20px; }
.fh-field--full { grid-column: 1 / -1; }
.fh-field label {
	display: block;
	margin-bottom: 8px;
	font-family: var(--fh-font-head);
	font-size: 14px;
	font-weight: 500;
	line-height: 1.4;
	color: var(--fh-text);
}
.fh-form input[type="text"],
.fh-form input[type="email"],
.fh-form input[type="url"],
.fh-form input[type="tel"],
.fh-form input[type="date"],
.fh-form select,
.fh-form textarea {
	width: 100%;
	box-sizing: border-box;
	margin: 0;
	background: var(--fh-input-bg);
	border: 2px solid var(--fh-border);
	border-radius: 3px;
	color: var(--fh-text);
	font-family: var(--fh-font-body);
	font-size: 15px;
	line-height: 1.5;
	padding: 11px 14px;
	box-shadow: none;
	color-scheme: dark;
	transition: border-color .2s;
}
.fh-form textarea { min-height: 120px; resize: vertical; }
.fh-form input::placeholder, .fh-form textarea::placeholder { color: #5f5f66; opacity: 1; }
.fh-form input:focus, .fh-form textarea:focus, .fh-form select:focus {
	outline: none;
	border-color: var(--fh-accent);
}
/* Checkbox group (Vekové kategórie) */
.fh-choices { margin: 0; padding: 0; border: 0; min-width: 0; }
.fh-choices legend {
	margin: 0 0 12px;
	padding: 0;
	font-family: var(--fh-font-head);
	font-size: 14px;
	font-weight: 500;
	line-height: 1.4;
	color: var(--fh-text);
}
.fh-choices__grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 12px 20px;
	padding: 18px 20px;
	background: var(--fh-input-bg);
	border: 2px solid var(--fh-border);
	border-radius: 3px;
}
.fh-field .fh-check {
	display: flex;
	margin: 0;
	font-family: var(--fh-font-body);
	font-size: 14px;
	font-weight: 400;
	color: var(--fh-muted);
}
.fh-check:has(input:checked) span { color: var(--fh-text); }

/* PDF upload */
.fh-file input[type="file"] {
	display: block;
	width: 100%;
	box-sizing: border-box;
	padding: 6px;
	background: var(--fh-input-bg);
	border: 2px solid var(--fh-border);
	border-radius: 3px;
	color: var(--fh-muted);
	font-family: var(--fh-font-body);
	font-size: 14px;
	line-height: 1.5;
	cursor: pointer;
}
.fh-file input[type="file"]:focus { outline: none; border-color: var(--fh-accent); }
.fh-file input[type="file"]::file-selector-button {
	margin-right: 12px;
	padding: 8px 16px;
	background: var(--fh-border);
	border: 0;
	border-radius: 3px;
	color: var(--fh-text);
	font-family: var(--fh-font-head);
	font-size: 13px;
	font-weight: 500;
	cursor: pointer;
	transition: background-color .2s;
}
.fh-file input[type="file"]:hover::file-selector-button { background: var(--fh-accent); }
.fh-file__current {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 6px 14px;
	margin-top: 8px;
	font-size: 13px;
	color: var(--fh-muted);
}
.fh-file__current a { color: var(--fh-text); text-decoration: underline; }
.fh-field .fh-check--inline { display: inline-flex; font-size: 13px; }

.fh-check { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; line-height: 1.5; color: var(--fh-muted); cursor: pointer; }
.fh-check input { width: 18px; height: 18px; margin: 2px 0 0; accent-color: var(--fh-accent); flex: none; }

.fh-form__footer { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-top: 28px; flex-wrap: wrap; }
.fh-form__req { font-size: 13px; color: var(--fh-muted); }
.fh-form__actions { display: flex; gap: 12px; }
.fh-form__actions .fh-btn--ghost { order: -1; }

.fh-btn {
	display: inline-block;
	background: var(--fh-accent);
	color: #fff !important;
	border: 0;
	border-radius: 3px;
	padding: 16px 32px;
	font-family: var(--fh-font-head);
	font-size: 15px;
	font-weight: 500;
	line-height: 1;
	cursor: pointer;
	text-decoration: none !important;
	transition: background-color .2s;
}
.fh-btn:hover, .fh-btn:focus { background: var(--fh-accent-hover); }
.fh-btn--ghost { background: transparent; border: 2px solid var(--fh-border); color: #d4d4d8 !important; padding: 14px 30px; }
.fh-btn--ghost:hover, .fh-btn--ghost:focus { background: var(--fh-border); }
.fh-btn--sm { padding: 12px 24px; font-size: 12px; line-height: 12px; }

.fh-hp { position: absolute !important; left: -10000px !important; width: 1px; height: 1px; overflow: hidden; }

.fh-notice {
	margin: 0 0 20px;
	padding: 16px 20px;
	border-radius: var(--fh-radius);
	background: var(--fh-card-bg);
	border: 2px solid var(--fh-border);
	color: var(--fh-text);
	font-family: var(--fh-font-body);
	font-size: 15px;
	line-height: 1.5;
}
.fh-notice--ok  { border-left: 4px solid #2fbf5b; }
.fh-notice--err { border-left: 4px solid var(--fh-accent); }
.fh-notice ul { margin: 0; padding-left: 18px; }
.fh-notice a { color: #fff; text-decoration: underline; }

.fh-mine { list-style: none; margin: 0; padding: 0; font-family: var(--fh-font-body); font-size: 15px; color: var(--fh-muted); }
.fh-mine li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 14px 0; border-bottom: 2px solid var(--fh-border); }
.fh-mine strong { font-family: var(--fh-font-head); color: var(--fh-text); }

@media (max-width: 640px) {
	.fh-card, .fh-form { padding: 24px; }
	.fh-form__grid { grid-template-columns: 1fr; }
	.fh-choices__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); padding: 14px; }
	.fh-form__footer { flex-direction: column-reverse; align-items: stretch; }
	.fh-form__actions { flex-direction: column; }
}
