* {
	box-sizing: border-box;
}

body {
	margin: 0;
	min-height: 100vh;
	display: flex;
	align-items: center;
	justify-content: center;
	font-family: "Segoe UI", Roboto, Arial, sans-serif;
	background: linear-gradient(135deg, #f1f5f9, #e5e7eb);
	color: #1f2933;
}

/* CARD */
.card {
	background: #ffffff;
	padding: 40px 35px;
	border-radius: 18px;
	width: 360px;
	text-align: center;
	box-shadow: 0 20px 45px rgba(0,0,0,.12);
}

.card img {
	max-width: 100%;
	height: auto;
	margin-bottom: 20px;
	display: block;
}

.card h1 {
	margin: 0;
	font-size: 22px;
	font-weight: 600;
	color: #111827;
}

.card p {
	margin: 8px 0 30px;
	font-size: 14px;
	color: #6b7280;
}

/* ERROR */
.error {
	color: #dc2626;
	font-size: 14px;
	margin-bottom: 15px;
}

/* PIN INPUT */
.pin-input {
	width: 100%;
	padding: 14px;
	font-size: 32px;
	letter-spacing: 14px;
	text-align: center;
	border-radius: 12px;
	border: 1px solid #d1d5db;
	background: #f9fafb;
	color: #111827;
	outline: none;
	margin-bottom: 30px;
}

.pin-input:focus {
	border-color: #22c55e;
	box-shadow: 0 0 0 3px rgba(34,197,94,.2);
}

/* KEYPAD */
.keypad {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 14px;
}

.keypad button {
	height: 64px;
	border-radius: 14px;
	border: none;
	font-size: 22px;
	cursor: pointer;
	background: #e5e7eb;
	color: #111827;
	transition: all .15s ease;
}

.keypad button:hover {
	background: #d1d5db;
	transform: translateY(-1px);
}

.keypad button:active {
	transform: scale(.96);
}

/* ACTIONS */
.keypad button.action {
	background: #cbd5e1;
}

.keypad button.ok {
	background: #22c55e;
	color: #ffffff;
}

.keypad button.ok:hover {
	background: #16a34a;
}

/* FOOTER */
.footer {
	margin-top: 25px;
	font-size: 11px;
	color: #9ca3af;
}

/* LOADER */
.loader-overlay {
	position: fixed;
	inset: 0;
	background: rgba(243, 244, 246, .85);
	display: none;
	align-items: center;
	justify-content: center;
	z-index: 999;
}

.loader-overlay.active {
	display: flex;
}

.loader-card {
	background: #ffffff;
	padding: 30px 40px;
	border-radius: 16px;
	text-align: center;
	box-shadow: 0 20px 45px rgba(0,0,0,.15);
}

.loader-card p {
	margin-top: 15px;
	font-size: 14px;
	color: #6b7280;
}

.spinner {
	width: 48px;
	height: 48px;
	border: 4px solid #e5e7eb;
	border-top-color: #22c55e;
	border-radius: 50%;
	animation: spin 1s linear infinite;
}

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