/**
 * Solquara Accounts — form styling.
 *
 * Palette taken from the live solquara.com computed styles so these pages sit
 * inside the existing theme without looking bolted on. Everything is scoped to
 * .sqa and uses explicit values, because the block theme's own resets are
 * aggressive about inputs and buttons.
 */

/* The block theme paints the page white. The site is obsidian everywhere else,
   and the homepage overrides it inline the same way, so match that. */
body.sqa-auth-page {
	background: #0b0a08 !important;
}

.sqa {
	--sqa-obsidian: #0b0a08;
	--sqa-surface: #151210;
	--sqa-raised: #1c1206;
	--sqa-line: #2a2118;
	--sqa-line-soft: #4a3b29;
	--sqa-solar: #f28c28;
	--sqa-solar-lift: #ffb25e;
	--sqa-cream: #f4f0e8;
	--sqa-muted: #a69d8c;
	--sqa-bad: #ff6b5e;
	--sqa-ok: #4ade80;

	display: flex;
	justify-content: center;
	padding: clamp(1.5rem, 5vw, 4rem) 1rem;
	font-family: Montserrat, "Fira Sans", system-ui, -apple-system, sans-serif;
	color: var(--sqa-cream);
	box-sizing: border-box;
}

.sqa *,
.sqa *::before,
.sqa *::after {
	box-sizing: inherit;
}

/* ---------- Card ---------- */

.sqa-card {
	width: 100%;
	max-width: 27rem;
	background: linear-gradient(180deg, var(--sqa-surface) 0%, var(--sqa-obsidian) 100%);
	border: 1px solid var(--sqa-line);
	border-radius: 22px;
	padding: clamp(1.75rem, 4vw, 2.5rem);
	box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
}

.sqa-card--tight {
	text-align: center;
}

.sqa-title {
	margin: 0 0 0.4rem;
	font-size: clamp(1.5rem, 3.5vw, 1.9rem);
	font-weight: 600;
	line-height: 1.2;
	letter-spacing: -0.01em;
	color: var(--sqa-cream);
}

.sqa-sub {
	margin: 0 0 1.75rem;
	font-size: 0.95rem;
	line-height: 1.5;
	color: var(--sqa-muted);
}

/* ---------- Fields ---------- */

.sqa-form {
	display: flex;
	flex-direction: column;
	gap: 1.15rem;
	margin: 0;
}

.sqa-field {
	display: flex;
	flex-direction: column;
	gap: 0.45rem;
}

.sqa-label {
	font-size: 0.8rem;
	font-weight: 600;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--sqa-muted);
}

.sqa input[type="text"],
.sqa input[type="email"],
.sqa input[type="password"] {
	width: 100%;
	margin: 0;
	padding: 0.85rem 1rem;
	font: inherit;
	font-size: 1rem;
	color: var(--sqa-cream);
	background: var(--sqa-raised);
	border: 1px solid var(--sqa-line-soft);
	border-radius: 12px;
	outline: none;
	transition: border-color 0.18s ease, box-shadow 0.18s ease;
	-webkit-appearance: none;
	appearance: none;
}

.sqa input::placeholder {
	color: rgba(166, 157, 140, 0.65);
}

.sqa input[type="text"]:focus,
.sqa input[type="email"]:focus,
.sqa input[type="password"]:focus {
	border-color: var(--sqa-solar);
	box-shadow: 0 0 0 3px rgba(242, 140, 40, 0.22);
}

/* Chrome paints its own autofill background; this keeps the field dark. */
.sqa input:-webkit-autofill,
.sqa input:-webkit-autofill:hover,
.sqa input:-webkit-autofill:focus {
	-webkit-text-fill-color: var(--sqa-cream);
	-webkit-box-shadow: 0 0 0 100px var(--sqa-raised) inset;
	caret-color: var(--sqa-cream);
}

/* ---------- Password reveal ---------- */

.sqa-pass {
	position: relative;
	display: block;
}

.sqa-pass input {
	padding-right: 4.25rem;
}

.sqa-reveal {
	position: absolute;
	top: 50%;
	right: 0.5rem;
	transform: translateY(-50%);
	padding: 0.35rem 0.6rem;
	font: inherit;
	font-size: 0.78rem;
	font-weight: 600;
	letter-spacing: 0.04em;
	color: var(--sqa-muted);
	background: transparent;
	border: 0;
	border-radius: 8px;
	cursor: pointer;
	transition: color 0.18s ease, background 0.18s ease;
}

.sqa-reveal:hover,
.sqa-reveal:focus-visible {
	color: var(--sqa-solar-lift);
	background: rgba(242, 140, 40, 0.1);
}

/* ---------- Strength meter ---------- */

