/**
 * Login / Signup card — built entirely from the shared --qcm-* tokens in
 * qcm-shared.css so it matches the rest of the plugin (and the site) with
 * no colors of its own.
 */
.qcm-auth-wrap {
	display: flex;
	justify-content: center;
	padding: 40px 16px;
}
.qcm-auth-card {
	width: 100%;
	max-width: 500px;
	background: #fff;
	border-radius: var(--qcm-radius);
	box-shadow: var(--qcm-shadow);
	padding: 32px;
	border-top: 4px solid var(--qcm-green);
	box-sizing: border-box;
}
.qcm-auth-tabs {
	display: flex;
	gap: 8px;
	margin-bottom: 20px;
	background: var(--qcm-cream);
	border-radius: var(--qcm-radius);
	padding: 4px;
}
.qcm-auth-tab-btn {
	flex: 1;
	padding: 10px;
	border: none;
	background: transparent;
	border-radius: 8px;
	cursor: pointer;
	font-weight: 600;
	color: var(--qcm-green);
	font-size: 15px;
}
.qcm-auth-tab-btn.is-active {
	background: var(--qcm-green);
	color: #fff;
}
.qcm-auth-form {
	display: none;
	flex-direction: column;
	gap: 6px;
}
.qcm-auth-form.is-active {
	display: flex;
}
.qcm-auth-form label {
	font-size: 13px;
	font-weight: 600;
	color: var(--qcm-ink);
	margin-top: 8px;
}
.qcm-auth-form input,
.qcm-auth-form select {
	display: block;
	width: 100%;
	margin-top: 4px;
	padding: 10px 12px;
	border: 1px solid var(--qcm-border);
	border-radius: 8px;
	font-size: 15px;
	box-sizing: border-box;
}
.qcm-auth-form input:focus,
.qcm-auth-form select:focus {
	outline: none;
	border-color: var(--qcm-gold);
}
.qcm-auth-forgot {
	align-self: flex-end;
	font-size: 13px;
	color: var(--qcm-gold);
	text-decoration: none;
	margin-top: 6px;
}
.qcm-auth-submit {
	margin-top: 18px;
	width: 100%;
	justify-content: center;
	padding: 12px;
	font-size: 15px;
}
.qcm-auth-loggedin {
	text-align: center;
	display: flex;
	flex-direction: column;
	gap: 10px;
}
.qcm-auth-logout {
	color: var(--qcm-gold);
	font-weight: 600;
	text-decoration: none;
}


