/*
Theme Name: LM-Umfrage
Theme URI: https://likemachines.com
Author: LikeMachines
Author URI: https://likemachines.com
Description: Minimalstes Theme zum Darstellen und Stylen eines WPForms-Formulars und dessen Umgebung.
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: umfrage
*/

/* ==========================================================================
   Schriftart – Roboto (lokal gehostet, DSGVO-konform, keine Google-Requests)
   Variable Font: ein File deckt 100–900 ab. Apache License 2.0.
   ========================================================================== */
@font-face {
	font-family: "Roboto";
	font-style: normal;
	font-weight: 100 900;
	font-display: swap;
	src: url("fonts/roboto-latin.woff2") format("woff2");
	unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
	font-family: "Roboto";
	font-style: normal;
	font-weight: 100 900;
	font-display: swap;
	src: url("fonts/roboto-latin-ext.woff2") format("woff2");
	unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* ==========================================================================
   Design Tokens
   ========================================================================== */
:root {
	--umf-bg: #f4f5f7;
	--umf-surface: #ffffff;
	--umf-text: #1a1c1f;
	--umf-muted: #6b7280;
	--umf-border: #d8dbe0;
	--umf-accent: #2563eb;
	--umf-accent-hover: #1d4ed8;
	--umf-radius: 10px;
	--umf-gap: 1.25rem;
	--umf-maxw: 80vw;
	--umf-font: "Roboto", -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
}

/* ==========================================================================
   Reset / Base
   ========================================================================== */
*,
*::before,
*::after {
	box-sizing: border-box;
}

html {
	-webkit-text-size-adjust: 100%;
}

body {
	margin: 0;
	font-family: var(--umf-font);
	font-size: 16px;
	line-height: 1.6;
	color: var(--umf-text);
	background: var(--umf-bg);
}

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

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

/* ==========================================================================
   Layout
   ========================================================================== */
.umf-site {
	display: flex;
	flex-direction: column;
	min-height: 100vh;
}

.umf-header,
.umf-footer {
	padding: 1.5rem 1.25rem;
	text-align: center;
}

.umf-footer {
	margin-top: auto;
	color: var(--umf-muted);
	font-size: 0.85rem;
}

.umf-site-title {
	margin: 0;
	font-size: 1.25rem;
	font-weight: 600;
}

.umf-site-title a {
	color: inherit;
	text-decoration: none;
}

.umf-main {
	width: 100%;
	max-width: var(--umf-maxw);
	margin: 2rem auto;
	padding: 0 1.25rem;
}

.umf-card {
	background: var(--umf-surface);
	border: 1px solid var(--umf-border);
	border-radius: var(--umf-radius);
	padding: 2rem;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.umf-entry-title {
	margin-top: 0;
	font-size: 1.6rem;
	line-height: 1.25;
}

/* ==========================================================================
   WPForms Styling
   --------------------------------------------------------------------------
   Überschreibt das Standard-Markup von WPForms. Selektoren bewusst spezifisch
   genug, um die Plugin-Defaults zu schlagen, ohne !important wo möglich.
   ========================================================================== */
.wpforms-container .wpforms-form {
	display: flex;
	flex-direction: column;
	gap: var(--umf-gap);
}

.wpforms-container .wpforms-field {
	padding: 0;
}

.wpforms-container .wpforms-field-label {
	display: block;
	margin-bottom: 0.4rem;
	font-weight: 600;
	font-size: 0.95rem;
}

.wpforms-container .wpforms-required-label {
	color: #dc2626;
}

.wpforms-container .wpforms-field-description {
	margin-top: 0.35rem;
	color: var(--umf-muted);
	font-size: 0.85rem;
}

/* Eingabefelder */
.wpforms-container input[type="text"],
.wpforms-container input[type="email"],
.wpforms-container input[type="url"],
.wpforms-container input[type="password"],
.wpforms-container input[type="tel"],
.wpforms-container input[type="number"],
.wpforms-container input[type="date"],
.wpforms-container select,
.wpforms-container textarea {
	width: 100%;
	padding: 0.7rem 0.85rem;
	font-size: 1rem;
	font-family: inherit;
	color: var(--umf-text);
	background: #fff;
	border: 1px solid var(--umf-border);
	border-radius: 8px;
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.wpforms-container textarea {
	min-height: 130px;
	resize: vertical;
}

.wpforms-container input:focus,
.wpforms-container select:focus,
.wpforms-container textarea:focus {
	outline: none;
	border-color: var(--umf-accent);
	box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

/* Checkbox / Radio Listen */
.wpforms-container ul.wpforms-field-required-text,
.wpforms-container .wpforms-field-checkbox ul,
.wpforms-container .wpforms-field-radio ul {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
}

.wpforms-container .wpforms-field-checkbox li,
.wpforms-container .wpforms-field-radio li {
	display: flex;
	align-items: center;
	gap: 0.5rem;
}

.wpforms-container .wpforms-field-checkbox input,
.wpforms-container .wpforms-field-radio input {
	width: auto;
	margin: 0;
}

/* Submit-Button */
.wpforms-container .wpforms-submit-container {
	margin: 0;
}

.wpforms-container button[type="submit"],
.wpforms-container .wpforms-submit {
	display: inline-block;
	padding: 0.75rem 1.5rem;
	font-size: 1rem;
	font-weight: 600;
	font-family: inherit;
	color: #fff;
	background: var(--umf-accent);
	border: none;
	border-radius: 8px;
	cursor: pointer;
	transition: background 0.15s ease;
}

.wpforms-container button[type="submit"]:hover,
.wpforms-container .wpforms-submit:hover {
	background: var(--umf-accent-hover);
}

.wpforms-container button[type="submit"]:focus {
	outline: none;
	box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.3);
}

/* Validierung / Fehler */
.wpforms-container label.wpforms-error {
	color: #dc2626;
	font-size: 0.85rem;
	margin-top: 0.3rem;
	display: block;
}

.wpforms-container input.wpforms-error,
.wpforms-container select.wpforms-error,
.wpforms-container textarea.wpforms-error {
	border-color: #dc2626;
}

/* Bestätigungsmeldung */
.wpforms-confirmation-container-full {
	background: #ecfdf5;
	border: 1px solid #a7f3d0;
	color: #065f46;
	padding: 1rem 1.25rem;
	border-radius: 8px;
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 600px) {
	.umf-card {
		padding: 1.5rem 1.25rem;
	}

	.umf-main {
		margin: 1.25rem auto;
	}
}