.sqa-meter {
	display: flex;
	align-items: center;
	gap: 0.6rem;
	margin-top: 0.15rem;
}

.sqa-meter-bar {
	position: relative;
	flex: 1;
	height: 4px;
	background: var(--sqa-line);
	border-radius: 99px;
	overflow: hidden;
}

.sqa-meter-bar > span {
	display: block;
	width: 0;
	height: 100%;
	border-radius: 99px;
	background: var(--sqa-bad);
	transition: width 0.25s ease, background 0.25s ease;
}

.sqa-meter-text {
	min-width: 4.5rem;
	font-size: 0.75rem;
	font-weight: 600;
	letter-spacing: 0.04em;
	color: var(--sqa-muted);
	text-align: right;
}

.sqa-meter[data-level="2"] .sqa-meter-bar > span { background: #e0a32e; }
.sqa-meter[data-level="3"] .sqa-meter-bar > span { background: var(--sqa-solar); }
.sqa-meter[data-level="4"] .sqa-meter-bar > span { background: var(--sqa-ok); }

.sqa-hint {
	font-size: 0.8rem;
	line-height: 1.45;
	color: var(--sqa-muted);
}

/* ---------- Row: remember / forgot ---------- */

.sqa-row {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75rem;
	align-items: center;
	justify-content: space-between;
	font-size: 0.88rem;
}

.sqa-check {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	color: var(--sqa-muted);
	cursor: pointer;
}

.sqa-check input {
	width: 1rem;
	height: 1rem;
	margin: 0;
	accent-color: var(--sqa-solar);
	cursor: pointer;
}

/* ---------- Buttons ---------- */

.sqa .sqa-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	margin-top: 0.35rem;
	padding: 0.95rem 1.5rem;
	font: inherit;
	font-size: 0.95rem;
	font-weight: 700;
	letter-spacing: 0.03em;
	color: var(--sqa-obsidian);
	text-decoration: none;
	background: linear-gradient(135deg, var(--sqa-solar-lift) 0%, var(--sqa-solar) 100%);
	border: 0;
	border-radius: 99px;
	cursor: pointer;
	transition: transform 0.18s ease, box-shadow 0.18s ease, opacity 0.18s ease;
}

.sqa .sqa-btn:hover {
	transform: translateY(-1px);
	box-shadow: 0 10px 26px rgba(242, 140, 40, 0.3);
}

.sqa .sqa-btn:active {
	transform: translateY(0);
}

.sqa .sqa-btn[disabled] {
	opacity: 0.6;
	cursor: default;
	transform: none;
	box-shadow: none;
}

.sqa .sqa-btn--ghost {
	color: var(--sqa-cream);
	background: transparent;
	border: 1px solid var(--sqa-line-soft);
}

.sqa .sqa-btn--ghost:hover {
	border-color: var(--sqa-solar);
	box-shadow: none;
}

.sqa-actions {
	display: flex;
	flex-direction: column;
	gap: 0.65rem;
	margin-top: 1.5rem;
}

/* ---------- Links and footer ---------- */

.sqa .sqa-link {
	color: var(--sqa-solar-lift);
	text-decoration: none;
	border-bottom: 1px solid rgba(255, 178, 94, 0.35);
	transition: border-color 0.18s ease;
}

.sqa .sqa-link:hover {
	border-bottom-color: var(--sqa-solar-lift);
}

.sqa-foot {
	margin: 1.6rem 0 0;
	font-size: 0.9rem;
	text-align: center;
	color: var(--sqa-muted);
}

/* ---------- Notices ---------- */

.sqa-notice {
	margin: 0 0 1.25rem;
	padding: 0.85rem 1rem;
	font-size: 0.9rem;
	line-height: 1.5;
	border-radius: 12px;
	border: 1px solid;
}

.sqa-notice p {
	margin: 0;
}

.sqa-notice p + p {
	margin-top: 0.5rem;
}

.sqa-notice--bad {
	color: #ffd9d4;
	background: rgba(255, 107, 94, 0.1);
	border-color: rgba(255, 107, 94, 0.4);
}

.sqa-notice--ok {
	color: #d6f5e0;
	background: rgba(74, 222, 128, 0.1);
	border-color: rgba(74, 222, 128, 0.4);
}

.sqa-notice a {
	color: inherit;
	font-weight: 600;
}

/* ---------- Honeypot ---------- */

/* Off-screen rather than display:none — some bots skip hidden inputs. */
.sqa-hp {
	position: absolute !important;
	left: -9999px !important;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

/* ---------- Motion ---------- */

@media (prefers-reduced-motion: reduce) {
	.sqa * {
		transition: none !important;
	}

	.sqa .sqa-btn:hover {
		transform: none;
	}
}