/* v3.5.0 - Continue with Google */
.qcm-google-btn {
	display: flex; align-items: center; justify-content: center; gap: 12px;
	width: 100%; box-sizing: border-box; padding: 11px 16px; margin: 0 0 4px;
	border: 1px solid #dadce0; border-radius: 10px; background: #fff; color: #3c4043;
	font: inherit; font-size: 15px; font-weight: 600; text-decoration: none; cursor: pointer;
	transition: box-shadow .15s, border-color .15s;
}
.qcm-google-btn:hover, .qcm-google-btn:focus-visible { box-shadow: 0 1px 3px rgba(60, 64, 67, .25); border-color: #c6c9cc; color: #202124; }
.qcm-google-g {
	display: inline-flex; align-items: center; justify-content: center; width: 22px; height: 22px;
	border-radius: 50%; background: #4285f4; color: #fff; font-weight: 800; font-size: 14px; line-height: 1;
}
.qcm-auth-or { position: relative; text-align: center; margin: 16px 0 14px !important; font-size: 13px; color: var(--qcm-muted, var(--qk2-mute,#64748B)); }
.qcm-auth-or::before { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 1px; background: var(--qcm-border, var(--qk2-line,#E2E8F0)); }
.qcm-auth-or span { position: relative; padding: 0 12px; background: #fff; }


/* =====================================================================
 * v3.9.3 - age-aware signup
 * Reading needs no account; the account is for print orders. Students 13+
 * sign up with their own email, a parent or guardian signs up for a younger
 * child, teachers and schools have their own form.
 * ===================================================================== */
.qcm-auth-wrap [hidden] { display: none !important; }

.qcm-auth-free {
	background: var(--qcm-cream);
	border: 1px solid var(--qcm-border);
	border-left: 4px solid var(--qcm-green);
	border-radius: 10px;
	padding: 14px 16px;
	margin: 0 0 20px;
}
.qcm-auth-free p { margin: 0; }
.qcm-auth-free__title { font-weight: 700; color: var(--qcm-green); font-size: 15px; }
.qcm-auth-free__text { font-size: 14px; line-height: 1.5; color: var(--qcm-ink); margin-top: 6px !important; }
.qcm-auth-free__link {
	display: inline-block; margin-top: 8px; font-weight: 700; font-size: 14px;
	color: var(--qcm-green); text-decoration: none; min-height: 24px;
}
.qcm-auth-free__link:hover { text-decoration: underline; }

.qcm-auth-fields { display: flex; flex-direction: column; gap: 6px; }

.qcm-auth-step { font-weight: 700; font-size: 15px; color: var(--qcm-ink); margin: 0 0 10px; }

/* Choice cards (radio buttons sit before them so CSS alone can open the right form) */
.qcm-pick-input { position: absolute !important; opacity: 0; width: 1px !important; height: 1px; margin: 0 !important; pointer-events: none; }
.qcm-pick-grid { display: grid; gap: 10px; }
.qcm-auth-form .qcm-pick {
	display: grid; grid-template-columns: 40px 1fr; grid-template-rows: auto auto; column-gap: 12px;
	align-items: center; margin: 0; padding: 12px 14px; cursor: pointer;
	border: 1.5px solid var(--qcm-border); border-radius: 12px; background: #fff;
	font-weight: 400; transition: border-color .15s, background .15s, box-shadow .15s;
}
.qcm-auth-form .qcm-pick:hover { border-color: var(--qcm-gold); }
.qcm-pick__icon { grid-row: 1 / span 2; font-size: 26px; line-height: 1; text-align: center; }
.qcm-pick__name { font-weight: 700; font-size: 15px; color: var(--qcm-ink); }
.qcm-pick__desc { font-size: 13px; color: var(--qcm-muted, var(--qk2-mute,#64748B)); line-height: 1.4; }

#qcm-pick-student:checked ~ .qcm-pick-grid .qcm-pick-student,
#qcm-pick-parent:checked ~ .qcm-pick-grid .qcm-pick-parent,
#qcm-pick-teacher:checked ~ .qcm-pick-grid .qcm-pick-teacher {
	border-color: var(--qcm-green); background: var(--qcm-cream); box-shadow: inset 0 0 0 1px var(--qcm-green);
}
#qcm-pick-student:focus-visible ~ .qcm-pick-grid .qcm-pick-student,
#qcm-pick-parent:focus-visible ~ .qcm-pick-grid .qcm-pick-parent,
#qcm-pick-teacher:focus-visible ~ .qcm-pick-grid .qcm-pick-teacher {
	outline: 3px solid var(--qcm-gold); outline-offset: 2px;
}

.qcm-auth-under { font-size: 13px; line-height: 1.5; color: var(--qcm-muted, var(--qk2-mute,#64748B)); margin: 12px 0 4px; }

/* Only the chosen person's form shows */
.qcm-role-form { display: none; margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--qcm-border); }
#qcm-pick-student:checked ~ .qcm-role-form-student,
#qcm-pick-parent:checked ~ .qcm-role-form-parent,
#qcm-pick-teacher:checked ~ .qcm-role-form-teacher { display: flex; }

.qcm-auth-rest { display: flex; flex-direction: column; gap: 6px; }

.qcm-auth-hint { font-size: 12.5px; line-height: 1.45; color: var(--qcm-muted, var(--qk2-mute,#64748B)); margin: 2px 0 0; }
.qcm-auth-hint--lead { font-size: 13.5px; color: var(--qcm-ink); margin: 0 0 4px; }

.qcm-auth-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
@media (max-width: 420px) { .qcm-auth-row { grid-template-columns: 1fr; } }

.qcm-auth-form .qcm-auth-check {
	display: flex; gap: 10px; align-items: flex-start; font-weight: 400; font-size: 13.5px; line-height: 1.45;
	margin-top: 12px; cursor: pointer;
}
.qcm-auth-form .qcm-auth-check input {
	width: 20px; height: 20px; min-width: 20px; margin: 1px 0 0; padding: 0; display: inline-block;
	accent-color: var(--qcm-green);
}

.qcm-auth-young {
	background: #fff8e6; border: 1px solid #ecd9a6; border-radius: 10px; padding: 14px; margin-top: 8px;
	font-size: 14px; line-height: 1.5; color: var(--qcm-ink);
}
.qcm-auth-young p { margin: 0 0 10px; }
.qcm-auth-young__actions { display: flex; flex-wrap: wrap; gap: 8px; }
.qcm-auth-form .qcm-auth-young__actions .qcm-btn { margin: 0; font-size: 14px; font-weight: 700; cursor: pointer; min-height: 44px; display: inline-flex; align-items: center; }

.qcm-google-btn--signup { margin-top: 10px; }
button.qcm-google-btn { width: 100%; }

.qcm-auth-foot { font-size: 13px; color: var(--qcm-muted, var(--qk2-mute,#64748B)); margin: 16px 0 0; text-align: center; }
.qcm-auth-foot a { color: var(--qcm-green); font-weight: 700; }

@media (max-width: 480px) {
	.qcm-auth-card { padding: 22px 18px; }
	.qcm-auth-wrap { padding: 24px 12px; }
}
