/* =========================================================================
   PrintDeed HRMS — Enterprise Theme (ADR-0009)
   New shell + new pages use this. Legacy pages remain on base.css.
   ========================================================================= */

:root {
	/* Palette */
	--pd-primary: #0B2942;
	--pd-primary-soft: #13355A;
	--pd-primary-2: #1B4068;

	--pd-accent: #14B8A6;
	--pd-accent-soft: #CCFBF1;
	--pd-accent-dark: #0F9488;

	--pd-bg: #F8FAFC;
	--pd-surface: #FFFFFF;
	--pd-surface-2: #F1F5F9;
	--pd-border: #DCE7E5;
	--pd-border-strong: #B6CCC8;

	--pd-text: #0B2942;
	--pd-text-muted: #64748B;
	--pd-text-light: #94A3B8;

	--pd-success: #16A34A;
	--pd-success-soft: #DCFCE7;
	--pd-warning: #F59E0B;
	--pd-warning-soft: #FEF3C7;
	--pd-danger: #DC2626;
	--pd-danger-soft: #FEE2E2;
	--pd-info: #0891B2;
	--pd-info-soft: #CFFAFE;

	/* Shape & shadow */
	--pd-radius-sm: 8px;
	--pd-radius: 12px;
	--pd-radius-lg: 16px;
	--pd-radius-xl: 24px;

	--pd-shadow-sm: 0 1px 2px rgba(11, 41, 66, .04);
	--pd-shadow-md: 0 6px 24px rgba(11, 41, 66, .06);
	--pd-shadow-lg: 0 20px 50px rgba(11, 41, 66, .10);
	--pd-glass: rgba(255, 255, 255, .72);

	/* Layout */
	--pd-sidebar-w: 248px;
	--pd-topbar-h: 64px;
}

/* ---------- Base reset ---------- */
.pd-app * { box-sizing: border-box; }
.pd-app {
	margin: 0;
	font-family: 'Inter', 'Space Grotesk', 'Segoe UI', sans-serif;
	color: var(--pd-text);
	background: var(--pd-bg);
	min-height: 100vh;
	-webkit-font-smoothing: antialiased;
}
.pd-app a { color: inherit; text-decoration: none; }
.pd-app h1, .pd-app h2, .pd-app h3, .pd-app h4 {
	color: var(--pd-primary);
	margin: 0;
	font-weight: 600;
	letter-spacing: -0.01em;
}
.pd-app h1 { font-size: 28px; line-height: 1.2; }
.pd-app h2 { font-size: 20px; }
.pd-app h3 { font-size: 16px; }
.pd-app p  { margin: 0; color: var(--pd-text-muted); font-size: 14px; line-height: 1.5; }
.pd-app button { font-family: inherit; }

/* ---------- Shell layout ---------- */
.pd-shell {
	display: grid;
	grid-template-columns: var(--pd-sidebar-w) 1fr;
	min-height: 100vh;
}

/* Sidebar */
.pd-sidebar {
	background: var(--pd-primary);
	color: #E2E8F0;
	padding: 20px 16px;
	position: sticky;
	top: 0;
	height: 100vh;
	overflow-y: auto;
	display: flex;
	flex-direction: column;
	gap: 8px;
	border-right: 1px solid rgba(255,255,255,.04);
}
.pd-sidebar::-webkit-scrollbar { width: 6px; }
.pd-sidebar::-webkit-scrollbar-thumb { background: rgba(255,255,255,.1); border-radius: 4px; }

