.ca-auth {
	--ca-text: #111827;
	--ca-muted: #6b7280;
	--ca-border: #e5e7eb;
	--ca-surface: #ffffff;
	--ca-background: #f8fafc;
	--ca-primary: #111827;
	--ca-primary-hover: #000000;
	--ca-danger: #b91c1c;
	--ca-success: #166534;
	--ca-radius: 14px;

	/* Space between the site header and the form. Increase if your header is fixed/sticky. */
	--ca-top-space: 80px;
	--ca-bottom-space: 64px;

	max-width: 680px;
	margin: 0 auto;
	padding: var(--ca-top-space) 20px var(--ca-bottom-space);
	box-sizing: border-box;
	color: var(--ca-text);
}

.ca-card,
.ca-profile-card {
	background: var(--ca-surface);
	border: 1px solid var(--ca-border);
	border-radius: var(--ca-radius);
	box-shadow: 0 18px 45px rgba(15, 23, 42, 0.08);
	padding: 32px;
}

.ca-card__header {
	margin-bottom: 24px;
}

.ca-card__header h2,
.ca-profile-card h2,
.ca-profile-card h3 {
	margin: 0;
	color: var(--ca-text);
}

.ca-card__header p,
.ca-profile-card__header p {
	margin: 8px 0 0;
	color: var(--ca-muted);
}

.ca-card__footer {
	margin: 20px 0 0;
	text-align: center;
	color: var(--ca-muted);
}

.ca-card a,
.ca-profile-card a {
	color: var(--ca-text);
	font-weight: 600;
}

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

.ca-form__grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 18px;
}

.ca-form__row {
	display: flex;
	align-items: center;
	gap: 12px;
}

.ca-form__row--between {
	justify-content: space-between;
}

.ca-field {
	display: flex;
	flex-direction: column;
	gap: 7px;
}

.ca-field label {
	font-size: 14px;
	font-weight: 700;
}

.ca-field input {
	width: 100%;
	box-sizing: border-box;
	padding: 12px 14px;
	border: 1px solid #d1d5db;
	border-radius: 10px;
	background: #fff;
	color: var(--ca-text);
	font-size: 16px;
	line-height: 1.4;
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.ca-field input:focus {
	outline: none;
	border-color: #6b7280;
	box-shadow: 0 0 0 3px rgba(17, 24, 39, 0.08);
}

.ca-field input[readonly] {
	background: #f3f4f6;
}

.ca-field__help,
.ca-password-hint {
	font-size: 12px;
	color: var(--ca-muted);
}

.ca-checkbox {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	font-size: 14px;
}

.ca-checkbox input {
	margin: 0;
}

.ca-button {
	width: 100%;
	border: 0;
	border-radius: 10px;
	padding: 13px 18px;
	background: var(--ca-primary);
	color: #fff;
	font-size: 15px;
	font-weight: 700;
	cursor: pointer;
	transition: background 0.15s ease, transform 0.05s ease;
}

.ca-button:hover {
	background: var(--ca-primary-hover);
}

.ca-button:active {
	transform: translateY(1px);
}

.ca-button--secondary {
	background: transparent;
	color: var(--ca-text);
	border: 1px solid var(--ca-border);
}

.ca-button--secondary:hover {
	background: #f9fafb;
}

.ca-alert {
	margin-bottom: 18px;
	padding: 12px 14px;
	border-radius: 10px;
	font-size: 14px;
	line-height: 1.45;
}

.ca-alert--success {
	background: #f0fdf4;
	border: 1px solid #bbf7d0;
	color: var(--ca-success);
}

.ca-alert--error {
	background: #fef2f2;
	border: 1px solid #fecaca;
	color: var(--ca-danger);
}

.ca-profile-card__header {
	display: flex;
	align-items: center;
	gap: 16px;
	padding-bottom: 24px;
	border-bottom: 1px solid var(--ca-border);
}

.ca-avatar {
	width: 56px;
	height: 56px;
	flex: 0 0 56px;
	display: grid;
	place-items: center;
	border-radius: 50%;
	background: #111827;
	color: #fff;
	font-weight: 800;
	font-size: 20px;
}

.ca-profile-card__section {
	padding: 28px 0;
	border-bottom: 1px solid var(--ca-border);
}

.ca-profile-card__section h3 {
	margin-bottom: 18px;
	font-size: 18px;
}

.ca-profile-card__footer {
	padding-top: 24px;
	text-align: right;
}

.ca-logout-form {
	display: inline;
}

.ca-link-button {
	padding: 0;
	border: 0;
	background: transparent;
	color: var(--ca-text);
	font: inherit;
	font-weight: 700;
	text-decoration: underline;
	cursor: pointer;
}

@media (max-width: 640px) {
	.ca-auth {
		--ca-top-space: 48px;
		--ca-bottom-space: 40px;
	}

	.ca-card,
	.ca-profile-card {
		padding: 22px;
	}

	.ca-form__grid {
		grid-template-columns: 1fr;
	}

	.ca-form__row--between {
		align-items: flex-start;
		flex-direction: column;
	}
}

.ca-badge {
	display: inline-block;
	padding: 3px 10px;
	border: 1px solid var(--ca-border);
	border-radius: 999px;
	background: #f3f4f6;
	color: var(--ca-text);
	font-size: 12px;
	font-weight: 700;
}
