/* ================= JUGMUG Payroll — Login =================
   Light page, one centered card: animated payslip preview (left) + sign-in form (right).
   Effects use transform / opacity only, no canvas, no blur filters: the page stays fast. */
:root {
	--ink: #111827; --text: #374151; --muted: #6b7280; --faint: #9ca3af;
	--line: #e5e7eb; --soft: #f5f7fb;
	--navy: #172036; --navy-2: #243150; --steel: #404E67;
	--red: #e3342f; --red-2: #f2594b; --green: #16a34a; --gold: #f5b544;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body {
	min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px;
	padding: 24px 16px; overflow-x: hidden;
	font-family: 'Plus Jakarta Sans', 'Segoe UI', Arial, sans-serif; color: var(--text);
	background:
		linear-gradient(rgba(64,78,103,.05) 1px, transparent 1px) 0 0 / 40px 40px,
		linear-gradient(90deg, rgba(64,78,103,.05) 1px, transparent 1px) 0 0 / 40px 40px,
		#eef1f6;
	-webkit-font-smoothing: antialiased;
}
.blob { position: fixed; z-index: 0; border-radius: 50%; pointer-events: none; will-change: transform; }
.blob.b1 { width: 520px; height: 520px; left: -180px; top: -200px; background: radial-gradient(circle, rgba(227,52,47,.14), transparent 68%); animation: drift1 20s ease-in-out infinite alternate; }
.blob.b2 { width: 560px; height: 560px; right: -200px; bottom: -220px; background: radial-gradient(circle, rgba(64,78,103,.22), transparent 68%); animation: drift2 24s ease-in-out infinite alternate; }
@keyframes drift1 { to { transform: translate(120px, 90px); } }
@keyframes drift2 { to { transform: translate(-110px, -80px); } }

/* ---------- Card ---------- */
.card {
	position: relative; z-index: 1; display: grid; grid-template-columns: 1.05fr 1fr;
	width: 100%; max-width: 940px; min-height: 560px; overflow: hidden;
	background: #fff; border-radius: 26px;
	box-shadow: 0 40px 90px -35px rgba(17,24,39,.45), 0 0 0 1px rgba(17,24,39,.04);
	animation: cardIn .5s cubic-bezier(.2,.9,.3,1.12) both;
}
@keyframes cardIn { from { opacity: 0; transform: translateY(20px) scale(.98); } to { opacity: 1; transform: none; } }

