/**
 * Bookdragons Auth (Login/Register/Profile)
 *
 * Setzt auf Brand-CSS-Variablen aus dem Elementor-Kit auf.
 * Fallbacks fuer Stand-Alone-Nutzung sind als Default-Werte angegeben.
 */

.bd-auth-card {
	max-width: 480px;
	margin: 0 auto;
	padding: 40px 36px;
	background: var(--bd-surface, #FFFFFF);
	border: 1px solid var(--bd-cream, #F5EDE3);
	border-radius: 16px;
	font-family: 'Source Sans 3', system-ui, sans-serif;
	color: var(--bd-anthracite, #2D2926);
}

.bd-auth-title {
	font-family: 'Lora', Georgia, serif;
	font-size: 28px;
	font-weight: 700;
	margin: 0 0 8px;
	color: var(--bd-anthracite, #2D2926);
	text-align: center;
}

.bd-auth-desc {
	font-size: 15px;
	line-height: 1.6;
	margin: 0 0 28px;
	color: #6B655F;
	text-align: center;
}

.bd-auth-form {
	display: flex;
	flex-direction: column;
	gap: 18px;
}

.bd-auth-row {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 16px;
}

@media (max-width: 480px) {
	.bd-auth-row {
		grid-template-columns: 1fr;
	}
}

.bd-auth-field {
	display: flex;
	flex-direction: column;
	gap: 6px;
}

.bd-auth-field label {
	font-size: 14px;
	font-weight: 600;
	color: var(--bd-anthracite, #2D2926);
}

.bd-req {
	color: var(--bd-rose, #C4707A);
	margin-left: 2px;
}

.bd-auth-field input[type="text"],
.bd-auth-field input[type="email"] {
	width: 100%;
	padding: 12px 14px;
	font-size: 15px;
	font-family: inherit;
	color: var(--bd-anthracite, #2D2926);
	background: var(--bd-cream, #FAF7F2);
	border: 1px solid #E5DDD3;
	border-radius: 8px;
	transition: border-color 0.15s, box-shadow 0.15s;
	box-sizing: border-box;
}

.bd-auth-field input:focus {
	outline: none;
	border-color: var(--bd-rose, #C4707A);
	box-shadow: 0 0 0 3px rgba(196, 112, 122, 0.15);
}

.bd-auth-field input.bd-auth-invalid {
	border-color: #C44A4A;
}

.bd-auth-hint {
	font-size: 12px;
	color: #8B7E78;
	line-height: 1.4;
}

.bd-auth-status {
	font-size: 12px;
	font-weight: 600;
	min-height: 16px;
}

.bd-auth-status.bd-status-ok {
	color: #4A8B5F;
}

.bd-auth-status.bd-status-bad {
	color: #C44A4A;
}

/* DSGVO-Checkbox */
.bd-auth-checkbox label {
	display: flex;
	align-items: flex-start;
	gap: 10px;
	font-weight: 400;
	font-size: 14px;
	line-height: 1.5;
	cursor: pointer;
}

.bd-auth-checkbox input[type="checkbox"] {
	flex-shrink: 0;
	width: 18px;
	height: 18px;
	margin-top: 2px;
	accent-color: var(--bd-rose, #C4707A);
	cursor: pointer;
}

.bd-auth-checkbox a {
	color: var(--bd-rose, #C4707A);
	text-decoration: underline;
}

/* Button */
.bd-auth-button {
	position: relative;
	padding: 14px 24px;
	font-family: 'Source Sans 3', system-ui, sans-serif;
	font-size: 15px;
	font-weight: 600;
	color: #FFFFFF;
	background: var(--bd-rose, #C4707A);
	border: none;
	border-radius: 8px;
	cursor: pointer;
	transition: background 0.15s, transform 0.05s;
	margin-top: 8px;
}

.bd-auth-button:hover:not(:disabled) {
	background: var(--bd-rose-hover, #B35E68);
}

.bd-auth-button:active:not(:disabled) {
	transform: translateY(1px);
}

.bd-auth-button:disabled {
	opacity: 0.7;
	cursor: not-allowed;
}

/* Spinner */
.bd-auth-spinner {
	display: none;
	width: 16px;
	height: 16px;
	margin-left: 10px;
	vertical-align: -3px;
	border: 2px solid rgba(255, 255, 255, 0.5);
	border-top-color: #FFFFFF;
	border-radius: 50%;
	animation: bd-spin 0.7s linear infinite;
}

.bd-auth-button.is-loading .bd-auth-spinner {
	display: inline-block;
}

.bd-auth-button.is-loading .bd-auth-button-label {
	opacity: 0.7;
}

@keyframes bd-spin {
	to { transform: rotate(360deg); }
}

/* Meldungen */
.bd-auth-message {
	padding: 12px 16px;
	font-size: 14px;
	line-height: 1.5;
	border-radius: 8px;
	background: #FBEDED;
	color: #8B2D2D;
	border: 1px solid #F2C8C8;
}

.bd-auth-message-success {
	background: #EDF6EF;
	color: #2E5C40;
	border-color: #C8E0CC;
}

.bd-auth-footer {
	text-align: center;
	font-size: 14px;
	color: #6B655F;
	margin: 8px 0 0;
}

.bd-auth-footer a {
	color: var(--bd-rose, #C4707A);
	font-weight: 600;
	text-decoration: none;
}

.bd-auth-footer a:hover {
	text-decoration: underline;
}

/* Erfolgs-Box (E-Mail wurde gesendet) */
.bd-auth-success {
	text-align: center;
	padding: 16px 0;
}

.bd-auth-success-icon {
	width: 64px;
	height: 64px;
	margin: 0 auto 16px;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 32px;
	color: #FFFFFF;
	background: var(--bd-rose, #C4707A);
	border-radius: 50%;
}

.bd-auth-success h3 {
	font-family: 'Lora', Georgia, serif;
	font-size: 22px;
	margin: 0 0 12px;
	color: var(--bd-anthracite, #2D2926);
}

.bd-auth-success p {
	font-size: 15px;
	line-height: 1.6;
	color: #6B655F;
	margin: 0;
}

/* Logged-in Hinweis */
.bd-auth-logged-in {
	text-align: center;
	padding: 24px 36px;
}