.pd-brand {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 8px 8px 20px;
	border-bottom: 1px solid rgba(255,255,255,.06);
	margin-bottom: 8px;
}
.pd-brand-mark {
	width: 38px; height: 38px;
	border-radius: 10px;
	background: linear-gradient(135deg, var(--pd-accent) 0%, var(--pd-accent-dark) 100%);
	color: #fff;
	display: grid;
	place-items: center;
	font-weight: 700;
	letter-spacing: -0.02em;
	box-shadow: 0 4px 12px rgba(20,184,166,.3);
}
.pd-brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.pd-brand-title { color: #fff; font-weight: 700; font-size: 15px; letter-spacing: .2px; }
.pd-brand-sub   { color: #94A3B8; font-size: 11px; text-transform: uppercase; letter-spacing: 1px; margin-top: 2px; }

.pd-nav-section { display: flex; flex-direction: column; gap: 2px; padding: 8px 0; }
.pd-nav-label {
	font-size: 10px;
	text-transform: uppercase;
	letter-spacing: 1.4px;
	color: #64748B;
	font-weight: 600;
	padding: 6px 12px;
}
.pd-nav-item {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 9px 12px;
	border-radius: 8px;
	color: #CBD5E1;
	font-size: 14px;
	font-weight: 500;
	transition: all .15s ease;
	cursor: pointer;
}
.pd-nav-item:hover {
	background: rgba(255,255,255,.05);
	color: #fff;
}
.pd-nav-item.active {
	background: linear-gradient(90deg, rgba(20,184,166,.18), rgba(20,184,166,0));
	color: #fff;
	box-shadow: inset 3px 0 0 var(--pd-accent);
}
.pd-nav-icon { width: 18px; height: 18px; flex-shrink: 0; opacity: .9; }
.pd-nav-item.active .pd-nav-icon { color: var(--pd-accent); }

/* Topbar */
.pd-main { display: flex; flex-direction: column; min-width: 0; }
.pd-topbar {
	height: var(--pd-topbar-h);
	background: var(--pd-surface);
	border-bottom: 1px solid var(--pd-border);
	display: flex;
	align-items: center;
	gap: 16px;
	padding: 0 28px;
	position: sticky;
	top: 0;
	z-index: 20;
	backdrop-filter: blur(8px);
}
.pd-topbar-search {
	flex: 1;
	max-width: 480px;
	position: relative;
}
.pd-topbar-search input {
	width: 100%;
	border: 1px solid var(--pd-border);
	background: var(--pd-surface-2);
	border-radius: 10px;
	padding: 9px 14px 9px 38px;
	font-size: 13px;
	color: var(--pd-text);
	outline: none;
	transition: all .15s ease;
}
.pd-topbar-search input:focus {
	border-color: var(--pd-accent);
	background: #fff;
	box-shadow: 0 0 0 3px var(--pd-accent-soft);
}
.pd-topbar-search-icon {
	position: absolute; left: 12px; top: 50%; transform: translateY(-50%);
	color: var(--pd-text-light); pointer-events: none;
}

.pd-topbar-actions { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.pd-icon-btn {
	width: 38px; height: 38px;
	border-radius: 10px;
	border: 1px solid transparent;
	background: transparent;
	color: var(--pd-text-muted);
	cursor: pointer;
	display: grid;
	place-items: center;
	position: relative;
	transition: all .15s ease;
}
.pd-icon-btn:hover { background: var(--pd-surface-2); color: var(--pd-primary); }
.pd-icon-btn .pd-badge-dot {
	position: absolute; top: 8px; right: 9px;
	width: 8px; height: 8px; border-radius: 50%;
	background: var(--pd-danger);
	border: 2px solid var(--pd-surface);
}

.pd-avatar-menu {
	display: flex; align-items: center; gap: 10px;
	padding: 4px 10px 4px 4px;
	border-radius: 999px;
	border: 1px solid var(--pd-border);
	cursor: pointer;
	transition: all .15s ease;
}
.pd-avatar-menu:hover { background: var(--pd-surface-2); }
.pd-avatar {
	width: 32px; height: 32px;
	border-radius: 50%;
	background: linear-gradient(135deg, var(--pd-accent) 0%, var(--pd-primary) 100%);
	color: #fff;
	display: grid;
	place-items: center;
	font-weight: 600;
	font-size: 13px;
}
.pd-avatar-name { font-size: 13px; font-weight: 600; color: var(--pd-text); line-height: 1.1; }
.pd-avatar-role { font-size: 11px; color: var(--pd-text-muted); line-height: 1.2; }
.pd-avatar-text { display: flex; flex-direction: column; }

/* Content area */
.pd-content {
	padding: 28px;
	flex: 1;
	min-width: 0;
}
.pd-page-head {
	display: flex;
	justify-content: space-between;
	align-items: flex-end;
	margin-bottom: 24px;
	flex-wrap: wrap;
	gap: 16px;
}
.pd-kicker {
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 1.6px;
	text-transform: uppercase;
	color: var(--pd-accent-dark);
	margin-bottom: 6px;
}
.pd-page-title { font-size: 26px; }
.pd-page-sub   { margin-top: 6px; color: var(--pd-text-muted); }

/* Cards */
.pd-card {
	background: var(--pd-surface);
	border: 1px solid var(--pd-border);
	border-radius: var(--pd-radius-lg);
	padding: 20px;
	box-shadow: var(--pd-shadow-sm);
	transition: box-shadow .2s ease, transform .2s ease;
}
.pd-card.is-hero {
	background: linear-gradient(135deg, var(--pd-primary) 0%, var(--pd-primary-2) 100%);
	color: #fff;
	border: none;
	padding: 28px;
	position: relative;
	overflow: hidden;
}
.pd-card.is-hero::after {
	content: '';
	position: absolute;
	right: -60px; top: -60px;
	width: 220px; height: 220px;
	background: radial-gradient(circle, rgba(20,184,166,.25), transparent 70%);
}
.pd-card.is-hero h1, .pd-card.is-hero h2, .pd-card.is-hero h3 { color: #fff; }
.pd-card.is-hero p { color: rgba(226,232,240,.85); }
.pd-card.is-hero .pd-kicker { color: var(--pd-accent); }
.pd-card.is-glass {
	background: rgba(255,255,255,.7);
	backdrop-filter: blur(12px);
	border: 1px solid rgba(255,255,255,.6);
}
.pd-card:hover { box-shadow: var(--pd-shadow-md); }

.pd-card-head { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 16px; gap: 12px; }
.pd-card-head h2, .pd-card-head h3 { margin-bottom: 4px; }

/* KPI cards */
.pd-kpi-grid {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 16px;
	margin-bottom: 24px;
}
.pd-kpi {
	background: var(--pd-surface);
	border: 1px solid var(--pd-border);
	border-radius: var(--pd-radius-lg);
	padding: 18px 20px;
	display: flex;
	flex-direction: column;
	gap: 10px;
	position: relative;
	overflow: hidden;
	transition: all .2s ease;
}
.pd-kpi:hover { transform: translateY(-2px); box-shadow: var(--pd-shadow-md); }
.pd-kpi-head { display: flex; justify-content: space-between; align-items: center; }
.pd-kpi-label { font-size: 12px; color: var(--pd-text-muted); font-weight: 500; }
.pd-kpi-icon {
	width: 36px; height: 36px;
	border-radius: 10px;
	display: grid; place-items: center;
	background: var(--pd-accent-soft);
	color: var(--pd-accent-dark);
}
.pd-kpi-icon.is-success { background: var(--pd-success-soft); color: var(--pd-success); }
.pd-kpi-icon.is-warning { background: var(--pd-warning-soft); color: var(--pd-warning); }
.pd-kpi-icon.is-danger  { background: var(--pd-danger-soft); color: var(--pd-danger); }
.pd-kpi-icon.is-info    { background: var(--pd-info-soft); color: var(--pd-info); }
.pd-kpi-value { font-size: 28px; font-weight: 700; color: var(--pd-primary); letter-spacing: -0.02em; line-height: 1; }
.pd-kpi-meta { font-size: 12px; color: var(--pd-text-muted); }
.pd-kpi-meta .up { color: var(--pd-success); font-weight: 600; }
.pd-kpi-meta .down { color: var(--pd-danger); font-weight: 600; }

/* Grids */
.pd-grid { display: grid; gap: 16px; }
.pd-grid-2  { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.pd-grid-3  { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.pd-grid-23 { grid-template-columns: 2fr 1fr; }
.pd-grid-32 { grid-template-columns: 1fr 2fr; }

/* Chips & badges */
.pd-chip {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 4px 10px;
	border-radius: 999px;
	font-size: 12px;
	font-weight: 500;
	background: var(--pd-surface-2);
	color: var(--pd-text-muted);
	border: 1px solid var(--pd-border);
}
.pd-chip.is-success { background: var(--pd-success-soft); color: var(--pd-success); border-color: transparent; }
.pd-chip.is-warning { background: var(--pd-warning-soft); color: #B45309; border-color: transparent; }
.pd-chip.is-danger  { background: var(--pd-danger-soft);  color: var(--pd-danger);  border-color: transparent; }
.pd-chip.is-info    { background: var(--pd-info-soft);    color: var(--pd-info);    border-color: transparent; }
.pd-chip.is-accent  { background: var(--pd-accent-soft);  color: var(--pd-accent-dark); border-color: transparent; }
.pd-chip.is-primary { background: var(--pd-primary); color: #fff; border-color: transparent; }

.pd-status-dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.pd-status-dot.is-online  { background: var(--pd-success); box-shadow: 0 0 0 3px var(--pd-success-soft); }
.pd-status-dot.is-warning { background: var(--pd-warning); }
.pd-status-dot.is-offline { background: var(--pd-text-light); }

/* Buttons */
.pd-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	padding: 9px 16px;
	border-radius: 10px;
	font-size: 13px;
	font-weight: 600;
	border: 1px solid transparent;
	cursor: pointer;
	transition: all .15s ease;
	text-decoration: none;
}
.pd-btn.is-primary {
	background: var(--pd-accent);
	color: #fff;
	box-shadow: 0 1px 2px rgba(20,184,166,.2);
}
.pd-btn.is-primary:hover { background: var(--pd-accent-dark); box-shadow: 0 4px 12px rgba(20,184,166,.3); }
.pd-btn.is-navy {
	background: var(--pd-primary);
	color: #fff;
}
.pd-btn.is-navy:hover { background: var(--pd-primary-soft); }
.pd-btn.is-ghost {
	background: transparent;
	color: var(--pd-text);
	border-color: var(--pd-border);
}
.pd-btn.is-ghost:hover { background: var(--pd-surface-2); border-color: var(--pd-border-strong); }
.pd-btn.is-danger { background: var(--pd-danger); color: #fff; }
.pd-btn.is-lg { padding: 12px 22px; font-size: 14px; }
.pd-btn.is-sm { padding: 6px 12px; font-size: 12px; }
.pd-btn.is-block { width: 100%; }

/* Forms */
.pd-field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.pd-label { font-size: 12px; font-weight: 600; color: var(--pd-text); }
.pd-input, .pd-select, .pd-textarea {
	width: 100%;
	padding: 10px 14px;
	border: 1px solid var(--pd-border);
	border-radius: 10px;
	background: var(--pd-surface);
	color: var(--pd-text);
	font-size: 14px;
	font-family: inherit;
	outline: none;
	transition: all .15s ease;
}
.pd-input:focus, .pd-select:focus, .pd-textarea:focus {
	border-color: var(--pd-accent);
	box-shadow: 0 0 0 3px var(--pd-accent-soft);
}
.pd-textarea { min-height: 96px; resize: vertical; }

/* Tables */
.pd-table-wrap { background: var(--pd-surface); border: 1px solid var(--pd-border); border-radius: var(--pd-radius-lg); overflow: hidden; }
.pd-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.pd-table thead th {
	background: var(--pd-surface-2);
	color: var(--pd-text-muted);
	font-weight: 600;
	font-size: 11px;
	text-transform: uppercase;
	letter-spacing: .5px;
	padding: 14px 16px;
	text-align: left;
	border-bottom: 1px solid var(--pd-border);
}
.pd-table tbody td { padding: 14px 16px; border-bottom: 1px solid var(--pd-border); color: var(--pd-text); vertical-align: middle; }
.pd-table tbody tr:hover { background: var(--pd-surface-2); }
.pd-table tbody tr:last-child td { border-bottom: 0; }

/* Filter strip */
.pd-filter-strip {
	display: flex; gap: 10px; flex-wrap: wrap; align-items: center;
	padding: 14px 18px;
	background: var(--pd-surface); border: 1px solid var(--pd-border);
	border-radius: var(--pd-radius-lg);
	margin-bottom: 16px;
}

/* Avatar in lists */
.pd-emp {
	display: flex; align-items: center; gap: 10px;
}
.pd-emp-avatar {
	width: 32px; height: 32px;
	border-radius: 50%;
	background: linear-gradient(135deg, var(--pd-accent-soft), var(--pd-accent));
	color: var(--pd-primary);
	display: grid; place-items: center;
	font-weight: 600;
	font-size: 12px;
}
.pd-emp-name { font-weight: 500; font-size: 13px; color: var(--pd-text); }
.pd-emp-code { font-size: 11px; color: var(--pd-text-muted); }

/* Activity list */
.pd-activity { display: flex; flex-direction: column; gap: 4px; }
.pd-activity-item {
	display: flex; gap: 12px; align-items: flex-start;
	padding: 10px 0;
	border-bottom: 1px dashed var(--pd-border);
}
.pd-activity-item:last-child { border-bottom: 0; }
.pd-activity-dot {
	width: 8px; height: 8px; margin-top: 6px; flex-shrink: 0;
	border-radius: 50%;
	background: var(--pd-accent);
}
.pd-activity-text { flex: 1; }
.pd-activity-title { font-size: 13px; color: var(--pd-text); font-weight: 500; }
.pd-activity-meta  { font-size: 12px; color: var(--pd-text-muted); margin-top: 2px; }

/* Tabs */
.pd-tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--pd-border); margin-bottom: 20px; }
.pd-tab {
	padding: 10px 16px;
	font-size: 13px;
	font-weight: 500;
	color: var(--pd-text-muted);
	border-bottom: 2px solid transparent;
	cursor: pointer;
	transition: all .15s ease;
}
.pd-tab:hover { color: var(--pd-primary); }
.pd-tab.active { color: var(--pd-primary); border-bottom-color: var(--pd-accent); font-weight: 600; }

/* Login (split-screen) */
.pd-login {
	min-height: 100vh;
	display: grid;
	grid-template-columns: 1.1fr .9fr;
	background: var(--pd-bg);
}
.pd-login-hero {
	background: linear-gradient(135deg, var(--pd-primary) 0%, #051A2E 100%);
	color: #fff;
	padding: 56px 56px 40px;
	display: flex;
	flex-direction: column;
	justify-content: space-between;
	position: relative;
	overflow: hidden;
}
.pd-login-hero::before {
	content: '';
	position: absolute;
	top: -120px; right: -120px;
	width: 400px; height: 400px;
	background: radial-gradient(circle, rgba(20,184,166,.25), transparent 70%);
}
.pd-login-hero::after {
	content: '';
	position: absolute;
	bottom: -200px; left: -200px;
	width: 500px; height: 500px;
	background: radial-gradient(circle, rgba(20,184,166,.12), transparent 70%);
}
.pd-login-hero > * { position: relative; z-index: 1; }
.pd-login-hero h1 { color: #fff; font-size: 40px; line-height: 1.15; letter-spacing: -0.02em; margin-bottom: 16px; }
.pd-login-hero .pd-kicker { color: var(--pd-accent); }
.pd-login-hero p { color: rgba(226,232,240,.8); font-size: 16px; max-width: 460px; }
.pd-login-features { display: flex; flex-direction: column; gap: 14px; margin-top: 36px; }
.pd-login-feature {
	display: flex; gap: 12px; align-items: center;
	color: rgba(226,232,240,.92); font-size: 14px;
}
.pd-login-feature .check {
	width: 22px; height: 22px;
	border-radius: 50%;
	background: rgba(20,184,166,.15);
	border: 1px solid var(--pd-accent);
	color: var(--pd-accent);
	display: grid; place-items: center;
	font-size: 12px;
}

.pd-login-form-wrap {
	display: grid;
	place-items: center;
	padding: 40px;
}
.pd-login-card {
	width: 100%;
	max-width: 420px;
	background: var(--pd-surface);
	border: 1px solid var(--pd-border);
	border-radius: 18px;
	padding: 36px;
	box-shadow: var(--pd-shadow-lg);
}
.pd-login-card h2 { font-size: 24px; margin-bottom: 4px; }
.pd-login-card .pd-card-sub { color: var(--pd-text-muted); font-size: 14px; margin-bottom: 26px; }
.pd-login-meta {
	display: flex; justify-content: space-between; align-items: center;
	font-size: 12px; color: var(--pd-text-muted);
	margin: -6px 0 18px;
}
.pd-login-meta a { color: var(--pd-accent-dark); font-weight: 600; }
.pd-login-error {
	background: var(--pd-danger-soft); color: var(--pd-danger);
	padding: 10px 14px; border-radius: 10px; font-size: 13px; font-weight: 500;
	margin-bottom: 16px;
}
.pd-login-footer { margin-top: 22px; padding-top: 18px; border-top: 1px dashed var(--pd-border); font-size: 12px; color: var(--pd-text-muted); text-align: center; }

/* Employee hero (check-in card) */
.pd-checkin {
	background: linear-gradient(135deg, var(--pd-primary) 0%, #0E2D4D 60%, #143A66 100%);
	color: #fff;
	border-radius: 18px;
	padding: 28px;
	position: relative;
	overflow: hidden;
	display: grid;
	grid-template-columns: 1fr auto;
	gap: 24px;
	align-items: center;
}
.pd-checkin::before {
	content: '';
	position: absolute;
	inset: 0;
	background: radial-gradient(circle at top right, rgba(20,184,166,.25), transparent 60%);
	pointer-events: none;
}
.pd-checkin > * { position: relative; z-index: 1; }
.pd-checkin .pd-kicker { color: var(--pd-accent); }
.pd-checkin h1 { color: #fff; font-size: 28px; margin-bottom: 8px; }
.pd-checkin p  { color: rgba(226,232,240,.8); font-size: 14px; }
.pd-checkin-stats { display: flex; gap: 24px; margin-top: 18px; }
.pd-checkin-stat { display: flex; flex-direction: column; gap: 2px; }
.pd-checkin-stat-label { font-size: 11px; text-transform: uppercase; letter-spacing: 1px; color: rgba(226,232,240,.6); }
.pd-checkin-stat-value { font-size: 18px; font-weight: 600; color: #fff; }
.pd-checkin-cta {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 14px;
	background: rgba(255,255,255,.08);
	padding: 22px;
	border-radius: 16px;
	border: 1px solid rgba(255,255,255,.12);
	backdrop-filter: blur(8px);
}
.pd-timer {
	font-family: 'JetBrains Mono', monospace;
	font-size: 30px;
	font-weight: 700;
	color: var(--pd-accent);
	letter-spacing: 1px;
}

/* Calendar */
.pd-cal {
	background: var(--pd-surface);
	border: 1px solid var(--pd-border);
	border-radius: var(--pd-radius-lg);
	padding: 20px;
}
.pd-cal-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; flex-wrap: wrap; gap: 12px; }
.pd-cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.pd-cal-day-head { font-size: 11px; text-align: center; color: var(--pd-text-muted); padding: 6px 0; font-weight: 600; text-transform: uppercase; letter-spacing: .5px; }
.pd-cal-cell {
	aspect-ratio: 1 / 1;
	border-radius: 10px;
	border: 1px solid var(--pd-border);
	padding: 6px;
	display: flex;
	flex-direction: column;
	justify-content: space-between;
	font-size: 12px;
	background: var(--pd-surface);
	cursor: pointer;
	transition: all .15s ease;
	min-height: 64px;
}
.pd-cal-cell:hover { border-color: var(--pd-accent); }
.pd-cal-cell.is-muted { background: var(--pd-surface-2); color: var(--pd-text-light); border-color: transparent; cursor: default; }
.pd-cal-cell.is-today { border-color: var(--pd-accent); box-shadow: 0 0 0 2px var(--pd-accent-soft); }
/* Status-driven calendar cells — class names match attendance/service.py _cal_css() output */
.pd-cal-cell { position: relative; }
.pd-cal-cell.pd-cal-present  { background: var(--pd-success-soft); border-color: transparent; }
.pd-cal-cell.pd-cal-absent   { background: var(--pd-danger-soft);  border-color: transparent; }
.pd-cal-cell.pd-cal-late     { background: var(--pd-warning-soft); border-color: transparent; }
.pd-cal-cell.pd-cal-half     { background: #FFEDD5;                border-color: transparent; }  /* orange-100 */
.pd-cal-cell.pd-cal-early-out { background: #FED7AA;               border-color: transparent; }  /* orange-200 */
.pd-cal-cell.pd-cal-missing  { background: #FECACA;                border-color: transparent; }  /* red-200 — missing punch */
.pd-cal-cell.pd-cal-leave    { background: #DBEAFE;                border-color: transparent; }  /* blue-100 */
.pd-cal-cell.pd-cal-holiday  { background: #EDE9FE;                border-color: transparent; }  /* purple-100 */
.pd-cal-cell.pd-cal-weekoff  { background: #F1F5F9;                border-color: transparent; }  /* slate-100 */
.pd-cal-cell.pd-cal-empty    { background: var(--pd-surface); }

/* Status dot — small colored indicator in top-left of each cell */
.pd-cal-cell::before { content: ''; position: absolute; top: 6px; right: 6px; width: 7px; height: 7px; border-radius: 50%; background: transparent; }
.pd-cal-cell.pd-cal-present::before  { background: #16A34A; }
.pd-cal-cell.pd-cal-absent::before   { background: #DC2626; }
.pd-cal-cell.pd-cal-late::before     { background: #F59E0B; }
.pd-cal-cell.pd-cal-half::before     { background: #EA580C; }
.pd-cal-cell.pd-cal-early-out::before { background: #C2410C; }
.pd-cal-cell.pd-cal-missing::before  { background: #B91C1C; }
.pd-cal-cell.pd-cal-leave::before    { background: #2563EB; }
.pd-cal-cell.pd-cal-holiday::before  { background: #7C3AED; }
.pd-cal-cell.pd-cal-weekoff::before  { background: #64748B; }

/* Legacy is-* aliases (some templates may still use these) */
.pd-cal-cell.is-present { background: var(--pd-success-soft); border-color: transparent; }
.pd-cal-cell.is-absent  { background: var(--pd-danger-soft); border-color: transparent; }
.pd-cal-cell.is-late    { background: var(--pd-warning-soft); border-color: transparent; }
.pd-cal-cell.is-leave   { background: #DBEAFE; border-color: transparent; }
.pd-cal-cell.is-holiday { background: #EDE9FE; border-color: transparent; }

.pd-cal-date { font-weight: 600; color: var(--pd-text); font-size: 12px; }
.pd-cal-status { font-size: 10px; color: var(--pd-text-muted); }

.pd-legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12px; color: var(--pd-text-muted); }
.pd-legend-item { display: flex; align-items: center; gap: 6px; }
.pd-legend-swatch { width: 10px; height: 10px; border-radius: 3px; }

/* Profile */
.pd-profile-head {
	display: flex;
	align-items: center;
	gap: 20px;
	padding: 24px;
	background: linear-gradient(135deg, var(--pd-primary) 0%, var(--pd-primary-2) 100%);
	border-radius: var(--pd-radius-lg);
	color: #fff;
	margin-bottom: 16px;
}
.pd-profile-avatar {
	width: 80px; height: 80px;
	border-radius: 50%;
	background: linear-gradient(135deg, var(--pd-accent), var(--pd-accent-dark));
	display: grid; place-items: center;
	font-size: 28px;
	font-weight: 700;
	color: #fff;
	border: 3px solid rgba(255,255,255,.2);
}
.pd-profile-info h1 { color: #fff; font-size: 24px; margin-bottom: 4px; }
.pd-profile-info p  { color: rgba(226,232,240,.8); }

.pd-info-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px 32px; }
.pd-info-row { display: flex; flex-direction: column; gap: 2px; }
.pd-info-label { font-size: 11px; color: var(--pd-text-muted); text-transform: uppercase; letter-spacing: .8px; font-weight: 600; }
.pd-info-value { font-size: 14px; color: var(--pd-text); font-weight: 500; }

/* Misc helpers */
.pd-spacer-sm { height: 8px; }
.pd-spacer    { height: 16px; }
.pd-spacer-lg { height: 24px; }
.pd-flex { display: flex; }
.pd-flex-between { display: flex; justify-content: space-between; align-items: center; }
.pd-flex-end { display: flex; justify-content: flex-end; gap: 8px; }
.pd-muted { color: var(--pd-text-muted); }
.pd-mono  { font-family: 'JetBrains Mono', monospace; }

/* Responsive */
@media (max-width: 1080px) {
	.pd-kpi-grid { grid-template-columns: repeat(2, 1fr); }
	.pd-grid-23, .pd-grid-32 { grid-template-columns: 1fr; }
	.pd-grid-2 { grid-template-columns: 1fr; }
}
@media (max-width: 820px) {
	.pd-shell { grid-template-columns: 1fr; }
	.pd-sidebar { display: none; }
	.pd-login { grid-template-columns: 1fr; }
	.pd-login-hero { padding: 32px; min-height: 240px; }
	.pd-content { padding: 18px; }
	.pd-checkin { grid-template-columns: 1fr; }
}

/* ── Badges ──────────────────────────────────────────────────────────────── */
.pd-badge {
	display: inline-flex; align-items: center;
	padding: 2px 8px; border-radius: 5px; font-size: 11px; font-weight: 600;
	letter-spacing: .03em; background: var(--pd-surface-2); color: var(--pd-text-muted);
	border: 1px solid var(--pd-border);
}
.pd-badge.is-success { background: var(--pd-success-soft); color: var(--pd-success); border-color: transparent; }
.pd-badge.is-warning { background: var(--pd-warning-soft); color: #B45309; border-color: transparent; }
.pd-badge.is-danger  { background: var(--pd-danger-soft);  color: var(--pd-danger);  border-color: transparent; }
.pd-badge.is-info    { background: var(--pd-info-soft);    color: var(--pd-info);    border-color: transparent; }
.pd-badge.is-muted   { background: var(--pd-surface-2);    color: var(--pd-text-muted); }
.pd-badge.is-secondary { background: var(--pd-surface-2);  color: var(--pd-text-light); }

/* ── Alerts ──────────────────────────────────────────────────────────────── */
.pd-alert {
	padding: 12px 16px; border-radius: var(--pd-radius); font-size: 13px;
	border-left: 3px solid currentColor;
}
.pd-alert.is-success { background: var(--pd-success-soft); color: var(--pd-success); }
.pd-alert.is-danger  { background: var(--pd-danger-soft);  color: var(--pd-danger); }
.pd-alert.is-warning { background: var(--pd-warning-soft); color: #B45309; }
.pd-alert.is-info    { background: var(--pd-info-soft);    color: var(--pd-info); }
.pd-alert.is-secondary { background: var(--pd-surface-2);  color: var(--pd-text-muted); border-left-color: var(--pd-border); }

/* ── Hint text ───────────────────────────────────────────────────────────── */
.pd-hint { font-size: 11px; color: var(--pd-text-muted); margin-top: 2px; }

/* ── Empty state ─────────────────────────────────────────────────────────── */
.pd-empty-state {
	display: flex; flex-direction: column; align-items: center; justify-content: center;
	padding: 64px 24px; text-align: center;
	background: var(--pd-surface); border: 1px solid var(--pd-border);
	border-radius: var(--pd-radius-lg);
}
.pd-empty-title { font-size: 15px; font-weight: 600; color: var(--pd-text); margin: 0 0 6px; }
.pd-empty-sub   { font-size: 13px; color: var(--pd-text-muted); margin: 0 0 20px; max-width: 360px; }

/* ── Danger ghost button ─────────────────────────────────────────────────── */
.pd-btn.is-danger-ghost {
	background: transparent; color: var(--pd-danger);
	border: 1px solid var(--pd-danger-soft);
}
.pd-btn.is-danger-ghost:hover { background: var(--pd-danger-soft); border-color: var(--pd-danger); }

/* ── Modal ───────────────────────────────────────────────────────────────── */
.pd-modal-backdrop {
	display: none; position: fixed; inset: 0; z-index: 1000;
	background: rgba(0,0,0,.45); align-items: center; justify-content: center;
	overflow-y: auto; padding: 24px;
}
.pd-modal {
	background: var(--pd-surface); border-radius: var(--pd-radius-lg);
	box-shadow: 0 20px 60px rgba(0,0,0,.25); width: 100%; max-width: 420px;
	margin: auto;
}
.pd-modal-head {
	display: flex; align-items: center; justify-content: space-between;
	padding: 18px 20px; border-bottom: 1px solid var(--pd-border);
}
.pd-modal-head h3 { margin: 0; font-size: 15px; font-weight: 600; }
.pd-modal-body { padding: 20px; }
.pd-modal-foot {
	display: flex; justify-content: flex-end; gap: 8px;
	padding: 14px 20px; border-top: 1px solid var(--pd-border);
}
.pd-modal-close {
	background: none; border: none; cursor: pointer; color: var(--pd-text-muted);
	font-size: 16px; padding: 4px; line-height: 1; border-radius: 4px;
}
.pd-modal-close:hover { color: var(--pd-text); background: var(--pd-surface-2); }