/* ================= Left: payroll showcase ================= */
.show {
	position: relative; overflow: hidden; padding: 34px 34px 28px; color: #e5e9f2;
	background:
		radial-gradient(420px 320px at 85% 10%, rgba(227,52,47,.35), transparent 60%),
		radial-gradient(380px 300px at 0% 100%, rgba(93,109,140,.45), transparent 60%),
		linear-gradient(160deg, var(--navy-2), var(--navy));
	display: flex; flex-direction: column;
}
.show::before { /* slow light sweep */
	content: ''; position: absolute; top: -50%; left: -60%; width: 60%; height: 200%;
	background: linear-gradient(100deg, transparent, rgba(255,255,255,.06), transparent); transform: rotate(12deg);
	animation: sweep 7s ease-in-out 1s infinite;
}
@keyframes sweep { 0%, 60% { left: -60%; } 100% { left: 130%; } }
.show-tag { display: inline-flex; align-self: flex-start; align-items: center; gap: 7px; padding: 5px 11px; border-radius: 999px; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.12); font-size: 11.5px; font-weight: 700; letter-spacing: .5px; color: #fff; }
.show-tag .live { width: 7px; height: 7px; border-radius: 50%; background: #4ade80; box-shadow: 0 0 0 0 rgba(74,222,128,.6); animation: ping 2s infinite; }
@keyframes ping { 70% { box-shadow: 0 0 0 7px rgba(74,222,128,0); } 100% { box-shadow: 0 0 0 0 rgba(74,222,128,0); } }
.show h2 { margin: 16px 0 8px; font-size: 30px; line-height: 1.15; font-weight: 800; letter-spacing: -.6px; color: #fff; }
.show h2 span { color: var(--red-2); }
.show p.lead { font-size: 13.5px; line-height: 1.6; color: #b4bdd0; max-width: 360px; }

/* Payslip preview */
.slip-zone { position: relative; flex: 1; display: flex; align-items: center; justify-content: flex-end; margin-top: 14px; min-height: 330px; padding: 34px 10px 48px 0; }
.slip {
	position: relative; width: 272px; padding: 16px 16px 14px; border-radius: 18px; color: var(--ink);
	background: #fff; box-shadow: 0 30px 50px -20px rgba(0,0,0,.6);
	transform: rotate(-3deg); animation: slipIn .7s cubic-bezier(.2,.9,.3,1.2) .35s both, bob 6s ease-in-out 1.2s infinite;
}
@keyframes slipIn { from { opacity: 0; transform: translateY(30px) rotate(-8deg) scale(.92); } to { opacity: 1; transform: rotate(-3deg); } }
@keyframes bob { 0%, 100% { transform: rotate(-3deg) translateY(0); } 50% { transform: rotate(-2deg) translateY(-8px); } }
.slip-head { display: flex; align-items: center; justify-content: space-between; padding-bottom: 10px; border-bottom: 1px dashed #e5e7eb; }
.slip-head b { font-size: 13px; font-weight: 800; color: var(--ink); }
.slip-head small { font-size: 11px; font-weight: 600; color: var(--muted); }
.emp { display: flex; align-items: center; gap: 10px; margin: 11px 0 9px; }
.emp .av { width: 34px; height: 34px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 800; color: #fff; background: linear-gradient(135deg, var(--steel), #6b5b95); }
.emp b { display: block; font-size: 12.5px; font-weight: 700; color: var(--ink); }
.emp small { font-size: 11px; color: var(--muted); }
.ln { display: flex; justify-content: space-between; padding: 4px 0; font-size: 12px; color: var(--text); opacity: 0; animation: lnIn .4s ease forwards; animation-delay: calc(.9s + var(--i) * .12s); }
.ln em { font-style: normal; font-weight: 700; color: var(--ink); font-variant-numeric: tabular-nums; }
.ln.minus em { color: var(--red); }
@keyframes lnIn { from { opacity: 0; transform: translateX(-8px); } to { opacity: 1; transform: none; } }
.net { display: flex; align-items: center; justify-content: space-between; margin-top: 9px; padding: 10px 12px; border-radius: 12px; background: #f0fdf4; border: 1px solid #dcfce7; }
.net small { font-size: 11px; font-weight: 700; letter-spacing: .4px; text-transform: uppercase; color: #15803d; }
.net b { font-size: 19px; font-weight: 800; color: #14532d; font-variant-numeric: tabular-nums; }
.stamp {
	position: absolute; right: -14px; top: 58px; padding: 5px 10px; border-radius: 8px; border: 2px solid var(--green);
	font-size: 11px; font-weight: 800; letter-spacing: 1px; color: var(--green); background: #fff;
	transform: rotate(12deg) scale(0); animation: stamp .35s cubic-bezier(.3,1.6,.5,1) 2.3s forwards;
}
@keyframes stamp { to { transform: rotate(12deg) scale(1); } }

/* Attendance mini chart (behind the slip) */
.att {
	position: absolute; left: 0; top: 44px; width: 118px; padding: 12px 12px 10px; border-radius: 14px;
	background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.12);
	opacity: 0; animation: fadeUp .6s ease .6s forwards;
}
.att small { display: block; margin-bottom: 8px; font-size: 10.5px; font-weight: 700; letter-spacing: .4px; color: #c7cfdf; }
.bars { display: flex; align-items: flex-end; gap: 7px; height: 54px; }
.bars i { flex: 1; border-radius: 4px 4px 2px 2px; background: linear-gradient(#4ade80, #16a34a); transform-origin: bottom; transform: scaleY(0); animation: grow .7s cubic-bezier(.2,.9,.3,1.2) forwards; animation-delay: calc(1s + var(--i) * .08s); }
.bars i.lo { background: linear-gradient(#fca5a5, #ef4444); }
@keyframes grow { to { transform: scaleY(1); } }
.days { display: flex; gap: 7px; margin-top: 5px; }
.days span { flex: 1; text-align: center; font-size: 9px; color: #8e99b3; }

/* Floating chips */
.fchip {
	position: absolute; display: inline-flex; align-items: center; gap: 7px; padding: 7px 11px; border-radius: 12px;
	background: #fff; color: var(--ink); font-size: 11.5px; font-weight: 700; box-shadow: 0 14px 28px -12px rgba(0,0,0,.55);
	opacity: 0; animation: fadeUp .5s ease forwards, float 5s ease-in-out infinite;
}
.fchip i { width: 22px; height: 22px; border-radius: 7px; display: flex; align-items: center; justify-content: center; font-style: normal; font-size: 12px; color: #fff; }
.fchip.c1 { left: 0; bottom: 0; animation-delay: 1.6s, 2.1s; }
.fchip.c1 i { background: var(--green); }
.fchip.c2 { right: 0; top: 0; animation-delay: 1.9s, 2.4s; }
.fchip.c2 i { background: var(--red); }
@keyframes fadeUp { from { opacity: 0; translate: 0 10px; } to { opacity: 1; translate: 0 0; } }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }

.perks { display: flex; flex-wrap: wrap; gap: 8px 16px; margin-top: 16px; font-size: 12px; font-weight: 600; color: #c7cfdf; }
.perks span { display: inline-flex; align-items: center; gap: 6px; }
.perks svg { width: 14px; height: 14px; fill: none; stroke: #4ade80; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }

/* ================= Right: sign-in ================= */
.auth { display: flex; flex-direction: column; justify-content: center; padding: 38px 40px 26px; }
.logo { display: block; width: 190px; height: auto; margin-bottom: 26px; }
.auth h1 { font-size: 26px; font-weight: 800; letter-spacing: -.5px; color: var(--ink); }
.auth h1 .wave { display: inline-block; transform-origin: 70% 70%; animation: wave 2.2s ease-in-out .6s 2; }
@keyframes wave { 0%, 60%, 100% { transform: rotate(0); } 10%, 30% { transform: rotate(14deg); } 20%, 40% { transform: rotate(-8deg); } }
.auth .sub { margin: 6px 0 22px; font-size: 13.5px; line-height: 1.55; color: var(--muted); }

.alert { display: flex; align-items: flex-start; gap: 9px; margin-bottom: 16px; padding: 10px 12px; border-radius: 12px; font-size: 13px; line-height: 1.45; }
.alert svg { flex: none; width: 17px; height: 17px; margin-top: 1px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.alert.error { color: #b42318; background: #fef2f2; border: 1px solid #fecaca; animation: shake .45s ease .4s both; }
.alert.info  { color: #1e3a8a; background: #eff6ff; border: 1px solid #dbeafe; }
@keyframes shake { 20%, 60% { transform: translateX(-5px); } 40%, 80% { transform: translateX(5px); } }

.field { margin-bottom: 15px; }
.field label { display: flex; justify-content: space-between; margin: 0 0 7px 2px; font-size: 12.5px; font-weight: 700; color: var(--text); }
.input { position: relative; }
.input input {
	width: 100%; height: 50px; padding: 0 46px 0 44px; border-radius: 13px; outline: none;
	font: 600 14.5px 'Plus Jakarta Sans', 'Segoe UI', Arial, sans-serif; color: var(--ink);
	background: var(--soft); border: 1.5px solid transparent;
	transition: border-color .15s, background .15s, box-shadow .15s;
}
.input input::placeholder { color: var(--faint); font-weight: 500; }
.input input:hover { background: #eff2f8; }
.input input:focus { background: #fff; border-color: var(--steel); box-shadow: 0 0 0 4px rgba(64,78,103,.12); }
.input .ico { position: absolute; left: 15px; top: 50%; width: 18px; height: 18px; transform: translateY(-50%); fill: none; stroke: var(--faint); stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; transition: stroke .15s; pointer-events: none; }
.input input:focus ~ .ico { stroke: var(--steel); }
.eye { position: absolute; right: 7px; top: 50%; transform: translateY(-50%); width: 36px; height: 36px; border: 0; border-radius: 10px; background: transparent; color: var(--faint); cursor: pointer; display: flex; align-items: center; justify-content: center; }
.eye:hover { color: var(--steel); background: #e9edf4; }
.eye svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.caps { display: none; align-items: center; gap: 6px; margin: -7px 0 12px 2px; font-size: 12px; font-weight: 700; color: #b45309; }
.caps.on { display: flex; }
.caps svg { width: 13px; height: 13px; fill: none; stroke: currentColor; stroke-width: 2.2; }

.options { display: flex; align-items: center; justify-content: space-between; margin: 2px 0 20px; }
.check { display: inline-flex; align-items: center; gap: 9px; font-size: 13px; font-weight: 600; color: var(--text); cursor: pointer; user-select: none; }
.check input { position: absolute; opacity: 0; width: 0; height: 0; }
.check .box { width: 18px; height: 18px; border-radius: 6px; border: 1.5px solid #cbd2dd; background: #fff; display: flex; align-items: center; justify-content: center; transition: all .15s; }
.check .box svg { width: 11px; height: 11px; fill: none; stroke: #fff; stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; opacity: 0; }
.check input:checked + .box { background: var(--steel); border-color: var(--steel); }
.check input:checked + .box svg { opacity: 1; }
.check input:focus-visible + .box { box-shadow: 0 0 0 3px rgba(64,78,103,.3); }
.today { font-size: 12px; font-weight: 600; color: var(--faint); font-variant-numeric: tabular-nums; }

.btn {
	position: relative; overflow: hidden; width: 100%; height: 52px; border: 0; border-radius: 14px; cursor: pointer;
	display: flex; align-items: center; justify-content: center; gap: 9px;
	font: 700 15px 'Plus Jakarta Sans', 'Segoe UI', Arial, sans-serif; color: #fff;
	background: linear-gradient(135deg, var(--red), var(--red-2));
	box-shadow: 0 14px 26px -12px rgba(227,52,47,.75);
	transition: transform .12s ease, box-shadow .18s ease;
}
.btn:hover { transform: translateY(-1px); box-shadow: 0 18px 30px -12px rgba(227,52,47,.85); }
.btn:active { transform: translateY(1px) scale(.99); }
.btn:focus-visible { outline: 3px solid rgba(227,52,47,.35); outline-offset: 2px; }
.btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2.3; stroke-linecap: round; stroke-linejoin: round; transition: transform .2s; }
.btn:hover svg { transform: translateX(3px); }
.btn::before { content: ''; position: absolute; top: 0; left: -60%; width: 40%; height: 100%; background: linear-gradient(100deg, transparent, rgba(255,255,255,.35), transparent); transform: skewX(-20deg); animation: gleam 4s ease-in-out 2s infinite; }
@keyframes gleam { 0%, 70% { left: -60%; } 100% { left: 140%; } }
.btn .spin { display: none; width: 17px; height: 17px; border-radius: 50%; border: 2.5px solid rgba(255,255,255,.4); border-top-color: #fff; animation: rot .7s linear infinite; }
@keyframes rot { to { transform: rotate(360deg); } }
.btn.busy { pointer-events: none; opacity: .92; }
.btn.busy svg { display: none; }
.btn.busy .spin { display: inline-block; }

.secure { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 18px; font-size: 12px; font-weight: 600; color: var(--muted); }
.secure svg { width: 14px; height: 14px; fill: none; stroke: var(--green); stroke-width: 2; }

.foot { position: relative; z-index: 1; font-size: 12px; color: var(--muted); }

/* ---------- Responsive ---------- */
@media (max-width: 880px) {
	.card { grid-template-columns: 1fr; max-width: 460px; min-height: 0; }
	.show { padding: 22px 24px; }
	.show h2 { font-size: 22px; margin: 12px 0 4px; }
	.show p.lead, .slip-zone, .perks { display: none; }
	.auth { padding: 28px 24px 22px; }
	.logo { width: 170px; margin-bottom: 20px; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .001ms !important; animation-delay: 0s !important; animation-iteration-count: 1 !important; transition: none !important; } }
